MCP Server

currencyapi ships a hosted Model Context Protocol (MCP) server, so AI agents and assistants can call the API as native tools — no SDK or glue code required.

https://api.currencyapi.com/mcp

The endpoint speaks the streamable HTTP transport. All requests — including listing the available tools — require your API key, sent as the apikey header. You can get a free API key here.

MCP clients that support MCP authorization (OAuth 2.1) can sign in instead of sending a key: see Sign in instead of an API key.

Connect

Using Claude Code:

claude mcp add --transport http currencyapi https://api.currencyapi.com/mcp --header "apikey: YOUR_API_KEY"

Or add the server to any MCP-capable client (Claude Desktop, Cursor, VS Code, ...):

{
  "mcpServers": {
    "currencyapi": {
      "url": "https://api.currencyapi.com/mcp",
      "headers": { "apikey": "YOUR_API_KEY" }
    }
  }
}

Sign in instead of an API key

MCP clients that support MCP authorization (OAuth 2.1) can connect without pasting a key, for example a custom connector in Claude (Settings → Connectors → Add custom connector, URL https://api.currencyapi.com/mcp). Without a key, the endpoint answers 401 with a WWW-Authenticate header that names the protected resource metadata, https://api.currencyapi.com/.well-known/oauth-protected-resource/mcp. The authorization server is https://currencyapi.com (metadata at https://currencyapi.com/.well-known/oauth-authorization-server, endpoints under https://app.currencyapi.com/oauth/); clients register dynamically or with a client ID metadata document, and PKCE (S256) is required.

You sign in on app.currencyapi.com and approve the connection, as the team's owner or an admin. The access token is a key of your team for 60 minutes, renewed with the refresh token, so tool calls count against your plan like any other request. Disconnect an app at any time under API keys → Connected apps in the dashboard. For your own code, use an API key.

Available tools

The tools are generated from the same OpenAPI specification that describes the REST API, so they always match the documented endpoints, parameters and responses.

ToolEndpointDescription
getLatestGET /v3/latestLatest exchange rates
getHistoricalGET /v3/historicalHistorical exchange rates
getConvertGET /v3/convertConvert a value between currencies
getRateGET /v3/rateExchange rate of one currency pair
getMatrixGET /v3/matrixCross rates between several currencies
getRangeGET /v3/rangeHistorical exchange rates for a time range
getOhlcGET /v3/ohlcHourly or daily OHLC candles
getFluctuationGET /v3/fluctuationHow rates changed between two dates
getAverageGET /v3/averageAverage, low and high rates per month, quarter or year
getOfficialGET /v3/officialOfficial central bank exchange rates
getOfficialRangeGET /v3/official/rangeOfficial central bank exchange rates for a date range
getOfficialCompareGET /v3/official/compareCompare one currency pair across central banks
getOfficialSourcesGET /v3/official/sourcesList central bank sources
getCurrenciesGET /v3/currenciesList supported currencies
getCountriesGET /v3/countriesList countries
getStatusGET /v3/statusAccount quota status

Quotas and errors

Tool calls are metered exactly like REST requests: they consume your plan quota and return the same status codes and error responses (401, 422, 429, ...). If a call fails, the tool result contains the API's error message including hints on how to proceed.