change_flight
ChatGPTSelect or change the flight for an existing hotel selection and generate the booking link. For FLIGHT+HOTEL packages, this is the ONLY tool to use for flight confirmation — both for the pre-selected flight AND for alternative flights. Must be used AFTER get_alternative_flights. Pass the transport_id of the desired flight (pre-selected or alternative) as new_transport_id. Automatically generates and returns the booking link — do NOT call generate_booking_link afterwards. CRITICAL: Before calling, verify the pricing_id matches the CURRENT hotel shown in widgetState.modelContent. The user may have changed hotel via widget click — widget hotel changes do NOT produce new conversation-history tool responses. If widgetState shows a different pricing_id than a previous select_hotel_options response in the conversation, use the pricing_id from widgetState.
generate_booking_link
ChatGPTGenerate a direct booking URL for the selected hotel room option. ⚠️ HOTEL-ONLY bookings: Use this tool to generate the booking link. ⚠️ FLIGHT+HOTEL packages: Do NOT use this tool — use change_flight instead, which handles both flight selection AND booking link generation in one step. change_flight must always be called for DP packages, even for the pre-selected flight. CRITICAL: Before calling, verify the pricing_id matches the CURRENT hotel shown in widgetState.modelContent. The user may have changed hotel via widget click — widget hotel changes do NOT produce new conversation-history tool responses. If widgetState shows a different pricing_id than a previous select_hotel_options response in the conversation, use the pricing_id from widgetState. RATE_ID RULE (critical to avoid 'Rate not found' errors): The rate_id MUST come from the room_options list of the SAME select_hotel_options response that produced the pricing_id you are using. If the user explored multiple hotels in this conversation, each hotel has its own set of rate_ids — they are NOT interchangeable. When the user asks for 'the cheapest room' or similar, use the _active_context.cheapest_rate_id from the most recent select_hotel_options response, NOT by scanning prices across all responses in the conversation. Passing a rate_id from a different hotel's response will fail with 'Rate not found' even if the pricing_id is correct.
get_alternative_flights
ChatGPTGet alternative flight options for an existing flight+hotel package. MANDATORY STEP: When the user selects or mentions a room in a flight+hotel package, call this tool BEFORE generate_booking_link. The user must confirm or change their flight before booking. Can ONLY be used AFTER select_hotel_options. Returns list of alternative flights with prices specific to the chosen room. Do NOT reorder the results. ORDINAL NUMBERING: The response contains a pre-selected flight (current_flight) and a list of alternatives (flights). The pre-selected flight is the FIRST flight shown in the widget (ordinal 1st). Alternatives start at 2nd. When the user refers to 'first', 'second', 'third' flight (or in any language, e.g. 'primo', 'secondo', 'terzo' volo), always count from the pre-selected flight: 1st = pre-selected (current_flight), 2nd = alternatives[0], 3rd = alternatives[1], etc. CRITICAL: Before calling, verify the pricing_id matches the CURRENT hotel shown in widgetState.modelContent. The user may have changed hotel via widget click — widget hotel changes do NOT produce new conversation-history tool responses. If widgetState shows a different pricing_id than a previous select_hotel_options response in the conversation, use the pricing_id from widgetState.
navigate_back
ChatGPTCall when the user explicitly asks to go back to a previous screen in the hotel/package booking widget. Do NOT call for forward navigation, search refinement, room/hotel/flight selection, or other requests. REQUIRED pricing_id: always pass the pricing_id of the current session (the same one used for get_alternative_flights, change_flight, or generate_booking_link). It is available in the structuredContent of any prior select_hotel_options / get_alternative_flights / change_flight / generate_booking_link response. Without it, the widget cannot be reattached and the back navigation will be ignored silently. HOW TO CHOOSE target (critical — read carefully): - target='previous': use WHENEVER the user does NOT explicitly name the destination screen. Examples: 'torna indietro', 'indietro', 'back', 'go back', 'vai indietro', 'undo', 'torna dietro'. This is the DEFAULT and covers the vast majority of cases. Do NOT pick a specific screen unless the user clearly names it. - target='rooms': ONLY when the user explicitly names rooms. Examples: 'torna alle camere', 'alle stanze', 'back to rooms', 'to the room list'. - target='flights': ONLY when the user explicitly names flights. Examples: 'torna ai voli', 'alla selezione volo', 'back to flights'. DP flow only. - target='hotel_list': ONLY when the user explicitly names hotels/hotel list. Examples: 'torna agli hotel', 'alla lista hotel', 'back to hotel list', 'to the hotel search results'. Disambiguation rules: - 'torna indietro' from any screen → target='previous' (never 'hotel_list'). - 'torna indietro di due' → resolve directly to the specific target screen name (e.g. from summary 'di due' = 'rooms'). - If the user is already on the hotel list and asks to go back, DO NOT call this tool — reply in text that they are already on the first screen.
resolve_destination_id
ChatGPTResolve a city name to its internal destination ID. MUST be called before search_only_hotel. Supported languages: IT, EN, ES, FR, DE, PL, SE, DK, NO, FI (others fall back to EN). Returns id on exact match → follow next_step immediately (call search_only_hotel with destination=id AND destination_name=name). Returns suggestions list on ambiguity → do NOT call search_only_hotel yet. Instead, present the suggestions to the user in a conversational way and ask which destination they meant. Once the user picks one, call search_only_hotel with the chosen destination ID and destination_name. No widget is shown for this step.
search_flight_and_hotel_package
ChatGPTSearch for COMBINED flight AND hotel vacation packages. Use for: 'Find me flight and hotel packages from Rome to Madrid', 'vacation package with flights and hotel from FCO to Barcelona'. IATA codes required for origin and destination (e.g. MIL, FCO, MAD, LON). NEVER pass raw city names. Use 3-letter city codes (MIL, NYC) or airport codes (MXP, JFK). Returns Markdown table: | Photo | Hotel | Stars | Rating | Total Price | Distance from Centre | Amenities.
search_flights
ChatGPTSearch flights on lastminute.com. Use this tool for ANY user request to find, search, compare, browse, or check flights. Do not answer a flight-search request with text only when this tool can be used. RULES: - Pass departure and arrival translated in IATA Code. - Set language to the language of the user's CURRENT message. Detect it from the message text itself — do NOT inherit from previous turns, do NOT default to Italian or any other language. - If the request specifies dates, times, stops, airports, airlines, cabin class, ranking, or filters, pass them through using the matching tool arguments. - ranking_best and explicit filters are mutually exclusive — use one or the other. - After the tool returns results, keep the assistant reply brief. Do not list flights, prices, airlines, or booking links in text because the widget presents the detailed results. - If required inputs are missing, ask only for the missing flight-search fields.
search_only_hotel
ChatGPTSearch for hotel-only stays (no flights). ONLY VALID ARGUMENTS: destination, destination_name, date_from, date_to, adults, ch_ages, lang, currency, sort, max_results, accommodation_type, accommodation_facilities, price, hotel_stars NEVER SEND: checkin, checkout, check_in, check_out, arrival_date, departure_date, country, locale, guests, room_qty, rooms, children_number, children_age, languagecode, order_by, page_number, limit, sort_by CORRECT: {"destination":"130522","destination_name":"Rome","date_from":"2026-04-20","date_to":"2026-04-25","adults":"2","lang":"it","sort":"recommended","max_results":8} CORRECT (EN with USD pricing): {"destination":"130522","destination_name":"Rome","date_from":"2026-04-20","date_to":"2026-04-25","adults":"2","lang":"en","currency":"USD","sort":"recommended","max_results":8} WRONG: {"destination":"130522","checkin":"2026-04-20","checkout":"2026-04-25","adults":2,"limit":8,"sort":"popularity"} FIXED: {"destination":"130522","destination_name":"Rome","date_from":"2026-04-20","date_to":"2026-04-25","adults":"2","lang":"it","sort":"recommended","max_results":8} HARD RULES: - adults MUST be a string: "2" not 2. Do NOT send adults as integer. - sort default = "recommended". Never use "popularity", "rating", "best", "popular". - currency is OPTIONAL and effective ONLY when lang=en (values: GBP, USD, EUR). For any other lang it is silently ignored. - Send only fields strictly needed. Do not add optional fields unless required. - destination_name is REQUIRED: always forward the 'name' field from resolve_destination_id. PRE-STEP (mandatory): call resolve_destination_id first to get the numeric ID. - success=true → use 'id' as destination AND 'name' as destination_name, call this tool immediately. - success=false → present suggestions conversationally to the user, ask which they meant, then call this tool with the chosen ID and name. Do NOT open any widget until this tool is called. destination: numeric ID from resolve_destination_id (e.g. '130522') or IATA code as fallback. NEVER a raw city name.
select_hotel_options
ChatGPTGet detailed room options for a specific hotel. Call when the user asks to select or view a specific hotel from the current search results. CRITICAL: If a hotel widget is already open (widgetState contains search_id), use that search_id directly — do NOT start a new search. Calling this tool with the SAME search_id as the active widget will UPDATE the widget in-place to show the room selection view (no new widget opened). Returns: hotel info, flights (if DP package), room options sorted by price. IMPORTANT: After this tool returns, the widget screen changes to ROOM SELECTION — the user is no longer on the hotel list. Read the current_screen and next_step fields in the response to know what to do. For hotel-only: call generate_booking_link with pricing_id and rate_id when the user picks a room. For flight+hotel: call get_alternative_flights. Do NOT call select_hotel_options again after it succeeds — the rooms are already loaded.
change_flight
ClaudeChange the flight for an existing hotel selection. This tool updates the flight associated with your hotel booking after viewing alternatives. ⚠️ IMPORTANT: - Must be used AFTER get_alternative_flights to see available options - Requires both pricing_id and the new_transport_id from the alternatives list - This will update the total package price based on the new flight selection Example use cases: - "Change to flight option 2" - "Select the morning flight instead" - "Update to the cheaper flight option" Args: pricing_id: The pricing ID from select_hotel_options response new_transport_id: The transport ID of the selected alternative flight (from get_alternative_flights response) Returns: Dictionary confirming the flight change with updated package details
generate_booking_link
ClaudeGenerate a direct booking URL for the selected hotel room option. After change_flight, rate_id values change but the internalIdRoom stays the same. This tool automatically maps old rate_id to new rate_id based on internalIdRoom only. Args: pricing_id: The pricing ID from select_hotel_options response (NOT search_id) rate_id: The rate ID of the selected room option (from select_hotel_options response) Returns: Dictionary containing the booking URL and summary details
get_alternative_flights
ClaudeGet alternative flight options for an existing hotel selection. Input parameters: - pricing_id (string, REQUIRED): pricing ID returned by select_hotel_options. Behavior: - Can ONLY be used AFTER select_hotel_options. - Returns a list of alternative flights with their details and prices. - On success, alternative flight options are also stored in session for later use by change_flight. - Don't touch the order of the proposed flights, return them as received from the backend.
resolve_destination_id
ClaudeResolve a city name to its internal destination ID using the lastminute.com hints API. This tool is useful when you need to map a free-text city name to a structured destination identifier before performing a hotel or package search. Supported languages: IT, EN, ES, FR, DE, PL, SE, DK, NO, FI. Any unsupported language falls back to English (en-GB). Args: lang: 2-letter language code (e.g. "en", "it", "fr"). Case-insensitive. city_name: The city name to resolve (e.g. "London", "Roma", "Paris"). Returns: On exact match: { "success": true, "id": "<destination_id>", "name": "<matched city name>", "country": "<country name>", "country_code": "<ISO2 code>" } On no exact match (returns all City-type suggestions): { "success": false, "message": "No exact match found. Suggestions returned.", "suggestions": [ { "id": "...", "name": "...", "country": "...", "country_code": "...", }, ... ] } On API error: { "success": false, "error": "<error description>" }
search_flight_and_hotel_package
Claude🛫🏨 Search for COMBINED flight AND hotel vacation packages. This tool searches for all-inclusive vacation packages that include: - ✈️ Round-trip flights (outbound and return) - 🏨 Hotel accommodation for the entire stay - 💰 Package pricing (flight + hotel combined) ⚠️ IMPORTANT: This is for PACKAGE deals, NOT separate flight/hotel bookings. Is important to use the correct language in the destination field and keep the original language used in the request made in the user chat. Example use cases: - "Find me flight and hotel packages from Rome to Madrid" - "I need a vacation package with flights and hotel from FCO to Barcelona" - "Search flight+hotel deals from Milan to Paris for 3 nights" ═══════════════════════════════════════════════════════════════════════════ HARD CONSTRAINTS ═══════════════════════════════════════════════════════════════════════════ 1. Dates: - start_date MUST be today or later (YYYY-MM-DD) - If user provides past date, ask for valid date BEFORE calling 2. IATA Codes (CRITICAL): - origin and destination MUST be 3-letter IATA codes, NOT city names - NEVER pass city names like "New York", "Geneva", "Milan" - use IATA codes instead - Both CITY codes and AIRPORT codes are accepted: City codes: NYC, GVA, ZRH, DUB, BRU, VIE, MIL, LON, PAR, BSL Airport codes: JFK, MXP, FCO, LHR (automatically converted to city codes) - Examples: MXP or MIL for Milan, JFK or NYC for New York, FCO or ROM for Rome Args: origin: IATA code only - 3 letters. Use city code (MIL, NYC, LON) or airport code (MXP, JFK, LHR). NEVER use city names like "Milan" or "New York". destination: IATA code only - 3 letters. Use city code (BCN, PMI) or airport code. NEVER use city names like "Barcelona" or "Palma". date_from: Check-in date (YYYY-MM-DD). Check this field MUST be today or later. date_to: Check-out date (YYYY-MM-DD). Check this field MUST be today or later. adults: Number of adult travelers. If you want different rooms, set number_adult_room1;number_adult_room2 (default: 2) ⚠️ IMPORTANT: ch_ages: Ages of child travelers. If you want different rooms, set number_chages_room1;number_chages_room2 (default: ""). If there are two rooms and one is empty the result can be ";number,number" or "number,number;". The user MUST specify ages for each child. lang: Language code (default: "en") sort: Sort order for results. Use this when user asks for cheapest, best rated, closest to center, etc. Valid values: - "recommended" (default): Multi-factor relevance (price, rating, internal score) - "price": Price ascending (cheapest first) - use when user wants "cheapest" or "lowest price" - "stars": Hotel star rating descending (5-star first) - use for "best hotels" or "luxury" - "review_score": Highest review score - use for "best reviewed" or "most popular" - "distance": Closest to city center first - use for "central" or "close to center" max_results: Maximum number of results to return (default: 5, max: 20) accommodation_type: Filter by accommodation type (optional). CSV of IDs 1-14: 1=Hotels, 2=Resorts, 3=Apartments, 4=Hostels, 5=Motels, 6=Country Houses, 7=Guest Houses, 8=B&B, 9=Villas, 10=Boats & Cruises, 11=Campsites, 12=Riads, 13=Ryokans, 14=Aparthotels. Example: "1,2" for Hotels and Resorts accommodation_facilities: Filter by facilities/amenities (optional). CSV of IDs 0-60. All values are valid. Common examples: 0=Free Wi-Fi, 3=Parking, 4=Pool, 6=Spa, 7=Adults Only, 9=Seafront, 13=Fitness Center, 25=Golf, 46=Indoor Pool, 49=Sauna, 56=Bar, 58=Restaurant. Example: "0,4,6" for Free Wi-Fi, Pool, and Spa price: Optional price filter for one-way price per person, as string. Supported formats: - "300" => max price 300 (in the selected currency) - "200,400" => price range between 200 and 400 Use only digits and a comma, do NOT include currency symbols. If you invert the order ("400,200"), the backend will normalize it to "200,400". hotel_stars: Optional filter for hotel star rating, as comma-separated integers. Allowed values: 1,2,3,4,5. Examples: - "4" => only 4-star hotels - "3,4" => 3 or 4 stars - "3,4,5" => 3, 4 or 5 stars Returns: Diction…
search_flights
Claudesearch_only_hotel
ClaudeSearch for hotel-only stays (no flights included). ⚠️ IMPORTANT: This is for hotel-only searches. Flight bookings are not included. ═══════════════════════════════════════════════════════════════════════════ MANDATORY PRE-STEP: DESTINATION RESOLUTION ═══════════════════════════════════════════════════════════════════════════ Before calling this tool, you MUST silently call resolve_destination_id to resolve the city name to its internal numeric ID. Do NOT inform the user about this step. Workflow: 1. User provides a city name (e.g. "London", "Madrid") 2. Silently call resolve_destination_id(lang=<lang>, city_name=<city>) 3a. If success=true → use the returned "id" (e.g. "141660") as the destination field for this tool. 3b. If success=false → show the user the "suggestions" list (name + country) and ask them to clarify which city they mean. Do NOT call this tool yet. The destination field accepts: - A numeric ID string from resolve_destination_id (e.g. "141660") ← preferred - A 3-letter IATA code as fallback (e.g. "MAD", "LON") when the user explicitly provides one and no resolution is needed. ═══════════════════════════════════════════════════════════════════════════ HARD CONSTRAINTS ═══════════════════════════════════════════════════════════════════════════ 1. Dates: - start_date MUST be today or later (YYYY-MM-DD) - If user provides past date, ask for valid date BEFORE calling 2. Destination (CRITICAL): - Always prefer the numeric ID from resolve_destination_id - If using IATA fallback: must be 3-letter code (MAD, PAR, MIL, LON) - NEVER pass raw city names like "Madrid" or "Paris" directly Example use cases: - "Find me a hotel in Madrid for 3 nights" → resolve "Madrid" first → use id - "Search hotel in London" → resolve "London" first → use id Args: destination: Numeric destination ID from resolve_destination_id (e.g. "141660"), or 3-letter IATA code (e.g. "MAD") as fallback. date_from: Check-in date (YYYY-MM-DD). Check this field MUST be today or later. date_to: Check-out date (YYYY-MM-DD). Check this field MUST be today or later. adults: Number of adult travelers. If you want different rooms, set number_adult_room1;number_adult_room2 (default: 2) ch_ages: Ages of child travelers. If you want different rooms, set number_chages_room1;number_chages_room2 (default: ""). If there are two rooms and one is empty the result can be ";number,number" or "number,number;". The user MUST specify ages for each child. lang: Language code (default: "en") sort: Sort order for results. Use this when user asks for cheapest, best rated, closest to center, etc. Valid values: - "recommended" (default): Multi-factor relevance (price, rating, internal score) - "price": Price ascending (cheapest first) - use when user wants "cheapest" or "lowest price" - "stars": Hotel star rating descending (5-star first) - use for "best hotels" or "luxury" - "review_score": Highest review score - use for "best reviewed" or "most popular" - "distance": Closest to city center first - use for "central" or "close to center" max_results: Maximum number of results to return (default: 5, max: 20) accommodation_type: Filter by accommodation type (optional). CSV of IDs 1-14: 1=Hotels, 2=Resorts, 3=Apartments, 4=Hostels, 5=Motels, 6=Country Houses, 7=Guest Houses, 8=B&B, 9=Villas, 10=Boats & Cruises, 11=Campsites, 12=Riads, 13=Ryokans, 14=Aparthotels. Example: "1,2" for Hotels and Resorts accommodation_facilities: Filter by facilities/amenities (optional). CSV of IDs 0-60. Examples: 0=Free Wi-Fi, 4=Pool, 6=Spa, 7=Adults Only, 9=Seafront, 25=Golf, 46=Indoor Pool, 56=Bar, 58=Restaurant. Example: "0,4,6" for Free Wi-Fi, Pool, and Spa price: Optional price filter for one-way price per person, as string. Supported formats: - "300" => max price 300 (in the selected currency) - "200,400" => price range between 200 and 400 Use only digits and a comma, do NOT include currency symbols. If you invert the order ("400,200"), the backend will normalize it to "200,400". hotel_stars: Optional filter for hotel star rating, as comma-separated integers. Allowed values: 1,2,3,4,5. Exampl…
select_hotel_options
ClaudeGet detailed options for a specific hotel after initial search. This tool automatically uses the same number of adults, children, currency, and business profile from the original search to ensure consistency. Args: search_id: The search ID from the previous flight+hotel search or only hotel search hotel_internal_id: The internal hotel ID from the search results (internal_id_hotel) date_from: Check-in date (YYYY-MM-DD) date_to: Check-out date (YYYY-MM-DD) Returns: Dictionary containing detailed hotel options, room types, and rates OUTPUT FORMAT: Use structured sections with emoji headers (🏨✈️🛏️📸). 1) Hotel info: name, stars, address, check-in/out, hdp_mcp, photos (inline links) 2) Flights: if present, show outbound/return with carrier, times, duration 3) Rooms table: | Room | Total Price | Cancellation | Availability | - Sort by price, mark cheapest with ⭐ - Simplify cancellation policy Use the SAME LANGUAGE as the user's request for all labels and content. Hide internal IDs (rate_id kept for booking but not shown in the display).