Skip to main content
Glama
Discord Self MCP

Discord Self MCP

by Maol-1997

search_messages

Search Discord channel messages by content, author ID, or date range to locate specific conversations, with optional message ID boundaries and result limits.

Instructions

Search for messages in a Discord channel by content, author, or date range

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": {
      "channelId": "<channelId>"
    },
    "name": "search_messages"
  }
}

Input Schema

NameRequiredDescriptionDefault
afterNoOptional: Search messages after this message ID
limitNoNumber of messages to search through (default: 100, max: 500)
queryNoText to search for in message content
beforeNoOptional: Search messages before this message ID
authorIdNoOptional: Filter by author ID
channelIdYesThe Discord channel ID to search messages in

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.2

TDQS

B3.2/5.0
Behavior2/5

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

No annotations exist, so the description carries the full behavioral burden and largely fails it: nothing about required permissions, whether search is confined to the named channel or the whole guild, result ordering, or how the limit/before/after parameters interact. The single sentence only restates the purpose.

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?

One front-loaded sentence with zero filler; the purpose and filter dimensions are readable at a glance. It is terse to the point of under-specification, but nothing is wasted.

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?

For a six-parameter search tool with no annotations and no output schema, the description is adequate but thin: it says what is searched yet omits result shape, ordering, and default behavior when no query is given. The fully documented schema compensates for most parameter gaps.

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. The description's 'by content, author, or date range' maps filters to query/authorId/before-after, adding some orientation, but it calls before/after a 'date range' when they actually take message IDs — a mild mismatch the schema corrects.

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 ('Search') plus the resource ('messages in a Discord channel') and enumerates the filter dimensions (content, author, date range). An agent can tell it apart from send_message or list_channels, though the boundary with read_channel is never drawn.

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 implied by the verb 'search' — the agent infers this is for targeted lookup rather than sequential reading. However, the description never states when to prefer it over read_channel or what to do when no filters are supplied (which would make it just a channel dump).

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