FEDERAL REPUBLIC OF NIGERIA  ·  ENERGY COMMISSION OF NIGERIA (ECN)  ·  ESTABLISHED UNDER ECN ACT, CAP. E10, LFN 2004
An official service of the Energy Commission of Nigeria.
REST API · v1

NEDB Public API

Open access to the energy statistics the Energy Commission has published. A series appears here only once it has been published for public access; withheld series are not served. Base URL: https://nedb.vercel.app

GET
/api/series
List all active data series. Returns metadata, frequency, and record count for each series.
Example Response
[{ "id": "crude_oil_production", "name": "Crude Oil Production", "sector": "petroleum", "unit_default": "M Barrels", "frequency": "monthly", "viz_types": ["line","stacked-area"], "record_count": 48 }]
GET
/api/series/{id}
Full metadata for a single series.
Parameters
NameInTypeDescription
id*pathstringSeries type ID, e.g. crude_oil_production
Example Response
{ "id": "...", "name": "...", "sector": "...", "unit_default": "M Barrels", "frequency": "monthly" }
GET
/api/series/{id}/data
Paginated time-series records for a series. Filterable by region, period range, and page.
Parameters
NameInTypeDescription
id*pathstringSeries type ID
regionquerystringISO 3166-2:NG state or NGA for national
period_fromquerystringStart period, e.g. 2020-01
period_toquerystringEnd period, e.g. 2024-12
pagequeryintegerPage number (default 1)
limitqueryintegerRecords per page (max 500, default 100)
Example Request
GET https://nedb.vercel.app/api/series/crude_oil_production/data?period_from=2022-01&period_to=2023-12
Example Response
{ "rows": [...], "total": 24, "page": 1, "limit": 100 }
GET
/api/series/{id}/stats
Auto-computed statistics: latest value, YoY change, MoM change, CAGR, rolling 3-period and 12-period averages.
Parameters
NameInTypeDescription
id*pathstringSeries type ID
Example Response
{ "latest": 85.4, "latest_period": "2024-06", "yoy_pct": 3.2, "mom_pct": -1.1, "cagr": 2.8, "rolling_3": 84.1, "rolling_12": 83.7, "unit": "M Barrels" }
GET
/api/series/{id}/export
Download all records for a series as CSV or Excel (XLSX). Excel includes a metadata sheet.
Parameters
NameInTypeDescription
id*pathstringSeries type ID
formatquerystringcsv (default) or xlsx
yearquerystringFilter by year, e.g. 2023
regionquerystringFilter by region
Example Request
GET https://nedb.vercel.app/api/series/electricity_generation/export?format=xlsx&year=2023
POST
/api/iot/ingest
Real-time data ingest from IoT field devices and EOM systems. Accepts a single reading or a batch of up to 100 readings. Authenticate with X-API-Key header.
X-API-Key required
Parameters
NameInTypeDescription
series_type_id*bodystringTarget series
period*bodystringe.g. 2026-06 or 2026-Q2
period_date*bodystringISO date e.g. 2026-06-01
value*bodynumberNumeric reading
unit*bodystringMust match series unit_default
regionbodystringNGA for national (default)
device_idbodystringEOM device identifier
readingsbodyarrayArray of readings for batch ingest
Example Request
POST https://nedb.vercel.app/api/iot/ingest
X-API-Key: <your-key>
Content-Type: application/json

{
  "series_type_id": "crude_oil_production",
  "period": "2026-06",
  "period_date": "2026-06-01",
  "value": 85.4,
  "unit": "M Barrels",
  "region": "NGA"
}
Example Response
{ "inserted": 1, "series_type_id": "crude_oil_production" }
GET
/api/health
System health check. Returns database and cache connectivity status.
Example Response
{ "status": "ok", "db": "ok", "ts": "2026-06-30T10:00:00.000Z" }

Usage & Rate Limits

Authentication
No key needed to read published data. An API key raises your rate limit and is supplied in an X-API-Key header; it does not widen what you can see. Request one from ECN Data Management.
Rate limits
60 requests/minute for anonymous callers, 600/minute with an API key. Use the export endpoint for bulk downloads rather than paging the data endpoint.
Data licence
Published under ECN Open Data Policy. Attribution required: cite NEDB (Energy Commission of Nigeria).
Coverage
Only published series are served. An unpublished series returns 404, and each series exposes only the fields the Commission has published for it.
Format
All responses are JSON (UTF-8). Export endpoint returns CSV or XLSX. All dates are ISO 8601.
Contact
For API access issues or data queries, contact ECN Data Management at data@energy.gov.ng