Expand description
Kick’s chat-feed events, typed.
The realtime feed delivers each event as Kick’s own envelope, an event name
and its data (usually a JSON string). parse turns that into a
KickEvent. Parsing is lenient: a field Kick leaves out or sends in
another type comes out as None, and an event this crate does not know
comes out as KickEvent::Unknown rather than an error, so a new event
from Kick never breaks a client that does not care about it.
Which feed carries which event is in crate::realtime::chat_channels.
Modules§
- names
- Kick’s event names, as they arrive.
Structs§
- Badge
- A badge in Kick’s first format (
identity.badges). - Badge
Image - A badge in Kick’s image format (
identity.badges_v2). Badges the user chose not to show (selected: false) are left out. - Chat
Message - A chat message.
- Hosted
- The channel a host went to, on the hosting side.
- Kicks
Gift - A Kicks gift.
- ReplyTo
- What a reply answers.
- Sender
- Who sent a chat message.
- UserRef
- Someone named in an event.
Enums§
- Kick
Event - One event from the chat feed.
Functions§
- chat_
message - A chat message from its data, or
Noneif it has no id, sender name or text. Also reads the messages in the website API’s history. - parse
- Reads one feed event: its name, and its
dataas Kick sent it (a JSON string, or a value).