Listar documentos de facturación

GET/api/public/v1/billing-documents

Devuelve, en formato HAL, el estado de facturación de las transacciones indicadas en purchaseCodes (hasta 100 por consulta), con sus comprobantes fiscales y el resumen de impuestos consolidado. Las transacciones sin documento de facturación no aparecen en el resultado. Los campos del comprobante varían según el país (México, Argentina o Chile). Los importes en cero no se envían, salvo discountTotal, tipTotal, insuranceTotal y localOtherTotal, donde el cero tiene significado propio.

Autorización

apiKeyScheme
X-API-KEY<token>

En: header

Parámetros de consulta

purchaseCodes*array<string>

Códigos únicos (uniqueCode) de las transacciones por las que filtrar los documentos de facturación (máximo 100).

Elementos0 <= items <= 100
page?integer

Número de página a devolver, comenzando en 0.

Formatoint32
Rango0 <= value
size?integer

Cantidad de elementos por página. Por defecto 20; un valor mayor al máximo de la operación (500 salvo que se indique otro) se recorta a ese máximo.

Formatoint32
sort?array<>

Criterios de ordenamiento, en orden de prioridad. Cada criterio se envía con índice: sort[0].property=<campo>&sort[0].direction=ASC|DESC.

Criterios de ordenamiento, enviados como sort[0].property y sort[0].direction (ASC o DESC). Sin ordenamiento explícito, el orden de los resultados no está garantizado.

property?string
direction?string

Valor en

  • "ASC"
  • "DESC"
excludeCount?boolean

Si es true, omite el cálculo del total de resultados para responder más rápido.

Cuerpo de la respuesta

application/vnd.hal+json

application/json

application/json

curl -X GET "https://example.com/api/public/v1/billing-documents"
{  "_embedded": {    "billing-documents": [      {        "_links": {          "property1": {            "href": "string",            "hreflang": "string",            "title": "string",            "type": "string",            "deprecation": "string",            "profile": "string",            "name": "string",            "templated": true          },          "property2": {            "href": "string",            "hreflang": "string",            "title": "string",            "type": "string",            "deprecation": "string",            "profile": "string",            "name": "string",            "templated": true          }        },        "purchaseUniqueCode": "0590843e-1d92-4d51-82c6-4a22a6b8be82",        "summaryStatus": "IN_PROGRESS",        "summaryDetail": "string",        "status": "ACTIVE",        "closingReason": "string",        "expectedRecoveryDay": "2024-11-13T16:51:00.000Z",        "fiscalDocuments": [          {            "sellerLegalId": "string",            "sellerLegalName": "string",            "sellerTaxRegime": "string",            "payerLegalId": "string",            "payerLegalName": "string",            "issueDateTime": "2024-11-13T16:51:00.000Z",            "amount": 2358,            "subTotal": 2000,            "currency": "string",            "legalUniqueCode": "string",            "orphan": true,            "invoiceNumber": "string",            "legalStatus": "string",            "legalSignature": "string",            "serie": "string",            "certificate": "string",            "receiptType": "I",            "version": "http://www.sat.gob.mx/cfd/4",            "payerTaxRegime": "string",            "payerTaxDomicile": "string",            "payerTaxResidence": "string",            "wayToPay": "04",            "paymentMethod": "PUE",            "cfdiUse": "G03",            "export": "01",            "expeditionPlace": "string",            "taxNumberIdentifier": "string",            "taxes": 358,            "discount": 50,            "exchangeRate": 0,            "isrRetencionTotal": 0,            "isrTrasladoTotal": 0,            "ivaTrasladoTotal": 0,            "ivaRetencionTotal": 0,            "iepsTrasladoTotal": 0,            "ishImpuestosLocalesTotal": 0,            "invoiceCode": "string",            "invoiceType": "string",            "salesPointNumber": "string",            "referenceNumber": "string",            "legalExpirationDate": "2024-11-13T16:51:00.000Z",            "exemptAmount": 2000,            "noTaxableAmount": 2000,            "ivaExemptAmount": 250,            "iva": 630,            "ingresosBrutos": 240,            "fiscalDocumentTaxes": [              {                "amount": 358,                "taxCatalog": {                  "code": "002",                  "type": "IVA",                  "category": "TRASLADO"                },                "baseAmount": 2000,                "taxRate": 0.16,                "factorType": "Tasa"              }            ],            "fiscalDocumentItems": [              {                "claveProdServ": "78111500",                "descripcion": "string",                "cantidad": 1,                "valorUnitario": 100,                "importe": 100              }            ]          }        ],        "purchaseTaxSummary": {          "sellerLegalId": "string",          "sellerLegalName": "string",          "invoiceNumber": "string",          "issueDateTime": "2024-11-13T16:51:00Z",          "totalAmount": 2358,          "totalSubtotal": 2000,          "unbilledAmount": 45,          "legalUniqueCode": "string",          "legalStatus": "string",          "expeditionPlace": "string",          "isrRetencionTotal": 0,          "isrTrasladoTotal": 0,          "ivaTrasladoTotal": 0,          "ivaRetencionTotal": 0,          "iepsTrasladoTotal": 0,          "ishImpuestosLocalesTotal": 0,          "trasladoIvaIsrTotal": 0,          "discountTotal": 0,          "tipTotal": 45,          "insuranceTotal": 0,          "localOtherTotal": 28.4,          "localTaxRawName": "string",          "taxesBreakdown": [            {              "code": "string",              "type": "string",              "category": "string",              "rate": 0.16,              "baseAmount": 946.72,              "factorType": "Tasa",              "amount": 151.48            }          ],          "invoiceCode": "string",          "invoiceType": "string",          "salesPointNumber": "string",          "referenceNumber": "string",          "legalExpirationDate": "2024-11-13T16:51:00.000Z",          "totalIva": 0,          "totalIngresosBrutos": 0,          "totalExemptAmount": 0,          "totalNoTaxableAmount": 0,          "totalIvaExemptAmount": 0,          "referencedDocumentFolio": "string",          "referencedDocumentType": "string",          "referencedDocumentCode": "string",          "referencedDocumentDate": "2025-09-01"        }      }    ]  },  "_links": {    "property1": {      "href": "string",      "hreflang": "string",      "title": "string",      "type": "string",      "deprecation": "string",      "profile": "string",      "name": "string",      "templated": true    },    "property2": {      "href": "string",      "hreflang": "string",      "title": "string",      "type": "string",      "deprecation": "string",      "profile": "string",      "name": "string",      "templated": true    }  },  "page": {    "size": 0,    "totalElements": 0,    "totalPages": 0,    "number": 0  }}