I am using the Deezer API for a competition, I'd like to submit a batch job to retrieve information about 452975 tracks, 151471 albums and 67142 artists. The deezer API has a request quota of 50 requests per 5 seconds, which will make this take a very long time (excluding overhead). So my question, is it possible to submit a batch job?
I've looked into doing some smarter things than just retrieve all the songs, albums and artists. Since I assumed that retrieving the album, would also yield the artist, and the featured songs. But the artist/song parts of the JSON do not supply me with all the information I can get if I request information about a particular song, namely: BPM and GAIN are missing when I look at the song information through the album API. I feel like this could and should be improved by the Deezer API team.
But to get back to my main question: is it possible to submit a batch job in any way to the Deezer API, something like:
http://api.deezer.com/track/3135553&3135554&3132233
Sorry, but you cannot submit a batch job on our REST API for now, we will consider that possibility.
Related
While figuring out how to use the Instagram Graph API for Hashtag searches I found out that the rate limit kind of makes it impossible for my use case to search hashtags. Maybe I just don't know the best practices for the Hashtag search so here is my use case:
A client wants an application to manage coupon/discounts initiatives for his clients. Each of those clients have a store and want to offer discounts for everyone posting on instagram with a store-specific hashtag. My client wants to create/update/delete stores in an application and define the hashtag for a store. Thats all done. Now I need to trigger hashtag searches for each store. And heres the problem:
There are 70 stores (at first, may be more in the future). Each store has a unique hashtag and wants to know who posts something with their hashtag. When someone posts with a hashtag the application should know after max. 20 seconds. This means triggering a hashtag search 70 times (because there are as many hashtags as there are stores) every 20 seconds (I know once I get the hashtag ID I can save it and don't need to search for the acutal term anymore, but I still need the newest media for the hashtag ID).
Thats one thing. The other thing is I can only query 30 different unique hashtags in a week (facebook api limitation). But I will need to query at least 70 different hashtags. And the stores don't want to create a facebook account and instagram business page, so they can oauth into my application just for that.
So at the moment the way of doing it is kind of create 70 fake-pseudo-accounts (one for each store) and use those acocunts to prevent hitting the rate limit. But I don't think this is the way facebook wants me to use the graph api.
In this post Facebook API rate limit increase an answer from 2017 shows that there is a possibility to request a rate limit increase and in the linked picture is even the sentence "This is a page management app with few users but many calls". But more recent comments show that this is not possible anymore and I couldn't find any rate limit increase option in the developer portal.
https://stackoverflow.com/a/39408611/6315447 This answer even says there is no possibility anymore and If you hit the rate limit you're doing something you are not supposed to. But how should I use the API then?
Am I missing something? What is the best practice for such a use case?
Thanks in advance.
Is it possible to get all the clicks (timestamped activities including comments, likes and shares) associated with any video/picture of any user that i wish, using Instagram API? i am not gonna limit myself to only my uploaded stuff! Basically I would like to creates a stream of clicks on popular photos or videos on Instagram. Also, I would like to have timestamps of follow-up activities on a particular video/picture rather counts.
You can get timestamps of comments from any image/video. However, you can't get timestamps when a user liked a picture. There isn't an endpoint where you can get info if someone shared the photo/video.
If you would like to create a stream of follow-up activities on a particular picture, you would have a script that calls out via Instagram's API every minute, save the JSON data, and then do a comparison to see if anything new happened.
If you sign up with Instagram's API, you can see what other data you can access:
http://instagram.com/developer/api-console/
I need in my application to build a social graph of friends for each user.
Like it is doing the facebook app "Social Graph":
App URL.
As I have seen there is no way to extract the friends of friends besides they are also using the application. So what I was thinking about is to extract the friends and for each pair of friends I can check with friends.areFriends whether they are friends and so build the social graph.
But for a user with 300 friends, I need 45.150 API calls. Which exceeds the API call limit per hour.
So is there a way to cast more queries in an API request. Or any suggestions how I can build this social graph in a better way??
best regards
I would suggest a slightly different approach to doing this. You should store what you can in your data store for quicker querying. You should implement the Real-Time API from Facebook and subscribe to each user's friend requests. This way you can keep track of friendship links to start fleshing out your social graph.
Using Facebook's Graph API, I am currently looping through all friends to retrieve their videos, and then present a list of these videos to the user. It obviusly takes a while to do this depending on number of friends,
Is there any way to just say to FQL - give me all videos that I have permsission to view?
Facebook doesn't want applications to be able to "mine data". They don't want applications to be able to collect that much data on anything they want. In most cases an ID must be specified.
User ID
Page ID
Group ID
Event ID
etc...
Even in such a case there is also limitations and multiple calls will have to be made. The limitations themselves are not only limited to accessing data with FQL or the Graph API.
There are also limitations on your access to the API. This is called application throttling and it can be enforced on your application if they find you doing an abnormally large amount of calls to the API. There are also other limitations such as making multiple sequential posts or even duplicate posts to your users.
I'm afraid that the answer is no.
Just playing around with the graph API explorer:
http://developers.facebook.com/tools/explorer?method=GET&path=fql%3Fq%3DSELECT%20vid%2C%20owner%2C%20title%2C%20src%20FROM%20video%20WHERE%20owner%3Dme%28%29
I know that to get a list of my friends I can do:
SELECT uid2 FROM friend WHERE uid1=me()
I then updated the video query to:
http://developers.facebook.com/tools/explorer?method=GET&path=fql%3Fq%3DSELECT%20vid%2C%20owner%2C%20title%2C%20src%20FROM%20video%20WHERE%20owner%20IN%20%28SELECT%20uid2%20FROM%20friend%20WHERE%20uid1%3Dme%28%29%29
And now I get a paginated list of all videos belonging to my friends. This one query is certainly better than pounding the API to death with multiple calls. :)
I am an intermediate level programmer with almost no web experience. I have an idea for an iPhone app and am trying to figure out if it is a feasible project to pursue.
I am thinking of building an application that groups certain specific twitter feeds together into an app. I am wondering if anyone has done this before, and if it is possible to use the twitter API to retrieve specific tweets without having a user have to log in.
The user will not be replying to or responding in any way to the links, rather just opening the links.
Thanks.
Jamie
Any public twitter feeds can be retrieved without a user authorizing their account. However you can usually only get a certain amount of tweets into the past. For instance this returns info about a user and their most recent tweets, just replace "screen_name=" with whatever name you are looking for
http://api.twitter.com/1/statuses/user_timeline.xml?screen_name=jsh2134
More can be found at the Twitter API documentation.