Developer Documentation

Use one API and SDK for address workflows across supported countries, with deeper Nigerian geography and address intelligence.

Introduction

AddressData is a global address intelligence platform built in Nigeria. It brings country-aware address validation, formatting, and geography into one developer integration, with deeper Nigerian state, LGA, FCT district, and estate data. Our planned direction is to support Nigeria's Digital Postcode through an authorized integration, with NIPOST remaining the source for issued postcode records and building locations.

TypeScript & Bun SDK

Official Client

The fastest way to use AddressData in modern JavaScript and TypeScript environments is via the official SDK:

Example SDK Integration:

import { addressData } from '@addressdata/sdk' // 1. Address validation with country-aware rules and Nigeria-specific intelligence const validation = await addressData.validate({ country: 'NG', state: 'Lagos', lga: 'Ikeja', street: '15 Allen Avenue', nipostPostcode: 'LA01A03FK01' }) console.log(validation.isValid) // true console.log(validation.standardized.formattedAddress) // "15 Allen Avenue, Ikeja, Ikeja LGA, Lagos State, LA-01-A03-FK-01, Nigeria" // 2. Ultra-Fast Autocomplete (Estates, Cities & LGAs) const suggestions = await addressData.autocomplete('Carlton Gate') console.log(suggestions) // 3. Validate Nigerian administrative geography const isValidLocation = addressData.nigeria.validateHierarchy('Lagos', 'Ikeja') console.log(isValidLocation.isValid)

Authentication

All REST API requests require a valid API key generated from your Developer Portal. Pass your key in either of the following headers:

  • X-Public-Key: YOUR_API_KEY (Recommended)
  • Authorization: Bearer YOUR_API_KEY
  • x-api-key: YOUR_API_KEY

cURL Request Example:

// Include your API key in either header: // Option A: X-Public-Key (Recommended) // Option B: Authorization: Bearer <API_KEY> curl -X POST "https://api.addressdata.ng/api/v1/validate" \ -H "X-Public-Key: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "country": "NG", "state": "Lagos", "lga": "Ikeja", "street": "15 Allen Avenue" }'

Rate Limits & Free Tier

100 Free Requests Per Day

Every developer account includes 100 free requests per calendar day. Ideal for local development, automated testing, and indie prototypes.

Every response includes real-time rate limit headers:

X-RateLimit-Limit: 100 X-RateLimit-Remaining: 84 X-RateLimit-Reset: 1728345600

Once your daily free quota is reached, subsequent requests return HTTP 429 Too Many Requests. Contact our team to scale to dedicated Growth or Enterprise volume plans.

API Base URL

All REST API endpoints are served securely over HTTPS:

https://api.addressdata.ng/api/v1
POST

/validate

Validates and standardizes address details for supported countries. For Nigeria, it checks state-to-LGA hierarchy, validates postcode format, and matches approved estates. Confirming that a Digital Postcode is assigned to a building is planned through an authorized NIPOST integration.

Request Body (JSON):

{ "country": "NG", "state": "Lagos", "lga": "Ikeja", "city": "Ikeja", "street": "15 Allen Avenue", "estate": "Carlton Gate Estate", "nipostPostcode": "LA01A03FK01" }

Success Response (200 OK):

{ "success": true, "data": { "isValid": true, "confidence": "exact", "country": { "code": "NG", "name": "Nigeria", "flag": "🇳🇬" }, "standardized": { "street": "15 Allen Avenue", "city": "Ikeja", "state": "Lagos", "lga": "Ikeja", "country": "Nigeria", "formattedAddress": "15 Allen Avenue, Carlton Gate Estate, Ikeja, Ikeja LGA, Lagos State, LA-01-A03-FK-01, Nigeria" }, "errors": [], "warnings": [], "intelligence": { "nigeria": { "state": "Lagos", "stateCode": "LA", "capital": "Ikeja", "geopoliticalZone": "South West", "lga": "Ikeja", "lgaValidForState": true, "isFctDistrict": false, "nipostPostcode": "LA-01-A03-FK-01", "estateMatched": { "id": "carlton-gate-ikeja", "name": "Carlton Gate Estate", "state": "Lagos", "lga": "Ikeja" } } } } }

The nipostValid result checks postcode format. Confirming that a Digital Postcode is assigned to a building requires resolution against NIPOST records through the planned authorized integration.

GET

/autocomplete

Search supported country names and Nigerian states, LGAs, and verified estates.

Query Parameters:

  • q (string, required): Partial query (e.g. "Ikeja", "Carlton").
  • country (string, optional): ISO country code (default: "NG").
  • limit (number, optional): Maximum suggestions to return (1-20, default: 5).

Success Response (200 OK):

{ "success": true, "query": "Ikeja", "count": 2, "data": [ { "id": "lga:ikeja", "label": "Ikeja", "secondaryLabel": "Lagos State", "type": "lga", "country": "NG" }, { "id": "estate:carlton-gate-ikeja", "label": "Carlton Gate Estate", "secondaryLabel": "Ikeja, Lagos", "type": "estate", "country": "NG" } ] }
GET

/geography/countries

Returns standard ISO 3166-1 alpha-2 country metadata, dial codes, flags, and postal format validation rules.

Success Response (200 OK):

{ "success": true, "count": 250, "data": [ { "code": "NG", "name": "Nigeria", "capital": "Abuja", "dialCode": "+234", "flag": "🇳🇬", "hasPostalCodes": true, "adminLevelName": "state" }, { "code": "GB", "name": "United Kingdom", "capital": "London", "dialCode": "+44", "flag": "🇬🇧", "hasPostalCodes": true, "adminLevelName": "county" } ] }
GET

/geography/states

Lists all 36 Nigerian States plus the Federal Capital Territory (FCT) with official state codes and geopolitical zones.

Success Response (200 OK):

{ "success": true, "count": 37, "data": [ { "id": "lagos", "name": "Lagos", "capital": "Ikeja", "code": "LA", "zone": "South West" }, { "id": "fct", "name": "Federal Capital Territory", "capital": "Abuja", "code": "FC", "zone": "North Central" } ] }
GET

/geography/states/:stateId/lgas

Returns Local Government Areas by state from AddressData's Nigerian geography data.

Success Response (200 OK):

{ "success": true, "state": "Lagos", "count": 20, "data": [ "Agege", "Ajeromi-Ifelodun", "Alimosho", "Amuwo-Odofin", "Apapa", "Badagry", "Epe", "Eti-Osa", "Ibeju-Lekki", "Ifako-Ijaiye", "Ikeja", "Ikorodu", "Kosofe", "Lagos Island", "Lagos Mainland", "Mushin", "Ojo", "Oshodi-Isolo", "Shomolu", "Surulere" ] }
GET

/estates

Queries approved gated residential and commercial estates across Nigeria with optional state and LGA filters.

Success Response (200 OK):

{ "success": true, "count": 1, "data": [ { "id": "carlton-gate-estate", "name": "Carlton Gate Estate", "state": "Lagos", "lga": "Ikeja", "status": "verified" } ] }

Error Handling & Status Codes

The API uses standard HTTP response codes:

  • 200 OK: Request completed successfully.
  • 400 Bad Request: Missing required parameters or malformed JSON payload.
  • 401 Unauthorized: Missing, inactive, or invalid API key.
  • 404 Not Found: Requested resource does not exist.
  • 429 Too Many Requests: Daily free tier quota (100 req/day) exceeded.
  • 500 Internal Error: Server error. Please contact developer support.

Need Integration Support?

Our developer support engineering team is available to assist with custom webhooks, bulk backfills, and enterprise deployments.

Visit Help & Support

Global address tools, built in Nigeria.

© 2026 AddressData by Haqqman. All Rights Reserved.