Pay for a booking
complete_bookingPay for a booking (付款) whose status is awaiting_payment, with a payment credential the customer approved for the booking's amount and currency. payment.handler_id must come from the booking's payment_handlers ("stripe_payments"), and credential is {type: "stripe_payment_token", token: "spt_…"}: a Stripe shared payment token issued to the handler's business_profile. Charges the customer once (repeating the call does not charge twice). Returns the booking (confirmed, or pending if the business confirms it) and the payment result; if payment.status is requires_action, open payment.redirect_url for the customer and call again with the same credential.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"business_id": "<business_id>",
"booking_id": "<booking_id>",
"status_token": "<status_token>",
"payment": "<payment>"
},
"name": "complete_booking"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| payment | Yes | Payment credential for this booking | |
| booking_id | Yes | booking_id returned by request_booking | |
| business_id | Yes | business_id from search_businesses | |
| status_token | Yes | status_token returned once by request_booking | |
| idempotency_key | No | Optional key (8–64 letters, digits, _ . : -) that makes retries safe: the same key with the same parameters returns the original result |