Share via

Create Subscription /users/{id}/events failed with ExtensionError in some users

Kazuya Matsumoto 1 Reputation point
2022-07-17T10:23:12.363+00:00

I'm trying creating a subscription for /users/{id}/events, but failed with ExtensionError in some users.

Here is a detail about what I did and what occurred.

What I did

  1. Create a user which authorized with Calendars.Read permission.
  2. Check validation endpoint is implemented correctly by Postman.
    221468-postman.png
  3. Request to create a subscription.
    const response = await axios.post<any, any>(  
          'https://graph.microsoft.com/v1.0/subscriptions',  
          {  
            changeType: 'created,updated',  
            notificationUrl: `http://nitte-functions.jp.ngrok.io/push_calendar_channel_notification_ms`,  
            resource: `/users/{my_id}/events`,  
            expirationDateTime: '2022-07-18T00:00:00.000Z' // set with in 3 days  
          },  
          headers: {  
            Authorization: `Bearer xxxxx`  
          }  
        )  
    
  4. It returns this error in some users, but succeeded in other users. 'ExtensionError'
    'Operation: Create; Exception: [Status Code: ServiceUnavailable; Reason: Target resource '00037ffe-3e39-7873-0000-000000000000' hosted on database '8bf41b6b-0cba-4703-9cf6-0f90da806005' is currently on backend 'Unknown']'

How can I fix this?

Microsoft Security | Microsoft Graph

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.