Connection - OneDrive
The OneDrive Connection stores the sign-in and security settings that these Tasks and Triggers use to connect to Microsoft OneDrive:
- Cloud - Upload file(s)
- Cloud - Download file(s)
- Cloud - List item(s)
- Cloud - List folder(s)
- Cloud - Create folder
- Cloud - Delete item(s)
- Cloud - Copy/move item(s)
- Cloud - Sync file(s)
- The Cloud file Trigger
Use it to transfer or sync files between OneDrive and a local folder, or between OneDrive and another cloud service.
Common settings

The Common settings and Proxy tabs are the same for every Connection type that has them; see Common settings and Proxy.
Test asks the Server to connect with the stored sign-in and read the root folder of the OneDrive.
Main settings

These fields are on Connection settings -> Main settings.
App Key
The Application (client) ID of the app that you register in Microsoft Entra ID. Required.
App Secret
A client secret of that app.
Redirect Url
The address that Microsoft sends the sign-in result to. Default: "http://localhost:9999". Add the same address as a redirect URI of the app.
Auto-accept server certificates
Selected by default.
OneDrive Connections accept any server certificate, whether or not Auto-accept server certificates is selected. The Server does not check the server certificate when it connects to OneDrive, so it cannot tell the real server from another server that answers at the same address. Connect to OneDrive only over a network path that you trust.
Create an account
Opens the App registrations page of the Azure portal.
Authenticate
Starts the Microsoft sign-in.
How to create a OneDrive Connection
To create a OneDrive Connection, complete the following steps:
-
Click Create an account to open App registrations in the Azure portal.
-
Click New registration.
-
Under Supported account types, select a type that includes the accounts that own the OneDrive: personal Microsoft accounts for a personal OneDrive, or your organization's accounts for OneDrive for work or school.
-
Click Register.
-
Copy the Application (client) ID into App Key.
-
Under Certificates & secrets, create a client secret.
-
Copy the value of the client secret into App Secret.
-
Under Authentication, add the value of Redirect Url, by default "http://localhost:9999", as a redirect URI.
-
Click Authenticate.
-
Sign in with the Microsoft account.
-
Accept the permissions that VisualCron requests.
-
Click OK to save the Connection.
-
Click Test on the Common settings tab.
The test reports that it was successful.
Authentication and token expiry
- Authenticate runs on the computer where the Client runs. The browser opens there, and the Client listens for the sign-in result on the port of Redirect Url, so that port must be free on that computer
- After the sign-in, the Connection stores the refresh token encrypted, and the Server uses it at run time
- When Microsoft no longer accepts the refresh token, the Server marks the Connection as expired, and the Client shows the message "Connection session expired". Open the Connection and click Authenticate again