Skip to content
Internal docs

Location Lookup

Endpoint

POST /partner/location/

Also mounted at POST /api/v1/location/ (identical behavior).

Auth: None (public). Limited to 60 requests / minute — per API key when you send X-API-Key, otherwise per client IP.

Purpose

Resolve a location_hash you already hold to the street address it belongs to — for example, to display the install address for a session or hand-off. The lookup direction is hash → address, not address → hash.

Request body

Provide at least one of the two fields (location_hash is preferred; if both are sent, location_hash wins):

{
"location_hash": "a3f2b1c4e5"
}
Field Type Notes
location_hash string 10 lowercase hex characters. Preferred.
location_identifier string Legacy structured identifier.

Sending neither fails validation with "Provide location_hash or location_identifier" (422).

Response — 200 OK

The location’s address, as a flat object with these fields when the address has them: street, housenumber, postalcode, city, unitnumber, floor, country, latitude, longitude, full_address, province. Then four fields that identify the location itself (the first three added 2026-09-15, postal_unit added 2026-10-02):

{
"street": "Hauptstrasse",
"housenumber": "12",
"postalcode": "29553",
"city": "Bienenbuettel",
"country": "Germany",
"location_identifier": "DE-NI|BIENENBUETTEL-Hauptstrasse12|MER|UNIT-101",
"location_hash": "a3f2b1c4e5",
"building_id": "e27934d9-428e-4919-a966-61b8f52b5e89",
"postal_unit": "2B"
}
Field Type Notes
location_identifier string The structured identifier the order flows key on.
location_hash string | null The short public form — use this in links and QR codes, never the identifier.
building_id string | null The building behind the switch port; null when the port’s switch is not assigned to a building yet.
postal_unit string | null The suite label the customer’s postal address uses when it differs from the unit id (unitnumber and the unit id in location_identifier are unchanged). null when the port resolves to no unit, the unit carries no separate label, or the unit lookup fails (the lookup failure is swallowed, the request still returns 200).

Errors

Status Detail
404 "Location not found"
422 "Invalid location_hash format" — not 10 lowercase hex chars
422 Model validation — neither field provided
429 Rate limit exceeded — 60 requests / minute

POST /partner/location/details exists on the same router and resolves a hash to the address (with unit number and floor). For kurnl staff it also names the port (location_identifier, port_type, interface) and the switch — never the switch’s own address; a provider’s staff get the hash and the address only. It needs a staff login allowed to add customers (subscribers:write; other logins get 403) and is not callable with partner credentials.