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

New Post: errors retrieving IUsers list from ID

$
0
0
Hi,

Well I am quite surprised to find out that I never talked about the cursors in all this thread.
Your problem right here is that you have not stored the cursor information.

An IIdsCursorQueryResultDTO contains various metadata information to help you execute the next queries.
The most notable property is the NextCursor. This property allows you to start a cursor query at a specific point. This basically allows you to get back and get the next data available when the results are bigger than the default limit (5000 in the context of follower ids).
// Existing Codevar followerQuery = String.Format("https://api.twitter.com/1.1/followers/ids.json?user_id={0}", myPolitician.Id);
var results = TwitterAccessor.ExecuteCursorGETCursorQueryResult<IIdsCursorQueryResultDTO>(followerQuery);

// New Codevar latestResult = results.Last();
var latestCursor = latestResult.NextCursor;

var newResultsStep = TwitterAccessor.ExecuteCursorGETCursorQueryResult<IIdsCursorQueryResultDTO>(followerQuery, cursor: latestCursor);
So what you will need to do is to store this latest NextCursor somewhere so that you can reuse them later on to complete your set of friends.

I am so sorry for not giving you this information before. I must have forgotten. Sorry if this delays your research.

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>