Semantics
Read-only. Returns a list of slots, each with `start_at`, `end_at`, and `available: boolean`. Slots already in the past are not returned. The slots are aligned to the provider's working hours and service duration.
Invariants
- Pure read. No state change.
- Returns slots in chronological order.
- `available: true` slots are a snapshot — they may be taken before `create_booking` is called. Conflicts at booking time return `slot_taken` with current alternatives.
- If `service_id` is unknown to the provider, returns `error: "invalid_service"`.
When to use
Always before `create_booking`, unless the user has been shown explicit alternatives in a prior turn that still hold.
Input schema
{
"type": "object",
"required": [
"service_id",
"date"
],
"properties": {
"date": {
"type": "string",
"pattern": "^\\d{4}-\\d{2}-\\d{2}$",
"description": "ISO date (YYYY-MM-DD) in the service's local timezone."
},
"service_id": {
"type": "string"
},
"duration_minutes": {
"type": "number",
"minimum": 5,
"description": "Override the service's default duration if it supports multiple lengths."
}
},
"additionalProperties": false
}Output schema
{
"type": "object",
"required": [
"ok"
],
"properties": {
"ok": {
"type": "boolean"
},
"error": {
"enum": [
"invalid_service",
"invalid_date",
"no_slots"
],
"type": "string"
},
"slots": {
"type": "array",
"items": {
"type": "object",
"required": [
"start_at",
"end_at",
"available"
],
"properties": {
"end_at": {
"type": "string",
"format": "date-time"
},
"start_at": {
"type": "string",
"format": "date-time"
},
"available": {
"type": "boolean"
}
}
}
},
"service": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"name": {
"type": "string"
},
"duration_minutes": {
"type": "number"
}
}
},
"timezone": {
"type": "string"
}
}
}