Microsoft OneDrive
Connect a OneDrive account (whole drive or one folder) to Datasaur to attach the drive to a knowledge base, which keeps its documents in sync on a schedule you set.
Prerequisites
A Microsoft account (Personal) or a Microsoft 365 account (Business).
Permission to register an application in the Azure Portal, or an admin who can do it for you.
Setup
Step 1 — Register an Application

Open the Azure Portal and go to Microsoft Entra ID.
Select App registrations, then click New registration.
Enter a Name, for example
Datasaur OneDrive.Under Supported account types, choose Accounts in any organizational directory and personal Microsoft accounts if you are connecting a personal OneDrive. For Business only, the default single-tenant option works.
Under Redirect URI, select Web and enter:
On Datasaur Cloud, use
https://llm.datasaur.ai/api/eos/authorization/onedrive. Self-hosted deployments must be served over HTTPS.Click Register.
From the Overview blade, copy the Application (client) ID and the Directory (tenant) ID.
Step 2 — Add API Permissions

Go to API permissions and click Add a permission.
Select Microsoft Graph, then Delegated permissions.
Add
Files.Read.All, then click Add permissions.For a Business account, click Grant admin consent if your tenant requires it. Personal accounts consent at sign-in instead. After admin consent is granted, a white check mark with green background should appear in the status column.
Datasaur also requests openid, profile, and offline_access. You do not need to add these. Sites.Read.All is not needed — that is for the SharePoint integration.
Step 3 — Create a Client Secret

Go to Certificates & secrets and click New client secret.
Enter a description, choose an expiry, and click Add.
Copy the secret's Value — not the Secret ID.
Step 4 — Get the Folder URL (optional)
Leave this blank to connect your whole drive. To connect one folder, right-click it in OneDrive, select Share, and click Copy link.
The URL must point to a folder, not a file, and must belong to the account you sign in with. A Personal link will not work with a Business account, or the reverse. You can also paste a URL copied from the OneDrive address bar, but only if it contains an id= parameter. Without it, Datasaur connects your whole drive and gives no error. A SharePoint site URL is rejected. Use the SharePoint integration instead.
Personal
https://1drv.ms/f/c/xxxxxxxxxxxx/...
Business
https://contoso-my.sharepoint.com/:f:/g/personal/user_contoso_com/...
Step 5 — Connect OneDrive in LLM Labs
Go to Settings > External object storage and click Add external object storage.
Select OneDrive.
Fill in the form:
FieldRequiredNotesAzure AD Application (client) ID
Yes
From Step 1.
Client secret
Yes, for a Web registration
From Step 3.
Tenant ID
Only for single-tenant apps
From Step 1.
Folder URL
No
Blank connects your My files.
Click Authorize
Sign in with the Microsoft account that owns the drive and click Accept on the consent screen.

You return to Datasaur. The connection is named after what it resolved to, such as
(user@contoso.com) My files, or that name plus the folder path for a scoped connection. You can rename it.
Using the Connection
Open a knowledge base, choose Connect object storage..., and pick your OneDrive connection.


Set the sync rules and schedule, then click Connect object storage.

The connection syncs everything in scope by those rules. It is not a file-by-file picker. To change the rules later, use Edit rules or schedule... on the connected source, available once the knowledge base has been updated.

You can add several connections for different folders on the same drive. Renaming or moving a connected folder does not break the connection. Folders shared with you can be connected too.
Last updated