get_leader_by_name
Search for travel guides by name to find specific leaders for your travel programs and activities using the LumbreTravel API.
Instructions
Buscar guías por su nombre.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Nombre del guía |
Implementation Reference
- src/handlers/tools.handler.ts:1583-1589 (handler)Handler logic for the 'get_leader_by_name' tool: extracts 'name' from args, calls apiService.getLeaderByName(name), and returns the result as JSON text content.case 'get_leader_by_name': { const { name } = args as { name: string } const leader = await this.apiService.getLeaderByName(name) return { content: [{ type: 'text', text: JSON.stringify(leader, null, 2) }] } }
- Input schema definition for the 'get_leader_by_name' tool, specifying a required 'name' string parameter.{ name: 'get_leader_by_name', description: 'Buscar guías por su nombre.', inputSchema: { type: 'object', properties: { name: { type: 'string', description: 'Nombre del guía' } }, required: ['name'] } },
- src/handlers/tools.handler.ts:1111-1113 (registration)The tool is registered in the listTools() method which returns the list of available tools including 'get_leader_by_name'.] } }
- src/services/api.service.ts:786-794 (helper)Helper method in ApiService that performs a POST request to the backend API endpoint '/integrations/mcp/leader/get_leaders_by_name' with the leader name to retrieve leader data.async getLeaderByName (name: string) { const headers = await this.getHeaders() const response = await fetch(`${API_CONFIG.baseUrl}/integrations/mcp/leader/get_leaders_by_name`, { method: 'POST', headers: { ...headers, 'Content-Type': 'application/json' }, body: JSON.stringify({ name }) }) return await this.handleResponse<any>(response) }