View Source TwitchEventSub (hello_twitch_eventsub v0.3.0)

TwitchEventSub websocket client supervisor. See the option/0 type for the required options.

Summary

Types

The IDs of the channels we're subscribing to or something.

The module that implements TwitchEventSub.

The keepalive timeout in seconds. Specifying an invalid, numeric value will return the nearest acceptable value. Optional. Defaults to 10.

The options accepted (or required) by the TwitchEventSub.Supervisor.

Tell the websocket client whether or not it should be started. Optional. Defaults to true.

A subscription for EventSub. Optional. Defaults to a bunch. Check TwitchEventSub.Websocket.Client for the defaults.

A websocket URL to connect to. Optional. Defaults to "wss://eventsub.wss.twitch.tv/ws".

The user ID of the broadcaster or bot user we are using for subscriptions.

Functions

Returns a specification to start this module under a supervisor.

Types

@type channel_ids() :: [String.t()]

The IDs of the channels we're subscribing to or something.

@type handler() :: module()

The module that implements TwitchEventSub.

@type keepalive_timeout() :: pos_integer()

The keepalive timeout in seconds. Specifying an invalid, numeric value will return the nearest acceptable value. Optional. Defaults to 10.

@type option() ::
  {:auth_store_callback_module, module()}
  | {:auth_store_name, TwitchAPI.AuthStore.name()}
  | {:channel_ids, channel_ids()}
  | {:handler, handler()}
  | {:keepalive_timeout, keepalive_timeout()}
  | {:start?, start?()}
  | {:subscriptions, [subscription()]}
  | {:url, url()}
  | {:user_id, user_id()}

The options accepted (or required) by the TwitchEventSub.Supervisor.

@type start?() :: boolean() | nil

Tell the websocket client whether or not it should be started. Optional. Defaults to true.

@type subscription() :: String.t() | %{condition: map(), name: String.t()}

A subscription for EventSub. Optional. Defaults to a bunch. Check TwitchEventSub.Websocket.Client for the defaults.

@type url() :: String.t()

A websocket URL to connect to. Optional. Defaults to "wss://eventsub.wss.twitch.tv/ws".

@type user_id() :: String.t()

The user ID of the broadcaster or bot user we are using for subscriptions.

Functions

Returns a specification to start this module under a supervisor.

See Supervisor.