Skip to main content
Glama

avia-mcp

MCP-сервер для поиска дешёвых авиабилетов через Aviasales Data API (Travelpayouts).

Цены берутся из кэша поисков Aviasales примерно за 48 часов — это не живой поиск. Актуальную цену подтверждает ссылка на Aviasales из ответа. Покупки и бронирования через сервер нет.

Инструменты

Инструмент

Что делает

search_places

IATA-код города или аэропорта по названию. Токен не нужен.

search_flights

Самые дешёвые билеты по маршруту на дату или месяц.

price_calendar

Минимальная цена по дням месяца и три самых дешёвых дня.

cheapest_destinations

Самые дешёвые направления из города, с потолком цены.

Related MCP server: Apify Google Flights Deals API

Токен

Бесплатный токен: travelpayouts.com → «Инструменты» → API. Без токена работает только search_places.

Подключение

Нужен Node.js 22 или новее. Сервер запускается через npx, ставить вручную ничего не надо.

Claude Code:

claude mcp add avia --scope user -e TRAVELPAYOUTS_TOKEN=ваш_токен -- npx -y avia-mcp

Claude Desktop, Cursor и другие клиенты — в конфиге MCP-серверов (для Claude Desktop это claude_desktop_config.json):

{
  "mcpServers": {
    "avia": {
      "command": "npx",
      "args": ["-y", "avia-mcp"],
      "env": { "TRAVELPAYOUTS_TOKEN": "ваш_токен" }
    }
  }
}

Переменные окружения

Переменная

По умолчанию

Что задаёт

TRAVELPAYOUTS_TOKEN

—

Токен Travelpayouts.

AVIA_CURRENCY

rub

Валюта цен.

Разработка

git clone https://github.com/danyasnov/avia-mcp.git
cd avia-mcp
npm install
npm run build
cp .env.example .env   # впишите токен

При запуске из клона сервер читает .env в корне проекта; переменные окружения процесса важнее файла. Подключить локальную сборку:

claude mcp add avia --scope user -- node /путь/к/avia-mcp/dist/index.js

Проверка

npm test
npm run smoke

npm run smoke запускает собранный сервер и вызывает каждый инструмент по разу. Без токена отвечает только search_places, остальные возвращают подсказку про токен.

Лицензия

MIT

Available Tools

4 tools
cheapest_destinationsA
Read-only

Куда дешевле всего улететь из города: по одному самому дешёвому билету на каждое направление, от дешёвых к дорогим. Подходит для вопросов «куда слетать в ноябре до 20 000 ₽». Цены берутся из кэша поисков Aviasales примерно за 48 часов, это не живой поиск: актуальную цену подтверждает ссылка url.

ParametersJSON Schema
NameRequiredDescriptionDefault
limitNoСколько направлений вернуть
directNoТолько прямые рейсы
originYesОткуда: IATA-код города или аэропорта, например MOW
currencyNoВалюта цен, например rub, usd, eur. По умолчанию — валюта сервера (rub).
max_priceNoПотолок цены в выбранной валюте
return_atNoОбратный вылет: дата YYYY-MM-DD или месяц YYYY-MM. Без него — билеты в одну сторону
departure_atNoВылет: дата YYYY-MM-DD или месяц YYYY-MM. Без него — любые даты

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already declare readOnlyHint and openWorldHint, and the description adds meaningful extra context: prices come from an ~48h Aviasales cache rather than a live search, and the actual price is confirmed via the returned url. This freshness caveat is exactly the kind of behavioral trait annotations can't convey.

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?

Three sentences, zero waste: purpose and sort order first, then the canonical use case, then the data-freshness caveat. Front-loaded and tightly organized.

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 does mention the returned url link and the sorted, one-per-destination result shape, which is helpful. It covers purpose, usage, and a key data caveat; only the remaining return fields and pagination behavior are left implicit.

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 description coverage is 100%, so every parameter (origin, limit, direct, currency, max_price, departure_at, return_at) is already documented in the schema. The description only echoes a max_price/currency example ('до 20 000 ₽') without adding format or constraint detail beyond what the schema provides.

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+resource and scope: 'Куда дешевле всего улететь из города', one cheapest ticket per destination, sorted cheap-to-expensive. This is clearly distinct from search_flights (specific flight lookup) and price_calendar (a calendar of prices), so an agent can differentiate without opening schemas.

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 an explicit use case ('куда слетать в ноябре до 20 000 ₽'), which tells the agent when to reach for this tool. However, it never names the alternatives (search_flights, price_calendar) or states when NOT to use it, so routing is only partly guided.

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

price_calendarA
Read-only

Минимальная цена по каждому дню вылета в выбранном месяце — чтобы найти самые дешёвые даты. С trip_duration цены за перелёт туда-обратно, без него — в одну сторону. Отдельно возвращает три самых дешёвых дня. Дни без данных в ответ не попадают. Цены берутся из кэша поисков Aviasales примерно за 48 часов, это не живой поиск: актуальную цену подтверждает ссылка url.

ParametersJSON Schema
NameRequiredDescriptionDefault
monthYesМесяц вылета в формате YYYY-MM
directNoТолько прямые рейсы
originYesОткуда: IATA-код города или аэропорта, например MOW
currencyNoВалюта цен, например rub, usd, eur. По умолчанию — валюта сервера (rub).
destinationYesКуда: IATA-код города или аэропорта, например IST
trip_durationNoДлительность поездки в днях — тогда цены туда-обратно. Без неё — в одну сторону

TDQS

A4/5.0
Behavior5/5

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

Beyond the readOnly/openWorld annotations, the description discloses substantial behavior: prices come from a ~48h Aviasales cache and are not live, the url link confirms the actual price, days without data are omitted, and the three cheapest days are returned separately. This is exactly the kind of non-obvious context annotations cannot express.

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

Conciseness4/5

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

Four sentences, front-loaded with the core purpose and no filler. Every sentence carries information (round-trip toggle, return extras, data omission, cache freshness). Slightly dense but well-structured with no redundancy.

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?

With no output schema, the description carries the return-shape burden and does so: it explains the three cheapest days, the exclusion of data-less days, and the url confirmation field. Combined with the cache caveat, an agent has everything needed to call and interpret it correctly.

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 description coverage is 100%, so the schema already documents all six parameters. The description reinforces the trip_duration semantics (round-trip vs one-way), adding a little meaning, but does not introduce syntax or constraints beyond the schema. Baseline 3 applies.

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

Purpose4/5

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

States a specific verb+resource: minimum price per departure day in a chosen month, framed as finding the cheapest dates. It clearly separates one-way vs round-trip behavior and names its returned extras. It does not explicitly differentiate itself from sibling tools like cheapest_destinations or search_flights, so an agent must infer routing from the name alone.

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

Usage Guidelines3/5

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

The 'чтобы найти самые дешёвые даты' (to find the cheapest dates) framing implies the use case, and the trip_duration toggle clarifies two usage modes. However, it names no alternatives and gives no explicit when-not guidance versus search_flights or cheapest_destinations, leaving the agent to infer the choice.

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

search_flightsA
Read-only

Самые дешёвые авиабилеты по маршруту на дату или месяц, от дешёвых к дорогим. Цена для туда-обратно — за весь перелёт. Цены берутся из кэша поисков Aviasales примерно за 48 часов, это не живой поиск: актуальную цену подтверждает ссылка url.

ParametersJSON Schema
NameRequiredDescriptionDefault
limitNoСколько билетов вернуть
directNoТолько прямые рейсы
originYesОткуда: IATA-код города или аэропорта, например MOW
currencyNoВалюта цен, например rub, usd, eur. По умолчанию — валюта сервера (rub).
return_atNoОбратный вылет: дата YYYY-MM-DD или месяц YYYY-MM. Без него ищутся билеты в одну сторону
destinationYesКуда: IATA-код города или аэропорта, например IST
departure_atYesВылет: дата YYYY-MM-DD или весь месяц YYYY-MM

TDQS

A3.7/5.0
Behavior5/5

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

Beyond the readOnlyHint/openWorldHint annotations, it discloses that results are sorted cheap-to-expensive, that round-trip prices cover the whole journey, and critically that prices come from a ~48h Aviasales cache rather than a live search, with the url as the source of truth. This is exactly the kind of non-obvious behavior an agent needs before presenting prices as current.

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

Conciseness4/5

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

Three tight sentences that front-load the core purpose, then add pricing semantics and the cache caveat. No filler, though the round-trip/one-way point is split across sentences rather than consolidated.

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?

For a 7-parameter read-only search with no output schema, the description covers purpose, ordering, pricing scope, and the freshness limitation. The main missing piece is routing guidance among the sibling fare-discovery tools.

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 description coverage is 100%, so the meaning of origin, destination, departure_at, return_at, currency, direct and limit is already fully documented. The description adds only the round-trip pricing semantics, so the schema does the heavy lifting and baseline 3 applies.

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

Purpose4/5

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

States a specific verb and resource ('cheapest flights by route for a date or month') plus the sort order and price semantics, making it clear this is a round-trip/one-way fare search. It does not, however, differentiate itself from siblings like cheapest_destinations or price_calendar, so an agent must infer the boundary.

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

Usage Guidelines2/5

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

The description explains data freshness (48h cache, not live) which helps interpret results, but gives no when-to-use guidance and never names an alternative among search_places, cheapest_destinations, or price_calendar. Selection between these siblings is left entirely to inference.

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

search_placesA
Read-only

Находит IATA-код города или аэропорта по названию. Вызывайте перед остальными инструментами, если код неизвестен: им нужны коды вроде MOW или LED, а не названия.

ParametersJSON Schema
NameRequiredDescriptionDefault
limitNoСколько вариантов вернуть
queryYesНазвание города или аэропорта на русском или английском, например «Питер»

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true and openWorldHint=true, so the safety profile is covered. The description adds real context beyond that: it is a lookup dependency for other tools, and its output is a code (MOW/LED), not free text. It does not mention how the limit/default affects result breadth, but that is minor against the annotation coverage.

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?

Two sentences, zero waste, with the core purpose stated first and the prerequisite workflow guidance second. Every sentence earns its place.

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 two-parameter lookup with no output schema, the description supplies the missing piece an agent needs: what comes back (an IATA code) and why it matters (siblings require codes, not names). Nothing essential to correct invocation 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 description coverage is 100% and both parameters (query, limit) are documented in the schema, so the baseline is 3. The description reinforces that query is a name (Russian or English implied by the example) but adds no syntax or format details beyond the 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: resolves the IATA code of a city or airport from a name. It also identifies its role relative to siblings (the code resolver that must run before search_flights/cheapest_destinations/price_calendar), so an agent can distinguish it without opening any schema.

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

Usage Guidelines5/5

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

Explicitly says when to call it: before the other tools, when the code is unknown, because those tools require codes like MOW or LED rather than names. This names the dependency condition and the alternative (skip it when the code is already known), leaving nothing to inference.

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

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

  1. 4 tool updatesv0.1.1
    • First observedcheapest_destinations
    • First observedprice_calendar
    • First observedsearch_flights
    • First observedsearch_places

TDQS

A3.9/5.0

Scored across 4 tools

Disambiguation4/5

Each tool targets a distinct task: IATA code lookup (search_places), route pricing (search_flights), destination discovery (cheapest_destinations), and date-flexibility search (price_calendar). There is mild overlap between search_flights by month and price_calendar, and between search_flights and cheapest_destinations, but descriptions clarify the boundaries well.

Naming Consistency4/5

All names are snake_case and descriptive, but the convention is not uniform: two use a search_ verb prefix while cheapest_destinations and price_calendar are noun phrases. Still readable and predictable enough to distinguish at a glance.

Tool Count4/5

Four tools is a lean but well-scoped set covering code resolution, route pricing, destination discovery, and calendar pricing. Each earns its place, though the surface is on the thin side for a full flight-search domain.

Completeness4/5

The surface covers the core discovery workflow: resolve location, search a route, explore cheap destinations, and find cheap dates. Notable gaps include multi-city/round-trip specifics beyond trip_duration and no booking or price-alert operation, but these are workarounds rather than dead ends.

Related MCP Connectors

Related MCP Servers