Outlook addin - how to get unique new event id

Dimitrios Gkiokas 20 Reputation points
2025-01-16T12:07:23.4333333+00:00

Hi,

We are developing an Outlook addin, and we want to save an event id for a new Outlook event so we can associate the new event with the state of our app.

We read that the Outlook API does provide unique event id but only if the event is saved.

Can we use that since first something happens in our app that mutates our app state, and after that the user may save the event?

Thanks.

Outlook
Outlook
A family of Microsoft email and calendar products.
4,319 questions
Microsoft Graph
Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
12,800 questions
Outlook Management
Outlook Management
Outlook: A family of Microsoft email and calendar products.Management: The act or process of organizing, handling, directing or controlling something.
5,406 questions
{count} votes

1 answer

Sort by: Most helpful
  1. CarlZhao-MSFT 44,756 Reputation points
    2025-01-17T10:04:21.92+00:00

    Hi @Dimitrios Gkiokas

    You can try using the Graph API to get the event ID.

    GET https://graph.microsoft.com/v1.0/me/events?$select=id,subject
    Prefer: outlook.timezone="Pacific Standard Time"
    

    However, if the user moves the event to another calendar, the event ID might change. One way to solve this problem is to use an immutable ID.

    Hope this helps.

    If the reply is helpful, please click Accept Answer and kindly upvote it. If you have additional questions about this answer, please click Comment.


Your answer

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