Get key of Application (client) ID & Secret Value & Directory (tenant) ID for Office 365 / Outlook user account
15-May-2025 · Wing Au Yeung
Why get key of Application (client) ID & Secret Value & Directory (tenant) ID for Office 365 / Outlook user account?
To add into outlook calendar when staff create Leave Application in ESS system or add created Leave Entry in Backstage Admin portal.
Please note that this function only works with your Work Microsoft 365 Account, personal outlook account may not be able to do it.
"A Microsoft 365 account with an Exchange Online mailbox. If you do not have a Microsoft 365 account, you can sign up for the Microsoft 365 Developer Program to get a free Microsoft 365 subscription."
Before starting, we highly recommend you do the following with the Microsoft 365 account you prepare to be an organization-wide Calendar.
How to get key of Application (client) ID & Secret Value & Directory (tenant) ID for Office 365 / Outlook user account?
1. Register your application
To use OAuth, an application must have an application ID issued by Microsoft Entra. In this tutorial, it is assumed that the application is a console application, so you need to register your application as a public client with Microsoft Entra. You can register an application in the Microsoft Entra admin center or by using Microsoft Graph.
Open a browser and navigate to the Microsoft Entra admin center and login using a Work or School Account.
Select Identity in the left-hand navigation, then select App registrations under Applications.
Select New registration. On the Register an application page, set the values as follows.
Set Name to a friendly name for your app.
Set Supported account types to the choice that makes sense for your scenario.