Factuarea APIDevelopers
Added

Transport control document (DeCA) and transport weight

New transport_documents resource with 17 endpoints to issue, modify, share and keep the Spanish digital control document for road freight, mandatory from 5 October 2026; 15 MCP tools, 10 transport_document.* events, 24 error codes and gross transport weight on products, variants, presentations and delivery notes.

From 5 October 2026 the administrative control document of Spanish public road freight transport must be digital. The public API now issues it: a PDF per version, served from a permanent public URL whose QR code travels with the driver, with the history the inspection needs. Everything is additive; no existing field changes meaning. See the Transport control document guide.

New transport_documents resource

OperationEndpoint
List, with cursor and the filters status, transport_date[gte|lte], company_role, carrier_tax_id, delivery_note_id and qGET /v1/transport_documents
Status catalogGET /v1/transport_documents/statuses
RetrieveGET /v1/transport_documents/{id}
Create a draft, optionally pre-filled from 1 to 50 delivery notesPOST /v1/transport_documents
Update or delete a draftPUT / DELETE /v1/transport_documents/{id}
Issue (irreversible)POST /v1/transport_documents/{id}/issue
Modify during the service, same URL and QR (irreversible)POST /v1/transport_documents/{id}/modify
Close and reopenPOST /v1/transport_documents/{id}/close, /reopen
Cancel or mark as superseded by the carrier's document (irreversible)POST /v1/transport_documents/{id}/cancel, /supersede
Email the copy to the carrier (irreversible)POST /v1/transport_documents/{id}/send
PDF of a version, QR code and issuance evidence (each entry with its actor_name, automatic closes as auto_closed, and the first 100 public downloads, with meta.downloads_total and meta.downloads_listed)GET /v1/transport_documents/{id}/pdf, /qr, /evidence
Proof of issuance in PDFGET /v1/transport_documents/{id}/issuance_proof

New scopes: transport_documents:read, transport_documents:write, transport_documents:delete and transport_documents:transition, also grantable through OAuth. The PDF of each version enforces pdfs:read; the proof of issuance, transport_documents:read, because it contains the issuance evidence. The transport_documents module requires delivery_notes.

MCP, events and errors

  • 15 MCP tools, one per operation except the QR code and the proof of issuance, which stay binary REST downloads. search_transport_documents takes the same q and sort as the REST list, and create_transport_document does not take id. See the tool catalog.
  • 10 events: transport_document.created, .updated, .issued, .modified, .closed (with close_mode manual or automatic), .reopened, .cancelled, .superseded, .email_sent and .email_failed. While a document is a draft, its parties follow changes to the linked contact and to your company data, and each refresh that changes something publishes .updated. See Events.
  • 24 error codes: the 22 of the new «Transport Documents» category, from transport_document_not_issuable (with error.details.missing) to transport_document_version_limit_reached, transport_document_pdf_too_large and transport_document_version_not_found (404 for a ?version=N the PDF does not have), plus invalid_gross_weight (also on the goods lines of a document) and gross_weight_not_allowed in Products. See the error catalog.

Limits and identifiers

  • A document holds at most 50 versions, the last one reserved for cancelling or superseding it; once it has 49, modify returns 422 transport_document_version_limit_reached.
  • Each version is a PDF of up to 5 MB (5,000,000 bytes). Issuing, modifying, cancelling and superseding return 422 transport_document_pdf_too_large without saving anything when the PDF would be larger.
  • The server generates the id of a document. shipments[].id is optional: on create, one already in use returns 422 on shipments.N.id; on update and modify, it only identifies a shipment of that document. A concurrent write that collides on an identifier returns 409 resource_conflict and can be retried. UUIDs are normalised to lower case.
  • On create, a shipment that omits origin takes your default loading place or your registered address; an explicit "origin": null leaves it without origin.
  • The public URL is limited per token and network prefix (60 per minute by default) and per token (600 per minute by default), never by IP alone; unknown tokens count per network prefix. The public PDF does not show who made each version.

Gross transport weight in the catalog and on delivery notes

  • Products, variants and fixed presentations accept gross_weight_kg on create and update and publish it on read: kg per base unit on products and variants and per commercial unit on presentations. Omitting it on update keeps the current value and null clears it. Services, mass base units (KGM, GRM) and variable_measure presentations reject it with gross_weight_not_allowed.
  • Delivery note lines freeze their weight when created or edited in draft and publish it as gross_weight_kg; the delivery note adds total_gross_weight_kg and lines_without_weight_count.
  • Series accept the new type transport_document (default code DC); its series is created on the first issue. GET /v1/series/stats counts it.

New endpoints17

EndpointDescription
GET/v1/transport_documentsList all transport documents
GET/v1/transport_documents/statusesList transport document statuses
GET/v1/transport_documents/{transport_document}Retrieve a transport document
POST/v1/transport_documentsCreate a transport document
PUT/v1/transport_documents/{transport_document}Update a draft transport document
DEL/v1/transport_documents/{transport_document}Delete a draft transport document
POST/v1/transport_documents/{transport_document}/issueIssue a transport document
POST/v1/transport_documents/{transport_document}/modifyModify an issued transport document
POST/v1/transport_documents/{transport_document}/closeClose a transport document
POST/v1/transport_documents/{transport_document}/reopenReopen a transport document
POST/v1/transport_documents/{transport_document}/cancelCancel a transport document
POST/v1/transport_documents/{transport_document}/supersedeMark a transport document as superseded
POST/v1/transport_documents/{transport_document}/sendSend a transport document by email
GET/v1/transport_documents/{transport_document}/pdfDownload transport document PDF
GET/v1/transport_documents/{transport_document}/qrDownload transport document QR code
GET/v1/transport_documents/{transport_document}/evidenceList transport document issuance evidence
GET/v1/transport_documents/{transport_document}/issuance_proofDownload transport document issuance proof

Updated endpoints21

EndpointDescription
POST/v1/productsCreate a product
PUT/v1/products/{product}Update a product
GET/v1/products/{product}Retrieve a product
GET/v1/productsList all products
POST/v1/products/{product}/variantsCreate a product variant
PUT/v1/products/{product}/variants/{variant}Update a product variant
GET/v1/products/{product}/variantsList product variants
POST/v1/products/{product}/presentationsCreate a product presentation
PUT/v1/products/{product}/presentations/{presentation}Update a product presentation
GET/v1/products/{product}/presentationsList product presentations
POST/v1/delivery_notesCreate a delivery note
PUT/v1/delivery_notes/{delivery_note}Update a delivery note
GET/v1/delivery_notes/{delivery_note}Retrieve a delivery note
GET/v1/delivery_notesList all delivery notes
POST/v1/seriesCreate a series
GET/v1/seriesList all series
GET/v1/series/statsGet series stats
POST/v1/webhook_endpointsCreate a webhook endpoint
PUT/v1/webhook_endpoints/{webhook_endpoint}Update a webhook endpoint
GET/v1/eventsList all events
POST/v1/account/api-keysCreate an API key

On this page

Need a hand?Contact support