class

Worker::DiscordClient

Inherits Reference < Object

Discord facade

Constants

INTENTS = ((Discord::Gateway::Intents::Guilds | Discord::Gateway::Intents::GuildVoiceStates) | Discord::Gateway::Intents::GuildMessages) | Discord::Gateway::Intents::DirectMessages
Log = Worker::Log.for("discord_client")
STATUS_UPDATE_INTERVAL = 15.minutes
VOICE_RECONNECTION_AWAIT = 1.second

Constructors

new(worker : Worker)
Source

Instance methods

delete_message(channel_id : UInt64, message_id : UInt64) : Nil
Source
log(message : String) : Nil
Source
role_id_by_name(role_name : String) : UInt64
Source
role_name(role_id : UInt64) : String
Source
send_dm(user_id : UInt64, text : String) : UInt64 | Nil
Source
server_administrator_roles_ids(server_id : UInt64) : Array(UInt64)
Source
server_name(server_id : UInt64) : String
Source
server_owner_id(server_id : UInt64) : UInt64
Source
servers_count
Source
stop
Source
user_voice_channel_id(server_id : UInt64, user_id : UInt64) : UInt64 | Nil
Source
voice_channel_users(server_id : UInt64, voice_channel_id : UInt64) : Array(UInt64)
Source
voice_client(server_id : UInt64) : VoiceClient | Nil
Source
voice_state_update(server_id : UInt64, channel_id : UInt64 | Nil) : Nil
Source

Nested types