I'm trying to use the Places (Search) API (or any HERE API for that matter) for the first time. I tried the example in this page and got this page as a response:
https://places.cit.api.here.com/places/v1/browse?app_id=YOUR-APP-ID&app_code=YOUR-APP-CODE&in=52.521,13.3807;r=2000&cat=petrol-station&pretty
I don't know what I'm missing here but, I expected to get a plain JSON/XML response (orange rectangle), like this example of the Routing (Isoline) API which outputs this to the browser:
this way I could consume the service using the JSON/XML output.
I already tried both examples above in my Spring (JAVA) app and the second one works as expected, while the first one throws error (as expected).
HERE API newbie here, help appreciated.
PS: this project app of mine is just about finding nearby POIs (e.g: gyms, coffee shops, pharmacies, cinemas, etc). So, any suggestions on what API is best to go with for this, also very appreciated.
I don't know the HERE api but from having a quick look it seems they generate your results depending on the Accept
header in your http request.
By default my chrome sends this accept header:
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8
If I use Postman to send the request without any Accept header or Accept: application/json
it returns the json results.
If I add an Accept: text/html
header to the request in Postman it sends me the PlayPen in html.
You can also see in their documentation that they use the appropriate Accept: application/json
I suggest you use Postman to test and play with the API's.