2

I want to search a result and sort it by categoryId. I also want to use some categories.

So, I've sent a request with this parameter:

https://api.foursquare.com/v2/venues/search?ll=35.660853,139.688323&categoryId=4d4b7105d754a06374d81259,4bf58dd8d48988d1a1941735,4bf58dd8d48988d116941735,4bf58dd8d48988d117941735,4bf58dd8d48988d11e941735,4bf58dd8d48988d118941735,4bf58dd8d48988d1d8941735,4bf58dd8d48988d119941735,4bf58dd8d48988d1d5941735,4bf58dd8d48988d121941735,4bf58dd8d48988d11b941735,4bf58dd8d48988d11c941735,4bf58dd8d48988d1d4941735,4bf58dd8d48988d11d941735,4bf58dd8d48988d122941735,4bf58dd8d48988d123941735,4bf58dd8d48988d1ef931735&radius=1000&oauth_token=token&v=20120602

But, the response data has a different categoryID than that of my request!

  • My request category:

    4d4b7105d754a06374d81259,4bf58dd8d48988d1a1941735,4bf58dd8d48988d116941735,4bf58dd8d48988d117941735,4bf58dd8d48988d11e941735,4bf58dd8d48988d118941735,4bf58dd8d48988d1d8941735,4bf58dd8d48988d119941735,4bf58dd8d48988d1d5941735,4bf58dd8d48988d121941735,4bf58dd8d48988d11b941735,4bf58dd8d48988d11c941735,4bf58dd8d48988d1d4941735,4bf58dd8d48988d11d941735,4bf58dd8d48988d122941735,4bf58dd8d48988d123941735,4bf58dd8d48988d1ef931735

  • ResponseCategory:

    contains 4bf58dd8d48988d129951735(station) etc...

Why do you receive this data response? How do I get the correct data response?

4

1 に答える 1

1

This is currently a bug with foursquare API and category filtering. I have posted about this before and they said they are checking into it and in theory it should not happen (hence, a bug)

You can see a similar question here: How to use categoryId in Foursquare Venues search API and as you see more people experience the same problem.

In our system, after getting the results for search we filter it ourselves, so this is minor to us, the only thing annoying about this is that there is a chance it makes other legitimate venues drop out (as foursquare will return up to 50) - but we do not really know what the problem with the categoryid filtering at foursquare end, so this is a guess for the annoyance part :)

于 2012-06-02T13:37:17.767 に答える