---
updatedAt: 2026-04-24T16:39:54.000Z
agentTools:
  projectIndex: https://developers.cloudbeds.com/llms.txt
---

# Get list of fiscal documents

Retrieves a paginated list of fiscal documents filtered by optional criteria.

# OpenAPI definition

```json
{
  "openapi": "3.0.1",
  "info": {
    "title": "Fiscal document service API",
    "version": "v1"
  },
  "servers": [
    {
      "url": "https://api.cloudbeds.com"
    }
  ],
  "paths": {
    "/fiscal-document/v1/fiscal-documents": {
      "get": {
        "summary": "Get list of fiscal documents",
        "description": "Retrieves a paginated list of fiscal documents filtered by optional criteria.",
        "operationId": "getFiscalDocuments",
        "tags": [
          "Fiscal Documents"
        ],
        "security": [
          {
            "bearerAuth": []
          },
          {
            "oauth2": [
              "read:reservation"
            ]
          }
        ],
        "parameters": [
          {
            "$ref": "#/components/parameters/propertyIdHeader"
          },
          {
            "name": "pageToken",
            "in": "query",
            "description": "Token for fetching the next page, as per cursor-based pagination.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "sort",
            "in": "query",
            "description": "Supported fields:\n - createdAt\n - dueDate\n - invoiceDate\n - kind\n - status\n\nSupported sort modes asc:desc. If not supplied default is asc.\n",
            "required": false,
            "schema": {
              "type": "string",
              "example": "createdAt:desc"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "description": "Number of results to return per page.",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 20,
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "in": "query",
            "name": "filters",
            "schema": {
              "$ref": "#/components/schemas/FiscalDocumentFilters"
            },
            "style": "form",
            "explode": true
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FiscalDocumentPaginated"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "JWT"
      },
      "oauth2": {
        "type": "oauth2",
        "flows": {
          "authorizationCode": {
            "authorizationUrl": "https://api.cloudbeds.com/auth/oauth/authorize",
            "tokenUrl": "https://api.cloudbeds.com/auth/oauth/token",
            "scopes": {
              "read:reservation": "Read fiscal documents and fiscalization configuration",
              "write:reservation": "Create, update, or void fiscal documents and fiscalization configuration"
            }
          }
        }
      }
    },
    "parameters": {
      "propertyIdHeader": {
        "name": "X-Property-ID",
        "in": "header",
        "required": true,
        "schema": {
          "type": "integer",
          "format": "int64",
          "minimum": 1
        },
        "description": "Property id"
      }
    },
    "schemas": {
      "FiscalDocumentDetailedResponse": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "number": {
            "type": "string"
          },
          "propertyId": {
            "type": "string"
          },
          "userId": {
            "type": "string"
          },
          "userFullName": {
            "type": "string"
          },
          "sourceName": {
            "type": "string"
          },
          "sourceId": {
            "type": "string"
          },
          "sourceKind": {
            "$ref": "#/components/schemas/SourceKind"
          },
          "kind": {
            "$ref": "#/components/schemas/FiscalDocumentKind"
          },
          "invoiceDate": {
            "deprecated": true,
            "type": "string",
            "format": "date"
          },
          "invoiceDatePropertyTimezone": {
            "type": "string",
            "format": "date"
          },
          "fileName": {
            "type": "string"
          },
          "files": {
            "type": "array",
            "description": "All files available for this document, primary first followed by any additional stored files (e.g. the Portuguese duplicate). Always present as an array, but may be empty for documents whose file has not been generated yet (e.g. REQUESTED or early FAILED status). The primary file entry, when present, has a null id (the download endpoint serves it without a fileId; additional entries are downloaded by passing their id as the fileId query parameter).\n",
            "items": {
              "$ref": "#/components/schemas/FiscalDocumentFile"
            }
          },
          "amount": {
            "type": "number"
          },
          "balance": {
            "type": "number"
          },
          "dueDate": {
            "deprecated": true,
            "type": "string",
            "format": "date"
          },
          "dueDatePropertyTimezone": {
            "type": "string",
            "format": "date"
          },
          "recipients": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RecipientDetails"
            }
          },
          "status": {
            "$ref": "#/components/schemas/FiscalDocumentStatus"
          },
          "origin": {
            "type": "string"
          },
          "externalId": {
            "type": "string"
          },
          "failReason": {
            "type": "string"
          },
          "reason": {
            "type": "string",
            "nullable": true,
            "description": "Correction reason recorded when the document was created (credit notes and rectifying invoices). One of the slugs offered by the credit-note action's reason field, or free text on the Spanish rectify path. Null when no reason was given."
          },
          "method": {
            "$ref": "#/components/schemas/CreationMethod"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "parentId": {
            "type": "string"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          },
          "governmentIntegration": {
            "$ref": "#/components/schemas/GovernmentIntegration"
          },
          "latestLinkedDocument": {
            "$ref": "#/components/schemas/LatestLinkedDocument"
          },
          "linkedDocuments": {
            "type": "array",
            "description": "List of documents linked to this fiscal document (both parent and child relationships)",
            "items": {
              "$ref": "#/components/schemas/LinkedDocument"
            }
          },
          "actions": {
            "$ref": "#/components/schemas/Actions"
          },
          "sourceIdentifier": {
            "type": "string",
            "description": "Reservation Identifier or a group code"
          },
          "simplified": {
            "type": "boolean",
            "nullable": false,
            "description": "Applies to invoices only."
          },
          "requireAttention": {
            "type": "boolean",
            "nullable": false,
            "description": "Indicates whether this document requires manual attention."
          },
          "hasDiscrepancies": {
            "type": "boolean",
            "nullable": false,
            "description": "Indicates whether this document has pending transaction discrepancies."
          },
          "packageBreakdown": {
            "type": "boolean",
            "nullable": true,
            "description": "Per-document override for package breakdown. Null means use property default."
          },
          "vatDisplay": {
            "$ref": "#/components/schemas/VatDisplay"
          },
          "currency": {
            "type": "string",
            "nullable": true,
            "description": "Currency the document amount is expressed in. Equals the invoice/document currency, which may differ from the property base currency when a foreign-currency invoice was issued."
          },
          "propertyCurrency": {
            "type": "string",
            "nullable": true,
            "description": "The property's base currency code."
          },
          "propertyCurrencyAmount": {
            "type": "number",
            "nullable": true,
            "description": "The document amount converted to the property's base currency using the property's configured exchange rates. Null when the document currency already equals the property base currency (no conversion needed)."
          }
        },
        "required": [
          "files"
        ]
      },
      "FiscalDocumentPaginated": {
        "type": "object",
        "properties": {
          "fiscalDocuments": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FiscalDocumentDetailedResponse"
            }
          },
          "nextPageToken": {
            "$ref": "#/components/schemas/NextPageToken"
          }
        }
      },
      "RecipientDetails": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "minLength": 1
          },
          "firstName": {
            "type": "string"
          },
          "lastName": {
            "type": "string"
          },
          "email": {
            "type": "string",
            "format": "email"
          },
          "type": {
            "$ref": "#/components/schemas/RecipientType"
          },
          "companyName": {
            "type": "string"
          }
        }
      },
      "RecipientType": {
        "type": "string",
        "enum": [
          "COMPANY",
          "PERSON",
          "MANUAL"
        ]
      },
      "GovernmentIntegration": {
        "type": "object",
        "properties": {
          "number": {
            "type": "string"
          },
          "series": {
            "type": "string"
          },
          "invoiceType": {
            "type": "string",
            "nullable": true,
            "description": "AR ARCA invoice class (A/B/C/T) for this document, used to disambiguate documents that share series + number across classes. Null for non-AR documents.\n"
          },
          "status": {
            "type": "string"
          },
          "qr": {
            "type": "object",
            "properties": {
              "url": {
                "type": "string",
                "format": "uri"
              },
              "string": {
                "type": "string"
              }
            }
          },
          "url": {
            "type": "string",
            "format": "uri"
          },
          "officialId": {
            "type": "string"
          },
          "externalId": {
            "type": "string"
          },
          "rectifyingInvoiceType": {
            "type": "string"
          },
          "cancellationFailedFallbackStatus": {
            "$ref": "#/components/schemas/FiscalDocumentStatus"
          },
          "cancellationStatus": {
            "type": "string",
            "readOnly": true,
            "enum": [
              "PENDING",
              "CANCELLED",
              "FAILED"
            ],
            "description": "Outcome of the latest cancellation request sent to the tax authority."
          },
          "pdfFileBase64": {
            "type": "string",
            "format": "byte",
            "description": "Base64-encoded PDF file content. Only allowed when status is COMPLETED_INTEGRATION."
          },
          "handwritten": {
            "type": "boolean",
            "description": "Indicates this is a handwritten receipt created during POS unavailability."
          },
          "signatures": {
            "type": "array",
            "description": "Array of semantic signatures/response data from the government integration.",
            "items": {
              "$ref": "#/components/schemas/IntegrationSignature"
            }
          },
          "folioFiscal": {
            "type": "string",
            "description": "MX SAT UUID (Folio Fiscal) — populated after CFDI acceptance by Fonoa.",
            "example": "9B3E26F4-1234-4A5B-8C9D-ABCDEF012345"
          },
          "satQrCode": {
            "type": "string",
            "description": "MX SAT validation URL used to verify a CFDI at verificacfdi.facturaelectronica.sat.gob.mx."
          },
          "ext": {
            "type": "object",
            "readOnly": true,
            "additionalProperties": {
              "type": "string"
            },
            "description": "Provider-returned extension values for the document, keyed by extension or stamp code (e.g. AR \"ar-arca-doc-type\", and \"arca-cae-expiry\" for the CAE expiry date as YYYY-MM-DD; the CAE itself is in officialId). Read-only.\n",
            "example": {
              "ar-arca-doc-type": "6",
              "arca-cae-expiry": "2026-10-02"
            }
          },
          "connectionId": {
            "type": "integer",
            "format": "int64",
            "readOnly": true,
            "description": "The fiscalization connection this document was dispatched through; its provider and channel are those of the connection. Read-only — a partner reporting an outcome cannot change where the document was routed, and uses this to confirm the document was addressed to it before acting on it.\n"
          }
        }
      },
      "IntegrationSignature": {
        "type": "object",
        "description": "A semantic signature/response item from a government integration.",
        "properties": {
          "type": {
            "type": "string",
            "description": "Semantic type (JWT_TOKEN, QR_CODE_DATA, TRANSACTION_ID, COMPLIANCE_CHECK, etc.)"
          },
          "label": {
            "type": "string",
            "description": "Human-readable display label."
          },
          "value": {
            "type": "string",
            "description": "The actual signature data/value."
          },
          "format": {
            "type": "string",
            "description": "Format of the value.",
            "enum": [
              "TEXT",
              "BASE64",
              "HEX",
              "URL",
              "UNKNOWN"
            ]
          },
          "source": {
            "type": "string",
            "description": "Source integration (FISKALTRUST_FR, FISKALTRUST_IT, etc.)"
          },
          "rawMetadata": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            },
            "description": "Original integration-specific codes for debugging/auditing."
          }
        }
      },
      "Actions": {
        "type": "array",
        "description": "Returns the list of actions available for the transaction",
        "items": {
          "$ref": "#/components/schemas/Action"
        }
      },
      "Action": {
        "type": "object",
        "properties": {
          "type": {
            "$ref": "#/components/schemas/DocumentAction"
          },
          "fields": {
            "type": "array",
            "description": "Action-specific input fields the UI must collect before submitting. Uses the same FieldDefinition schema as /fiscalization/rules.\n",
            "items": {
              "$ref": "#/components/schemas/FieldDefinition"
            }
          }
        }
      },
      "NextPageToken": {
        "type": "string",
        "description": "Token for fetching the next page of results"
      },
      "LatestLinkedDocument": {
        "type": "object",
        "description": "Information about the latest document in a rectification chain",
        "properties": {
          "id": {
            "type": "string",
            "description": "ID of the latest linked document"
          },
          "number": {
            "type": "string",
            "description": "Number of the latest linked document"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time",
            "description": "Creation date of the latest linked document"
          },
          "kind": {
            "$ref": "#/components/schemas/FiscalDocumentKind"
          },
          "status": {
            "$ref": "#/components/schemas/FiscalDocumentStatus"
          }
        }
      },
      "LinkedDocument": {
        "type": "object",
        "description": "Information about a document linked to another fiscal document (parent or child relationship)",
        "properties": {
          "id": {
            "type": "string",
            "description": "ID of the linked document"
          },
          "number": {
            "type": "string",
            "description": "Number of the linked document"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time",
            "description": "Creation date of the linked document"
          },
          "kind": {
            "$ref": "#/components/schemas/FiscalDocumentKind"
          },
          "status": {
            "$ref": "#/components/schemas/FiscalDocumentStatus"
          },
          "isLatest": {
            "type": "boolean",
            "description": "Whether this is the latest document in the chain"
          },
          "relationshipType": {
            "type": "string",
            "enum": [
              "PARENT",
              "CHILD",
              "REPLACED",
              "REPLACED_BY"
            ],
            "description": "PARENT means this document is linked to the current document, CHILD means the current document is linked to this one. REPLACED and REPLACED_BY are the two sides of a replacement: on an invoice, REPLACED names a receipt it withdrew — one that already declared the same charges and was voided when the invoice was issued; on that receipt, REPLACED_BY names the invoice that withdrew it. A client that presents the two differently should read this field; one that lists related documents plainly needs no change."
          }
        }
      },
      "FiscalDocumentFile": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "nullable": true,
            "description": "Id of the stored file, passed as the download endpoint's fileId query parameter. Null for the primary file (the document itself), which the download endpoint serves without a fileId."
          },
          "category": {
            "$ref": "#/components/schemas/FiscalDocumentFileCategory"
          },
          "mimeType": {
            "type": "string",
            "description": "Mime type of the file, derived from its extension (e.g. application/pdf)."
          },
          "filename": {
            "type": "string",
            "description": "Display file name, including extension."
          }
        },
        "required": [
          "category",
          "mimeType",
          "filename"
        ]
      },
      "FiscalDocumentFileCategory": {
        "type": "string",
        "description": "The role this file plays for the document. Clients must tolerate unknown values.",
        "enum": [
          "PRIMARY",
          "DUPLICATE",
          "XML",
          "UNOFFICIAL_COPY",
          "CANCELLATION_ACK"
        ]
      },
      "DocumentAction": {
        "type": "string",
        "description": "Action that can be performed on a fiscal document",
        "enum": [
          "CANCEL",
          "RECTIFY",
          "DOWNLOAD",
          "CREDIT_NOTE",
          "VOID_AND_CREDIT_NOTE",
          "VOID",
          "VOID_AND_REFUND",
          "ADD_PAYMENT",
          "APPLY_TO_INVOICE",
          "GENERATE_SETTLEMENT"
        ]
      },
      "SourceKind": {
        "type": "string",
        "description": "Kind of the source entity",
        "enum": [
          "GROUP_PROFILE",
          "RESERVATION",
          "HOUSE_ACCOUNT",
          "ACCOUNTS_RECEIVABLE_LEDGER"
        ]
      },
      "Origin": {
        "type": "string",
        "description": "Origin of the fiscal document",
        "enum": [
          "MFD",
          "FISCAL_DOCUMENT",
          "INTEGRATION"
        ]
      },
      "FiscalDocumentStatus": {
        "type": "string",
        "description": "Status of the fiscal document",
        "enum": [
          "COMPLETED",
          "VOIDED",
          "PAID",
          "PENDING_INTEGRATION",
          "PARTIALLY_PAID",
          "COMPLETED_INTEGRATION",
          "FAILED_INTEGRATION",
          "CORRECTION_NEEDED",
          "CANCELED",
          "CANCEL_REQUESTED",
          "OPEN",
          "REQUESTED",
          "VOID_REQUESTED",
          "FAILED",
          "MANUALLY_RECONCILED",
          "REJECTED",
          "ACCEPTED",
          "PENDING_TRANSACTION",
          "ALLOCATED",
          "APPLIED"
        ]
      },
      "FiscalDocumentKind": {
        "type": "string",
        "description": "Kind of fiscal document",
        "enum": [
          "INVOICE",
          "CREDIT_NOTE",
          "RECEIPT",
          "RECTIFY_INVOICE",
          "PRO_FORMA_INVOICE",
          "REFUND_RECEIPT",
          "INVOICE_RECEIPT",
          "ADVANCE_INVOICE",
          "SETTLEMENT_INVOICE",
          "TAX_WITHHOLDING"
        ]
      },
      "VatDisplay": {
        "type": "string",
        "enum": [
          "PER_LINE",
          "SUMMARY_ONLY"
        ]
      },
      "CreationMethod": {
        "type": "string",
        "enum": [
          "VOID",
          "ADJUSTMENT"
        ]
      },
      "FiscalDocumentFilters": {
        "type": "object",
        "properties": {
          "ids": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "List of IDs to filter by",
            "example": [
              "123",
              "456",
              "789"
            ]
          },
          "sourceIds": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "List of source IDs to filter by",
            "example": [
              "123",
              "456",
              "789"
            ]
          },
          "sourceIdentifiers": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "List of source-specific identifiers",
            "example": [
              "ABC123",
              "XYZ789"
            ]
          },
          "sourceKind": {
            "$ref": "#/components/schemas/SourceKind",
            "description": "Filter by source kind"
          },
          "sourceKinds": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SourceKind"
            },
            "description": "Filter by source kind"
          },
          "numberContains": {
            "type": "string",
            "description": "Filter by document number partial match"
          },
          "statuses": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FiscalDocumentStatus"
            },
            "description": "List of fiscal document statuses to filter by",
            "example": [
              "OPEN",
              "COMPLETED"
            ]
          },
          "kinds": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FiscalDocumentKind"
            },
            "description": "List of fiscal document kinds to filter by",
            "example": [
              "INVOICE",
              "RECEIPT"
            ]
          },
          "origins": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Origin"
            },
            "description": "List of fiscal document origins to filter by",
            "example": [
              "MFD",
              "FISCAL_DOCUMENT"
            ]
          },
          "createdAtFrom": {
            "type": "string",
            "format": "date-time",
            "description": "Creation date-time range start"
          },
          "createdAtTo": {
            "type": "string",
            "format": "date-time",
            "description": "Creation date-time range end"
          },
          "invoiceDateFrom": {
            "deprecated": true,
            "type": "string",
            "format": "date",
            "description": "Invoice date range start"
          },
          "invoiceDateTo": {
            "deprecated": true,
            "type": "string",
            "format": "date",
            "description": "Invoice date range end"
          },
          "invoiceDatePropertyTimezoneFrom": {
            "type": "string",
            "format": "date",
            "description": "Invoice date range start"
          },
          "invoiceDatePropertyTimezoneTo": {
            "type": "string",
            "format": "date",
            "description": "Invoice date range end"
          },
          "dueDateFrom": {
            "deprecated": true,
            "type": "string",
            "format": "date",
            "description": "Due date range start"
          },
          "dueDateTo": {
            "deprecated": true,
            "type": "string",
            "format": "date",
            "description": "Due date range end"
          },
          "dueDatePropertyTimezoneFrom": {
            "type": "string",
            "format": "date",
            "description": "Due date range start"
          },
          "dueDatePropertyTimezoneTo": {
            "type": "string",
            "format": "date",
            "description": "Due date range end"
          },
          "amountFrom": {
            "type": "number",
            "description": "Minimum document amount"
          },
          "amountTo": {
            "type": "number",
            "description": "Maximum document amount"
          },
          "balanceFrom": {
            "type": "number",
            "description": "Minimum document balance"
          },
          "balanceTo": {
            "type": "number",
            "description": "Maximum document balance"
          },
          "hasDiscrepancies": {
            "type": "boolean",
            "description": "Filter by whether the document has pending-transaction discrepancies. Reads the persisted `hasDiscrepancies` flag, the same one returned in the response payload."
          }
        }
      },
      "FieldDefinition": {
        "type": "object",
        "required": [
          "path",
          "label",
          "type",
          "required"
        ],
        "properties": {
          "path": {
            "type": "string",
            "description": "Field path (e.g., \"name\", \"tax_id.code\", \"addresses\")",
            "example": "name"
          },
          "label": {
            "type": "string",
            "description": "Display label for the field",
            "example": "Legal Name"
          },
          "type": {
            "type": "string",
            "enum": [
              "text",
              "email",
              "password",
              "file",
              "select",
              "boolean",
              "array",
              "object"
            ],
            "description": "Field input type"
          },
          "category": {
            "type": "string",
            "enum": [
              "company",
              "tax",
              "address",
              "contact",
              "supplementary",
              "custom"
            ],
            "description": "Field grouping category"
          },
          "sectionKey": {
            "type": "string",
            "description": "Key of the RulesSection that hosts this field. Defaults to \"registration\" when absent. Nested fields inside arrays/objects inherit the parent's section and should omit this attribute.",
            "example": "customization.invoicing"
          },
          "required": {
            "type": "boolean",
            "description": "Whether field is required"
          },
          "requiredIf": {
            "$ref": "#/components/schemas/FieldCondition"
          },
          "primary": {
            "type": "boolean",
            "description": "Indicates primary tax ID field",
            "default": false
          },
          "editable": {
            "type": "boolean",
            "description": "Whether this field can still be edited once the property is a connected provider. Defaults to false; the registration email and any country-specific editable fields (e.g. Croatia's Business Premises Code and POS Device Code) are true.",
            "default": false
          },
          "validation": {
            "$ref": "#/components/schemas/FieldValidation"
          },
          "data": {
            "$ref": "#/components/schemas/FieldData"
          },
          "options": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SelectOption"
            }
          },
          "item": {
            "$ref": "#/components/schemas/ArrayItemDefinition"
          },
          "properties": {
            "type": "object",
            "additionalProperties": {
              "$ref": "#/components/schemas/FieldDefinition"
            },
            "description": "Object properties for object type fields"
          },
          "default": {
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "boolean"
              },
              {
                "type": "number"
              }
            ]
          },
          "description": {
            "type": "string",
            "description": "Field description"
          }
        }
      },
      "FieldCondition": {
        "type": "object",
        "required": [
          "field",
          "pattern"
        ],
        "properties": {
          "field": {
            "type": "string",
            "description": "Path of the sibling field whose value is tested (e.g. \"taxId\").",
            "example": "taxId"
          },
          "pattern": {
            "type": "string",
            "description": "Regex applied to the referenced field's value. The owning field is required only when the referenced value matches this pattern.",
            "example": "^[^123]"
          }
        }
      },
      "SelectOption": {
        "type": "object",
        "required": [
          "value",
          "label"
        ],
        "properties": {
          "value": {
            "type": "string"
          },
          "label": {
            "type": "string"
          }
        }
      },
      "FieldValidation": {
        "type": "object",
        "properties": {
          "pattern": {
            "type": "string",
            "description": "Regex pattern for validation"
          },
          "min": {
            "type": "integer",
            "description": "Minimum length or items"
          },
          "max": {
            "type": "integer",
            "description": "Maximum length"
          },
          "checksum": {
            "type": "boolean",
            "description": "Whether field has checksum validation"
          },
          "format": {
            "type": "string",
            "description": "Display format mask (e.g., XX.XXX.XXX/XXXX-XX)"
          },
          "message": {
            "type": "string",
            "description": "Human-readable description of the rule, suitable for FE error messages (e.g. \"NFS-e series must be 1-5 alphanumeric characters\")."
          },
          "example": {
            "type": "string",
            "description": "A valid example value that can be shown as a placeholder hint (e.g. \"ABC12\" for NFS-e, \"1\" for NFC-e)."
          }
        }
      },
      "FieldData": {
        "type": "object",
        "properties": {
          "placeholder": {
            "type": "string",
            "description": "Input placeholder text"
          },
          "help": {
            "type": "string",
            "description": "Help text for the field"
          },
          "alternatives": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Alternative accepted formats (e.g., CPF for CNPJ fields)"
          }
        }
      },
      "ArrayItemDefinition": {
        "type": "object",
        "required": [
          "type",
          "fields"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "object"
            ]
          },
          "fields": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/FieldDefinition"
            }
          }
        }
      }
    }
  }
}
```