How to Set Up Microsoft OneDrive Integration Hub SpokeSummary<!-- /*NS Branding Styles*/ --> .ns-kb-css-body-editor-container { p { font-size: 12pt; font-family: Lato; color: #000000; } span { font-size: 12pt; font-family: Lato; color: #000000; } h2 { font-size: 24pt; font-family: Lato; color: black; } h3 { font-size: 18pt; font-family: Lato; color: black; } h4 { font-size: 14pt; font-family: Lato; color: black; } a { font-size: 12pt; font-family: Lato; color: #00718F; } a:hover { font-size: 12pt; color: #024F69; } a:target { font-size: 12pt; color: #032D42; } a:visited { font-size: 12pt; color: #00718f; } ul { font-size: 12pt; font-family: Lato; } li { font-size: 12pt; font-family: Lato; } img { display: ; max-width: ; width: ; height: ; } } Automate file and folder management and collaboration in Microsoft OneDrive by integrating it with your ServiceNow instance. The Microsoft OneDrive spoke allows you to access and manage OneDrive data directly from ServiceNow. Before you begin, review the official documentation and store details to understand the spoke flows, subflows, and actions to ensure they meet your requirements: Documentation: Microsoft OneDrive SpokeServiceNow Store: Microsoft OneDrive Spoke This article guides you through configuring the Microsoft OneDrive Spoke in your ServiceNow instance. Release<!-- /*NS Branding Styles*/ --> .ns-kb-css-body-editor-container { p { font-size: 12pt; font-family: Lato; color: #000000; } span { font-size: 12pt; font-family: Lato; color: #000000; } h2 { font-size: 24pt; font-family: Lato; color: black; } h3 { font-size: 18pt; font-family: Lato; color: black; } h4 { font-size: 14pt; font-family: Lato; color: black; } a { font-size: 12pt; font-family: Lato; color: #00718F; } a:hover { font-size: 12pt; color: #024F69; } a:target { font-size: 12pt; color: #032D42; } a:visited { font-size: 12pt; color: #00718f; } ul { font-size: 12pt; font-family: Lato; } li { font-size: 12pt; font-family: Lato; } img { display: ; max-width: ; width: ; height: ; } } N/A Instructions<!-- /*NS Branding Styles*/ --> .ns-kb-css-body-editor-container { p { font-size: 12pt; font-family: Lato; color: #000000; } span { font-size: 12pt; font-family: Lato; color: #000000; } h2 { font-size: 24pt; font-family: Lato; color: black; } h3 { font-size: 18pt; font-family: Lato; color: black; } h4 { font-size: 14pt; font-family: Lato; color: black; } a { font-size: 12pt; font-family: Lato; color: #00718F; } a:hover { font-size: 12pt; color: #024F69; } a:target { font-size: 12pt; color: #032D42; } a:visited { font-size: 12pt; color: #00718f; } ul { font-size: 12pt; font-family: Lato; } li { font-size: 12pt; font-family: Lato; } img { display: ; max-width: ; width: ; height: ; } } Step 1: Configure Microsoft OneDrive Application in Microsoft Azure Portal Create a custom OAuth application in Microsoft Azure to enable OAuth 2.0 authentication with ServiceNow. Log in to Azure portal with your organization credentials.Register a new application:Enter an application nameSelect supported account typeProvide redirect URI in this format: https://<instance>.service-now.com/oauth_redirect.doClick Register Copy Application (Client) ID and Directory (Tenant) ID for later use. Add a client secret: Navigate to Manage > Certificates & secretsProvide description and expiration date, click AddCopy the client secret immediately and store it securely for later use in ServiceNow. Enable required API permissions: Navigate to Manage > API permissionsClick the Microsoft Graph tileSelect Delegated or Application permissions depending on your use case Required scopes: NameOAuth ScopeCalendars.ReadWrite Calendars.ReadWriteCalendars.ReadWrite.Shared Calendars.ReadWrite.SharedemailemailFiles.ReadFiles.ReadFiles.Read.AllFiles.Read.Alloffline_accessoffline_access Click Add permissions to finalize. Step 2: Create Connection and Credential Alias in ServiceNow Connections allow the OneDrive spoke to authenticate and perform actions on your account. Navigate to All > IntegrationHub > Connections & Credential Aliases > OneDriveClick Create New Connection & Credential Fill in the form: FieldValueConnection NameMicrosoft OneDrive Spoke Connection (default)Connection URLhttps://graph.microsoft.comOAuth Entity NameMicrosoft OneDrive Spoke Auth (default)OAuth Client IDApplication ID from AzureOAuth Client SecretClient secret from AzureOAuth Redirect URL https://<your-instance>.service-now.com/oauth_redirect.do Click Create and Get OAuth Token Important Note: By default, the authorization code and token URLs are set for multi-tenant applications. If you are using a single-tenant application, you must update the URLs in the Microsoft OneDrive Spoke Auth application registry: Authorization URL: https://login.microsoftonline.com/<Directory-ID>/oauth2/v2.0/authorizeToken URL: https://login.microsoftonline.com/<Directory-ID>/oauth2/v2.0/token Fetch the OAuth token: Navigate to All > IntegrationHub > Connections & Credential Aliases > OneDriveOpen the credential record Click on Get OAuth Token under Related Links to fetch the tokens. Accept the requested permissions on the Azure. Validate the token: Once authorization is complete, you will see the Token Available message on the credential record. You can also navigate to All > System OAuth > Manage Tokens to view the tokens. The Microsoft OneDrive spoke is now set up and integrated with your ServiceNow instance. You may proceed to the bonus step to test the integration. Bonus Step: Test the Integration with Spoke Actions You can test the integration using actions like Look up Drive Info or Create Folder. Navigate to Flow Designer > ActionsSearch for the Look up Drive Info action This action retrieves the metadata of a specific Microsoft OneDrive drive Alternatively, you can test the integration by using the Create Folder action to create a new folder in OneDrive. Successfully performing these actions confirms the integration is working as expected. If you encounter any issues, please revisit the steps above or contact us for assistance whenever needed.