Skip to main content
Glama

Generate a lead's emails with AI

generate_lead_sequence
DestructiveIdempotent

Write one lead's email sequence with AI — the Generate button of a SINGLE campaign, one lead at a time. SPENDS THE USER'S OPENAI CREDITS on their own key, so ask them before calling it. The lead needs a title or a description: the AI writes the pitch from the project details and refuses rather than inventing one. Replaces any existing draft for that lead. Does not apply to 'multi' campaigns, which use one shared set_sequence. NOTHING IS SENT — the draft waits at 'pending_review' for the user to approve in ReplyNorth.

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": {
      "lead_id": "<lead_id>"
    },
    "name": "generate_lead_sequence"
  }
}

Input Schema

NameRequiredDescriptionDefault
lead_idYesThe lead to write emails for — the `id` from list_leads, which is the lead's row in one campaign, not a contact id. SINGLE campaigns only.
idempotency_keyNoOptional. Send the SAME value when retrying, so a generation is not paid for twice.

Schema Changelog

Changes observed during successful MCP inspections.

No schema history has been recorded yet.

TDQS

A4.7/5.0
Behavior5/5

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

Beyond the annotations it discloses the costly side effect (consumes the user's own OpenAI credits), the destructive consequence (replaces any existing draft for that lead), and the outcome boundary (nothing is sent; the draft waits at 'pending_review'). The destructiveHint is therefore explained rather than merely flagged.

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?

Every sentence earns its place: scope first, cost warning second, precondition third, replace behavior fourth, exclusion fifth, outcome last. The em-dash headline front-loads the core action, and there is no filler or repetition.

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?

With no output schema, the description still tells the agent what the result looks like (a draft at 'pending_review' awaiting user approval) and that nothing is sent. For a two-parameter, cost-incurring generation tool, nothing needed to call it correctly is missing.

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% and both parameters are already documented, including lead_id being a campaign row rather than a contact id and the retry use of idempotency_key. The description reinforces the single-lead scope but adds no parameter-level detail the schema does not already carry, so the baseline of 3 applies.

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 gives a specific verb and resource ('Write one lead's email sequence with AI') plus explicit scope: 'the Generate button of a SINGLE campaign, one lead at a time.' It also actively distinguishes itself from the sibling set_sequence by noting multi campaigns use one shared sequence.

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?

It states the precondition (the lead needs a title or description), the exclusion (not for 'multi' campaigns, use set_sequence), and a consent requirement (ask the user before calling because it spends their OpenAI credits). That is when-to-use, when-not-to-use, and an alternative named in one place.

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