Get Content
m365_get_contentRetrieve the content of OneDrive files, email attachments, or contacts: save files to local disk, get temporary download links, or export contacts as vCards.
Instructions
Get the content of an item rather than its details: save a OneDrive file or an email attachment to a local file (mode='download'), get a temporary download link for a OneDrive file (mode='download_url'), or export a contact as a vCard (mode='vcard'). Writes to the local disk only inside the allowed folders. Use m365_get for item details.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | OneDrive item ID, email ID or contact ID. | |
| mode | Yes | download: drive_item file or email attachment to save_path. download_url: drive_item file only. vcard: contact only. | |
| resource | Yes | Type of item. | |
| overwrite | No | Replace save_path if it already exists. | |
| save_path | No | Local file path inside the server's allowed folders. Hidden and secret files are refused. | |
| account_id | No | Account ID or email address. Omit when only one account is signed in. | |
| attachment_id | No | email + download only: attachment ID from m365_get(resource='email'). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | ||
| mode | Yes | ||
| size | Yes | ||
| vcard | 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. | |
| resource | Yes | ||
| mime_type | Yes | ||
| saved_path | Yes | ||
| download_url | Yes |