Package-level declarations

Types

Link copied to clipboard
data class ChannelDeletedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val cid: String, val channelType: String, val channelId: String, val channel: Channel, val user: User?) : CidEvent, HasChannel

Triggered when a channel is deleted

Link copied to clipboard
data class ChannelHiddenEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val cid: String, val channelType: String, val channelId: String, val user: User, val clearHistory: Boolean) : CidEvent, UserEvent

Triggered when a channel is mark as hidden

Link copied to clipboard
data class ChannelTruncatedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val cid: String, val channelType: String, val channelId: String, val user: User?, val message: Message?, val channel: Channel) : CidEvent, HasChannel

Triggered when a channels' history is truncated. Could contain system message.

Link copied to clipboard
data class ChannelUpdatedByUserEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val cid: String, val channelType: String, val channelId: String, val user: User, val message: Message?, val channel: Channel) : CidEvent, UserEvent, HasChannel

Triggered when a channel is updated by user. Could contain system message.

Link copied to clipboard
data class ChannelUpdatedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val cid: String, val channelType: String, val channelId: String, val message: Message?, val channel: Channel) : CidEvent, HasChannel

Triggered when a channel is updated. Could contain system message.

Link copied to clipboard
data class ChannelUserBannedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val cid: String, val channelType: String, val channelId: String, val user: User, val expiration: Date?, val shadow: Boolean) : CidEvent, UserEvent

Triggered when the user is banned from a channel

Link copied to clipboard
data class ChannelUserUnbannedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User, val cid: String, val channelType: String, val channelId: String) : CidEvent, UserEvent

Triggered when the channel user ban is lifted

Link copied to clipboard
data class ChannelVisibleEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val cid: String, val channelType: String, val channelId: String, val user: User) : CidEvent, UserEvent

Triggered when a channel is made visible

Link copied to clipboard
sealed class ChatEvent
Link copied to clipboard
sealed class CidEvent : ChatEvent
Link copied to clipboard
data class ConnectedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val me: User, val connectionId: String) : ChatEvent, HasOwnUser

Triggered when a user gets connected to the WS

Link copied to clipboard
data class ConnectingEvent(val type: String, val createdAt: Date, val rawCreatedAt: String?) : ChatEvent

Triggered when a user is connecting to the WS

Link copied to clipboard
data class DisconnectedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String?, val disconnectCause: DisconnectCause = DisconnectCause.NetworkNotAvailable) : ChatEvent

Triggered when a user gets disconnected to the WS

Link copied to clipboard
data class ErrorEvent(val type: String, val createdAt: Date, val rawCreatedAt: String?, val error: Error) : ChatEvent

Triggered when WS connection emits error

Link copied to clipboard
data class GlobalUserBannedEvent(val type: String, val user: User, val createdAt: Date, val rawCreatedAt: String) : ChatEvent, UserEvent

Triggered when the user is banned globally

Link copied to clipboard
data class GlobalUserUnbannedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User) : ChatEvent, UserEvent

Triggered when the global user ban is lifted

Link copied to clipboard
interface HasChannel
Link copied to clipboard
interface HasMember
Link copied to clipboard
interface HasMessage
Link copied to clipboard
interface HasOwnUser
Link copied to clipboard
interface HasReaction
Link copied to clipboard
interface HasUnreadCounts

Interface that marks a ChatEvent as having the information about unread counts. There are certain cases when the server omits these fields (e.g. when ReadEvents option is disabled, when the number of watchers is over 100, etc). In that case totalUnreadCount and unreadChannels fields have 0 values.

Link copied to clipboard
interface HasWatcherCount

Interface that marks a ChatEvent as having the information about watcher count.

Link copied to clipboard
data class HealthEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val connectionId: String) : ChatEvent

Triggered every 30 second to confirm that the client connection is still alive

Link copied to clipboard
data class MarkAllReadEvent(val type: String = "", val createdAt: Date, val rawCreatedAt: String, val user: User, val totalUnreadCount: Int = 0, val unreadChannels: Int = 0) : ChatEvent, UserEvent, HasUnreadCounts

Triggered when the total count of unread messages (across all channels the user is a member) changes

Link copied to clipboard
data class MemberAddedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User, val cid: String, val channelType: String, val channelId: String, val member: Member) : CidEvent, UserEvent, HasMember

Triggered when a member is added to a channel

Link copied to clipboard
data class MemberRemovedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User, val cid: String, val channelType: String, val channelId: String, val member: Member) : CidEvent, UserEvent, HasMember

Triggered when a member is removed from a channel

Link copied to clipboard
data class MemberUpdatedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User, val cid: String, val channelType: String, val channelId: String, val member: Member) : CidEvent, UserEvent, HasMember

Triggered when a channel member is updated (promoted to moderator/accepted/.rejected the invite)

Link copied to clipboard
data class MessageDeletedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User?, val cid: String, val channelType: String, val channelId: String, val message: Message, val hardDelete: Boolean) : CidEvent, HasMessage

Triggered when a message is deleted

Link copied to clipboard
data class MessageReadEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User, val cid: String, val channelType: String, val channelId: String) : CidEvent, UserEvent

Triggered when a channel is marked as read

Link copied to clipboard
data class MessageUpdatedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User, val cid: String, val channelType: String, val channelId: String, val message: Message) : CidEvent, UserEvent, HasMessage

Triggered when a message is updated

Link copied to clipboard
data class NewMessageEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User, val cid: String, val channelType: String, val channelId: String, val message: Message, val watcherCount: Int = 0, val totalUnreadCount: Int = 0, val unreadChannels: Int = 0) : CidEvent, UserEvent, HasMessage, HasWatcherCount, HasUnreadCounts

Triggered when a new message is added on a channel.

Link copied to clipboard
data class NotificationAddedToChannelEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val cid: String, val channelType: String, val channelId: String, val channel: Channel, val member: Member, val totalUnreadCount: Int = 0, val unreadChannels: Int = 0) : CidEvent, HasChannel, HasMember, HasUnreadCounts

Triggered when the user is added to the list of channel members

Link copied to clipboard
data class NotificationChannelDeletedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val cid: String, val channelType: String, val channelId: String, val channel: Channel, val totalUnreadCount: Int = 0, val unreadChannels: Int = 0) : CidEvent, HasChannel, HasUnreadCounts

Triggered when a channel is deleted

Link copied to clipboard
data class NotificationChannelMutesUpdatedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val me: User) : ChatEvent, HasOwnUser

Triggered when a channel is muted

Link copied to clipboard
data class NotificationChannelTruncatedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val cid: String, val channelType: String, val channelId: String, val channel: Channel, val totalUnreadCount: Int = 0, val unreadChannels: Int = 0) : CidEvent, HasChannel, HasUnreadCounts

Triggered when a channels' history is truncated

Link copied to clipboard
data class NotificationInviteAcceptedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val cid: String, val channelType: String, val channelId: String, val user: User, val member: Member, val channel: Channel) : CidEvent, UserEvent, HasMember, HasChannel

Triggered when the user accepts an invite

Link copied to clipboard
data class NotificationInvitedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val cid: String, val channelType: String, val channelId: String, val user: User, val member: Member) : CidEvent, UserEvent, HasMember

Triggered when the user is invited to join a channel

Link copied to clipboard
data class NotificationInviteRejectedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val cid: String, val channelType: String, val channelId: String, val user: User, val member: Member, val channel: Channel) : CidEvent, UserEvent, HasMember, HasChannel

Triggered when the user rejects an invite

Link copied to clipboard
data class NotificationMarkReadEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User, val cid: String, val channelType: String, val channelId: String, val totalUnreadCount: Int = 0, val unreadChannels: Int = 0) : CidEvent, UserEvent, HasUnreadCounts

Triggered when the count of unread messages for a particular channel changes

Link copied to clipboard
data class NotificationMarkUnreadEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User, val cid: String, val channelType: String, val channelId: String, val totalUnreadCount: Int = 0, val unreadChannels: Int = 0, val unreadMessages: Int, val firstUnreadMessageId: String, val lastReadMessageAt: Date, val lastReadMessageId: String) : CidEvent, UserEvent, HasUnreadCounts

Triggered when the the user mark as unread a conversation from a particular message

Link copied to clipboard
data class NotificationMessageNewEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val cid: String, val channelType: String, val channelId: String, val channel: Channel, val message: Message, val totalUnreadCount: Int = 0, val unreadChannels: Int = 0) : CidEvent, HasChannel, HasMessage, HasUnreadCounts

Triggered when a message is added to a channel

Link copied to clipboard
data class NotificationMutesUpdatedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val me: User) : ChatEvent, HasOwnUser

Triggered when the user mutes are updated

Link copied to clipboard
data class NotificationRemovedFromChannelEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User?, val cid: String, val channelType: String, val channelId: String, val channel: Channel, val member: Member) : CidEvent, HasMember, HasChannel

Triggered when a user is removed from the list of channel members

Link copied to clipboard
data class ReactionDeletedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User, val cid: String, val channelType: String, val channelId: String, val message: Message, val reaction: Reaction) : CidEvent, UserEvent, HasMessage, HasReaction

Triggered when a message reaction is deleted

Link copied to clipboard
data class ReactionNewEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User, val cid: String, val channelType: String, val channelId: String, val message: Message, val reaction: Reaction) : CidEvent, UserEvent, HasMessage, HasReaction

Triggered when a message reaction is added

Link copied to clipboard
data class ReactionUpdateEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User, val cid: String, val channelType: String, val channelId: String, val message: Message, val reaction: Reaction) : CidEvent, UserEvent, HasMessage, HasReaction

Triggered when a message reaction is updated

Link copied to clipboard
data class TypingStartEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User, val cid: String, val channelType: String, val channelId: String, val parentId: String?) : CidEvent, UserEvent

Triggered when a user starts typing

Link copied to clipboard
data class TypingStopEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User, val cid: String, val channelType: String, val channelId: String, val parentId: String?) : CidEvent, UserEvent

Triggered when a user stops typing

Link copied to clipboard
data class UnknownEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User?, val rawData: Map<*, *>) : ChatEvent

Triggered when event type is not supported

Link copied to clipboard
data class UserDeletedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User) : ChatEvent, UserEvent
Link copied to clipboard
interface UserEvent
Link copied to clipboard
data class UserPresenceChangedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User) : ChatEvent, UserEvent

Triggered when a user status changes (eg. online, offline, away, etc.)

Link copied to clipboard
data class UserStartWatchingEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val cid: String, val watcherCount: Int = 0, val channelType: String, val channelId: String, val user: User) : CidEvent, UserEvent, HasWatcherCount

Triggered when a user starts watching a channel

Link copied to clipboard
data class UserStopWatchingEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val cid: String, val watcherCount: Int = 0, val channelType: String, val channelId: String, val user: User) : CidEvent, UserEvent, HasWatcherCount

Triggered when a user stops watching a channel

Link copied to clipboard
data class UserUpdatedEvent(val type: String, val createdAt: Date, val rawCreatedAt: String, val user: User) : ChatEvent, UserEvent

Triggered when a user is updated