We provide a simple REST API to retrieve currency exchange rates against the Kyrgyz som. The API offers several endpoints designed for different currency rate usage scenarios.
| Term | Description |
|---|---|
| API Token | A unique key used to identify the API user via the Bearer Token Authorization Header. |
| Currency Code | A three-character ISO currency code. |
| Base Currency | The currency against which the exchange rate is returned. Example: 1 dollar = 88 soms, the som is the Base Currency. |
The API uses standard HTTP codes to indicate the success or failure of a request.
| Code | Description |
|---|---|
| 200 OK | Successful request. Data is returned in JSON format. |
| 400 Bad Request | Validation error. Check the request parameters. |
| 401 Unauthorized | Missing or invalid API token. Check the Authorization header. |
| 403 Forbidden | No API access or monthly request limit exceeded. Contact support. |
| 500 Internal Server Error | Internal server error. Try again later or contact support. |
You need to register and obtain an API Bearer Token. Then you must send it with every request to our API.
https://data.fx.kg/api/v1/
L5HoneK2u1F61cYy6IX6SLv7BkaYKVB2iZzfVBa9
You can find more information on how to use the token at this link.
401 Unauthorized (invalid token):
{
"message": "Unauthenticated."
}
403 Forbidden (request limit exceeded):
{
"messages": "Monthly request limit exceeded. Contact support."
}
403 Forbidden (no API access):
{
"messages": "No API access. Contact support."
}
Currency exchange rates in real time.
GET https://data.fx.kg/api/v1/average
HTTP codes: 200 (success), 401 (unauthorized), 403 (no access/limit)
Response (200 OK):
{
"updated_at": null,
"type": null,
"buy_usd": "87.00",
"sell_usd": "87.70",
"buy_eur": "96.30",
"sell_eur": "97.30",
"buy_rub": "1.10",
"sell_rub": "1.12",
"buy_kzt": "0.14",
"sell_kzt": "0.20"
}
GET https://data.fx.kg/api/v1/best
HTTP codes: 200 (success), 401 (unauthorized), 403 (no access/limit)
Response (200 OK):
{
"updated_at": null,
"type": null,
"buy_usd": "87.00",
"sell_usd": "87.70",
"buy_eur": "96.30",
"sell_eur": "97.30",
"buy_rub": "1.10",
"sell_rub": "1.12",
"buy_kzt": "0.14",
"sell_kzt": "0.20"
}
GET https://data.fx.kg/api/v1/current
HTTP codes: 200 (success), 401 (unauthorized), 403 (no access/limit)
Response (200 OK):
[
{
"id": 1,
"title": "MBANK",
"official_title": "ОАО \"MBANK\"",
"slug": "mbank",
"website_url": "https://www.mbank.kg",
"rates": [
{
"organization_id": 1,
"base_currency_id": 1,
"created_at": "2023-06-15T02:35:05.000000Z",
"updated_at": "2023-06-15T02:35:05.000000Z",
"is_current": 1,
"type": "cashless",
"buy_usd": "87.00",
"sell_usd": "87.64",
"buy_eur": "94.50",
"sell_eur": "95.50",
"buy_rub": "1.020",
"sell_rub": "1.070",
"buy_kzt": "0.130",
"sell_kzt": "0.200",
"buy_uzs": null,
"sell_uzs": null,
"buy_cny": "11.00",
"sell_cny": "14.00",
"buy_gbp": null,
"sell_gbp": null,
"buy_try": null,
"sell_try": null
},
{
"organization_id": 1,
"base_currency_id": 1,
"created_at": "2023-06-15T02:40:04.000000Z",
"updated_at": "2023-06-15T02:40:04.000000Z",
"is_current": 1,
"type": "regular",
"buy_usd": "87.40",
"sell_usd": "88.10",
"buy_eur": "94.50",
"sell_eur": "95.50",
"buy_rub": "1.030",
"sell_rub": "1.060",
"buy_kzt": "0.130",
"sell_kzt": "0.200",
"buy_uzs": null,
"sell_uzs": null,
"buy_cny": null,
"sell_cny": null,
"buy_gbp": null,
"sell_gbp": null,
"buy_try": null,
"sell_try": null
}
]
},
{
"id": 2,
"title": "Optima Bank",
"official_title": "ОАО \"Оптима Банк\"",
"slug": "optima-bank",
"website_url": "https://www.optimabank.kg",
"rates": [
{
"organization_id": 2,
"base_currency_id": 1,
"created_at": "2023-06-15T03:05:31.000000Z",
"updated_at": "2023-06-15T03:05:31.000000Z",
"is_current": 1,
"type": "regular",
"buy_usd": "87.50",
"sell_usd": "88.00",
"buy_eur": "94.40",
"sell_eur": "95.40",
"buy_rub": "1.030",
"sell_rub": "1.055",
"buy_kzt": "0.135",
"sell_kzt": "0.205",
"buy_uzs": null,
"sell_uzs": null,
"buy_cny": null,
"sell_cny": null,
"buy_gbp": null,
"sell_gbp": null,
"buy_try": null,
"sell_try": null
},
{
"organization_id": 2,
"base_currency_id": 1,
"created_at": "2023-06-15T03:05:31.000000Z",
"updated_at": "2023-06-15T03:05:31.000000Z",
"is_current": 1,
"type": "cashless",
"buy_usd": "87.30",
"sell_usd": "87.64",
"buy_eur": "94.40",
"sell_eur": "95.40",
"buy_rub": "1.010",
"sell_rub": "1.080",
"buy_kzt": "0.135",
"sell_kzt": "0.205",
"buy_uzs": null,
"sell_uzs": null,
"buy_cny": null,
"sell_cny": null,
"buy_gbp": null,
"sell_gbp": null,
"buy_try": null,
"sell_try": null
}
]
},
{...}
]
GET https://data.fx.kg/api/v1/central
HTTP codes: 200 (success), 401 (unauthorized), 403 (no access/limit)
Response (200 OK):
{
"created_at": "2023-06-26T10:00:34.000000Z",
"updated_at": "2023-06-26T10:00:34.000000Z",
"is_current": 1,
"usd": "87.3231",
"eur": "95.1036",
"kzt": "0.1940",
"rub": "1.0323",
"gbp": "110.8733",
"dkk": "12.7144",
"inr": "1.0641",
"cad": "66.1026",
"cny": "12.1595",
"krw": "0.0666",
"nok": "8.0359",
"xdr": "117.0534",
"sek": "8.0974",
"chf": "96.9444",
"jpy": "6.1007",
"amd": "2.2608",
"byr": "0.3402",
"mdl": "4.8381",
"tjs": "7.9993",
"uzs": "0.0076",
"uah": "2.3873",
"kwd": "283.8142",
"huf": "2.5562",
"czk": "3.9963",
"nzd": "53.5139",
"pkr": "0.3047",
"aud": "58.3895",
"try": "3.4586",
"azn": "51.3520",
"sgd": "64.5340",
"afn": "1.0170",
"bgn": "48.4238",
"brl": "18.2885",
"gel": "33.2439",
"aed": "23.7673",
"irr": "0.0208",
"myr": "18.6675",
"mnt": "0.0253",
"twd": "2.8099",
"tmt": "24.9424",
"pln": "21.3464",
"sar": "23.2718",
"byn": "29.2948"
}
We have an archive of currency rate changes since 2013. You can retrieve rates for any specific day by adding the date parameter to the request.
Requirements:
Y-m-d (e.g., 2025-01-15)Timezone: all dates in API responses are returned in UTC format.
| Parameter | Type | Description |
|---|---|---|
| date | string | Date in Y-m-d format. Optional. If omitted, current data is returned. |
The date parameter is supported on the following endpoints:
GET https://data.fx.kg/api/v1/average?date=2025-01-15
GET https://data.fx.kg/api/v1/best?date=2025-01-15
GET https://data.fx.kg/api/v1/current?date=2025-01-15
GET https://data.fx.kg/api/v1/central?date=2025-01-15
HTTP codes: 200 (success), 400 (invalid date format), 401 (unauthorized), 403 (no subscription/limit exceeded)
Returns all currency rate records for the specified day, sorted from oldest to newest. Can be filtered by organization and currency.
GET https://data.fx.kg/api/v1/rates/history?date=2025-01-15
Query Parameters:
| Parameter | Required | Description |
|---|---|---|
| date | yes | Date in Y-m-d format (e.g., 2025-01-15) |
| organization_id | no | Organization ID for filtering |
| currency | no | Currency code: usd, eur, rub, kzt, uzs, cny, gbp, try. When specified, only rates for the selected currency are returned. |
| type | no | Rate type: regular (cash) or cashless (non-cash). Default: regular. |
Filter examples:
GET https://data.fx.kg/api/v1/rates/history?date=2025-01-15&organization_id=1
GET https://data.fx.kg/api/v1/rates/history?date=2025-01-15¤cy=usd
GET https://data.fx.kg/api/v1/rates/history?date=2025-01-15&organization_id=1¤cy=eur
GET https://data.fx.kg/api/v1/rates/history?date=2025-01-15&type=cashless
Response (200 OK):
[
{
"organization_id": 1,
"organization": "MBANK",
"type": "regular",
"created_at": "2025-01-15T03:35:05.000000Z",
"buy_usd": "87.40",
"sell_usd": "88.10",
"buy_eur": "94.50",
"sell_eur": "95.50",
"buy_rub": "1.030",
"sell_rub": "1.060",
"buy_kzt": "0.130",
"sell_kzt": "0.200",
"buy_uzs": null,
"sell_uzs": null,
"buy_cny": null,
"sell_cny": null,
"buy_gbp": null,
"sell_gbp": null,
"buy_try": null,
"sell_try": null
},
{
"organization_id": 2,
"organization": "Optima Bank",
"type": "regular",
"created_at": "2025-01-15T05:05:31.000000Z",
"buy_usd": "87.50",
"sell_usd": "88.00",
...
},
{...}
]
Response with currency=usd filter (200 OK):
[
{
"organization_id": 1,
"organization": "MBANK",
"type": "regular",
"created_at": "2025-01-15T03:35:05.000000Z",
"buy_usd": "87.40",
"sell_usd": "88.10"
},
{...}
]
403 Forbidden (no paid subscription):
{
"messages": "Access to historical data is available only for paid subscriptions."
}
403 Forbidden (historical request limit exceeded):
{
"messages": "Historical request limit exceeded (100 per month)."
}
400 Bad Request (invalid date format):
{
"message": "Invalid date format. Use the Y-m-d format (e.g., 2025-01-15)."
}
Instead of periodically polling the API, you can specify a Webhook URL for each token.
The system will automatically send a POST request
to your URL every time rates are updated at one of the banks.
Requirements:
Go to the API Tokens page, click the Webhook button next to the desired token, and enter your server URL.
| Parameter | Value |
|---|---|
| Method | POST |
| Content-Type | application/json |
| Timeout | 5 seconds |
| Field | Type | Description |
|---|---|---|
| data | array | Array of updated rates |
| data[].organization_id | integer | ID of the bank or exchange office |
| data[].type | string | cash — cash rates, transfer — transfer rates |
| data[].buy_usd / sell_usd | float|null | USD buy/sell rate |
| data[].buy_eur / sell_eur, buy_rub / sell_rub ... | float|null | Similarly for EUR, RUB, KZT, CNY, GBP, TRY |
{
"data": [
{
"organization_id": 12,
"type": "cash",
"buy_usd": 87.50,
"sell_usd": 88.00,
"buy_eur": 95.00,
"sell_eur": 96.50,
"buy_rub": 0.95,
"sell_rub": 0.98,
"buy_kzt": null,
"sell_kzt": null,
"buy_cny": null,
"sell_cny": null,
"buy_gbp": null,
"sell_gbp": null,
"buy_try": null,
"sell_try": null
}
]
}
Additional endpoints that may be useful.
Returns a list of commercial banks with their current exchange rates.
GET https://data.fx.kg/api/v1/organizations
HTTP codes: 200 (success), 401 (unauthorized), 403 (no access/limit)
Response (200 OK):
[
{
"id": 1,
"title": "MBANK",
"official_title": "ОАО \"MBANK\"",
"slug": "mbank",
"website_url": "https://www.mbank.kg",
"rates": [
{
"organization_id": 1,
"base_currency_id": 1,
"created_at": "2023-06-15T02:35:05.000000Z",
"updated_at": "2023-06-15T02:35:05.000000Z",
"is_current": 1,
"type": "regular",
"buy_usd": "87.40",
"sell_usd": "88.10",
"buy_eur": "94.50",
"sell_eur": "95.50",
"buy_rub": "1.030",
"sell_rub": "1.060",
"buy_kzt": "0.130",
"sell_kzt": "0.200"
}
]
},
{...}
]
Response objects:
| Field | Description |
|---|---|
| id | Internal organization ID. Used in other endpoints for filtering. |
| title | Short bank name. |
| official_title | Official legal bank name. |
| slug | Unique string identifier for the bank. |
| website_url | Official bank website. |
| rates | Array of the bank's current exchange rates. May contain multiple entries (cash and non-cash rates). |
GET https://data.fx.kg/api/v1/currencies
HTTP codes: 200 (success), 401 (unauthorized), 403 (no access/limit)
Response (200 OK):
[
{
"id": 1,
"code": "KGS",
"title": "Kyrgyz Som"
},
{
"id": 2,
"code": "USD",
"title": "US Dollar"
},
{
"id": 3,
"code": "EUR",
"title": "Euro"
},
{
"id": 4,
"code": "RUB",
"title": "Russian Ruble"
},
{
"id": 5,
"code": "KZT",
"title": "Kazakh Tenge"
},
{...}
]
Response objects:
| Field | Description |
|---|---|
| id | Internal currency ID. |
| code | Three-character ISO currency code. |
| title | Currency name. |
GET https://data.fx.kg/api/v1/currencies/convertible
HTTP codes: 200 (success), 401 (unauthorized), 403 (no access/limit)
Response (200 OK):
[
{
"id": 2,
"code": "USD",
"title": "US Dollar"
},
{
"id": 3,
"code": "EUR",
"title": "Euro"
},
{
"id": 4,
"code": "RUB",
"title": "Russian Ruble"
},
{
"id": 5,
"code": "KZT",
"title": "Kazakh Tenge"
}
]
Response objects:
| Field | Description |
|---|---|
| id | Internal currency ID. |
| code | Three-character ISO currency code. |
| title | Currency name. |