Skip to main content
Glama
code-rabi

Mews MCP

by code-rabi

getAllReservations

Retrieve hotel reservations from Mews platform using filters like date range, customer IDs, reservation states, and pagination for efficient management.

Instructions

Get reservations with filters. Note: The time interval between StartUtc and EndUtc must not exceed 100 hours.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
ReservationIdsNoSpecific reservation IDs to retrieve
CustomerIdsNoFilter by customer IDs
StatesNoFilter by reservation states (Confirmed, Canceled, etc.)
StartUtcYesStart date for search (ISO 8601)
EndUtcYesEnd date for search (ISO 8601)
LimitationNoPagination settings

Implementation Reference

  • The execute function that implements the core logic of the getAllReservations tool by calling the Mews API endpoint '/api/connector/v1/reservations/getAll' with the provided arguments and returning the JSON-formatted result.
    async execute(config: MewsAuthConfig, args: unknown): Promise<ToolResult> {
      const result = await mewsRequest(config, '/api/connector/v1/reservations/getAll', args);
      return {
        content: [{
          type: 'text',
          text: JSON.stringify(result, null, 2)
        }]
      };
    }
  • The inputSchema defining the parameters accepted by the getAllReservations tool, including filters for reservation IDs, customers, states, date range, and pagination.
    inputSchema: {
      type: 'object',
      properties: {
        ReservationIds: { 
          type: 'array', 
          items: { type: 'string' },
          description: 'Specific reservation IDs to retrieve'
        },
        CustomerIds: { 
          type: 'array', 
          items: { type: 'string' },
          description: 'Filter by customer IDs'
        },
        States: { 
          type: 'array', 
          items: { type: 'string' },
          description: 'Filter by reservation states (Confirmed, Canceled, etc.)'
        },
        StartUtc: {
          type: 'string',
          description: 'Start date for search (ISO 8601)'
        },
        EndUtc: {
          type: 'string',
          description: 'End date for search (ISO 8601)'
        },
        Limitation: {
          type: 'object',
          properties: {
            Count: { type: 'number', description: 'Maximum number of reservations to return' },
            Cursor: { type: 'string', description: 'Pagination cursor for next page' }
          },
          description: 'Pagination settings'
        }
      },
      required: ['StartUtc', 'EndUtc']
    },
  • Import statement for the getAllReservationsTool.
    import { getAllReservationsTool } from './reservations/getAllReservations.js';
  • Inclusion of getAllReservationsTool in the allTools array, registering it for use in the MCP server.
    getAllReservationsTool,
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It mentions one important constraint: 'The time interval between StartUtc and EndUtc must not exceed 100 hours.' This is valuable behavioral information. However, it doesn't disclose other critical behaviors: whether this is a read-only operation, pagination behavior (though Limitation parameter hints at it), rate limits, authentication requirements, or what happens when filters return no results. For a tool with 6 parameters and no annotations, this is insufficient.

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?

The description is appropriately concise - just two sentences. The first sentence states the core purpose, and the second adds a critical constraint. There's no wasted language. However, it could be slightly more front-loaded by mentioning the constraint earlier or integrating it more seamlessly.

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

Completeness3/5

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

Given the tool's complexity (6 parameters, nested objects, no output schema, no annotations), the description is minimally adequate. It states the purpose and one critical constraint, but leaves many questions unanswered: return format, error conditions, pagination details, and how this differs from similar reservation tools. With no output schema and no annotations, the description should provide more context about what to expect from this operation.

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

Parameters3/5

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

Schema description coverage is 100%, so the schema already documents all parameters thoroughly. The description adds one important semantic constraint about the time interval between StartUtc and EndUtc parameters, which is valuable beyond the schema. However, it doesn't provide additional context about how filters combine (AND/OR logic), parameter dependencies, or default behaviors. With high schema coverage, baseline 3 is appropriate.

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

Purpose4/5

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

The description clearly states the tool's purpose: 'Get reservations with filters.' This specifies the verb ('Get') and resource ('reservations'), and mentions filtering capability. However, it doesn't differentiate from sibling tools like 'exportReservations' or 'getAllReservations' (which appears to be the same tool name but listed as sibling - this is confusing). The purpose is clear but sibling differentiation is missing.

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

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives. There are multiple reservation-related tools in the sibling list (addReservation, cancelReservations, exportReservations, updateReservations), but the description offers no comparison or context about when this specific filtering tool is appropriate versus other reservation operations.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/code-rabi/mews-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server