Inbox / CLI

Generate reply draft

Run the ReplyAgent to draft a reply to an inbox conversation, using workspace GTM context (offers, ICP, personas, case studies) and calendar availability. Returns the drafted message, strategy, confidence, and whether it needs human review before sending.

pipeline generate-reply-draftBackend AI, consent required

Parameters

workspaceIdOptional · string
Optional workspace ID or slug. Required when this credential can access multiple workspaces and no workspace was configured on the client.
workspaceSlugOptional · string
Required for Clerk auth. Ignored when using API key (workspace inferred from key).
linkedin_account_idOptional · string
Optional connected LinkedIn account UUID used to scope calendar availability and reply context.
conversationRequired · object
Required. The conversation object (must include chat_id).
messagesOptional · array
Message thread the reply should respond to.
sentimentAnalysisOptional · object
Optional prior sentiment classification (from analyze-sentiment) to ground strategy selection.
allowHostedAiOptional · boolean
Must be true when this operation uses Pipeline hosted inference.
Request example
pipeline generate-reply-draft \
  --conversation-json '{}' \
  --allow-hosted-ai
Full input schema
Input schema
{
  "type": "object",
  "properties": {
    "workspaceId": {
      "type": "string",
      "minLength": 1,
      "description": "Optional workspace ID or slug. Required when this credential can access multiple workspaces and no workspace was configured on the client."
    },
    "workspaceSlug": {
      "type": "string",
      "description": "Required for Clerk auth. Ignored when using API key (workspace inferred from key)."
    },
    "linkedin_account_id": {
      "type": "string",
      "format": "uuid",
      "description": "Optional connected LinkedIn account UUID used to scope calendar availability and reply context."
    },
    "conversation": {
      "type": "object",
      "additionalProperties": true,
      "description": "Required. The conversation object (must include chat_id)."
    },
    "messages": {
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": true
      },
      "description": "Message thread the reply should respond to."
    },
    "sentimentAnalysis": {
      "type": "object",
      "additionalProperties": true,
      "description": "Optional prior sentiment classification (from analyze-sentiment) to ground strategy selection."
    },
    "allowHostedAi": {
      "type": "boolean",
      "description": "Must be true when this operation uses Pipeline hosted inference."
    }
  },
  "required": [
    "conversation"
  ]
}
See this operation inMCP REST API TypeScript SDK
CLI guide | Pipeline v2 preview