Skip to main content
Glama

treasury-fiscaldata-mcp-server

Get Treasury Interest Rates

treasury_get_interest_rates
Read-onlyIdempotent

Average interest rates Treasury pays on its outstanding securities by security type. Answers "what is the government's cost of borrowing?" Covers every type Treasury reports — marketable issues, non-marketable series, and the aggregate totals — and which types it reports changes over the years, so omit security_type to see the ones a given period carries. Rates are percentages, not basis points. Updated monthly (end-of-month records). Mode "latest" returns the most recent month's rates for all or one security type; "series" returns a time history, staging the result as a DataCanvas table when canvas_id is set or the range matches more than 200 rows — read the table's column schema with treasury_dataframe_describe, then run SQL over it with treasury_dataframe_query.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modeNo"latest" returns the most recent month's rates. "series" returns a time range.latest
end_dateNoISO 8601 end date for mode=series. Defaults to today.
canvas_idNoSet any non-empty value to stage mode=series results as a DataCanvas table for SQL analysis — the value only requests staging; the server picks the table name. Staging also happens on its own when a series matches more than 200 rows. The assigned name (df_XXXXX_XXXXX) comes back in the output canvas_id; pass it to treasury_dataframe_describe, then treasury_dataframe_query. Requires CANVAS_PROVIDER_TYPE=duckdb.
start_dateNoISO 8601 start date for mode=series (YYYY-MM-DD, must be end-of-month for meaningful results).
security_typeNoFilter to one security type, matched exactly against the security_desc field — full case and punctuation, as in "Treasury Inflation-Protected Securities (TIPS)". Omit for every type in the period, which is how to read the set of types on offer; the response names them when a filter matches nothing.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
capNoThe preview cap applied to the inline series array.
errorNoPresent when the call failed. Absent on success.
ratesNoInterest rate records, newest first. Whole in mode=latest — a month is a bounded set. In mode=series an inline preview of at most 20 rows; compare its length against total_records to detect the cap, and reach the rest through canvas_id when one is returned.
shownNoSeries rows returned inline.
noticeNoGuidance when no records match (where the requested security type does have records, or the types the most recent month carries, or the empty date range), when the inline series is a preview, or when the series was staged as a DataCanvas table.
canvas_idNoDuckDB table name (df_XXXXX_XXXXX) holding the staged series. Pass it to treasury_dataframe_describe for the column schema, then use it as the FROM target in treasury_dataframe_query SQL. Absent when nothing was staged.
truncatedNoTrue when the inline series array holds fewer rows than were retrieved.
as_of_dateNoMost recent record date returned (YYYY-MM-DD).
total_recordsNoIn mode=latest, the number of rows in rates. In mode=series, the full upstream match — larger than rates.length whenever the preview cap applied.
canvas_expires_atNoISO 8601 expiry for the canvas dataframe.

TDQS

A4.7/5.0
Behavior5/5

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

Annotations already cover read-only and idempotent behavior, so the bar is lower. The description adds substantial behavioral nuance: rates are percentages not basis points, the set of security types changes over years, data is updated monthly, and large series trigger automatic DataCanvas staging. It also discloses that canvas_id staging requires duckdb. These details go far beyond the annotations and significantly aid correct invocation.

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?

The description is dense but well-structured, starting with the core purpose and then layering details about coverage, units, update frequency, and modes. Every sentence contributes necessary information; the length is justified given the tool's complexity (5 params, two modes, staging behavior). It could be slightly trimmed in wording, but it remains focused and front-loaded with the most important facts.

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

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity and that an output schema exists, the description covers all essential operational aspects: how to use modes, parameter nuances, staging trigger conditions, and the follow-up workflow with sibling tools. It even explains the 'omit security_type' strategy for discovering available types. Nothing an agent needs to call it correctly and interpret results is missing.

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

Parameters5/5

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

Although schema coverage is 100% (all parameters documented), the description adds crucial semantic depth: security_type can be omitted to list all types and the response names types when a filter matches nothing; start_date should be end-of-month; canvas_id only requests staging and the actual table name is returned; the exact match requirement for security_type is clarified. These enrich the schema descriptions to a level that prevents common errors.

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 description clearly states the tool's function: obtaining average interest rates on Treasury securities by type, with a specific verb and resource. It explicitly differentiates from siblings by naming the domain (interest rates vs debt, exchange rates) and covers the full scope of security types. The inclusion of a clarifying 'answers the government's cost of borrowing' makes the purpose immediately obvious.

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?

The description provides explicit guidance on how to use the tool's modes ('latest' vs 'series'), when to omit security_type to discover available types, and the meaning of end-of-month for start_date. It also references sibling tools (treasury_dataframe_describe, treasury_dataframe_query) for post-processing staged results. However, it does not explicitly state when to choose this tool over alternatives like treasury_get_debt or treasury_get_exchange_rates, leaving that to the agent's domain inference.

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.

TDQS

A4.7/5.0
Disambiguation4/5

The tools are mostly distinct: each specialized getter (debt, exchange rates, interest rates) targets a specific dataset, while the generic query tool and list tool serve discovery and ad-hoc queries. There is some overlap between the generic treasury_query_dataset and the specialized getters, but the descriptions clearly differentiate their intended use (specialized modes vs. raw endpoint queries).

Naming Consistency5/5

All tools follow a consistent treasury_verb_noun pattern with snake_case (e.g., treasury_get_debt, treasury_list_datasets, treasury_dataframe_query). The verbs (get, list, query, describe) are consistent in style and each noun is plural or singular appropriately, making the naming uniform and predictable.

Tool Count5/5

With 7 tools, the server is well-scoped for its purpose of accessing Treasury fiscal data. It offers dedicated tools for common datasets, a generic query tool for flexibility, and DataFrame staging/query utilities, with no redundancy or overwhelming number of tools.

Completeness5/5

The tool surface covers essential workflows: discovering available datasets (list_datasets), querying any endpoint (query_dataset), retrieving common datasets with convenience modes (debt, exchange rates, interest rates), and handling large result sets via DataCanvas staging (describe/query). No obvious gaps exist; even less common datasets are accessible through the generic query tool.