Skip to main content
Glama

send_dunning

Destructive

Send the next (or given) dunning level for an invoice by e-mail and record it in the invoice's dunning history. Required: invoice_table (customer_invoices | mod_seminar_invoices), invoice_id. Optional: level (1|2), dry_run=true to see subject, text, recipient and new payment deadline without sending. Uses the tenant's templates (get_dunning_levels).

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": {
      "invoice_table": "<invoice_table>",
      "invoice_id": "<invoice_id>"
    },
    "name": "send_dunning"
  }
}

Input Schema

NameRequiredDescriptionDefault
levelNoDunning level to send (1 or 2); default the next level
dry_runNoOnly simulate and report what would happen; change nothing
invoice_idYesID of the invoice
invoice_tableYesInvoice table: customer_invoices or mod_seminar_invoices

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changed
    • addedInput schema / properties / dry_run / description
      Added value: +"Only simulate and report what would happen; change nothing"
    • addedInput schema / properties / invoice_id / description
      Added value: +"ID of the invoice"
    • addedInput schema / properties / invoice_table / description
      Added value: +"Invoice table: customer_invoices or mod_seminar_invoices"
    • addedInput schema / properties / level / description
      Added value: +"Dunning level to send (1 or 2); default the next level"
  2. First observed

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already flag destructiveHint=true, openWorldHint=true and idempotentHint=false, so the safety profile is covered. The description adds real value beyond that: it discloses the persistent side effect (a history entry is recorded), that a real e-mail leaves the system, that tenant templates drive the content, and that dry_run suppresses sending entirely.

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?

Three front-loaded sentences: action first, then parameter requirements, then template source. The required/optional enumeration mildly restates the schema, but it is compact and every clause carries information an agent needs before invoking a destructive send.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a destructive, externally-visible mutation with no output schema, the definition covers prerequisites, preview behavior and template dependency well. It does not say what a non-dry-run call returns (confirmation, message ID, updated deadline) or how failures such as a missing e-mail address are surfaced, which an agent planning retries would want.

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 baseline is 3, but the description adds meaning the schema lacks: level defaults to the next level rather than an arbitrary value, and dry_run previews subject, text, recipient and the new payment deadline. It also reinforces the two valid invoice_table values, though the level default is the only genuinely new semantic.

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?

States a specific verb and resource: send a dunning level for an invoice by e-mail and record it in dunning history. It also distinguishes itself from the read-only sibling get_dunning_levels by naming it as the template source. It stops short of explicitly contrasting with set_dunning_level, which mutates level configuration rather than sending.

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?

The description makes the send-and-record use case clear and lists required vs optional parameters, plus a preview mode. However, it offers no explicit when-not guidance and never says when to choose this over set_dunning_level or list_dunning_candidates; the routing is left implicit.

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.