Skip to main content
Glama
Microsoft 365 MCP Server

Microsoft 365 MCP Server

by Softeria

delete-mail-message-skip-deleted-items

delete-mail-message-skip-deleted-items
Destructive

Delete an Outlook email by ID without moving it to Deleted Items: it goes to Recoverable Items, hidden from mailbox and restorable until retention ends; also removes messages from Deleted Items.

Instructions

Delete an Outlook email message by its message ID without moving it to Deleted Items, the way Shift+Delete in Outlook does: the message goes to Recoverable Items, is no longer shown in the mailbox, and the user can only restore it with Recover Deleted Items until the retention period ends. Also removes a message from Deleted Items. For an ordinary delete, use delete-mail-message.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "messageId": "<messageId>"
    },
    "name": "delete-mail-message-skip-deleted-items"
  }
}

Input Schema

NameRequiredDescriptionDefault
confirmNoFor destructive operations when the confirm gate is enabled (MS365_MCP_REQUIRE_CONFIRM=true; off by default). Set to true only after the user has explicitly approved this action. When the gate is on, calls without confirm: true return { error: "confirmation_required" } without touching user data.
If-MatchNoETag
messageIdYesValue for the 'messageId' path segment. Pass it under the name 'messageId', not as 'id'. Use the 'id' field of the message object as returned by Microsoft Graph.
includeHeadersNoInclude response headers (including ETag) in the response metadata
excludeResponseNoExclude the full response body and only return success or failure indication

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.181.0

TDQS

A4.4/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare destructiveHint=true and openWorldHint=true, but the description adds substantive consequence detail beyond that: the item lands in Recoverable Items, disappears from the mailbox, and can only be restored via Recover Deleted Items until retention expires. It stops short of stating permission requirements or that the confirm gate may block the call, which the schema covers instead.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loads the action and its key differentiator, then explains the consequence, then the fallback sibling. Three compact clauses with no filler; the Shift+Delete comparison compresses a lot of behavior into a few words.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a destructive 5-parameter tool with no output schema, the description covers intent, consequence, and alternative well. It leaves out only operational side notes such as permission scope or behavior on invalid IDs, which are minor given the rich annotations and fully described schema.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so every parameter (confirm, If-Match, messageId, includeHeaders, excludeResponse) is already documented in detail. The description only passes along that the ID is a 'message ID', adding no format, ETag-concurrency, or response-shaping guidance beyond the schema, so baseline 3 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Names a specific verb and resource ('Delete an Outlook email message by its message ID') plus the defining scope: bypassing Deleted Items. The Shift+Delete analogy and the secondary case ('Also removes a message from Deleted Items') make the operation unmistakable and distinct from delete-mail-message.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly routes the agent: 'For an ordinary delete, use delete-mail-message.' That names the alternative sibling and the condition that selects it, and the description also implies when this variant is appropriate (permanent removal, or purging an already-deleted item).

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools