Skip to main content

Common Use Cases

This page walks through typical integration workflows with the Partner API.

Simple booking workflow​

The most common workflow: find a trip, check availability, create a booking, and add a customer.

Step 1: Find the trip​

Query for the trip by its code to get the trip ID and available related products.

curl -X GET "https://{host}/v1/trips?tripCode=TTSN" \
-H "Authorization: Bearer {token}"

Step 2: Get departures​

Fetch available departures for the trip, filtering to future dates.

curl -X GET "https://{host}/v1/departures?tripCode=TTSN&dateRangeFrom=2026-01-01" \
-H "Authorization: Bearer {token}"

Step 3: Check room options and prices​

For a specific departure, retrieve the available room options with pricing.

curl -X GET "https://{host}/v1/departures/{departureId}/room-options" \
-H "Authorization: Bearer {token}"

The response includes:

  • Room type (Twin, Single, etc.)
  • Capacity
  • Price per currency
  • Availability status (AVAILABLE, ON_REQUEST, SOLD_OUT)

Step 4: Create a booking​

Create an empty booking container with your preferred currency and agent reference.

curl -X POST "https://{host}/v1/bookings" \
-H "Authorization: Bearer {token}" \
-H "Content-Type: application/json" \
-d '{
"currency": "AUD",
"agentReferenceNumber": "YOUR-REF-123"
}'

Step 5: Add the trip to the booking​

Attach the selected departure and room option to the booking.

curl -X POST "https://{host}/v1/bookings/{bookingId}/trips" \
-H "Authorization: Bearer {token}" \
-H "Content-Type: application/json" \
-d '{
"departureId": "159897TTSN260105",
"roomOptionId": "room-twin-01"
}'

Step 6: Add a customer​

Add passenger details to the booking.

curl -X POST "https://{host}/v1/bookings/{bookingId}/customers" \
-H "Authorization: Bearer {token}" \
-H "Content-Type: application/json" \
-d '{
"firstName": "Jane",
"lastName": "Smith",
"dateOfBirth": "1990-05-15",
"nationality": "AU",
"email": "jane.smith@example.com"
}'
What's next?

After creating a booking, you can:

  • Add optional extras like pre-trip accommodations or airport transfers
  • Query the booking status with GET /bookings/{bookingId}
  • Update customer details with PATCH /bookings/{bookingId}/customers/{customerId}