API — United Kingdom (GB)

4 nations, 361 county/councils.

Endpoints

GET /api/v1/countries/gb.json
Full dataset — all levels, all records
GET /api/v1/gb/nation.json
All 4 nations (Nation)
GET /api/v1/gb/county.json
All 361 county/councils (County/Council)
GET /api/v1/gb/nation/{slug}.json
Single nation with children

Quick Start

JavaScript

fetch('https://api.openadmindata.org/api/v1/countries/gb.json')
  .then(r => r.json())
  .then(data => {
    const levels = data.meta.levels.map(l => l.name_en);
    console.log('United Kingdom:', levels.join(' → '));
    
    console.log(data.data.nation.length, 'nations');
  });

Python

import requests
data = requests.get('https://api.openadmindata.org/api/v1/countries/gb.json').json()
nations = data['data']['nation']
print(f"United Kingdom: {len(nations)} nations")

cURL

curl -s https://api.openadmindata.org/api/v1/gb/nation.json | jq '.count'

Schema

Each entity record contains:

FieldTypeDescription
idstringUnique identifier
name_localstringName in local script
name_enstringEnglish / romanized name
slugstringURL-safe slug
latnumberLatitude (WGS84)
lonnumberLongitude (WGS84)
parent_idstring?Parent entity ID (null for top level)
parent_name_localstring?Parent name in local script
parent_name_enstring?Parent English name
postal_codestring?Postal code (deepest level only, where available)