Skip to main content
Glama

ingest_message

Destructive

Ingest one incoming message from an external channel (Beeper network, desktop mail, …) forwarded by the local comms-forward bridge. Idempotent on (channel, external_id). Stores the message and, unless auto_draft is false, generates an AI reply DRAFT (never auto-sends) — EXCEPT when a background agent of this tenant picks up new incoming items itself (run condition inbound_messages.neu / emails.unsortiert): then that agent drafts the reply for approval and no draft is made here. Returns { ingested, message_id, draft_id, auto_draft: 'created'|'skipped_agent_handles'|'disabled'|'empty'|'failed'|'skipped_duplicate', handled_by_agent? }.

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": {
      "channel": "<channel>",
      "external_id": "<external_id>",
      "body": "<body>"
    },
    "name": "ingest_message"
  }
}

Input Schema

NameRequiredDescriptionDefault
bodyYesBody text
senderNoSender handle or ID at the source channel
channelYesSource class, e.g. 'beeper' or 'mail'
chat_idNoID of the chat
subjectNoSubject line
agent_idNoDrafting agent; defaults to the tenant's first enabled agent
metadataNoAdditional source data stored with the message (free-form object)
chat_nameNoDisplay name of the chat or conversation
auto_draftNoDraft a reply (default true)
external_idYesStable per-channel de-dupe id
received_atNoISO-8601 timestamp
sender_nameNoSender display name

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed7 schema fields changed
    • addedInput schema / properties / body / description
      Added value: +"Body text"
    • addedInput schema / properties / chat_id / description
      Added value: +"ID of the chat"
    • addedInput schema / properties / chat_name / description
      Added value: +"Display name of the chat or conversation"
    • addedInput schema / properties / metadata / description
      Added value: +"Additional source data stored with the message (free-form object)"
    • addedInput schema / properties / sender / description
      Added value: +"Sender handle or ID at the source channel"
    • addedInput schema / properties / sender_name / description
      Added value: +"Sender display name"
    • addedInput schema / properties / subject / description
      Added value: +"Subject line"
  2. First observed

TDQS

A3.5/5.0
Behavior2/5

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

Beyond the annotations the description adds genuinely useful behaviour: it never auto-sends, it only drafts, it lists the exact auto_draft outcome states, and it discloses the agent-handles-it exception. However, it asserts 'Idempotent on (channel, external_id)' while the annotations declare idempotentHint=false, and it presents a write that 'stores the message' without reconciling that with destructiveHint=true, so a caller cannot tell which side to trust on repeat calls.

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?

Everything is front-loaded: what it ingests, its idempotency key, then the drafting rule, then the return shape. It is dense with parentheticals and embedded conditionals, but each clause carries distinct information and none is padding.

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?

With 12 parameters, no output schema, and no sibling guidance elsewhere, this description still supplies the return object shape, all auto_draft terminal states, the skip-on-duplicate outcome, and the background-agent exception. An agent has enough to call it and interpret the response without further documentation.

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 a 3 is the baseline, but the description goes beyond it by naming (channel, external_id) as the de-dupe key and by explaining how auto_draft changes behaviour and which return values it produces. That maps parameters to effects rather than just restating field descriptions.

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 gives a specific verb and resource ('Ingest one incoming message from an external channel ... forwarded by the local comms-forward bridge') and pins the scope to a single message, so the agent knows exactly what the call does. It does not, however, distinguish itself from overlapping siblings such as ingest_email or ingest_whatsapp_lead, so an agent facing a mail or WhatsApp payload gets no explicit routing signal here.

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 rather than stated: the tool is for items arriving via the comms-forward bridge, and the auto_draft paragraph explains one branch of behaviour. There is no explicit when-to-use/when-not guidance relative to the channel-specific ingest siblings, and no stated prerequisites for calling it.

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.