none
Office Api get event instances RRS feed

  • Question

  • I have an app the retrieves all events in the organization using the office 365 API via Subscriptions and Notifications. We just realized it doesn't get the recurring events so we have to retrieve the instances for that. If I try to use this, as Microsoft documentation suggests I get Forbidden:

    https://outlook.office.com/api/v2.0/users/me/events/{eventId}/instances?...
    

    This might be explained by the fact that the request is made in behalf of the application, so there is no "me". 

    Bu then why if I use this I get a bad request:

    https://outlook.office.com/api/v2.0/users/{outlookId}/events/{eventId}/instances?...
    

    although if I try the same request for one event it works:

    https://outlook.office.com/api/v2.0/users/{outlookId}/events/{eventId}
    

    What am I doing wrong and how to retrieve the instances of a recurring event?


    • Edited by Oana Marina Thursday, June 13, 2019 8:54 PM
    Thursday, June 13, 2019 12:31 PM

All replies

  • Hi

    Try Graph to fetch events data.

    ex.

    https://graph.microsoft.com/v1.0/me/events?$select=subject,body,bodyPreview,organizer,attendees,start,end,location

    https://developer.microsoft.com/en-us/graph/graph-explorer


    Justin Liu Office Apps & Services MVP, MCSE
    Senior Software Engineer
    Please Vote and Mark as Answer if it helps you.

    Friday, June 14, 2019 1:30 AM
  • It's not that easy, to use Graph I need to get permissions from Management so that the application has the necessary permissions to the API. Plus I have to retest all the code that will use graph instead of office api. And in the end, the question is why is this call not working when everything else is?
    Friday, June 14, 2019 12:30 PM