hought.geodb.geodb-java-client.1.4.2.source-code.swagger.json Maven / Gradle / Ivy
{
"swagger": "2.0",
"info": {
"version": "1.0.0",
"title": "GeoDB Cities API",
"description": "The GeoDB API focuses on getting global city and region data. Easily obtain country, region, and city data for use\nin your apps! \n\n - Filter cities by name prefix, country, location, time-zone, and even minimum population.
\n - Sort cities by name, country code, elevation, and population - or any combination of these.
\n - Get all country regions.
- Get all cities in a given region.
\n - \n Display results in multiple languages.
- RESTful API adheres to industry best-practices, including\n HATEOAS-style links to facilitate paging results.\n
\n - Backed by cloud-based load-balanced infrastructure for resiliency and performance!
\n - Data is periodically refreshed from GeoNames and WikiData.
\n
\nNotes:\n
\n - \n Since the database is periodically updated, this may very rarely result in certain cities\n being marked deleted (e.g., duplicates removed). By default, endpoints returning city data will exclude\n cities marked deleted. However, in the unlikely event that this occurs while your app is paging through a set\n of affected results - and you care about the paged results suddenly changing underneath - specify \n includeDeleted=SINCE_YESTERDAY (or SINCE_LAST_WEEK if you're really paranoid!).\n
\n
\n
\nUseful Resources
\n\n - \n SDKs\n
\n - \n Angular, \n Sample App\n
\n - Java
\n - JavaScript
\n
\n - Swagger Docs
\n - Usage License
\n \n
\n",
"license": {
"name": "Creative Commons Attribution 3.0",
"url": "http://creativecommons.org/licenses/by/3.0/"
}
},
"host": "wft-geo-db.p.rapidapi.com",
"basePath": "/v1",
"schemes": [
"https"
],
"produces": [
"application/json"
],
"tags": [
{
"name": "Geo",
"description": "Geo Endpoints"
},
{
"name": "Locale",
"description": "Locale Endpoints"
}
],
"securityDefinitions": {
"UserSecurity": {
"type": "apiKey",
"name": "x-rapidapi-key",
"in": "header"
}
},
"security": [
{
"UserSecurity": []
}
],
"paths": {
"/geo/adminDivisions": {
"get": {
"tags": [
"Geo"
],
"summary": "Find administrative divisions",
"description": "Find administrative divisions, filtering by optional criteria. If no criteria are set, you will get back all\nknown divisions.\n",
"operationId": "findAdminDivisionsUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/query.place.location.id"
},
{
"$ref": "#/parameters/query.place.location.radiusOf"
},
{
"$ref": "#/parameters/query.distanceUnit"
},
{
"$ref": "#/parameters/query.place.countryIds"
},
{
"$ref": "#/parameters/query.place.excludedCountryIds"
},
{
"$ref": "#/parameters/query.place.minPopulation"
},
{
"$ref": "#/parameters/query.place.maxPopulation"
},
{
"$ref": "#/parameters/query.entity.namePrefix"
},
{
"$ref": "#/parameters/query.timeZoneIds"
},
{
"$ref": "#/parameters/query.asciiMode"
},
{
"$ref": "#/parameters/query.hateoasMode"
},
{
"$ref": "#/parameters/query.languageCode"
},
{
"$ref": "#/parameters/query.limit"
},
{
"$ref": "#/parameters/query.offset"
},
{
"$ref": "#/parameters/query.place.sort"
},
{
"$ref": "#/parameters/query.includeDeleted"
}
],
"responses": {
"200": {
"$ref": "#/responses/PopulatedPlaces"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
}
}
}
},
"/geo/adminDivisions/{divisionId}/nearbyDivisions": {
"get": {
"tags": [
"Geo"
],
"summary": "Find divisions near division",
"description": "Find administrative divisions near the given origin division, filtering by optional criteria. If no criteria\nare set, you will get back all known divisions.\n",
"operationId": "findDivisionsNearAdminDivisionUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/path.divisionId"
},
{
"$ref": "#/parameters/query.place.location.radiusOf"
},
{
"$ref": "#/parameters/query.distanceUnit"
},
{
"$ref": "#/parameters/query.place.countryIds"
},
{
"$ref": "#/parameters/query.place.excludedCountryIds"
},
{
"$ref": "#/parameters/query.place.minPopulation"
},
{
"$ref": "#/parameters/query.place.maxPopulation"
},
{
"$ref": "#/parameters/query.entity.namePrefix"
},
{
"$ref": "#/parameters/query.timeZoneIds"
},
{
"$ref": "#/parameters/query.asciiMode"
},
{
"$ref": "#/parameters/query.hateoasMode"
},
{
"$ref": "#/parameters/query.languageCode"
},
{
"$ref": "#/parameters/query.limit"
},
{
"$ref": "#/parameters/query.offset"
},
{
"$ref": "#/parameters/query.place.sort"
},
{
"$ref": "#/parameters/query.includeDeleted"
}
],
"responses": {
"200": {
"$ref": "#/responses/PopulatedPlaces"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
},
"404": {
"$ref": "#/responses/NotFound"
}
}
}
},
"/geo/adminDivisions/{divisionId}/nearbyCities": {
"get": {
"tags": [
"Geo"
],
"summary": "Find cities near division",
"description": "Find cities near the given administrative division, filtering by optional criteria. If no criteria are set, you\nwill get back all known cities.\n",
"operationId": "findCitiesNearAdminDivisionUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/path.divisionId"
},
{
"$ref": "#/parameters/query.place.location.radiusOf"
},
{
"$ref": "#/parameters/query.distanceUnit"
},
{
"$ref": "#/parameters/query.place.countryIds"
},
{
"$ref": "#/parameters/query.place.excludedCountryIds"
},
{
"$ref": "#/parameters/query.place.minPopulation"
},
{
"$ref": "#/parameters/query.place.maxPopulation"
},
{
"$ref": "#/parameters/query.entity.namePrefix"
},
{
"$ref": "#/parameters/query.timeZoneIds"
},
{
"$ref": "#/parameters/query.place.types"
},
{
"$ref": "#/parameters/query.asciiMode"
},
{
"$ref": "#/parameters/query.hateoasMode"
},
{
"$ref": "#/parameters/query.languageCode"
},
{
"$ref": "#/parameters/query.limit"
},
{
"$ref": "#/parameters/query.offset"
},
{
"$ref": "#/parameters/query.place.sort"
},
{
"$ref": "#/parameters/query.includeDeleted"
}
],
"responses": {
"200": {
"$ref": "#/responses/PopulatedPlaces"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
},
"404": {
"$ref": "#/responses/NotFound"
}
}
}
},
"/geo/cities": {
"get": {
"tags": [
"Geo"
],
"summary": "Find cities",
"description": "Find cities, filtering by optional criteria. If no criteria are set, you will get back all known cities.\n",
"operationId": "findCitiesUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/query.place.location.id"
},
{
"$ref": "#/parameters/query.place.location.radiusOf"
},
{
"$ref": "#/parameters/query.distanceUnit"
},
{
"$ref": "#/parameters/query.place.countryIds"
},
{
"$ref": "#/parameters/query.place.excludedCountryIds"
},
{
"$ref": "#/parameters/query.place.minPopulation"
},
{
"$ref": "#/parameters/query.place.maxPopulation"
},
{
"$ref": "#/parameters/query.entity.namePrefix"
},
{
"$ref": "#/parameters/query.timeZoneIds"
},
{
"$ref": "#/parameters/query.place.types"
},
{
"$ref": "#/parameters/query.asciiMode"
},
{
"$ref": "#/parameters/query.hateoasMode"
},
{
"$ref": "#/parameters/query.languageCode"
},
{
"$ref": "#/parameters/query.limit"
},
{
"$ref": "#/parameters/query.offset"
},
{
"$ref": "#/parameters/query.place.sort"
},
{
"$ref": "#/parameters/query.includeDeleted"
}
],
"responses": {
"200": {
"$ref": "#/responses/PopulatedPlaces"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
}
}
}
},
"/geo/cities/{cityId}/nearbyCities": {
"get": {
"tags": [
"Geo"
],
"summary": "Find cities near city",
"description": "Find cities near the given origin city, filtering by optional criteria. If no criteria are set, you will get\nback all known cities.\n",
"operationId": "findCitiesNearCityUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/path.cityId"
},
{
"$ref": "#/parameters/query.place.location.radiusOf"
},
{
"$ref": "#/parameters/query.distanceUnit"
},
{
"$ref": "#/parameters/query.place.countryIds"
},
{
"$ref": "#/parameters/query.place.excludedCountryIds"
},
{
"$ref": "#/parameters/query.place.minPopulation"
},
{
"$ref": "#/parameters/query.place.maxPopulation"
},
{
"$ref": "#/parameters/query.entity.namePrefix"
},
{
"$ref": "#/parameters/query.timeZoneIds"
},
{
"$ref": "#/parameters/query.place.types"
},
{
"$ref": "#/parameters/query.asciiMode"
},
{
"$ref": "#/parameters/query.hateoasMode"
},
{
"$ref": "#/parameters/query.languageCode"
},
{
"$ref": "#/parameters/query.limit"
},
{
"$ref": "#/parameters/query.offset"
},
{
"$ref": "#/parameters/query.place.sort"
},
{
"$ref": "#/parameters/query.includeDeleted"
}
],
"responses": {
"200": {
"$ref": "#/responses/PopulatedPlaces"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
},
"404": {
"$ref": "#/responses/NotFound"
}
}
}
},
"/geo/locations/{locationId}/nearbyDivisions": {
"get": {
"tags": [
"Geo"
],
"summary": "Find divisions near location",
"description": "Find administrative divisions near the given location, filtering by optional criteria. If no criteria are set,\nyou will get back all known divisions.\n",
"operationId": "findDivisionsNearLocationUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/path.location.id"
},
{
"$ref": "#/parameters/query.place.location.radiusOf"
},
{
"$ref": "#/parameters/query.distanceUnit"
},
{
"$ref": "#/parameters/query.place.countryIds"
},
{
"$ref": "#/parameters/query.place.excludedCountryIds"
},
{
"$ref": "#/parameters/query.place.minPopulation"
},
{
"$ref": "#/parameters/query.place.maxPopulation"
},
{
"$ref": "#/parameters/query.entity.namePrefix"
},
{
"$ref": "#/parameters/query.timeZoneIds"
},
{
"$ref": "#/parameters/query.asciiMode"
},
{
"$ref": "#/parameters/query.hateoasMode"
},
{
"$ref": "#/parameters/query.languageCode"
},
{
"$ref": "#/parameters/query.limit"
},
{
"$ref": "#/parameters/query.offset"
},
{
"$ref": "#/parameters/query.place.sort"
},
{
"$ref": "#/parameters/query.includeDeleted"
}
],
"responses": {
"200": {
"$ref": "#/responses/PopulatedPlaces"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
}
}
}
},
"/geo/locations/{locationId}/nearbyCities": {
"get": {
"tags": [
"Geo"
],
"summary": "Find cities near location",
"description": "Find cities near the given location, filtering by optional criteria. If no criteria are set, you will get back\nall known cities.\n",
"operationId": "findCitiesNearLocationUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/path.location.id"
},
{
"$ref": "#/parameters/query.place.location.radiusOf"
},
{
"$ref": "#/parameters/query.distanceUnit"
},
{
"$ref": "#/parameters/query.place.countryIds"
},
{
"$ref": "#/parameters/query.place.excludedCountryIds"
},
{
"$ref": "#/parameters/query.place.minPopulation"
},
{
"$ref": "#/parameters/query.place.maxPopulation"
},
{
"$ref": "#/parameters/query.entity.namePrefix"
},
{
"$ref": "#/parameters/query.timeZoneIds"
},
{
"$ref": "#/parameters/query.place.types"
},
{
"$ref": "#/parameters/query.asciiMode"
},
{
"$ref": "#/parameters/query.hateoasMode"
},
{
"$ref": "#/parameters/query.languageCode"
},
{
"$ref": "#/parameters/query.limit"
},
{
"$ref": "#/parameters/query.offset"
},
{
"$ref": "#/parameters/query.place.sort"
},
{
"$ref": "#/parameters/query.includeDeleted"
}
],
"responses": {
"200": {
"$ref": "#/responses/PopulatedPlaces"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
}
}
}
},
"/geo/adminDivisions/{divisionId}": {
"get": {
"tags": [
"Geo"
],
"summary": "Get administrative division details",
"description": "Get the details for a specific administrative division, including location coordinates, population, and\nelevation above sea-level (if available).\n",
"operationId": "getAdminDivisionUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/path.divisionId"
},
{
"$ref": "#/parameters/query.asciiMode"
},
{
"$ref": "#/parameters/query.languageCode"
}
],
"responses": {
"200": {
"$ref": "#/responses/PopulatedPlace"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
},
"404": {
"$ref": "#/responses/NotFound"
}
}
}
},
"/geo/cities/{cityId}": {
"get": {
"tags": [
"Geo"
],
"summary": "Get city details",
"description": "Get the details for a specific city, including location coordinates, population, and elevation above sea-level\n(if available).\n",
"operationId": "getCityUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/path.cityId"
},
{
"$ref": "#/parameters/query.asciiMode"
},
{
"$ref": "#/parameters/query.languageCode"
}
],
"responses": {
"200": {
"$ref": "#/responses/PopulatedPlace"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
},
"404": {
"$ref": "#/responses/NotFound"
}
}
}
},
"/geo/cities/{cityId}/distance": {
"get": {
"tags": [
"Geo"
],
"summary": "Get city distance",
"description": "Get distance from the given city",
"operationId": "getCityDistanceUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/path.cityId"
},
{
"$ref": "#/parameters/query.toCityId"
},
{
"$ref": "#/parameters/query.distanceUnit"
}
],
"responses": {
"200": {
"$ref": "#/responses/Distance"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
},
"404": {
"$ref": "#/responses/NotFound"
}
}
}
},
"/geo/cities/{cityId}/dateTime": {
"get": {
"tags": [
"Geo"
],
"summary": "Get city date-time",
"description": "Get city date-time",
"operationId": "getCityDateTimeUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/path.cityId"
}
],
"responses": {
"200": {
"$ref": "#/responses/DateTime"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
},
"404": {
"$ref": "#/responses/NotFound"
}
}
}
},
"/geo/cities/{cityId}/locatedIn": {
"get": {
"tags": [
"Geo"
],
"summary": "Get this city's containing populated place (e.g., its county or other administrative division)",
"description": "Get the details for the containing populated place, including location coordinates, population, and elevation above sea-level\n(if available).\n",
"operationId": "getCityLocatedInUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/path.cityId"
},
{
"$ref": "#/parameters/query.asciiMode"
},
{
"$ref": "#/parameters/query.languageCode"
}
],
"responses": {
"200": {
"$ref": "#/responses/PopulatedPlace"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
},
"404": {
"$ref": "#/responses/NotFound"
}
}
}
},
"/geo/cities/{cityId}/time": {
"get": {
"tags": [
"Geo"
],
"summary": "Get city time",
"description": "Get city time",
"operationId": "getCityTimeUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/path.cityId"
}
],
"responses": {
"200": {
"$ref": "#/responses/Time"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
},
"404": {
"$ref": "#/responses/NotFound"
}
}
}
},
"/geo/countries": {
"get": {
"tags": [
"Geo"
],
"summary": "Find countries",
"description": "Find countries, filtering by optional criteria. If no criteria are set, you will get back all known countries.\n",
"operationId": "getCountriesUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/query.country.currencyCode"
},
{
"$ref": "#/parameters/query.entity.namePrefix"
},
{
"$ref": "#/parameters/query.asciiMode"
},
{
"$ref": "#/parameters/query.hateoasMode"
},
{
"$ref": "#/parameters/query.languageCode"
},
{
"$ref": "#/parameters/query.limit"
},
{
"$ref": "#/parameters/query.offset"
}
],
"responses": {
"200": {
"$ref": "#/responses/Countries"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
}
}
}
},
"/geo/countries/{countryId}": {
"get": {
"tags": [
"Geo"
],
"summary": "Get country details",
"description": "Get the details for a specific country, including number of regions.",
"operationId": "getCountryUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/path.countryId"
},
{
"$ref": "#/parameters/query.asciiMode"
},
{
"$ref": "#/parameters/query.languageCode"
}
],
"responses": {
"200": {
"$ref": "#/responses/Country"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
},
"404": {
"$ref": "#/responses/NotFound"
}
}
}
},
"/geo/countries/{countryId}/regions": {
"get": {
"tags": [
"Geo"
],
"summary": "Find country regions",
"description": "Get all regions in a specific country. These could be states, provinces, districts, or otherwise major\npolitical divisions.\n",
"operationId": "getRegionsUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/path.countryId"
},
{
"$ref": "#/parameters/query.entity.namePrefix"
},
{
"$ref": "#/parameters/query.asciiMode"
},
{
"$ref": "#/parameters/query.hateoasMode"
},
{
"$ref": "#/parameters/query.languageCode"
},
{
"$ref": "#/parameters/query.limit"
},
{
"$ref": "#/parameters/query.offset"
}
],
"responses": {
"200": {
"$ref": "#/responses/Regions"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
},
"404": {
"$ref": "#/responses/NotFound"
}
}
}
},
"/geo/countries/{countryId}/regions/{regionCode}": {
"get": {
"tags": [
"Geo"
],
"summary": "Get region details",
"description": "Get the details of a specific country region, including number of cities.",
"operationId": "getRegionUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/path.countryId"
},
{
"$ref": "#/parameters/path.regionCode"
},
{
"$ref": "#/parameters/query.asciiMode"
},
{
"$ref": "#/parameters/query.languageCode"
}
],
"responses": {
"200": {
"$ref": "#/responses/Region"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
},
"404": {
"$ref": "#/responses/NotFound"
}
}
}
},
"/geo/countries/{countryId}/regions/{regionCode}/adminDivisions": {
"get": {
"tags": [
"Geo"
],
"summary": "Find country region administrative divisions",
"description": "Get the administrative divisions in a specific country region. The country and region info is omitted in the\nresponse.\n",
"operationId": "findRegionDivisionsUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/path.countryId"
},
{
"$ref": "#/parameters/path.regionCode"
},
{
"$ref": "#/parameters/query.place.minPopulation"
},
{
"$ref": "#/parameters/query.place.maxPopulation"
},
{
"$ref": "#/parameters/query.entity.namePrefix"
},
{
"$ref": "#/parameters/query.timeZoneIds"
},
{
"$ref": "#/parameters/query.asciiMode"
},
{
"$ref": "#/parameters/query.hateoasMode"
},
{
"$ref": "#/parameters/query.languageCode"
},
{
"$ref": "#/parameters/query.limit"
},
{
"$ref": "#/parameters/query.offset"
},
{
"$ref": "#/parameters/query.place.sort.withinRegion"
},
{
"$ref": "#/parameters/query.includeDeleted"
}
],
"responses": {
"200": {
"$ref": "#/responses/PopulatedPlaces"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
},
"404": {
"$ref": "#/responses/NotFound"
}
}
}
},
"/geo/countries/{countryId}/regions/{regionCode}/cities": {
"get": {
"tags": [
"Geo"
],
"summary": "Find country region cities",
"description": "Get the cities in a specific country region. The country and region info is omitted in the response.\n",
"operationId": "findRegionCitiesUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/path.countryId"
},
{
"$ref": "#/parameters/path.regionCode"
},
{
"$ref": "#/parameters/query.place.minPopulation"
},
{
"$ref": "#/parameters/query.place.maxPopulation"
},
{
"$ref": "#/parameters/query.entity.namePrefix"
},
{
"$ref": "#/parameters/query.timeZoneIds"
},
{
"$ref": "#/parameters/query.place.types"
},
{
"$ref": "#/parameters/query.asciiMode"
},
{
"$ref": "#/parameters/query.hateoasMode"
},
{
"$ref": "#/parameters/query.languageCode"
},
{
"$ref": "#/parameters/query.limit"
},
{
"$ref": "#/parameters/query.offset"
},
{
"$ref": "#/parameters/query.place.sort.withinRegion"
},
{
"$ref": "#/parameters/query.includeDeleted"
}
],
"responses": {
"200": {
"$ref": "#/responses/PopulatedPlaces"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
},
"404": {
"$ref": "#/responses/NotFound"
}
}
}
},
"/locale/currencies": {
"get": {
"tags": [
"Locale"
],
"summary": "Find currencies",
"description": "Find currencies, filtering by optional criteria. If no criteria are set, you will get back all known currencies.",
"operationId": "getCurrenciesUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/query.currency.countryId"
},
{
"$ref": "#/parameters/query.hateoasMode"
},
{
"$ref": "#/parameters/query.limit"
},
{
"$ref": "#/parameters/query.offset"
}
],
"responses": {
"200": {
"$ref": "#/responses/Currencies"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
}
}
}
},
"/locale/languages": {
"get": {
"tags": [
"Locale"
],
"summary": "Get languages",
"description": "Get all supported languages",
"operationId": "getLanguagesUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/query.hateoasMode"
},
{
"$ref": "#/parameters/query.limit"
},
{
"$ref": "#/parameters/query.offset"
}
],
"responses": {
"200": {
"$ref": "#/responses/Languages"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
}
}
}
},
"/locale/locales": {
"get": {
"tags": [
"Locale"
],
"summary": "Get locales",
"description": "Get all known locales",
"operationId": "getLocalesUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/query.hateoasMode"
},
{
"$ref": "#/parameters/query.limit"
},
{
"$ref": "#/parameters/query.offset"
}
],
"responses": {
"200": {
"$ref": "#/responses/Locales"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
}
}
}
},
"/locale/timezones": {
"get": {
"tags": [
"Locale"
],
"summary": "Get time-zones",
"description": "Get all known time-zones",
"operationId": "getTimezonesUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/query.hateoasMode"
},
{
"$ref": "#/parameters/query.limit"
},
{
"$ref": "#/parameters/query.offset"
}
],
"responses": {
"200": {
"$ref": "#/responses/TimeZones"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
}
}
}
},
"/locale/timezones/{zoneId}/dateTime": {
"get": {
"tags": [
"Locale"
],
"summary": "Get time-zone date-time",
"description": "Get time-zone date-time",
"operationId": "getTimeZoneDateTimeUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/path.zoneId"
}
],
"responses": {
"200": {
"$ref": "#/responses/DateTime"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
},
"404": {
"$ref": "#/responses/NotFound"
}
}
}
},
"/locale/timezones/{zoneId}/time": {
"get": {
"tags": [
"Locale"
],
"summary": "Get time-zone time",
"description": "Get time-zone time",
"operationId": "getTimeZoneTimeUsingGET",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"$ref": "#/parameters/path.zoneId"
}
],
"responses": {
"200": {
"$ref": "#/responses/Time"
},
"400": {
"$ref": "#/responses/BadRequest"
},
"401": {
"$ref": "#/responses/Unauthorized"
},
"403": {
"$ref": "#/responses/Forbidden"
},
"404": {
"$ref": "#/responses/NotFound"
}
}
}
}
},
"parameters": {
"path.cityId": {
"name": "cityId",
"in": "path",
"description": "A city id (either native 'id' or 'wikiDataId')",
"required": true,
"type": "string"
},
"path.countryId": {
"name": "countryId",
"in": "path",
"description": "An ISO-3166 country code or WikiData id",
"required": true,
"type": "string"
},
"query.country.currencyCode": {
"name": "currencyCode",
"in": "query",
"description": "Only countries supporting this currency",
"required": false,
"type": "string"
},
"query.currency.countryId": {
"name": "countryId",
"in": "query",
"description": "Currencies for this country id",
"required": true,
"type": "string"
},
"path.divisionId": {
"name": "divisionId",
"in": "path",
"description": "An admin-division id (either native 'id' or 'wikiDataId')",
"required": true,
"type": "string"
},
"query.entity.namePrefix": {
"name": "namePrefix",
"in": "query",
"description": "Only entities whose names start with this prefix. If languageCode is set, the prefix will be matched on the name\nas it appears in that language.\n",
"required": false,
"type": "string"
},
"path.location.id": {
"name": "locationId",
"in": "path",
"description": "A latitude/longitude in ISO-6709 format: ±DD.DDDD±DDD.DDDD",
"required": true,
"type": "string"
},
"query.distanceUnit": {
"name": "distanceUnit",
"in": "query",
"description": "The unit of distance: MI | KM",
"required": false,
"type": "string",
"default": "MI"
},
"query.toCityId": {
"name": "toCityId",
"in": "query",
"description": "Distance to this city",
"required": true,
"type": "string"
},
"query.place.countryIds": {
"name": "countryIds",
"in": "query",
"description": "Only places in these countries (comma-delimited country codes or WikiData ids)",
"required": false,
"type": "string"
},
"query.place.excludedCountryIds": {
"name": "excludedCountryIds",
"in": "query",
"description": "Only places NOT in these countries (comma-delimited country codes or WikiData ids)",
"required": false,
"type": "string"
},
"query.place.location.id": {
"name": "location",
"in": "query",
"description": "Only places near this location. Latitude/longitude in ISO-6709 format: ±DD.DDDD±DDD.DDDD",
"required": false,
"type": "string"
},
"query.place.location.radiusOf": {
"name": "radius",
"in": "query",
"description": "The location radius within which to find places",
"required": false,
"type": "integer",
"format": "int32"
},
"query.place.minPopulation": {
"name": "minPopulation",
"in": "query",
"description": "Only places having at least this population",
"required": false,
"type": "integer",
"format": "int32"
},
"query.place.maxPopulation": {
"name": "maxPopulation",
"in": "query",
"description": "Only places having no more than this population",
"required": false,
"type": "integer",
"format": "int32"
},
"query.place.types": {
"name": "types",
"in": "query",
"description": "Only places for these types (comma-delimited): CITY | ADM2",
"required": false,
"type": "string"
},
"query.place.sort": {
"name": "sort",
"in": "query",
"description": "How to sort place results. \n'Format: ±SORT_FIELD,±SORT_FIELD' \nwhere SORT_FIELD = countryCode | elevation | name | population\n",
"required": false,
"type": "string"
},
"query.place.sort.withinRegion": {
"name": "sort",
"in": "query",
"description": "How to sort place results. \n'Format: ±SORT_FIELD,±SORT_FIELD' \nwhere SORT_FIELD = elevation | name | population\n",
"required": false,
"type": "string"
},
"path.regionCode": {
"name": "regionCode",
"in": "path",
"description": "An ISO-3166 or FIPS region code",
"required": true,
"type": "string"
},
"path.zoneId": {
"name": "zoneId",
"in": "path",
"description": "A time-zone id",
"required": true,
"type": "string"
},
"query.timeZoneIds": {
"name": "timeZoneIds",
"in": "query",
"description": "Only places in these time-zones (comma-delimited)",
"required": false,
"type": "string"
},
"query.asciiMode": {
"name": "asciiMode",
"in": "query",
"description": "Display results using ASCII characters",
"required": false,
"type": "boolean",
"default": false
},
"query.hateoasMode": {
"name": "hateoasMode",
"in": "query",
"description": "Include HATEOAS-style links in results",
"required": false,
"type": "boolean",
"default": true
},
"query.languageCode": {
"name": "languageCode",
"in": "query",
"description": "Display results in this language",
"required": false,
"type": "string"
},
"query.limit": {
"name": "limit",
"in": "query",
"description": "The maximum number of results to retrieve",
"required": false,
"type": "integer",
"default": 10,
"format": "int32"
},
"query.offset": {
"name": "offset",
"in": "query",
"description": "The zero-ary offset index into the results",
"required": false,
"type": "integer",
"default": 0,
"format": "int32"
},
"query.sort": {
"name": "sort",
"in": "query",
"description": "How to sort place results. \n'Format: ±SORT_FIELD,±SORT_FIELD' \nwhere SORT_FIELD = countryCode | elevation | name | population\n",
"required": false,
"type": "string"
},
"query.includeDeleted": {
"name": "includeDeleted",
"in": "query",
"description": "Whether to include any divisions marked deleted: ALL | SINCE_YESTERDAY | SINCE_LAST_WEEK | NONE",
"required": false,
"type": "string",
"default": "NONE"
}
},
"responses": {
"Countries": {
"description": "A list of countries",
"schema": {
"$ref": "#/definitions/CountriesResponse"
}
},
"Country": {
"description": "Country detail",
"schema": {
"$ref": "#/definitions/CountryResponse"
}
},
"Currencies": {
"description": "A list of currencies",
"schema": {
"$ref": "#/definitions/CurrenciesResponse"
}
},
"DateTime": {
"description": "An ISO-6801 date-time",
"schema": {
"$ref": "#/definitions/DateTimeResponse"
}
},
"Distance": {
"description": "A decimal distance (in miles or kilometers)",
"schema": {
"$ref": "#/definitions/DistanceResponse"
}
},
"Languages": {
"description": "A list of languages supported by the system",
"schema": {
"$ref": "#/definitions/LanguagesResponse"
}
},
"Locales": {
"description": "A list of locales",
"schema": {
"$ref": "#/definitions/LocalesResponse"
}
},
"PopulatedPlace": {
"description": "Populated-place details",
"schema": {
"$ref": "#/definitions/PopulatedPlaceResponse"
}
},
"PopulatedPlaces": {
"description": "A list of populated places",
"schema": {
"$ref": "#/definitions/PopulatedPlacesResponse"
}
},
"Region": {
"description": "Country region details",
"schema": {
"$ref": "#/definitions/RegionResponse"
}
},
"Regions": {
"description": "A list of country regions",
"schema": {
"$ref": "#/definitions/RegionsResponse"
}
},
"Time": {
"description": "An ISO-8601 time response",
"schema": {
"$ref": "#/definitions/TimeResponse"
}
},
"TimeZones": {
"description": "A list of time-zones",
"schema": {
"$ref": "#/definitions/TimeZonesResponse"
}
},
"BadRequest": {
"description": "400 - Bad Request",
"schema": {
"$ref": "#/definitions/BadRequestResponse"
}
},
"Forbidden": {
"description": "403 - Forbidden",
"schema": {
"$ref": "#/definitions/ForbiddenResponse"
}
},
"NotFound": {
"description": "404 - Not Found",
"schema": {
"$ref": "#/definitions/NotFoundResponse"
}
},
"Unauthorized": {
"description": "401 - Unauthorized"
}
},
"definitions": {
"CountrySummary": {
"type": "object",
"title": "Country Summary",
"description": "Minimal country info",
"properties": {
"code": {
"description": "The ISO-3166 country code",
"type": "string"
},
"currencyCodes": {
"description": "A list of supported ISO-4217 currency codes",
"type": "array",
"items": {
"type": "string"
}
},
"name": {
"description": "The country name (varies by languageCode)",
"type": "string"
},
"wikiDataId": {
"description": "The country WikiData id",
"type": "string"
}
},
"example": {
"code": "US",
"currencyCodes": [
"USD"
],
"name": "United States",
"wikiDataId": "Q30"
}
},
"CountryDetails": {
"type": "object",
"title": "Country Details",
"description": "Full country details",
"properties": {
"code": {
"description": "The ISO-3166 country code",
"type": "string"
},
"currencyCodes": {
"description": "A list of supported ISO-4217 currency codes",
"type": "array",
"items": {
"type": "string"
}
},
"flagImageUri": {
"description": "The country flag image",
"type": "string"
},
"name": {
"description": "The country name (varies by languageCode)",
"type": "string"
},
"numRegions": {
"description": "The number of regions in this country",
"type": "integer",
"format": "int32"
},
"wikiDataId": {
"description": "The country WikiData id",
"type": "string"
}
},
"example": {
"code": "US",
"currencyCodes": [
"USD"
],
"flagImageUri": "http://commons.wikimedia.org/wiki/Special:FilePath/Flag%20of%20the%20United%20States.svg",
"name": "United States",
"numRegions": 56,
"wikiDataId": "Q30"
}
},
"Currency": {
"type": "object",
"title": "Currency",
"description": "Currency info",
"properties": {
"code": {
"description": "The ISO-4217 currency code",
"type": "string"
},
"countryCodes": {
"description": "A list of ISO-3166 country codes of countries supporting this currency",
"type": "array",
"items": {
"type": "string"
}
},
"symbol": {
"description": "The currency symbol",
"type": "string"
}
},
"example": {
"code": "USD",
"countryCodes": [
"PR",
"MP",
"IO",
"FM",
"PW",
"GU",
"BQ",
"TC",
"VG",
"AS",
"VI",
"TL",
"UM",
"MH",
"EC",
"US"
],
"symbol": "$"
}
},
"Error": {
"type": "object",
"title": "Error",
"description": "An error that occurred processing the request",
"properties": {
"code": {
"$ref": "#/definitions/ErrorCode"
},
"message": {
"type": "string"
}
},
"example": {
"code": "ENTITY_NOT_FOUND",
"message": "Param [someParam] has invalid value: invalidValue"
}
},
"ErrorCode": {
"type": "string",
"title": "ErrorCode",
"description": "One of a set of enumerated error codes representing the types of errors that can occur processing a\nrequest\n",
"enum": [
"ACCESS_DENIED",
"ENTITY_NOT_FOUND",
"INCOMPATIBLE",
"PARAM_INVALID",
"PARAMS_MUTUALLY_EXCLUSIVE",
"REQUEST_UNPROCESSABLE"
],
"example": "ENTITY_NOT_FOUND"
},
"LanguageDescriptor": {
"type": "object",
"title": "Language",
"description": "A language supported by the service",
"properties": {
"code": {
"type": "string",
"enum": [
"undefined",
"aa",
"ab",
"ae",
"af",
"ak",
"am",
"an",
"ar",
"as",
"av",
"ay",
"az",
"ba",
"be",
"bg",
"bh",
"bi",
"bm",
"bn",
"bo",
"br",
"bs",
"ca",
"ce",
"ch",
"co",
"cr",
"cs",
"cu",
"cv",
"cy",
"da",
"de",
"dv",
"dz",
"ee",
"el",
"en",
"eo",
"es",
"et",
"eu",
"fa",
"ff",
"fi",
"fj",
"fo",
"fr",
"fy",
"ga",
"gd",
"gl",
"gn",
"gu",
"gv",
"ha",
"he",
"hi",
"ho",
"hr",
"ht",
"hu",
"hy",
"hz",
"ia",
"id",
"ie",
"ig",
"ii",
"ik",
"io",
"is",
"it",
"iu",
"ja",
"jv",
"ka",
"kg",
"ki",
"kj",
"kk",
"kl",
"km",
"kn",
"ko",
"kr",
"ks",
"ku",
"kv",
"kw",
"ky",
"la",
"lb",
"lg",
"li",
"ln",
"lo",
"lt",
"lu",
"lv",
"mg",
"mh",
"mi",
"mk",
"ml",
"mn",
"mr",
"ms",
"mt",
"my",
"na",
"nb",
"nd",
"ne",
"ng",
"nl",
"nn",
"no",
"nr",
"nv",
"ny",
"oc",
"oj",
"om",
"or",
"os",
"pa",
"pi",
"pl",
"ps",
"pt",
"qu",
"rm",
"rn",
"ro",
"ru",
"rw",
"sa",
"sc",
"sd",
"se",
"sg",
"si",
"sk",
"sl",
"sm",
"sn",
"so",
"sq",
"sr",
"ss",
"st",
"su",
"sv",
"sw",
"ta",
"te",
"tg",
"th",
"ti",
"tk",
"tl",
"tn",
"to",
"tr",
"ts",
"tt",
"tw",
"ty",
"ug",
"uk",
"ur",
"uz",
"ve",
"vi",
"vo",
"wa",
"wo",
"xh",
"yi",
"yo",
"za",
"zh",
"zu"
]
},
"name": {
"type": "string"
}
},
"example": {
"code": "en",
"name": "English"
}
},
"Link": {
"type": "object",
"title": "Link",
"description": "A HATEAOS link",
"properties": {
"href": {
"type": "string"
},
"rel": {
"type": "string"
}
},
"example": {
"rel": "next",
"href": "/data/world/v1/geo/cities?offset=10&limit=10"
}
},
"Locale": {
"type": "object",
"title": "Locale",
"description": "A locale representing a language/region combination",
"properties": {
"code": {
"description": "The locale code",
"type": "string"
},
"name": {
"description": "The locale name",
"type": "string"
}
},
"example": {
"code": "en_US",
"name": "English (US)"
}
},
"Metadata": {
"type": "object",
"title": "Metadata",
"description": "Result metadata (currently only associated with collection results)",
"properties": {
"currentOffset": {
"description": "The zero-ary offset into the results (0 is the first result)",
"type": "integer",
"format": "int64"
},
"totalCount": {
"description": "The total number of results across pages",
"type": "integer",
"format": "int64"
}
},
"example": {
"currentOffset": 0,
"totalCount": 100
}
},
"PopulatedPlaceDetails": {
"type": "object",
"title": "Populated-Place Details",
"description": "Full populated-place details",
"properties": {
"country": {
"description": "The country name (varies by languageCode)",
"type": "string"
},
"countryCode": {
"description": "The ISO-3166 country code",
"type": "string"
},
"deleted": {
"description": "If this place has been soft-deleted",
"type": "boolean"
},
"elevationMeters": {
"description": "The place elevation (meters) above sea level",
"type": "integer",
"format": "int32"
},
"id": {
"description": "The place GeoDB native id",
"type": "integer",
"format": "int32"
},
"latitude": {
"description": "The place latittude (-90.0 to 90.0)",
"type": "number",
"format": "double"
},
"longitude": {
"description": "The place longitude (-180.0 to 180.0)",
"type": "number",
"format": "double"
},
"name": {
"description": "The place name (varies by languageCode)",
"type": "string"
},
"population": {
"description": "The place population",
"type": "integer",
"format": "int32"
},
"region": {
"description": "The region name (varies by languageCode)",
"type": "string"
},
"regionCode": {
"description": "The ISO or FIPS region code",
"type": "string"
},
"timezone": {
"description": "The place timezone id",
"type": "string"
},
"type": {
"description": "The place type",
"$ref": "#/definitions/PopulatedPlaceType"
},
"wikiDataId": {
"description": "The place WikiData id",
"type": "string"
}
},
"example": {
"id": 123214,
"wikiDataId": "Q60",
"type": "CITY",
"name": "New York City",
"country": "United States of America",
"countryCode": "US",
"region": "New York",
"regionCode": "NY",
"elevationMeters": 10,
"latitude": 40.67,
"longitude": -73.94,
"population": 8398748,
"timezone": "America__New_York",
"deleted": false
}
},
"PopulatedPlaceSummary": {
"type": "object",
"description": "Minimal populated-place info",
"properties": {
"country": {
"description": "The country name (varies by languageCode)",
"type": "string"
},
"countryCode": {
"description": "The ISO-3166 country code",
"type": "string"
},
"distance": {
"type": "number",
"format": "double",
"description": "Included if this is the result of a distance query"
},
"id": {
"description": "The place GeoDB native id",
"type": "integer",
"format": "int32"
},
"latitude": {
"description": "The place latittude (-90.0 to 90.0)",
"type": "number",
"format": "double"
},
"longitude": {
"description": "The place longitude (-180.0 to 180.0)",
"type": "number",
"format": "double"
},
"name": {
"description": "The place name (varies by languageCode)",
"type": "string"
},
"population": {
"description": "The place population",
"type": "integer",
"format": "int32"
},
"region": {
"description": "The region name (varies by languageCode)",
"type": "string"
},
"regionCode": {
"description": "The ISO or FIPS region code",
"type": "string"
},
"type": {
"description": "The place type",
"$ref": "#/definitions/PopulatedPlaceType"
},
"wikiDataId": {
"description": "The place WikiData id",
"type": "string"
}
},
"example": {
"id": 123214,
"wikiDataId": "Q60",
"type": "CITY",
"name": "New York City",
"country": "United States of America",
"countryCode": "US",
"region": "New York",
"regionCode": "NY",
"latitude": 40.67,
"longitude": -73.94
}
},
"PopulatedPlaceType": {
"type": "string",
"description": "One of a set of enumerated populated-place types known by the service (currently only level-2 admin divisions and\ncities)\n",
"enum": [
"ADM2",
"CITY"
],
"example": "CITY"
},
"RegionDetails": {
"type": "object",
"title": "Country Region Details",
"description": "Full country region details",
"properties": {
"capital": {
"description": "The region's capital city (varies by languageCode)",
"type": "string"
},
"countryCode": {
"description": "An ISO-3166 country code",
"type": "string"
},
"fipsCode": {
"description": "The FIPS 10-4 region code",
"type": "string"
},
"isoCode": {
"description": "The ISO region code",
"type": "string"
},
"name": {
"description": "The region name (varies by languageCode)",
"type": "string"
},
"numCities": {
"description": "The number of cities in this region",
"type": "integer",
"format": "int32"
},
"wikiDataId": {
"description": "The region WikiData id",
"type": "string"
}
},
"example": {
"capital": "Sacramento",
"countryCode": "US",
"fipsCode": 6,
"isoCode": "CA",
"name": "California",
"numCities": 1532,
"wikiDataId": "Q99"
}
},
"RegionSummary": {
"type": "object",
"title": "Country Region Summary",
"description": "Minimal country region info",
"properties": {
"countryCode": {
"description": "An ISO-3166 country code",
"type": "string"
},
"fipsCode": {
"description": "The FIPS 10-4 region code",
"type": "string"
},
"isoCode": {
"description": "The ISO region code",
"type": "string"
},
"name": {
"description": "The region name (varies by languageCode)",
"type": "string"
},
"wikiDataId": {
"description": "The region WikiData id",
"type": "string"
}
},
"example": {
"countryCode": "US",
"fipsCode": 6,
"isoCode": "CA",
"name": "California",
"wikiDataId": "Q99"
}
},
"TimeZoneDescriptor": {
"type": "object",
"title": "Time-Zone",
"description": "A time-zone",
"properties": {
"id": {
"description": "The time-zone id",
"type": "string"
},
"name": {
"description": "The time-zone name",
"type": "string"
},
"rawUtcOffsetHours": {
"description": "The number of hours this time-zone is offset from UTC",
"type": "integer",
"format": "int32"
}
},
"example": {
"id": "Africa__Abidjan",
"name": "Greenwich Mean Time",
"rawUtcOffsetHours": 0
}
},
"BaseResponse": {
"type": "object",
"title": "Base Response",
"description": "Common properties for all responses",
"properties": {
"errors": {
"title": "Errors",
"type": "array",
"items": {
"$ref": "#/definitions/Error"
}
}
},
"example": {
"errors": []
}
},
"BaseCollectionResponse": {
"type": "object",
"title": "Base Collection Response",
"description": "Common properties for all collection responses",
"allOf": [
{
"$ref": "#/definitions/BaseResponse"
},
{
"properties": {
"links": {
"title": "Links",
"type": "array",
"items": {
"$ref": "#/definitions/Link"
}
},
"metadata": {
"title": "Metadata",
"$ref": "#/definitions/Metadata"
}
}
}
],
"example": {
"links": [
{
"rel": "first",
"href": "/data/world/v1/some/resource?offset=0&limit=5"
},
{
"rel": "prev",
"href": "/data/world/v1/some/resource?offset=0&limit=5"
},
{
"rel": "next",
"href": "/data/world/v1/some/resource?offset=10&limit=5"
},
{
"rel": "last",
"href": "/data/world/v1/some/resource?offset=95&limit=5"
}
],
"metadata": {
"currentOffset": 5,
"totalCount": 100
}
}
},
"CountriesResponse": {
"type": "object",
"title": "Countries Response",
"description": "A list of countries",
"allOf": [
{
"$ref": "#/definitions/BaseCollectionResponse"
},
{
"properties": {
"data": {
"type": "array",
"title": "CountrySummaries",
"items": {
"$ref": "#/definitions/CountrySummary"
}
}
}
}
],
"example": {
"data": [
{
"code": "SM",
"currencyCodes": [
"EUR"
],
"name": "San Marino",
"wikiDataId": "Q238"
},
{
"code": "NE",
"currencyCodes": [
"XOF"
],
"name": "Niger",
"wikiDataId": "Q1032"
},
{
"code": "MT",
"currencyCodes": [
"EUR"
],
"name": "Malta",
"wikiDataId": "Q233"
},
{
"code": "KZ",
"currencyCodes": [
"KZT"
],
"name": "Kazakhstan",
"wikiDataId": "Q232"
},
{
"code": "KE",
"currencyCodes": [
"KES"
],
"name": "Kenya",
"wikiDataId": "Q114"
}
],
"links": [
{
"rel": "first",
"href": "/data/world/v1/geo/countries?offset=0&limit=5"
},
{
"rel": "prev",
"href": "/data/world/v1/geo/countries?offset=0&limit=5"
},
{
"rel": "next",
"href": "/data/world/v1/geo/countries?offset=10&limit=5"
},
{
"rel": "last",
"href": "/data/world/v1/geo/countries?offset=195&limit=5"
}
],
"metadata": {
"currentOffset": 5,
"totalCount": 198
}
}
},
"CountryResponse": {
"type": "object",
"title": "Country Response",
"description": "Country details response",
"allOf": [
{
"$ref": "#/definitions/BaseResponse"
},
{
"properties": {
"data": {
"$ref": "#/definitions/CountryDetails"
}
}
}
],
"example": {
"data": {
"code": "US",
"currencyCodes": [
"USD"
],
"flagImageUri": "http://commons.wikimedia.org/wiki/Special:FilePath/Flag%20of%20the%20United%20States.svg",
"name": "United States",
"numRegions": 56,
"wikiDataId": "Q30"
}
}
},
"CurrenciesResponse": {
"type": "object",
"title": "Currencies Response",
"description": "A list of currencies",
"allOf": [
{
"$ref": "#/definitions/BaseCollectionResponse"
},
{
"properties": {
"data": {
"type": "array",
"items": {
"$ref": "#/definitions/Currency"
}
}
}
}
],
"example": {
"data": [
{
"code": "AWG",
"countryCodes": [
"AW"
]
},
{
"code": "AZN",
"countryCodes": [
"AZ"
]
},
{
"code": "BAM",
"countryCodes": [
"BA"
]
},
{
"code": "BBD",
"countryCodes": [
"BB"
]
},
{
"code": "BDT",
"countryCodes": [
"BD"
]
}
],
"links": [
{
"rel": "first",
"href": "/data/world/v1/locale/currencies?offset=0&limit=5"
},
{
"rel": "prev",
"href": "/data/world/v1/locale/currencies?offset=5&limit=5"
},
{
"rel": "next",
"href": "/data/world/v1/locale/currencies?offset=15&limit=5"
},
{
"rel": "last",
"href": "/data/world/v1/locale/currencies?offset=200&limit=5"
}
],
"metadata": {
"currentOffset": 10,
"totalCount": 205
}
}
},
"DateTimeResponse": {
"type": "object",
"title": "Date-Time Response",
"description": "An ISO-6801 date-time response",
"allOf": [
{
"$ref": "#/definitions/BaseResponse"
},
{
"properties": {
"data": {
"description": "The date-time in ISO-6801 format: yyyyMMdd'T'HHmmssZ",
"type": "string",
"format": "date-time"
}
}
}
],
"example": {
"data": "2020-10-05T01:16:53.504604+04:30"
}
},
"DistanceResponse": {
"type": "object",
"title": "Distance Response",
"description": "A decimal distance (in miles or kilometers)",
"allOf": [
{
"$ref": "#/definitions/BaseResponse"
},
{
"properties": {
"data": {
"description": "The distance in units as set by the distanceUnit param (defaults to miles)",
"type": "number",
"format": "double"
}
}
}
],
"example": {
"data": 6707.9
}
},
"LanguagesResponse": {
"type": "object",
"title": "Languages Response",
"description": "A list of languages supported by the system",
"allOf": [
{
"$ref": "#/definitions/BaseCollectionResponse"
},
{
"properties": {
"data": {
"type": "array",
"items": {
"$ref": "#/definitions/LanguageDescriptor"
}
}
}
}
],
"example": {
"data": [
{
"code": "fr",
"name": "French"
},
{
"code": "it",
"name": "Italian"
},
{
"code": "pt",
"name": "Portuguese"
}
],
"links": [
{
"rel": "first",
"href": "/data/world/v1/locale/languages?offset=0&limit=3"
},
{
"rel": "prev",
"href": "/data/world/v1/locale/languages?offset=0&limit=3"
},
{
"rel": "next",
"href": "/data/world/v1/locale/languages?offset=6&limit=3"
},
{
"rel": "last",
"href": "/data/world/v1/locale/languages?offset=6&limit=3"
}
],
"metadata": {
"currentOffset": 3,
"totalCount": 8
}
}
},
"LocalesResponse": {
"type": "object",
"title": "Locales Response",
"description": "A list of locales",
"allOf": [
{
"$ref": "#/definitions/BaseCollectionResponse"
},
{
"properties": {
"data": {
"type": "array",
"items": {
"$ref": "#/definitions/Locale"
}
}
}
}
],
"example": {
"data": [
{
"code": "eu"
},
{
"code": "ar_MR"
},
{
"code": "es_DO"
},
{
"code": "ru"
},
{
"code": "az"
}
],
"links": [
{
"rel": "first",
"href": "/data/world/v1/locale/locales?offset=0&limit=5"
},
{
"rel": "prev",
"href": "/data/world/v1/locale/locales?offset=45&limit=5"
},
{
"rel": "next",
"href": "/data/world/v1/locale/locales?offset=55&limit=5"
},
{
"rel": "last",
"href": "/data/world/v1/locale/locales?offset=770&limit=5"
}
],
"metadata": {
"currentOffset": 50,
"totalCount": 772
}
}
},
"PopulatedPlacesResponse": {
"type": "object",
"title": "Populated-Places Response",
"description": "A list of populated places",
"allOf": [
{
"$ref": "#/definitions/BaseCollectionResponse"
},
{
"properties": {
"data": {
"type": "array",
"items": {
"$ref": "#/definitions/PopulatedPlaceSummary"
}
}
}
}
],
"example": {
"data": [
{
"id": 2987553,
"wikiDataId": "Q24371",
"type": "CITY",
"name": "L'Aldosa de Canillo",
"country": "Andorra",
"countryCode": "AD",
"region": "Canillo",
"regionCode": 2,
"latitude": 42.57777778,
"longitude": 1.61944444
},
{
"id": 3086756,
"wikiDataId": "Q24486",
"type": "CITY",
"name": "La Cortinada",
"country": "Andorra",
"countryCode": "AD",
"region": "Ordino",
"regionCode": 5,
"latitude": 42.57667,
"longitude": 1.51773
},
{
"id": 3056764,
"wikiDataId": "Q2536296",
"type": "CITY",
"name": "La Margineda",
"country": "Andorra",
"countryCode": "AD",
"region": "Andorra la Vella",
"regionCode": 7,
"latitude": 42.4859,
"longitude": 1.49045
},
{
"id": 978,
"wikiDataId": "Q3820973",
"type": "CITY",
"name": "La Massana",
"country": "Andorra",
"countryCode": "AD",
"region": "La Massana",
"regionCode": 4,
"latitude": 42.544354,
"longitude": 1.515427
},
{
"id": 759,
"wikiDataId": "Q1050185",
"type": "CITY",
"name": "Les Escaldes",
"country": "Andorra",
"countryCode": "AD",
"region": "Escaldes-Engordany",
"regionCode": "08",
"latitude": 42.5,
"longitude": 1.53333333
}
],
"links": [
{
"rel": "first",
"href": "/data/world/v1/geo/cities?offset=0&limit=5"
},
{
"rel": "prev",
"href": "/data/world/v1/geo/cities?offset=0&limit=5"
},
{
"rel": "next",
"href": "/data/world/v1/geo/cities?offset=10&limit=5"
},
{
"rel": "last",
"href": "/data/world/v1/geo/cities?offset=273685&limit=5"
}
],
"metadata": {
"currentOffset": 5,
"totalCount": 273690
}
}
},
"PopulatedPlaceResponse": {
"type": "object",
"title": "Populated-Place Response",
"description": "Populated-place details response",
"allOf": [
{
"$ref": "#/definitions/BaseResponse"
},
{
"properties": {
"data": {
"$ref": "#/definitions/PopulatedPlaceDetails"
}
}
}
],
"example": {
"data": {
"id": 123214,
"wikiDataId": "Q60",
"type": "CITY",
"name": "New York City",
"country": "United States of America",
"countryCode": "US",
"region": "New York",
"regionCode": "NY",
"elevationMeters": 10,
"latitude": 40.67,
"longitude": -73.94,
"population": 8398748,
"timezone": "America__New_York",
"deleted": false
}
}
},
"RegionResponse": {
"type": "object",
"title": "Country Region Response",
"description": "Country region details response",
"allOf": [
{
"$ref": "#/definitions/BaseResponse"
},
{
"properties": {
"data": {
"$ref": "#/definitions/RegionDetails"
}
}
}
],
"example": {
"data": {
"capital": "Sacramento",
"countryCode": "US",
"fipsCode": 6,
"isoCode": "CA",
"name": "California",
"numCities": 1532,
"wikiDataId": "Q99"
}
}
},
"RegionsResponse": {
"type": "object",
"title": "Country Regions Response",
"description": "A list of country regions",
"allOf": [
{
"$ref": "#/definitions/BaseCollectionResponse"
},
{
"properties": {
"data": {
"description": "A list of RegionSummaries",
"type": "array",
"items": {
"$ref": "#/definitions/RegionSummary"
}
}
}
}
],
"example": {
"data": [
{
"wikiDataId": "Q1439",
"fipsCode": 48,
"isoCode": "TX",
"name": "Texas",
"countryCode": "US"
},
{
"wikiDataId": "Q1397",
"fipsCode": 39,
"isoCode": "OH",
"name": "Ohio",
"countryCode": "US"
},
{
"wikiDataId": "Q1553",
"fipsCode": 31,
"isoCode": "NE",
"name": "Nebraska",
"countryCode": "US"
},
{
"wikiDataId": "Q16551",
"fipsCode": 50,
"isoCode": "VT",
"name": "Vermont",
"countryCode": "US"
},
{
"wikiDataId": "Q782",
"fipsCode": 15,
"isoCode": "HI",
"name": "Hawaii",
"countryCode": "US"
}
],
"links": [
{
"rel": "first",
"href": "/data/world/v1/geo/countries/US/regions?offset=0&limit=5"
},
{
"rel": "prev",
"href": "/data/world/v1/geo/countries/US/regions?offset=0&limit=5"
},
{
"rel": "next",
"href": "/data/world/v1/geo/countries/US/regions?offset=10&limit=5"
},
{
"rel": "last",
"href": "/data/world/v1/geo/countries/US/regions?offset=55&limit=5"
}
],
"metadata": {
"currentOffset": 5,
"totalCount": 56
}
}
},
"TimeResponse": {
"type": "object",
"title": "Time Response",
"description": "An ISO-8601 time response",
"allOf": [
{
"$ref": "#/definitions/BaseResponse"
},
{
"properties": {
"data": {
"description": "The time in ISO-8601 format: HHmmss.SSSZ",
"type": "string"
}
}
}
],
"example": {
"data": "19:21:38.796217"
}
},
"TimeZonesResponse": {
"type": "object",
"title": "Time-Zones Response",
"description": "A list of time-zones",
"allOf": [
{
"$ref": "#/definitions/BaseCollectionResponse"
},
{
"properties": {
"data": {
"type": "array",
"items": {
"$ref": "#/definitions/TimeZoneDescriptor"
}
}
}
}
],
"example": {
"data": [
{
"id": "America__Marigot",
"name": "Atlantic Standard Time",
"rawUtcOffsetHours": -4
},
{
"id": "Asia__Aqtau",
"name": "West Kazakhstan Time",
"rawUtcOffsetHours": 5
},
{
"id": "Pacific__Kwajalein",
"name": "Marshall Islands Time",
"rawUtcOffsetHours": 12
},
{
"id": "America__El_Salvador",
"name": "Central Standard Time",
"rawUtcOffsetHours": -6
},
{
"id": "Asia__Pontianak",
"name": "Western Indonesia Time",
"rawUtcOffsetHours": 7
}
],
"links": [
{
"rel": "first",
"href": "/data/world/v1/locale/timezones?offset=0&limit=5"
},
{
"rel": "prev",
"href": "/data/world/v1/locale/timezones?offset=0&limit=5"
},
{
"rel": "next",
"href": "/data/world/v1/locale/timezones?offset=10&limit=5"
},
{
"rel": "last",
"href": "/data/world/v1/locale/timezones?offset=595&limit=5"
}
],
"metadata": {
"currentOffset": 5,
"totalCount": 600
}
}
},
"BadRequestResponse": {
"type": "object",
"title": "Bad Request Response",
"description": "Bad Request Response",
"allOf": [
{
"$ref": "#/definitions/BaseResponse"
}
],
"example": {
"errors": [
{
"code": "PARAM_INVALID",
"message": "Param [someParam] has invalid value: invalidValue"
}
]
}
},
"ForbiddenResponse": {
"type": "object",
"title": "Forbidden Response",
"description": "Forbidden Response",
"allOf": [
{
"$ref": "#/definitions/BaseResponse"
}
],
"example": {
"errors": [
{
"code": "ACCESS_DENIED",
"message": "The reason why access was denied"
}
]
}
},
"NotFoundResponse": {
"type": "object",
"title": "Not Found Response",
"description": "Not Found Response",
"allOf": [
{
"$ref": "#/definitions/BaseResponse"
}
],
"example": {
"errors": [
{
"code": "ENTITY_NOT_FOUND",
"message": "Entity not found for id: someEntityId"
}
]
}
}
}
}