Skip to main content
Glama

Connect Microsoft 365 Account

connect_m365_account
Destructive

Connect a Microsoft 365 account (or add another one, or sign one in again). Call again after you've authenticated at microsoft.com/devicelogin to finish the connection. Pass include_channel_messages: true to also read Teams channel messages and search them — that permission needs an administrator of your Microsoft 365 organization; without that approval the sign-in is refused and the account keeps its current access.

Input Schema

NameRequiredDescriptionDefault
confirmNoIgnored; kept for older clients.
account_typeNo"work" (default): a work or school Microsoft 365 account — mail, calendar, contacts, Teams. "personal": an Outlook.com / Hotmail / Live account — mail, calendar and contacts only (Microsoft has no Teams chats or directory for personal accounts, and asking for them makes Microsoft refuse the sign-in as an 'expired code'). Ask the person which one it is when unsure.
include_channel_messagesNoAlso request access to Teams channel messages and message search. Needs an administrator of the Microsoft 365 organization; without that approval this sign-in is refused and the account keeps its current access.

Output Schema

NameRequiredDescriptionDefault
okNo
messageNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / confirm / description
      Previous value: -"Must be true to start the sign-in. Without it the call returns a preview and does nothing."New value: +"Ignored; kept for older clients."
  2. Changed1 schema field changed
    • addedInput schema / properties / confirm
      Added value: +{
      +  "description": "Must be true to start the sign-in. Without it the call returns a preview and does nothing.",
      +  "type": "boolean"
      +}
  3. Changed1 schema field changed
    • addedInput schema / properties / account_type
      Added value: +{
      +  "description": "\"work\" (default): a work or school Microsoft 365 account — mail, calendar, contacts, Teams. \"personal\": an Outlook.com / Hotmail / Live account — mail, calendar and contacts only (Microsoft has no Teams chats or directory for personal accounts, and asking for them makes Microsoft refuse the sign-in as an 'expired code'). Ask the person which one it is when unsure.",
      +  "enum": [
      +    "work",
      +    "personal"
      +  ],
      +  "type": "string"
      +}
  4. Changed1 schema field changed
    • addedInput schema / properties / include_channel_messages
      Added value: +{
      +  "description": "Also request access to Teams channel messages and message search. Needs an administrator of the Microsoft 365 organization; without that approval this sign-in is refused and the account keeps its current access.",
      +  "type": "boolean"
      +}
  5. First observed

TDQS

A4.6/5.0
Behavior4/5

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

While annotations cover the destructive nature, the description adds crucial behavioral context: it states that `include_channel_messages` requires admin approval, and specifies the failure mode—the sign-in is refused and the account retains current access. This is vital process knowledge.

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

Conciseness4/5

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

The description is highly efficient. It front-loads the core function, then immediately addresses the complex operational flow (external login), and finally details the permission constraints in a single, cohesive block of text.

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

Completeness5/5

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

The description is highly complete. It covers the overall goal, the necessary external authentication sequence, and the specific behavioral rules around administrative permissions and potential sign-in failure.

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

Parameters4/5

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

The schema coverage is 100%, which is a strong baseline. The description elevates this by providing operational semantics—specifically explaining the consequence and prerequisite (admin approval) of the `include_channel_messages` boolean parameter.

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?

The description provides a perfect functional overview: it defines the action (Connect/Add/Sign In) and the resource (Microsoft 365 account). It clearly distinguishes this tool from related list or delete functions by focusing on the connection setup process.

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?

It provides a critical procedural guideline by explicitly telling the agent that the tool call must be made after a specific external step (authentication at microsoft.com/devicelogin), which defines the necessary workflow.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources