Skip to main content
Glama

Fama

Create autopilot rule

create_autopilot_rule

Turns a standing order the person describes into an autopilot rule, checked every hour. It is saved in DRY RUN: it records what it would do but changes nothing until the person switches it to live on the Autopilot screen. The result shows what it would match right now; tell them. level: campaign, adset or ad. window_days: 1 (today), 3, 7, 14 or 30, always including today. conditions (all must hold, 1 to 4): metric is one of spend, impressions, link_clicks, link_ctr (percent), cpc, cpm, frequency, landing_page_views, purchases, cpa, roas, results and cost_per_result (results by each campaign's own goal); op is gt, gte, lt, lte or eq; money values in the account currency's major units (200 means R200.00). A cost metric never matches something with no results, so 'spent R200 and no purchases' is spend gte 200 plus purchases eq 0. A rule judging a cost or a rate must also have a floor (spend, impressions or link clicks at least something), or it is refused. action: pause, alert (no change), lower_budget or raise_budget with percent 5 to 50 (budget rules only at campaign or adset level; raises only where the person allowed autopilot to raise in Settings). cooldown_hours (default 24) is how often it may act on the same thing. Ask the person for any number they did not give.

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>",
      "level": "<level>",
      "window_days": "<window_days>",
      "conditions": "<conditions>",
      "action": "<action>"
    },
    "name": "create_autopilot_rule"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYes
levelYes
actionYes
percentNoFor lower_budget and raise_budget.
conditionsYes
window_daysYes
name_containsNoOnly things whose name contains this text.
cooldown_hoursNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Despite annotations already declaring it non-destructive and open-world, the description adds critical behavior: the rule is saved in DRY RUN, records but changes nothing until switched live on the Autopilot screen, and is evaluated every hour. It also discloses refusal rules (a cost or rate rule without a floor is refused) and constraints on budget actions and raise permissions, which no structured field conveys.

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?

The most decision-relevant fact, the dry-run save, is front-loaded, and length is justified by the tool's complexity. However, it is delivered as one dense run-on block where parameter semantics and validation rules interleave, making it harder to scan than a lightly structured version would be.

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?

For an 8-parameter creation tool with no output schema, the definition covers the essential ground: what is created, that it is inert until switched live, what the result shows, and the validation constraints that cause rejection. An agent has enough to construct a valid call and set expectations with the person.

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

Parameters4/5

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

With only 25% schema description coverage, the description carries the burden well: it explains level values, window_days including 'always including today,' the meaning of each metric (link_ctr as percent, results by each campaign's goal), money in major currency units, the floor requirement for cost/rate rules, percent range 5-50, and cooldown_hours default 24. It omits the cooldown_hours bounds (6-168) and says nothing about the name or name_contains parameters.

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 description opens with a specific verb and resource: it 'turns a standing order the person describes into an autopilot rule, checked every hour.' The dry-run framing makes it unmistakable that this creates a rule object rather than a live change, distinguishing it from mutation siblings like pause or set_daily_budget.

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?

The trigger condition is clear: use this when a person describes a standing order that should be evaluated hourly, and tell them what it would match right now. There is no explicit when-not guidance and no named alternative (e.g., a one-off pause), so it stops short of full routing guidance.

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