Skip to main content
Glama

DirectMailAmerica — Narrow

Send Letter

send_letter
Destructive

Release the immutable quoteId from quote_letter using an existing authenticated workspace balance. Requires confirmed=true, approvedTotalCents matching the saved quote and one idempotencyKey after review of the exact saved PDF, addresses and options. Changed content requires a new quote and fresh approval. Immediately spends the approved amount and can buy postage. No guest payment, funding or cryptocurrency settlement. Insufficient balance sends nothing. Staging prevents postage but still debits the workspace balance. Safe failures before mailing authorization queue the approved order for automatic retry without another debit. Queued is not submitted. Reuse the same quoteId and key after interruption; uncertain sends require reconciliation. Tool contract: https://directmailamerica.com/agents/references/mcp-narrow.md

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": {
      "quoteId": "<quoteId>",
      "confirmed": "<confirmed>",
      "approvedTotalCents": "<approvedTotalCents>",
      "idempotencyKey": "<idempotencyKey>"
    },
    "name": "send_letter"
  }
}

Input Schema

NameRequiredDescriptionDefault
bodyNoPlain-text letter body when not uploading a PDF
fromNo
colorNoColor letter printing adds $0.49 per printed page per recipient. Express postcards default to included full color: true preserves color; false converts the mailed PDF to grayscale.
quoteIdYesImmutable quote returned by quote_letter. Review its exact PDF, addresses, options and total before approval.
filenameNo
certifiedNo
confirmedYesThe user explicitly approved the exact document, addresses, options and total.
mailClassNofirst_class
pageCountNoActual inspected PDF page count determines the send price; this field cannot override it.
pdfBase64NoPrint-ready PDF as base64, maximum 25 MiB decoded. Embedded fonts are preserved. Express postcard: exactly one unrotated 5.5 × 4.25 inch (396 × 306 point) page, matching page boxes, no added bleed or crop marks. No raw image files.
couponCodeNoServer-validated catalog code (case-insensitive). Applied to charged/quoted cents only — staging keys still never buy postage. Unknown codes are rejected.
recipientsNo
doubleSidedNo
idempotencyKeyYesRequired for workspace-credit sends. Generate once per intended mailing and reuse for identical retries. Uncertain results remain reserved and cannot automatically resubmit.
approvedTotalCentsYesExact approved USD cents; must match the server's calculated price before the balance is spent.
electronicReturnReceiptNo

Output Schema

NameRequiredDescriptionDefault
idNo
errorNo
quoteNo
replayNo
statusNo
quoteIdNo
intentIdNo
createdAtNo
operationYes
priceCentsNo
settlementNo
statusLabelNo
balanceCentsNoUSD cents. Null means not applicable or not known; never interpret null as zero.
trackingNumberNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.5/5.0
Behavior4/5

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

Goes well beyond the annotations: it discloses that the approved amount is spent immediately and can buy postage, that insufficient balance sends nothing, that staging still debits the balance, and that safe pre-authorization failures queue for automatic retry without another debit. The only gap is the fine distinction between key-based retry deduplication and the idempotentHint=false annotation, which is implied ('reuse the same key') but not squarely reconciled.

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-loads the core action and the approval gates, then moves to failure and retry behavior; nearly every sentence carries a distinct constraint. It is dense and telegraphic in places ('Queued is not submitted.') and a short bulleted structure would parse faster, but there is little outright waste.

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 16-parameter, nested-object, money-spending tool the description covers the risk-critical semantics and points to a full contract URL, and return values are covered by an output schema. It does not say which optional content parameters interact (e.g. body vs pdfBase64, pageCount not overriding inspection), but nothing essential to safe invocation is missing.

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?

At 56% schema coverage the description still adds real meaning for the decisive parameters: confirmed must represent explicit user approval of the exact document, approvedTotalCents must match the server-calculated price before funds move, and the idempotencyKey must be generated once per intended mailing and reused only for identical retries. The many content parameters (mailClass, doubleSided, color, pdfBase64) are left to the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Release the immutable quoteId from quote_letter') and immediately frames it as the commit/spend step funded by the workspace balance, which cleanly separates it from the quote_letter, preview_letter and get_letter_status siblings.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicit preconditions (confirmed=true, approvedTotalCents matching the saved quote, a single idempotencyKey) and exclusions ('No guest payment, funding or cryptocurrency settlement') are stated, plus the routing rule that changed content requires a new quote and fresh approval rather than resending.

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