Skip to main content

🔽 Downstream - send to 🌐

Downstream API


The Downstream API is used to input data from your system to Dockflow.

Example request


Replace xxxxx with your API token for authorization.

curl -X POST \
-H "Authorization: xxxxx" \
-d '[{ "container_reference": "ABCD1234567", "tradeflow_reference": "PO1674684" }]' \
https://api.dockflow.com/downstream
note

For the reference requests below, the Authorization header placeholder will be omitted. However, make sure to include it.

Request payload


The request can contain one or multiple tradeflows, but should always be an array. A tradeflow contains a container reference and a tradeflow reference.

[
{

"tradeflow_reference": "PO4564268", // mandatory - the internal reference from your system

// At least one of these
// (
"container_reference": "ABCD1234567", // either container number
// AND/OR
"bill_of_lading_reference": "ANR00001010", // and/or B/L reference
// AND/OR
"booking_reference": "94512540", // and/or booking reference
// )

// Optional arguments
"port_of_loading": "BEANR", // optional
"port_of_discharge": "NLRTM", // optional
"estimated_time_of_departure": "2021-08-24T15:00:25+00:00", // optional
"explicit_departure_confirmation": false, // optional
"estimated_time_of_arrival": "2021-08-24T15:00:25+00:00", // optional
"explicit_arrival_confirmation": false, // optional
"vessel": "Maersk SOPHIE", // optional
"customer_name": "Fruit Maker EXIM International", // optional
"customer_reference": "PO_12345_CUST", // optional
"carrier_name": "Maersk", // optional
"lead_contact": "[email protected]", // optional
"incoterms": "FOB", // optional
"configuration": {
"enroll_insurance": true,
}, // optional configuration flags
"references": {
"house_bill_of_lading": "hbl_123456789", // optional house bill of lading reference
"delivery_location": "Factory yard 12345", // optional, string of the delivery location
"delivery_event_date": "2021-08-24T15:00:25+00:00" // optional, ISO-date of delivery
},
"events":[ // optional, array of events to import
{
"message": "container loaded on vessel", // mandatory, name of the event- preferably DSCA-compliant
"container_reference": "ABCD1234567", // optional, container number
"location_name": "BEANR" // optional, location of the vent
"event_date":"2021-08-24T15:00:25+00:00", // optional, ISO-date of the event
"actual": true // optional, whether the event is actual or estimated - default is false
}
]
},
{
// Example of correct minimum message
"container_reference": "MNOP7654321",
"tradeflow_reference": "XYZ12341223AB2"
},
{
// Other example of correct minimum message
"bill_of_lading_reference": "ANR00001010",
"tradeflow_reference": "XYZ12341223AB2"
}
]
  • Tradeflow_reference refers to the internal name for this shipment, usually set to the client's PO-number, or B/L number. It can be any arbitrary string, by which containers are grouped for business sense. Tradeflow specific alerts will be grouped by tradeflow
  • Two dumps can have the same tradeflow_reference. In this case the two containers will be grouped in the same tradeflow

Single tradeflow with multiple containers example

[
{
"container_reference": "ABCD1234567",
"tradeflow_reference": "PO1674684"
},
{
"container_reference": "XYZZ7654321",
"tradeflow_reference": "PO1674684"
}
]

Set the tradeflow_reference equal to the container_reference to have each container in a separate tradeflow or file

Success Response


Condition: Data provided is valid and User is Authenticated.

Code: 202 Accepted

Custom payloads


If you are importing a custom payload, please post to https://api.dockflow.com/downstream/scheme/xxxxx, replacing xxxxx with your integration scheme.