Call it
curl https://api.peume.com/v1/call/get-booking \
-H "Authorization: Bearer $PEUME_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"input": {
"run_id": "your run id"
}
}'const res = await fetch("https://api.peume.com/v1/call/get-booking", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.PEUME_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"input": {
"run_id": "your run id"
}
}),
});
const { output, cost_usd } = await res.json();import os, requests
res = requests.post(
"https://api.peume.com/v1/call/get-booking",
headers={"Authorization": f"Bearer {os.environ['PEUME_API_KEY']}"},
json={
"input": {
"run_id": "your run id"
}
},
)
print(res.json()["output"])Answer: {"id": "run_…", "status": "completed", "cost_usd": …, "output": {…}}. Long jobs answer 202 with a run id to read later. From an AI agent, connect the MCP server and ask for this by name: get-booking.
Parameters
run_idRequiredstringrunId of one of YOUR OWN completed /trips/save runs for the trip.
check_eligibilitybooleanWhether to check now, with the airline or supplier, if each item can be voided, refunded or exchanged (`items[].servicing`). For a flight this asks the airline and can add several seconds. Send `false` to read the booking and its stored `fare_conditions` without asking the airline: an active flight item then leaves its eligibility fields out of `items[].servicing`, and hotel, car and ground items still state theirs. Defaults to `true`; after a 180-day notice the default becomes `false`, so send `true` explicitly before cancelling or changing.
