Facebook graph API & PHP SDK questions - php

Is there any limit to access graph API or php sdk in facebook (like XXX no. of hits allowed per day/hour)

See Policies, Features and Functionality point five:
https://developers.facebook.com/policy/
" If you exceed, or plan to exceed, any of the following thresholds please contact us by creating a confidential bug report with the "threshold policy" tag as you may be subject to additional terms: (>5M MAU) or (>100M API calls per day) or (>50M impressions per day)."
100 million API calls a day is hard to hit eh? :)

If you are using a token from the current logged in user, the limit was 600 requests/minute a few months ago, haven't checked since. If you are using an application token, I haven't seen any limits, at least ones that can be tested by a mid-range server.

Related

Twitter API V2 - Increase Rate Limit and Get Rate Limit Status

I'm using following Twitter APIs
https://developer.twitter.com/en/docs/twitter-api/tweets/manage-tweets/api-reference/post-tweets
https://developer.twitter.com/en/docs/twitter-api/tweets/retweets/api-reference/post-users-id-retweets
https://developer.twitter.com/en/docs/twitter-api/users/follows/api-reference/post-users-source_user_id-following
The rate limit for these APIs are https://developer.twitter.com/en/docs/twitter-api/rate-limits here.
Twitter API Rate Limit Image
The solutions I needed:
How can I increase the APIs rate limit?
I'm using https://developer.twitter.com/en/docs/twitter-api/v1/developer-utilities/rate-limit-status/api-reference/get-application-rate_limit_status API to get the APIs usage status, but it's returning same value in limit and remaining field. How can I get the exact usage details of APIs?
How I can get the daily API APP limits? The API seems to be returning 15 minutes limits, but I need to know how much app limit quota is remaining.
The post limits (Tweets, retweets, Direct Messages etc) are per-user quota. You can find out more about them from Twitter’s help pages.
The current technical limits for accounts are:
Direct Messages (daily): The limit is 1,000 messages sent per day.
Tweets: 2,400 per day. The daily update limit is further broken down into smaller limits for semi-hourly intervals. Retweets are counted as Tweets.
These limits are shared across all of the apps a user might use within a day. There is no API endpoint or header that shows what the current quota is - you have to account for this in your code.

Google APIs Get User Email PHP

I'm using Google plus API in my website to Sign In users and it does work great, However because I only need the user email since I create my own Auth Token I no longer need to use Google plus API because Gmail API provide all the information I need Also give more daily query Which is 1,000,000,000 compared to 20,000,000 for Google plus API.
The Problem is:
When I used Gmail API I got the same information that Google plus API provided, Which is great.
However, going to my dashboard inside Google Cloud Console >> OAuth consent screen Tap >> OAuth rate limits.
It says that Your token grant rate = Your current per day token grant rate limit is 10,000 grants per day. The per day token grant rate resets every day
So, Do I miss something?
Note: When I switched to Gmail API, I did change the client key, secret key, and Google Sign In URL.
There is a difference between the OAuth Rate Limits and the Gmail API Usage Limits. When designing your app you have two take into consideration these two factors:
1) OAuth
The OAuth Rate Limits refers to the number of tokens that your application can request to Google in order to be able to have permission to sensitive scopes from the users that are utilizing your app and in that way allow to access their data (how much data depends in the scopes) when calling the Gooogle's APIs.
2) Gmail API
The Gmail API Usage Limits refers to the number of requests that your app can do to the API, no matter the number of users(as long as it doesn't surpass the limit) because it was previously checked by the OAuth rate limit.

Developing Facebook App for large API request load?

I was given a task to post on Facebook fan pages through Graph API. I have successfully managed to do it. Everything is running fine from my end.
We are managing about 2000-3000 fan pages from 3 or 4 profiles. We post about 15000-20000 posts daily on Facebook fan pages.
One big problem is, after some days (5-6 days), our App is deleted or blocked by Facebook or App developer account is blocked or profile account is blocked.
Our App is properly configured and all Facebook required details have been entered in App details like privacy policy, terms of services, website/domain, etc. We are not posting any content that violates the Facebook policy.
I have Googled a lot to find the right solution but couldn't find one. I have visited some commercial websites offering same sort of services.
These commercial websites post million of posts every day.
I am very eager to know how they maintain App, App profiles, etc?
What is the right solution to maintain such Apps?
Is there anything special Facebook offer for such Apps?
We have Facebook business manager account (business.facebook.com). Can this help to solve this issue?
Feel free to ask any question regarding this issue.
Thanks in advance.
You need to explore more about facebook API limits, on the developer page it says :
Each each app is given an allotment of 200 API calls per user in any
given 60 minute window.
As an example, if your app had 10 users yesterday and 5 new logins
today, that would give you a base of 15 users. This means that your
app can make ((10 + 5) * 200) = 3000 API calls in any 60 minute
window.
https://developers.facebook.com/docs/graph-api/advanced/rate-limiting
Repetedly violating API limits can get your app stopped or worse deleted

Tumblr API V2 Error code 429: "Rate Limit Exceeded" You are being rate limited, slow down. Header info?

I tested Tumblr API with PHP, then I try to follow with friends using API and worked successfully, then later I get this error:
Error 429 "Rate Limit Exceeded"
I heard I need to wait 1 hour and limits will gone.
Also I see a few information about headers:
x_ratelimit_api_followers_limit
x_ratelimit_api_followers_remaining
x_ratelimit_api_followers_reset
This informations can be in header. What header? Oauth? I don't found that.
How can I see this variables?
How can I get more information about API follower limitations?
Tumblr's API documentation not contain that.
Answer provided by Felix Bonkoski:
You can only fetch X many followers per minute with the API. This is represented in the x_ratelimit_api_... headers. These fields in the header inform you what the limit is, how many more calls to the API you can make, and when the limit will expire so that you can start using that API endpoint again. This is not in the documentation, but please see the Tumblr API Discussion Group where there are posts dealing with this issue.

Max. Requests Twitter

I wanted to use the Twitter API to get the friends status list from many users.
How many requests could I request in one moment?
Little another question:
What's faster: XML or JSON with a lot of data with PHP?
Currently, there is a rate limit of 350 requests per hour when using OAuth. I believe it's 150 when using Basic Auth which will be deprecated in June.
The number of requests per hour over REST is irrelevant here as to achieve what you require (tracking the friends of many users I assume) then you need to be using site streams rather than the REST API. This will give you an initial list of friends for a followed user then will stream you updates to that user as any changes happen.

Categories