mcpHosted AI, explicit consent

Analyze sentiment

tools/call

Run the SentimentAgent on a conversation: classifies the prospect across the canonical 7 stages (initial, interested, neutral, objection, meeting_ready, closed_lost, closed_won) and updates the conversation_contexts row. Pass the full conversation object plus its messages - the agent uses the message thread, not the chat_id alone.

Parameters

workspaceId
string
Optional workspace ID or slug. Required when this credential can access multiple workspaces and no workspace was configured on the client.
decisionOverride
object
No description.
workspaceSlug
string
Required for Clerk auth. Ignored when using API key (workspace inferred from key).
conversationrequired
object
Required. The conversation object (must include chat_id).
messages
object[]
Message thread to analyze.
currentTags
string[]
Existing conversation tags so the agent can update incrementally.
allowHostedAi
boolean
Must be true when this operation uses Pipeline hosted inference.

Example

MCP tools/calljson
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "analyze-sentiment",
"arguments": {
"conversation": {},
"allowHostedAi": true
}
}
}

Response

The operation is available, but its typed response schema has not been published yet.

JSON-RPC errors

-32602
Invalid parameters. Field-level details are returned in the JSON-RPC error data.
-32001
Authentication or hosted AI consent is required.
-32003
Workspace access is denied.
-32029
The request was rate limited.
Pipeline MCP documentation | Pipeline