About Aviasales
Aviasales is an MCP server for searching fares through the Aviasales Data API. It serves travel planning queries for routes and dates; prices come from roughly 48-hour search caches, and it does not handle booking or purchases.
Key features
- 01Find city or airport IATA codes by name
- 02Search low fares by route and date
- 03View daily minimum fares for a month
- 04Find cheap destinations under a price cap
Use cases
- 01Find an airport or city’s IATA code
- 02Compare fare dates for a route
- 03Identify lower-fare dates across a month
- 04Find destinations within a budget
MCP support
As an MCP server, it exposes place lookup, flight search, price calendar, and cheap-destination tools to clients. All tools except `search_places` require `TRAVELPAYOUTS_TOKEN`; returned cached prices should be confirmed through Aviasales links.
Configuration
Local server config is the same for every client. Copy it into your client’s MCP config file.
npx -y avia-mcpTRAVELPAYOUTS_TOKENSecretTravelpayouts API token (free: travelpayouts.com → Tools → API)AVIA_CURRENCYPrice currency, e.g. rub, usd, eurLocal servers need a runtime on your machine (e.g. Node.js 18+). Config file locations differ by client; see your client’s docs.
Tools
4Saved tool list · updated 2w ago
| Parameter | Type | Required | Description |
|---|---|---|---|
| limit | integer | No | Number of results to return |
| query | string | Yes | City or airport name in Russian or English, e.g. “Питер” |
Details
From the project READMEavia-mcp
MCP-сервер для поиска дешёвых авиабилетов через Aviasales Data API (Travelpayouts).
Цены берутся из кэша поисков Aviasales примерно за 48 часов — это не живой поиск. Актуальную цену подтверждает ссылка на Aviasales из ответа. Покупки и бронирования через сервер нет.
Инструменты
| Инструмент | Что делает |
|---|---|
search_places | IATA-код города или аэропорта по названию. Токен не нужен. |
search_flights | Самые дешёвые билеты по маршруту на дату или месяц. |
price_calendar | Минимальная цена по дням месяца и три самых дешёвых дня. |
cheapest_destinations | Самые дешёвые направления из города, с потолком цены. |
Токен
Бесплатный токен: 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
Comments
New to MCP?
From what the protocol is to installing your first server, these answers cover most first questions.
An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.