Skip to main content
Glama

ads_campaign_analytics

Read-onlyIdempotent

Live performance report for one campaign over a date range. Returns { id, kind, platform, currency, range, summary, daily: [...], breakdowns, unsupported_breakdowns, cached }; summary and each daily row carry the full metric set (spend, impressions, reach, clicks, ctr, cpc, cpm, conversions, roas, video metrics, ...). A repeat within 5 seconds returns the previous answer with cached: true. For many objects at once use ads_insights.

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": "ads_campaign_analytics"
  }
}

Input Schema

NameRequiredDescriptionDefault
toNoEnd date, YYYY-MM-DD. Defaults to today.
fromNoStart date, YYYY-MM-DD. Defaults to 30 days ago. At most 37 months back.
breakdownsNoSplit the metrics by these dimensions. Meta only; ones the network does not offer come back in unsupported_breakdowns.
campaign_idYesCampaign id: the Postproxy id (id field of a campaign), not the network's platform_id
profile_group_idNoProfile group hashid, to scope the call to one profile group. Usually not needed.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.3/5.0
Behavior3/5

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

Annotations already cover safety (readOnlyHint, idempotentHint, destructiveHint=false, openWorldHint=false), so the bar is lower. The description still adds real value beyond them: the exact response envelope, the full metric set carried by summary and daily rows, the unsupported_breakdowns fallback, and the 5-second cache behavior where a repeat returns cached: true. That caching detail is a genuine behavioral disclosure an agent would otherwise misread as fresh data.

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?

Front-loaded with the one-line purpose, then the return shape, then two edge-case behaviors (caching, sibling routing). The metric list is compressed into a parenthetical with an ellipsis rather than enumerated in full, so there is no padding.

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, so the description must carry the return-value burden, and it does — naming every top-level field and noting that summary and each daily row share the metric set. Combined with the cache caveat and the breakdown fallback field, an agent has enough to call it and interpret the response without additional docs.

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?

Schema description coverage is 100%, so the baseline is 3, and the description goes somewhat beyond by explaining that breakdowns the network does not offer surface in unsupported_breakdowns rather than failing. It does not clarify the campaign_id vs platform_id distinction or the from/to window limits, but those are already well documented in the schema.

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?

States a specific verb and resource — a live performance report for ONE campaign over a date range — and immediately scopes it against the aggregate alternative (ads_insights for many objects). The single-campaign scope distinguishes it from the ad-level and ad-set-level analytics siblings without opening their schemas.

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?

Gives an explicit routing rule: 'For many objects at once use ads_insights.' That covers the main fork, but there is no guidance on when to prefer this over ads_ad_analytics or ads_ad_set_analytics for the same campaign, and no prerequisites or caveats on when a campaign-level report is insufficient.

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.