integration-service
latest
false
UiPath logo, featuring letters U and I in white

Integration Service user guide

Last updated Nov 18, 2025

Microsoft OneDrive and SharePoint authentication

Overview

In Integration Service, when you create a connection to one of our Microsoft Graph-based connectors, you can choose between the following authentication options:

  • OAuth 2.0 Authorization code – connects to the UiPath public application.
  • OAuth 2.0 Client credentials – uses a service account.
  • Bring your own OAuth 2.0 app – connects to a private application you create.
Note: For more details regarding the different authentication types, refer to the How to connect to Microsoft 365 activities guide.

Admin consent

Note: This section applies only to the OAuth 2.0 Authorization code and Bring your own OAuth 2.0 app authentication options.

Many organizations require the consent of an administrator before you create a connection to an external application. The admin consent workflow requires an admin to approve the app registration to specific users or groups before a connection is established. For more details, check Overview of admin consent workflow and User and admin consent in Microsoft Entra ID in the Microsoft documentation.

Note: Integration Service impersonates the user who creates the connection. The credentials of the user offer access to all of the same resources that they have in the given application. If you share the connection, every change made to Microsoft SharePoint or OneDrive with that connection is made on behalf of that user.

OAuth 2.0 Authorization code

Scopes

The connector requires the following minimum scopes to create a connection: openid, offline_access, email, and Files.Read.
The connector requires the following full set of scopes for all activities to function: offline_access, Files.Read, Files.Read.All, Files.ReadWrite, Files.ReadWrite.All, Sites.Read.All, Sites.ReadWrite.All, Group.Read.All, Group.ReadWrite.All, profile, openid, email, User.Read.All, and User.Read.

To add more granular permissions, refer to the activities documentation.

Adding the Microsoft OneDrive and SharePoint connection

To create a connection to your Microsoft OneDrive and SharePoint instance, perform the following steps:
  1. In Automation Cloud, select Integration Service from the rail.
  2. From the Connectors list, select Microsoft OneDrive and SharePoint. You can also use the search bar to narrow down the connector.
  3. Select Connect to Microsoft OneDrive and SharePoint, which redirects you to the connection page.
  4. Select the OAuth 2.0 Authorization code authentication type.
  5. Configure the following:
    • Scope - Add or remove permissions for your connector.
    • Environment - Optionally, select an environment from the dropdown list:
      • Office 365 (default)
      • US Government L4 - Public Sector domain
      • US Government L5 - Public Sector domain
      • China

        Select Office 365 (default) for all regions, and only switch to Government or China for cloud deployments. For more details on environments, check Microsoft Graph and Graph Explorer service root endpoints.

  6. Select Connect.
  7. Authenticate with your Microsoft email address and password.

Refresh tokens for OAuth applications

Refresh tokens for OAuth applications can be invalidated or revoked at any time by Microsoft. This can happen for different reasons, such as timeouts and revocations. For details, see Microsoft's official documentation.

Warning: Token invalidation results in failed connections and automations are unable to run without fixing connections.

Make sure to follow best practices from Microsoft when creating your OAuth applications. For full details on how to create a Microsoft OAuth app, see the Microsoft documentation.

This issue affects not only the OneDrive & SharePoint connector, but all Microsoft Graph-based connectors, such as Outlook or Teams.

OAuth 2.0 Client credentials

Scopes

The connector requires the following minimum scopes to create a connection: Files.Read.
The connector requires the following full set of scopes for all activities to function: offline_access, Files.Read, Files.Read.All, Files.ReadWrite, Files.ReadWrite.All, Sites.Read.All, Sites.ReadWrite.All, Group.Read.All, Group.ReadWrite.All, profile, openid, email, User.Read.All, and User.Read.

To add more granular permissions, refer to the activities documentation.

Adding the Microsoft OneDrive and SharePoint connection

To create a connection to your Microsoft OneDrive and SharePoint instance, perform the following steps:
  1. In Automation Cloud, select Integration Service from the rail.
  2. From the Connectors list, select Microsoft OneDrive and SharePoint. You can also use the search bar to narrow down the connector.
  3. Select Connect to Microsoft OneDrive and SharePoint, which redirects you to the connection page.
  4. Select the OAuth 2.0 Client credentials authentication type.
  5. Configure the following:
    • Client ID - The client ID from the Overview section of your Microsoft Azure application registration.
    • Client secret - The client secret from the Certificates & secrets section of your Microsoft Azure application.
    • Tenant ID - The Microsoft Azure tenant ID for an app from the Overview section.
    • Environment - Optionally, select an environment from the dropdown list:
      • Office 365 (default)
      • US Government L4 - Public Sector domain
      • US Government L5 - Public Sector domain
      • China

        Select Office 365 (default) for all regions, and only switch to Government or China for cloud deployments. For more details on environments, check Microsoft Graph and Graph Explorer service root endpoints.

    • Account - Represents the account used to impersonate a user. Specify the user principal name (UPN) of the account or shared mailbox to be used in connection. This is required for the connection to be established.
  6. Select Connect.

Bring your own OAuth 2.0 app

Overview

To learn how to create an application, check the official Microsoft documentation: Register an application with the Microsoft identity platform.

Note: This is an advanced functionality and requires admin privileges in the target application. Work with your IT administrator to set up your application successfully.
Requirements

When you create your own application to use with Integration Service, make sure you meet the following requirements:

  1. Configure the application as a Multi-tenant or Single-tenant application.
  2. Configure a Web application.
  3. Configure a Web Redirect URI. The Redirect URI (or callback URL) for your OAuth 2.0 application is provided in the authentication screen when creating a connection: https://cloud.uipath.com/provisioning_/callback.
  4. You must set up delegated permissions. For more information, refer to Permissions in the Microsoft official documentation.
  5. Generate a client secret for your application.
Important: The advantage of using your private OAuth application is that you can customize permissions depending on your actual needs. To learn which scopes are required for each activity in the Microsoft 365 package, refer to Working with scopes and check out the activities documentation.

The connector uses Microsoft Graph API. Refer to the Microsoft Graph permissions reference page for details on all permissions.

After you create your application, use its Client ID and Client Secret to create a connection with the Microsoft connectors.

Scopes

  • The connector requires the following minimum scopes to create a connection: openid, offline_access, User.Read.All or User.Read, Files.Read.
  • OneDrive triggers require the following minimum scopes:
    • openid, offline_access, User.Read.All or User.Read, Sites.Read.All – for events on SharePoint sites.
    • Group.Read.All – for events on groups and calendars.
    • Files.Read.All – for all the remaining event types.
The connector requires the following full set of scopes for all activities to function: offline_access, Files.Read, Files.Read.All, Files.ReadWrite, Files.ReadWrite.All, Sites.Read.All, Sites.ReadWrite.All, Group.Read.All, Group.ReadWrite.All, profile, openid, email, User.Read.All, and User.Read.

To add more granular permissions, refer to the activities documentation.

Adding the Microsoft OneDrive and SharePoint connection

To create a connection to your Microsoft OneDrive and SharePoint instance, perform the following steps:
  1. In Automation Cloud, select Integration Service from the rail.
  2. From the Connectors list, select Microsoft OneDrive and SharePoint. You can also use the search bar to narrow down the connector.
  3. Select Connect to Microsoft OneDrive and SharePoint, which redirects you to the connection page.
  4. Select the Bring your own OAuth 2.0 app authentication type.
  5. Configure the following:
    • Client ID - The client ID from the Overview section of your Microsoft Azure application registration.
    • Client secret - The client secret from the Certificates & secrets section of your Microsoft Azure application.
    • Scope - Add or remove permissions for your connector.
    • Tenant ID - The Microsoft Azure tenant ID for an app from the Overview section.
      Note:
      • If you use a multi-tenant application, keep the default value common.
      • If you use a single-tenant application, retrieve the tenant ID from Azure. For more details, check How to find your Microsoft Entra tenant ID.
    • Environment - Optionally, select an environment from the dropdown list:
      • Office 365 (default)
      • US Government L4 - Public Sector domain
      • US Government L5 - Public Sector domain
      • China

        Select Office 365 (default) for all regions, and only switch to Government or China for cloud deployments. For more details on environments, check Microsoft Graph and Graph Explorer service root endpoints.

  6. Select Connect.

Refresh tokens for OAuth applications

Refresh tokens for OAuth applications can be invalidated or revoked at any time by Microsoft. This can happen for different reasons, such as timeouts and revocations. For details, see Microsoft's official documentation.

Warning: Token invalidation results in failed connections and automations are unable to run without fixing connections.

Make sure to follow best practices from Microsoft when creating your OAuth applications. For full details on how to create a Microsoft OAuth app, see the Microsoft documentation.

This issue affects not only the OneDrive & SharePoint connector, but all Microsoft Graph-based connectors, such as Outlook or Teams.

Was this page helpful?

Get The Help You Need
Learning RPA - Automation Courses
UiPath Community Forum
Uipath Logo
Trust and Security
© 2005-2025 UiPath. All rights reserved.