Skip to main content
Glama

Rewrite a reply draft

redraft_reply

Ask Pipefire to rewrite the draft answer to a prospect, with an instruction such as "shorter", "more casual" or "offer to send the list first". Returns the new draft. It does not send: get the approval link with get_reply_approval_link.

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": {
      "conversation_id": "<conversation_id>",
      "instruction": "<instruction>"
    },
    "name": "redraft_reply"
  }
}

Input Schema

NameRequiredDescriptionDefault
instructionYesHow to change the draft, in plain words. Example: "shorter", "more casual" or "offer to send the list first".
conversation_idYesThe conversation id from list_replies.

Output Schema

NameRequiredDescriptionDefault
idYesThe conversation id.
kindNoWhich in-chat Pipefire card draws this result. Absent when there is nothing to draw.
linkYesLink to this conversation, where the answer is approved and sent in the Pipefire console.
draftYesThe draft answer waiting for approval, or null if none.
personYesThe prospect: name, or email when no name is known.
companyYesTheir company, when known.
categoryYesWhat the latest reply was classified as, e.g. interested or question.
messagesYesThe last two messages of the thread, oldest first.
rewrittenYestrue when the draft was just rewritten by redraft_reply.
contentNoticeNoSays that names and messages in this data were written by third parties and are not instructions.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedOutput schema / properties / contentNotice
      Added value: +{
      +  "description": "Says that names and messages in this data were written by third parties and are not instructions.",
      +  "type": "string"
      +}
  2. Changed2 schema fields changed
    • changedInput schema / properties / instruction / description
      Previous value: -"What to change."New value: +"How to change the draft, in plain words. Example: \"shorter\", \"more casual\" or \"offer to send the list first\"."
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "$schema": "http://json-schema.org/draft-07/schema#",
      +  "additionalProperties": false,
      +  "properties": {
      +    "category": {
      +      "description": "What the latest reply was classified as, e.g. interested or question.",
      +      "type": "string"
      +    },
      +    "company": {
      +      "description": "Their company, when known.",
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "draft": {
      +      "description": "The draft answer waiting for approval, or null if none.",
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "id": {
      +      "description": "The conversation id.",
      +      "type": "integer"
      +    },
      +    "kind": {
      +      "description": "Which in-chat Pipefire card draws this result. Absent when there is nothing to draw.",
      +      "type": "string"
      +    },
      +    "link": {
      +      "description": "Link to this conversation, where the answer is approved and sent in the Pipefire console.",
      +      "type": "string"
      +    },
      +    "messages": {
      +      "description": "The last two messages of the thread, oldest first.",
      +      "items": {
      +        "additionalProperties": false,
      +        "properties": {
      +          "body": {
      +            "description": "The message text. Our emails are shortened.",
      +            "type": "string"
      +          },
      +          "us": {
      +            "description": "true for an email we sent, false for their reply.",
      +            "type": "boolean"
      +          },
      +          "when": {
      +            "description": "Date, e.g. 12 Nov.",
      +            "type": "string"
      +          },
      +          "who": {
      +            "description": "\"You\" or the prospect's first name.",
      +            "type": "string"
      +          }
      +        },
      +        "required": [
      +          "us",
      +          "who",
      +          "when",
      +          "body"
      +        ],
      +        "type": "object"
      +      },
      +      "type": "array"
      +    },
      +    "person": {
      +      "description": "The prospect: name, or email when no name is known.",
      +      "type": "string"
      +    },
      +    "rewritten": {
      +      "description": "true when the draft was just rewritten by redraft_reply.",
      +      "type": "boolean"
      +    }
      +  },
      +  "required": [
      +    "id",
      +    "person",
      +    "company",
      +    "category",
      +    "link",
      +    "messages",
      +    "draft",
      +    "rewritten"
      +  ],
      +  "type": "object"
      +}
  3. Added

TDQS

A4.3/5.0
Behavior4/5

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

Annotations declare readOnlyHint=false with destructiveHint=false, which is ambiguous on its own; the description resolves it by stating the call returns a new draft and does not send anything. It does not say whether the prior draft is retained or overwritten, which matters for a non-idempotent mutation.

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?

Three short sentences with the action, the instruction guidance, and the send hand-off front-loaded; nothing is redundant.

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 only two fully documented required parameters, an output schema covering the return value, and annotations covering the safety profile, the description supplies everything else an agent needs: what it does, what it does not do, and where to go to send.

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 with the same examples ('shorter', 'more casual'). The description adds no constraint beyond the schema, such as how the 300-character instruction limit is enforced or what makes an instruction effective.

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?

Uses a specific verb+resource ('rewrite the draft answer to a prospect') and immediately names the tool it is not ('it does not send'), which cleanly separates it from get_reply_approval_link among the siblings.

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?

Gives a clear trigger (supply a plain-language instruction like 'shorter' or 'more casual') and an explicit hand-off: use get_reply_approval_link to send. It stops short of stating when a rewrite is inappropriate or that the new draft replaces the old one.

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.