Skip to main content
Glama
PurelyMail MCP Server

PurelyMail MCP Server

by gui-wf

create_routing_rule

Creates a domain routing rule to reroute mail for a matched user to specified target addresses and prevent duplicate user/prefix rules.

Instructions

Creates a new routing rule for a domain. Routing rule must not have the same user/prefix as any other existing rules for the domain.

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": {
      "domainName": "<domainName>",
      "prefix": "<prefix>",
      "matchUser": "<matchUser>",
      "targetAddresses": "<targetAddresses>"
    },
    "name": "create_routing_rule"
  }
}

Input Schema

NameRequiredDescriptionDefault
prefixYes
catchallNoWhether this is a 'catchall' rule that will not fire if address maps to a user
matchUserYesThe local part of the user address to be matched, i.e. "user" in "user@domain.org"
domainNameYes
targetAddressesYesList of full email addresses that this mail will be rerouted to

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv3.0.2

TDQS

B3.3/5.0
Behavior3/5

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

With no annotations provided, the description carries the full burden. It usefully discloses an error condition (duplicate user/prefix for the domain), but says nothing about required privileges, whether the rule takes effect immediately, or what is returned on success or failure.

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

Conciseness5/5

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

Two short sentences with no waste; the purpose is front-loaded and the constraint follows immediately.

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 five-parameter mutation with no annotations and no output schema, the definition covers purpose and one validation rule but omits permissions, side effects, and the semantics of the ambiguous prefix flag, leaving real gaps.

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 60%: matchUser and targetAddresses are documented, and catchall has a description, but domainName and the boolean prefix parameter are undocumented in both places. The description only reiterates the user/prefix uniqueness idea and clarifies neither the meaning nor the type of prefix, so it does not compensate for the gap.

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 concrete verb and resource: creates a routing rule scoped to a domain. That distinguishes it cleanly from list_routing_rules and delete_routing_rule, though it does not explicitly name those siblings.

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?

It supplies one creation precondition (user/prefix must be unique within the domain), which implicitly signals this is the tool for adding new mappings. There is no explicit when-to-use versus alternatives guidance and no mention of prerequisite steps such as the domain already existing.

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