GET /api/v1/cities/{slug}/base
Stadt-Stammdaten aus Wikidata
Liefert Einwohnerzahl, Fläche und Geo-Koordinaten einer Stadt aus Wikidata im kanonischen Envelope mit Attribution und Lizenz-Tag. Ist die Quelle deaktiviert, antwortet die Route mit 200, data=null und meta.source_status="disabled" (nie 5xx). Ist der Upstream tot und liegt kein zwischengespeicherter Wert vor, kommt 503 mit einem Hint auf GET /api/v1/health.
Parameter
| Name | In | Pflicht | Typ | Beschreibung |
|---|---|---|---|---|
slug | path | ja | string |
Code-Beispiele
curl "https://infranode.dev/api/v1/cities/hamburg/base"const res = await fetch("https://infranode.dev/api/v1/cities/hamburg/base");
const data = await res.json();
console.log(data);import httpx
res = httpx.get("https://infranode.dev/api/v1/cities/hamburg/base")
res.raise_for_status()
print(res.json())