Skip to main content
Glama

Mailrith Email Marketing

Create or upsert a subscriber

subscribers_upsert
Destructive

Creates a new subscriber when the email does not exist in the workspace. If the email already exists, the API updates the existing subscriber unless create_only is true. Effect: external-email. Retry with the same idempotency_key. Permissions: live_actions:write, subscribers:write. API reference: https://mailrith.com/developers/api-reference.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
bodyYesThe exact JSON request body defined by the Mailrith public API contract.
idempotency_keyNoOptional idempotency key to retry the request safely. It must not exceed 256 UTF-8 bytes.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
errorNo
responseNo
request_idYesThe stable correlation ID for this MCP tool invocation.
operation_idYesThe stable Mailrith public API operation ID.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changed
    • addedInput schema / $defs / ConsentEvidence / properties / collected_at / description
      Added value: +"When the consent evidence was collected, as ISO 8601 with an explicit UTC offset. This must not be later than Mailrith's server time. Do not treat a workspace-local clock as UTC; use the evidence record's confirmed timestamp."
    • removedInput schema / $defs / ConsentEvidence / properties / collected_at / format
      Removed value: -"date-time"
    • addedInput schema / $defs / ConsentEvidence / properties / collected_at / pattern
      Added value: +"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|[+-](?:[01]\\d|2[0-3]):[0-5]\\d)$"
    • changedInput schema / properties / idempotency_key / description
      Previous value: -"Optional idempotency key to retry the request safely."New value: +"Optional idempotency key to retry the request safely. It must not exceed 256 UTF-8 bytes."
    • addedInput schema / properties / idempotency_key / maxLength
      Added value: +256
  2. Changed5 schema fields changed
    • removedInput schema / $defs / ConsentEvidence / properties / collected_at / description
      Removed value: -"When the consent evidence was collected, as ISO 8601 with an explicit UTC offset. This must not be later than Mailrith's server time. Do not treat a workspace-local clock as UTC; use the evidence record's confirmed timestamp."
    • addedInput schema / $defs / ConsentEvidence / properties / collected_at / format
      Added value: +"date-time"
    • removedInput schema / $defs / ConsentEvidence / properties / collected_at / pattern
      Removed value: -"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|[+-](?:[01]\\d|2[0-3]):[0-5]\\d)$"
    • changedInput schema / properties / idempotency_key / description
      Previous value: -"Optional idempotency key to retry the request safely. It must not exceed 256 UTF-8 bytes."New value: +"Optional idempotency key to retry the request safely."
    • removedInput schema / properties / idempotency_key / maxLength
      Removed value: -256
  3. Changed2 schema fields changed
    • changedInput schema / properties / idempotency_key / description
      Previous value: -"Optional idempotency key to retry the request safely."New value: +"Optional idempotency key to retry the request safely. It must not exceed 256 UTF-8 bytes."
    • addedInput schema / properties / idempotency_key / maxLength
      Added value: +256
  4. Changed3 schema fields changed
    • addedInput schema / $defs / ConsentEvidence / properties / collected_at / description
      Added value: +"When the consent evidence was collected, as ISO 8601 with an explicit UTC offset. This must not be later than Mailrith's server time. Do not treat a workspace-local clock as UTC; use the evidence record's confirmed timestamp."
    • removedInput schema / $defs / ConsentEvidence / properties / collected_at / format
      Removed value: -"date-time"
    • addedInput schema / $defs / ConsentEvidence / properties / collected_at / pattern
      Added value: +"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|[+-](?:[01]\\d|2[0-3]):[0-5]\\d)$"
  5. First observed

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already indicate destructive=true and idempotent=false. The description adds valuable context: the external-email effect, required permissions, and retry instructions with idempotency_key. It explains the modify-or-update behavior clearly, going beyond the annotation flags, though it could have disclosed side effects like which fields get updated.

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?

The description is three sentences, each serving a distinct purpose: behavior semantics, effect/permissions, and retry guidance. It is front-loaded with the most critical upsert logic and avoids redundancy or fluff.

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?

The tool has a complex schema with nested consent_evidence and custom fields, but the description covers the core behavior, permissions, external effect, and idempotency retry. An output schema exists, so return-value explanation is not needed. The description adequately supports agent decision-making and invocation.

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

Parameters3/5

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

Schema coverage is 100% with detailed per-parameter descriptions. The description adds minimal extra guidance beyond the schema, mainly reinforcing create_only and idempotency_key behavior. This meets the baseline for high schema coverage but doesn't significantly extend parameter understanding.

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?

The description clearly states 'Creates a new subscriber when the email does not exist... updates the existing subscriber...' making the verb-resource relationship and the upsert behavior unambiguous. It also distinguishes itself from sibling tools like subscribers_update by explaining the conditional create-or-update behavior based on email existence.

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

Usage Guidelines4/5

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

The description explains when to use it (creating or updating a subscriber based on email existence) and the create_only flag for avoiding updates. It also provides operational guidance on idempotency_key retries. However, it doesn't explicitly name alternative tools (e.g., subscribers_update for existing-only updates) or state when NOT to use this tool, though it's implied.

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.