Skip to main content

NotificationApiClient

Contains all the endpoints needed to manage notifications.

Constructors

Constructor

new NotificationApiClient(): NotificationApiClient

Returns

NotificationApiClient

Methods

createCustomNotification()

static createCustomNotification(data, config?): Promise<any>

This endpoint generates a custom notification starting from the user. The recipients of the notification can be the user's friends/followers or the user himself (based on recipients_type value). Es. connections -> "user" added an item to the wishlist.

Parameters

ParameterTypeDescription
dataCustomNotificationParams
config?AxiosRequestConfig

Returns

Promise<any>


disposeBroadcastMessages()

static disposeBroadcastMessages(banner_ids, config?): Promise<any>

This endpoint disposes a broadcast message for a user.

Parameters

ParameterTypeDescription
banner_idsnumber[]
config?AxiosRequestConfig

Returns

Promise<any>


getUnseenNotification()

static getUnseenNotification(config?): Promise<SCNotificationUnseenCountType>

This endpoint retrieves the number of unseen/unread notifications.

Parameters

ParameterTypeDescription
config?AxiosRequestConfig

Returns

Promise<SCNotificationUnseenCountType>


listBroadcastMessages()

static listBroadcastMessages(config?): Promise<SCPaginatedResponse<SCBroadcastMessageType>>

This endpoint lists all broadcast messages. Broadcast Message is a feature which allows a specific user to send messages and announcements to a larger group of users at once.

Parameters

ParameterTypeDescription
config?AxiosRequestConfig

Returns

Promise<SCPaginatedResponse<SCBroadcastMessageType>>


listBroadcastMessagesUndisposedCount()

static listBroadcastMessagesUndisposedCount(config?): Promise<SCNotificationUnseenCountType>

This endpoint retrieves the total number of broadcast messages not yet disposed by the user.

Parameters

ParameterTypeDescription
config?AxiosRequestConfig

Returns

Promise<SCNotificationUnseenCountType>


listBroadcastMessagesUnseenCount()

static listBroadcastMessagesUnseenCount(config?): Promise<SCNotificationUnseenCountType>

This endpoint retrieves the total number of broadcast messages not yet seen by the user.

Parameters

ParameterTypeDescription
config?AxiosRequestConfig

Returns

Promise<SCNotificationUnseenCountType>


listUserNotification()

static listUserNotification(config?): Promise<SCPaginatedResponse<SCNotificationAggregatedType>>

List all user notifications (in aggregate form) related to the community.

Parameters

ParameterTypeDescription
config?AxiosRequestConfig

Returns

Promise<SCPaginatedResponse<SCNotificationAggregatedType>>


markReadBroadcastMessages()

static markReadBroadcastMessages(banner_ids, config?): Promise<any>

This endpoint marks as viewed/read a broadcast message for a user.

Parameters

ParameterTypeDescription
banner_idsnumber[]
config?AxiosRequestConfig

Returns

Promise<any>


markReadNotification()

static markReadNotification(sids, config?): Promise<any>

This endpoint marks as read a list of notifications identified by serialization_ids (sids).

Parameters

ParameterTypeDescription
sidsstring[]
config?AxiosRequestConfig

Returns

Promise<any>