Cannot retrieve all tweets with user_timeline api

api

#1

I can’t fetch all tweets with user_timeline, always few tweets missing. The following was what I got for each iteration:

expected total: 1476

  1. GET 1.1/statuses/user_timeline?count=200&include_rts=1&user_id=43064490
    -> returned: 200, lowest id: 666938639054675968, max_id = lowest id - 1: 666938639054675967

  2. GET 1.1/statuses/user_timeline?count=200&include_rts=1&user_id=43064490&max_id=666938639054675967
    -> returned: 200, lowest id: 644651930887700480, max_id = lowest id - 1: 644651930887700479

  3. GET 1.1/statuses/user_timeline?count=200&include_rts=1&user_id=43064490&max_id=644651930887700479
    -> returned: 200, lowest id: 512501307325034496, max_id = lowest id - 1: 512501307325034495

  4. GET 1.1/statuses/user_timeline?count=200&include_rts=1&user_id=43064490&max_id=512501307325034495
    -> returned: 199, lowest id: 442839343711784960, max_id = lowest id - 1: 442839343711784959

  5. GET 1.1/statuses/user_timeline?count=200&include_rts=1&user_id=43064490&max_id=442839343711784959
    -> returned: 199, lowest id: 397931756340649984, max_id = lowest id - 1: 397931756340649983

  6. GET 1.1/statuses/user_timeline?count=200&include_rts=1&user_id=43064490&max_id=397931756340649983
    -> returned: 200, lowest id: 203392000001720321, max_id = lowest id - 1: 203392000001720320

  7. GET 1.1/statuses/user_timeline?count=200&include_rts=1&user_id=43064490&max_id=203392000001720320
    -> returned: 200, lowest id: 27595392677842945, max_id = lowest id - 1: 27595392677842944

  8. GET 1.1/statuses/user_timeline?count=200&include_rts=1&user_id=43064490&max_id=27595392677842944
    -> returned: 72, lowest id: 2096643703, max_id = lowest id - 1: 2096643702

  9. GET 1.1/statuses/user_timeline?count=200&include_rts=1&user_id=43064490&max_id=2096643702
    -> returned: 0 (done)

actual total: 1470

any ideas where did other SIX tweets go? the number is under the limits (3200)
is there a bug inside the api?


#2

can anyone here help with? any team member?


#3

They may have been deleted. Deleted tweets still count in the count parameter but not in the response


#4

thanks @richardhyland. I have tried with deletion, the count was also updated accordingly when I deleted a tweet.