Yandex Direct MCP with dry-run by default
Yandex Direct MCP Server
20 Yandex Direct tools where every edit shows the plan by default and needs confirm=True to actually send anything
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
- With confirm=True it actually creates, pauses and archives campaigns
- Bulk-changes keyword bids with real money
Install
Manual install
{
"mcpServers": {
"yandex-direct": {
"command": "python",
"args": ["/абсолютный/путь/src/server.py"],
"env": { "YD_TOKEN": "ваш_токен", "YDIRECT_ENV": "sandbox" }
}
}
}Local stdio run; start with YDIRECT_ENV=sandbox.
This is third-party code. Review the repository files before installing.
What it does
The server gives 20 Direct API v5 tools split into two groups. Six read tools run with no confirmation: campaigns, groups, ads, keywords, balance and a universal report with async polling. The rest (creating and updating campaigns, pausing and resuming, archiving, and working with groups, ads, keywords and bulk bids) are guarded by dry-run: confirm=False by default, so a call only shows the request plan, and actually sending it needs explicit confirm=True. The server converts amounts out of and back into micro-units itself and polls the async Reports API until the report is ready.
Who it is for. For people who want to manage Yandex Direct through Claude but worry about accidentally spending budget on one wrong phrase.
Good fit when
- You need to find low-CTR keywords and propose bid cuts before changing anything
- You want protection against accidental money-moving actions built into the server itself, not just the client
- You need a report with automatic polling of the async Reports API
Not a fit when
- You want changes applied quickly without the dry-run-then-confirm two-step
- You need Unified Performance Campaigns, display campaigns or Direct Commander: the server only covers text campaigns
- You need an official server from Yandex itself
Example request
Show campaigns with this week's spend, find keywords with CTR below 2% and suggest which bids to lowerLimitations
Every edit needs two calls: first without confirm to check the plan, then with confirm=True to actually send it, which lengthens the flow. One flag, YDIRECT_ENV, switches between sandbox and production. Not an official Yandex product; stdio transport only.
How to disable. Remove the yandex-direct block from your Claude Desktop or Claude Code client config.
MCP
- Transport
- stdio
- Authentication
- API key
| Environment variables | |
|---|---|
| YD_TOKEN required, secret | Yandex Direct OAuth token |
| YDIRECT_ENV | sandbox or production, switches the API environment |
Security check
- With confirm=True it actually creates, pauses and archives campaigns
- Bulk-changes keyword bids with real money
README in short
The README presents the project as an engineering demonstration of a safe agentic interface to money: an architecture diagram covering the dry-run guard, micro-unit conversion and async report polling, a table of 20 tools split into read and dry-run-guarded write, and a section on switching sandbox and production via the YDIRECT_ENV flag.
FAQ
Can Claude accidentally spend budget?
By design, per the README, no: every mutating tool runs dry-run until confirm=True is passed explicitly.
How does the server handle Direct's micro-units?
It converts amounts out of micro-units into regular currency and back itself, so no manual math is needed.
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