Skip to main content
Glama

get_channel_messages

Retrieve the newest messages from a channel, group, or direct message. Paginate through history using count and offset parameters.

Instructions

Get messages from a channel, group or DM (newest first).

Args:
    room_id: Room ID or room name of the channel/group/DM
    count: Number of messages to retrieve (default: 20, max: 100)
    offset: Skip this many newest messages — use to page back through history
            instead of re-reading with a larger count (e.g. offset=20 to get
            the 20 messages older than the first page)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
room_idYes
countNo
offsetNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

With no annotations, description adds behavioral details: 'newest first' ordering, offset for paging, default and max count. Could mention authentication or error handling, but covers key behavior.

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?

Description is well-structured with Args section and examples. Slightly verbose in offset explanation, but every sentence adds value. Acceptable length.

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?

Given output schema exists, description explains input completely: required room_id, optional count/offset with defaults. Paging mechanics are covered. No missing context for typical usage.

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

Parameters5/5

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

Schema coverage is 0%, so description adds essential meaning: room_id accepts 'room name', count has default/max, offset described with paging example. Greatly enhances parameter understanding.

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?

Description clearly states 'Get messages from a channel, group or DM (newest first)'. It specifies the verb, resource, and ordering, distinguishing it from siblings like search_messages or send_message_in_channel.

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?

The description explains paging with count and offset, including an example. It doesn't explicitly state when not to use (e.g., for searching), but the context and sibling list imply it. Clear for basic use.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/millerchou/rocketchat-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server