Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

I was wondering if anyone knew how to notifiy attendees upon event creation in google calendar. When I create the event manualy, I can send an event as I wish. But when I create the event using the api with the javascript client library. I do not receive email notifications.

Here is my code for creation :

var request = gapi.client.calendar.events.insert({
    'calendarId': '***@***.com',
    'resource': resource
});
request.execute(function() {
});

My resource variable is already defined and the event is added successfuly to the calendar, but no attendees receive any invitations. And if I go into the event on the calendar after creating it, the attendees are there.

Is there anything I am missing in the request to make it so that the attendees receive notifications upon the creation.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
605 views
Welcome To Ask or Share your Answers For Others

1 Answer

The attendees array has a responseStatus that you can set to: "needsAction" - The attendee has not responded to the invitation. "declined" - The attendee has declined the invitation. "tentative" - The attendee has tentatively accepted the invitation. "accepted" - The attendee has accepted the invitation.

var request = gapi.client.calendar.events.insert({
  'calendarId': '***@***.com',
  'resource': resource,
  'attendees': [{'email':'example@example.com','responseStatus':'needsAction'}]
  }
});
request.execute(function() {
});

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...