Skip to main content
Glama

Get campaign stats

get_campaign_stats
Read-only

How a campaign is doing over a range of UTC days (the last 30 by default): sends, deliveries, opens, clicks, replies, bounces, complaints and unsubscribes in total, per step and per day, the rates, clicks per link, and how many people are in it and why they left. Counts land on the day each email was sent. Stats are folded about once a minute.

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_stats"
  }
}

Input Schema

NameRequiredDescriptionDefault
to_dayNoYYYY-MM-DD, UTC.
from_dayNoYYYY-MM-DD, UTC.
campaign_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4/5.0
Behavior4/5

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

Annotations already establish readOnlyHint=true and openWorldHint=false, so the safety profile is covered. The description adds genuinely non-obvious behavior beyond that: the default 30-day window, that day bucketing attributes counts to the send date rather than the event date, and that aggregation lags roughly one minute, which matters for interpreting near-real-time results.

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?

Front-loaded with the core answer and tightly written with no filler; the two trailing sentences on send-date attribution and one-minute folding each carry distinct, load-bearing information. The opening sentence is long and list-heavy, but every enumerated metric earns its place given there is no output schema.

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 must describe the return payload, and it does so thoroughly: metric set, per-step and per-day breakdowns, rates, link-level clicks, and audience counts with exit reasons. Only minor gaps remain, such as whether the response paginates or how very large day ranges behave, which an agent could reasonably want to know.

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 coverage is 67%, with only a bare type for campaign_id, so the description carries some burden. It states the range is in UTC days and defaults to the last 30 days, adding real meaning on top of the schema's 'YYYY-MM-DD, UTC' hints for from_day and to_day and implicitly framing campaign_id as the scoping key.

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 resource (campaign) and enumerates exactly what the response contains: sends, deliveries, opens, clicks, replies, bounces, complaints, unsubscribes, rates, clicks per link, and enrollment/exit counts, broken out per step and per day. It is clearly distinct from get_campaign (settings) and get_broadcast_stats by the 'campaign' scope, though it never explicitly names those siblings to sharpen the boundary.

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?

Usage is implied rather than stated: a default window ('the last 30 by default') and a warning that 'stats are folded about once a minute' hint at when this is appropriate and how fresh the numbers are. There is no explicit guidance on when to prefer this over get_campaign_readiness, list_email_events, or get_broadcast_stats for broadcast objects, so the agent must infer the routing.

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