Quantcast
Channel: Tweetinvi a friendly Twitter C# library
Viewing all articles
Browse latest Browse all 4126

New Post: How to get long followers list

$
0
0
Here is how I would do it (and I checked it works as expected).
RateLimit.AwaitForQueryRateLimit("https://api.twitter.com/1.1/followers/ids.json?screen_name=shakira");
var results = TwitterAccessor.ExecuteCursorGETCursorQueryResult<IIdsCursorQueryResultDTO>("https://api.twitter.com/1.1/followers/ids.json?screen_name=shakira").ToArray();
if (results.Any())
{
    var nextCursorToUse = results.Last().NextCursor;

    var rateLimits = RateLimit.GetQueryRateLimit("https://api.twitter.com/1.1/followers/ids.json?screen_name=shakira");

    Console.WriteLine("Restarting queries at {0}", rateLimits.ResetDateTime.ToLongTimeString());
    RateLimit.AwaitForQueryRateLimit(rateLimits);

    var results2 = TwitterAccessor.ExecuteCursorGETCursorQueryResult<IIdsCursorQueryResultDTO>("https://api.twitter.com/1.1/followers/ids.json?screen_name=shakira", cursor: nextCursorToUse);
}
Linvi

Viewing all articles
Browse latest Browse all 4126

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>