Skip to main content
A trip item can carry required_attributes: the traveler details that must be collected before the item can be booked, such as passport fields on a flight whose carrier requires travel documents.

Where it appears

required_attributes is set once the trip is priced. It appears on the trip items returned by get_trip, checkout and the ancillaries response (GET /v1/trip/{trip_id}/ancillaries). The items returned by the trip action itself (POST /v1/trip) do not carry it, so read the trip again after a trip action.

Shape

A list with no names is omitted.

source: "provider"

The carrier states that these fields are needed to create the booking, and checkout enforces them. When per_passenger names a passport attribute or Nationality and a traveler lacks the matching field, checkout refuses with 422 MISSING_CUSTOMER_DETAILS before any payment object is issued: no checkout_url and no agent_spt_params. Nothing is charged. The three passport attributes are satisfied together. If per_passenger names any of them, every traveler needs all three of passport_number, passport_expiry and passport_country, because the booking sends a passport only when it is complete.

source: "derived"

The platform inferred the requirement from the itinerary. This happens on itineraries priced through a source that reports no document requirements, when the segments touch two or more countries. A low-cost-carrier source that reports nothing produces no required_attributes at all, not a derived one. Countries are compared by ISO country code, so a territory counts separately from its sovereign country, and a domestic route such as New York (JFK) to San Juan (SJU) produces this advisory. An airport the platform cannot place in a country never produces it on its own. A derived requirement is advisory only. It is not a compliance statement, and checkout never enforces it.

Attribute names and traveler fields

Checkout enforces these four names when a provider requirement lists them in per_passenger. Each is satisfied by a traveler field you send with upsert_travelers: Attribute names are an open set in the carrier’s own vocabulary, so other names, such as DateOfBirth (satisfied by date_of_birth), can appear. Checkout does not refuse on them.

What is left out

Five names are removed from per_passenger and per_passenger_conditional once every traveler on the trip satisfies them: DateOfBirth, the three passport names and Nationality. Other names stay listed whatever the travelers carry, and booking and booking_conditional are returned as stated. When the trip has no travelers, nothing is removed. When no names are left, the object is omitted. An absent required_attributes means no outstanding requirement is known. It is not a statement that no travel document is needed.

Examples

A flight whose carrier requires passports:
An international itinerary priced through a source that reports no document requirements:

When checkout refuses

Checking out the first trip above before the travelers carry passport details returns:
missing_fields lists the traveler fields to collect, and missing_by_domain groups them by item kind. Send upsert_travelers with those fields for every traveler, then check out again. See Errors & troubleshooting.