Skip to main content
Microsoft OneDrive Logo

OneDrive Toolset

Cloud files, sharing, and OneNote notebooks

ReadyMicrosoft 365

Overview

The OneDrive toolset lets AI agents work with files in Microsoft OneDrive (and other drives you can access through Microsoft Graph), including shared libraries, downloads, sharing with people, and basic OneNote notebook operations. It uses delegated OAuth (user consent) so actions run as the signed-in user.

Key Capabilities

  • Drives and browsing - List drives, open the root folder, list folders and files, and fetch item metadata
  • Search - Search within a drive by keyword; search across content shared with you
  • Shared with me - List and search files others have shared with you without needing a drive ID first
  • File and folder actions - Create folders, rename, move, and copy items (copy may complete asynchronously)
  • Sharing - Invite specific people by email with read, write, or owner roles
  • Content and links - Get short-lived download URLs; read file content (parsed text and structured output for many formats, subject to size limits)
  • New Word files - Create a new .docx in a folder, optionally with initial text content
  • OneNote - Create notebooks, sections, and pages; list sections and pages; read page HTML
Almost every operation that targets a specific drive needs a drive_id. Call get_drives first when the drive is unknown.

Available Tools

Drive and navigation

Search and shared content

Organize, copy, and share

Download and read content

Create files and OneNote


Configuration Guide

Step 1: Open App registrations from the Azure portal home

  1. Go to portal.azure.com and sign in.
  2. On the home page, find Azure services and click App registrations. You can also search the top bar for App registrations or open Microsoft Entra ID and choose App registrations from there.
Azure portal home with App registrations

Step 2: Start a new registration

On the App registrations page, click + New registration.
App registrations list with New registration

Step 3: Register the application

  1. Name: Enter a display name (for example, PipesHub OneDrive Toolset).
  2. Supported account types: Choose who can sign in—for example Accounts in any organizational directory and personal Microsoft accounts for broad support, or a single-tenant option if you only use your organization.
  3. Redirect URI: Use the Web redirect URI from the PipesHub Configure OneDrive (or Microsoft 365 files) dialog in toolset settings where OneDrive is set up—for example Workspace → Actions and the OneDrive toolset + Setup / Configure flow.
PipesHub Configure OneDrive dialog showing Redirect URI
  1. Click Register.
Register an application form in Azure

Step 4: Copy Application (client) ID and Directory (tenant) ID

On the Overview page for your app, copy:
  • Application (client) ID — used as Client ID in PipesHub.
  • Directory (tenant) ID — used as Tenant ID in PipesHub (or use common / leave blank per the toolset dialog if you want both work/school and personal accounts).
App registration Overview with client and tenant IDs
Use the Application (client) ID, not the Object ID. They are different values.

Step 5: Create a client secret

  1. In the left sidebar under Manage, open Certificates & secrets.
  2. On the Client secrets tab, click + New client secret.
  3. Add a description, choose an expiration, then click Add.
  4. Copy the secret value immediately — it is shown only once.
Certificates and secrets with new client secret
If you leave this page without copying the secret, you cannot read it again—create a new client secret instead.

Step 6: Add Microsoft Graph API permissions

  1. In the left sidebar, open API permissions.
  2. Click + Add a permissionMicrosoft GraphDelegated permissions.
  3. Add the permissions your agents need, for example:
If users rely on SharePoint document libraries that appear as drives, you may also need delegated Sites permissions appropriate to your tenant (for example Sites.Read.All or Sites.ReadWrite.All). Start with the table above and add permissions if Graph returns authorization errors for specific drives.
The OneDrive toolset uses Delegated permissions so actions run as the signed-in user, not only as the application.
Microsoft Graph delegated API permissions for OneDrive
Click Grant admin consent for your organization (the button includes your tenant name) and confirm, so delegated permissions show as granted for the tenant (especially for permissions that require admin approval).
API permissions with Grant admin consent

Step 8: Configure the OneDrive toolset in PipesHub

  1. In PipesHub, go to WorkspaceActions (or the area where toolsets are configured for your workspace).
  2. Find OneDrive (or the Microsoft 365 files toolset that includes these tools) and open setup / configuration (+ Setup or Configure).
  3. Confirm the Redirect URI in the dialog matches the Web redirect URI you registered in Azure Step 3.
  4. Enter Client ID, Client Secret, and optionally Tenant ID (common or your tenant/domain per the form), then create or save the instance.
PipesHub OneDrive toolset configuration with Client ID, secret, and redirect URI

Step 9: Authenticate the toolset under Your actions

  1. Open Your actions (or the equivalent entry under Personal in the sidebar).
  2. Select your OneDrive instance and complete Authenticate with OAuth (Microsoft sign-in, then accept permissions).
OneDrive toolset OAuth sign-in and consent in PipesHub

Step 10: Add OneDrive to an agent

  1. Go to the Home page.
  2. Next to Agents, click + to create a new agent.
  3. Give the agent a name, drag the OneDrive toolset onto the canvas, connect it to the Agent node with your model and chat input/output, then create the agent.
Agent builder with a Microsoft 365 toolset connected

FAQ

Example: Use the OneDrive Connector to ingest documents for semantic search. Use the OneDrive Toolset when the agent should list folders, search by keyword, copy files, or share a document while the user is signed in.

Usage Tips

Example: Find a document by name
Ask the agent to search your OneDrive for “Q3 roadmap” (it should resolve drive_id, then run search_files or browse folders as needed).
Example: Move a file into a folder
Ask to move “Budget.xlsx” into the “Archive” folder (the agent can search for IDs, then call move_item).
Example: Share read-only with a colleague
Ask to share a specific file with alice@contoso.com with view access.