Skip to main content
Glama
lumile

LumbreTravel MCP Server

by lumile

update_hotel

Modify hotel details like name, description, contact information, and address in the LumbreTravel system to keep listings current and accurate.

Instructions

Actualizar un hotel

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesID del hotel a actualizar
nameYesNombre del hotel
descriptionYesDescripción del hotel
phoneYesTeléfono del hotel
emailYesEmail del hotel
addressYesDirección del hotel

Implementation Reference

  • The main handler logic for the 'update_hotel' tool within the callTool switch statement. It extracts arguments, calls the ApiService updateHotel method, and returns the result.
    case 'update_hotel': { const { id, name, description, phone, email, address } = args const hotel = await this.apiService.updateHotel({ id, name, description, phone, email, address }) return { content: [{ type: 'text', text: JSON.stringify(hotel, null, 2) }] } }
  • The tool definition including name, description, and input schema in the listTools() method.
    { name: 'update_hotel', description: 'Actualizar un hotel', inputSchema: { type: 'object', properties: { id: { type: 'string', description: 'ID del hotel a actualizar' }, name: { type: 'string', description: 'Nombre del hotel' }, description: { type: 'string', description: 'Descripción del hotel' }, phone: { type: 'string', description: 'Teléfono del hotel' }, email: { type: 'string', description: 'Email del hotel' }, address: { type: 'string', description: 'Dirección del hotel' } }, required: ['id', 'name', 'description', 'phone', 'email', 'address'] } },
  • Supporting ApiService method that sends a PUT request to the external API endpoint to update a hotel.
    async updateHotel (data: { id: string name: string description: string phone: string email: string address: string }) { const headers = await this.getHeaders() const response = await fetch(`${API_CONFIG.baseUrl}/integrations/mcp/hotels/update`, { method: 'PUT', headers: { ...headers, 'Content-Type': 'application/json' }, body: JSON.stringify(data) }) return await this.handleResponse<any>(response)
  • src/index.ts:44-47 (registration)
    Server registration of the callTool handler, which dispatches to the specific tool handler based on name.
    this.server.setRequestHandler( CallToolRequestSchema, async (request) => await this.toolsHandler.callTool(request.params.name, request.params.arguments, this.server) )
  • src/index.ts:39-41 (registration)
    Server registration of the listTools handler, which returns the list of available tools including update_hotel.
    ListToolsRequestSchema, async () => this.toolsHandler.listTools() )

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/lumile/lumbretravel-mcp'

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