If a new message arrives Matterhorn issues a system notification. This can also be configured via activityNotifyCommand. An example script is in the official repo: notifications-scripts/notify.
Found these workaround:
Other ways seem to depend on mounting the X11 socket and maybe dbus.