reply all 8 May 2024

Skip to first unread message

Vishal Sheth

May 8, 2024, 7:07:27 AMMay 8
to Google Apps Script Community
I would like help with this.

I want to automatically reply all to a specific email from "" with subject "test". This should happen and also get saved as it was normally replied by us.

Vishal Sheth

May 29, 2024, 4:23:05 AMMay 29
to Google Apps Script Community
I used the above code but it's not running when the email arrives. What am I missing here?
With "To" there would be emails in "cc". The script should do reply all so all get the email.

function onMessageReceived(e) {
const message = e.message;
const subject = message.getSubject();
const from = message.getFrom();

if (subject === "test" && from === "*") {
const body = "Hello";
GmailApp.replyAll(message, body);
Reply all
Reply to author
0 new messages