---
title: "Look up a patient's appointments"
description: "Find a patient by their exact documentNumber (and documentType, such as CC or TI, when known) and list their appointments, newest first, each with id, start, status and agendas; upcoming ones also carry guidance (patientInstructions, arrivalOrder, who attends and the site's address). Use it before cancelling or rescheduling; found=false means no patient has that document. When several patients share the number under different types, patients lists them and appointments is empty: ask which one and call again with documentType.\n\n- **Scopes:** any one of `agenda:bookings:read`, `agenda:bookings:write`\n- **Credentials:** an API key, a client-credentials token or a person's access token\n- **Effect:** read-only; safe to retry\n- **Limits:** request body up to 256 KB, response up to 8 MB\n- **CLI:** `arbol agenda bookings lookup` · **MCP tool:** `agenda_bookings_lookup`"
---

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

Path: Agenda API › Bookings

`POST /v1/agenda/bookings/lookup`

Find a patient by their exact documentNumber (and documentType, such as CC or TI, when known) and list their appointments, newest first, each with id, start, status and agendas; upcoming ones also carry guidance (patientInstructions, arrivalOrder, who attends and the site's address). Use it before cancelling or rescheduling; found=false means no patient has that document. When several patients share the number under different types, patients lists them and appointments is empty: ask which one and call again with documentType.

- **Scopes:** any one of `agenda:bookings:read`, `agenda:bookings:write`
- **Credentials:** an API key, a client-credentials token or a person's access token
- **Effect:** read-only; safe to retry
- **Limits:** request body up to 256 KB, response up to 8 MB
- **CLI:** `arbol agenda bookings lookup` · **MCP tool:** `agenda_bookings_lookup`

## Authentication

Requires one of the following:

- `arbolHuman`, oauth2, scopes: `agenda:bookings:read`
- `arbolHuman`, oauth2, scopes: `agenda:bookings:write`
- `arbolMachine`, oauth2, scopes: `agenda:bookings:read`
- `arbolMachine`, oauth2, scopes: `agenda:bookings:write`
- `arbolApiKey`, http, header `Authorization`

## Request body

_Required._

- `documentNumber` (`agenda.bookings.lookup.documentNumber`; string, optional) — Exact patient document number; normalized for matching, with documentType needed when multiple types share the number.
- `documentType` (`agenda.bookings.lookup.documentType`; string, optional) — Document-type code from the organization’s configured active types. Input is trimmed and uppercased.
- `channel` (`agenda.bookings.lookup.channel`; string, optional) — The conversation's channel, set by the platform. It changes nothing in Agenda; omit it.
  - one of `"voice"`, `"whatsapp"`, `"web"`
- `connectionId` (`agenda.bookings.lookup.connectionId`; string, optional) — The platform's id for the organization's Agenda, set by the platform. An organization has one Agenda, so it selects nothing; omit it.
  - minLength 1; maxLength 128; pattern `^[\w-]+$`
- `document` (`agenda.bookings.lookup.document`; string, optional, deprecated) — Deprecated: use `documentNumber`. Answered until 2027-01-28.

## Example request

```json
{
  "documentNumber": "string",
  "documentType": "string",
  "channel": "voice",
  "connectionId": "string",
  "document": "string"
}
```

## Code samples

### cURL

```bash
curl https://api.getarbol.com/v1/agenda/bookings/lookup \
  --request POST \
  --header "Authorization: Bearer $ARBOL_API_KEY" \
  --header "Content-Type: application/json" \
  --data '{}'
```

### TypeScript

```typescript
import { createClient } from "@arbol-ai/sdk";

const arbol = createClient({
  baseUrl: "https://api.getarbol.com",
  token: process.env.ARBOL_API_KEY!,
});

const { data } = await arbol.agenda.bookings.lookup();
```

### Rust

```rust
use arbol_sdk::{types, Client, Credential};

let arbol = Client::new(Credential::ApiKey(std::env::var("ARBOL_API_KEY")?))?;

let data = arbol
    .agenda()
    .bookings()
    .lookup(&types::AgendaBookingsLookupInput::default())
    .await?;
```

### CLI

```bash
arbol agenda bookings lookup
```

### MCP

```json
{
  "name": "agenda_bookings_lookup",
  "arguments": {}
}
```

## Responses

### 200

Successful operation.

#### Example

```json
{
  "success": true,
  "data": {
    "appointments": [
      {
        "endsAt": "string",
        "guidance": {
          "arrivalOrder": true,
          "attendedBy": [
            "string"
          ],
          "location": {
            "address": "string",
            "city": "string",
            "name": "string"
          },
          "patientInstructions": "string",
          "serviceName": "string"
        },
        "id": "string",
        "offeringId": "string",
        "resourceIds": [
          "string"
        ],
        "startsAt": "string",
        "status": "tentative",
        "version": 0
      }
    ],
    "found": true,
    "patient": {
      "addressLine": "string",
      "alert": "string",
      "archivedAt": "string",
      "birthDate": "string",
      "city": "string",
      "createdAt": "string",
      "document": "string",
      "documentNumber": "string",
      "documentType": "string",
      "email": "string",
      "entity": "string",
      "fields": {},
      "gender": "male",
      "id": "string",
      "name": "string",
      "object": "scheduling.patient",
      "phone": "string",
      "updatedAt": "string",
      "version": 0,
      "cancelled": 0,
      "lastAt": "string",
      "nextAt": "string",
      "noShow": 0,
      "total": 0
    },
    "patients": [
      {
        "document": "string",
        "documentNumber": "string",
        "documentType": "string",
        "id": "string",
        "name": "string"
      }
    ]
  },
  "error": null,
  "metadata": {
    "requestId": "string"
  }
}
```

- `success` (`agenda.bookings.lookup.response.200.success`; boolean, required)
- `data` (`agenda.bookings.lookup.response.200.data`; object, required)
  - `appointments` (`agenda.bookings.lookup.response.200.data.appointments`; array<object>, required) — Appointments for the uniquely identified patient, newest first; empty when the document is absent or ambiguous.
    - `endsAt` (`agenda.bookings.lookup.response.200.data.appointments.endsAt`; string, required) — Appointment end as an ISO instant.
    - `guidance` (`agenda.bookings.lookup.response.200.data.appointments.guidance`; any of, required) — Current arrival guidance for upcoming appointments; null for past appointments or absent projection.
      - any of: `AgendaAppointmentGuidance`, `null`
    - `id` (`agenda.bookings.lookup.response.200.data.appointments.id`; string, required) — Appointment identifier used to read, cancel or reschedule the selected booking.
    - `offeringId` (`agenda.bookings.lookup.response.200.data.appointments.offeringId`; string | null, required) — Offering recorded on the appointment; null when the appointment has no linked offering.
      - pattern `^off_[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$`
    - `resourceIds` (`agenda.bookings.lookup.response.200.data.appointments.resourceIds`; array<string>, required) — Agenda identifiers allocated to this appointment.
    - `startsAt` (`agenda.bookings.lookup.response.200.data.appointments.startsAt`; string, required) — Appointment start as an ISO instant.
    - `status` (`agenda.bookings.lookup.response.200.data.appointments.status`; string, required) — Current appointment lifecycle state; cancelled and completed appointments cannot regain capacity through a status change.
      - one of `"tentative"`, `"scheduled"`, `"confirmed"`, `"checked_in"`, `"completed"`, `"cancelled"`, `"no_show"`, `"unknown"`
    - `version` (`agenda.bookings.lookup.response.200.data.appointments.version`; number, required) — Current appointment version used by guarded cancellation and rescheduling.
  - `found` (`agenda.bookings.lookup.response.200.data.found`; boolean, required) — Whether an exact document match exists; a true value may still require document-type disambiguation.
  - `patient` (`agenda.bookings.lookup.response.200.data.patient`; object, optional) — Current patient record and appointment summary within the verified organization.
    - `addressLine` (`agenda.bookings.lookup.response.200.data.patient.addressLine`; string | null, required) — Patient street address as recorded by staff; null when unknown.
    - `alert` (`agenda.bookings.lookup.response.200.data.patient.alert`; string | null, required) — Staff-visible patient care warning; null when none is recorded.
    - `archivedAt` (`agenda.bookings.lookup.response.200.data.patient.archivedAt`; string | null, required) — ISO instant when the record was archived; null while active. Archived records remain readable by id.
    - `birthDate` (`agenda.bookings.lookup.response.200.data.patient.birthDate`; string | null, required) — Patient date of birth as YYYY-MM-DD; null when unknown.
    - `city` (`agenda.bookings.lookup.response.200.data.patient.city`; string | null, required) — Patient municipality as written by staff, not a geographic code; null when unknown.
    - `createdAt` (`agenda.bookings.lookup.response.200.data.patient.createdAt`; string, required) — ISO instant when the patient record was created.
    - `document` (`agenda.bookings.lookup.response.200.data.patient.document`; string | null, required, deprecated) — Deprecated: use `documentNumber`. Answered until 2027-01-28.
    - `documentNumber` (`agenda.bookings.lookup.response.200.data.patient.documentNumber`; string | null, required) — Normalized patient document number; null when no document is recorded. Identity combines its type and number.
    - `documentType` (`agenda.bookings.lookup.response.200.data.patient.documentType`; string | null, required) — Organization-configured document type code. A number without a supplied type uses the configured first type; no number means no stored type.
    - `email` (`agenda.bookings.lookup.response.200.data.patient.email`; string | null, required) — Patient email address for enabled appointment notices; null when unknown.
    - `entity` (`agenda.bookings.lookup.response.200.data.patient.entity`; string | null, required) — Patient payer or insurer as named by the clinic; null when unknown. It is unrelated to the authenticated organization.
    - `fields` (`agenda.bookings.lookup.response.200.data.patient.fields`; object, required) — Custom patient values keyed by the organization's configured field keys; values retain their declared string, number or boolean type.
    - `gender` (`agenda.bookings.lookup.response.200.data.patient.gender`; string | null, required) — FHIR administrative gender recorded for registration; null when unknown.
      - one of `"male"`, `"female"`, `"other"`, `"unknown"`, `null`
    - `id` (`agenda.bookings.lookup.response.200.data.patient.id`; string, required) — Identifier of this patient record within the verified organization.
    - `name` (`agenda.bookings.lookup.response.200.data.patient.name`; string, required) — Patient display name with surrounding whitespace removed.
    - `object` (`agenda.bookings.lookup.response.200.data.patient.object`; string, required) — Discriminator identifying the scheduling.patient response shape.
    - `phone` (`agenda.bookings.lookup.response.200.data.patient.phone`; string | null, required) — Patient contact phone, preserving its entered formatting; null when unknown.
    - `updatedAt` (`agenda.bookings.lookup.response.200.data.patient.updatedAt`; string, required) — ISO instant of the latest patient record change.
    - `version` (`agenda.bookings.lookup.response.200.data.patient.version`; number, required) — Current patient record version; send it as expectedVersion for a compare-and-set edit.
    - `cancelled` (`agenda.bookings.lookup.response.200.data.patient.cancelled`; number, required) — Number of this patient's nondeleted appointments currently cancelled.
    - `lastAt` (`agenda.bookings.lookup.response.200.data.patient.lastAt`; string | null, required) — Latest past appointment start as an ISO instant, excluding cancelled appointments; null when none exists.
    - `nextAt` (`agenda.bookings.lookup.response.200.data.patient.nextAt`; string | null, required) — Earliest upcoming open appointment start as an ISO instant; null when none exists.
    - `noShow` (`agenda.bookings.lookup.response.200.data.patient.noShow`; number, required) — Number of this patient's nondeleted appointments currently marked as no-show.
    - `total` (`agenda.bookings.lookup.response.200.data.patient.total`; number, required) — Number of this patient's nondeleted appointments across all statuses.
  - `patients` (`agenda.bookings.lookup.response.200.data.patients`; array<object>, optional) — Candidate patients when an exact document number matches multiple document types; omitted after unique identification.
    - `document` (`agenda.bookings.lookup.response.200.data.patients.document`; string | null, required, deprecated) — Deprecated: use `documentNumber`. Answered until 2027-01-28.
    - `documentNumber` (`agenda.bookings.lookup.response.200.data.patients.documentNumber`; string | null, required) — Matched patient’s normalized document number; null when absent from the record.
    - `documentType` (`agenda.bookings.lookup.response.200.data.patients.documentType`; string | null, required) — Matched patient’s organization document-type code; use it to resolve a shared document number.
    - `id` (`agenda.bookings.lookup.response.200.data.patients.id`; string, required) — Patient record identifier belonging to the verified organization.
    - `name` (`agenda.bookings.lookup.response.200.data.patients.name`; string, required) — Patient display name for asking which matching document type applies.
- `error` (`agenda.bookings.lookup.response.200.error`; null, required)
- `metadata` (`agenda.bookings.lookup.response.200.metadata`; object, required)
  - `requestId` (`agenda.bookings.lookup.response.200.metadata.requestId`; string, required) — Request correlation identifier, also sent as X-Request-Id.

### 400

- `INVALID_INPUT`: The request does not match the published schema.
- `INVALID_APPOINTMENT_INTAKE`: Correct the indicated patient or intake fields before booking.
- `INVALID_PATIENT_FIELDS`: Correct the indicated patient fields before saving.
- `DURATION_CHANGE_OFF`: This service does not allow changing appointment duration.
- `DURATION_NOT_ALLOWED`: Select a duration allowed by this service.
- `STUDY_LENGTH_NOT_OFFERED`: Select one of the study lengths this agenda offers.
- `INVALID_FILE_KIND`: Select a supported attachment kind.
- `INVALID_FILE_NAME`: Provide a valid attachment filename.
- `INVALID_ID_TOKEN`: Provide a valid identity token.
- `INVALID_JSON`: Send a valid JSON document.
- `INVALID_WINDOW`: Provide a positive time window within the supported range.
- `UNEXPECTED_QUERY_PARAMETERS`: Remove query parameters not declared by this operation.
- `INVALID_BODY`: The request body could not be read. Send valid uncompressed JSON.

#### Example

```json
{
  "error": {
    "code": "INVALID_INPUT"
  }
}
```

- `error` (`agenda.bookings.lookup.response.400.error`; object, required)
  - any of: `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`

### 401

`UNAUTHORIZED`: A valid access token is required.

#### Example

```json
{
  "error": {
    "code": "UNAUTHORIZED"
  }
}
```

- `error` (`agenda.bookings.lookup.response.401.error`; object, required)
  - any of: `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`

### 403

- `FORBIDDEN`: The token does not authorize this operation.
- `ID_TOKEN_MISMATCH`: The identity token does not match the authenticated user.
- `NOT_FILE_UPLOADER`: Only the uploader may delete this attachment.
- `NOT_NOTE_AUTHOR`: Only the author may edit or delete this note.
- `ORIGIN_NOT_ALLOWED`: This request origin is not allowed.

#### Example

```json
{
  "error": {
    "code": "FORBIDDEN"
  }
}
```

- `error` (`agenda.bookings.lookup.response.403.error`; object, required)
  - any of: `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`

### 404

`NOT_FOUND`: The requested resource does not exist.

#### Example

```json
{
  "error": {
    "code": "NOT_FOUND"
  }
}
```

- `error` (`agenda.bookings.lookup.response.404.error`; object, required)
  - any of: `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`

### 405

`HTTP_METHOD_NOT_ALLOWED`: The HTTP method is not supported for this resource.

#### Example

```json
{
  "error": {
    "code": "HTTP_METHOD_NOT_ALLOWED"
  }
}
```

- `error` (`agenda.bookings.lookup.response.405.error`; object, required)
  - any of: `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`

### 409

- `PAYER_STAFF_ONLY`: This payer requires booking by the organization team. Add the patient to the waitlist for review.
- `APPOINTMENT_NOT_REMINDABLE`: Only an open future appointment with a patient email can receive a reminder.
- `APPOINTMENT_WITHOUT_PATIENT`: Link a patient to this appointment before performing this action.
- `ARBOL_CATALOG_TOO_LARGE`: The integration catalog exceeds the supported size. Narrow the catalog before retrying.
- `ARBOL_CONFIGURATION_REQUIRED`: Configure the organization integration before using it.
- `NOTIFICATIONS_NOT_SET_UP`: Patient emails need the notifications module turned on.
- `SAME_OFFERING`: An agenda cannot take its own appointments.
- `SAME_SERVICE`: A service cannot be merged into itself.
- `INVALID_HOLD_PAYLOAD`: The held slot is malformed.
- `HOLD_NOT_ACTIVE`: The hold is no longer active.
- `APPOINTMENT_CLOSED`: A cancelled appointment cannot be edited.
- `APPOINTMENT_VERSION_MISMATCH`: The appointment changed after it was loaded.
- `APPOINTMENT_NOT_MOVABLE`: A closed appointment cannot be moved.
- `SERVICE_CHANGED`: The new slot belongs to another service.
- `SCHEDULE_CHANGED`: The selected time no longer matches the current schedule.
- `INVALID_AVAILABILITY_WINDOW`: Availability windows must be positive and at most 31 days.
- `SERVICE_CAPACITY_EXCEEDED`: This service already has as many appointments as it can run at once at that time.
- `RESOURCE_CAPACITY_EXCEEDED`: The selected time is no longer available.
- `OVERBOOK_OUT_OF_RANGE`: An overbooked appointment must start between yesterday and the booking horizon.
- `OVERBOOK_UNAVAILABLE`: No active agenda can take this appointment.
- `STUDY_OVERBOOKING_NOT_ALLOWED`: This study has an explicit capacity limit and requires an available ordinary slot.
- `INVALID_SLOT_TOKEN`: Request a fresh available slot before booking.
- `BIRTH_DATE_REQUIRED`: This service has an age rule: the patient's date of birth is required.
- `AGE_NOT_ELIGIBLE`: The patient's age on that day is outside this service's age rule.
- `INTAKE_SETTINGS_VERSION_MISMATCH`: Intake settings changed; reload before saving.
- `PAYER_NAME_TAKEN`: Another payer already has that name.
- `PAYER_VERSION_MISMATCH`: The payer changed; reload before saving.
- `LOCATION_VERSION_MISMATCH`: The site changed after it was loaded.
- `PROFILE_VERSION_MISMATCH`: The profile changed after it was loaded.
- `PROVIDER_DISABLED`: Enable the provider integration before using it.
- `BINDING_VERSION_MISMATCH`: Connection changed or is synchronizing; refresh and retry.
- `RESOURCE_VERSION_MISMATCH`: The resource changed after it was loaded.
- `SCHEDULE_RULE_AGENDA_MISMATCH`: The schedule rule belongs to another agenda.
- `SCHEDULE_RULE_EXPECTED_VERSION_REQUIRED`: Expected version is required for an update.
- `SCHEDULE_RULE_VERSION_MISMATCH`: The schedule rule changed after it was loaded.
- `SCHEDULE_RULES_CHANGED`: The schedule changed after it was loaded.
- `SERVICE_VERSION_MISMATCH`: The service changed after it was loaded.
- `OFFERING_VERSION_MISMATCH`: The offering changed after it was loaded.
- `SAME_RESOURCE`: An agenda cannot take its own appointments.
- `TARGET_INACTIVE`: An archived agenda takes no appointments.
- `SLOT_REQUIRED`: A hold or slot token is required.
- `ARBOL_SETTINGS_VERSION_MISMATCH`: Arbol settings changed.
- `NOTIFICATION_SETTINGS_VERSION_MISMATCH`: Notification settings changed; reload before saving.
- `ORGANIZATION_VERSION_MISMATCH`: The organization changed; reload before saving.
- `PATIENT_DOCUMENT_TAKEN`: Another patient has that document.
- `PATIENT_VERSION_MISMATCH`: The patient changed after it was loaded.
- `DAILY_REPORT_TOO_LARGE`: Daily report exceeds the supported size; no partial report was generated.
- `REPORT_SETTINGS_VERSION_MISMATCH`: Report settings changed; reload before saving.
- `REPORT_NOTIFICATIONS_DISABLED`: Enable the notifications module before sending a daily agenda.
- `REPORT_RECIPIENTS_REQUIRED`: No eligible organization owner or additional delivery address is available for this agenda.
- `WAITLIST_ENTRY_VERSION_MISMATCH`: The waitlist entry changed; reload before saving.
- `REMOVAL_JOB_CONFLICT`: A removal is already active, or this idempotency key belongs to another decision.
- `FOLLOWUP_SETTINGS_VERSION_MISMATCH`: Follow-up email settings changed; reload before saving.
- `FOLLOWUP_DISABLED`: Turn this follow-up email on in the notification settings first.
- `FOLLOWUP_CONSENT_REQUIRED`: The patient has not consented to this follow-up email for their current address.
- `PATIENT_EMAIL_REQUIRED`: Record the patient's email before this action.
- `PATIENT_ARCHIVED`: Restore the patient before this action.
- `RECALL_ALREADY_ACTIVE`: The patient already has an active recall for this service.
- `RECALL_MONTH_PASSED`: The recall's month has already passed.
- `RECALL_VISIT_REQUIRED`: Enter the last visit: there is no attended appointment of this service for the patient.
- `RECALL_VISIT_IN_FUTURE`: The last visit must be a past date.
- `RECALL_VERSION_MISMATCH`: The recall changed after it was loaded.
- `SLOT_OFFER_NOT_ALLOWED`: Only an open waiting-list entry of a registered patient can receive a slot offer.
- `SLOT_OFFER_MISMATCH`: The slot belongs to another service or agenda than the entry asks for.
- `SLOT_OFFER_TOO_SOON`: The slot starts too soon to hold it for the patient; offer a later one.
- `SLOT_OFFER_ALREADY_OPEN`: This waiting-list entry already has an open slot offer.
- `SLOT_OFFER_CLOSED`: The slot offer is no longer open.

#### Example

```json
{
  "error": {
    "code": "PAYER_STAFF_ONLY"
  }
}
```

- `error` (`agenda.bookings.lookup.response.409.error`; object, required)
  - any of: `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`

### 413

`REQUEST_TOO_LARGE`: The request exceeds the allowed size.

#### Example

```json
{
  "error": {
    "code": "REQUEST_TOO_LARGE"
  }
}
```

- `error` (`agenda.bookings.lookup.response.413.error`; object, required)
  - any of: `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`

### 415

- `UNSUPPORTED_MEDIA_TYPE`: The request content type is not supported.
- `APPLICATION_JSON_REQUIRED`: Send the request as application/json.
- `FILE_CONTENT_MISMATCH`: The uploaded content does not match its declared file type.
- `UNSUPPORTED_CONTENT_ENCODING`: Send an uncompressed request body.
- `UNSUPPORTED_FILE_TYPE`: Select a supported attachment file type.

#### Example

```json
{
  "error": {
    "code": "UNSUPPORTED_MEDIA_TYPE"
  }
}
```

- `error` (`agenda.bookings.lookup.response.415.error`; object, required)
  - any of: `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`

### 426

`UPGRADE_REQUIRED`: Open the live channel with a WebSocket upgrade.

#### Example

```json
{
  "error": {
    "code": "UPGRADE_REQUIRED"
  }
}
```

- `error` (`agenda.bookings.lookup.response.426.error`; object, required)
  - any of: `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`

### 429

`RATE_LIMITED`: The request rate limit was exceeded. Try again later.

#### Example

```json
{
  "error": {
    "code": "RATE_LIMITED"
  }
}
```

- `error` (`agenda.bookings.lookup.response.429.error`; object, required)
  - any of: `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`

### 500

`INTERNAL_ERROR`: The service could not complete the operation.

#### Example

```json
{
  "error": {
    "code": "INTERNAL_ERROR"
  }
}
```

- `error` (`agenda.bookings.lookup.response.500.error`; object, required)
  - any of: `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`

### 502

`OUTCOME_UNKNOWN`: The operation may have been applied; check its result before repeating it.

#### Example

```json
{
  "error": {
    "code": "OUTCOME_UNKNOWN"
  }
}
```

- `error` (`agenda.bookings.lookup.response.502.error`; object, required)
  - any of: `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`

### 503

- `UPSTREAM_UNAVAILABLE`: The upstream service could not complete the request.
- `ARBOL_RESPONSE_TOO_LARGE`: The integration response exceeds the supported size.
- `ARBOL_UNAVAILABLE`: The integration service is temporarily unavailable. Retry later.
- `REMOVAL_WORKFLOW_UNAVAILABLE`: Durable removal is unavailable here; use the bounded manual removal operations.
- `ARBOL_REFUSED`: The integration service rejected this request. Review its configuration.

#### Example

```json
{
  "error": {
    "code": "UPSTREAM_UNAVAILABLE"
  }
}
```

- `error` (`agenda.bookings.lookup.response.503.error`; object, required)
  - any of: `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`

### 504

`UPSTREAM_TIMEOUT`: The upstream service did not respond before its deadline.

#### Example

```json
{
  "error": {
    "code": "UPSTREAM_TIMEOUT"
  }
}
```

- `error` (`agenda.bookings.lookup.response.504.error`; object, required)
  - any of: `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`, `object`


Source: https://docs.getarbol.com/api/agenda/bookings/lookup/index.md
