Skip to main content
Glama
Aryan-Jhaveri

Statistics Canada MCP Server

get_sdmx_vector_data

Retrieve time-series observations for a known Statistics Canada vector ID via SDMX. Filter by date range or last N observations to get exactly the periods you need.

Instructions

Fetch time-series observations for a single StatCan vector via SDMX REST.

Simpler alternative to get_sdmx_data when you already know the vectorId. Use get_series_info_from_cube_pid_coord or get_cube_metadata to find vectorIds.

Time filtering (use one or the other, not both): lastNObservations=5 → last 5 periods startPeriod="2020-01" → from Jan 2020 (monthly); "2020" for annual endPeriod="2023-12" → up to Dec 2023

LIMITATION: StatCan rejects combining lastNObservations with startPeriod/endPeriod (returns 406).

Output rows contain: dimension values, "period", "value", SCALAR_FACTOR, UOM, VECTOR_ID, STATUS, and other SDMX attributes.

IMPORTANT: In your final response to the user, you MUST cite the source of your data. This means including the _sdmx_url,and vectorId in your response.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
vectorIdYes
endPeriodNoEnd period in YYYY or YYYY-MM format.
startPeriodNoStart period in YYYY or YYYY-MM format.
lastNObservationsNoReturn only the last N observations (e.g. 5 for last 5 periods).
Behavior4/5

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

No annotations are provided, so the description carries the transparency burden. It discloses a specific limitation ('StatCan rejects combining lastNObservations with startPeriod/endPeriod returns 406'), describes the output rows, and includes a mandatory citation requirement. It does not discuss rate limits or auth, but for a read-only fetch operation, the disclosed information is substantial.

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 somewhat long but well-structured with clear sections for purpose, alternatives, time filtering, limitation, output, and citation. Every section adds necessary information, though it could be tightened without losing content. Front-loading the core purpose and alternative helps quick scanning.

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, lack of output schema, and multiple sibling tools, the description covers all essential aspects: what it does, when to use it, how to find parameters, parameter constraints, output structure, and a critical legal/citation requirement. It is sufficiently complete for an agent to invoke it correctly.

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 75%, and the description adds meaningful context beyond the schema: it gives concrete examples for startPeriod and endPeriod formats (monthly vs annual), demonstrates lastNObservations usage, and warns against combining mutually exclusive filters. The schema already describes most fields, so the description complements rather than repeats.

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: 'Fetch time-series observations for a single StatCan vector via SDMX REST.' It also distinguishes this tool from its sibling by calling it a 'Simpler alternative to get_sdmx_data when you already know the vectorId,' which directly addresses the key differentiation.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

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

Explicit usage guidance is given: it names alternative siblings for finding vectorIds ('Use get_series_info_from_cube_pid_coord or get_cube_metadata to find vectorIds') and clarifies when this tool is appropriate versus get_sdmx_data. It also provides concrete examples for parameter usage, making the decision process clear.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Aryan-Jhaveri/mcp-statcan'

If you have feedback or need assistance with the MCP directory API, please join our Discord server