Import users to Office 365 using Microsoft Graph API

You can import users from external directories into Okta and provision them in Office 365 using Microsoft Graph API.

Before you begin

Procedure

To import users using the Microsoft Graph API, complete the following steps:

Configure API integration

You can automate provisioning tasks by enabling API integration and granting admin consent. Office 365 requires a token to authenticate against the Microsoft API. This allows Okta to implement provisioning in Office 365.

  1. In the Admin Console, go to Applications and Resources > Applications.

  2. Locate and select the Microsoft Office 365 app
  3. Go to Provisioning > API Integration.
  4. Click Configure API Integration, and select Enable API Integration.
  5. Enter your Microsoft admin username and password.
  6. Click Authenticate with Microsoft Office 365. You're redirected to the Microsoft account sign-in page.
  7. On the Microsoft account sign-in page, do the following:

    1. Sign in to Microsoft as a global admin for your Microsoft tenant.

    2. Read and accept the instructions that are listed on the Okta Microsoft Graph Client page.

  8. Optional. To import groups during this process, select Import Groups.
  9. Click Test API Credentials.
  10. After the credentials are verified, click Save. You can now go to the Imports tab to begin your user import.

Configure imports from Office 365 to Okta

Early Access release. See Enable self-service features.

You can use full imports, incremental imports, or both. An incremental import reads only the users, groups, and roles that changed since the last import. Incremental imports do not track the following changes:

  • Users disabled in Entra ID.

  • Unlicensed users, unless you select Import unlicensed users.

  • Deleted users and groups. If you restore a deleted user or group in Entra ID, Okta imports it as new. Its previous group memberships and roles aren't restored.

  • Groups synced from on-premises Active Directory.

  • Admin roles assigned through a group. Okta imports only admin roles assigned directly to users.

Configure import settings

  1. On the Provisioning tab, select To Okta.
  2. In the General section, select values for Full Import Schedule, Incremental Import Schedule, and Okta username format.
  3. Optional. Select Import unlicensed users to import users from Microsoft Office 365 who have no license assigned.
  4. Select the appropriate User Creation and Matching values.
  5. Click Save.

To run an import manually, complete the following steps:

  1. Open the Import tab.
  2. Select Import Now.
  3. Select Full import or Incremental import.

Okta runs the first two scheduled incremental imports as full imports. This creates the baseline that later incremental imports compare against.

Recommended import schedule

To keep Okta and Entra ID in sync, use the following schedule:

  • Run an incremental import every weekday.

  • Run a full import once a week.

  • Don't let more than three days pass between incremental imports. Otherwise, the next incremental import runs as a full import.

Changes in Entra ID appear in Okta after the next import, not immediately.