Endpoint Issuing

API invoice creation is used when you need to issue invoices programmatically by integrating Brinta with your system or ERP.

This option is ideal when you:

  1. Want to automate invoice issuance
  2. Issue invoices in real time from your own system
  3. Work with large or continuous invoice volumes
  4. Need a scalable and fully integrated solution

With API invoice creation, you can:

  1. Send invoice data directly to Brinta via API
  2. Issue invoices without using the dashboard
  3. Handle multiple document types programmatically
  4. Receive real-time responses and validation results

This method follows the same validation rules as manual and bulk invoicing, including country-specific electronic invoicing requirements.


How it works

All invoice creation goes through a single endpoint:

POST https://api.brinta.com/invoices

The payload structure is the same across all countries and document types. What changes is which fields are required depending on the country and document type you're issuing.

The general flow is:

  1. Authenticate — include your API key in the request header.
  2. Build the payload — set invoice_type, document_type, and the fields required for your country.
  3. Send the request — Brinta validates, stamps, and returns the signed document.
  4. Handle the response — check the status and store the invoice ID and fiscal UUID returned.

Payload structure

Every request shares the same root structure:

FieldTypeRequiredDescription
supplier_company_idstringYesUUID of the issuing company registered in Brinta.
invoice_typestringYesType of document. Possible values: debit, payment, transport.
document_typestringYesSpecific document format. Varies by country — see Invoice Document Types.
invoice_datestringYesIssuance date in YYYY-MM-DD format.
invoice_seriestringVariesInvoice series or prefix.
invoice_numberstringVariesInvoice number or folio.
currencystringYesISO 4217 currency code (e.g. MXN, PEN, COP).
exchange_ratenumberVariesRequired when currency is not the country's local currency.
e_invoicebooleanYesSet to true to issue as an electronic invoice.
reasonstringVariesUsage or transport reason code. Country-specific SAT/SUNAT catalog.
export_reasonstringVariesExport or transfer reason. Required for MX transport documents.
fiscal_statusstringVariesFiscal object code. Required for MX payment invoices (SAT c_ObjetoImp).
additional_infostringNoFree-text field appended to the document. Used for PE transport.
payment_methodobjectVariesPayment form. Required for MX payment invoices.
buyerobjectYesBuyer information including tax registrations and address.
itemsarrayVariesLine items. Required for standard invoices.
sendersarrayVariesOrigin locations. Required for MX and PE transport documents.
beneficiariesarrayVariesDestination locations. Required for MX and PE transport documents.
transportation_companiesarrayVariesDrivers, owners, and carriers. Required for MX and PE transport documents.
vehicleobjectVariesVehicle information. Required for all transport documents.
amountsarrayVariesDocument-level payment amounts. Required for MX Payment Invoice Mode A.
taxesarrayVariesDocument-level taxes. Required for MX Payment Invoice Mode A.
relationsarrayVariesRelated documents. Used for MX payment invoices and PE transport.

Authentication

Include your API key in every request:

curl --request POST \
  --url https://api.brinta.com/invoices \
  --header 'accept: application/json' \
  --header 'content-type: application/json' \
  --header 'Authorization: Bearer YOUR_API_KEY' \
  --data '{...}'

Document types by country

CountryDocumentinvoice_typedocument_type
ALLStandard Invoicedebitinvoice
MXPayment Complementpaymentpayment invoice
MXBill of Lading — Roadtransportbill of lading road
MXBill of Lading — Airtransportbill of lading air
MXBill of Lading — Seatransportbill of lading sea
MXBill of Lading — Railtransportbill of lading rail
PETransport (Guia de Remision)transporttransport

For a complete list see Invoice Document Types.


Response

A successful request returns 201 with the created invoice object, including:

  • id — Brinta invoice UUID
  • invoice_key — Fiscal UUID (folio fiscal) stamped by the tax authority
  • status — Current invoice status
  • xml / pdf — Signed document links (where applicable)

For error codes and status descriptions see Invoice Status Codes and Invoice Errors.


Useful Links