Foursquare API v2, authentication, and my now-broken app
-
12-10-2019 - |
Question
I had a developer work on integrating Foursquare into my app (which makes me pretty unfamiliar with the process, but I've been educating myself). Essentially, it worked like this:
- 4sq short URL was pulled from a Twitter message
- Mechanize was used to unpack the shortened link and grab the venue_id from the full URL
- v1 of the API was queried for location info based on the venue_id from the full URL
- venue info was stored from the API
This was working fine. It seems like some things at foursquare have recently changed. First, it seems like I can't get the venue ID from the full URL anymore. Is that correct, is that a recent change?
I've been looking at v2 of the API. For those familiar with the API, does it seem like I can accomplish what I was doing before with V2 of the API without having users authorize their Foursquare account?
Any tips here would be greatly appreciated.
Solution
With V2, you will need to authenticate once and store the auth_token in a db. You can always use the auth_token for subsequent requests.