Response format
https://suggest.api.mappable.world/v1/suggest?apikey=YOUR_API_KEY&text=burj&print_address=1&attrs=uri
In this case, the geosuggest response will look like this:
Response
{
"results": [
{
"title": {
"text": "Burj Khalifa, Zaabeel, Dubai",
"hl": [{
"begin": 0,
"end": 10
},
{
"begin": 18,
"end": 20
}]
},
"subtitle": {
"text": "Dubai"
},
"tags": [
"house"
],
"distance": {
"text": "7141.91 km",
"value": 7141908.95
},
"address": {
"formatted_address": "Burj Khalifa, Zaabeel, Dubai",
"component": [
{
"name": "United Arab Emirates",
"kind": [
"COUNTRY"
]
},
{
"name": "Emirate Dubai",
"kind": [
"PROVINCE"
]
},
{
"name": "Dubai",
"kind": [
"PROVINCE"
]
},
{
"name": "Dubai",
"kind": [
"LOCALITY"
]
},
{
"name": "Zaabeel",
"kind": [
"STREET"
]
},
{
"name": "1",
"kind": [
"HOUSE"
]
}
]
},
"uri": "mappable://geo?data=Cgg1MzA2MzU1OBIy0JzQvtGB0LrQvtCy0YHQutCw0Y8g0L7QsdC70LDRgdGC0YwsINCc0YvRgtC40YnQuCA,"
}
]
}
Response parameters
results-
Request results in the form of an array of objects. If nothing was found, the parameter may be omitted.
title-
Object name.
text-
Object name.
hl-
Highlights the fragment of the
textstring in the interface that matches the user request.begin- Start of the range of symbol indexes in the
textstring for highlighting. end- Start of the range of symbol indexes in the
textstring for highlighting.
Indexes are specified as numbers of the UTF-16 encoded 16-bit code units in the string.
subtitle-
Additional object name.
text- Object name.
hl- Highlights the fragment of the
textstring in the interface that matches the user request.
tags-
Object type:
-
companies from Business Directory use the
businesstagAdditional tags related to the company's business type
airport terminalairportsanimationattractionautobaggage roombanksbarsbeachbenchbikebike rentboat stationbuddhismbus stationbus stopcablewaycafecar parkcatholic churchcatholic churchcemeterychildrens playgroundchristmastreecinemasclothes shopcollegeconcert hallconfectionarycurrency exchangedance paviliondentaldrugstoresdry cleaningemergency point trfallback funfallback outdoorfallback servicesfast foodfestivalfire stationfireworks launchingfitnessflower shopforestfountainfurniture storegardengasstationgovernmenthairdressershaulierhelicopterhighspeed tram stophotelshypermarketindustrial enterpriseinformationinformation desklandmarklaundrymallsmedicinememorable eventmetromonumentmosquemountainofficeoffice serviceorthodox churchparkpet playgroundpetshopphotopicnicpierplaygroundpolicepolice postportpost officeprotestant churchracingrailway stationrailway terminalrestaurantsrezervationsanatoriumscenesecurity postskating rinksoftwarespasportcenterspringstadiumstenograffiasupermarketsushiswimming poolsynagoguetailortaxitheatretire fittingtrade pointtram stoptrashtravel agencytribuneviewpointwaterfallwaterparkwcshopzoo
-
geographical objects use different tags
tags for toponym
streetmetrodistrictlocalityareaprovincecountryhydrorailwaystationroutevegetationairportotherhouse
-
distance-
Distance to the object in meters.
- Calculated based on user coordinates indicated in the request
- Or the center of the search window if user coordinates are not set
text- Localized representation
value- Distance in meters.
address-
Object's address.
formatted_address-
Object's address.
component-
Address components.
name-
Address component name.
kind-
Address component type. Two components with the same
kindparameter values but differentnamevalues may be returned.Possible values
country— countryregion— regionprovince— provincearea— regional districtlocality— localitydistrict— district, microdistrict, villagestreet— streethouse— househydro— river, lake, reservoir, etc.station— public transport stopmetro_station— metro stationrailway_station— railway stationroute— metro line, highway, railway linevegetation— forest, park, garden, etc.airport— airportother— otherentrance— entrancelevel— floorapartment— apartmentunknown— none of the above
uri-
Additional information about the object that can be used in a request to the Geocoder API — to do this, specify the value of the
uriparameter instead of text and coordinates.
Error messages
| Code | Description |
|---|---|
400 |
The request is missing a required parameter or an invalid parameter value is specified. The message contains additional information about the error. |
403 |
The request doesn't contain the apikey parameter or an invalid key was specified. |
429 |
There are too many requests in a short time. |