Przygotuj rezerwację
prepare_bookingPURPOSE: Step 1 of 2 of booking. Holds the chosen slot for 10 minutes and sends a 6-digit SMS code to the customer's Polish mobile. Returns confirmation_id and a summary to show verbatim. Does NOT create a booking. WHEN TO USE: Only after the customer explicitly said they want to book THIS slot, gave first and last name, street address with number and mobile phone, and accepted the terms. WHEN NOT TO USE: Not for price or date questions, not when the customer says "maybe" or only asks how much / when. Never guess or invent missing data - ask. REQUIRED: quote_id, slot_id (from check_availability), customer.name, customer.address, customer.phone, terms_accepted=true. Missing data -> error missing_required_fields with missing_fields[]. SIDE EFFECTS: one SMS to the phone + 10-minute slot hold. The identical call repeated returns the same confirmation_id, no new SMS. NEXT: ask the customer for the SMS code, then call create_booking.
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": {
"quote_id": "<quote_id>",
"slot_id": "<slot_id>",
"customer": "<customer>",
"terms_accepted": "<terms_accepted>"
},
"name": "prepare_booking"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| notes | No | Optional note for the cleaner (fabric type, stains, parking) | |
| slot_id | Yes | slot_id chosen by the customer from check_availability | |
| customer | Yes | ||
| quote_id | Yes | quote_id from calculate_quote | |
| session_id | No | Optional. session_id from the previous result, if you have it. The server also recovers the session from quote_id / slot_id / confirmation_id / customer_grant. | |
| invoice_data | No | Optional, only if the customer wants a company invoice | |
| terms_accepted | Yes | true only if the customer explicitly accepted the terms and consents. false -> the server returns the consent text to show. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| code | No | ||
| error | No | Stable machine-readable error id when success=false, e.g. missing_required_fields, unsupported_postcode, no_availability | |
| total | No | ||
| status | No | ||
| message | No | ||
| success | Yes | true = operation done / data returned; false = see error | |
| summary | No | ||
| currency | No | ||
| expires_at | No | ||
| session_id | No | ||
| code_sent_to | No | ||
| missing_fields | No | ||
| booking_created | No | ||
| confirmation_id | No |