Actions Overview
| Action | Description |
|---|---|
summarize | Compress older messages into an LLM-generated summary, keeping recent messages intact. |
trim | Drop the oldest messages to bring the count under a limit. |
clear | Remove all messages from the memory instance. |
export | Return all messages without modifying them. |
Summarize
Replaces older messages with a concise LLM-generated summary. The agent node’s configured LLM provider and model are used for summarization.Summarize Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
action | string | ✅ | Must be "summarize". |
context_memory_id | string | ✅ | The context memory ID (resolved chat/session ID). |
workflow_version_id | string (uuid) | ✅ | The workflow version ID. |
keep_last_n | integer | — | Keep this many recent messages; summarize the rest. Defaults to keeping the last 2. |
summarize_prompt | string | — | Custom summarization prompt. Falls back to the agent’s configured prompt. |
Trim
Removes the oldest messages to bring the total count under the specified limit.Trim Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
action | string | ✅ | Must be "trim". |
context_memory_id | string | ✅ | The context memory ID. |
workflow_version_id | string (uuid) | ✅ | The workflow version ID. |
max_messages | integer | — | Maximum messages to keep (default 10). |
Clear
Removes all messages from the memory instance and resets the context window size to 0.Export
Returns all memory messages without modifying them.Response
All actions return the same response shape:| Field | Type | Description |
|---|---|---|
action | string | The action that was performed. |
message | string | Human-readable status message. |
deleted_count | integer | Number of messages removed. |
summary | string | The generated summary text (only for summarize). |
messages | array | Full message list (only for export). |
remaining_count | integer | Messages remaining after the action. |

