delete_agency
Remove a travel agency from the LumbreTravel system to prevent its association with programs.
Instructions
Eliminar una agencia. La agencia eliminada no se puede usar para asociarle programas
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | ID de la agencia a eliminar |
Implementation Reference
- src/handlers/tools.handler.ts:1447-1453 (handler)Handler logic in callTool method that executes the delete_agency tool by calling ApiService.deleteAgency(id) and returning the result.case 'delete_agency': { const { id } = args as { id: string } const agency = await this.apiService.deleteAgency(id) return { content: [{ type: 'text', text: JSON.stringify(agency, null, 2) }] } }
- src/handlers/tools.handler.ts:732-742 (registration)Registration of the delete_agency tool in the listTools() method's tools array, including name, description, and input schema.{ name: 'delete_agency', description: 'Eliminar una agencia. La agencia eliminada no se puede usar para asociarle programas', inputSchema: { type: 'object', properties: { id: { type: 'string', description: 'ID de la agencia a eliminar' } }, required: ['id'] } },
- Input schema for the delete_agency tool, defining required 'id' parameter.inputSchema: { type: 'object', properties: { id: { type: 'string', description: 'ID de la agencia a eliminar' } }, required: ['id'] }
- src/services/api.service.ts:463-470 (helper)ApiService helper method that performs the actual API call to delete an agency by ID.async deleteAgency (id: string) { const headers = await this.getHeaders() const response = await fetch(`${API_CONFIG.baseUrl}/integrations/mcp/agency/delete/${id}`, { method: 'DELETE', headers }) return await this.handleResponse<any>(response) }