discord_gleam/ws/event_loop
Event loop for handling the discord gateway websocket Dispatches events to registered event handlers
Types
Values
pub fn main(
bot: bot.Bot,
event_handlers: List(fn(bot.Bot, event_handler.Packet) -> Nil),
host: String,
reconnect: Bool,
session_id: String,
state_ets: booklet.Booklet(dict.Dict(String, String)),
) -> Nil
Start the event loop, with a set of event handlers.