Raw definition
{
"name": "search_flights",
"title": "Search Flights",
"description": "Search flights between any two cities worldwide on Go2Trip. Returns a curated set of options, each tagged with one or more categories:\n- **best**: the engine's recommended balance of price, total duration, and stops.\n- **cheapest**: lowest total price.\n- **fastest**: shortest total travel time.\nThe categories overlap — a single flight can be both best and cheapest. Each option includes price, total durations, layovers, its `categories`, and a direct booking link on the Go2Trip site for the chosen `market`. Options may include `seats_remaining` — the number of seats left in this booking class at this price; values of 4 or fewer indicate limited availability.",
"inputSchema": {
"type": "object",
"$schema": "http://json-schema.org/draft-07/schema#",
"required": [
"origin",
"destination",
"departure_date"
],
"properties": {
"adults": {
"type": "integer",
"default": 1,
"maximum": 9,
"minimum": 0,
"description": "Number of adult passengers (0–9)"
},
"market": {
"enum": [
"uk",
"ae",
"qa",
"au",
"cy",
"cz",
"gr",
"mt",
"sk"
],
"type": "string",
"default": "uk",
"description": "Go2Trip country site to search and book on: 'uk' (United Kingdom), 'ae' (United Arab Emirates), 'qa' (Qatar), 'au' (Australia), 'cy' (Cyprus), 'cz' (Czech Republic), 'gr' (Greece), 'mt' (Malta) or 'sk' (Slovakia). Use the site of the user's country of residence when the conversation makes it clear and it is one of these; otherwise use 'uk'. Prices come back in that site's currency and the booking link opens on that site."
},
"origin": {
"type": "string",
"maxLength": 3,
"minLength": 3,
"description": "3-letter IATA city or airport code (e.g. 'TLV', 'LON', 'MAD')"
},
"infants": {
"type": "integer",
"default": 0,
"maximum": 9,
"minimum": 0,
"description": "Number of infant passengers (0–9)"
},
"seniors": {
"type": "integer",
"default": 0,
"maximum": 9,
"minimum": 0,
"description": "Number of senior passengers (0–9)"
},
"children": {
"type": "integer",
"default": 0,
"maximum": 9,
"minimum": 0,
"description": "Number of child passengers (0–9)"
},
"language": {
"enum": [
"en"
],
"type": "string",
"default": "en",
"description": "Language for the interactive results widget. English only."
},
"destination": {
"type": "string",
"maxLength": 3,
"minLength": 3,
"description": "3-letter IATA city or airport code (e.g. 'TLV', 'LON', 'MAD')"
},
"return_date": {
"type": "string",
"pattern": "^\\d{4}-\\d{2}-\\d{2}$",
"description": "Return date for round trips (YYYY-MM-DD). Omit for one-way."
},
"flight_class": {
"enum": [
"tour",
"tourPlus",
"business",
"first"
],
"type": "string",
"default": "tour",
"description": "Cabin class: tour (economy), tourPlus (premium economy), business, or first"
},
"departure_date": {
"type": "string",
"pattern": "^\\d{4}-\\d{2}-\\d{2}$",
"description": "Departure date in YYYY-MM-DD format"
}
},
"additionalProperties": false
},
"outputSchema": {
"type": "object",
"$schema": "http://json-schema.org/draft-07/schema#",
"required": [
"query",
"flights",
"total"
],
"properties": {
"query": {
"type": "object",
"required": [
"origin",
"destination",
"departure_date"
],
"properties": {
"adults": {
"type": "integer",
"default": 1,
"maximum": 9,
"minimum": 0,
"description": "Number of adult passengers (0–9)"
},
"market": {
"enum": [
"uk",
"ae",
"qa",
"au",
"cy",
"cz",
"gr",
"mt",
"sk"
],
"type": "string",
"default": "uk",
"description": "Go2Trip country site to search and book on: 'uk' (United Kingdom), 'ae' (United Arab Emirates), 'qa' (Qatar), 'au' (Australia), 'cy' (Cyprus), 'cz' (Czech Republic), 'gr' (Greece), 'mt' (Malta) or 'sk' (Slovakia). Use the site of the user's country of residence when the conversation makes it clear and it is one of these; otherwise use 'uk'. Prices come back in that site's currency and the booking link opens on that site."
},
"origin": {
"type": "string",
"maxLength": 3,
"minLength": 3,
"description": "3-letter IATA city or airport code (e.g. 'TLV', 'LON', 'MAD')"
},
"infants": {
"type": "integer",
"default": 0,
"maximum": 9,
"minimum": 0,
"description": "Number of infant passengers (0–9)"
},
"seniors": {
"type": "integer",
"default": 0,
"maximum": 9,
"minimum": 0,
"description": "Number of senior passengers (0–9)"
},
"children": {
"type": "integer",
"default": 0,
"maximum": 9,
"minimum": 0,
"description": "Number of child passengers (0–9)"
},
"language": {
"enum": [
"en"
],
"type": "string",
"default": "en",
"description": "Language for the interactive results widget. English only."
},
"destination": {
"type": "string",
"maxLength": 3,
"minLength": 3,
"description": "3-letter IATA city or airport code (e.g. 'TLV', 'LON', 'MAD')"
},
"return_date": {
"type": "string",
"pattern": "^\\d{4}-\\d{2}-\\d{2}$",
"description": "Return date for round trips (YYYY-MM-DD). Omit for one-way."
},
"flight_class": {
"enum": [
"tour",
"tourPlus",
"business",
"first"
],
"type": "string",
"default": "tour",
"description": "Cabin class: tour (economy), tourPlus (premium economy), business, or first"
},
"departure_date": {
"type": "string",
"pattern": "^\\d{4}-\\d{2}-\\d{2}$",
"description": "Departure date in YYYY-MM-DD format"
}
},
"description": "The search parameters, with defaults applied",
"additionalProperties": false
},
"total": {
"type": "integer",
"description": "Total matches found, which may exceed `flights.length`"
},
"flights": {
"type": "array",
"items": {
"type": "object",
"required": [
"outbound",
"pricing_details",
"categories"
],
"properties": {
"price": {
"type": "number",
"description": "Total trip price for all passengers"
},
"inbound": {
"$ref": "#/properties/flights/items/properties/outbound",
"description": "Absent on one-way trips"
},
"currency": {
"type": "string",
"description": "ISO currency code of `price`"
},
"outbound": {
"type": "object",
"required": [
"from",
"to",
"departure_local",
"arrival_local",
"duration_minutes",
"flights",
"layovers"
],
"properties": {
"to": {
"type": "string"
},
"from": {
"type": "string"
},
"flights": {
"type": "array",
"items": {
"type": "object",
"required": [
"from",
"to",
"departure_local",
"arrival_local",
"flight_number",
"duration_minutes"
],
"properties": {
"to": {
"type": "string"
},
"from": {
"type": "string"
},
"brand": {
"type": "string",
"description": "Fare brand, e.g. 'LITE', 'FLEX'"
},
"cabin": {
"type": "string",
"description": "Raw cabin code, e.g. 'Y', 'C'/'J', 'F'"
},
"terminal_to": {
"type": "string"
},
"arrival_local": {
"type": "string"
},
"flight_number": {
"type": "string"
},
"terminal_from": {
"type": "string"
},
"departure_local": {
"type": "string"
},
"seats_remaining": {
"type": "number"
},
"duration_minutes": {
"type": "number"
},
"checked_bag_included": {
"type": "boolean"
}
},
"additionalProperties": false
}
},
"layovers": {
"type": "array",
"items": {
"type": "object",
"required": [
"airport_code",
"arrival_local",
"departure_local"
],
"properties": {
"airport_code": {
"type": "string"
},
"arrival_local": {
"type": "string"
},
"departure_local": {
"type": "string"
}
},
"additionalProperties": false
}
},
"arrival_local": {
"type": "string"
},
"departure_local": {
"type": "string"
},
"duration_minutes": {
"type": "number"
}
},
"additionalProperties": false
},
"deep_link": {
"type": "string",
"description": "Link to complete this booking on the Go2Trip site for the searched market"
},
"categories": {
"type": "array",
"items": {
"enum": [
"best",
"cheapest",
"fastest"
],
"type": "string"
},
"description": "Which curated selections this flight appeared in; may be more than one"
},
"pricing_details": {
"type": "array",
"items": {
"type": "object",
"required": [
"passenger_type",
"total_price"
],
"properties": {
"total_price": {
"type": "number"
},
"passenger_type": {
"enum": [
"ADT",
"CHD",
"INF",
"YCD"
],
"type": "string"
}
},
"additionalProperties": false
}
},
"seats_remaining": {
"type": "number",
"description": "Seats bookable at this price; 4 or fewer means limited availability"
}
},
"additionalProperties": false
},
"description": "Matching options, capped at 30"
}
},
"additionalProperties": false
},
"annotations": {
"title": "Search Flights",
"readOnlyHint": true,
"openWorldHint": true,
"destructiveHint": false
}
}