Upload File
drive_uploadUpload a local file to OneDrive as a new item or replace an existing file's contents, returning the OneDrive item.
Instructions
Upload a local file to OneDrive, as a new file (parent_id or parent_path) or by replacing an existing file's contents (item_id). Reads from the local disk, inside the allowed folders only. Returns the OneDrive item.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | New file: name in OneDrive (default: local file name). | |
| item_id | No | Replace the contents of this existing file. | |
| if_exists | No | New file: what to do if the name is taken. | fail |
| parent_id | No | New file: destination folder ID ('root' allowed). | |
| account_id | No | Account ID or email address. Omit when only one account is signed in. | |
| local_path | Yes | Local file path inside the server's allowed folders. Hidden and secret files are refused. | |
| parent_path | No | New file: destination folder path, e.g. /Documents. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| item | Yes | ||
| status | Yes | ||
| summary | Yes | One-line human summary. The tool's text content is this result serialized as JSON (summary included), so a client that ignores structuredContent still sees every field. |