Skip to content

Instantly share code, notes, and snippets.

@JayantGoel001
Created January 5, 2021 15:06
Show Gist options
  • Save JayantGoel001/26353940cc26bd822eadda1d9cb20963 to your computer and use it in GitHub Desktop.
Save JayantGoel001/26353940cc26bd822eadda1d9cb20963 to your computer and use it in GitHub Desktop.
Automate WhatsApp using Python and pywhatkit
import pywhatkit as kt
import getpass as gp
from datetime import datetime,timedelta
print("Let's Automate Python")
p_num = gp.getpass(prompt="Phone Number:",stream=None)
msg = "Hello Coders!! \nIt's Jayant"
init_time = datetime.now()
msg_time = init_time + timedelta(seconds=59)
kt.sendwhatmsg(p_num,msg,msg_time.hour,msg_time.minute,10)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment