Availability of POIs in HERE WeGo app vs Here Entrypoint (Places Search API) - rest

I'm looking for certain POIs using their confirmed coordinates but the Here entrypoint from Place Search API (/discover/here) doesn't provide all POIs which I could manually find in the HERE WeGo web-app.
At the beginning I thought maybe this is because the default categories are set to eat-drink, going-out and shopping? I have provided an additional parameter (cat) to my request with all the categories, but this gave me even more missing POIs.
Does anyone know why there is a such difference between the web-app and API service?

The here-wego app doesn't use the "discover/here" endpoint so this won't show you the same results. It uses "discover/search".
The discover/here entrypoint was designed for a different use case and its behavior is a bit odd. It was set up for "check-ins", so it isn't guaranteed to return everything in an area.
If you want to provide your users all of the POIs in an area, you should use the browse/ endpoint. I know that requires them to specify categories, but it's really the best choice.
Alternatively, depending on your use case, you can call discover/search the same way you called it by using the here-wego app (same query and search center).

Related

drupal 8 rest api: get allowed values for list field

I am not a drupal dev, and i know next to nothing of php specifically. That said, I am developing a new interface for an existing drupal website and we will continue to use drupal in headless mode using the rest api while we migrate to a better long term solution.
Exposing custom content types be pretty straightforward for the most part, but one aspect is giving me a headache: it seems impossible to expose the list of allowed values in a list field (e.g. list of decimals, integers or text). Ideally, there would be a way to query the drupal api for a given field name, returning a list of possible values for that field.
The closest I've gotten is through the entity rest extra module found here.
but while it exposes a ton of info on the fields, even default value for the list field, the allowed values are not there.
Is there a way to expose the allowed values list in the restful api?
Since the module I found is so close to what I need, would it be easily implemented by custom patching my drupal php code? where should I look for clues?
thanks in advance

Best way to Test an API Web Service using Automation

I am looking for the best way to test this scenario using automation. Before you mention or ask, yes, i have throughly searched to make sure or even get info or knowledge on this topic.
I have a web service that provides various pricing for health insurance. The pricing is based on different class category of race, age, location etc. All that is inputed into the web service to get the fee for the client.
Right now everything is done locally with SoupUI. As you know SoupUI does not have a way for you to randomly change the data in the body, but i need a way to automate this so random age, race, location, etc can be inputed in and verify the result against a CSV file with the information.
Is this possible or is there a better way to test this web service?
-
Per #lloyd request, because he is King here and other known methods i know:
UI Option: We build a UI to interface with the API and use Selenium to run the countless scenarios we have, but they do not want to do this. They are more incline on testing the API itself.
Ruby: Use Ruby to connect to the API, using Rspec and Airborne (https://github.com/brooklynDev/airborne), the downsize of this is also the same as using SoupUI. Everything is entered in manually, and the code just runs through the various variations we have to get the return and match it against what it should be.
I also found another tool, https://assertible.com/ but the downsize of that is we cannot limit the random generator between 2 selected numbers, plus no way to do the comparison.
Then there is Postman, which is also similar to SoupUI so not a real automation since we cannot change the values in the body. http://blog.getpostman.com/2015/09/03/how-to-write-powerful-automated-api-tests-with-postman-newman-and-jenkins/

how to specify URL in filters pagePath core reporting api V3

I am building a web app that pulls data through the Core Reporting Api v3 from Google. I am using the client PHP library offered by Google.
I am currently trying to specify a page and retrieve its pageviews for a time range. Every other seems to be working okay except for the fact that if a specfy a filter with ga:pagePath==http://link/uri then I get 0 all the time no matter the time range.
I think the problem is got to do with the setting of value for this pagePath. I want to have spearate data for the desktop version of the site and the smartphone version denoted by s. subdomain
Can anyone hint me on some tips and or tricks to use to get the required data?
Example URL:
http://domain.com/user/profile/id/1
http://s.domain.com/user/profile/id/1
Thanks in advance!
for the the default implementation of Google Analytics, ga:pagePath doesn't include the scheme or hostname so in your case you'd actually want to filter using ga:hostname and ga:pagePath together.
I suggest you use the Query Explorer to build your queries and get familiar with what will work. You can also use this tool to at least get a sense for what type of data the ga:pagePath and ga:hostname dimensions return before trying to filter on them. Finally, once you have the query you want, you can easily get the exact Core Reporting API query by clicking on the Query URI button.
Also check out the Combining Filters section of GA API docs.
So if you want filter on ga:pagepath for domain.com and s.domain.com separately you could do something like
filters=ga:pagePath==/user/profile/id/1;ga:hostname==domain.com
filters=ga:pagePath==/user/profile/id/1;ga:hostname==s.domain.com

Bing search API with DisableLocationDetection not working

The Bing search API is using my (or my server's) location even when I set the appropriate option. I would like it to provide a location agnostic response.
Am I misunderstanding the documentation? Is this syntax right?
http://api.bing.net/json.aspx?Appid=<XXX>&query=microsoft&sources=news&options=DisableLocationDetection
Thanks in advance
The syntax is right. According to the doc, the DisableLocationDetection option prevents Bing from inferring location from the query itself ("microsoft" in your example), but not from the properties of the request, such as server's IP.
News requests can specify LocationOverride parameter to get news from a particular US state. Also, if you're having troubles with automatic market detection (if your server is in another country, for example), you can specify Market parameter to override the market detection.
If this still doesn't help you, can you update the question to provide an example of a query which gives you the bad result?

Search Google POI (maps.google.com)

when you go to maps.google.com and search for "cupcakes" for example, you get the results displayed on a map, and on the left there is a list of results.
I want the user of my application (iPhone and Web) to be able to enter a search term, then it searches on google and provides a list (much like the list on the left in maps.google.com), the user can then select a location from the list.
The list would need to be in XML format or something similar that can be parsed on the iPhone. It needs to include the Name of the location, a description (if provided) and its address/coordinates.
Is this possible, and if so, how can it be done?
You'll probably want to use the Google AJAX Search APIs, which has a different set of terms from the Geocoder. The Geocoder is for taking an address and returning a lat/long, not for things like local search. Specifically, you'll want to use local search feature. Check out the section on "Flash and other Non-Javascript Environments" for info on how to access this though a RESTful interface (for the iPhone).
Google provides a number of map services where you can search for locations, etc. Especially their Geocoding API may be of interest. If you use their services you are however required to show these results on Google Maps.
An alternative to Google is to use one of the free GeoNames services. They have a more relaxed set of conditions.