Skip to main content
Glama

get_campaign_stats

Read-onlyIdempotent

Quick all-time counters: requests_sent, requests_accepted, replied_count, profiles_touched, plus derived acceptance and reply rates. Pass campaign_id for one campaign; omit it for the whole workspace. For a date range, daily series, breakdowns per sender or campaign, or the reply heatmap use get_dashboard instead. With a campaign_id you can also pass include to add more in the same call, each under its own key next to stats: funnel = the per-step funnel: perStep (cumulative active count per trunk step), perNode (map of step id to active prospects currently sitting AT that node, including nested branch steps), perEnd (map of branch terminal to prospects that FINISHED there, keyed ':<accepted|notAccepted>' or 'trunk') and the terminal totals replied/bounced/paused/completed/total; ab_tests = A/Z test results: steps, one entry per message step under test (2+ variants), each with stepId, type and variants[]. Each variant has id (stable; "a" = the step's primary body, Variant A), index, body, sent, replied, accepted (connection_request only) and retired (true = a removed variant kept only for its history). Bucket by id, not index; reply rate is replied/sent and accept rate accepted/sent. For campaigns with a language setting each variant also has byLanguage ({ "de": {sent, replied, accepted}, "original": {...} }), and translated steps appear even without variants. Empty steps means no step is A/Z testing or translated. Use it to pick and keep the winning variant, and to see which language replies best. Without include the response is just the counters.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "get_campaign_stats"
  }
}

Input Schema

NameRequiredDescriptionDefault
includeNoExtra sections to fetch alongside the counters: funnel, ab_tests. Only with campaign_id.
campaign_idNoCampaign UUID (from list_campaigns). Omit for workspace-wide totals.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • changedInput schema / properties / campaign_id / description
      Previous value: -"Campaign UUID"New value: +"Campaign UUID (from list_campaigns). Omit for workspace-wide totals."
    • addedInput schema / properties / include
      Added value: +{
      +  "description": "Extra sections to fetch alongside the counters: funnel, ab_tests. Only with campaign_id.",
      +  "items": {
      +    "enum": [
      +      "funnel",
      +      "ab_tests"
      +    ],
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
    • removedInput schema / required
      Removed value: -[
      -  "campaign_id"
      -]
  2. First observed

TDQS

A4.8/5.0
Behavior5/5

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

Annotations already cover the read-only/idempotent/non-destructive profile, and the description adds substantial behavior beyond that: the exact response shape, that extra sections land under their own keys next to `stats`, that empty `steps` means no A/Z test or translation, that variants must be bucketed by `id` not `index`, and how rates are computed. This is unusually rich disclosure for a read tool.

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 core purpose and the dashboard alternative are front-loaded, and there is no filler. However, the `include` discussion is a single dense run-on with deeply nested parentheses and quoted key formats, which is harder to scan than it needs to be; some of that key-level detail is discovery-time rather than selection-time information.

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?

With no output schema, the description carries the return-value burden and does so thoroughly, including edge cases like retired variants and empty `steps`. Nothing an agent needs to call this correctly or interpret the result is missing.

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 coverage is 100%, so the baseline is 3; the description earns above that by explaining what each `include` value actually yields (perStep/perNode/perEnd semantics, variant fields, byLanguage) and how it changes the response. It goes beyond the schema's one-line enum gloss without adding new syntax for campaign_id.

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?

Opens with a specific verb and resource plus the exact counters returned (requests_sent, replied_count, profiles_touched, derived rates), and explicitly contrasts itself with get_dashboard. An agent can distinguish it from the dashboard sibling without opening either schema.

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

Usage Guidelines5/5

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

Gives concrete routing rules: pass campaign_id for one campaign, omit for workspace totals, and use get_dashboard for date ranges, daily series, per-sender breakdowns, or the heatmap. It also states the condition for `include` (only with campaign_id) and what the no-include default returns.

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