Skip to main content
Glama

get_pivot_report

Read-only

Cross-tab spending or income: rows by category, subcategory, payee or tag against time columns (yearly, quarterly, monthly, weekly), with row and column totals, in the base currency. Splits are distributed and refunds netted, so a refunded amount never counts as spend.

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": {
      "from": "<from>",
      "to": "<to>",
      "granularity": "<granularity>",
      "rowDimension": "<rowDimension>",
      "measure": "<measure>"
    },
    "name": "get_pivot_report"
  }
}

Input Schema

NameRequiredDescriptionDefault
toYesPeriod end (YYYY-MM-DD, inclusive)
fromYesPeriod start (YYYY-MM-DD, inclusive)
measureYesWhat to sum: expense or income
payeeIdsNoOnly these payees
accountIdsNoOnly these accounts
categoryIdsNoOnly these categories (a parent includes its subcategories)
granularityYesColumn size: yearly, quarterly, monthly or weekly
rowDimensionYesWhat the rows are: category, subcategory, payee or tag

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4/5.0
Behavior4/5

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

Annotations only declare readOnlyHint=true, so the description carries real weight here and delivers: amounts are in base currency, splits are distributed, and refunds are netted so a refunded amount never counts as spend. That last clause is exactly the kind of non-obvious aggregation rule an agent cannot guess, though volume limits, handling of uncategorized items and date/timezone boundaries are unstated.

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 operation and its shape, followed by the aggregation caveat. No filler and nothing a schema already covers at length is re-explained.

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 8 parameters, no output schema and only a readOnlyHint annotation, the description does the necessary work by stating the output is a matrix with row and column totals in base currency. It falls short only on edge behavior (empty columns, uncategorized spend, treatment of transfers) that an agent querying it would eventually need.

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% with enums documented for measure, granularity and rowDimension, so the schema does the heavy lifting and baseline 3 applies. The description adds one genuine semantic beyond the schema (results are expressed in the base currency) and restates the dimension lists, but gives no extra detail such as how categoryIds interacts with subcategory rows or what weekly columns anchor to.

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?

"Cross-tab spending or income" names the operation precisely, then enumerates the row dimensions (category, subcategory, payee, tag) and column granularities, which lets an agent separate it from siblings like get_spending_by_categories or get_cash_flow without opening a schema.

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 makes it evident this is the right tool when a category-by-time matrix with totals is wanted, but it never names an alternative or states an exclusion (e.g., 'use get_spending_by_categories for a single-period breakdown'). Routing is inferred, not instructed.

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.