Skip to main content

Headless Inbox Examples

Use @novu/js for vanilla JavaScript applications or when you want full control over the UI.

Installation

Initialize the Client

Fetch Notifications

Count Notifications

Mark as Read

Mark as Unread

Archive

Unarchive

Complete Actions

Snooze / Unsnooze

Delete

Preferences

Real-Time Updates

The @novu/js client automatically maintains a WebSocket connection for real-time notification updates. No additional configuration is needed.

Vanilla JavaScript Example