Skip to main content
Glama
Yandex Direct MCP

Yandex Direct MCP

Действие с объявлениями

ad_action
Destructive

Apply moderation, suspension, resumption, archiving, unarchiving, or deletion to Yandex Direct ads by ID. Use it to pause, restore, or remove ads in bulk without manual editing.

Instructions

Выполняет действие над объявлениями по id: moderate, suspend, resume, archive, unarchive или delete.

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": {
      "action": "<action>",
      "ids": "<ids>"
    },
    "name": "ad_action"
  }
}

Input Schema

NameRequiredDescriptionDefault
idsYesId объявлений, к которым применить действие. Длинный id (приходит в ответах строкой) передавать строкой как есть.
actionYes
client_loginNoЛогин клиента агентства или кабинета в управлении (из list_clients). Если не указан — YANDEX_DIRECT_LOGIN из конфигурации, а без него собственный аккаунт токена.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changedv1.14.0
    • changedInput schema / properties / ids / description
      Previous value: -"Id объявлений, к которым применить действие."New value: +"Id объявлений, к которым применить действие. Длинный id (приходит в ответах строкой) передавать строкой как есть."
    • addedInput schema / properties / ids / items / anyOf
      Added value: +[
      +  {
      +    "type": "integer"
      +  },
      +  {
      +    "pattern": "^\\d+$",
      +    "type": "string"
      +  }
      +]
    • removedInput schema / properties / ids / items / type
      Removed value: -"integer"
  2. Changed1 schema field changedv1.6.0
    • addedInput schema / properties / client_login
      Added value: +{
      +  "description": "Логин клиента агентства или кабинета в управлении (из list_clients). Если не указан — YANDEX_DIRECT_LOGIN из конфигурации, а без него собственный аккаунт токена.",
      +  "pattern": "^[A-Za-z0-9][A-Za-z0-9._@-]{0,99}$",
      +  "type": "string"
      +}
  3. Changed1 schema field changedv1.5.1
    • changedInput schema / properties / ids / description
      Previous value: -"Ad ids to act on."New value: +"Id объявлений, к которым применить действие."
  4. First observedv0.1.0

TDQS

A3.6/5.0
Behavior3/5

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

Annotations already declare destructiveHint=true, readOnlyHint=false, and idempotentHint=false, so the safety profile is carried by structured data. The description adds the concrete set of operations (including destructive delete/archive), but it does not say what is lost on delete, whether suspend is reversible, or how the API responds to partially invalid id lists.

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

Conciseness5/5

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

A single front-loaded sentence with the verb, resource, keying parameter, and full action enumeration; no filler or redundancy.

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 three-parameter mutation tool with no output schema, the description covers the resource, the keying parameter, and the full action set, which is enough to invoke it correctly. It falls short only on action semantics and result behavior, which are secondary given the annotations and schema.

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 67%, so ids and client_login are partly documented by the schema itself. The description mentions only that the action applies 'по id', adding no detail on client_login's login-resolution fallback or on per-action constraints; the enum values themselves are restated from the schema rather than explained.

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 names a specific verb (выполняет действие) and resource (объявления) and enumerates the six allowed actions, so the agent knows exactly what the tool mutates. It does not differentiate itself from sibling action tools like campaign_action or keyword_action, but the resource scoping is unambiguous.

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?

The enumerated action list implies the contexts in which the tool is used, but there is no explicit when-to-use guidance, no exclusion of alternatives, and no prerequisites (e.g., that the ad must be in a particular state to resume, or that delete is irreversible). Usage must be inferred from the action names.

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