Skip to main content
Glama
M365 Assistant MCP Server

M365 Assistant MCP Server

by ryaker

read-email

Reads a specific Microsoft 365 email and extracts only visible text from HTML to block hidden prompt-injection content.

Instructions

Reads the content of a specific email. HTML emails are securely sanitized to extract only visible text, preventing prompt injection attacks via hidden content.

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": {
      "id": "<id>"
    },
    "name": "read-email"
  }
}

Input Schema

NameRequiredDescriptionDefault
idYesID of the email to read
includeRawHtmlNoInclude raw HTML content (UNSAFE - for debugging only, may contain hidden prompt injection content)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.0.0

TDQS

A3.7/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does disclose meaningful behavior: HTML is sanitized to visible text and hidden content is stripped as an anti-prompt-injection measure. It does not state whether reading marks the message as read (a real side-effect given the mark-as-read sibling) or what authentication is required.

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?

Two tight sentences with the core action first and the safety-relevant sanitization note second. Every clause earns its place and nothing is redundant.

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

Completeness3/5

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

There is no output schema, so the description should indicate what 'content' includes (subject, sender, recipients, body, attachments). It also omits the side-effect and auth context an agent needs before calling a read operation on mail.

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 coverage is 100%, so both parameters, including the UNSAFE warning on includeRawHtml, are already documented in the schema. The description adds no format or constraint detail beyond what the schema provides, so the baseline of 3 applies.

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

Purpose4/5

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

States a specific verb and resource: 'Reads the content of a specific email,' which contrasts implicitly with the sibling list-emails by scoping to one message. It does not name the alternative explicitly, but the single-email scope is unambiguous.

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

Usage Guidelines3/5

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

Usage is only implied: an agent infers it should call this after obtaining an ID (presumably from list-emails), but no when-to-use or when-not-to-use guidance is given. There is no mention of prerequisites such as needing an ID from a listing tool.

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