Skip to main content
Glama

Get booking history and lifetime value for a guest

guests.bookings
Read-onlyIdempotent

Get booking history and lifetime value for a guest. Get guestId from guests.list or guests.search. Lifetime value is the sum of booked, staying, and completed booking totals. Use bookings.list to search bookings by date or booking code. This history does not include extras or fee details; use bookings.get to read them. Returns up to 100 bookings per page. Set page to bookings.page.next to continue. A next value of 0 marks the last page.

Input Schema

NameRequiredDescriptionDefault
pageNoPage number, starting at 1. Omit for the first page.
guestIdYesGuest record ID from guests.list, guests.search, or guests.create.

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedOutput schema / properties / result / properties / bookings / properties / items / items / properties / products
      Added value: +{
      +  "description": "Active extras and fees. Prices and totals use the booking currency.",
      +  "items": {
      +    "additionalProperties": false,
      +    "properties": {
      +      "bookingUnitId": {
      +        "type": "string"
      +      },
      +      "mode": {
      +        "enum": [
      +          "once",
      +          "per_night",
      +          "per_person",
      +          "per_person_per_night"
      +        ],
      +        "type": "string"
      +      },
      +      "name": {
      +        "type": "string"
      +      },
      +      "price": {
      +        "type": "string"
      +      },
      +      "quantity": {
      +        "type": "number"
      +      },
      +      "total": {
      +        "type": "string"
      +      },
      +      "type": {
      +        "enum": [
      +          "product",
      +          "fee"
      +        ],
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "name",
      +      "type",
      +      "mode",
      +      "price",
      +      "quantity",
      +      "total"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
  2. Changed2 schema fields changed
    • addedOutput schema / properties / result / properties / bookings / properties / items / items / properties / units / items / properties / stayStatus
      Added value: +{
      +  "enum": [
      +    "booked",
      +    "staying",
      +    "completed"
      +  ],
      +  "type": "string"
      +}
    • changedOutput schema / properties / result / properties / bookings / properties / items / items / properties / units / items / required
      Previous value: -[
      -  "unitId",
      -  "checkinAt",
      -  "checkoutAt",
      -  "guests"
      -]New value: +[
      +  "unitId",
      +  "stayStatus",
      +  "checkinAt",
      +  "checkoutAt",
      +  "guests"
      +]
  3. Changed1 schema field changed
    • changedInput schema / properties / guestId / description
      Previous value: -"Guest ID from guests.search or guests.create."New value: +"Guest record ID from guests.list, guests.search, or guests.create."
  4. Changed2 schema fields changed
    • addedInput schema / properties / guestId / description
      Added value: +"Guest ID from guests.search or guests.create."
    • addedInput schema / properties / page
      Added value: +{
      +  "default": 1,
      +  "description": "Page number, starting at 1. Omit for the first page.",
      +  "exclusiveMinimum": 0,
      +  "maximum": 9007199254740991,
      +  "type": "integer"
      +}
  5. Changed2 schema fields changed
    • addedOutput schema / properties / result / properties / bookings / properties / items / items / properties / units / items / properties / cancellationPolicy
      Added value: +{
      +  "additionalProperties": false,
      +  "properties": {
      +    "enabled": {
      +      "type": "boolean"
      +    },
      +    "noshow": {
      +      "additionalProperties": false,
      +      "properties": {
      +        "type": {
      +          "type": "string"
      +        },
      +        "value": {
      +          "type": "number"
      +        }
      +      },
      +      "required": [
      +        "type"
      +      ],
      +      "type": "object"
      +    },
      +    "presetId": {
      +      "type": "string"
      +    },
      +    "tiers": {
      +      "items": {
      +        "additionalProperties": false,
      +        "properties": {
      +          "minDays": {
      +            "type": "number"
      +          },
      +          "penalty": {
      +            "additionalProperties": false,
      +            "properties": {
      +              "type": {
      +                "type": "string"
      +              },
      +              "value": {
      +                "type": "number"
      +              }
      +            },
      +            "required": [
      +              "type"
      +            ],
      +            "type": "object"
      +          }
      +        },
      +        "required": [
      +          "minDays",
      +          "penalty"
      +        ],
      +        "type": "object"
      +      },
      +      "type": "array"
      +    }
      +  },
      +  "required": [
      +    "enabled",
      +    "tiers",
      +    "noshow"
      +  ],
      +  "type": "object"
      +}
    • addedOutput schema / properties / result / properties / bookings / properties / items / items / properties / units / items / properties / id
      Added value: +{
      +  "type": "string"
      +}
  6. First observed

TDQS

A4.4/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnly, idempotent, non-destructive and closed-world, so the safety profile is covered. The description still adds real behavioral value: it defines lifetime value as the sum of booked, staying and completed totals, and warns the history omits extras and fees. However, it does not describe ordering of the returned bookings or what happens for a guest with no bookings, so it is not fully transparent.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the purpose, and every sentence carries information with no filler. The three-sentence pagination block is slightly verbose and could be tightened, but nothing is wasted.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Output shape is covered by the output schema, and the description fills the remaining gaps an agent needs: ID provenance, page size, continuation token semantics, and the exclusion of extras/fees with a pointer to the tool that has them. Complete for a two-parameter paged read.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline would be 3, but the description goes beyond the schema by explaining pagination semantics: 100 bookings per page and 'set page to bookings.page.next, a next value of 0 marks the last page'. That is invocation-critical meaning the schema does not carry, and it also reinforces where guestId comes from.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Get booking history and lifetime value for a guest') and the title reinforces it. It also implicitly differentiates from bookings.list and bookings.get by naming each as the right tool for other tasks.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly routes the agent: guestId from guests.list or guests.search, use bookings.list for date/booking-code searches, and bookings.get for extras and fee details. Both the alternative and the condition that selects it are stated, so nothing is left to inference.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources