Elixir v0.2.0 Nostrum.Shard.Payload

Specifies maps to be used for WS payloads.. and also the state map.

Summary

Types

The state map contained and maintained in each websocket process

Types

state_map()
state_map() :: map

The state map contained and maintained in each websocket process.

Keys

  • token - The token of the bot.
  • shard_num - The shard number container this state.
  • seq - Current seq number of the websocket.
  • session - Current session of the websocket.
  • reconnect_attempts - Current number of reconnect attempts.
  • last_heartbeat - The time of the last heartbeat.
  • shard_pid - Pid of the shard containing this state.
  • producer_pid - Pid of the producer attached to this shard
  • heartbeat_intervals - List of last ten heartbeat intervals, from hearbeat send to ack.

Functions

state_map(token, shard_num, pid)