Ruby MCP Server

Manage
Yandex Direct
via chat

MCP server connects Yandex Direct to AI assistants. Create campaigns, write ads, and analyze results right in Claude Code.

30
Tools
6
API Services
0
Dependencies
MIT
License
claude code
> Show my campaigns

Found 1 campaign:
ID: 708319023
Name: Book «Autopsy Will Show» — author.today
Status: Draft
Budget: 1,714 KZT/day
Keywords: 18

Full control over advertising

Everything you need to manage Yandex Direct campaigns — from creation to analytics

6 tools

Campaigns

Create, edit, pause, and resume ad campaigns with budget and negative keyword settings

4 tools

Ad Groups

Geo-targeting by regions, cities, and countries. Group-level negative keywords

7 tools

Ads

Text and image ads with titles, copy, and links. Submit for moderation

6 tools

Keywords

Add, update, and manage keywords. Pause and resume impressions

3 tools

Reports

Campaign, ad, and search query statistics: impressions, clicks, spend, CTR

4 tools

Dictionaries

Regions for geo-targeting, currencies, audience interests, and other reference data

Setup in 5 minutes

Connect the MCP server to Claude Code and start managing your ads

1

Create an OAuth app

Register an app at oauth.yandex.ru with Yandex Direct API access permissions

2

Apply for API access

In Yandex Direct go to Tools → API → My Applications. The API starts working right after submission

3

Get an OAuth token

Authorize via OAuth and copy the token from the address bar

4

Add the config

Copy the MCP server config into your project's .mcp.json or the global ~/.claude.json

5

Done!

Restart Claude Code — all 30 tools are available via chat

.mcp.json
{
  "mcpServers": {
    "yandex-direct": {
      "command": "ruby",
      "args": ["path/to/bin/server"],
      "env": {
        "YANDEX_DIRECT_TOKEN": "your_token"
      }
    }
  }
}

30 Tools

Complete toolkit for managing ad campaigns

Tool Description Type
campaigns_getList campaigns with filteringread
campaigns_addCreate a campaign with budgetwrite
campaigns_updateUpdate parameterswrite
campaigns_suspendPause impressionswrite
campaigns_resumeResume impressionswrite
campaigns_deleteArchive campaignsdelete
adgroups_getAd groupsread
adgroups_addCreate with geo-targetingwrite
ads_getList adsread
ads_addCreate an adwrite
ads_moderateSubmit for moderationwrite
keywords_getKeywordsread
keywords_addAdd keywordswrite
report_campaignCampaign statisticsread
report_search_queriesSearch queriesread
dictionaries_regionsRegions directoryread
dictionaries_interestsAudience interestsread