OneDrive

Integrate OneDrive with your AI workspace

OneDrive is Microsoft’s cloud storage solution enabling users to store, sync, and share files across devices, offering offline access, real-time collaboration, and enterprise-grade security

Explore Triggers and Actions

File Updated

Trigger that fires when a OneDrive file's content or metadata changes. Returns file ID, last modified time, and modifier info.

TriggerpollTry it

Item Moved or Renamed

Triggers when a file or folder is moved to a different path or renamed in OneDrive. Includes both old and new path/name data in the payload.

TriggerpollTry it

New Version Created

Trigger that fires when a new version of a specified OneDrive file is created.

TriggerpollTry it

OneDrive File Created Trigger

Triggers when a new file is created in OneDrive. Uses Gmail-style state management for reliable duplicate prevention.

TriggerpollTry it

OneDrive Folder Created Trigger

Triggers when a new folder is created in OneDrive. Uses Gmail-style state management for reliable duplicate prevention.

TriggerpollTry it

OneDrive Item Deleted Trigger

Triggers when a file or folder is deleted in OneDrive. Uses Gmail-style state management for reliable duplicate prevention.

TriggerpollTry it

OneDrive Item Updated Trigger

Triggers when an existing file or folder is modified in OneDrive. Uses Gmail-style state management and only detects actual modifications, not new creations.

TriggerpollTry it

Onedrivebasetrigger

Base trigger for OneDrive changes using Gmail-style state management. Subclasses override `filter_changes(...)` to extract only the relevant items.

TriggerpollTry it

Sharing Permission Added or Removed

Sharing Permission Added or Removed

TriggerpollTry it

Add Workbook Worksheet

Adds a new worksheet to an existing Excel workbook in OneDrive or SharePoint. The worksheet is created with the specified name and appended to the end of the workbook's worksheet collection. Use this action when you need to create a new sheet in an Excel file to organize data, add reports, or separate information into logical sections.

ActionTry it

Check In Drive Item

Tool to check in a checked out driveItem resource, making the version of the document available to others. Use when you need to check in a file that was previously checked out in OneDrive or SharePoint.

ActionTry it

Checkout Drive Item

Tool to check out a driveItem to prevent others from editing it and make your changes invisible until checked in. Use when you need to lock a file for exclusive editing in SharePoint or OneDrive.

ActionTry it

Clear Workbook Range

Clears values, formats, or both from a worksheet range in an Excel workbook stored in OneDrive or SharePoint without deleting cells or shifting neighboring data. Use this action when you need to reset a range while preserving the worksheet's cell structure.

ActionTry it

Copy Item

Tool to copy a DriveItem (file or folder) to a new location asynchronously. Use when you need to duplicate an item, optionally renaming it or specifying a different parent folder. The operation is asynchronous; the response provides a URL to monitor the copy progress. Do not assume the copy is complete immediately; verify via ONE_DRIVE_GET_ITEM or by listing the destination, especially for large folder trees.

ActionTry it

Create a new text file

Creates a new plain-text file with specified content in the authenticated user's personal OneDrive, using either the folder's unique ID or its absolute path relative to the user's OneDrive root (paths are automatically resolved to IDs); note that OneDrive may rename or create a new version if the filename already exists. All files are written as plain text regardless of extension — specifying .docx or .xlsx does not produce a true Office document. This action only works with the user's personal OneDrive (/me/drive) and does not support SharePoint document libraries or shared drives.

ActionTry it

Create Drive Item Permission

Tool to create a new permission on a OneDrive drive item. Use when you need to grant application or SharePoint group permissions to a file or folder. This endpoint supports creating application permissions and SharePoint site group permissions only.

ActionTry it

Create folder

Creates a new folder in the user's OneDrive with configurable conflict behavior, optionally within a specified parent_folder (by ID or full path from root) which, if not the root, must exist and be accessible.

ActionTry it

Create SharePoint List Item

Create an item in a SharePoint list using Microsoft Graph through the OneDrive connection. Use when you need to add a new row/item to a SharePoint list after resolving the site ID and list ID.

ActionTry it

Create Sharing Link

Tool to create a sharing link for a DriveItem (file or folder) by its unique ID. Use when you need to generate a shareable link for an item in OneDrive or SharePoint.

ActionTry it

Delete Drive Following

Tool to unfollow a driveItem by removing it from the user's followed items collection. Use when you need to stop following a file or folder that was previously marked to follow.

ActionTry it

Delete Drive Item Permission

Tool to delete a permission from a drive item. Use when you need to revoke sharing access to a file or folder. Only non-inherited sharing permissions can be deleted.

ActionTry it

Delete Item

Tool to delete a DriveItem (file or folder) by its unique ID from the authenticated user's OneDrive. Use when you need to remove an item from OneDrive. This action moves the item to the recycle bin, not permanently deleting it; storage quota is not freed until the recycle bin is emptied. Bulk deletions can trigger 429 (rate limit) or 5xx responses — limit concurrency and use exponential backoff.

ActionTry it

Delete SharePoint Item Permission

Revoke a Microsoft Graph beta permission from a SharePoint list or list item.

ActionTry it

Delete Shares Permission

Tool to delete the permission navigation property for a shared drive item. Use when you need to remove a sharing link permission. This effectively revokes access via the specific share link.

ActionTry it

Delete Workbook Range

Deletes a range of cells from a worksheet in an Excel workbook stored in OneDrive. Use this action when you need to remove a specific cell range and shift the remaining cells to fill the gap. This action is irreversible — the deleted range cannot be recovered once removed. The operation requires Files.ReadWrite scope and the workbook must not be locked by another user or process.

ActionTry it

Delete Workbook Worksheet

Deletes a worksheet from a workbook in OneDrive by its ID or name. Use this action when you need to remove a specific worksheet from an Excel workbook stored in OneDrive or SharePoint. This action is irreversible — the worksheet cannot be recovered once deleted. Note that deleting the last visible worksheet in a workbook may result in an error.

ActionTry it

Discard Checkout

Tool to discard the checkout of a driveItem, releasing it and discarding any changes made while checked out. Use when you need to cancel a checkout and revert changes on a file in SharePoint or OneDrive.

ActionTry it

Download a file

Downloads a file from a user's OneDrive using its item ID, which must refer to a file and not a folder. Response contains a content object with fields: s3url (URL to fetch raw file bytes), mimetype, and name; raw file data is not returned directly. Parsing content from Excel, Word, PDF, or other formats requires additional tooling. The response also includes attachment.s3key, required when passing this file to downstream tools such as OUTLOOK_SEND_EMAIL or OUTLOOK_CREATE_DRAFT.

ActionTry it

Download Drive Item Version Content

Tool to download the contents of a specific previous version of a drive item (file). Returns the actual file content. Note: You cannot download the current version using this endpoint - it only works for previous versions.

ActionTry it

Download file by path

Downloads the contents of a file from OneDrive by its path. The API returns a 302 redirect to a pre-authenticated download URL. Use when you know the file path but not the item ID.

ActionTry it

Download item as format

Tool to download the contents of a driveItem converted to a specific format (e.g., PDF or HTML). Use when you need to convert Office documents to PDF or Loop/Fluid files to HTML before downloading. Supports accessing items by item_id or by path, and can target specific drives via drive_id.

ActionTry it

Find Folder

Finds folders by name within an accessible parent folder in OneDrive, or lists all its direct child folders if no name is specified. Search is non-recursive: only immediate children of `folder` are checked, not deeper hierarchy levels.

ActionTry it

Find Item

Non-recursively finds an item (file or folder) in a specified OneDrive folder; if `folder` is provided as a path, it must actually exist. Results in large folders may be paginated via `@odata.nextLink`; iterate all pages to avoid missing files. For searches where the subfolder is unknown, use ONE_DRIVE_SEARCH_ITEMS instead.

ActionTry it

Follow Drive Item

Tool to follow a driveItem (file or folder) in OneDrive or SharePoint. Use when you need to add an item to the user's followed items list for tracking updates.

ActionTry it

Get document comments

Extracts comments from a Word .docx file in OneDrive. The action downloads the document, parses the OOXML comments part, and returns structured comment data inline. When possible, it also includes the selected text and paragraph context from the document body so agents can understand what each comment refers to.

ActionTry it

Get Drive

Retrieves the properties and relationships of a Drive resource by its unique ID. Use this action when you need to get details about a specific OneDrive, user's OneDrive, group's document library, or a site's document library. Only drives accessible to the authenticated user are returned; missing drives indicate insufficient OAuth scope or tenant permissions.

ActionTry it

Get Drive Root Folder

Tool to retrieve metadata for the root folder of the signed-in user's OneDrive. Use when you need information about the user's OneDrive root directory, such as size, child count, or web URL.

ActionTry it

Get Drive Special Folder

Tool to retrieve a special folder in OneDrive by name. Use when you need to access well-known folders (documents, photos, approot, etc.) without looking up by path or ID.

ActionTry it

Get DriveItem by Sharing URL

Tool to resolve a OneDrive/SharePoint sharing URL (or shareId) to a DriveItem with driveId and itemId. Use when you have a sharing link from Teams, chat, or 1drv.ms and need the item's metadata or IDs for downstream actions like permissions or download.

ActionTry it

Get Drives Following

Tool to retrieve a specific followed driveItem from a drive. Use when you need to get details about a file or folder that the user has marked to follow.

ActionTry it

Get Group Drive

Tool to retrieve the document library (drive) for a Microsoft 365 group. Use when you need to access the default document library associated with a specific group.

ActionTry it

Get Item Metadata

Retrieves the metadata of a DriveItem by its unique ID. Use this tool to get information about a specific file or folder in OneDrive when you have its ID. If a `drive_id` is not provided, it defaults to the user's main drive.

ActionTry it

Get Item Permissions

Retrieves the permissions of a DriveItem by its unique ID within a specific Drive. Use when you need to check who has access to a file or folder and what level of access they have. Response nests permission entries under `data.value`; check top-level `success`/`error` flags before processing results. Results include inherited permissions, owner entries, and anonymous link entries — not just explicitly granted permissions. Sharing links may have differing scopes (org-only vs. anonymous); verify `link.scope` before treating a permission as externally accessible.

ActionTry it

Get Item Thumbnails

Tool to retrieve the thumbnails associated with a DriveItem. Use when you need to display visual previews of files. Response contains a `value` array with size keys (`small`, `medium`, `large`); thumbnails may not be generated for all file types or newly uploaded items, so handle an empty or missing `value` array. Returned thumbnail URLs are external HTTP endpoints with independent availability.

ActionTry it

Get Item Versions

Tool to retrieve the version history of a DriveItem by its unique ID. Use when you need to access or list previous versions of a file. Version history may be unavailable or empty for folders or items in drives without versioning enabled.

ActionTry it

Get Recent Items

DEPRECATED: Microsoft has deprecated the `GET /me/drive/recent` endpoint backing this action; it already runs in a degraded state and stops returning data after November 2026. This action is retained for backward compatibility and will be removed once the upstream API is fully retired. Get files and folders recently accessed by the user. Returns items based on activity history (opened, edited, viewed), sorted by most recent first — NOT by modification time; use ONE_DRIVE_ONEDRIVE_LIST_ITEMS or ONE_DRIVE_LIST_ROOT_DRIVE_CHANGES for strictly modification-based queries. Use when you need to see what the user worked on recently (e.g., 'Show me files I worked on today'). Different from search - this tracks activity, not content. Results may contain duplicate names; disambiguate using lastModifiedDateTime, parentReference.path, and the file/folder property before acting on a specific item.

ActionTry it

Get Shared Item by ShareId

Tool to access a shared DriveItem or collection of shared items using a shareId or encoded sharing URL. Returns the sharedDriveItem resource with metadata about the shared item and its owner. Use when you have a shareId or sharing token and need information about what was shared.

ActionTry it

Get Shared Items

DEPRECATED: Use ONE_DRIVE_SEARCH_DRIVE_ITEMS to find a specific shared file or ONE_DRIVE_LIST_ONEDRIVE_SHARED_ITEMS to list files shared from other people's OneDrive accounts. Microsoft Graph sharedWithMe is degraded until November 2026 and will stop returning data after that.

ActionTry it

Get SharePoint List Items

Tool to get the items (list items) within a specific SharePoint list on a site. Use when you need to retrieve data from a SharePoint list.

ActionTry it

Get SharePoint Site Page Content

Gets the content of a modern SharePoint site page. Use when you need to retrieve the details and content of a specific page within a SharePoint site.

ActionTry it

Get Site Details

Retrieves metadata for a specific SharePoint site by its ID. Use this action when you need to get details like display name, web URL, and creation/modification dates for a known SharePoint site.

ActionTry it

Get User Profile

Retrieves the properties and profile information for a specific Microsoft user by their user ID or user principal name. Use this action when you need to get detailed information about a user's profile, including their contact details, job information, and account status. This action requires the User.Read or User.ReadBasic.All OAuth scope to access user profile data.

ActionTry it

Get Workbook Used Range

Retrieves the used range of a worksheet in an Excel workbook stored in OneDrive or SharePoint without requiring the caller to know an explicit A1 range address. Use this action to read the active data region of a worksheet, optionally ignoring formatting-only cells.

ActionTry it

Get Workbook Worksheet

Retrieves a specific worksheet from an Excel workbook stored in OneDrive or SharePoint using Microsoft Graph API. Use this action when you need to get details about a particular worksheet, including its ID, name, position, and visibility. The worksheet can be identified by either its unique ID or its display name.

ActionTry it

Grant SharePoint Item Permission

Grant an application permission on a SharePoint list or list item using Microsoft Graph beta.

ActionTry it

Grant Shares Permission

Tool to grant users access to a link represented by a permission using an encoded sharing URL. Use when you need to give specific users access to a shared OneDrive or SharePoint resource.

ActionTry it

Invite User to Drive Item

Tool to invite users or grant permissions to a specific item in a OneDrive drive. Use when you need to share a file or folder with other users and define their access level (e.g., read or write).

ActionTry it

List All Drive Items Recursively

Recursively lists all files and folders in a OneDrive drive by traversing the entire folder hierarchy. Starts at the drive root and explores every subfolder to return a complete flattened list of all items. Use this action when you need a comprehensive inventory of all drive contents, want to search across all folders, or need to analyze the complete drive structure. For large drives with thousands of items, this operation may take significant time as it must traverse every folder.

ActionTry it

List Drive Activities

Tool to retrieve recent activities on the authenticated user's OneDrive. Use when you need to track recent changes or actions performed across the drive.

ActionTry it

List Drive Bundles

Tool to retrieve a list of bundle resources from a specified drive. Bundles are collections of files (e.g., photo albums). Use when you need to list bundles in a drive.

ActionTry it

List Drive Item Activities

Tool to list recent activities for a specific item in a OneDrive drive. Use when you need to track changes or actions performed on a file or folder.

ActionTry it

List Drives

Tool to retrieve a list of Drive resources available to the authenticated user, or for a specific user, group, or site. Use when you need to find out what drives are accessible. Returns only drives within the signed-in account's permission scope; missing drives indicate insufficient permissions or different tenant scope. Results are paginated — follow skip_token across all pages to avoid missing drives. Returned drives represent document libraries and may not reflect full SharePoint site structure; use SHARE_POINT_GET_SITE_COLLECTION_INFO or SHARE_POINT_SEARCH_QUERY for broader coverage. Use driveType and webUrl to distinguish personal, system, and SharePoint-backed drives.

ActionTry it

List Folder Children

List the direct children (files/folders) of a OneDrive/SharePoint folder by DriveItem ID or path. Returns reliable pagination tokens/nextLink for large folders. Use when you need to enumerate folder contents deterministically, find companion artifacts (e.g., .vtt/.docx files), or browse within a known folder.

ActionTry it

List OneDrive items

Retrieves all files and folders as `driveItem` resources from the root of a specified user's OneDrive, automatically handling pagination. Non-recursive: returns only root-level items; subfolder contents require separate calls. Results may include `remoteItem` pointers (shared items from other drives) — use `remoteItem.driveId` and `remoteItem.id` for those in downstream calls. Distinguish files from folders by presence of `file` or `folder` property. Always use `id` values returned by this tool directly; never construct item IDs manually. Items may be absent from results due to permission restrictions, not drive absence.

ActionTry it

List OneDrive Shared Items

List files shared from other people's OneDrive accounts using Microsoft Graph Search match-all and a OneDrive-personal URL heuristic. This excludes SharePoint-site shares by design; use ONE_DRIVE_SEARCH_DRIVE_ITEMS for broad keyword/KQL search across OneDrive and SharePoint.

ActionTry it

List Root Drive Changes

Tool to list changes in the root of the user's primary drive using a delta token. Use when you need to track file and folder modifications, additions, or deletions in the main OneDrive directory. First call without `token` returns all current items plus an `@odata.deltaLink`; store that token and pass it on subsequent calls to retrieve only incremental changes. Losing the deltaLink token forces a full resync. Responses include deleted items (check `deleted` property) and the root item itself alongside files and folders.

ActionTry it

List SharePoint Item Permissions

List Microsoft Graph beta permissions from a SharePoint list or list item.

ActionTry it

List SharePoint List Items Delta

Tool to track changes to items in a SharePoint list using a delta query. Use when you need to get newly created, updated, or deleted list items without performing a full read of the entire item collection.

ActionTry it

List Shares Permission

Tool to retrieve permission details for a shared OneDrive or SharePoint item using a share ID. Use when you have an encoded sharing URL and need to check the permission level, password protection, and access details.

ActionTry it

List Site Columns

Tool to list all column definitions for a SharePoint site. Use this when you need to retrieve the schema or structure of columns within a specific SharePoint site.

ActionTry it

List Site Drive Items Delta

Tool to track changes to DriveItems in the default document library of a SharePoint site. Use when you need to get a list of items that have been added, modified, or deleted since a previous state or to get an initial enumeration of all items.

ActionTry it

List Site Lists

Tool to list all lists under a specific SharePoint site. Use when you need to enumerate lists within a known site. Returns only Microsoft Graph-supported lists — internal/system lists are excluded, so results may be a strict subset of all site lists (e.g., 13 returned where 108 exist). Results are in the `data.value` array. IMPORTANT: Only works with organizational Microsoft 365 accounts (Azure AD/Entra ID). NOT supported for personal Microsoft accounts (MSA/Outlook.com/Hotmail). Personal OneDrive users cannot access SharePoint sites through this endpoint.

ActionTry it

List Site Subsites

Tool to list all subsites of a SharePoint site. Use when you need to retrieve a collection of subsites for a given parent site. IMPORTANT: This action only works with organizational Microsoft 365 accounts (Azure AD/Entra ID accounts). It is NOT supported for personal Microsoft accounts (MSA/Outlook.com/Hotmail accounts). Personal OneDrive users cannot access SharePoint sites through this endpoint. An empty `value` array in the response means the site has no subsites, not a failure.

ActionTry it

List Subscriptions

Tool to list the current subscriptions for the authenticated user or app. Use this to retrieve details of existing webhook subscriptions. Results may span multiple drives and resources; filter client-side by resource URL or type to narrow to a specific scope. An empty `value` array means no subscriptions exist, not a failed call.

ActionTry it

List Workbook Worksheets

Retrieves a list of all worksheets in an Excel workbook stored in OneDrive or SharePoint. Returns worksheet metadata including IDs, names, positions, and visibility states. Use this action when you need to enumerate available worksheets in a workbook, find a specific worksheet by name, or understand the workbook structure before performing operations on worksheet data.

ActionTry it

Move Item

Tool to move a file or folder to a new parent folder in OneDrive. Use when you need to reorganize your files or folders by changing their location. You can optionally rename the item during the move. If a file with the same name exists at the destination, the API returns `nameAlreadyExists`; use the `name` parameter to provide a unique name or resolve the conflict beforehand.

ActionTry it

Permanently Delete Drive Item

Tool to permanently delete a driveItem by its ID without moving it to the recycle bin. Use when you need to irreversibly remove a file or folder from OneDrive or SharePoint. This action cannot be undone.

ActionTry it

Preview Drive Item

Generates or retrieves a short-lived, permission-bound embeddable URL for a preview of a specific item. URLs expire and must be regenerated per session — do not cache. Use when you need to display a temporary preview of a file.

ActionTry it

Read Workbook Range

Reads a range of cells from an Excel workbook worksheet stored in OneDrive or SharePoint using Microsoft Graph API. Returns cell values, formulas, formatting, and metadata for the specified range. Use this action when you need to extract data from specific cells in an Excel file, whether reading a single cell, a rectangular range, an entire column, or an entire row. The range address must be specified in A1 notation (e.g., 'A1:B5').

ActionTry it

Restore Deleted Item

Tool to restore a deleted OneDrive driveItem (file or folder) from the recycle bin. Use when you need to recover a deleted item to its original location or to a specified parent folder, optionally renaming it during restoration. IMPORTANT LIMITATION: This API is ONLY available for OneDrive Personal accounts. It does NOT work with OneDrive for Business or SharePoint. For Business/SharePoint accounts, use the SharePoint REST API endpoints (/_api/web/recyclebin) instead.

ActionTry it

Restore Item Version

Restores a previous version of a DriveItem (file) by creating a new version with the content of the specified version. Use this action when you need to revert a file to an earlier version. The restoration is permanent and creates a new current version — the file cannot be automatically reverted after this operation, though you can restore again to a different version if needed. This action is irreversible in the sense that it immediately changes the current file content.

ActionTry it

Search Drive Items

Search OneDrive and accessible SharePoint files with Microsoft Graph Search. This does not produce a complete shared-with-me list; use deprecated ONE_DRIVE_GET_SHARED_ITEMS only when full shared-with-me enumeration is required before Microsoft removes that API in November 2026. Requires OneDrive permissions plus Sites.Read.All because SharePoint-backed files can appear in results.

ActionTry it

Search Items

Search OneDrive for files and folders by keyword. Searches filenames, metadata, and file content to find matching items. Use when you need to find specific files based on keywords, file types, or content. Supports filtering, sorting, and pagination. Results are mixed files and folders — filter client-side using file vs folder properties. Disambiguate similarly named items using parentReference.path, lastModifiedDateTime, and size before passing item IDs downstream. Newly created or recently moved files may not appear due to indexing delays; fall back to ONE_DRIVE_LIST_FOLDER_CHILDREN if expected items are missing. No server-side date filtering — apply lastModifiedDateTime/createdDateTime filtering in your own logic. HTTP 429 responses include a Retry-After header; use exponential backoff.

ActionTry it

Update Drive Item Metadata

Tool to update the metadata of a specific item (file or folder) in OneDrive. Use this to rename items, change descriptions, or move items to a new parent folder.

ActionTry it

Update Drive Item Permissions

Tool to update the roles of an existing permission on a OneDrive drive item. Use when you need to change the access level (read, write, owner) for a specific permission on a file or folder.

ActionTry it

Update File Content

Tool to update an existing file's content in OneDrive. When called without a `file` parameter, creates an upload session and returns its uploadUrl (legacy behavior — caller drives the PUT uploads). When called with a `file` (FileUploadable), the action streams the file's bytes in chunks via the upload session and returns the final updated DriveItem. The item's ID is preserved (existing share links remain valid) unless conflict_behavior=rename causes the server to create a new item.

ActionTry it

Update SharePoint Item Permission

Update an application permission on a SharePoint list or list item using Microsoft Graph beta.

ActionTry it

Update SharePoint List Item Fields

Update field values on a SharePoint list item using Microsoft Graph through the OneDrive connection. Use when you need to modify one or more columns on an existing SharePoint list item.

ActionTry it

Update Workbook Range

Updates a range in a workbook worksheet using Microsoft Graph API. Use this action when you need to write data, formulas, or number formats to specific cells in an Excel workbook stored in OneDrive or SharePoint. The address parameter supports various formats including single cells, cell ranges, entire columns, or entire rows.

ActionTry it

Update Workbook Worksheet

Updates properties of a worksheet in an Excel workbook stored in OneDrive. Use this action when you need to rename a worksheet, change its position (tab order), or modify its visibility state. At least one of name, position, or visibility must be provided in the request. The worksheet is identified by its ID or display name within the specified workbook.

ActionTry it

Upload file

Uploads a file to a specified OneDrive folder, automatically creating the destination folder if it doesn't exist, renaming on conflict, and supporting large files via chunking.

ActionTry it

Write Workbook Cell

Updates the value, formula, or format of a specific cell in an Excel workbook stored in OneDrive. Use this action when you need to write data to a single cell at a specific row and column position. The row and column parameters are 0-indexed (row 0 is the first row, column 0 is column A).

ActionTry it