# Register Microsoft 365 Copilot in Okta

Register Microsoft 365 Copilot as an app in Okta so it can sign people in to your Dtwo gateway.

## Overview

Microsoft 365 Copilot needs its own app in Okta to sign people in to your Dtwo gateway. You only do this once for your organization. Everyone who uses the gateway in Copilot signs in through this app.

## Before you start

If you haven't set up your Dtwo gateway in Okta yet, follow [Configure Okta](/docs/identity-provider-okta) first, then come back here.

## Register Microsoft 365 Copilot

1. Go to **Applications and Resources → Applications** and select **Create App Integration**.
2. Set **Sign-in method** to **OIDC - OpenID Connect** and **Application type** to **Web Application**, then select **Next**.
3. Fill in the app settings:
   - **App integration name**: `Microsoft 365 Copilot`
   - **Grant type**: **Authorization Code** and **Refresh Token**
   - **Sign-in redirect URIs**: `https://teams.microsoft.com/api/platform/v1.0/oAuthRedirect`. Microsoft 365 Copilot signs people in from Microsoft's servers, so it uses a web redirect rather than a localhost one.
   - **Controlled access**: assign the users or groups who may use the gateway through this client
4. Select **Save**. On the **General** tab, copy the **Client ID** — this is the client's `<ClientId>` — and the **Client secret** under **Client Credentials** — this is the client's `<ClientSecret>`.

## Next steps

Use the client ID and secret you copied to [roll out Dtwo to your organization in Microsoft 365 Copilot](/docs/connect-client-m365-copilot).

---

Having trouble? Email [support@dtwo.ai](mailto:support@dtwo.ai).