Module websocket/notifications
Type aliases
ClientboundNotification
Clientbound
Notification: { type: "Bulk"; v: ClientboundNotification[] } | { data: number; type: "Ping" } | { data: number; type: "Pong" } | ({ type: "Error" } & WebSocketError) | { type: "Authenticated" } | ReadyPacket | ({ type: "Message" } & Message) | { channel: string; data: Partial<Message>; id: string; type: "MessageUpdate" } | { append: Pick<Partial<Message>, "embeds">; channel: string; id: string; type: "MessageAppend" } | { channel: string; id: string; type: "MessageDelete" } | { channel_id: string; emoji_id: string; id: string; type: "MessageReact"; user_id: string } | { channel_id: string; emoji_id: string; id: string; type: "MessageUnreact"; user_id: string } | { channel_id: string; emoji_id: string; id: string; type: "MessageRemoveReaction" } | { channel: string; ids: string[]; type: "BulkMessageDelete" } | ({ type: "ChannelCreate" } & Channel) | { clear?: FieldsChannel[]; data: Partial<Channel>; id: string; type: "ChannelUpdate" } | { id: string; type: "ChannelDelete" } | { id: string; type: "ChannelGroupJoin"; user: string } | { id: string; type: "ChannelGroupLeave"; user: string } | { id: string; type: "ChannelStartTyping"; user: string } | { id: string; type: "ChannelStopTyping"; user: string } | { id: string; message_id: string; type: "ChannelAck"; user: string } | { channels: Channel[]; id: string; server: Server; type: "ServerCreate" } | { clear?: FieldsServer[]; data: Partial<Server>; id: string; type: "ServerUpdate" } | { id: string; type: "ServerDelete" } | { clear?: FieldsMember[]; data: Partial<Member>; id: MemberCompositeKey; type: "ServerMemberUpdate" } | { id: string; type: "ServerMemberJoin"; user: string } | { id: string; type: "ServerMemberLeave"; user: string } | { data: Partial<Role>; id: string; role_id: string; type: "ServerRoleUpdate" } | { id: string; role_id: string; type: "ServerRoleDelete" } | { clear?: FieldsUser[]; data: Partial<User>; id: string; type: "UserUpdate" } | { status: RelationshipStatus; type: "UserRelationship"; user: User } | { id: string; online: boolean; type: "UserPresence" } | { id: string; type: "UserSettingsUpdate"; update: {} } | ({ type: "EmojiCreate" } & Emoji) | { id: string; type: "EmojiDelete" }
ReadyPacket
Type declaration
-
-
Optional emojis?: Emoji[]
-
-
-
type: "Ready"
-
users: User[]
ServerboundNotification
Serverbound
Notification: { data: number; type: "Ping" } | { data: number; type: "Pong" } | ({ type: "Authenticate" } & Session) | { token: string; type: "Authenticate" } | { channel: string; type: "BeginTyping" } | { channel: string; type: "EndTyping" }