Retrieve the current order status and ticket resources.
Authentication and headers
| Header | Description |
|---|---|
Authorization | Bearer <secret_key>. Keep the secret on the server and never write it to client logs. |
X-Travelandz-Id | <public_key>:<profile_code>, where the persisted profile code has the form dp_<12 alphanumeric>. |
Content-Type | application/json for requests with a JSON body. |
Request
Path parameters: gdsprovider is currently 0; orderId comes from order creation.
Request Params Schema
gdsproviderCurrently
0orderIdOrder id returned by order creation.
Success response
Returns order with status, reference and itineraryItems[].tickets[]. Ticket types include pdf_ticket, check_in_resource and ticket_on_departure; ticket fields can be null.
Response Body Schema
orderordergdsproviderorderidorderstatusorderreferenceorderitineraryItemsorderitineraryItems[]itineraryIndexorderitineraryItems[]ticketsorderitineraryItems[]tickets[]typeorderitineraryItems[]tickets[]urlorderitineraryItems[]tickets[]referenceorderitineraryItems[]tickets[]descriptionErrors
400for validation or unknown fields.401or403for invalid API credentials.500 internal_communication_errororunknown_errorfor provider failures.order_not_foundwhen the order does not exist.
Usage notes
Ticket URLs can be provider resources. Treat nullable url, reference and description as expected.
cURL example
bash
curl --request GET \
--url "https://api.sandbox.travelandz.com/v1/trains/order/0/order_123" \
--header "Authorization: Bearer $TRAVELANDZ_SECRET_KEY" \
--header "X-Travelandz-Id: $TRAVELANDZ_PUBLIC_KEY:$TRAVELANDZ_PROFILE_CODE"