List of regions
Directory of regions (2.0)
2GIS API Support: api@2gis.ru URL: https://docs.2gis.com/
Getting a list of regions according to parameters
Provides a list of all available regions for the specified parameters.
query Parameters
| key required | string A unique key of API user. |
| page | integer Default: 1 The number of the requested page. |
| page_size | integer [ 1 .. 2000 ] Default: 1000 Number of search results displayed on one page. |
| locale | string The locale with which the search is performed and given results. |
| locale_filter | Array of strings Example: locale_filter=ru_RU List of locales separated by commas that you use to filter. |
| country_code_filter | string Example: country_code_filter=ru List of country codes separated by commas that you use to filter. |
| fields | Array of strings Additional fields to be displayed in the response should be separated by commas.
|
| type | string Default: "region" Examples:
A filter by object type, the types should be comma separated.
|
Responses
Response Schema:
required | object (ObjMeta) Response metadata |
required | object Main result |
Response samples
- 200
- 400
- 403
- 404
- 500
Content type
{- "meta": {
- "api_version": "dev",
- "issue_date": "string",
- "code": 200
}, - "result": {
- "items": [
- {
- "id": "123456",
- "type": "region",
- "country_code": "st",
- "uri_aliases": [
- "string"
], - "satellites": [
- {
- "id": "123456",
- "name": "Moscow",
- "geometry": "POLYGON((83.4457915421126 53.4866943332863,84.0879338133862 53.4866943332863,84.0879338133862 53.1585977185895,83.4457915421126 53.1585977185895,83.4457915421126 53.4866943332863)",
- "centroid": "POINT(83.4457915421126 53.4866943332863)"
}
], - "flags": {
- "parking_layer": true,
- "ctx_layer": true,
- "road_network": true,
- "truck_graph": true,
- "traffic": true,
- "public_transport": true,
- "flamp": true,
- "2gis_reviews": true,
- "has_net_booklet": true,
- "gdpr": true,
- "metro": true,
- "pedestrian_routing": true
}, - "bounds": "POLYGON((83.4457915421126 53.4866943332863,84.0879338133862 53.4866943332863,84.0879338133862 53.1585977185895,83.4457915421126 53.1585977185895,83.4457915421126 53.4866943332863)",
- "domain": "ru",
- "default_pos": {
- "lon": "43.2988455",
- "lat": "56.7724145",
- "zoom": "11"
}, - "zoom_level": {
- "min": 22,
- "max": 22
}, - "tips_languages": "{\"ru\": \"ru\"}",
- "statistics": {
- "route_count": 0,
- "rubric_count": 0,
- "org_count": 0,
- "branch_count": 0
}, - "time_zone": {
- "offset": 240,
- "name": "Asia/Novosibirsk"
}, - "settlements": [
- "string"
], - "code": "nnovgorod",
- "seo": {
- "description": "string",
- "title": "string"
}, - "locale": "ru_RU",
- "uri_code": "nnovgorod",
- "name": "Moscow",
- "online_languages": {
- "available": "string",
- "default_lang": "string"
}, - "locales": "ru_RU",
- "name_grammatical_cases": {
- "genitive": "of Novosibirsk",
- "prepositional": "in Novosibirsk",
- "accusative": "Novosibirsk",
- "dative": "to Novosibirsk"
}
}
], - "total": 1
}
}