getAllAddresses
Retrieve all address data for specified accounts in the Mews hospitality platform to manage customer information and support operations.
Instructions
Get all addresses associated with specified accounts
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| AccountIds | Yes | Array of account IDs to get addresses for |
Implementation Reference
- The main handler function that executes the tool logic: calls the Mews API endpoint '/api/connector/v1/addresses/getAll' with provided AccountIds and returns the result as formatted JSON.
async execute(config: MewsAuthConfig, args: unknown): Promise<ToolResult> { const result = await mewsRequest(config, '/api/connector/v1/addresses/getAll', args); return { content: [{ type: 'text', text: JSON.stringify(result, null, 2) }] }; } - Input schema defining the required 'AccountIds' array parameter for the tool.
inputSchema: { type: 'object', properties: { AccountIds: { type: 'array', items: { type: 'string' }, description: 'Array of account IDs to get addresses for' } }, required: ['AccountIds'] }, - src/tools/index.ts:89-89 (registration)Registers the getAllAddressesTool in the central allTools array, which is used to generate tool definitions for MCP server and populate the toolMap.
getAllAddressesTool, - src/tools/index.ts:4-4 (registration)Imports the getAllAddressesTool for inclusion in the tools registry.
import { getAllAddressesTool } from './accounts/getAllAddresses.js';