get
locations
https://api.srgssr.ch/polis-api/v2 /locations
Name | Values | Description |
---|---|---|
lang |
The language of the multilanguage content. Must be one of "de" (German), "fr" (French), "it" (Italian), "rr" (Romansch), "en" (English) |
|
parentid |
If you provide a parentid, the output will be filtered to the locations that have that parentid. If there are no locations with that parentid, the No Data XML will be delivered. |
|
date |
The list of locations changes from time to time, eg. because of Community Fusions. If you provide a date, you will receive the valid location list of that date. |
|
locationtypeid |
The type of the location. Must be one of "1 - Country (Land)", "2 - Canton (Kanton)", "3 - Destrict (Bezirk)", "4 - Community (Gemeinde)", "5 - Swiss citizens living abroad (Ausland Schweizer)", "6 - Urban District (Stadtkreis)" |
Name | Values | Description |
---|---|---|
accept |
|
|
Authorization
(required) |
Pass the access-key as a Bearer token in Authorization header. In the developer portal, Authorization header is attached on OAuth authentication. |
HTTP Code | Error Code | Description |
---|---|---|
400 | 400 |
Object of type BadRequest. |
401 | 401 |
Object of type TokenError |
403 | 403 |
Object of type QuotaViolation. |
404 | 404 |
Object of type UnknownResource. |
405 | 405 |
Object of type MethodNotAllowed. |
Resource Summary
Security |
Category |
---|---|
Locations |