I have an app where you can buy food on delivery restaurants.
Can I use the Foursquare API so the user can check-in on the restaurant that he order from?
Probably the user will not be in the resutaurant it self when he checkin.
There is an special way to do this on the foursquare api?
thanks
You can check-in any user that has authorized your application at a venue using the /checkins/add endpoint in the API. If you don't know the user's actual location (or fully expect them not to actually be there, but have a legitimate reason to be checking in, e.g. for delivery) be sure to leave the lat/lng parameter blank. The check-in will go through and be in the user's history, but won't count for badges/mayorships, etc.
I'm not too sure what you're asking. I don't think you can check in to places if you're not even near them (or at least I wasn't able to when I last used the 4sq API).
Check this tutorial out if you need help getting started with the API, or read the 4sq api documentation.
Related
Instagram API permission is strict now and I want to know whether the tool my company will make can get the permission from Instagram or not, because it may not suit with the 3 valid use case.
We are an offshore company which develops application.
One clients ( PR or Advertisement company) asked us to make an app which finds influencers(the user who has many followers) on Instagram so that the clients can ask the influencer to advertise their products.
We want to make a influencer searching tool. Lets, say if you search with #Chocolate, the list of users who have posted photos with #Chocolate will show up, and we want to sort out the list according to the number of followers.
Referring to the valid use case for Instagram, which case may be suitable for the app we want to make?
Also, by one-off project, what does it mean? We are an offshore company and get orders from a client which want us to make a tool for them. If we just make it, and will not sell or use the application again, would it be "one-off" project?
In order to avoid one-off project, do we need to keep selling or offering the app ?
There is no direct API call to make this. You have to make a series of API calls to get all the posts for hashtag, this will have user_id and name. Then for each user you have to make another API call to get followers count. And then you have sort the results and make query for >3000
For example #chocolate has 1 million posts, so to get all 1 million posts you have make about 50000 API calls (u get 20 post per API call), and then you have to make 1 million user_info API calls to get follower counts, so 1050000 API calls total and you have 5000/hr API calls limit. So to complete this operation it will take you 9 days.
This will be a one off project if u do for a client use, you have to make a platform or service for this feature and have your client (and others) login and use the service.
In any case, the project is unrealistic to implement due to the limitation of APIs
is there a way to grab instagram users based on a specific hashtag ?
I run contests based on re posting photos with specified hashtag then randomly pick a winner, i need a tool that can grab the usernames of those who reposted that photo and used that hashtag.
You can query instagram using the API. There are official clients for both python and ruby.
You didn't specify what language/platform you are using, so I'll give you the generic approach.
Query instagram using the Tag Recent Media endpoint.
In the response, you will receive a user object that has the user's username, id, profile url, and so on. This should be enough to do what you are describing.
As far as tools, there aren't great options to probably do things exactly how you want. If you just want a simple contest, you could use statigram, but it's not free.
If you roll your own solution, I highly recommend you also do the following:
Implement a rate limiting mechanism such as a task queue so you don't exceed your API calls (5000 per hour for most calls). Also useful for failures/network hicups, etc.
Have users authenticate so you can use OAuth to extend your API calls to 5000/per user/hour to get around #1.
Try the subscribe API if there won't be many items. You can subscribe to a specific tag as well, and you will get a change notification. At that point though you need to retrieve the actual media item(s), and this can cost a lot of API calls depending on how frequent and what volume these changes occur.
If your users don't have much photos/relatively small/known in advance, you can actually query the user's recent media instead and filter in your own code by hash tag.
A client is proposing an app that would display checkins from users who have agreed to share their foursquare info with us; the catch is that they would want to distinguish between checkins that are and aren't relevant to this app. Is there a way to handle that, for instance with user comments at the time of checkin?
You can always look at the category of the venue the user has checked into, which should be available from the check-in response, or filter by specific venues directly. You can also filtering by content in a check-in shout is also a viable idea; the #mom app does this.
I which to display on my website a the list of maybe the last 5 peoples who checked in my venue.
I didn't find any method in the api to do that, the closest was showing your friend...
I tell my boss that it wasn't possible to do that then he shows me this site :
http://www.brooklynmuseum.org/community/foursquare/
How is it possible to get this kind of list and if possible with no authentication (my server will do the call no a real person so no oauth...)
thanks !
You can use the Venue Push API (documented here) to notify your website whenever a user checks in to your managed venue, which you can use to update such a list.
The website has had for some time now a section that shows friends who have been to a certain venue, yet I do not see an endpoint for getting this information.
Is such an endpoint in the works or is this considered a privacy issue like friends history even though they're both on the website???
There is no API endpoint with this functionality yet. There's a variety of reasons for why this is the case, but the primary one is that it hasn't hit the top of our priority stack just yet (this element of the website was not built off of the API)