Skip to main content
Glama
yandex-direct-mcp-plus

yandex-direct-mcp-plus

by Pavelsiba

Создать кампанию

create_campaign

Creates a new text-graphic campaign in Yandex.Direct with specified budget, Metrica counters, and attribution model. Use it to set up campaigns for later moderation and activation.

Instructions

Создать новую текстово-графическую кампанию. Бюджет в рублях; счётчики Метрики и модель атрибуции задаются сразу. Смарт-баннеры и динамические объявления Директ через API не создаёт с 22.05.2026, единую перфоманс-кампанию этот сервер пока не создаёт: такие кампании заводятся в интерфейсе Директа, дальше их можно читать и править здесь. ⚠️ Тестовой среды у Директа нет: кампания создаётся в боевом аккаунте. Деньги она начнёт тратить после модерации и включения, поэтому созданную для проверки оставляйте черновиком.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "name": "<name>",
      "start_date": "<start_date>"
    },
    "name": "create_campaign"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYesНазвание кампании
typeNoТип кампании. Через API создаётся только текстово-графическая: смарт-баннеры и динамические объявления Директ через API не создаётTEXT_CAMPAIGN
time_zoneNoЧасовой пояс показов, например Europe/Moscow (по умолчанию). Список — в справочнике list_time_zones; на даты отчётов не влияет, они всегда по Москве
start_dateYesДата начала показов, YYYY-MM-DD
counter_idsNoСчётчики Метрики кампании. Без привязанного счётчика конверсионные стратегии и цели (set_priority_goals) настроить не на что. Директ не проверяет, что счётчик существует и принадлежит аккаунту
daily_budgetNoДневной бюджет в рублях, например 1000 — это 1000 ₽
search_strategyNoСтратегия показов на поиске; SERVING_OFF отключает показы на поискеHIGHEST_POSITION
tracking_paramsNoUTM-разметка, дописывается к ссылкам всех объявлений кампании. Без ведущего «?»: utm_source=yandex&utm_campaign={campaign_id}. Допустимы подстановки Директа в фигурных скобках. null снимает разметку
network_strategyNoСтратегия показов в сетях (РСЯ); SERVING_OFF отключает показы в сетяхSERVING_OFF
attribution_modelNoМодель атрибуции конверсий кампании: FC — первый переход, LC — последний, LSC — последний значимый, LYDC — последний переход из Яндекса; CD в конце — кросс-девайс; AUTO — автоматическая

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changedv2.1.0
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • addedInput schema / additionalProperties
      Added value: +false
    • addedInput schema / properties / attribution_model
      Added value: +{
      +  "description": "Модель атрибуции конверсий кампании: FC — первый переход, LC — последний, LSC — последний значимый, LYDC — последний переход из Яндекса; CD в конце — кросс-девайс; AUTO — автоматическая",
      +  "enum": [
      +    "AUTO",
      +    "FC",
      +    "FCCD",
      +    "LC",
      +    "LSC",
      +    "LSCCD",
      +    "LYDC",
      +    "LYDCCD"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / counter_ids
      Added value: +{
      +  "description": "Счётчики Метрики кампании. Без привязанного счётчика конверсионные стратегии и цели (set_priority_goals) настроить не на что. Директ не проверяет, что счётчик существует и принадлежит аккаунту",
      +  "items": {
      +    "description": "ID счётчика Метрики",
      +    "pattern": "^[1-9]\\d*$",
      +    "type": "string"
      +  },
      +  "minItems": 1,
      +  "type": "array"
      +}
    • removedInput schema / properties / dry_run
      Removed value: -{
      -  "description": "true — ничего не менять: проверить параметры и вернуть тела запросов, которые ушли бы в Директ. Чтение при этом выполняется.",
      -  "type": "boolean"
      -}
  2. Changed4 schema fields changedv1.7.0
    • addedInput schema / properties / dry_run
      Added value: +{
      +  "description": "true — ничего не менять: проверить параметры и вернуть тела запросов, которые ушли бы в Директ. Чтение при этом выполняется.",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / type / const
      Added value: +"TEXT_CAMPAIGN"
    • changedInput schema / properties / type / description
      Previous value: -"Тип кампании: текстово-графическая или динамические объявления"New value: +"Тип кампании. Через API создаётся только текстово-графическая: смарт-баннеры и динамические объявления Директ через API не создаёт"
    • removedInput schema / properties / type / enum
      Removed value: -[
      -  "TEXT_CAMPAIGN",
      -  "DYNAMIC_TEXT_CAMPAIGN"
      -]
  3. First observedv1.6.1

TDQS

A4.1/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations only declare readOnlyHint=false and openWorldHint=true; the description adds genuinely important behavior: no sandbox exists, the campaign is created in the live account, and it begins spending money only after moderation and enabling. That is real value beyond the annotations. However it says nothing about the resulting campaign state (draft vs. moderated) or what identifier comes back, so a caller cannot plan the follow-up call from this text.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core action, then the API limitations, then the production/money hazard, so the most consequential information is not buried. Sentences are dense but each carries a distinct fact; only the length of the limitation sentence slightly blurs the read.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a ten-parameter mutating tool with no output schema, the description covers the biggest risk (irreversible production creation and spend) and the campaign-type restrictions. The remaining gap is the return value — the created campaign's ID/state — which the agent needs to chain into set_strategy or update_campaign, and no output schema exists to supply it.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100% and all ten parameters already carry descriptions, including units, enum semantics, and the Yandex Direct substitution syntax for tracking_params. The description only restates that budget is in rubles and that counters and attribution model are set at creation time, adding no syntax or constraint detail beyond the schema. Baseline 3 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ("Создать новую текстово-графическую кампанию") and immediately narrows scope: only text-graphic campaigns can be created via API, smart banners and dynamic ads cannot, and unified performance campaigns must be created in the Direct UI. An agent can distinguish this from update_campaign/manage_campaigns without opening a schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives explicit when-not-to-use cases (smart banners, dynamic ads, unified performance campaigns) and names the alternative path (create in the Direct interface, then read/edit here). It also tells the caller to leave test campaigns as drafts, which is actionable usage guidance rather than background prose.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.