TCMB Exchange Rates
Finance Türkiye Credits / request: 1Returns the latest exchange rates published by the Central Bank of Türkiye.
GET
https://api.apikodu.com/api/v1/exchangerates/tcmb
Documentation
Overview
Returns CBRT (TCMB) FX rates.
Authentication
Every request requires the x-api-key header. Credits used and remaining quota are returned in response headers (x-api-credits-used, x-api-remaining-credits, x-rate-limit-*).
Request
GET
https://api.apikodu.com/api/v1/exchangerates/tcmb?code=USD
Query string. Empty code returns all rates.
Parameters
| Name | Type | Required | Default | Options | Description |
|---|---|---|---|---|---|
code |
string | Optional | — | USD AUD DKK EUR GBP CHF SEK CAD KWD NOK SAR JPY BGN RON RUB IRR CNY PKR QAR KRW AZN AED XDR |
Currency code. Empty returns all rates. |
Response
| Name | Type | Description |
|---|---|---|
date |
string | CBRT rate date (ISO datetime). Previous business day on weekends/holidays. |
source |
string | Always TCMB. |
rates |
array | Rate list. A single item when code is set. |
rates[].code |
string | ISO currency code (USD, EUR, GBP ...). |
rates[].name |
string | CBRT Turkish currency name. Example: ABD DOLARI. |
rates[].forexBuying |
number | FX buying (CBRT). May be null. |
rates[].forexSelling |
number | FX selling (CBRT). May be null. |
rates[].banknoteBuying |
number | Banknote buying. Null for some codes. |
rates[].banknoteSelling |
number | Banknote selling. Null for some codes. |
Errors
| HTTP | code | Description |
|---|---|---|
400 |
-225 |
code is not in the CBRT list. |
503 |
-224 |
CBRT rate cache is empty or could not be retrieved. |
401 |
-100 |
x-api-key is missing, empty, malformed, inactive, banned, expired, IP-restricted, or not allowed for this API. |
429 |
-221 |
Per-minute request limit exceeded. Response headers: x-rate-limit-limit, x-rate-limit-remaining, x-rate-limit-reset. |
429 |
— | Package credit quota cannot cover this request. Body may be { error, limit, currentUsage, requestCost } (no code field). |
500 |
-1 |
Unexpected server error. message is a generic error text without technical details. |
Notes
- Success body is { data: { ... } }. Error body is { code, message }. code is an ApiResponseCode enum value (negative integer).
Sample response
{
"data": {
"date": "2026-08-19T00:00:00",
"source": "TCMB",
"rates": [
{
"code": "USD",
"name": "ABD DOLARI",
"forexBuying": 33.5214,
"forexSelling": 33.5818,
"banknoteBuying": 33.4980,
"banknoteSelling": 33.6321
},
{
"code": "EUR",
"name": "EURO",
"forexBuying": 36.2105,
"forexSelling": 36.2757,
"banknoteBuying": 36.1851,
"banknoteSelling": 36.3301
},
{
"code": "GBP",
"name": "İNGİLİZ STERLİNİ",
"forexBuying": 42.8012,
"forexSelling": 43.0256,
"banknoteBuying": 42.7712,
"banknoteSelling": 43.0901
}
]
}
}
Code samples
const response = await fetch('https://api.apikodu.com/api/v1/exchangerates/tcmb', {
method: 'GET',
headers: {
'x-api-key': 'YOUR_API_KEY'
}
});
const data = await response.json();
console.log(data);
import requests
headers = {
'x-api-key': 'YOUR_API_KEY'
}
response = requests.get('https://api.apikodu.com/api/v1/exchangerates/tcmb', headers=headers)
print(response.json())
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("x-api-key", "YOUR_API_KEY");
var response = await client.GetStringAsync("https://api.apikodu.com/api/v1/exchangerates/tcmb");
Console.WriteLine(response);
$response = file_get_contents('https://api.apikodu.com/api/v1/exchangerates/tcmb', false, stream_context_create([
'http' => [
'header' => "x-api-key: YOUR_API_KEY"
]
]));
print_r(json_decode($response, true));
curl -X GET 'https://api.apikodu.com/api/v1/exchangerates/tcmb' \
-H 'x-api-key: YOUR_API_KEY'
Start building in minutes
Create a free account, get your API key and send your first request in minutes.