Skip to main content
Glama
Pavelsiba

yandex-direct-mcp-plus

by Pavelsiba

Минус-фразы кампании

set_campaign_negative_keywords
Destructive

Set campaign-level negative keywords in Yandex.Direct by replacing, adding, or removing phrases via required mode; use add to append without overwriting existing terms.

Instructions

Минус-фразы на уровне кампании. Режим mode обязателен: replace заменяет список целиком (прежние фразы теряются, пустой массив очищает), add дописывает к текущим, remove убирает названные — читать список перед этим не нужно, add и remove делают это сами. Чтобы добавить фразу к существующим, нужен add: replace с одной фразой сотрёт остальные.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modeYesОбязателен. replace — заменить список целиком (пустой массив очищает, прежние фразы теряются), add — дописать к текущим, remove — убрать перечисленные. add и remove сначала читают текущий список, это дополнительный вызов API. Фразы сравниваются так же, как их сравнивает Директ: без учёта регистра, буквы ё и е равны, краевые и повторные пробелы не учитываются, операторы закрепления ! и + игнорируются
dry_runNotrue — ничего не менять: проверить параметры и вернуть тела запросов, которые ушли бы в Директ. Чтение при этом выполняется.
campaign_idYesID кампании
negative_keywordsYesМинус-фразы кампании: при mode=replace — полный новый список взамен прежнего, при add — что дописать, при remove — что убрать

Schema Changelog

Changes observed during successful MCP inspections.

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

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already declare destructiveHint=true and readOnlyHint=false, and the description reinforces this with concrete consequences ('прежние фразы теряются', 'пустой массив очищает'). It adds real value beyond the annotation flags, though it does not discuss permissions or rate limits.

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-loads the resource and scope, then concentrates on mode semantics. Slightly repetitive with the schema's mode description, but every sentence is relevant and no filler.

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 destructive mutation tool with annotations and no output schema, the description covers mode behavior, data loss, and the read-before-write nuance well. Permissions/response details are not covered but are not critical here.

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 coverage is 100% and the schema description already documents each mode exhaustively, so the baseline is 3. The description's mode explanation largely restates the schema, adding only the worked example about a single-phrase replace.

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?

States a specific verb+resource (setting campaign-level negative keywords) and scopes it with 'на уровне кампании', which distinguishes it from the ad-group sibling. It does not name the alternative tool explicitly, so it falls just short of a 5.

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?

Explicitly distinguishes replace vs add vs remove, tells the agent it need not pre-read the list, and warns that replace with one phrase erases the rest and that add is required to append. The condition selecting each mode is spelled out, so nothing is left to inference.

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