Bun-based Yandex Direct MCP with Unified Performance and Click.ru proxy
Yandex Direct MCP
A Bun-based Direct API v5 MCP server with 50 tools, Unified Performance support, and connection via your own token or a Click.ru proxy with no OAuth
High risk
We rate an entry high when the tool writes to external systems, handles money, production databases or secrets, or runs arbitrary commands. The CLI installs it only with your consent.
Why this level
- Creates and changes campaigns, including Unified Performance ones, with a real budget
- Forecasts and changes bids, which directly affects spend
Install
In your terminal, with SkillFoxx CLI
npx skillfoxx add mcp/alexf81xxx-yandex-direct-mcpDetects the agents on your machine, checks the risk and pins the version.
Other ways to install
This entry is high risk, so there is no one-click install. Review the code and add the config by hand.
Run in a terminal
claude mcp add --transport stdio yandex-direct-mcp -- npx -y @ai-hub-open/yandex-direct-mcp@0.5.0Or add to the file .mcp.json, in the project
{
"mcpServers": {
"yandex-direct-mcp": {
"command": "npx",
"args": [
"-y",
"@ai-hub-open/yandex-direct-mcp@0.5.0"
]
}
}
}If the file already exists, add the server inside the mcpServers key.
Keys and settings
CLICK_RU_PROXYoptional- true — Click.ru proxy mode (primary)
CLICK_RU_TOKENsecret, optional- Click.ru API token
CLICK_RU_CLIENT_LOGINoptional- Yandex Direct account login connected in Click.ru
YANDEX_DIRECT_TOKENsecret, optional- Yandex Direct OAuth token (direct mode)
YANDEX_DIRECT_SANDBOXoptional- true — Yandex sandbox (direct mode only)
Replace the values in angle brackets with your own. Keys never go into install links and are not stored by us.
Add to the file ~/.cursor/mcp.json, for all projects
{
"mcpServers": {
"yandex-direct-mcp": {
"command": "npx",
"args": [
"-y",
"@ai-hub-open/yandex-direct-mcp@0.5.0"
]
}
}
}If the file already exists, add the server inside the mcpServers key. For a single project, put the same block into .cursor/mcp.json.
Keys and settings
CLICK_RU_PROXYoptional- true — Click.ru proxy mode (primary)
CLICK_RU_TOKENsecret, optional- Click.ru API token
CLICK_RU_CLIENT_LOGINoptional- Yandex Direct account login connected in Click.ru
YANDEX_DIRECT_TOKENsecret, optional- Yandex Direct OAuth token (direct mode)
YANDEX_DIRECT_SANDBOXoptional- true — Yandex sandbox (direct mode only)
Replace the values in angle brackets with your own. Keys never go into install links and are not stored by us.
Run in a terminal
code --add-mcp '{"name":"yandex-direct-mcp","type":"stdio","command":"npx","args":["-y","@ai-hub-open/yandex-direct-mcp@0.5.0"]}'Or add to the file .vscode/mcp.json, in the project
{
"servers": {
"yandex-direct-mcp": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@ai-hub-open/yandex-direct-mcp@0.5.0"
]
}
}
}If the file already exists, add the server inside the servers key.
Keys and settings
CLICK_RU_PROXYoptional- true — Click.ru proxy mode (primary)
CLICK_RU_TOKENsecret, optional- Click.ru API token
CLICK_RU_CLIENT_LOGINoptional- Yandex Direct account login connected in Click.ru
YANDEX_DIRECT_TOKENsecret, optional- Yandex Direct OAuth token (direct mode)
YANDEX_DIRECT_SANDBOXoptional- true — Yandex sandbox (direct mode only)
Replace the values in angle brackets with your own. Keys never go into install links and are not stored by us.
Run in a terminal
codex mcp add yandex-direct-mcp -- npx -y @ai-hub-open/yandex-direct-mcp@0.5.0Or add to the file ~/.codex/config.toml, for all projects
[mcp_servers.yandex-direct-mcp]
command = "npx"
args = ["-y", "@ai-hub-open/yandex-direct-mcp@0.5.0"]If the file already exists, append the block to the end.
Keys and settings
CLICK_RU_PROXYoptional- true — Click.ru proxy mode (primary)
CLICK_RU_TOKENsecret, optional- Click.ru API token
CLICK_RU_CLIENT_LOGINoptional- Yandex Direct account login connected in Click.ru
YANDEX_DIRECT_TOKENsecret, optional- Yandex Direct OAuth token (direct mode)
YANDEX_DIRECT_SANDBOXoptional- true — Yandex sandbox (direct mode only)
Replace the values in angle brackets with your own. Keys never go into install links and are not stored by us.
Add to the file ~/.gemini/settings.json, for all projects
{
"mcpServers": {
"yandex-direct-mcp": {
"command": "npx",
"args": [
"-y",
"@ai-hub-open/yandex-direct-mcp@0.5.0"
]
}
}
}If the file already exists, add the server inside the mcpServers key.
Keys and settings
CLICK_RU_PROXYoptional- true — Click.ru proxy mode (primary)
CLICK_RU_TOKENsecret, optional- Click.ru API token
CLICK_RU_CLIENT_LOGINoptional- Yandex Direct account login connected in Click.ru
YANDEX_DIRECT_TOKENsecret, optional- Yandex Direct OAuth token (direct mode)
YANDEX_DIRECT_SANDBOXoptional- true — Yandex sandbox (direct mode only)
Replace the values in angle brackets with your own. Keys never go into install links and are not stored by us.
Add to the file ~/.config/devin/mcp_config.json, for all projects
{
"mcpServers": {
"yandex-direct-mcp": {
"command": "npx",
"args": [
"-y",
"@ai-hub-open/yandex-direct-mcp@0.5.0"
]
}
}
}If the file already exists, add the server inside the mcpServers key. Legacy Cascade keeps the MCP config in ~/.codeium/windsurf/mcp_config.json.
Keys and settings
CLICK_RU_PROXYoptional- true — Click.ru proxy mode (primary)
CLICK_RU_TOKENsecret, optional- Click.ru API token
CLICK_RU_CLIENT_LOGINoptional- Yandex Direct account login connected in Click.ru
YANDEX_DIRECT_TOKENsecret, optional- Yandex Direct OAuth token (direct mode)
YANDEX_DIRECT_SANDBOXoptional- true — Yandex sandbox (direct mode only)
Replace the values in angle brackets with your own. Keys never go into install links and are not stored by us.
Formerly Windsurf.
Add to the file cline_mcp_settings.json, for all projects
{
"mcpServers": {
"yandex-direct-mcp": {
"command": "npx",
"args": [
"-y",
"@ai-hub-open/yandex-direct-mcp@0.5.0"
]
}
}
}If the file already exists, add the server inside the mcpServers key. Open the settings file in Cline: MCP Servers tab, Configure MCP Servers.
Keys and settings
CLICK_RU_PROXYoptional- true — Click.ru proxy mode (primary)
CLICK_RU_TOKENsecret, optional- Click.ru API token
CLICK_RU_CLIENT_LOGINoptional- Yandex Direct account login connected in Click.ru
YANDEX_DIRECT_TOKENsecret, optional- Yandex Direct OAuth token (direct mode)
YANDEX_DIRECT_SANDBOXoptional- true — Yandex sandbox (direct mode only)
Replace the values in angle brackets with your own. Keys never go into install links and are not stored by us.
Add to the file .roo/mcp.json, in the project
{
"mcpServers": {
"yandex-direct-mcp": {
"command": "npx",
"args": [
"-y",
"@ai-hub-open/yandex-direct-mcp@0.5.0"
]
}
}
}If the file already exists, add the server inside the mcpServers key.
Keys and settings
CLICK_RU_PROXYoptional- true — Click.ru proxy mode (primary)
CLICK_RU_TOKENsecret, optional- Click.ru API token
CLICK_RU_CLIENT_LOGINoptional- Yandex Direct account login connected in Click.ru
YANDEX_DIRECT_TOKENsecret, optional- Yandex Direct OAuth token (direct mode)
YANDEX_DIRECT_SANDBOXoptional- true — Yandex sandbox (direct mode only)
Replace the values in angle brackets with your own. Keys never go into install links and are not stored by us.
A fork of Roo Code, same .roo folders.
Add to the file opencode.json, in the project
{
"mcp": {
"yandex-direct-mcp": {
"type": "local",
"command": [
"npx",
"-y",
"@ai-hub-open/yandex-direct-mcp@0.5.0"
]
}
}
}If the file already exists, add the server inside the mcp key.
Keys and settings
CLICK_RU_PROXYoptional- true — Click.ru proxy mode (primary)
CLICK_RU_TOKENsecret, optional- Click.ru API token
CLICK_RU_CLIENT_LOGINoptional- Yandex Direct account login connected in Click.ru
YANDEX_DIRECT_TOKENsecret, optional- Yandex Direct OAuth token (direct mode)
YANDEX_DIRECT_SANDBOXoptional- true — Yandex sandbox (direct mode only)
Replace the values in angle brackets with your own. Keys never go into install links and are not stored by us.
Add to the file ~/.config/zed/settings.json, for all projects
{
"context_servers": {
"yandex-direct-mcp": {
"command": "npx",
"args": [
"-y",
"@ai-hub-open/yandex-direct-mcp@0.5.0"
]
}
}
}If the file already exists, add the server inside the context_servers key.
Keys and settings
CLICK_RU_PROXYoptional- true — Click.ru proxy mode (primary)
CLICK_RU_TOKENsecret, optional- Click.ru API token
CLICK_RU_CLIENT_LOGINoptional- Yandex Direct account login connected in Click.ru
YANDEX_DIRECT_TOKENsecret, optional- Yandex Direct OAuth token (direct mode)
YANDEX_DIRECT_SANDBOXoptional- true — Yandex sandbox (direct mode only)
Replace the values in angle brackets with your own. Keys never go into install links and are not stored by us.
Add to the file .codeassistant/mcp.json, in the project
{
"mcpServers": {
"yandex-direct-mcp": {
"command": "npx",
"args": [
"-y",
"@ai-hub-open/yandex-direct-mcp@0.5.0"
]
}
}
}If the file already exists, add the server inside the mcpServers key.
Keys and settings
CLICK_RU_PROXYoptional- true — Click.ru proxy mode (primary)
CLICK_RU_TOKENsecret, optional- Click.ru API token
CLICK_RU_CLIENT_LOGINoptional- Yandex Direct account login connected in Click.ru
YANDEX_DIRECT_TOKENsecret, optional- Yandex Direct OAuth token (direct mode)
YANDEX_DIRECT_SANDBOXoptional- true — Yandex sandbox (direct mode only)
Replace the values in angle brackets with your own. Keys never go into install links and are not stored by us.
Install dependencies with bun install, set either YANDEX_DIRECT_TOKEN for direct mode or CLICK_RU_PROXY=true with CLICK_RU_TOKEN and CLICK_RU_CLIENT_LOGIN for Click.ru mode in .env, then add src/index.ts as a local stdio MCP server.
Other ways from the author
{
"mcpServers": {
"yandex-direct": {
"command": "bun",
"args": ["run", "/абсолютный/путь/к/yandex-direct-mcp/src/index.ts"],
"env": { "YANDEX_DIRECT_TOKEN": "y0__..." }
}
}
}Direct mode with your own Direct OAuth token.
This is third-party code. Review the repository files before installing.
What it does
This Bun and TypeScript server gives 50 Direct API v5 tools: campaigns including Unified Performance Campaigns with bid strategies and Metrica goals, ad groups, text and combinatorial ads, extensions like sitelinks and callouts, images, bids and click-price forecasting, bid adjustments, keywords, reports and dictionaries. There are two connection modes: direct with your own Yandex Direct OAuth token, or through a Click.ru proxy, using a click.ru profile API token and the login of an account already connected there instead of a Yandex token. It defaults to API version v501, required for Unified Performance. There is an HTTP mode requiring MCP_AUTH_TOKEN, and releases are authorized through a trusted GitHub OIDC publisher with no long-lived secrets.
Who it is for. For people running Unified Performance Campaigns in Direct, or already working through Click.ru, who want to manage ads without getting a separate Yandex OAuth token.
Good fit when
- You need to work with a Unified Performance Campaign, not just a text one
- You already have a Click.ru account and do not want to register a separate Yandex OAuth app
- You need HTTP mode with your own auth token for remote access
Not a fit when
- You have neither your own OAuth token nor a Click.ru account: neither connection mode can be set up without one
- You need a sandbox together with the Click.ru proxy: it only works with production API
- You need guarantees around known sandbox limitations: some operations there are simply unverifiable
Example request
Create a Unified Performance Campaign with a Metrica goal and show the click-price forecast for the keywordsLimitations
The Click.ru proxy only works with the production API; sandbox is unavailable through it. Yandex's own sandbox has confirmed limitations: uploading ads into a group is unverifiable, bidmodifiers.get always returns empty, and the sitelinks service is sometimes unavailable. These are documented and explicitly marked as skipped, not failed, in the e2e tests. HTTP mode requires MCP_AUTH_TOKEN.
How to disable. Remove the yandex-direct block from your project's .mcp.json or stop the server process.
MCP
- Transport
- stdio, http
- Authentication
- API key
| Environment variables | |
|---|---|
| YANDEX_DIRECT_TOKEN secret | Yandex Direct OAuth token for direct mode |
| CLICK_RU_PROXY | true enables the Click.ru proxy mode instead of a direct token |
| CLICK_RU_TOKEN secret | API token from the click.ru profile |
| MCP_AUTH_TOKEN secret | Required in HTTP mode to authorize clients |
Security check
- Creates and changes campaigns, including Unified Performance ones, with a real budget
- Forecasts and changes bids, which directly affects spend
README in short
The README gives two independent setup blocks: direct mode with YANDEX_DIRECT_TOKEN and Click.ru mode with its own variables, run commands for stdio and HTTP modes, a section on network-free mock tests and HTTP transport, and an honest list of known Yandex sandbox limitations reproduced in the e2e tests. It separately describes the release process: versions are checked in three places, and npm and MCP registry publishing goes through a trusted GitHub OIDC publisher.
FAQ
Do I need a Yandex token if I go through Click.ru?
No, in CLICK_RU_PROXY=true mode a click.ru profile API token and the login of a Direct account already connected there replace the Yandex token.
Does the sandbox work through the Click.ru proxy?
No, the proxy only works with Yandex's production API; sandbox is unavailable through it.
Related
A skill that strips AI writing tells from text using Wikipedia's list, without adding invented facts
Marketing Skills for AI agents
Marketing Skills for AI Agents
About fifty skills for CRO, copywriting, SEO, analytics, ads and launches, built for coding agents
SendPulse MCP server
SendPulse MCP
SendPulse's official remote MCP server: statistics, campaigns and user data through an agent chat
Yandex Direct MCP generated from a machine-readable schema
yandex-direct-mcp
An MCP server and CLI covering all 113 Yandex Direct API v5 methods generated from WSDL, exposing 9 read tools by default and writes only on demand