Skip to main content
Glama
CSOSA MCP Server

CSOSA MCP Server

by nidahal

Summarize CSOSA Contract Spending

csosa_spending_summary
Read-onlyIdempotent

Aggregates CSOSA contract spending by fiscal year, recipient, or product/service category, with optional date filters, to produce summary totals and chart-ready results.

Instructions

Aggregate CSOSA contract spending for summaries and charts.

Source: USAspending.gov spending_over_time / spending_by_category APIs, scoped to CSOSA contracts. Data refreshes daily; see csosa_search_contract_awards's module docstring for coverage limits.

Returns: {"group_by": ..., "results": [{"label": ..., "amount": ...}, ...]}

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "csosa_spending_summary"
  }
}

Input Schema

NameRequiredDescriptionDefault
limitNoMax rows to return for recipient/product_or_service breakdowns (ignored for fiscal_year, which always returns every year).
end_dateNoISO date (YYYY-MM-DD).
group_byNoHow to aggregate spending: fiscal_year (a time series, good for a trend chart), recipient (top contractors by total obligated amount), or product_or_service (top PSC categories of work).fiscal_year
start_dateNoISO date (YYYY-MM-DD). Earliest supported is 2007-10-01. Defaults to the full available range.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive, open-world behavior, so the safety profile is covered. The description adds meaningful context beyond that: the upstream source (USAspending.gov spending_over_time / spending_by_category), the CSOSA scoping constraint, and the daily refresh cadence, plus a pointer to the sibling docstring for coverage limits.

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 one-line purpose, then source and refresh context, then return shape. It is short and every element is useful, though the 'Returns:' block partially duplicates the existing output schema.

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?

For a read-only aggregation tool with a full output schema, the description supplies source provenance, scope, refresh cadence, and a coverage-limit pointer — enough to call it correctly. The mild redundancy of restating the return shape is the only shortfall.

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 description coverage is 100%, so all four parameters — including the group_by enum and the limit/date semantics — are documented in the schema itself. The description adds no syntax or format detail beyond what the schema provides, so the baseline of 3 applies.

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?

Description states a specific verb+resource: 'Aggregate CSOSA contract spending for summaries and charts,' which clearly distinguishes this aggregator from the more granular sibling tools like csosa_search_contract_awards and csosa_get_award_details. It does not explicitly name those siblings as alternatives, but the aggregation framing makes the role evident.

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 when to use it (summaries and charts, grouping options) and references csosa_search_contract_awards for coverage limits, but never states when to prefer this tool over search or award-detail siblings. Usage is inferable rather than explicit.

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