Action operator_panel__get_last_dialog
System ID:
action_operator_panel__get_last_dialog
In the scenario also:operator_panel__get_last_dialog
Description
Finds the last Operator Panel chat room for the current chat_id and channel, loads messages and participants, and writes the result to a constant. Format: JSON (string) or text (txt). Default constant — last_operator_dialog, unless set_to is set.
Events (scenario branches)
| Event | When it occurs |
|---|---|
| success | Chat room found; result (if there are messages) written to the constant |
| error | Chat room not found |
If the room exists but has no messages, the action may still return success, and the constant may stay without a new value.
Parameters
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
format | string | no | json | Output format: json or txt |
set_to | string | no | — | Constant name for the result; if missing — last_operator_dialog |
Configuration example
{
"format": "json",
"set_to": "dialog_history"
}
Text variant:
{
"format": "txt",
"set_to": "dialog_text"
}