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

yandex-direct-mcp-plus

by Pavelsiba

Изменить стратегию кампании

set_strategy
Idempotent

Configure a Yandex.Direct text campaign's search and network bidding strategy, including manual, max clicks, average CPC/CPA, and pay-per-conversion with budgets and Metrica goals.

Instructions

Изменить стратегию текстово-графической кампании: ручная, максимум кликов, средняя цена клика или конверсии, оплата за конверсию. Цены — в рублях, цель Метрики — goal_id.

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": {
      "campaign_id": "<campaign_id>",
      "search_type": "<search_type>",
      "network_type": "<network_type>"
    },
    "name": "set_strategy"
  }
}

Input Schema

NameRequiredDescriptionDefault
goal_idNoID цели Метрики для AVERAGE_CPA, PAY_FOR_CONVERSION и WB_MAXIMUM_CONVERSION_RATE; для оплаты за конверсию обязателен. Для WB_MAXIMUM_CONVERSION_RATE допустимо служебное 13 — оптимизация по ключевым целям кампании (PriorityGoals); Директ принимает его, только если в PriorityGoals есть цель, кроме 12 «Вовлечённые сессии»; сами цели задаёт set_priority_goals
average_cpaNoСредняя цена конверсии в рублях; обязательна для AVERAGE_CPA
average_cpcNoСредняя цена клика в рублях; обязательна для AVERAGE_CPC
bid_ceilingNoМаксимальная ставка в рублях для WB_MAXIMUM_CLICKS, WB_MAXIMUM_CONVERSION_RATE и AVERAGE_CPA
campaign_idYesID текстово-графической кампании
search_typeYesСтратегия на поиске: HIGHEST_POSITION (ручная), WB_MAXIMUM_CLICKS, WB_MAXIMUM_CONVERSION_RATE (максимум конверсий за недельный бюджет), AVERAGE_CPC, AVERAGE_CPA, PAY_FOR_CONVERSION или SERVING_OFF
network_typeYesСтратегия в сетях: NETWORK_DEFAULT (по настройкам поиска), MAXIMUM_COVERAGE, WB_MAXIMUM_CLICKS, WB_MAXIMUM_CONVERSION_RATE, AVERAGE_CPC, AVERAGE_CPA, PAY_FOR_CONVERSION или SERVING_OFF
conversion_priceNoЦена конверсии в рублях для PAY_FOR_CONVERSION: списывается за конверсию, а не за клик
weekly_spend_limitNoНедельный бюджет в рублях; обязателен для WB_MAXIMUM_CLICKS и WB_MAXIMUM_CONVERSION_RATE, для остальных автостратегий необязателен
network_limit_percentNoДоля расходов в сетях для NETWORK_DEFAULT, проценты

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 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
    • removedInput schema / properties / dry_run
      Removed value: -{
      -  "description": "true — ничего не менять: проверить параметры и вернуть тела запросов, которые ушли бы в Директ. Чтение при этом выполняется.",
      -  "type": "boolean"
      -}
  2. Changed1 schema field changedv1.7.0
    • addedInput schema / properties / dry_run
      Added value: +{
      +  "description": "true — ничего не менять: проверить параметры и вернуть тела запросов, которые ушли бы в Директ. Чтение при этом выполняется.",
      +  "type": "boolean"
      +}
  3. First observedv1.6.1

TDQS

B3.4/5.0
Behavior3/5

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

The annotations already declare the mutation profile (readOnlyHint=false, idempotentHint=true, openWorldHint=true), so the bar is lower, and the description adds the useful conventions that all prices are in rubles and that the Metrika goal is passed as goal_id. It does not say what happens to fields not supplied (e.g. whether an existing weekly budget or network limit is cleared), nor whether the search and network strategies must be consistent, nor anything about API failure modes.

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?

Two short clauses with the resource and the strategy list front-loaded and no filler. It could be slightly better structured by separating the pricing/goal convention from the strategy enumeration, but nothing is wasteful.

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

Completeness3/5

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

For a 10-parameter mutation with coupled conditional requirements across search_type, network_type, and the price fields, the description is thin: it never states that campaign_id, search_type and network_type are mandatory or how the two strategy axes interact. The rich schema and the annotations carry most of the weight, so it is adequate but not complete.

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%, so the schema already explains every parameter, including the ruble units and the goal_id conditions; the description's 'Цены — в рублях, цель Метрики — goal_id' largely restates that. It adds essentially no cross-parameter logic beyond the schema, so baseline 3 is appropriate.

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

Purpose4/5

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

The description states a specific verb and resource ('Изменить стратегию текстово-графической кампании') and enumerates the strategy families the tool can set (manual, max clicks, average CPC/CPA, pay-per-conversion). This clearly separates it from 'get_strategy', but it never names the siblings that touch the same strategy surface, such as 'set_priority_goals' or 'update_campaign', which the schema itself references.

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

Usage Guidelines3/5

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

Usage is only implied by the verb: an agent can infer 'use this to change an existing campaign's bid strategy', but there is no explicit when-to-use, when-not, or pointer to alternatives like get_strategy for reading or set_priority_goals for goal lists. The dependency on priority goals for WB_MAXIMUM_CONVERSION_RATE appears only inside the goal_id schema entry, not in the description.

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