Skip to main content
Glama

search_flights

Read-only

Search flight routes and dates to get ranked cash-priced options, 10 per page. Filter by cabin class, airlines, stops, and passengers for tailored results.

Instructions

Search for flights by route and date and return cash-priced options.

Results are ranked for the traveler by the search backend — weighing their airline
loyalty/status and travel history alongside flight quality — and returned 10 per page.
To see more options, call again with ``page=2``, ``page=3``, and so on.

Args:
    origin: Origin airport code or city (e.g. "LAX", "SFO", "New York").
    destination: Destination airport code or city (e.g. "NRT", "LHR", "Paris").
    departure_date: Departure date in YYYY-MM-DD format (e.g. "2025-03-15").
    return_date: Optional return date in YYYY-MM-DD format for a round trip. In browse
        mode, round trips are searched as two one-way legs.
    num_passengers: Number of passengers. Defaults to 1.
    cabin_class: Optional cabin class preference. One of:
        "economy", "premium economy", "business", "first".
    mode: Leave as "browse" (default). "book" is a restricted alpha — only use it if
        the user explicitly asks to book a flight.
    page: 1-based results page, 10 options per page. Increment to see more options.
    airlines: Optional airline codes or names for browse mode (e.g. ["UA"] or
        ["United"]). Passed to the Google Flights search API.
    max_stops: Optional maximum stops per direction in browse mode. Use 0 for
        nonstop only, 1 for nonstop or one-stop itineraries.

Returns:
    A ranked, paged list of flight options — airlines, routes, prices, and a link.

    Cash prices only. This tool does not currently return award (points/miles) pricing
    for flights, so do not state or imply a flight's points cost from these results. If
    the user asks how many miles a flight costs, say that award pricing is not available
    here right now and point them at the airline's own award search. Hotel award pricing
    is unaffected: the hotel tools still return points rates and cents-per-point.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modeNobrowse
pageNo
originYes
airlinesNo
max_stopsNo
cabin_classNo
destinationYes
return_dateNo
departure_dateYes
num_passengersNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.8/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With readOnlyHint=true already available, the description still adds substantial behavioral context: results are ranked by the backend based on loyalty and travel history, only cash prices are returned, award pricing must not be implied, and browse-mode round trips are searched as two one-way legs.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The summary is front-loaded, the Args section is ordered logically, and the caveat about award pricing is clearly separated under Returns. Every paragraph earns its place, and the length is justified by the tool's 10 parameters and important behavioral constraints.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a tool with 10 parameters, an output schema, and nuanced booking-mode behavior, the description covers all essential invocation details: required parameters, optional filters, pagination, mode restrictions, and the cash-only limitation. Nothing an agent needs to call it correctly is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, but the description's Args section richly documents every parameter: origin/destination accept codes or city names, date format is specified, cabin_class values are enumerated, mode restrictions are explained, and max_stops semantics are clarified. This goes far beyond the bare input schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb and resource: 'Search for flights by route and date and return cash-priced options.' This clearly distinguishes the tool from hotel, vehicle, and event search tools among the siblings.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description gives clear usage context: browse mode is the default, book mode is restricted to explicit user requests, and pagination instructions tell the caller how to get more results. It does not explicitly contrast with sibling search tools, but the flight-specific scope makes that contrast unnecessary.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.