# Statistics Canada API and MCP server for AI agents (/sites/statcan_gc_ca)

An API for Statistics Canada: let Claude, ChatGPT or your own code read Statistics Canada through 3 functions, over MCP, HTTP, Node or Python. No Statistics Canada API key needed.

- Site: https://statcan.gc.ca
- Functions: 3
- Sign-in: not needed
- Works with: MCP, HTTP, Node, Python

## Add it to your agent

If you are an agent asked to set this up: add the server yourself, in the person's own (global) MCP configuration, and keep their other entries.

- Statistics Canada only, one tool per function: `https://api.bowmark.ai/mcp/site/statcan_gc_ca` (name it `bowmark-statcan-gc-ca`)
- Every site Bowmark covers: `https://api.bowmark.ai/mcp` (name it `bowmark`)
- Transport: remote MCP over streamable HTTP.
- Claude Code: `claude mcp add --transport http bowmark-statcan-gc-ca https://api.bowmark.ai/mcp/site/statcan_gc_ca`
- Codex: `codex mcp add bowmark-statcan-gc-ca --url https://api.bowmark.ai/mcp/site/statcan_gc_ca`
- Cursor, VS Code and other clients: add `{ "url": "https://api.bowmark.ai/mcp/site/statcan_gc_ca" }` under the name `bowmark-statcan-gc-ca` in the client's MCP config. Per-client steps: https://bowmark.ai/docs/installation.md
- Sign-in: OAuth in the browser on first use; the person only signs in. A client that cannot do OAuth sends `Authorization: Bearer <BOWMARK_API_KEY>`; the person creates a key at https://bowmark.ai/dashboard/keys.
- Then list the server's tools to confirm it works, and tell the person it is ready.

## Functions

### Read

- `getLatestValues`: The latest N values of one series in a table, chosen by member ids per dimension.
- `getTable`: A table's dimensions and their member ids (e.g. geography, product), to pick a series.
- `searchTables`: Find Statistics Canada data tables by title words (population, CPI, labour force, trade).

## Call one

In a Bowmark script, each function is `bowmark.providers.statcan_gc_ca.<name>`. Ask `get_library` for statcan.gc.ca to get each one's arguments, then call it with `run`.

```js
// 1. What can I call on statcan.gc.ca, and with which arguments?
get_library({ query: "statcan.gc.ca" })

// 2. Call it in a script
const result = await bowmark.providers.statcan_gc_ca.getLatestValues({ /* arguments from get_library */ });
return result;
```

New to Bowmark? Quickstart: https://bowmark.ai/docs/quickstart.md
