Tool description (what the LLM sees)
Tool description (what the LLM sees)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
trip_id | string | No | Existing trip ID. Omit to create a new trip. |
add_item | object | No | Add a flight or hotel item to the trip. |
add_item.trip_item_token | string | Yes | Token from flight_search results (offer__* format) or offer_id from hotel_search results (htl_* format). |
remove_item | object | No | Remove an existing item from the trip. Requires an existing trip_id — you cannot remove from a trip that has not been created yet. Can be combined with add_item in a single call to swap an item (remove runs first, then add). |
remove_item.item_id | string | Yes | ID of the trip item to remove. Matches the value returned in the trip response items[].item_id field. |
upsert_travelers | object | No | Set or update travelers and contact info on the trip. Optional per call (you can add_item while building the cart), but travelers and a contact must be present before booking. |
upsert_travelers.travelers | array<object> | Yes | List of travelers (replaces all). Required to complete a booking; the first traveler also supplies the booking contact name. |
upsert_travelers.contact | object | Yes | Booking contact (email + phone, both required). Required before the trip can be booked. |
select_ancillaries | object | No | Select ancillaries (bags, seats, meals) for a quoted trip item. Uses full-replacement semantics — send all desired selections. |
select_ancillaries.item_id | string | Yes | ID of the trip item to select ancillaries for. Get from trip response trip_items[].id |
select_ancillaries.selections | array<object> | Yes | Ancillary selections. Full replacement — send all desired selections each time. Get offer_ids from trip_item.available_ancillaries[].offer_id |
Examples
Create a new trip (add flight + set travelers in one call):frequent_flyer object so miles are credited on the booking. airline is the IATA code of the program issuer (e.g. LH for Lufthansa Miles & More) — not necessarily the operating carrier, since alliances credit miles on partner flights. Both airline and number are required when the object is present.
trip_id, the current item list, and totals. Use trip_id with book when you’re ready to check out.