Skip to content

Latest commit

 

History

History
247 lines (156 loc) · 4.83 KB

notifications.md

File metadata and controls

247 lines (156 loc) · 4.83 KB

Notifications

notifications_controller = client.notifications

Class Name

NotificationsController

Methods

Create Admin Notification

Sends a notification to all admins.

def create_admin_notification(self,
                             body)

Parameters

Parameter Type Tags Description
body AdminNotificationDto Body, Required The notification request.

Response Type

void

Example Usage

body = AdminNotificationDto()

result = notifications_controller.create_admin_notification(body)

Errors

HTTP Status Code Error Description Exception Class
401 Unauthorized APIException
403 Forbidden APIException

Get Notification Services

Gets notification services.

def get_notification_services(self)

Response Type

List of NameIdPair

Example Usage

result = notifications_controller.get_notification_services()

Errors

HTTP Status Code Error Description Exception Class
401 Unauthorized APIException
403 Forbidden APIException

Get Notification Types

Gets notification types.

def get_notification_types(self)

Response Type

List of NotificationTypeInfo

Example Usage

result = notifications_controller.get_notification_types()

Errors

HTTP Status Code Error Description Exception Class
401 Unauthorized APIException
403 Forbidden APIException

Get Notifications

Gets a user's notifications.

def get_notifications(self,
                     user_id)

Parameters

Parameter Type Tags Description
user_id string Template, Required -

Response Type

NotificationResultDto

Example Usage

user_id = 'userId0'

result = notifications_controller.get_notifications(user_id)

Errors

HTTP Status Code Error Description Exception Class
401 Unauthorized APIException
403 Forbidden APIException

Get Notifications Summary

Gets a user's notification summary.

def get_notifications_summary(self,
                             user_id)

Parameters

Parameter Type Tags Description
user_id string Template, Required -

Response Type

NotificationsSummaryDto

Example Usage

user_id = 'userId0'

result = notifications_controller.get_notifications_summary(user_id)

Errors

HTTP Status Code Error Description Exception Class
401 Unauthorized APIException
403 Forbidden APIException

Set Read

Sets notifications as read.

def set_read(self,
            user_id)

Parameters

Parameter Type Tags Description
user_id string Template, Required -

Response Type

void

Example Usage

user_id = 'userId0'

result = notifications_controller.set_read(user_id)

Errors

HTTP Status Code Error Description Exception Class
401 Unauthorized APIException
403 Forbidden APIException

Set Unread

Sets notifications as unread.

def set_unread(self,
              user_id)

Parameters

Parameter Type Tags Description
user_id string Template, Required -

Response Type

void

Example Usage

user_id = 'userId0'

result = notifications_controller.set_unread(user_id)

Errors

HTTP Status Code Error Description Exception Class
401 Unauthorized APIException
403 Forbidden APIException