TCMB MCP
Production-ready MCP (Model Context Protocol) server for Turkish Central Bank (TCMB) exchange rates.
Features
Current Rates: Get today's exchange rates from TCMB
Historical Rates: Query rates for any date since 1996
Currency Conversion: Convert between any currencies (including TRY)
Rate History: Get rate history with statistics (min, max, avg, change %)
Multi-Currency Comparison: Compare multiple currencies over time
Smart Caching: SQLite-based cache with configurable TTL
Holiday Support: Automatic fallback to previous business day
Turkish Holidays: Includes all official and religious holidays
Installation
Using Smithery (Recommended)
Install directly via Smithery:
Using uv (Local Development)
Using pip
Usage
Claude Desktop Configuration
Add to your Claude Desktop config file:
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json
Running Manually
Testing with MCP Inspector
Available Tools
1. tcmb_get_current_rates
Get current exchange rates from TCMB.
2. tcmb_get_historical_rates
Get exchange rates for a specific date.
3. tcmb_list_currencies
List all available currencies.
4. tcmb_convert_currency
Convert between currencies.
5. tcmb_get_rate_history
Get rate history with statistics.
6. tcmb_compare_currencies
Compare multiple currencies.
Configuration
Environment Variables
Variable | Default | Description |
|
| Enable SQLite caching |
|
| Cache database path |
|
| Cache TTL for today (seconds) |
|
| Cache TTL for historical (seconds) |
|
| API timeout (seconds) |
|
| Maximum retry attempts |
|
| Enable debug logging |
|
| Log level |
|
| Transport mode (
or
) |
|
| HTTP server port (when using HTTP transport) |
Development
Setup
Running Tests
Code Quality
Local HTTP Server Testing
Docker
Build
Run
API Reference
TCMB URL Format
Today's rates:
https://www.tcmb.gov.tr/kurlar/today.xmlHistorical:
https://www.tcmb.gov.tr/kurlar/YYYYMM/DDMMYYYY.xmlExample: January 15, 2024 →
/kurlar/202401/15012024.xml
Rate Types
Type | Turkish | Description |
| Döviz Alış | Electronic transfer buying rate |
| Döviz Satış | Electronic transfer selling rate |
| Efektif Alış | Cash buying rate |
| Efektif Satış | Cash selling rate |
Author
Oktay Furkan Uygur
GitHub: @ofurkanuygur