Scheduling Periodic Messages to WhatsApp Desktop with Powershell

Questions, comments, and suggestions related to Typeitin.
Post Reply
Fattchee
Posts: 2
Joined: Thu Nov 19, 2020 6:33 am

Scheduling Periodic Messages to WhatsApp Desktop with Powershell

Post by Fattchee » Thu Apr 21, 2022 10:19 pm

Objective: I want use powershell to automate periodic well-formatted messages to WhatsApp chat groups called "Safety Meeting Agenda" without having to pay for complex software that uses the WhatsApp API.

Pre-Conditions:
1. TypeItIn is installed in the usual directory.
2. WhatsApp desktop is installed on your machine and it is launched.
3. You have a group named "SafetyMeetings"
4. You have a button named "SafetyAgenda"

{Activate WhatsApp}
{App WhatsApp.exe}
{Ctrl f}SafetyMeetings{Enter}{Delay 500}
*Safety Agenda Update: {DateTime dd-mmm-yyyy hh:mm}*
{Shift {Enter}}{enter}

Setup your "Windows Scheduler" with the following powershell script to run periodically:

Start-Process -FilePath “TypeItIn.exe" -ArgumentList "SafetyMeetings SafetyAgenda” -WorkingDirectory “C:\Program Files (x86)\TypeItIn\”

Wavget
Site Admin
Posts: 91
Joined: Wed Jan 16, 2019 4:32 pm

Re: Scheduling Periodic Messages to WhatsApp Desktop with Powershell

Post by Wavget » Fri Apr 22, 2022 9:01 pm

You can use a loop to execute a sequence of commands until you press the button again.

For example, {Var1=0}{While (Var1=0) [Example{Enter}{Pause 10}]} will type Example and press Enter every 10 seconds until you press the button again to stop.

Fattchee
Posts: 2
Joined: Thu Nov 19, 2020 6:33 am

Re: Scheduling Periodic Messages to WhatsApp Desktop with Powershell

Post by Fattchee » Fri Apr 29, 2022 9:08 pm

Yes. The windows task scheduler can schedule daily, weekly - MTWTFSS, monthly automated activity.

Each button can trigger a looped series of prompts to generate a custom message or a series of messages via {Pastefile} to insert multiple chats in an messaging app like Telegram or WhatsApp.

Post Reply