> ## Documentation Index
> Fetch the complete documentation index at: https://docs.keebai.com/llms.txt
> Use this file to discover all available pages before exploring further.

# GET /v1/scheduling/booking/resource-bookings

> Search the resource bookings of a customer by phone, email or name: stays, blocks and older resource appointments.

Finds the resource bookings of a customer, newest first. It covers stays and block bookings, plus the resource appointments the business made before stays existed (`kind: "appointment"`). Cancelled ones are left out.

Use the `id` of an item with [GET](https://docs.keebai.com/dev/endpoints/scheduling-resource-booking-get.md), [PATCH](https://docs.keebai.com/dev/endpoints/scheduling-resource-booking-update.md) or [cancel](https://docs.keebai.com/dev/endpoints/scheduling-resource-booking-cancel.md): they accept both kinds.

## Endpoint

```
GET https://api.keebai.com/v1/scheduling/booking/resource-bookings
```

## Required scope

`scheduling:appointments:read`

## Query params

```json theme={"system"}
{
  "query": "+56987654321",
  "limit": 15
}
```

* `query`: required. A phone (with or without `+`), an email, or a name (each word matches the first or last name). 1 to 200 characters.
* `limit`: 1 to 15. Defaults to 15.

## Example request

```bash curl theme={"system"}
curl -G https://api.keebai.com/v1/scheduling/booking/resource-bookings \
  -H "Authorization: Bearer kbai_pk_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" \
  --data-urlencode "query=+56987654321"
```

## Response

### 200 OK

```json theme={"system"}
{
  "items": [
    {
      "id": "665f00000000000000000c01",
      "kind": "resource_booking",
      "booking_unit": "night",
      "resource": "Suite canina · Mediana",
      "resource_id": "665f00000000000000000a01",
      "branch": "Sucursal Centro",
      "branch_id": "665f00000000000000000b01",
      "label": "Ingreso jue 3 dic · Retiro sáb 5 dic · 2 noches",
      "start_time": "2026-12-03T11:00:00-03:00",
      "end_time": "2026-12-05T14:30:00-03:00",
      "time_zone": "America/Santiago",
      "check_in": "2026-12-03",
      "check_out": "2026-12-05",
      "nights": 2,
      "party_size": 1,
      "price": 40000,
      "currency": "CLP",
      "status": "booked",
      "payment_status": "partial",
      "payment_link": "https://pay.keebai.com/p/K7Q2M",
      "payment_hold_expires_at": null,
      "customer_phone": "56987654321"
    },
    {
      "id": "665f00000000000000000c02",
      "kind": "resource_booking",
      "booking_unit": "block",
      "resource": "Cancha 2",
      "resource_id": "665f00000000000000000a03",
      "branch": "Sucursal Norte",
      "branch_id": "665f00000000000000000b02",
      "label": "mar 1 dic · 19:00 a 20:30",
      "start_time": "2026-12-01T19:00:00-03:00",
      "end_time": "2026-12-01T20:30:00-03:00",
      "time_zone": "America/Santiago",
      "date": "2026-12-01",
      "duration_minutes": 90,
      "party_size": 4,
      "price": 24000,
      "currency": "CLP",
      "status": "booked",
      "payment_status": "pending",
      "payment_link": null,
      "payment_hold_expires_at": null,
      "customer_phone": "56987654321"
    },
    {
      "id": "665f00000000000000000c03",
      "kind": "appointment",
      "booking_unit": "night",
      "resource": "Suite canina · Mediana",
      "resource_id": "665f00000000000000000a01",
      "branch": "Sucursal Centro",
      "branch_id": "665f00000000000000000b01",
      "label": "mié 25 nov · 10:00 a 18:00",
      "start_time": "2026-11-25T10:00:00-03:00",
      "end_time": "2026-11-25T18:00:00-03:00",
      "time_zone": "America/Santiago",
      "party_size": 1,
      "price": 20000,
      "currency": "CLP",
      "status": "completed",
      "payment_status": "paid",
      "customer_phone": "56987654321"
    }
  ],
  "total": 3
}
```

* `start_time` and `end_time`: local date-times with the branch's offset.
* A stay carries `check_in`, `check_out` and `nights`. A block carries `date` and `duration_minutes`.
* An older resource appointment (`kind: "appointment"`) keeps its block label and carries no `check_in`, `check_out` or `nights`, even on a night resource. It took the night of its day.
* `customer_phone`: the phone stored on the booking. It is what you pass as `customer_phone` to read, change or cancel it.

### 400 Bad Request

`query` missing, empty or longer than 200 characters, or `limit` outside 1 to 15.

### 401 Unauthorized · 403 Forbidden

Same semantics as the rest of the public API.


## OpenAPI

````yaml GET /v1/scheduling/booking/resource-bookings
openapi: 3.0.0
info:
  title: Keebai Public API
  description: Superficie pública REST autenticada con Personal Access Tokens (PAT).
  version: 1.0.0
  contact: {}
servers:
  - url: https://api.keebai.com
    description: Production
security: []
tags: []
paths:
  /v1/scheduling/booking/resource-bookings:
    get:
      tags:
        - scheduling-resource-bookings
      summary: Search the resource bookings of a customer
      description: >-
        By phone, email or name. Includes legacy resource appointments (`kind:
        "appointment"`); leaves cancelled ones out.
      operationId: PublicResourceBookingsController_search
      parameters:
        - name: query
          required: true
          in: query
          description: Phone, email or name of the customer.
          schema:
            type: string
        - name: limit
          required: false
          in: query
          schema:
            minimum: 1
            maximum: 15
            default: 15
            type: number
      responses:
        '200':
          description: ''
      security:
        - PAT: []
components:
  securitySchemes:
    PAT:
      scheme: bearer
      bearerFormat: kbai_pk_<hex>
      type: http
      description: >-
        Personal Access Token con prefijo `kbai_pk_`. Generar desde el portal
        con permiso `developer.manage_tokens`.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.