ios developer
ios developer

Reputation: 3473

Foursquare API for nearby places iPhone

I want to get the nearby place by passing the current lat-long. And want to get photos of that place.

I have got this link:

http://api.foursquare.com/v1/venues.json?geolat=40.82&geolong=-74.1&l=50&q=pizza

But it is showing me Error page

How do i get this error solved?

Please help me and suggest a FourSquare API URL which will help me to get the place information and photos of current lat-long.

Thanks

Upvotes: 2

Views: 2105

Answers (2)

Denis Lazendić
Denis Lazendić

Reputation: 177

I'm working on a similar app...

Use API explorer to create and test the string you'd like to use

As Gilbert said, you have to use v2, this is an example of a valid link...

https://api.foursquare.com/v2/venues/search?ll=45.49,15.59&categoryId=4bf58dd8d48988d1c4941735&radius=3000&oauth_token=A5ZDWL2DLXPZCQ3ZJESVOAKDMPQHSNNVWC3UMVOUOXPQHWRT&v=20121105

As you can see, you also must have &oauth_token=A5ZDWL2DLXPZCQ3ZJESVOAKDMPQHSNNVWC3UMVOUOXPQHWRT&v=20121105 at the end of the URL link...

When you're in an API Explorer copy the link below the textbox and it should work...

Take a look here:API EXPLORER example

Upvotes: 2

Gilbert
Gilbert

Reputation: 134

The v1 API is no longer functional. You'll need to use v2. https://developer.foursquare.com/docs/venues/search

Upvotes: 3

Related Questions