Skip to main content
Glama

Fare Facts

Explain an airline fare basis code (free)

explain_fare_basis
Read-onlyIdempotent

US airline tickets, how to read them: explain a fare basis code (for example KL7NR3). Returns the booking class from the first letter, labeled notes that match the rest of the code (detail 'full' lists every convention), and a tip to paste the fare rules from your own booking for exact change and refund terms. Tax codes are not covered. Free: every Fare Facts tool and answer is free, with no account. Names, confirmation codes (record locators), ticket numbers and frequent flyer numbers are not needed or used; the input is only the codes or numbers in the input schema.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "fare_basis": "<fare_basis>"
    },
    "name": "explain_fare_basis"
  }
}

Input Schema

NameRequiredDescriptionDefault
detailNoOptional. "brief" (default) gives the main facts; "full" adds every note we have.brief
airlineNoOptional 2-character airline code, for example AA, DL, UA or B6.
fare_basisYesThe fare basis code only, 1 to 15 characters.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4/5.0
Behavior4/5

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

Annotations already declare read-only, closed-world and idempotent, and the description adds value beyond them: it describes what is returned (booking class from the first letter, labeled notes, a follow-up tip), states the tool is free with no account, and clarifies that no PII is required or used. It does not cover error behavior for malformed or unknown codes, which keeps it below a 5.

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

Conciseness3/5

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

Content is front-loaded and the domain framing comes first, which is good, but it is delivered as one dense run-on paragraph and restates 'free' from the title in a long sentence about record locators and frequent flyer numbers. Those privacy details are useful but could be tightened.

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

Completeness4/5

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

With no output schema, the description carries the burden of explaining the return payload, and it does so adequately (booking class, labeled notes, tip). Gaps remain around behavior on invalid or unknown codes and airline-code coverage, but nothing critical to calling it correctly is missing.

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

Parameters3/5

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

Schema coverage is 100%, so the enum meanings for detail and the airline pattern are already documented. The description adds only modest meaning, explaining that the first letter maps to booking class and that 'full' lists every convention; the airline parameter is barely elaborated beyond 'codes or numbers in the 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?

States a specific verb and resource ('explain a fare basis code') with a concrete example (KL7NR3) and explicitly marks the boundary versus the sibling explain_tax_codes ('Tax codes are not covered'). An agent can select this tool without opening the schema.

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?

Gives clear conditions and an exclusion ('Tax codes are not covered') plus guidance on when to escalate to the user's own fare rules for exact change/refund terms, and when to use detail='full'. It does not name the sibling tools by name, but the exclusions make usage unambiguous.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources