One Drive

Learn how to use One Drive with Composio

Overview

SLUG

ONE_DRIVE

Description

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

Authentication Details

client_id
stringRequired
client_secret
stringRequired
oauth_redirect_uri
stringDefaults to https://backend.composio.dev/api/v1/auth-apps/add
scopes
stringDefaults to Files.ReadWrite.All,Sites.Read.All,offline_access
bearer_token
string

Tools

SLUG: ONE_DRIVE_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.

Action Parameters

@microsoft.graph.conflictBehavior
stringDefaults to fail
children_only
boolean
drive_id
string
group_id
string
include_all_version_history
boolean
item_id
stringRequired
name
string
parent_reference
object
site_id
string
user_id
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: ONE_DRIVE_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.

Action Parameters

if_match
string
item_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: ONE_DRIVE_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.

Action Parameters

drive_id
stringRequired
select_fields
array

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: ONE_DRIVE_GET_ITEM

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.

Action Parameters

drive_id
string
expand_relations
array
item_id
stringRequired
select_fields
array

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: ONE_DRIVE_GET_ITEM_PERMISSIONS

Retrieves the permissions of a driveitem by its unique id or path 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.

Action Parameters

drive_id
string
group_id
string
item_id
stringRequired
item_path
string
select
string
site_id
string
user_id
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: ONE_DRIVE_GET_ITEM_THUMBNAILS

Tool to retrieve the thumbnails associated with a driveitem. use when you need to display visual previews of files.

Action Parameters

drive_id
string
group_id
string
item_id
stringRequired
original_orientation
boolean
select
string
site_id
string
user_id
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: ONE_DRIVE_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.

Action Parameters

drive_id
string
group_id
string
item_id
stringRequired
site_id
string
user_id
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: ONE_DRIVE_GET_QUOTA

Tool to retrieve the quota information for the authenticated user's onedrive. use this action to check the storage space details like total, used, and remaining space on the user's onedrive.

Action Parameters

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: ONE_DRIVE_GET_RECENT_ITEMS

Retrieves a list of items that have been recently used by the authenticated user. this tool is useful when you need to access or display files and folders that the user has interacted with recently across their onedrive and accessible shared drives.

Action Parameters

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: ONE_DRIVE_GET_SHARED_ITEMS

Tool to retrieve a list of items that have been shared with the authenticated user. use this action to get details of files and folders shared with the current user.

Action Parameters

allow_external
boolean

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: ONE_DRIVE_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.

Action Parameters

expand
string
filter
string
list_id
stringRequired
select
string
site_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: ONE_DRIVE_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.

Action Parameters

site_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: ONE_DRIVE_GET_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.

Action Parameters

expand
string
page_id
stringRequired
site_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: ONE_DRIVE_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).

Action Parameters

drive_id
string
expiration_date_time
string
group_id
string
item_id
stringRequired
message
string
password
string
recipients
arrayRequired
require_sign_in
boolean
retain_inherited_permissions
booleanDefaults to True
roles
arrayRequired
send_invitation
boolean
site_id
string
user_id
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: ONE_DRIVE_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.

Action Parameters

expand
string
group_id
string
orderby
string
select
string
site_id
string
skip_token
string
top
integer
user_id
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: ONE_DRIVE_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.

Action Parameters

$filter
string
$orderby
string
$skip
integer
$top
integer
drive_id
stringRequired
item_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: ONE_DRIVE_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.

Action Parameters

token
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: ONE_DRIVE_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.

Action Parameters

expand
string
list_id
stringRequired
select
string
site_id
stringRequired
token
string
top
integer

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: ONE_DRIVE_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.

Action Parameters

expand
string
filter
string
orderby
string
select
string
site_id
stringRequired
skip
integer
top
integer

Action Response

data
objectRequired
error
string
successful
booleanRequired