You could simply request twice as many as you need and do the math. However, in rare occasions (very rare) it could happen that an user sent 20 tweets and deleted all of them, in which case it may look like you are at the end of the list.
It is not recommended to use two API calls for 20 messages. Tom On 8/11/10 5:30 PM, Mark Krieger wrote: > Thanks for the quick response, that is what I thought I had > remembered. > > Does this mean that I always need to read-ahead to see if I am on the > last page? > > Mark > > On Aug 11, 10:48 am, Julio Biason <[email protected]> wrote: >> On Wed, Aug 11, 2010 at 8:43 AM, Mark Krieger <[email protected]> wrote: >>> 2. Assume that these calls will always really send me back 20 results >>> ALWAYS, then if less, I know this is the last screen. >> >> Unfortunately, that won't work. Twitter retrieves the messages from >> the cache and then tests if they still exist. This means you could >> receive less than 20 and still not being in the last page. >> >> -- >> Julio Biason <[email protected]> >> Twitter:http://twitter.com/juliobiason
