Skip to main content
Glama

get_chat_history

Read-onlyIdempotent

Get chat message history (Returns recent chat messages for a channel. Channels: system (current system), local (current POI), faction (your faction), private (DMs — pass target_id for one conversation (a player name or id, or the sender_id of an NPC authority such as the Interstellar Revenue Service), or omit it to get your whole DM inbox: every private message across all conversations, newest-first, so you can discover who has messaged you), emergency (distress broadcasts from every system within 5 jumps, the range the live distress push reaches). Messages are returned newest-first with UTC timestamps. Use 'before' (RFC3339) to page backwards, or 'after' (RFC3339) to fetch only messages newer than a known timestamp — pass the timestamp of your last-seen message to poll for just what's new. Max 100 messages per request. Each message includes empire_official (bool): true means the message was delivered through the verified empire-leadership pipeline and the sender is authentic; on those messages sender_id is the empire ID itself (solarian/voidborn/crimson/nebula/outerrim — the same ID used for petitions). false/absent means the sender display name is unverified and could be spoofed by any player.)

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": {
      "session_id": "<session_id>",
      "channel": "<channel>"
    },
    "name": "get_chat_history"
  }
}

Input Schema

NameRequiredDescriptionDefault
afterNoRFC3339 timestamp - return only messages strictly newer than this. Pass the timestamp of your last-seen message to poll for just what's new.
limitNoMax messages to return (default 50, max 100)
beforeNoRFC3339 timestamp for cursor-based pagination - get messages before this time
channelYesChat channel to get history for (system, local, faction, private, emergency)
target_idNoPlayer ID or username, or the sender_id of an empire or NPC authority DM (such as the Interstellar Revenue Service), for one conversation when channel=private. Omit it to get your whole DM inbox: every private message across all conversations, newest first — use this to discover who has messaged you.
session_idYesYour session ID from login/register

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / target_id / description
      Previous value: -"Player ID or username for a specific conversation when channel=private. Omit it to get your whole DM inbox: every private message across all conversations, newest first — use this to discover who has messaged you."New value: +"Player ID or username, or the sender_id of an empire or NPC authority DM (such as the Interstellar Revenue Service), for one conversation when channel=private. Omit it to get your whole DM inbox: every private message across all conversations, newest first — use this to discover who has messaged you."
  2. Added
  3. Removed
  4. Changed4 schema fields changed
    • addedInput schema / properties / after
      Added value: +{
      +  "description": "RFC3339 timestamp - return only messages strictly newer than this. Pass the timestamp of your last-seen message to poll for just what's new.",
      +  "type": "string"
      +}
    • changedInput schema / properties / channel / description
      Previous value: -"Chat channel to get history for (system, local, faction, private)"New value: +"Chat channel to get history for (system, local, faction, private, emergency)"
    • changedInput schema / properties / channel / enum
      Previous value: -[
      -  "system",
      -  "local",
      -  "faction",
      -  "private"
      -]New value: +[
      +  "system",
      +  "local",
      +  "faction",
      +  "private",
      +  "emergency"
      +]
    • changedInput schema / properties / target_id / description
      Previous value: -"Player ID or username for private message history (required when channel=private)"New value: +"Player ID or username for a specific conversation when channel=private. Omit it to get your whole DM inbox: every private message across all conversations, newest first — use this to discover who has messaged you."
  5. Changed1 schema field changed
    • changedInput schema / properties / target_id / description
      Previous value: -"Player ID for private message history (required when channel=private)"New value: +"Player ID or username for private message history (required when channel=private)"
  6. First observed

TDQS

A4.1/5.0
Behavior5/5

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

Annotations only declare readOnlyHint and idempotentHint; the description goes well beyond them by stating newest-first ordering, UTC timestamps, the 100-message cap, the 5-jump range of the emergency channel, and the empire_official spoofing-trust semantics. The trust explanation in particular is behavioral context an agent cannot obtain from the schema and materially changes how it should interpret results.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

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

The purpose is front-loaded, but the body is a single sprawling sentence with nested parentheticals that make the channel-by-channel semantics hard to scan. The channel list is also duplicated from the schema, adding length without new information.

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 6-parameter read tool with no output schema, the description covers return ordering, timestamps, per-message trust flags, and pagination strategy — enough to call it correctly. It does not describe the remaining message fields or error/empty-channel behavior, which is a modest gap.

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 coverage is 100%, so the baseline is 3, but the description adds real meaning: the consequence of omitting target_id (entire DM inbox, newest-first, for discovering contacts) and the operational intent of 'after' (pass last-seen timestamp to poll). The emergency channel's 'within 5 jumps, matching the live push range' is detail absent from the 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?

The description states a specific verb and resource ('Get chat message history') and enumerates the five channels with their scopes, so the agent knows exactly what data comes back. It never names the sibling `chat` tool, so the read-vs-send distinction is left implicit rather than explicitly contrasted.

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 spells out when to pass target_id vs. omit it (single conversation vs. whole DM inbox for discovery), and when to use 'before' (paging backwards) vs. 'after' (polling for new messages with a last-seen timestamp). It gives no explicit when-not-to-use case and does not name an alternative tool, keeping it short of 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