oneapi
Sign in
Anaf v1 / e-Transport

Render PDF

A summary PDF of the notification, to keep with the shipment's paperwork. The response is the document, not JSON.

POST
https://oneapi.ro/api/anaf/v1/etransport/render

Request body

The request body is the whole document, sent raw (Content-Type: application/xml) — not an object with fields.

Notification

etransport.xml application/xml · 1,1 KB — sent as is, in the request body.

An intra-community supply

etransport-lic.xml application/xml · 1,0 KB — sent as is, in the request body.

An export

etransport-exp.xml application/xml · 1,0 KB — sent as is, in the request body.

Query parameters

This route accepts no query parameters.

How it behaves

  • The document can also be sent as a file: multipart/form-data with the fisier field (curl -F fisier=@document.xml), instead of the raw body. The file content becomes the request body, so the result is identical; options stay in the query string, and any other form field next to fisier returns 422 camp_necunoscut.
  • Takes the XML of a declaration and returns a readable summary PDF, with the goods, partner, transport, route and documents — the codes translated into names. Local (dompdf), in-memory.
  • The document is informative; it does not replace filing in SPV and carries no UIT code (that one is obtained on filing).
  • Zero retention: the XML received is not written and not logged.

What it is for

  • A printable summary for the driver / transport file.

Response structure

FieldTypeDescription

Response examples

body: @etransport.xml

POSThttps://oneapi.ro/api/anaf/v1/etransport/render
The response is a binary document, not JSON: application/pdf, 31,6 KB in this example.

Download the document this example returns

Error codes

CodeSlugWhen it occurs
401neautentificatToken missing, invalid, expired or revoked.
403feature_indisponibilThe current plan does not include the feature the route depends on.
422xml_invalidInvalid XML — it cannot be rendered.
429cota_depasitaThe plan's monthly quota has been exceeded (see Retry-After).

Errors in the Anaf module use the same envelope as the rest of the platform, with two extra fields: {eroare: {cod, mesaj, camp, request_id}}. eroare.cod is stable and is what you branch on; on validation (422) the code is case-specific: xml_invalid, xml_nu_e_factura, unitate_necunoscuta, luna_invalida and so on. camp points at the offending field when one can be identified.

{
    "eroare": {
        "cod": "xml_invalid",
        "mesaj": "Invalid XML — it cannot be rendered.",
        "camp": null,
        "request_id": "0199c1f0-6e1a-7c3d-9b2f-4a8e5d1c7b04"
    }
}