How to create Microsoft OAuth2 API
Published: (December 3, 2025 at 02:52 AM EST)
1 min read
Source: Dev.to
Source: Dev.to
Register a new application
- Go to Azure Portal – App Registrations: https://portal.azure.com/#view/Microsoft_AAD_RegisteredApps/ApplicationsListBlade
- Click New registration.
- Fill Name.
- Choose Accounts in any organizational directory (Any Microsoft Entra ID tenant – Multitenant).
- Choose Web.
- Set Redirect URI to
https://[host]/rest/oauth2-credential/callback.
Retrieve application credentials
- Copy the Application (client) ID.
- Click Add a certificate or secret.
- Click New client secret.
- Fill Description.
- Choose Expires.
- Click Add.
- Copy the Value (Client Secret).