1

The play_sounds option in ConverseJS (version 3.2) allows "playing a notification sound when you receive a personal message or when your nickname is mentioned in a chat room" (see here). Is there a way to play sound for every new message in the muc chat room, not just the ones that mention a user?

MikeMarsian
  • 608
  • 1
  • 7
  • 21

1 Answers1

1

Yes, there is a way to do this.

Use the notify_all_room_messages setting.

From the above link:

If you set this setting to true, then you will be notified of all messages received in a room.

This refers to both sound notifications and HTML5 desktop notifications.

To have notifications for only some rooms:

converse.initialize({
        // Other config settings omitted for brevity
        // ...

        notify_all_room_messages: [                                                  
            'foo@conference.exampl.org',
            'bar@conference.example.org',                            
                   │
        ]
});

Or to enable notifications for all rooms:

converse.initialize({
        // Other config settings omitted for brevity
        // ...

        notify_all_room_messages: true                                               
});
JC Brand
  • 2,652
  • 18
  • 18