Skip to content

LGA context

GEThttps://api.ai4mproject.com/v1/context/lgasScope: risk_scores

Returns what surrounds a risk score: how many people live in each LGA, and how well it is covered by bed nets, treatment and health facilities. Use it with the risk score to decide where need is greatest.

Name Type Required Description
state string Yes Two-letter state code, such as KN

Parameters go in the query string.

curl "https://api.ai4mproject.com/v1/context/lgas?state=KN" \
-H "Authorization: Bearer $AI4M_API_KEY"

Shares run from 0 to 1. A figure is null where the source has no estimate for the area.

Field Type Description
source.name string Where the coverage figures come from
source.coverage_year integer The year the net and treatment figures describe
state_code string The state asked for
state string Its name
lgas[].lga_code string Stable LGA identifier. Join on this, not the name
lgas[].lga string LGA name
lgas[].is_urban boolean Whether the LGA is classed as urban
lgas[].population integer People living in the area
lgas[].area_km2 number Land area in square kilometres
lgas[].itn_use number Share of people who slept under a treated net
lgas[].itn_access number Share of people with access to a treated net
lgas[].irs_coverage number Share of people protected by indoor spraying
lgas[].effective_treatment number Share of malaria cases that get an effective treatment
lgas[].travel_minutes_to_care number Average travel time to the nearest health facility, in minutes
lgas[].response_index number Average of net use and effective treatment
200 OK
{
"source": {
"name": "Malaria Atlas Project",
"coverage_year": 2024,
"note": "Modelled estimates shown as context. They are not inputs to the risk score. Shares run from 0 to 1."
},
"state_code": "KN",
"state": "Kano",
"lgas": [
{
"lga_code": "NGA.20.1_1",
"lga": "Ajingi",
"is_urban": false,
"population": 252054,
"area_km2": 690.9,
"itn_use": 0.532,
"itn_access": 0.613,
"irs_coverage": 0,
"effective_treatment": 0.574,
"travel_minutes_to_care": 4.755,
"response_index": 0.553
},
{
"lga_code": "NGA.20.2_1",
"lga": "Albasu",
"is_urban": false,
"population": 278283,
"area_km2": 458.5,
"itn_use": 0.507,
"itn_access": 0.598,
"irs_coverage": 0,
"effective_treatment": 0.574,
"travel_minutes_to_care": 4.996,
"response_index": 0.54
}
]
}

The example shows two of Kano’s 44 LGAs. LGAs are returned in alphabetical order.

Code Status When
UNKNOWN_STATE 404 state is missing or is not a valid state code
SCOPE_REQUIRED 403 The key does not include the scope this endpoint needs

Any request can also return 401 for a bad key and 429 when a limit is reached. See Errors.