Links
Comment on page

Iframe Events

When the iframe integration is enabled, some events are triggered. These events include the following:
Event name
Description
startup
Fired when an iframe initializes
notification
Fired when a user receives a notification
unread-changed-by-subscription
Fired each time a user's subscription record changes (i.e.: unread counts, etc)
unread-changed
Fired when the pages title changes
room-opened
Fired when a room is opened
new-message
Fired every time the opened room receives a new message
click-user-card-message
Fired when the user clicks on a username link
click-mention-link
Fired when the user clicks on a mention link
click-message-link
Fired when the user clicks on a posted link
click-action-link
Fired when the user clicks on an action link button (i.e.: "click to join" to video conferences)
Here is a sample code that listens to events fired from Rocket.Chat opened on an iframe:
window.addEventListener('message', function(e) {
console.log(e.data.eventName); // event name
console.log(e.data.data); // event data
});
Last modified 4mo ago
Deprecation for cloud services and apps is now extended to November 20, 2023. Rocket.Chat versions receive support for six months after release.