Skip to main content
Glama

Execute an action

execute_action
Destructive

Run one action returned by list_actions. Mutating and open-world.

Only run the action the user explicitly asked for — this may write to an external ad platform, third-party app, or Porter destination, or spend generation quota (creative image/video/voice actions). Pass the action id from list_actions, the params conforming to its params_schema, and — when the action requires_account — the account_id from list_accounts (verbatim). Returns a fixed envelope: status (success|error), result, message, knowledge (related KB entries you can open with get_knowledge), and an optional follow_up.

display (optional) says how the result should be SHOWN in clients that render the result widget; it never changes what the action does. Omit it and the widget picks a view from the payload — a generated video gets a player and a download button, ads with images get a grid, rows get a table. Set it when the user asked for a particular view, or when you know the payload's shape better than a guess would: {"mode": "text|table|kv|grid|masonry|carousel|gallery|video|image|json", "title": "Top ads", # header "items": "data.ads", # dot-path to the list to render "fields": {"image": "thumb", "title": "name", "subtitle": "status", "badge": "objective", "link": "permalink", "meta": ["cpa", "ctr"]}, "columns": ["name", "cpa"], # table columns, in order "page_size": 24} Use carousel to browse creative one at a time, masonry for mixed-height images, grid for a scannable set, gallery for image-only sets, table/columns to compare numbers, text for a plain answer.

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>"
    },
    "name": "execute_action"
  }
}

Input Schema

NameRequiredDescriptionDefault
actionYes
paramsNo
displayNo
account_idNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.7/5.0
Behavior5/5

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

Annotations already declare destructiveHint=true, openWorldHint=true, and non-idempotent, but the description goes well beyond them by naming concrete side effects: writes to an external ad platform or third-party app, and consumption of generation quota for image/video/voice actions. It also documents the fixed response envelope (`status`, `result`, `message`, `knowledge`, `follow_up`) in the absence of an output schema.

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?

Purpose, side effects, and parameter sourcing are front-loaded in the first paragraph, and the `display` block is dense but functional. The tradeoff is that the display section occupies roughly half the text, which is justified only because a bare nested object with 0% schema coverage would otherwise be unusable.

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

Completeness5/5

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

No output schema exists, and the description compensates by enumerating the return envelope fields. For a destructive, open-world four-parameter tool, all critical decision inputs — side effects, prerequisite tool chain, conditional account requirement, and result shape — are present.

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

Parameters5/5

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

Schema description coverage is 0%, so the description carries the full burden and does so: it explains where `action` comes from, that `params` must conform to the action's `params_schema`, that `account_id` is required only when the action `requires_account` and must be passed verbatim, and it fully specifies the optional `display` object's modes, dot-path `items`, `fields`, `columns`, and `page_size`.

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?

The opening sentence states a specific verb and resource ('Run one action returned by `list_actions`'), immediately scoping it against the sibling that enumerates actions. It also flags the mutation and open-world character up front, so an agent knows exactly what class of operation this is before opening the schema.

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

Usage Guidelines4/5

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

There is an explicit precondition ('only run the action the user explicitly asked for') and a clear chain of prerequisites: the `action` id comes from `list_actions`, `params` from its `params_schema`, and `account_id` from `list_accounts` when `requires_account`. It also gives when-to-set guidance for `display` ('when the user asked for a particular view') and when to omit it. The gap is that it never differentiates from the `read_action` sibling for inspection-only cases.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources