Skip to main content
Glama

cloudflare_get_zone_analytics

Read-onlyIdempotent

Retrieves daily and total traffic analytics for a Cloudflare zone over a chosen period of up to 30 days, covering requests, cached requests, bandwidth, threats, page views, and unique visitors.

Instructions

A zone's traffic for the last N days (default 7, at most 30) from the GraphQL Analytics API: requests, cached requests, bandwidth, threats, page views and unique visitors, per day and in total. Older days may be missing on Free plans.

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": {
      "zone": "<zone>"
    },
    "name": "cloudflare_get_zone_analytics"
  }
}

Input Schema

NameRequiredDescriptionDefault
daysNoDays to cover, ending today (UTC). Default 7.
zoneYesThe zone: its name (example.com.au) or its 32-character zone ID.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4/5.0
Behavior4/5

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

Annotations already declare readOnly=true, idempotent=true and non-destructive, so safety is covered; the description still earns credit for disclosing the upstream source (GraphQL Analytics API) and a genuine data-quality caveat: older days may be absent on Free plans. It stops short of covering retention behavior on paid plans or how partial days are handled.

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?

Two sentences, front-loaded with the purpose and output inventory, followed by the one caveat that actually changes interpretation of the results. No filler or redundant restatement of the tool name.

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 correctly compensates by enumerating the returned metrics and their granularity ('per day and in total'), and it flags the Free-plan gap. It could go one step further on how the per-day series is shaped or sorted, but nothing essential for a correct call is missing.

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

Parameters3/5

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

Schema coverage is 100% and both parameters are fully documented in the schema, so the baseline applies. The description's 'default 7, at most 30' and 'ends today (UTC)' essentially restate the schema's defaults, bounds and description rather than adding new meaning.

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 zone's traffic for the last N days') and enumerates exactly which metrics are returned (requests, cached requests, bandwidth, threats, page views, unique visitors). The metric list cleanly separates it from sibling tools like cloudflare_get_zone or cloudflare_get_zone_settings, which return configuration rather than traffic data.

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?

The description implies its usage context (traffic analysis for a single zone) and supplies a useful limit, but never says when to pick this over an alternative or what it should not be used for. There is no explicit routing to or away from any sibling, so the agent must infer the choice from the metric list.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.