Skip to main content
Glama

Top values of a dimension

get_breakdown
Read-onlyIdempotent

Visitors and attributed revenue per value of one dimension. Defaults to visitors descending. Dimensions: channel, referrer, campaign, keyword, source, hostname, entry, exit, country, region, city, browser, os, device, page, goal, outbound. dim=page includes scroll: median maximum depth (percent), measured/tracked page-view counts, measurement coverage (fraction) and 25/50/75/100% milestone counts and shares of measured views (fractions). Missing depth is null, excluded from the median. Imported history has no scroll measurements. sort=scroll_depth only works with dim=page; unknown depths stay last in both directions. Use get_page_scroll for one exact page. Each row key can be used as a visit filter in other tools.

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": {
      "dim": "<dim>"
    },
    "name": "get_breakdown"
  }
}

Input Schema

NameRequiredDescriptionDefault
toNoLast day, inclusive (YYYY-MM-DD).
dimYesThe dimension to group by.
fromNoFirst day (YYYY-MM-DD, site time zone). Use with to instead of period.
siteNoSite domain (example.com), id or public id (tb_…). Optional with a site key, or when the account has one site.
sortNoDefault visitors. scroll_depth sorts page medians only (dim=page), before limiting.
limitNoRows to return. Default 10.
periodNoTime range. Default 30d. today, yesterday, 24h, 7d, 30d, 90d, 12m, wtd, mtd, ytd, all.
filtersNoOnly visits that match every filter. A value is "is": {"country": "US"}; a list is "is any of": {"country": ["PT", "ES"]}; an object picks the operator: {"page": {"contains": "/blog"}}, {"channel": {"is_not": ["Direct", "Email"]}}, {"page": {"not_contains": "/admin"}}. Operators: is, is_not, contains, not_contains (case-insensitive). "visitor" is "new" or "returning". "ad" is an ad campaign as "google:<campaign id>" or "meta:<campaign id>" (the visits that the Ads page counts for it). Use "(none)" for empty values; countries take ISO codes or English names.
sort_dirNoDefault desc. Unknown scroll depths stay last in either direction.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / filters / propertyNames / enum
      Previous value: -[
      -  "channel",
      -  "referrer",
      -  "campaign",
      -  "keyword",
      -  "source",
      -  "hostname",
      -  "entry",
      -  "exit",
      -  "country",
      -  "region",
      -  "city",
      -  "browser",
      -  "os",
      -  "device",
      -  "page",
      -  "goal",
      -  "visitor",
      -  "ad"
      -]New value: +[
      +  "channel",
      +  "referrer",
      +  "campaign",
      +  "keyword",
      +  "source",
      +  "hostname",
      +  "entry",
      +  "exit",
      +  "country",
      +  "region",
      +  "city",
      +  "browser",
      +  "os",
      +  "device",
      +  "page",
      +  "goal",
      +  "visitor",
      +  "ad",
      +  "assistant"
      +]
  2. Changed2 schema fields changed
    • addedInput schema / properties / sort
      Added value: +{
      +  "description": "Default visitors. scroll_depth sorts page medians only (dim=page), before limiting.",
      +  "enum": [
      +    "name",
      +    "visitors",
      +    "revenue",
      +    "scroll_depth"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / sort_dir
      Added value: +{
      +  "description": "Default desc. Unknown scroll depths stay last in either direction.",
      +  "enum": [
      +    "asc",
      +    "desc"
      +  ],
      +  "type": "string"
      +}
  3. First observed

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive, closed-world behavior, so the description's job is to add domain context — which it does: it discloses that missing depth is null and excluded from the median, that imported history has no scroll measurements, and that unknown depths sort last in both directions. That is real behavioral detail an agent could not infer from the annotations or schema, though it is confined to the page/scroll path and says nothing about the non-page dimensions' return behavior.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The first sentence is well front-loaded, but the seventeen-value dimension list duplicates the dim enum verbatim and 'Defaults to visitors descending' repeats the sort parameter's schema description. The scroll paragraph is dense and useful but is effectively an output-shape spec crammed into a sentence, made harder to scan by being run-on.

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 nine parameters, a nested filters object and no output schema, the definition does enough: it explains the aggregation, the scroll-specific return fields, and the filter-reuse pattern. What it omits is a general description of the row shape for non-page dimensions and what 'attributed revenue' attribution means, which matters given no output schema exists.

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% and each parameter already carries a description, so the baseline is 3; the description earns a bump by explaining that dim=page yields scroll metrics (median maximum depth, measured/tracked counts, coverage, milestone counts and shares) — meaning the bare 'page' enum value does not convey. The rest of the parameter narrative (default sort, scroll_depth restriction) largely restates the schema.

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?

The opening sentence names the exact output — visitors and attributed revenue per value of one dimension — and enumerates every valid dimension, so an agent knows precisely what aggregation this produces. It also distinguishes itself from get_page_scroll for the single-page case, so it is separable from at least one nearby sibling 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 Guidelines4/5

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

Explicit routing is given for the page-drill-down case ('Use get_page_scroll for one exact page') and a usage constraint is stated ('sort=scroll_depth only works with dim=page'). It also tells the agent how to chain results ('Each row key can be used as a visit filter in other tools'), but gives no guidance on when to prefer get_timeseries or get_overview instead of a grouped breakdown.

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