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.
Related
Below is my code:
$response= $fb->sendRequest('GET', '/me/feed', ['fields' => 'message,type,attachments'],
$val->api_token, 'eTag', 'v2.10');
dd($response);
Get only 25 records How to get all feed in single request what should i add them in query string.
Almost every commercial API provides Rate Limiting / Throttling and Record Limiting Per Request. Even Graph API does Rate Limiting and Record Limiting
When you are requesting let's say 100 records, the 3rd party API server is using it's resources to get you those 100 records. The thing is, there might be many API clients like you who want to use the same API for their usage. So, Rate Limiting helps the API providers to make sure each client is not requesting large set of data together.
Also, it's very unlikely that you will need all data from Graph API at once. It is suggested to use pagination so that you are requesting small number of data per API request.
If you want to save all in your database, You can save in incrementally like get 50 records and store it, then get next 50 and store them and so on..
I have a problem when trying to use Amazon product API. I have all my credentials, but when I send a request I get a 503 Status code with description
You are submitting requests too quickly. Please retry your requests at
a slower rate
I have tried a library called apai-io link: https://github.com/Exeu/apai-io.
I have also tried this code: https://www.patchesoft.com/amazon-affiliate-api-php#fullcode.
The weird thing is that I am sending only one request, trying to find a product with a specific ID. I would really be grateful if someone could give me some instructions or more information.
They are rate limiting the requests, see the discussion here
https://forums.aws.amazon.com/forum.jspa?forumID=9
And the policy here is new for the efficiency guidelines
Effective 23-Jan-2019, the request limit for each account is calculated based on revenue performance attributed to calls to the Product Advertising API (PA API) during the last 30 days.
Each account used for Product Advertising API is allowed an initial usage limit of 8640 requests per day (TPD) subject to a maximum of 1 request per second (TPS). Your account will receive an additional 1 TPD for every 5 cents or 1 TPS (up to a maximum of 10) for every $4320 of shipped item revenue generated via the use of Product Advertising API for shipments in the last 30 days.
https://docs.aws.amazon.com/AWSECommerceService/latest/DG/TroubleshootingApplications.html#efficiency-guidelines
This has impacted me too and it's counterintuitive imo, you have to sell to use API but cannot use the API if you don't sell.
I am using instagram feeds on my website, but due to traffic it is showing error as:
You have exceeded the maximum number of requests per hour. You have performed a total of 694 requests in the last hour. Our general maximum limit is set at 500 requests per hour
Try to cache your result from Instagram and update cache every hour. User will see cache without another request to your instagram feed api.
It sounds like you are still in sandbox. Switch to LIVE where they allow 5,000 requests per hour?
Global Rate Limits
Global rate limits are applied inclusive of all API calls made by an app per access token over the 1-hour sliding window, regardless of the particular endpoint. Rate limits also apply to invalid or malformed requests. Client Status Rate Limit:
Sandbox 500 / hour,
Live 5000 / hour
I got an client app in sandbox for Instagram, was thinking of using it for showing a widget on client websites with their users recent media.
At the moment I am using GET requests towards this endpoint:
- api.instagram.com/v1/users/{user-id}/media/recent/?access_token=ACCESS-TOKEN
This is done on the server side, and it works good with my sandbox user. I save the data response from the API to avoid reaching the rate limit of 500 each hour. The saved response is then formatted to a html list, with links to the media. The request is only done once each day at the moment.
Is the rate limit only incremented on API calls as I thought? Do I avoid hitting the rate limit with this solution? If not: when is the rate limit incremented exactly?
Thanks in advance!
Yes, the rate limit will be decremented by 1 for your GET request. One way to keep track of the rate limit is to check the response headers from Instagram for x-ratelimit-remaining[1]. This will be set to an integer value (eg, 4990) and applies to the access_token used for the request. This method works only for GET requests; POST requests do not return accurate x-ratelimit-remaining values.
[1] As described in the deprecated developer documentation but inexplicably omitted from the current documentation.
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.