Renders a live two-way chat widget backed by the Axion conversation webhook system, supporting text and image messages with auto-refresh.
CHAT — set as ReportType in def_report.
def Render(self, Param1="", Param2="", Param3="") -> str:
The query must return a single row with columns: conversation_id (col 0), client_id (col 1). Messages from the current client appear on the right; others appear on the left with avatars. New messages are polled every 10 seconds via RPC.
RpcConversation(data)Fetches new messages since last_stamp from the CONVERSATION_RECEIVE webhook. Returns [last_stamp, html_fragment].
RpcUsers(data)Returns distinct senders in the conversation and ensures their avatars are provisioned via ObjUser.
RpcSendmessage(data)Posts a text message to the CONVERSATION_SEND webhook, then returns the updated message list.
RpcSendimage(data)Posts a base64-encoded image to the CONVERSATION_SEND webhook (with : and ; escaped), then returns the updated message list.
Options read from self._Options JSON.
| Key | Effect |
|---|---|
do_file_input |
Set to "True" to show a file picker button for image uploads and a preview area. |
Requires jquery.timeago.js and axion.rpc.js. Uses the CONVERSATION_RECEIVE and CONVERSATION_SEND webhook endpoints configured at $baseurl$/webhook/.