API — Luxembourg (LU)

12 cantons, 102 communes.

Endpoints

GET /api/v1/countries/lu.json
Full dataset — all levels, all records
GET /api/v1/lu/canton.json
All 12 cantons (Canton)
GET /api/v1/lu/commune.json
All 102 communes (Commune)
GET /api/v1/lu/canton/{slug}.json
Single canton with children

Quick Start

JavaScript

fetch('https://openadmindata.org/api/v1/countries/lu.json')
  .then(r => r.json())
  .then(data => {
    const levels = data.meta.levels.map(l => l.name_en);
    console.log('Luxembourg:', levels.join(' → '));
    
    console.log(data.data.canton.length, 'cantons');
  });

Python

import requests
data = requests.get('https://openadmindata.org/api/v1/countries/lu.json').json()
cantons = data['data']['canton']
print(f"Luxembourg: {len(cantons)} cantons")

cURL

curl -s https://openadmindata.org/api/v1/lu/canton.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)