Skip to main content
Glama

Get Direct Messages

get_direct_messages
Read-onlyIdempotent

Retrieve direct message history with a specific Mattermost user, newest first, and filter by timestamp, limit results, or page backward through older messages.

Instructions

Get direct message history with a specific user, newest first.

Input Schema

NameRequiredDescriptionDefault
limitNoMaximum number of messages to return. Default: 30.
sinceNoISO 8601 datetime — only return messages after this timestamp.
beforeNoA post ID — return messages older than it, to page back through history.
usernameYesThe Mattermost username (without @).

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv1.0.0
    • addedInput schema / properties / before
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "A post ID — return messages older than it, to page back through history."
      +}
  2. First observedv0.2.0

TDQS

A3.5/5.0
Behavior3/5

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

Annotations already establish readOnlyHint, idempotentHint, and openWorldHint, so the safety profile is covered. The description adds one genuine behavioral trait — results are returned newest first — but says nothing about pagination behavior, result caps, or permission requirements for reading another user's DMs.

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?

A single front-loaded sentence with zero filler, and the ordering guarantee is placed where it matters. It is efficient but so terse that it leaves obvious gaps unaddressed.

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?

An output schema exists, so return values need not be explained, and annotations cover the safety profile; schema coverage is complete. What is missing is minor context such as whether group conversations are included and how to page back through history in practice.

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?

With 100% schema description coverage, every parameter already carries its own documentation, including the default limit of 30 and the ISO 8601 format for since. The description adds no parameter-level meaning beyond the implicit ordering caveat, so the baseline 3 applies.

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?

The description states a specific verb and resource (get direct message history) and narrows scope to a specific user, which separates it from channel-oriented siblings like get_channel_posts or get_thread. It stops short of naming an alternative tool explicitly, so differentiation has to be inferred from the sibling list.

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 only implied: needing a username suggests a one-to-one conversation, but the description never says when to prefer this over get_channel_posts, get_mentions, or search_posts, and gives no exclusions or prerequisites.

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