list_agencies
Retrieve available travel agencies to associate with travel programs using the LumbreTravel MCP Server.
Instructions
Obtiene todas las agencias disponibles para asociar a un programa de viajes
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/handlers/tools.handler.ts:1227-1235 (handler)Handler logic for the 'list_agencies' tool: fetches agencies using ApiService and returns JSON-formatted response.case 'list_agencies': { const agencies = await this.apiService.getAgencies() return { content: [{ type: 'text', text: JSON.stringify(agencies, null, 2) }] } }
- Input schema definition for the 'list_agencies' tool (no parameters required).name: 'list_agencies', description: 'Obtiene todas las agencias disponibles para asociar a un programa de viajes', inputSchema: { type: 'object', properties: {} } },
- src/services/api.service.ts:356-363 (helper)ApiService method getAgencies() that performs the HTTP GET request to retrieve the list of agencies from the backend API.async getAgencies () { const headers = await this.getHeaders() const response = await fetch(`${API_CONFIG.baseUrl}/integrations/mcp/agencies`, { method: 'GET', headers }) return await this.handleResponse<any[]>(response) }
- src/index.ts:44-47 (registration)Registration of the CallToolRequestHandler which dispatches to ToolsHandler.callTool based on tool name, including 'list_agencies'.this.server.setRequestHandler( CallToolRequestSchema, async (request) => await this.toolsHandler.callTool(request.params.name, request.params.arguments, this.server) )
- src/index.ts:39-41 (registration)Registration of ListToolsRequestHandler which returns the list of available tools, including 'list_agencies'.ListToolsRequestSchema, async () => this.toolsHandler.listTools() )