Twitter API restriction issue

I wrote a small java program to upload profile photos of friends and followers from Twitter. But I get an error because only 150 requests per hour are allowed per IP address.

exact error:

twitter4j.TwitterException: 400:The request was invalid.  An accompanying error message will explain why. This is the status code will be returned during rate limiting.
<?xml version="1.0" encoding="UTF-8"?>
<hash>
  <request>/users/show/92715794.xml</request>
  <error>Rate limit exceeded. Clients may not make more than 150 requests per hour.</error>
</hash>

Is there any way around this problem ... ??? Please, help...

+3
source share
3 answers

As a developer, you can request a white list of your account by increasing the limit to 20,000 requests / hours. Read more at http://apiwiki.twitter.com/Rate-limiting

+6
source

Is there any way around this problem ... ???

Yes. Slow down the process to only 150 requests per hour.

+1

  • Get your application on the white list (20,000 req / h).
  • Instead of making unauthorized requests, authenticate with OAuth (350 req / h)
  • Slowing down your requests

Judging by your description, I don't know if you can expect to get a whitelist. Given that you will not be very successful, implementing OAuth may not be worth the trouble. You seem to be stuck on this slowly.

+1
source

Source: https://habr.com/ru/post/1754992/


All Articles