Skip to main content
Glama

独行录 / opcmenu

读会话消息

read_messages
Read-only

登录/会话成员;默认最近倒序、nextBefore前翻;after=messageId增量正序,可轮询。

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": {
      "conversationId": "<conversationId>"
    },
    "name": "read_messages"
  }
}

Input Schema

NameRequiredDescriptionDefault
afterNo增量:取该 messageId 之后更新的消息
limitNo返回条数,默认 30
beforeNo向前翻页:取该 messageId 之前更老的消息
conversationIdYes会话 id

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / limit / description
      Previous value: -"返回条数,默认 30"New value: +"返回条数,默认 30"
  2. First observed

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, so the safety profile is covered. The description adds meaningful context beyond that: default descending ordering, the direction each paging cursor moves, and the fact that after-based reads are safe to poll. It does not describe return shape or pagination limits, and the precondition wording ('登录/会话成员') is too terse to tell an agent exactly what auth/membership state 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.

Conciseness4/5

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

It is a single dense sentence with no filler, and the default-ordering behavior is front-loaded. The telegraphic semicolon-separated style and the incorrect 'nextBefore' token cost it some clarity, but nothing is redundant.

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 simple read-only, 4-parameter tool with full schema descriptions and no output schema, the description covers the essentials: auth precondition, ordering, both paging directions, and pollability. The main gap is that return contents are never characterized despite there being no output schema to fall back on.

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 the baseline is 3 and the schema already documents after/before/limit/conversationId. The description contributes ordering semantics the schema lacks (ascending for after, descending by default), but it also references 'nextBefore', a parameter that does not exist in the schema (the actual field is 'before'), which risks misleading an agent.

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

Purpose3/5

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

The description never states a clean verb+resource; the opening fragment '登录/会话成员' is an auth/membership precondition rather than a purpose statement, and the tool's actual job (reading messages in a conversation) is only inferable from the parameter semantics. It is distinguishable from siblings like export_live_messages by its paging/polling semantics, but that distinction is implied rather than stated.

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

Usage Guidelines4/5

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

It gives concrete mode selection: default = most-recent-first, use before to page backwards, use after with a messageId for ascending incremental reads that can be polled. That is real when-to-use guidance per parameter mode. It stops short of naming alternatives or exclusions (e.g., when to prefer export_live_messages), so it is not a 5.

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