Skip to main content
Notifications

List Notifications

This API returns list of notifications for the given user.

GET
/
v3
/
notifications

Authentication Parameters

X-ENGAGESPOT-API-KEY
string
header
required

X-ENGAGESPOT-USER-ID
string
header
required

Authentication Bearer
string
header

Required if secure mode is enabled in your workspace

Query Parameters

pageNo
string

limit
string

Response

unreadCount
number

The unread notification count.

pagination
object

data
array

List of notifications for this user.

import Engagespot from '@engagespot/core';

const engagespot = new Engagespot('YOUR_ENGAGESPOT_API_KEY', {
  userId: 'unique-user-id',
});

const notificationList = engagespot.getNotificationList();
await notificationList.fetch();
notificationList.data.forEach(notification => {
  console.log(notification.title, notification.message);
});