Skip to main content
Glama

Period comparison

compare_periods
Read-onlyIdempotent

Comparison of a period with the previous one: absolute and relative change, warnings about incomparability.

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": {
      "account_id": "<account_id>"
    },
    "name": "compare_periods"
  }
}

Input Schema

NameRequiredDescriptionDefault
modeNo
date_toNoPeriod end, YYYY-MM-DD, no later than yesterday; up to 31 days. Optional: by default yesterday (the account's time zone when known, otherwise UTC).
date_fromNoPeriod start, YYYY-MM-DD, a completed day. Optional: without dates the last 7 completed days are used (date_from = date_to − 6 days).
account_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • changedInput schema / properties / date_from / description
      Previous value: -"Period start, YYYY-MM-DD, a completed day"New value: +"Period start, YYYY-MM-DD, a completed day. Optional: without dates the last 7 completed days are used (date_from = date_to − 6 days)."
    • changedInput schema / properties / date_to / description
      Previous value: -"Period end, YYYY-MM-DD, no later than yesterday; up to 31 days"New value: +"Period end, YYYY-MM-DD, no later than yesterday; up to 31 days. Optional: by default yesterday (the account's time zone when known, otherwise UTC)."
    • changedInput schema / required
      Previous value: -[
      -  "account_id",
      -  "date_from",
      -  "date_to"
      -]New value: +[
      +  "account_id"
      +]
  2. First observed

TDQS

B3.2/5.0
Behavior3/5

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

Annotations already cover readOnlyHint, idempotentHint, destructiveHint=false and closed-world scope, so the safety profile needs no restating. The description does add real value by disclosing the return contents ('absolute and relative change, warnings about incomparability'), but says nothing about limits such as the 31-day cap or what triggers an incomparability warning.

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?

A single compact sentence with the core purpose front-loaded and no wasted wording. It is written as a noun phrase rather than a full clause, which is terse but still parseable.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/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 usefully characterizes the response, but for a 4-parameter tool at 50% schema coverage it should explain the mode enum and default window behavior. It leaves an agent guessing on two of four parameters.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is only 50%: date_from/date_to are documented in the schema, but 'mode' and 'account_id' are not. The description's phrase 'the previous one' vaguely gestures at mode yet never explains the previous_period/previous_month/previous_year enum or what account_id should be, so it does not compensate for the coverage gap.

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 states a specific operation and its output: comparing a period against 'the previous one' and returning absolute/relative change plus incomparability warnings. It is clearly distinct from reporting tools like get_performance, but it never names a sibling to route the agent explicitly.

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?

Period-over-period comparison is implied as the use case, but there is no explicit 'use this when...' guidance, no mention of when to prefer get_performance or ga4_report instead, and no prerequisite information.

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