update_passengers
Edit passenger details including personal information, documents, and contact data for travel management within the LumbreTravel system.
Instructions
Edita pasajeros teniendo en cuenta que se conoce el ID del pasajero.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| passengers | Yes |
Implementation Reference
- src/handlers/tools.handler.ts:1351-1360 (handler)MCP tool handler that calls apiService.updatePassengers with the input passengers array and formats the response as MCP content.case 'update_passengers': { const { passengers } = args as { passengers: any[] } const updatedPassengers = await this.apiService.updatePassengers(passengers) return { content: [{ type: 'text', text: JSON.stringify(updatedPassengers, null, 2) }] } }
- Input schema defining the structure for updating passengers, requiring an array of passenger objects each with passengerId and other personal details.inputSchema: { type: 'object', properties: { passengers: { type: 'array', items: { type: 'object', properties: { passengerId: { type: 'string' }, firstname: { type: 'string' }, lastname: { type: 'string' }, birthdate: { type: 'string', description: "Fecha de nacimiento del pasajero (DD-MM-YYYY), si no se especifica usa el valor 'No conocemos'" }, documenttype: { type: 'string', description: 'Tipo de documento, opciones válidas son DNI, Pasaporte, Licencia de Conducir o ID' }, document: { type: 'string', description: "Numero de documento, si no se especifica usa el valor 'No conocemos'" }, gender: { type: 'string', description: 'Género del pasajero, puede ser male, female,non_binary, prefer_not_to_say, other. Si no se especifica deducilo del nombre y apellido' }, nationality: { type: 'string', description: 'Nacionalidad del pasajero de acuerdo a ISO 3166-1. Si no se especifica deducilo del nombre y apellido' }, language: { type: 'string', description: "Idioma del pasajero de acuerdo a ISO 639-1. Si no se especifica deducilo del nombre y apellido. No intentes usar las tools 'list_service_languages' ni 'get_service_language_by_name' para obtener el idioma del pasajero. El idioma del pasajero es simplemente un string en formato ISO 639-1." }, email: { type: 'string', description: "Email del pasajero, si no se especifica usa el valor 'No conocemos'" }, phone: { type: 'string', description: "Telefono del pasajero, si no se especifica usa el valor 'No conocemos'" } }, required: ['passengerId', 'firstname', 'lastname', 'birthdate', 'documenttype', 'document', 'gender', 'nationality', 'language', 'email', 'phone'] } } }, required: ['passengers'] }
- src/handlers/tools.handler.ts:331-366 (registration)Tool registration in the listTools() array, specifying name, description, and inputSchema.{ name: 'update_passengers', description: 'Edita pasajeros teniendo en cuenta que se conoce el ID del pasajero.', inputSchema: { type: 'object', properties: { passengers: { type: 'array', items: { type: 'object', properties: { passengerId: { type: 'string' }, firstname: { type: 'string' }, lastname: { type: 'string' }, birthdate: { type: 'string', description: "Fecha de nacimiento del pasajero (DD-MM-YYYY), si no se especifica usa el valor 'No conocemos'" }, documenttype: { type: 'string', description: 'Tipo de documento, opciones válidas son DNI, Pasaporte, Licencia de Conducir o ID' }, document: { type: 'string', description: "Numero de documento, si no se especifica usa el valor 'No conocemos'" }, gender: { type: 'string', description: 'Género del pasajero, puede ser male, female,non_binary, prefer_not_to_say, other. Si no se especifica deducilo del nombre y apellido' }, nationality: { type: 'string', description: 'Nacionalidad del pasajero de acuerdo a ISO 3166-1. Si no se especifica deducilo del nombre y apellido' }, language: { type: 'string', description: "Idioma del pasajero de acuerdo a ISO 639-1. Si no se especifica deducilo del nombre y apellido. No intentes usar las tools 'list_service_languages' ni 'get_service_language_by_name' para obtener el idioma del pasajero. El idioma del pasajero es simplemente un string en formato ISO 639-1." }, email: { type: 'string', description: "Email del pasajero, si no se especifica usa el valor 'No conocemos'" }, phone: { type: 'string', description: "Telefono del pasajero, si no se especifica usa el valor 'No conocemos'" } }, required: ['passengerId', 'firstname', 'lastname', 'birthdate', 'documenttype', 'document', 'gender', 'nationality', 'language', 'email', 'phone'] } } }, required: ['passengers'] } },
- src/services/api.service.ts:307-315 (helper)ApiService helper method that sends a POST request to the backend endpoint /integrations/mcp/passengers/update_passengers with the passengers data.async updatePassengers (passengers: any[]) { const headers = await this.getHeaders() const response = await fetch(`${API_CONFIG.baseUrl}/integrations/mcp/passengers/update_passengers`, { method: 'POST', headers: { ...headers, 'Content-Type': 'application/json' }, body: JSON.stringify({ passengers }) }) return await this.handleResponse<any>(response) }