/v1/rank
Rank countries by latest Gini
Try it live
10 free calls per day — no sign-up, no API key. Goes through the oanor gateway.
It works. Grab an API key and use it in your project.
Get an API keyCode snippets
curl "https://api.oanor.com/gini-api/v1/rank" \ -H "x-oanor-key: oanor_test_..."
await fetch("https://api.oanor.com/gini-api/v1/rank", {
headers: { "x-oanor-key": "oanor_test_..." }
});
$ch = curl_init("https://api.oanor.com/gini-api/v1/rank");
curl_setopt($ch, CURLOPT_HTTPHEADER, ["x-oanor-key: oanor_test_..."]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$out = curl_exec($ch);
import requests
requests.get(
"https://api.oanor.com/gini-api/v1/rank",
headers={"x-oanor-key": "oanor_test_..."}
)
Example response
A real response from this endpoint, captured by the latest health check.
{
"data": {
"basis": "latest available Gini index",
"count": 10,
"order": "desc",
"ranking": [
{
"max": 64.8,
"min": 57.8,
"code": "ZA",
"gini": 63,
"rank": 1,
"year": 2014,
"emoji": "🇿🇦",
"alpha3": "ZAF",
"latest": {
"gini": 63,
"year": 2014
},
"country": "South Africa",
"history": [
{
"gini": 59.3,
"year": 1993
},
{
"gini": 57.8,
"year": 2000
},
{
"gini": 64.8,
"year": 2005
},
{
"gini": 63,
"year": 2008
},
{
"gini": 63.4,
"year": 2010
},
{
"gini": 63,
"year": 2014
}
]
},
{
"max": 71.1,
"min": 59.1,
"code": "NA",
"gini": 59.1,
"rank": 2,
"year": 2015,
"emoji": "🇳🇦",
"alpha3": "NAM",
"latest": {
"gini": 59.1,
"year": 2015
},
"country": "Namibia",
"history": [
{
"gini": 71.1,
"year": 1993
},
{
"gini": 63.3,
"year": 2003
},
{
"gini": 61,
"year": 2009
},
{
"gini": 59.1,
"year": 2015
}
]
},
{
"max": 61.5,
"min": 54.2,
"code": "BW",
"gini": 54.9,
"rank": 3,
"year": 2015,
"emoji": "🇧🇼",
"alpha3": "BWA",
"latest": {
"gini": 54.9,
"year": 2015
},
"country": "Botswana",
"history": [
{
"gini": 54.2,
"year": 1985
},
{
"gini": 60.1,
"year": 1993
},
{
"gini": 61.5,
…