Notifications #
The RealtimeController.subscribe method takes a handler argument, called with a KuzzleResponse object, whose content of the Result
property depends on the type of notification received.
Document & messages #
These notifications represent documents changes & messages.
The Result
Map is the notification content, and it has the following structure:
Property | Type | Description |
---|---|---|
_id | String | Document unique IDnull if the notification is from a real-time message |
_source | Map<String, dynamic> | Message or full document content. Not present if the event is about a document deletion |
User #
These notifications represent user events.
The Result
object is the notification content, and it has the following structure:
Property | Type | Description |
---|---|---|
count | int | Updated users count sharing that same subscription |
Edit this page on Github(opens new window)