0

I tried to get subscription for push notification

Here is the code

`def subscribe(access_token):
  url = graph_endpoint.format('/subscriptions')
  d = {"changeType": "updated","notificationUrl": 
       "https://webhook.azurewebsites.net/api/send/myNotifyClient","resource": 
       "me/mailFolders('Inbox')/messages","clientState": 
       "secretClientValue","latestSupportedTlsVersion": 
       "v1_2"}
  r = make_api_call('POST',url, access_token,payload= d)`

the response code was 400

the access token is correct

and another doubt is how to make a login in outlook webhook ??? If any body know the step by step to create a push notification in outlook please share....

baywet
  • 4,377
  • 4
  • 20
  • 49
frank jos
  • 3
  • 1
  • 2
  • What permissions did you request/get with the token? What error message do you get in the response? – baywet Feb 26 '20 at 02:34
  • elif (method.upper() == 'POST'): headers.update({ 'Content-Type' : 'application/json' }) response = requests.post(url, headers = headers, data = json.dumps(payload)) – frank jos Feb 26 '20 at 05:17
  • I'm not sure this replies to my questions – baywet Feb 26 '20 at 16:45

0 Answers0