Skip to main content

Authentication Method

  • oauth_2 - OAuth 2.0 (Microsoft identity platform)

OAuth App Setup

Step 1: Register an App in Azure

  1. Go to the Azure portal
  2. Navigate to Azure Active DirectoryApp registrations
  3. Click New registration
  4. Fill in the app name and select the account type
  5. Add a redirect URI (e.g., http://localhost:3456/callback) under Web
  6. Click Register

Step 2: Configure API Permissions

  1. Go to API permissionsAdd a permissionMicrosoft Graph
  2. Add delegated permissions:
    • Mail.ReadWrite — Read and write emails
    • Mail.Send — Send emails
    • Calendars.ReadWrite — Read and write calendars
    • Contacts.ReadWrite — Read and write contacts

Step 3: Create a Client Secret

  1. Go to Certificates & secretsNew client secret
  2. Give it a description and expiry
  3. Copy the Value immediately — you won’t see it again

Step 4: Store Credentials

pnpm corsair setup --plugin=outlook client_id=your-application-id client_secret=your-client-secret

Step 5: Authorize

pnpm corsair auth --plugin=outlook
This opens a browser window to complete the Microsoft OAuth flow. Tokens are saved automatically.

Required Credentials Summary

CredentialRequired ForWhere to Find
Application (Client) IDOAuth flowAzure App registration → Overview
Client SecretOAuth flowAzure App registration → Certificates & secrets
For general information about how Corsair handles authentication, see Authentication.