DanskAdresseAPIv1
Områder (DAGI)

Look up administrative divisions from a coordinate or a postal code

Give either lat+lon (nearest address) OR postnr (an aggregate with arrays per field).

GET/v1/dagi/lookup

Authentication

Authorizationstringheaderrequired

Your API key as a Bearer token.

Parameters

latnumberquery

Latitude in WGS84 (EPSG:4326).

lonnumberquery

Longitude in WGS84 (EPSG:4326).

postnrstringquery

Filter by postal code.

sridstringquery

Coordinate system as an EPSG code, e.g. 25832. Defaults to 4326 (WGS84).

fieldsstringquery

Comma-separated list of fields to include in the response (sparse fieldset). Omitted = all fields.

Request

curl --request GET \
  --url "https://api.danskadresseapi.dk/v1/dagi/lookup" \
  --header "Authorization: Bearer $API_NOEGLE"

Response

application/json

DAGI-inddelinger

sognobject
Show child attributes(2)
sogn.kodestring | null
sogn.navnstring | null
regionobject
Show child attributes(2)
region.kodestring | null
region.navnstring | null
sourceenum<string>
kommuneobject
Show child attributes(2)
kommune.kodestring | null
kommune.navnstring | null
landsdelobject
Show child attributes(2)
landsdel.kodestring | null
landsdel.navnstring | null
retskredsobject
Show child attributes(2)
retskreds.kodestring | null
retskreds.navnstring | null
storkredsobject
Show child attributes(2)
storkreds.kodestring | null
storkreds.navnstring | null
politikredsobject
Show child attributes(2)
politikreds.kodestring | null
politikreds.navnstring | null
valglandsdelobject
Show child attributes(2)
valglandsdel.kodestring | null
valglandsdel.navnstring | null
opstillingskredsobject
Show child attributes(2)
opstillingskreds.kodestring | null
opstillingskreds.navnstring | null
afstemningsomraadeobject
Show child attributes(2)
afstemningsomraade.navnstring | null
afstemningsomraade.nummerstring | null
200Eksempel
{
  "sogn": {
    "kode": "0101",
    "navn": "København"
  },
  "region": {
    "kode": "0101",
    "navn": "København"
  },
  "source": "koordinat",
  "kommune": {
    "kode": "0101",
    "navn": "København"
  },
  "landsdel": {
    "kode": "0101",
    "navn": "København"
  },
  "retskreds": {
    "kode": "0101",
    "navn": "København"
  },
  "storkreds": {
    "kode": "0101",
    "navn": "København"
  },
  "politikreds": {
    "kode": "0101",
    "navn": "København"
  },
  "valglandsdel": {
    "kode": "0101",
    "navn": "København"
  },
  "opstillingskreds": {
    "kode": "0101",
    "navn": "København"
  },
  "afstemningsomraade": {
    "navn": null,
    "nummer": null
  }
}
401Missing key
{
  "error": {
    "code": "unauthorized",
    "message": "Missing or invalid API key."
  }
}
DanskAdresseAPI