Examples
Travel Booking
Search, holds, approvals, and rollback for multi-part bookings.
Travel bookings are multi-part, time-sensitive, and expensive to get wrong. This example shows how a fictional travel product supports an agent booking a trip with a flight and a hotel.
Illustrative exampleThe task
"Book me a return flight from Lisbon to Berlin on 18 October, back on the 21st, and a hotel near Alexanderplatz. Keep it under €600 total."
The task spans two suppliers, involves holds that expire, and has a total budget across both.
Clarify before searching
"Berlin" is unambiguous, but many destinations are not. The search action returns a clarification when it needs one:
{
"status": "needs_clarification",
"field": "origin",
"options": [
{ "id": "LIS", "label": "Lisbon Humberto Delgado Airport (LIS)" }
],
"message": "Confirm the departure airport."
}Model the trip as a workflow
{
"id": "trip_4410",
"type": "trip_booking",
"budget": { "amount": 600, "currency": "EUR" },
"steps": [
{ "name": "flight", "status": "held", "holdExpiresAt": "2026-10-06T14:20:00Z", "price": { "amount": 231, "currency": "EUR" } },
{ "name": "hotel", "status": "held", "holdExpiresAt": "2026-10-06T14:35:00Z", "price": { "amount": 318, "currency": "EUR" } },
{ "name": "payment", "status": "approval_required", "approvalId": "apr_221" }
],
"total": { "amount": 549, "currency": "EUR" },
"next": { "action": "confirm_trip", "requires": ["approvalId"] }
}Holds are explicit, with expiry times, so the agent can tell the traveller how long they have to approve.
Roll back on failure
If payment fails after both holds succeed, the product releases the holds and reports it:
{
"status": "failed",
"error": { "code": "payment_declined", "retryable": false },
"rolledBack": [
{ "step": "hotel", "action": "release_hold", "status": "completed" },
{ "step": "flight", "action": "release_hold", "status": "completed" }
]
}Resume after interruption
If the agent's session ends while waiting for approval, a new session calls GET /trips/trip_4410/resume and learns that the fare changed by €17 during the pause. It re-confirms with the traveller instead of booking at a price they didn't approve. See Context Restoration.
Related
Last updated 2026-10-06. AX Framework documentation describes proposals unless a section is marked as an established standard.