Configure Events & Actions
The Events & Actions section in the Admin Portal lets you create, edit, and delete event listeners and their actions.
Event listeners
The Event Listeners section shows how many listeners you created, their type and status, and how many actions they trigger. Hover to see the linked action name. For details, see create event listeners.
Actions
The Actions section shows how many actions you created, their type and status, and how many listeners link to them. Hover to see the linked listener name. For details, see create actions.
Create event listener
To create an event listener:
-
Open Admin Portal and choose Events & Actions.
-
Select your app and keyset.
-
Click + Add Event Listener and select the event source. For sources, see Event source.
-
Choose the event producer and event type.
Available producers and types
If you don't see the event type you need, choose a different event source.
-
Select a filter type. The flow may vary based on the selected source and type.
Name Description No filter Triggers actions for all messages. Basic filters Predetermined UI conditions. Advanced JSONPath JSONPath conditions over payload fields. -
Pair the listener with an existing action without leaving Event Listeners. In Add Action, pick the action.
-
Click Save Changes.
Filter types
There are three filter types:
No filter
No setup necessary. Triggers actions for all messages.
Basic filters
After choosing Basic filters, you see two dropdowns—Filters and Conditions—and a Value input.
-
From Filters, pick a filter.
Name Description Channel Trigger an action after a message is published on a specific channel. Sender ID Trigger an action after a message is published by a specific sender. -
From Conditions, pick a condition.
Name Description Exact Match Trigger an action only if there is an exact match. Contains Trigger an action if the specified value is found. -
In Value, enter the value that must match. For example, an exact match on channel
Matrix
triggers an action for every message inMatrix
.
Advanced JSONPath
JSONPath supports more advanced conditions than Basic filters.
You can use JSONPath to define the following conditions:
Condition name | Data type | Description |
---|---|---|
channel | string | Name of the channel the message was sent to. |
message | any | Message content. |
meta | any | Custom metadata. |
uuid | string | Sender ID. |
User ID / UUID
User ID is also referred to as UUID
/uuid
in some APIs and server responses but holds the value of the userId
parameter you set during initialization.
To recreate the Basic filters example, use:$.[?(@.channel == "Matrix")]
.
This triggers an action when a message is published to the Matrix
channel.
Create action
Choose the action category and follow its steps.
Name | Description |
---|---|
Webhook | Integrate with a third‑party service. |
Amazon SQS | Use a third‑party message queue. |
Amazon Kinesis | Use a real‑time streaming service. |
Amazon S3 | Use third‑party object storage. |
Apache Kafka | Export events to Apache Kafka. |
IFTTT Webhook | Automate actions across services and devices. |
AMQP Action | Export events to AMQP. |
Webhook payload example
The JSON below shows a webhook payload triggered when the message Wake up, Neo...
is sent by Client-w5h0y
on channel Matrix
.
User ID / UUID
User ID is also referred to as UUID
/uuid
in some APIs and server responses but holds the value of the userId
parameter you set during initialization.
{
"event": {
"channel": "Matrix",
"eventCategory": "message",
"eventType": "message.publish",
"eventId": "a2748829-a16e-4ce7-b3ed-67021d2c7c65",
"eventPayload": {
"message": "{\"text\":\"Wake up, Neo...\"}",
"meta": {}
},
"iso8601timestamp": "2023-11-28T12:31:32Z",
"subscribeKey": "sub-c-95c7895c-b977-4728-bebe-f2e5db1b4f90",
"timetoken": "17011746925168240",
"senderId": "Client-w5h0y"
},
show all 32 linesFor webhook payloads, see Webhooks.