daily pastebin goal
47%
SHARE
TWEET

Untitled

a guest Aug 20th, 2018 66 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. from TwitterAPI import TwitterAPI
  2. import json
  3. api = TwitterAPI('', '', '', '')
  4.  
  5. next_cursor = '-1'
  6.  
  7.    
  8. for x in range(0, 46):
  9.     r = api.request('followers/list', {'screen_name':'canalarte1','include_user_entities':'true','count':'200','cursor':next_cursor})
  10.     userlist = json.loads(r.text)
  11.     next_cursor = userlist['next_cursor']
  12.     print(next_cursor)
  13.     print(r.status_code)
  14.     with open("followers.txt", "a") as text_file:
  15.         text_file.write(r.text)
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top