How can I get with foursquare API only user checkins from specific categories:
http://aboutfoursquare.com/foursquare-categories/parks-outdoors/
I only want users checkins on the beaches.
thx
How can I get with foursquare API only user checkins from specific categories:
http://aboutfoursquare.com/foursquare-categories/parks-outdoors/
I only want users checkins on the beaches.
thx
Firstly, you can only access the check-in histories of people who have OAuthed your application. You can't just query foursquare for recent checkins.
Once a user has authorized your application, you can query the users/USER_ID/checkins endpoint to get their check-in history. You then can page through this history looking for check-ins into the categories you want.
For example, you can see all the fields of a check-in object here:
https://developer.foursquare.com/docs/responses/checkin
One of those fields is a 'venue' object, which looks like this:
As you can see it has a 'categories' list. So just check this list for the categories you want. Hope that helps