# yandex-direct-mcp [Health: Active]

**Category:** 🎯 Marketing  
**Repository:** https://github.com/theYahia/yandex-direct-mcp  
**GitHub Stars:** 4  
**npm Downloads (last month):** 324  
**Views:** 1  
**Installs:** 0  
**Upvotes:** 0  
**Directory Page:** https://allmcps.com/mcp/yandex-direct-mcp-2

## Description
MCP server for Yandex.Direct API — campaigns, ads, statistics, keywords. Bearer token auth.

## Tools
Capabilities this server exposes over MCP:

- **list_campaigns** — Список рекламных кампаний Яндекс.Директ с фильтрацией по статусу и типу. Бюджеты — в рублях.
- **get_campaign** — Детальная информация о кампании по ID: бюджет (руб), статус, даты, статистика.
- **create_campaign** — Создать новую рекламную кампанию. Бюджет в рублях. ⚠️ Тратит реальные деньги — используйте sandbox для теста.
- **update_campaign** — Обновить кампанию: название, бюджет (руб) и/или статус (SUSPEND/RESUME/ARCHIVE/UNARCHIVE).
- **list_ad_groups** — Группы объявлений выбранных кампаний: названия, регионы, статусы.
- **create_ad_group** — Создать группу объявлений в кампании с таргетингом по регионам (см. get_regions).
- **delete_ad_groups** — Удалить группы объявлений по их ID. ⚠️ Необратимо.
- **list_ads** — Объявления в группах: заголовки, тексты, ссылки, статусы.
- **create_text_ad** — Создать текстовое объявление: заголовок (≤56), второй заголовок (≤30), текст (≤81), ссылка.
- **update_text_ad** — Обновить текстовое объявление: заголовок, текст, ссылка. Изменённое объявление уходит на модерацию.
- **manage_ads** — Действие над объявлениями: suspend/resume/archive/unarchive/moderate/delete. ⚠️ delete необратимо.
- **list_keywords** — Ключевые фразы в группах объявлений: фразы, ставки (руб), статусы.
- **add_keywords** — Добавить ключевые фразы в группу объявлений.
- **set_keyword_bids** — Установить ставки (поиск/сети, в рублях) на уровне фраз, групп или кампаний (сервис Bids).
- **manage_keywords** — Действие над ключевыми фразами: suspend/resume/delete. ⚠️ delete необратимо.
- **set_campaign_negative_keywords** — Задать минус-фразы на уровне кампании (заменяет текущий список; пустой массив очищает).
- **set_ad_group_negative_keywords** — Задать минус-фразы на уровне группы объявлений (заменяет текущий список; пустой массив очищает).
- **get_statistics** — Статистика кампаний за период: показы, клики, расход (руб), CTR, CPC (ReportService, TSV).
- **get_account_balance** — Баланс и финансовая информация аккаунта (Amount, Currency) через Live API v4.
- **get_regions** — Справочник кодов регионов (GeoRegions) для таргетинга. Фильтр по названию. 225 = Россия.

## Claude Desktop Quick Installation
Install path detected from listing signals. Uses `npx` (confidence: high):

```json
"mcpServers": {
  "yandex-direct-mcp": {
    "command": "npx",
    "args": ["-y","@theyahia/yandex-direct-mcp"],
    "env": {
      "YANDEX_DIRECT_TOKEN": "",
      "YANDEX_DIRECT_SANDBOX": "",
      "YANDEX_DIRECT_LOGIN": ""
    }
  }
}
```

**Requires environment variables:** `YANDEX_DIRECT_TOKEN`, `YANDEX_DIRECT_SANDBOX`, `YANDEX_DIRECT_LOGIN` — the values above are empty placeholders; fill in real credentials before running (see the repository for what each one is for).

## Documentation

## What yandex-direct-mcp MCP server does

yandex-direct-mcp MCP server exposes Yandex.Direct advertising operations through the Model Context Protocol. It supports campaign management, ad group organization, text ad editing, keyword maintenance, bid changes, negative phrases, reporting, account balance checks, and regional reference data.

The server includes 20 tools. Campaign tools can list, inspect, create, and update campaigns, including budget, strategy, name, and lifecycle status. Ad group tools cover listing, creation with regional targeting, deletion, and group-level negative phrases. Ad tools list ads, create and update text ads, and apply actions such as suspend, resume, archive, unarchive, moderate, or delete.

Keyword tools list and add phrases, set search and network bids, change keyword status, remove keywords, and assign campaign-level negative phrases. Reporting returns impressions, clicks, spend, CTR, and CPC for a selected period. Other tools return the account balance through Live API v4 and look up region codes.

## How it works

An MCP client starts the server and invokes its tools against Yandex.Direct. Requests use a bearer OAuth token supplied through the environment. Amounts entered for budgets and bids use rubles; the server converts those values to the API's micro-units and converts returned monetary values back to rubles.

The available operations include both read-only queries and mutations. Listing and reporting calls can inspect existing account data, while campaign creation, ad creation, keyword additions, bid changes, and status actions can alter the account. The README specifically warns that several mutation tools may spend real money when used against a production account.

## Setup and configuration

Install and run the package with `npx -y @theyahia/yandex-direct-mcp`. For Claude Desktop, add a server entry whose command is `npx`, whose argument is `-y @theyahia/yandex-direct-mcp`, and whose environment contains `YANDEX_DIRECT_TOKEN`. Claude Code can register the same command with `claude mcp add`.

The required `YANDEX_DIRECT_TOKEN` must be an OAuth token issued for an application registered with Yandex OAuth and authorized for the Direct API. API access also needs to be requested in the Yandex.Direct interface. Set `YANDEX_DIRECT_SANDBOX=1` to use isolated sandbox data without spending money. Set `YANDEX_DIRECT_LOGIN` when using an agent token that requires the `Client-Login` header.

## Tools and capabilities

The yandex-direct-mcp MCP server provides these capability groups:

- Campaign listing, inspection, creation, budget and status updates
- Ad group creation, deletion, regional targeting, and negative phrases
- Text ad creation and updates, plus moderation and lifecycle actions
- Keyword addition, status management, negative phrases, and bids
- Period-based performance statistics and account balance retrieval
- Region code lookup for geographic targeting

## Limitations and notes

Production mutations can change a live advertising account and may incur charges. Use the sandbox while developing or testing agent workflows. The sandbox uses isolated data and a different API URL, but the same token setting is used.

Text ad creation accepts limits of 56, 30, and 81 characters for its respective text fields, as specified by the project. Bid and budget inputs are expressed in rubles rather than the API's underlying micro-units. Agent-token users must provide the client login in addition to the bearer token.

_Full upstream README: https://allmcps.com/mcp/yandex-direct-mcp-2/readme_

