Advertisement
Guest User

Untitled

a guest
Sep 20th, 2017
71
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1. from fbchat import Client, log
  2. from getpass import getpass
  3.  
  4. username = str(raw_input("Username: "))
  5. password = getpass()
  6.  
  7. client = Client(username, password)
  8.  
  9. name = str(raw_input("Name of that friends you wanna send messages, input like-- Narendra pandey--: "))
  10.  
  11. thread = str(client.searchForThreads(name)[0]).split(' ')[3].split('(')[1].split(')')[0]
  12.  
  13. message = str(raw_input("Message to that person: "))
  14.  
  15. num = int(raw_input("Number of time you wanna send that message: "))
  16.  
  17. for i in range(num):
  18. client.sendMessage(message, thread_id=thread)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement