Reputation: 431
I have successfully subscribed to changes of the events resource with a request body of:
{ "@odata.type": "#Microsoft.OutlookServices.PushSubscription", "Resource": "me/events", "NotificationURL": "...", "ChangeType": "Created, Updated, Deleted" }
Although I get the expected webhook notification when modifying an event in the user's default calendar, I don't get any webhook notifications when modifying events in other calendars of the same user.
Am I doing something wrong or is it a bug or just an undocumented behaviour?
Upvotes: 1
Views: 811
Reputation: 4680
To subscribe the notification of other calendars, you need to change the the "Resource" to "me/calendars/{calendar_id}/events".
GET https://outlook.office.com/api/v2.0/me/calendars
{
"@odata.type": "#Microsoft.OutlookServices.PushSubscription",
"Resource": "me/calendars/{calendar_id}/events",
"NotificationURL": "...",
"ChangeType": "Created, Updated, Deleted"
}
Upvotes: 2