Skip to main content
Glama

graph_get_channel_messages

Retrieve messages from a Microsoft Teams channel, including full HTML bodies, attachments, and mentions. Use compact fields and next-link paging to browse large collections efficiently.

Instructions

Get messages from a channel.

Messages carry full HTML bodies plus their attachments and mentions, so compact narrows them to the identifying fields. Without it no $select is sent and the response is unchanged.

Args: team_id: The team ID (from graph_list_teams). channel_id: The channel ID (from graph_list_channels). top: Maximum number of messages to return (default 50, maximum 50). compact: Whether to return only the identifying fields instead of the full record (default false). Use it to page through large collections cheaply. next_link: Opaque nextLink URL from a previous call, used to fetch the next page. Overrides the other paging arguments when supplied. include_next_link: Whether to wrap the result as {items, next_link} so paging can continue (default false, which returns a bare list).

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": {
      "team_id": "<team_id>",
      "channel_id": "<channel_id>"
    },
    "name": "graph_get_channel_messages"
  }
}

Input Schema

NameRequiredDescriptionDefault
topNo
compactNo
team_idYes
next_linkNo
channel_idYes
include_next_linkNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.10.0

TDQS

A3.9/5.0
Behavior4/5

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

With no annotations, the description carries the behavioral burden and discloses important details: messages carry full HTML bodies plus attachments and mentions, `compact` narrows the record, no `$select` is sent without it, and `include_next_link` changes the return shape from a bare list to `{items, next_link}`. It also explains that `next_link` overrides other paging arguments. It does not mention permissions, rate limits, or ordering, so it is strong but not exhaustive.

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?

The description is front-loaded with the core purpose and then uses a clear Args list for the six parameters. Each sentence adds useful operational detail without repetition or filler.

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 six-parameter read tool with no annotations and no output schema, the description covers paging, compact mode, response shape, and parameter sources well enough for an agent to call it correctly. The missing explicit alternative routing and the `top` maximum inconsistency keep it from being fully complete.

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?

Schema description coverage is 0%, so the description must document all six parameters, and it does: it gives ID provenance for `team_id` and `channel_id`, default/limit behavior for `top`, default and purpose for `compact`, the opaque paging URL for `next_link`, and the wrapping behavior for `include_next_link`. One issue is that its stated maximum of 50 for `top` conflicts with the schema's much larger maximum, which could mislead an agent, but overall it adds substantial meaning beyond the bare schema.

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: 'Get messages from a channel.' The word 'channel' separates it from chat message and reply retrieval tools, but it does not explicitly name or contrast sibling alternatives, so it is clear but not fully differentiated.

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?

Gives useful usage notes for `compact` and paging, such as using `compact` to page through large collections cheaply and `next_link` to continue paging. However, it does not state when to use this tool instead of `graph_get_chat_messages`, `graph_get_channel_message_replies`, or `graph_search_messages`, and gives no when-not guidance.

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