Skip to content
Documentation
Get started

Invoices

Preview an Invoice without issuing it

POST
/v1/invoices/preview
curl --request POST \
--url https://api.timbro.do/v1/invoices/preview \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "additionalInformation": { "referenceNumber": "example", "shipment": { "containerNumber": "example", "deliveryNoteNumber": "example", "driver": "example", "grossWeight": "example", "grossWeightUnit": "example", "netWeight": "example", "netWeightUnit": "example", "packageCount": "example", "packageUnit": "example", "packageVolume": "example", "route": "example", "shipmentDate": "example", "shipmentNumber": "example", "transportDocumentNumber": "example", "transportZone": "example", "vehicleFiche": "example", "vehiclePlate": "example", "volumeUnit": "example" } }, "buyer": { "address": "example", "deliveryPhone": "example", "email": "example", "legalName": "example", "taxId": "example" }, "currency": "DOP", "exchangeRate": { "rate": "example" }, "expectedTotals": { "fiscal": { "net": "example", "tax": "example", "total": "example" }, "net": "example", "nonBillable": "example", "tax": "example", "total": "example" }, "incomeType": "01", "invoiceReference": "example", "items": [ { "additionalDescription": "example", "adjustments": { "discounts": [ { "amount": "example", "kind": "fixed_amount" } ], "surcharges": [ { "amount": "example", "kind": "fixed_amount" } ] }, "description": "example", "id": "example", "itemCodes": [ { "code": "example", "typeCode": "example" } ], "kind": "good", "legalTip": true, "quantity": "example", "tax": { "included": true, "kind": "itbis_18" }, "unit": "barrel", "unitPrice": "example" } ], "numbering": { "eNcf": "example", "sequenceExpiresOn": "example" }, "paymentTerms": { "allocations": [ { "amount": "example", "method": "cash" } ], "paymentAccount": { "accountNumber": "example", "bankName": "example" }, "type": "immediate" }, "pdfLayout": "a4", "referenceInformation": { "attribution": { "fiscalOperationId": "example", "kind": "internal_operation" }, "fiscalNumber": "example", "issuedOn": "2026-04-15", "modificationCode": "4" }, "source": { "id": "example", "version": "example" }, "type": "E31" }'
Media typeapplication/json
object
buyer
required
object
legalName
required
string
>= 1 characters <= 150 characters /^[^\p{White_Space}](?:[\s\S]*[^\p{White_Space}])?$/
taxId
required
string
/^[0-9]{9}([0-9]{2})?$/
address
null
deliveryPhone
null
email
null
currency
required
string
Allowed values: DOP BRL CAD CHF CHY XDR DKK EUR GBP JPY NOK SCP SEK USD VEF HTG MXN COP
invoiceReference
required

The only field a source-system reference travels in, bounded at 128 characters.

string
>= 1 characters <= 128 characters /^[^\p{White_Space}](?:[\s\S]*[^\p{White_Space}])?$/
items
required
Array<object>
>= 1 items <= 1000 items
object
description
required
string
>= 1 characters <= 80 characters /^[^\p{White_Space}](?:[\s\S]*[^\p{White_Space}])?$/
kind
required

Whether a Source line describes a good or a service.

string
Allowed values: good service
quantity
required
string
/^(?=[0-9.]*[1-9])[0-9]{1,16}(\.[0-9]{1,2})?$/
tax
required
discriminator: kind
object
included
required
boolean
kind
required
string
Allowed values: itbis_18
unit
required

A DGII e-CF unit of measure: a readable lowercase name on the Source and Invoice wire, the official numeric catalog code in fiscal documents.

string
Allowed values: barrel bag jar bundle bottle box cigarette_pack centimetre cylinder set container day dozen bale gallon degree gram bulk hour crate kilogram kilowatt_hour pound litre lot metre square_metre cubic_metre million_btu minute package pair foot piece roll envelope second tank ton tube yard square_yard unit element thousand sack tin display drum ration quintal gross_register_tonnage square_foot passenger inch boat_berth_stay tray hectare millilitre milligram ounce troy_ounce
unitPrice
required
string
/^[0-9]{1,16}(\.[0-9]{1,4})?$/
additionalDescription
null
adjustments
null
id
null
itemCodes
null
legalTip
boolean | null
paymentTerms
required
discriminator: type
object
type
required
string
Allowed values: immediate
allocations
null
paymentAccount
object
accountNumber
null
bankName
null
type
required
string
Allowed values: E31
Optional fields
additionalInformation
null
exchangeRate
null
expectedTotals
null
incomeType
null
numbering
null
pdfLayout
null
referenceInformation
null
source
null

Default Response

Media typeapplication/json
Response fields and codes
discriminator: status
object
status
required
string
Allowed values: valid
totals
required
object
foreign
required
null
net
required
string
nonBillable
required
string
tax
required
string
total
required
string
request-id
required
string

Identifies this request. Quote it when you contact support.