Skip to main content
Glama

Get campaign performance

get_campaign_metrics
Read-only

Spend, impressions, clicks, conversions, CTR, CPC, CPA and ROAS for one campaign over a window, broken down per ad network plus a total. Use this to answer how a campaign is performing, which network is cheapest or most expensive per conversion, or where spend went. Figures are what each network itself reported.

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

Input Schema

NameRequiredDescriptionDefault
daysNoLook-back window in days.
campaign_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already cover safety (readOnlyHint=true, destructiveHint=false, openWorldHint=false), so the description's main contribution is the provenance caveat that figures are 'what each network itself reported,' which warns the agent about cross-network attribution inconsistencies. It also discloses the per-network-plus-total output shape, which annotations cannot convey. It does not mention latency, data freshness, or handling of networks with zero activity.

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?

Three sentences, front-loaded with the metric list and output grain, then the use cases, then the provenance caveat that qualifies all the numbers. No filler and no repetition of the title or annotations.

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?

With no output schema, the description correctly carries the burden of describing the return shape (metrics broken down per network plus a total). For a two-parameter read tool this is nearly complete; the remaining gap is the undocumented campaign_id and the absence of units/currency or freshness expectations for the reported figures.

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 50%: days is fully documented in the schema with default 30 and range 1-365, while campaign_id has no description at all. The description's phrase 'over a window' reinforces days but adds nothing beyond the schema, and it does not clarify the campaign_id format or whether the default window applies when days is omitted. Baseline 3 is appropriate with this coverage.

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 names a precise verb and resource and enumerates the exact metrics returned (spend, impressions, clicks, conversions, CTR, CPC, CPA, ROAS), along with the aggregation grain: per ad network plus a total for a single campaign. That level of specificity makes it unmistakable against config-oriented siblings such as get_campaign or set_campaign_budget without needing to name them.

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?

It gives three concrete question shapes the tool answers: overall campaign performance, per-network cost efficiency per conversion, and spend distribution. That is clear positive guidance, but there is no explicit when-not guidance (for example, that campaign configuration questions belong to get_campaign or that multi-campaign comparisons are out of scope).

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