Skip to main content
Glama
Cloady

Cloady

Official
by Cloady

Read Service Mail

readServiceMail
Read-only

Reads a service's mail delivery logs and queue to surface send outcomes, delivery times, rejections, bounces, and queue state so you can diagnose email delivery issues.

Instructions

Reads a Postfix service's delivery log and queue: outbound attempts by outcome per step, time to delivery, inbound rejections and authentication failures, outcomes by recipient domain, bounce reasons with addresses masked, the queue's size by state and the retry settings. Postfix must log to standard output (maillog_file = /dev/stdout). Stalwart is read from its own Prometheus exporter and JMAP API once its admin turns the exporter on and the app holds an API key as the variable STALWART_API_KEY (and the exporter's login, if it has one, as STALWART_METRICS_AUTH, written user:secret); Mailpit and MailHog report what they caught. Nothing is invented for a server Monitor cannot read.

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": {
      "workspaceSlug": "<workspaceSlug>",
      "appSlug": "<appSlug>",
      "serviceName": "<serviceName>"
    },
    "name": "readServiceMail"
  }
}

Input Schema

NameRequiredDescriptionDefault
envNo
rangeNoHow far back to look; the answer has 30 to 96 points across it1h
regionNo
appSlugYes
serviceNameYes
workspaceSlugYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.18.0

TDQS

A3.7/5.0
Behavior5/5

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

Well beyond the readOnlyHint/openWorldHint annotations, the description discloses the underlying data sources per mail server, the configuration each source requires before it is readable, and the degradation contract ('Nothing is invented for a server Monitor cannot read'). That last clause is exactly the kind of empty-result warning an agent needs before interpreting output.

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?

Front-loaded with the purpose and the data returned before any prerequisites, so a skimming agent gets the core. The enumerations are dense but each item conveys distinct returned data; the Stalwart environment-variable parenthetical is the one place wording becomes heavier than needed.

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?

With no output schema, the description carries the return-value burden and does so thoroughly, plus it documents prerequisites and the no-fabrication guarantee. The remaining gap is parameter documentation for env, region, and the slug parameters, which is unaddressed in both schema and description.

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

Parameters2/5

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

Schema description coverage is only 17% - just the 'range' parameter - and the description adds no meaning for env, region, workspaceSlug, appSlug, or serviceName. The only indirect hint is that the subject is 'a Postfix service', which weakly maps to serviceName. With low coverage, the description should have compensated and does not.

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 names a specific verb and resource ('Reads a Postfix service's delivery log and queue') and then enumerates the concrete facets returned (delivery time, rejections, bounce reasons, queue size by state, retry settings). It never distinguishes itself from close siblings that overlap it - readServiceMailQueue, readServiceLogs, flushServiceMailQueue - so an agent cannot tell from the text which one to call for queue data alone.

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?

There is no explicit 'use this when...' or 'use X instead' clause, and no routing against the mail-queue and log siblings. The prerequisite paragraph does give implicit guidance by stating when the tool will actually yield data (maillog_file=/dev/stdout, exporter enabled, API key present), which helps an agent judge whether a call is worthwhile.

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

Deploy Server

Other Tools