Regenerate agent conversation message
Regenerate the AI response for a specific message in an agent conversation and stream the new answer over Server-Sent Events.
Constraints:
- Only the last message in the conversation can be regenerated.
- The target message must be of type bot_response.
Request body:
chatMode: quick is required. Other fields are optional and reuse the original model/context when omitted. The body supports:
- filters
- chatMode
- modelKey
- modelName
- modelFriendlyName
- timezone
- currentTime
- tools
- protocol
- agentCapabilities
Streaming behavior:
The response is delivered as an AG-UI text/event-stream. Stable outcomes are RUN_FINISHED and RUN_ERROR; see AgentRegenerateSSEEvent.
Additional agent/tool lifecycle events may be forwarded by the backend and should be treated as informational updates.
Validation failures on params/body are returned as normal HTTP 400 responses before the stream starts. Valid-shape requests that fail conversation lookup or regenerate rules are reported as RUN_ERROR events after stream initialization.
Path parameters
Stable key identifying the agent that owns this conversation.
ID of the agent conversation containing the target message.
ID of the bot-response message to regenerate.
Request body
Example request
{
"modelKey": "05438a37-68f2-4641-a8dc-6c47e63278ca",
"modelName": "gpt-5.4-mini",
"modelFriendlyName": "mini",
"chatMode": "internal_search",
"timezone": "Asia/Calcutta",
"currentTime": "2026-05-11T15:43:21+05:30",
"tools": [
"jira.create_issue",
"confluence.search_content"
]
}Response
SSE stream established.
Stable event names:
- RUN_FINISHED — { type, result }, where result contains the updated conversation and metadata
- RUN_ERROR — { type, message, code? }, reporting lookup, authorization, or regenerate-rule failures
Forwarded lifecycle and child-run events may include runId, threadId, and parentRunId. Additional backend-defined agent/tool events may be emitted. Clients should ignore unknown event names.