List supported currency codes
curl --request GET \
--url https://avraapi.com/api/v1/utility/currency/codes \
--header 'X-API-KEY: <api-key>' \
--header 'X-API-SECRET: <api-key>'const options = {
method: 'GET',
headers: {'X-API-KEY': '<api-key>', 'X-API-SECRET': '<api-key>'}
};
fetch('https://avraapi.com/api/v1/utility/currency/codes', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://avraapi.com/api/v1/utility/currency/codes",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-KEY: <api-key>",
"X-API-SECRET: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}{
"success": true,
"request_id": "01f00000-0000-4000-8000-000000000001",
"data": {
"count": 4,
"codes": [
{
"code": "AUD",
"name": "Australian Dollar"
},
{
"code": "LKR",
"name": "Sri Lankan Rupee"
},
{
"code": "LKR-SELL",
"name": "Sri Lankan Rupee (CBSL Sell Rate)"
},
{
"code": "USD",
"name": "US Dollar"
}
]
}
}Currencies
List supported currency codes
Retrieve the active Currency code list, including CBSL target codes.
GET
/
utility
/
currency
/
codes
List supported currency codes
curl --request GET \
--url https://avraapi.com/api/v1/utility/currency/codes \
--header 'X-API-KEY: <api-key>' \
--header 'X-API-SECRET: <api-key>'const options = {
method: 'GET',
headers: {'X-API-KEY': '<api-key>', 'X-API-SECRET': '<api-key>'}
};
fetch('https://avraapi.com/api/v1/utility/currency/codes', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://avraapi.com/api/v1/utility/currency/codes",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-KEY: <api-key>",
"X-API-SECRET: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}{
"success": true,
"request_id": "01f00000-0000-4000-8000-000000000001",
"data": {
"count": 4,
"codes": [
{
"code": "AUD",
"name": "Australian Dollar"
},
{
"code": "LKR",
"name": "Sri Lankan Rupee"
},
{
"code": "LKR-SELL",
"name": "Sri Lankan Rupee (CBSL Sell Rate)"
},
{
"code": "USD",
"name": "US Dollar"
}
]
}
}Live Testing Guide: Before using Try it, create a Development project, then enter its Client ID and Client Secret. Configure the relevant provider for that project before sending the request.
USD and LKR, plus the CBSL target codes LKR-SELL, LKR-BUY, and LKR-CBSL when active. Those three are valid only as a target in the pair routes; they are not ordinary currencies to use as a base.
API endpoint
GET
https://avraapi.com/api/v1/utility/currency/codes
Request
curl
curl "https://avraapi.com/api/v1/utility/currency/codes" \
-H "X-API-KEY: YOUR_PROJECT_CLIENT_ID" \
-H "X-API-SECRET: YOUR_PROJECT_CLIENT_SECRET" \
-H "X-ENV: development" \
-H "Accept: application/json"
Response
The list below is shortened for readability.data.codes contains every active code returned by the API.
{
"success": true,
"request_id": "d57a5f8b-69bc-4877-8da7-31bb9dbfa575",
"data": {
"count": 169,
"codes": [
{
"code": "AED",
"name": "UAE Dirham"
},
{
"code": "AFN",
"name": "Afghan Afghani"
},
{
"code": "ALL",
"name": "Albanian Lek"
}
]
}
}
Error codes
| HTTP | error.code | When it happens |
|---|---|---|
401 | unauthorized | The Project Client ID or Client Secret is missing, invalid, inactive, or does not match the selected environment. |
422 | provider_selection_failed | The Currency provider cannot be selected for the project environment. |
429 | rate_limit_exceeded | The project has exceeded the Currency service request limit. Wait for Retry-After before retrying. |
503 | project_paused | The project is paused and cannot make API requests. |
request_id when contacting support; see the REST API guide for the shared response format.
Use the response safely
Cache the list only for the lifetime that makes sense for your UI and refresh it from the endpoint before relying on a newly added or removed code. Keeprequest_id with support records when a code unexpectedly becomes unavailable.
For CBSL target meanings and the direct-data fallback rule, read CBSL Rates.
Playground resources
The generated reference below lists this endpoint’s API standard details: request fields, authorizations, and response schema. The complete integration guide, request and response examples, and endpoint-specific error handling are above.Authorizations
Headers
Last modified on October 1, 2026
Was this page helpful?
