API Documentation
How to query Labari Data programmatically with your API key.
What this is
Labari Data exposes our public datasets — country profiles, parliaments, startups, and more — over a plain REST API for scripts and apps. Your API key identifies you; it does not let you write, modify, or delete anything — every call is read-only.
Getting a key
Sign in and generate a key from your API dashboard. The key is shown once — copy it somewhere safe. You can revoke it and generate a new one from the same page at any time.
- Free — no payment required, 30 requests per minute and 5,000 per day, every dataset except those marked Pro.
- Pro — 60 requests per minute, 20,000 per day, and access to the Pro datasets (
election-results,vcs). Upgrade from the same dashboard.
Making requests
It's a plain HTTP GET with no protocol handshake, so it works the same way every time:
curl "https://labaridata.com/api/v1/countries" \
-H "Authorization: Bearer YOUR_API_KEY"The path segment is the dataset name (see the list below), and any query-string params are passed through to the dataset, e.g. /api/v1/search?q=kenya or /api/v1/election-results?election=2024 Presidential (the full label, not just the year — a bare year silently returns zero results). Responses are plain JSON. Most datasets return { count, results }; search returns a bare array of matches (empty if q is missing), and network returns its records grouped by type.
Datasets
The value of the path segment to pass after /api/v1/:
countriesPolitical, economic & demographic profiles for African nations
mpsGhana's Members of Parliament
rwanda-mpsRwanda's Chamber of Deputies
rwanda-senateRwanda's Senate
election-resultsProGhana election results — requires ?election=<full label>, e.g. "2024 Presidential"
ministriesGhana government ministries
soeState-owned enterprises directory
startupsAfrican startup directory
vcsProVenture capital firms investing in Africa
networkPeople & organisations in African media
women-in-techWomen in African tech directory
ghana-diasporaGhanaian diaspora directory
playersAfrican sports athlete profiles
creatorsAfrica digital creators — YouTubers, TikTokers & influencers
ghana-moviesGhanaian films — cast, crew, genres & posters
eventsPan-African events calendar
chartsPublished Datawrapper & Flourish charts
searchCross-dataset search
recently-updatedWhat's changed across the platform recently
Example exchange
Request
curl "https://labaridata.com/api/v1/startups" \
-H "Authorization: Bearer YOUR_API_KEY"Response
{
"count": 391,
"results": [
{ "name": "Andela", "sector": "Talent", "hqCountry": "Nigeria", ... },
...
]
}Rate limits
Limits are per key, over a fixed one-minute window that resets at the start of each minute. Every response carries headers showing where you stand:
X-RateLimit-Limit: 30
X-RateLimit-Remaining: 27
X-RateLimit-Reset: 42 # seconds until the window resets
X-RateLimit-Daily-Limit: 5000
X-RateLimit-Daily-Remaining: 4812Over the limit you'll get a 429 with a Retry-After header — wait that many seconds and retry. Daily limits reset at midnight UTC.
Errors
Errors come back as JSON with an error message:
400Missing or invalid query parameter, e.g. election-results without ?election=403Missing, invalid or revoked key — or a Pro dataset requested with a Free key404Unknown dataset (the response lists the valid ones)429Per-minute or daily limit exceeded — see Retry-After502The upstream data source is temporarily unavailable — retry shortlyGood to know
- Your key is personal. Don't share it or commit it to a public repo — treat it like a password. If it leaks, revoke it from your API dashboard and generate a new one.
- Getting a 403 you didn't expect? Check the key hasn't been revoked or replaced in your API dashboard, and that you're not requesting a Pro dataset on a Free key.
- Every dataset here mirrors what's already public on labaridata.com — the REST API is just a faster way to get at it programmatically, not a separate or expanded dataset.
Support
Questions, a dataset you'd like added, or something not behaving as described here — email us at hi@labaridata.com.