Skip to main content
Glama
bank-of-canada-mcp

bank-of-canada-mcp

by koleharv

bank-of-canada-mcp

An MCP server that gives Claude and other LLMs live access to Canadian economic data via the Bank of Canada's free Valet API — ~16,000 time series covering exchange rates, the policy interest rate, CPI, bond yields, commodity prices, and more.

FRED, the World Bank, and the IMF all have MCP servers. Canada didn't — now it does.

No API key required.

Quick start

Claude Code

claude mcp add bank-of-canada -- npx -y bank-of-canada-mcp

Claude Desktop — add to claude_desktop_config.json:

{
  "mcpServers": {
    "bank-of-canada": {
      "command": "npx",
      "args": ["-y", "bank-of-canada-mcp"]
    }
  }
}

The same npx invocation works in Cursor, Windsurf, and any other MCP client.

Related MCP server: boc-valet-mcp

Tools

Tool

What it does

search_series

Keyword search across the full series catalogue — find the series name for anything ("overnight rate target", "CPI", "5-year bond")

get_observations

Time-series data for up to 5 series, by date range or N most recent

latest_fx_rates

Today's official daily exchange rates vs CAD

convert_currency

Convert between any two supported currencies using today's rates

Example prompts

  • "What's the Bank of Canada's current policy rate, and how has it moved this year?"

  • "Plot USD/CAD for the last 90 days."

  • "Convert 2,500 EUR to CAD at today's official rate."

  • "How does core CPI compare to headline CPI over the past two years?"

Development

npm install
npm test        # offline unit tests (vitest)
npm run build   # tsc → dist/

Architecture: src/valet.ts is a plain API client with pure, unit-tested logic (search, conversion math); src/index.ts is the MCP wiring. Errors from the Valet API (e.g. an unknown series name) are returned as MCP tool errors with the API's own message, so the model can self-correct by re-searching.

Notes

  • Rates are the Bank of Canada's indicative daily averages, published once per business day — not transactional quotes.

  • Data is © Bank of Canada, used under their terms. This project is not affiliated with or endorsed by the Bank of Canada.

Roadmap

  • Statistics Canada Web Data Service tools

  • Group browsing (lists/groups)

  • Streamable HTTP transport for remote deployment

License

MIT

Available Tools

4 tools
convert_currencyConvert currencyA

Convert an amount between currencies using the latest Bank of Canada daily rates (cross-rated through CAD). Indicative daily averages, not transactional quotes.

Inputs: to (required), from (required), amount (required).

get_observationsGet time-series observationsA

Fetch observations for up to 5 Bank of Canada series (find names with search_series). Defaults to the 10 most recent observations when no range is given.

Inputs: series (required), recent, end_date, start_date.

latest_fx_ratesLatest daily exchange ratesA

Latest official Bank of Canada daily exchange rates, quoted as CAD per 1 unit of each foreign currency.

Inputs: no named parameters.

search_seriesSearch Bank of Canada data seriesA

Search the Bank of Canada's catalogue of ~16,000 economic time series (exchange rates, policy interest rate, CPI, bond yields, commodity prices...). Returns series names to use with get_observations.

Inputs: query (required), limit.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4/5.0

    Scored across 4 tools

    Disambiguation5/5

    Each tool has a clearly distinct purpose: searching series, fetching observations, getting latest FX rates, and converting currency. Even though latest_fx_rates and get_observations both relate to exchange rates, the descriptions clarify scope (latest vs. historical series data), leaving no ambiguity.

    Naming Consistency4/5

    All tool names use snake_case and are descriptive. Most follow a verb_noun pattern (search_series, get_observations, convert_currency), while latest_fx_rates is an adjective_noun deviation, but the style remains consistent and predictable.

    Tool Count4/5

    Four tools is slightly lean but appropriate for the focused scope of a Bank of Canada data read server. Each tool has a clear role, and the count feels adequate rather than excessive or trivially small.

    Completeness4/5

    The server covers the core workflow: discover series, fetch observations, retrieve latest FX rates, and perform currency conversion. Minor gaps exist (e.g., no metadata endpoint or historical FX rate convenience method), but agents can work around them using get_observations with series names.

    Maintenance

    ActivityMaintained
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      F
      maintenance
      Provides access to Statistics Canada official statistics without authentication, enabling AI agents to query Canadian economic and demographic data.
      4 npm
      MIT
    • A
      license
      A
      quality
      D
      maintenance
      Provides LLM agents with live access to Canadian economic and financial data (exchange rates, interest rates, inflation, etc.) through the Bank of Canada Valet API, with no API key required.
      10
      5
      MIT
    • A
      license
      Not graded
      quality
      C
      maintenance
      Retrieves metadata for Bank of Canada financial data series using the Valet API. Supports keyless access with date parameters in YYYY-MM-DD format.
      60 npm
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      Provides access to Chilean economic indicators (dolar, UF, IPC, etc.) via the mindicador.cl API, enabling queries for current values, historical series, and specific dates.
      MIT