Skip to content
duxt
Upcoming version
You're browsing the documentation for an upcoming version. Its documentation and features are subject to change.

Book a consignment

post
/consignments

createConsignment

Books one consignment and tells you where it ended up.

Authorisation

  • Any one of these

    • apiKeyapiKey · X-Api-Key · Header

      A key from the account page.

  • Any one of these

    • bearerhttp · bearer

      A token obtained from the authorisation server.

Parameters

Header

  • X-Request-Idstring

    An identifier echoed back on every response.

Request body Required

The consignment to book.

objectNewConsignmentOne consignment, as the API sees it.
  • idstringRead-only
  • reference*Requiredstringmin length 1max length 120
  • status*RequiredstringConsignmentStatusbooked | loading | sailing | landed | cancelledWhere a consignment has got to.
  • createdAtstringRead-only
  • parentanyConsignmentRefers to itself; expanded above.
  • tagsarray<string>unique

    Each item

    string
  • metadataobject

    Any other property

    string
  • callbackUrlstringWhere to send the callback once the load is aboard.

The smallest body that works

json
{
  "reference": "HB-1042",
  "status": "booked"
}

With the paperwork attached

json
{
  "reference": "HB-1042",
  "status": "booked",
  "callbackUrl": "https://example.org/hooks/harbour",
  "tags": [
    "refrigerated"
  ]
}

Responses

201
Booked.

Headers

  • Location*Requiredstring

    Where the new consignment can be read.

application/json

objectConsignmentOne consignment, as the API sees it.
  • id*RequiredstringRead-only
  • reference*Requiredstringmin length 1max length 120
  • status*RequiredstringConsignmentStatusbooked | loading | sailing | landed | cancelledWhere a consignment has got to.
  • createdAtstringRead-only
  • parentanyConsignmentRefers to itself; expanded above.
  • tagsarray<string>unique

    Each item

    string
  • metadataobject

    Any other property

    string
json
{
  "id": "00000000-0000-4000-8000-000000000000",
  "reference": "string",
  "status": "booked",
  "createdAt": "2026-01-01T09:00:00Z",
  "parent": null,
  "tags": [
    "string"
  ],
  "metadata": {}
}
422
Something went wrong, described the same way every time.

application/problem+json

objectProblem
  • title*RequiredstringA short, human-readable summary.
  • status*Requiredintegermin 400max 599
  • detailstring | null
json
{
  "title": "string",
  "status": 400,
  "detail": "string"
}

Callbacks

consignmentLoaded

post
{$request.body#/callbackUrl}

Sent once the consignment has been loaded.

application/json

objectConsignmentOne consignment, as the API sees it.
  • idstringRead-only
  • reference*Requiredstringmin length 1max length 120
  • status*RequiredstringConsignmentStatusbooked | loading | sailing | landed | cancelledWhere a consignment has got to.
  • createdAtstringRead-only
  • parentanyConsignmentRefers to itself; expanded above.
  • tagsarray<string>unique

    Each item

    string
  • metadataobject

    Any other property

    string
json
{
  "reference": "string",
  "status": "booked",
  "parent": null,
  "tags": [
    "string"
  ],
  "metadata": {}
}

Expects in return

  • 204
    Acknowledged.

Send a request

Authentication

What you type here stays in this tab, is never stored, and is sent only to the server you chose.

Parameters

This body cannot be drawn as a form: edit it as JSON.

The request is sent by your browser, straight to that server.

curl 'https://api.example.org/v3/consignments?limit=20&cursor=string&status=%5B%0A++%22booked%22%0A%5D&session=string' \
  -H 'Authorization: Bearer demo-token' \
  -H 'X-Request-Id: 00000000-0000-4000-8000-000000000000'