Outlook webhook notification subscription

删除回忆录丶 提交于 2019-12-11 14:48:49

问题


I already implemented outlook notification rest api into my code and its work fine but today it suddenly failed and gives me 400 error.

Request outlook for create subscription for notification Output::

{"error":{"code":"ErrorInvalidParameter","message":"The parameter 'Resource' is invalid."}}

My post data as below :: URL => outlook.office.com/api/v2.0/me/subscriptions

$subscriptionParameters = json_encode(array( "@odata.type" => "#Microsoft.OutlookServices.PushSubscription", "Resource" => "https://outlook.office.com/api/v2.0/me/events",
"NotificationURL" => "https://mydomain/acceptnotification.php", "ChangeType" => "Created, Updated, Deleted", "ClientState" => "c75831bd-fad3-4191-9a66-280a48528679" ));

Pass above data to outlook with access_token and email address using cUrl

Please suggest me.


回答1:


Thank you for reporting this issue. Microsoft engineering team is investigating it right now. Meanwhile, a workaround that worked for multiple subscription cases is to use relative URL for the resource property

e.g.

"Resource": "me/events",

Thanks.



来源:https://stackoverflow.com/questions/36217663/outlook-webhook-notification-subscription

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!