Add invoice for transport document to an order

This method allows to add invoice scan with basic invoice data to an existing order. Method available for carriers and forwarders in carrier role. Invoice file must be uploaded first.

Url parameters and connection settings

  • URL: https://api.platform.trans.eu
  • Endpoint: /ext/orders-api/v1/orders/{order-Id}/invoice
  • Method: POST

Headers

  • Content-type: application/json
  • Accept: application/json
  • Authorization: Bearer {access_token}
  • Api-key: {unique_app_api-key}

Authorization and access

Authorization process is described here.  Each API request must also consist of unique Api-key obtained during application registration together with client_id and client_secret.

Structure of adding an invoice

Json Example Type Is required Description
invoice_data Object Yes Invoice data
invoice_number 13/12/1234 String Yes Invoice number
invoice_issuance_date 2021-12-13 String Yes Invoice issuance date
sales_date 2021-12-13 String Yes Sales date
net_value 1230 Float Yes Net value
currency Pln String Yes Currency
payment_due_date 2021-12-20 String Yes Payment term (date)
payment_offset_days 7 Int Yes Payment term (days)
gross_value 1512.90 Float No Gross value
tax_value 23 Int No Vat type (must be one of following – 0,5,8,23)
media_name Invoice String Yes Attachment name
media_id 72d71c93-355b-4119-9c5d-2460f368297b, String Yes Media id (returned after uploading a file)
visible_to_contractor True Boolean Yes Invoice visible to contractor
description Example description String Yes File description

Example Json

 {"invoice_data": {
        "invoice_number": "13/12/1234",
        "invoice_issuance_date": "2021-12-13",
        "sales_date": "2021-12-13",
        "net_value": 1230,
        "currency": "pln",
        "payment_due_date": "2021-12-20",
        "payment_offset_days": 7,
        "gross_value": 1512.90,
        "tax_value": 23
    },
    "media_name": "invoice",
    "media_id": "72d71c93-355b-4119-9c5d-2460f368297b",
    "visible_to_contractor": true,
    "description": "Example description"
}