fxapi Exchange Rates MCP Server

Live and historical FX rates for AI agents: latest rates, conversion, time series, fluctuation and period averages for 190+ currencies, crypto and metals.

Hosted MCP Server

npx add-mcp 'https://api.fxapi.com/mcp'

Installs into Claude Code, Codex, Cursor and more

Documentation

Why give your AI agent an exchange rate API?

Language models don’t know today’s exchange rates – and they shouldn’t make them up. With the fxapi MCP server, an assistant can fetch the current EUR/USD rate, convert an invoice amount at the rate of its date or pull a month of historical data, and show you exactly where the number came from.

Connect in seconds

Claude Code

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

Claude Desktop, Cursor, VS Code and other MCP clients

Add the server to your client’s MCP configuration. File locations and key names vary by client (VS Code, for example, uses a servers key in .vscode/mcp.json), so check your client’s documentation for remote HTTP servers with custom headers:

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

Replace YOUR_API_KEY with your key from the fxapi dashboard.

Available tools

The tools map one-to-one to the REST endpoints:

ToolEndpointWhat it does
getLatest/v1/latestLatest exchange rates
getHistorical/v1/historicalRates for a past date
getConvert/v1/convertConvert an amount
getRange/v1/rangeTime series
getFluctuation/v1/fluctuationChange between two dates
getAverage/v1/averagePeriod averages
getCurrencies/v1/currenciesSupported currencies
getStatus/v1/statusYour remaining quota

Plan restrictions are the same as for the REST API – for example, getConvert requires the Basic plan or higher.

Example prompts

  • “What’s the current exchange rate from EUR to USD, GBP and CHF?”
  • “Convert 4,250 CHF to EUR at the rate of 30 June 2026.”
  • “Show me how the Japanese yen moved against the dollar over the last 30 days.”
  • “Give me the monthly average EUR/USD rates for Q1 2026 as a table.”

Prefer to build it yourself?

Use the OpenAPI 3.1 specification to generate tools for your own agent framework, or read the machine-readable docs at /docs/llms.txt.

Read the full walkthrough in exchange rates for AI agents and the MCP documentation.

This endpoint is part of the fxapi foreign exchange rate API – the same key, response format and 190+ currencies across every endpoint.

Frequently asked questions

What is an MCP server?

The Model Context Protocol (MCP) is an open standard that lets AI assistants call external tools and data sources. The fxapi MCP server exposes the exchange rate API as tools, so an assistant can look up rates itself instead of guessing them.

Do I need an API key?

Yes. Send your fxapi key in the apikey header – a free key works. Tool calls count against your plan’s quota like normal API requests.

Which MCP clients are supported?

Any client that supports remote MCP servers over streamable HTTP, including Claude Code, Claude Desktop, Cursor and VS Code.

What happens if a tool call fails?

The tool result contains the same machine-readable error message and status the REST API would return (for example 422 for a bad date or 429 for an exhausted quota), so the agent can correct the request or tell the user.