A guest's booked trip, from the link they gave you
get_trip_summaryAfter the booking. Takes the link a guest made for their assistant on their trip page (or just the key on the end of it) and returns a read-only summary of that one trip: whether it is ready to travel, what needs doing, by what date and who it is waiting on, each booked line with what it came to, and the money — payments received, refunds completed and pending, what is retained, the damage deposit and what is owing. Read it again each time you are asked (freshness.staleAfterSeconds). A fact that is not known is "unknown" and an amount that cannot be stated is null: never read those as yes, no or 0. When money.state is not_reconciled, tell the guest not to pay again on the strength of this and to call the desk. It includes nobody's name or contact details and can change nothing. A link that is wrong, expired or turned off is refused; ask the guest for a new one.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| key | No | Or only the 43-character key on the end of that link. | |
| link | No | The link the guest gave you, whole: it looks like https://experiencebamfield.com/api/assistant/trip/KEY. Send this or key. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| trip | Yes | ||
| about | Yes | ||
| money | Yes | Read from the order's own payment record. Always present on this link. | |
| ready | Yes | ||
| booked | Yes | ||
| contact | Yes | ||
| finishes | Yes | Three separate things: ready to travel, the trip being over, and the money being settled. | |
| thisLink | Yes | ||
| freshness | Yes | The summary is the trip as recorded at checkedAt and is worked out again on every read. Read the link again before answering; do not answer from a copy older than staleAfterSeconds. | |
| notIncluded | Yes | ||
| needsAttention | Yes | Lines that need someone: a payment record to be checked first, then the guest's own, then the desk's, then what could not be verified, then what is waiting; within each, the earliest actBy first. Once the trip is over or cancelled, only money that still needs someone is listed (a payment record to check, a deposit not returned). |