Skip to main content
Glama

Campaigns

get_campaigns
Read-onlyIdempotent

Every ad campaign (Meta, Google and the other ad platforms) over the period, largest spend first, with largestFalls and largestRises already ranked by the change in what the platform claims (compare for last year, or compareFrom and compareTo): spend, the revenue the PLATFORM claims for it (claimedRevenue) and roas (claimedRevenue ÷ spend), with the previous period's spend, claim and ROAS beside them (priorSpend, priorClaimedRevenue, priorRoas; null when comparable is false). Claims are each platform's own and overlap — never add them up into store revenue. name null = the campaign was never named in the sync, quote its id. Use for 'which campaigns spend the most', 'best and worst campaigns', 'how did campaign X do'. For Nuira's own attribution per campaign use get_sales; for Google products inside Shopping and Performance Max use get_google_product_split. Optional from and to (inclusive YYYY-MM-DD, both or neither, never after today) read another span instead of the default period. A named month, a week or two dates the operator gave MUST be sent here: without them this reads the last 30 days, which is not that month.

Input Schema

NameRequiredDescriptionDefault
toNoLast day of the span, inclusive, as YYYY-MM-DD; not after today. Send together with `from`, or omit both to read the default 30-day period.
fromNoFirst day of the span, inclusive, as YYYY-MM-DD. Send together with `to`, or omit both to read the default 30-day period.
compareNoWhat to compare the span with: previous (default, the same number of days just before), yoy (the same dates last year) or yoyWeekday (52 weeks back, the same weekdays — use it for natural Monday–Sunday weeks or whenever the operator says 'last year' over weeks).
compareToNoLast day of the named comparison period, YYYY-MM-DD.
compareFromNoFirst day of a NAMED comparison period, YYYY-MM-DD, with compareTo. For 'September with October': from/to October, compareFrom/compareTo the whole of September. Takes the place of compare.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • addedInput schema / properties / compare
      Added value: +{
      +  "description": "What to compare the span with: previous (default, the same number of days just before), yoy (the same dates last year) or yoyWeekday (52 weeks back, the same weekdays — use it for natural Monday–Sunday weeks or whenever the operator says 'last year' over weeks).",
      +  "enum": [
      +    "previous",
      +    "yoy",
      +    "yoyWeekday"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / compareFrom
      Added value: +{
      +  "description": "First day of a NAMED comparison period, YYYY-MM-DD, with compareTo. For 'September with October': from/to October, compareFrom/compareTo the whole of September. Takes the place of compare.",
      +  "format": "date",
      +  "type": "string"
      +}
    • addedInput schema / properties / compareTo
      Added value: +{
      +  "description": "Last day of the named comparison period, YYYY-MM-DD.",
      +  "format": "date",
      +  "type": "string"
      +}
  2. Added

TDQS

A4.6/5.0
Behavior4/5

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

Annotations already declare readOnly/idempotent/non-destructive, so this is clearly a safe read. The description still adds substantial non-structured context: default sort order, that largestFalls/largestRises are pre-ranked, that prior* fields are null when comparable is false, and the important caveat that platform claims overlap and must never be summed into store revenue. It does not discuss pagination, row limits, or what 'the period' defaults to beyond 'last 30 days' being implied.

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 purpose, sort order and ranking, then caveats, then use cases, then parameters — a sensible order. It is a single dense paragraph with heavy parenthetical nesting (field lists, null semantics, sibling routing all interleaved), which makes it harder to scan than it needs to be, though almost every clause carries 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: it enumerates spend, claimedRevenue, roas and the prior* counterparts, explains null meanings and the name-null case. Combined with the date/comparison parameter guidance, an agent has everything needed to call it correctly.

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 baseline by explaining the intent and coupling rules the schema only states mechanically: compare for last year, compareFrom/compareTo take the place of compare, and the worked example ('September with October'). The 'both or neither, never after today' constraint is repeated from the schema, which slightly dilutes the added value.

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+resource+scope (every ad campaign across Meta, Google and other platforms, over the period, sorted by largest spend) and names the two sibling tools it is not: get_sales for Nuira's own attribution and get_google_product_split for Google product splits. An agent can distinguish it from the ~45 siblings without opening any 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 explicit when-to-use phrasings ('which campaigns spend the most', 'best and worst campaigns', 'how did campaign X do') plus explicit routing to alternatives (get_sales, get_google_product_split). It also states a hard when-to-use rule for the date params: a named month, week or operator-supplied date range MUST be passed here because the default is the last 30 days.

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