Continuation to my previous question, following code snippet is proposed by @Tanaike to send Google calendar invitation email to multiple email addresses simultaneously:
function SendMultiple(calendarId, eventId) {
var newGuests = ["user1@gmail.com", "user2@gmail.com"];
Calendar.Events.patch({ attendees: newGuests.map(email => ({ email })) }, calendarId, eventId, { sendUpdates: "all" });
}
However, when I use my personal email address in the newGuests
array, it does not send to it, for example:
var newGuests = ["personal@gmail.com","user1@gmail.com", "user2@gmail.com"];
It will not send Google calendar invitation to:
personal@gmail.com
Is it because my email has edit access to the calendar while others do not have? or can we find a way to send emails to this personal email address as well, any guidance would be much appreciated.
I was able to get the same behavior using Google Apps Script as well as when using the Google Calendar Web UI by doing this:
I could find this issue tracker entry where the same behavior was reported but it was confirmed to be an expected behavior: https://issuetracker.google.com/issues/235108773#comment6.
Basically, Google is considering the actor of the Event Update request as an Organizer, this would explain why the invites are not sent in this specific scenario. You could create a Feature Request requesting for a feature to be able to send invitation emails to all attendees regardless of the using this link https://developers.google.com/calendar/api/support#developer_product_feedback.