# Discussion Board

1. Hi
I have my current coordinates and a radius, how to request places within given radius using RESTFul API?
thanks

2. You can specify a search within a given viewport, by adding a an X-Map-Viewport Header.

Code:
X-Map-Viewport   13.39,52.51,13.41,52.54
And this URL ( note the lack of at parameter)
Code:
http://demo.places.nlp.nokia.com/places/v1/discover/explore?tf=plain&pretty=y&size=10&app_id=demo_qCG24t50dHOwrLQ&app_code=NYKC67ShPhQwqaydGIW4yg
You will get the results within a given box, which is more typical for display on a map.

If you need to reduce this to a radius, you'll just need to calculate the corners of the box from your centre point and distance. The mathematics can be seen here:

http://www.johndcook.com/lat_long_details.html

For a simple calculation, 1 nautical mile = 1/60th degree latitude at the equator = approx. 6000ft = 1.852km = 1.151 miles

3. Hi,

the viewport header is a good way to go.

However, please be aware, that we take this as an indicator of what part of the map the user of your application is looking at. We might serve places that are outside this region in the case that there are some good results just outside of it.

Thus, exact region search is not fully supported yet. Since the API is in development and we will add more features to it, could you tell us more about your use case?

Some more details on the current behaviour:

When trying to serve the best set of places we process several location contexts that you could provide to us.

* We currently support one explicit location context (i.e., the user tapped on the map to explicitly search here) which can be set using the "at" query parameter.
* We currently support two implicit location contexts:
| * The X-Map-Viewport header to indicate which part of the map the user is looking at
| * The Geolocation header to indicate the physical position user as derived from GPS or WiFi sensors

Position values support uncertainty values and an indicator from which sensor the data is coming from.

Additionally you can provide us the X-Mobility-Mode header to indicate if the user is driving, walking or not moving at all.

Documentation on these parameters can be found here:
http://api.maps.nokia.com/en/restpla....html#location

and here:

Best,
daniel.

4. Hi

Daniel, are you planning to support radius search as it google does for example?
the use case is AR application, btw

thanks,

We are evaluating it.

Do you need to search for a given term or do you want to explore places?

daniel.

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•
Nokia Developer aims to help you create apps and publish them so you can connect with users around the world.