Documentation ¶
Index ¶
- type Attachment
- type Channel
- type Embed
- type Emoji
- type Event
- type Game
- type Guild
- type GuildBan
- type GuildEmojisUpdate
- type GuildIntegrationsUpdate
- type GuildParams
- type GuildRole
- type GuildRoleDelete
- type Handshake
- type HandshakeProperties
- type ICEServer
- type Invite
- type Member
- type Message
- type MessageAck
- type PermissionOverwrite
- type Presence
- type PresenceUpdate
- type PresencesReplace
- type RateLimit
- type ReadState
- type Ready
- type Resume
- type Resumed
- type Role
- type Settings
- type TypingStart
- type User
- type UserGuildSettings
- type UserGuildSettingsChannelOverride
- func (v UserGuildSettingsChannelOverride) MarshalEasyJSON(w *jwriter.Writer)
- func (v UserGuildSettingsChannelOverride) MarshalJSON() ([]byte, error)
- func (v *UserGuildSettingsChannelOverride) UnmarshalEasyJSON(l *jlexer.Lexer)
- func (v *UserGuildSettingsChannelOverride) UnmarshalJSON(data []byte) error
- type UserSettingsUpdate
- type VerificationLevel
- type VoiceICE
- type VoiceRegion
- type VoiceServerUpdate
- type VoiceState
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Attachment ¶
type Attachment struct { ID string `json:"id"` URL string `json:"url"` ProxyURL string `json:"proxy_url"` Filename string `json:"filename"` Width int `json:"width"` Height int `json:"height"` Size int `json:"size"` }
An Attachment stores data for message attachments.
func (Attachment) MarshalEasyJSON ¶
func (v Attachment) MarshalEasyJSON(w *jwriter.Writer)
func (Attachment) MarshalJSON ¶
func (v Attachment) MarshalJSON() ([]byte, error)
func (*Attachment) UnmarshalEasyJSON ¶
func (v *Attachment) UnmarshalEasyJSON(l *jlexer.Lexer)
func (*Attachment) UnmarshalJSON ¶
func (v *Attachment) UnmarshalJSON(data []byte) error
type Channel ¶
type Channel struct { ID string `json:"id"` GuildID string `json:"guild_id"` Name string `json:"name"` Topic string `json:"topic"` Type string `json:"type"` LastMessageID string `json:"last_message_id"` Position int `json:"position"` Bitrate int `json:"bitrate"` IsPrivate bool `json:"is_private"` Recipient *User `json:"recipient"` Messages []*Message `json:"-"` PermissionOverwrites []*PermissionOverwrite `json:"permission_overwrites"` }
A Channel holds all data related to an individual Discord channel.
func (Channel) MarshalEasyJSON ¶
func (Channel) MarshalJSON ¶
func (*Channel) UnmarshalEasyJSON ¶
func (*Channel) UnmarshalJSON ¶
type Embed ¶
type Embed struct { URL string `json:"url"` Type string `json:"type"` Title string `json:"title"` Description string `json:"description"` Thumbnail *struct { URL string `json:"url"` ProxyURL string `json:"proxy_url"` Width int `json:"width"` Height int `json:"height"` } `json:"thumbnail"` Provider *struct { URL string `json:"url"` Name string `json:"name"` } `json:"provider"` Author *struct { URL string `json:"url"` Name string `json:"name"` } `json:"author"` Video *struct { URL string `json:"url"` Width int `json:"width"` Height int `json:"height"` } `json:"video"` }
An Embed stores data for message embeds.
func (Embed) MarshalEasyJSON ¶
func (Embed) MarshalJSON ¶
func (*Embed) UnmarshalEasyJSON ¶
func (*Embed) UnmarshalJSON ¶
type Emoji ¶
type Emoji struct { ID string `json:"id"` Name string `json:"name"` Roles []string `json:"roles"` Managed bool `json:"managed"` RequireColons bool `json:"require_colons"` }
Emoji struct holds data related to Emoji's
func (Emoji) MarshalEasyJSON ¶
func (Emoji) MarshalJSON ¶
func (*Emoji) UnmarshalEasyJSON ¶
func (*Emoji) UnmarshalJSON ¶
type Event ¶
type Event struct { Type string `json:"t"` State int `json:"s"` Operation int `json:"op"` Direction int `json:"dir"` RawData json.RawMessage `json:"d"` Struct interface{} `json:"-"` }
An Event provides a basic initial struct for all websocket event.
func (Event) MarshalEasyJSON ¶
func (Event) MarshalJSON ¶
func (*Event) UnmarshalEasyJSON ¶
func (*Event) UnmarshalJSON ¶
type Game ¶
type Game struct {
Name string `json:"name"`
}
A Game struct holds the name of the "playing .." game for a user
func (Game) MarshalEasyJSON ¶
func (Game) MarshalJSON ¶
func (*Game) UnmarshalEasyJSON ¶
func (*Game) UnmarshalJSON ¶
type Guild ¶
type Guild struct { ID string `json:"id"` Name string `json:"name"` Icon string `json:"icon"` Region string `json:"region"` AfkChannelID string `json:"afk_channel_id"` EmbedChannelID string `json:"embed_channel_id"` OwnerID string `json:"owner_id"` JoinedAt string `json:"joined_at"` // make this a timestamp Splash string `json:"splash"` AfkTimeout int `json:"afk_timeout"` VerificationLevel VerificationLevel `json:"verification_level"` EmbedEnabled bool `json:"embed_enabled"` Large bool `json:"large"` // ?? Roles []*Role `json:"roles"` Emojis []*Emoji `json:"emojis"` Members []*Member `json:"members"` Presences []*Presence `json:"presences"` Channels []*Channel `json:"channels"` VoiceStates []*VoiceState `json:"voice_states"` }
A Guild holds all data related to a specific Discord Guild. Guilds are also sometimes referred to as Servers in the Discord client.
func (Guild) MarshalEasyJSON ¶
func (Guild) MarshalJSON ¶
func (*Guild) UnmarshalEasyJSON ¶
func (*Guild) UnmarshalJSON ¶
type GuildBan ¶
A GuildBan stores data for a guild ban.
func (GuildBan) MarshalEasyJSON ¶
func (GuildBan) MarshalJSON ¶
func (*GuildBan) UnmarshalEasyJSON ¶
func (*GuildBan) UnmarshalJSON ¶
type GuildEmojisUpdate ¶
A GuildEmojisUpdate stores data for a guild emoji update event.
func (GuildEmojisUpdate) MarshalEasyJSON ¶
func (v GuildEmojisUpdate) MarshalEasyJSON(w *jwriter.Writer)
func (GuildEmojisUpdate) MarshalJSON ¶
func (v GuildEmojisUpdate) MarshalJSON() ([]byte, error)
func (*GuildEmojisUpdate) UnmarshalEasyJSON ¶
func (v *GuildEmojisUpdate) UnmarshalEasyJSON(l *jlexer.Lexer)
func (*GuildEmojisUpdate) UnmarshalJSON ¶
func (v *GuildEmojisUpdate) UnmarshalJSON(data []byte) error
type GuildIntegrationsUpdate ¶
type GuildIntegrationsUpdate struct {
GuildID string `json:"guild_id"`
}
A GuildIntegrationsUpdate stores data for the guild integrations update websocket event.
func (GuildIntegrationsUpdate) MarshalEasyJSON ¶
func (v GuildIntegrationsUpdate) MarshalEasyJSON(w *jwriter.Writer)
func (GuildIntegrationsUpdate) MarshalJSON ¶
func (v GuildIntegrationsUpdate) MarshalJSON() ([]byte, error)
func (*GuildIntegrationsUpdate) UnmarshalEasyJSON ¶
func (v *GuildIntegrationsUpdate) UnmarshalEasyJSON(l *jlexer.Lexer)
func (*GuildIntegrationsUpdate) UnmarshalJSON ¶
func (v *GuildIntegrationsUpdate) UnmarshalJSON(data []byte) error
type GuildParams ¶
type GuildParams struct { Name string `json:"name"` Region string `json:"region"` VerificationLevel *VerificationLevel `json:"verification_level"` }
A GuildParams stores all the data needed to update discord guild settings
func (GuildParams) MarshalEasyJSON ¶
func (v GuildParams) MarshalEasyJSON(w *jwriter.Writer)
func (GuildParams) MarshalJSON ¶
func (v GuildParams) MarshalJSON() ([]byte, error)
func (*GuildParams) UnmarshalEasyJSON ¶
func (v *GuildParams) UnmarshalEasyJSON(l *jlexer.Lexer)
func (*GuildParams) UnmarshalJSON ¶
func (v *GuildParams) UnmarshalJSON(data []byte) error
type GuildRole ¶
A GuildRole stores data for guild role websocket events.
func (GuildRole) MarshalEasyJSON ¶
func (GuildRole) MarshalJSON ¶
func (*GuildRole) UnmarshalEasyJSON ¶
func (*GuildRole) UnmarshalJSON ¶
type GuildRoleDelete ¶
A GuildRoleDelete stores data for the guild role delete websocket event.
func (GuildRoleDelete) MarshalEasyJSON ¶
func (v GuildRoleDelete) MarshalEasyJSON(w *jwriter.Writer)
func (GuildRoleDelete) MarshalJSON ¶
func (v GuildRoleDelete) MarshalJSON() ([]byte, error)
func (*GuildRoleDelete) UnmarshalEasyJSON ¶
func (v *GuildRoleDelete) UnmarshalEasyJSON(l *jlexer.Lexer)
func (*GuildRoleDelete) UnmarshalJSON ¶
func (v *GuildRoleDelete) UnmarshalJSON(data []byte) error
type Handshake ¶
type Handshake struct { Token string `json:"token"` Properties HandshakeProperties `json:"properties"` Compress bool `json:"compress"` LargeThreshold int `json:"large_threshold"` }
Handshake is sent initially on the first connection to the server.
func (Handshake) MarshalEasyJSON ¶
func (Handshake) MarshalJSON ¶
func (*Handshake) UnmarshalEasyJSON ¶
func (*Handshake) UnmarshalJSON ¶
type HandshakeProperties ¶
type HandshakeProperties struct { OS string `json:"$os"` Browser string `json:"$browser"` Device string `json:"$device"` Referer string `json:"$referer"` ReferringDomain string `json:"$referring_domain"` }
HandhsakeProperties are contained within the handshake and describe the device conntecting to Discord's server.
func (HandshakeProperties) MarshalEasyJSON ¶
func (v HandshakeProperties) MarshalEasyJSON(w *jwriter.Writer)
func (HandshakeProperties) MarshalJSON ¶
func (v HandshakeProperties) MarshalJSON() ([]byte, error)
func (*HandshakeProperties) UnmarshalEasyJSON ¶
func (v *HandshakeProperties) UnmarshalEasyJSON(l *jlexer.Lexer)
func (*HandshakeProperties) UnmarshalJSON ¶
func (v *HandshakeProperties) UnmarshalJSON(data []byte) error
type ICEServer ¶
type ICEServer struct { URL string `json:"url"` Username string `json:"username"` Credential string `json:"credential"` }
A ICEServer stores data for a specific voice ICE server.
func (ICEServer) MarshalEasyJSON ¶
func (ICEServer) MarshalJSON ¶
func (*ICEServer) UnmarshalEasyJSON ¶
func (*ICEServer) UnmarshalJSON ¶
type Invite ¶
type Invite struct { Guild *Guild `json:"guild"` Channel *Channel `json:"channel"` Inviter *User `json:"inviter"` Code string `json:"code"` CreatedAt string `json:"created_at"` // TODO make timestamp MaxAge int `json:"max_age"` Uses int `json:"uses"` MaxUses int `json:"max_uses"` XkcdPass bool `json:"xkcdpass"` Revoked bool `json:"revoked"` Temporary bool `json:"temporary"` }
A Invite stores all data related to a specific Discord Guild or Channel invite.
func (Invite) MarshalEasyJSON ¶
func (Invite) MarshalJSON ¶
func (*Invite) UnmarshalEasyJSON ¶
func (*Invite) UnmarshalJSON ¶
type Member ¶
type Member struct { GuildID string `json:"guild_id"` JoinedAt string `json:"joined_at"` Deaf bool `json:"deaf"` Mute bool `json:"mute"` User *User `json:"user"` Roles []string `json:"roles"` }
A Member stores user information for Guild members.
func (Member) MarshalEasyJSON ¶
func (Member) MarshalJSON ¶
func (*Member) UnmarshalEasyJSON ¶
func (*Member) UnmarshalJSON ¶
type Message ¶
type Message struct { ID string `json:"id"` ChannelID string `json:"channel_id"` Content string `json:"content"` Timestamp string `json:"timestamp"` EditedTimestamp string `json:"edited_timestamp"` Tts bool `json:"tts"` MentionEveryone bool `json:"mention_everyone"` Author *User `json:"author"` Attachments []*Attachment `json:"attachments"` Embeds []*Embed `json:"embeds"` Mentions []*User `json:"mentions"` }
A Message stores all data related to a specific Discord message.
func (Message) MarshalEasyJSON ¶
func (Message) MarshalJSON ¶
func (*Message) UnmarshalEasyJSON ¶
func (*Message) UnmarshalJSON ¶
type MessageAck ¶
type MessageAck struct { MessageID string `json:"message_id"` ChannelID string `json:"channel_id"` }
A MessageAck stores data for the message ack websocket event.
func (MessageAck) MarshalEasyJSON ¶
func (v MessageAck) MarshalEasyJSON(w *jwriter.Writer)
func (MessageAck) MarshalJSON ¶
func (v MessageAck) MarshalJSON() ([]byte, error)
func (*MessageAck) UnmarshalEasyJSON ¶
func (v *MessageAck) UnmarshalEasyJSON(l *jlexer.Lexer)
func (*MessageAck) UnmarshalJSON ¶
func (v *MessageAck) UnmarshalJSON(data []byte) error
type PermissionOverwrite ¶
type PermissionOverwrite struct { ID string `json:"id"` Type string `json:"type"` Deny int `json:"deny"` Allow int `json:"allow"` }
A PermissionOverwrite holds permission overwrite data for a Channel
func (PermissionOverwrite) MarshalEasyJSON ¶
func (v PermissionOverwrite) MarshalEasyJSON(w *jwriter.Writer)
func (PermissionOverwrite) MarshalJSON ¶
func (v PermissionOverwrite) MarshalJSON() ([]byte, error)
func (*PermissionOverwrite) UnmarshalEasyJSON ¶
func (v *PermissionOverwrite) UnmarshalEasyJSON(l *jlexer.Lexer)
func (*PermissionOverwrite) UnmarshalJSON ¶
func (v *PermissionOverwrite) UnmarshalJSON(data []byte) error
type Presence ¶
type Presence struct { User *User `json:"user"` Status string `json:"status"` Game *Game `json:"game"` }
A Presence stores the online, offline, or idle and game status of Guild members.
func (Presence) MarshalEasyJSON ¶
func (Presence) MarshalJSON ¶
func (*Presence) UnmarshalEasyJSON ¶
func (*Presence) UnmarshalJSON ¶
type PresenceUpdate ¶
type PresenceUpdate struct { Status string `json:"status"` GuildID string `json:"guild_id"` Roles []string `json:"roles"` User *User `json:"user"` Game *Game `json:"game"` }
A PresenceUpdate stores data for the presence update websocket event.
func (PresenceUpdate) MarshalEasyJSON ¶
func (v PresenceUpdate) MarshalEasyJSON(w *jwriter.Writer)
func (PresenceUpdate) MarshalJSON ¶
func (v PresenceUpdate) MarshalJSON() ([]byte, error)
func (*PresenceUpdate) UnmarshalEasyJSON ¶
func (v *PresenceUpdate) UnmarshalEasyJSON(l *jlexer.Lexer)
func (*PresenceUpdate) UnmarshalJSON ¶
func (v *PresenceUpdate) UnmarshalJSON(data []byte) error
type PresencesReplace ¶
type PresencesReplace []*Presence
PresencesReplace is an array of Presences for an event.
func (*PresencesReplace) UnmarshalJSON ¶
func (p *PresencesReplace) UnmarshalJSON(b []byte) error
type RateLimit ¶
type RateLimit struct { Bucket string `json:"bucket"` Message string `json:"message"` RetryAfter time.Duration `json:"retry_after"` }
A RateLimit struct holds information related to a specific rate limit.
func (RateLimit) MarshalEasyJSON ¶
func (RateLimit) MarshalJSON ¶
func (*RateLimit) UnmarshalEasyJSON ¶
func (*RateLimit) UnmarshalJSON ¶
type ReadState ¶
type ReadState struct { MentionCount int `json:"mention_count"` LastMessageID string `json:"last_message_id"` ID string `json:"id"` }
A ReadState stores data on the read state of channels.
func (ReadState) MarshalEasyJSON ¶
func (ReadState) MarshalJSON ¶
func (*ReadState) UnmarshalEasyJSON ¶
func (*ReadState) UnmarshalJSON ¶
type Ready ¶
type Ready struct { Version int `json:"v"` SessionID string `json:"session_id"` HeartbeatInterval uint `json:"heartbeat_interval"` User *User `json:"user"` ReadState []*ReadState `json:"read_state"` PrivateChannels []*Channel `json:"private_channels"` Guilds []*Guild `json:"guilds"` }
A Ready stores all data for the websocket READY event.
func (Ready) MarshalEasyJSON ¶
func (Ready) MarshalJSON ¶
func (*Ready) UnmarshalEasyJSON ¶
func (*Ready) UnmarshalJSON ¶
type Resume ¶
type Resume struct { Token string `json:"token"` SessionID string `json:"session_id"` Sequence uint64 `json:"seq"` }
Resume can be sent over the websocket to continue an existing session.
func (Resume) MarshalEasyJSON ¶
func (Resume) MarshalJSON ¶
func (*Resume) UnmarshalEasyJSON ¶
func (*Resume) UnmarshalJSON ¶
type Resumed ¶
type Resumed struct {
HeartbeatInterval uint `json:"heartbeat_interval"`
}
Resumed is received after a successful Resume packet is sent.
func (Resumed) MarshalEasyJSON ¶
func (Resumed) MarshalJSON ¶
func (*Resumed) UnmarshalEasyJSON ¶
func (*Resumed) UnmarshalJSON ¶
type Role ¶
type Role struct { ID string `json:"id"` Name string `json:"name"` Managed bool `json:"managed"` Hoist bool `json:"hoist"` Color int `json:"color"` Position int `json:"position"` Permissions int `json:"permissions"` }
A Role stores information about Discord guild member roles.
func (Role) MarshalEasyJSON ¶
func (Role) MarshalJSON ¶
func (*Role) UnmarshalEasyJSON ¶
func (*Role) UnmarshalJSON ¶
type Settings ¶
type Settings struct { RenderEmbeds bool `json:"render_embeds"` InlineEmbedMedia bool `json:"inline_embed_media"` EnableTtsCommand bool `json:"enable_tts_command"` MessageDisplayCompact bool `json:"message_display_compact"` ShowCurrentGame bool `json:"show_current_game"` Locale string `json:"locale"` Theme string `json:"theme"` MutedChannels []string `json:"muted_channels"` }
A Settings stores data for a specific users Discord client settings.
func (Settings) MarshalEasyJSON ¶
func (Settings) MarshalJSON ¶
func (*Settings) UnmarshalEasyJSON ¶
func (*Settings) UnmarshalJSON ¶
type TypingStart ¶
type TypingStart struct { UserID string `json:"user_id"` ChannelID string `json:"channel_id"` Timestamp int `json:"timestamp"` }
A TypingStart stores data for the typing start websocket event.
func (TypingStart) MarshalEasyJSON ¶
func (v TypingStart) MarshalEasyJSON(w *jwriter.Writer)
func (TypingStart) MarshalJSON ¶
func (v TypingStart) MarshalJSON() ([]byte, error)
func (*TypingStart) UnmarshalEasyJSON ¶
func (v *TypingStart) UnmarshalEasyJSON(l *jlexer.Lexer)
func (*TypingStart) UnmarshalJSON ¶
func (v *TypingStart) UnmarshalJSON(data []byte) error
type User ¶
type User struct { ID string `json:"id"` Email string `json:"email"` Username string `json:"username"` Avatar string `json:"Avatar"` Discriminator string `json:"discriminator"` Token string `json:"token"` Verified bool `json:"verified"` Bot bool `json:"bot"` }
A User stores all data for an individual Discord user.
func (User) MarshalEasyJSON ¶
func (User) MarshalJSON ¶
func (*User) UnmarshalEasyJSON ¶
func (*User) UnmarshalJSON ¶
type UserGuildSettings ¶
type UserGuildSettings struct { SupressEveryone bool `json:"suppress_everyone"` Muted bool `json:"muted"` MobilePush bool `json:"mobile_push"` MessageNotifications int `json:"message_notifications"` GuildID string `json:"guild_id"` ChannelOverrides []*UserGuildSettingsChannelOverride `json:"channel_overrides"` }
A UserGuildSettings stores data for a users guild settings.
func (UserGuildSettings) MarshalEasyJSON ¶
func (v UserGuildSettings) MarshalEasyJSON(w *jwriter.Writer)
func (UserGuildSettings) MarshalJSON ¶
func (v UserGuildSettings) MarshalJSON() ([]byte, error)
func (*UserGuildSettings) UnmarshalEasyJSON ¶
func (v *UserGuildSettings) UnmarshalEasyJSON(l *jlexer.Lexer)
func (*UserGuildSettings) UnmarshalJSON ¶
func (v *UserGuildSettings) UnmarshalJSON(data []byte) error
type UserGuildSettingsChannelOverride ¶
type UserGuildSettingsChannelOverride struct { Muted bool `json:"muted"` MessageNotifications int `json:"message_notifications"` ChannelID string `json:"channel_id"` }
A UserGuildSettingsChannelOverride stores data for a channel override for a users guild settings.
func (UserGuildSettingsChannelOverride) MarshalEasyJSON ¶
func (v UserGuildSettingsChannelOverride) MarshalEasyJSON(w *jwriter.Writer)
func (UserGuildSettingsChannelOverride) MarshalJSON ¶
func (v UserGuildSettingsChannelOverride) MarshalJSON() ([]byte, error)
func (*UserGuildSettingsChannelOverride) UnmarshalEasyJSON ¶
func (v *UserGuildSettingsChannelOverride) UnmarshalEasyJSON(l *jlexer.Lexer)
func (*UserGuildSettingsChannelOverride) UnmarshalJSON ¶
func (v *UserGuildSettingsChannelOverride) UnmarshalJSON(data []byte) error
type UserSettingsUpdate ¶
type UserSettingsUpdate map[string]interface{}
UserSettingsUpdate is a map for an event.
func (*UserSettingsUpdate) UnmarshalJSON ¶
func (u *UserSettingsUpdate) UnmarshalJSON(b []byte) error
type VerificationLevel ¶
type VerificationLevel int
VerificationLevel type defination
const ( VerificationLevelNone VerificationLevel = iota VerificationLevelLow VerificationLevelMedium VerificationLevelHigh )
Constants for VerificationLevel levels from 0 to 3 inclusive
type VoiceICE ¶
A VoiceICE stores data for voice ICE servers.
func (VoiceICE) MarshalEasyJSON ¶
func (VoiceICE) MarshalJSON ¶
func (*VoiceICE) UnmarshalEasyJSON ¶
func (*VoiceICE) UnmarshalJSON ¶
type VoiceRegion ¶
type VoiceRegion struct { ID string `json:"id"` Name string `json:"name"` Hostname string `json:"sample_hostname"` Port int `json:"sample_port"` }
A VoiceRegion stores data for a specific voice region server.
func (VoiceRegion) MarshalEasyJSON ¶
func (v VoiceRegion) MarshalEasyJSON(w *jwriter.Writer)
func (VoiceRegion) MarshalJSON ¶
func (v VoiceRegion) MarshalJSON() ([]byte, error)
func (*VoiceRegion) UnmarshalEasyJSON ¶
func (v *VoiceRegion) UnmarshalEasyJSON(l *jlexer.Lexer)
func (*VoiceRegion) UnmarshalJSON ¶
func (v *VoiceRegion) UnmarshalJSON(data []byte) error
type VoiceServerUpdate ¶
type VoiceServerUpdate struct { Token string `json:"token"` GuildID string `json:"guild_id"` Endpoint string `json:"endpoint"` }
A VoiceServerUpdate stores the data received during the Voice Server Update data websocket event. This data is used during the initial Voice Channel join handshaking.
func (VoiceServerUpdate) MarshalEasyJSON ¶
func (v VoiceServerUpdate) MarshalEasyJSON(w *jwriter.Writer)
func (VoiceServerUpdate) MarshalJSON ¶
func (v VoiceServerUpdate) MarshalJSON() ([]byte, error)
func (*VoiceServerUpdate) UnmarshalEasyJSON ¶
func (v *VoiceServerUpdate) UnmarshalEasyJSON(l *jlexer.Lexer)
func (*VoiceServerUpdate) UnmarshalJSON ¶
func (v *VoiceServerUpdate) UnmarshalJSON(data []byte) error
type VoiceState ¶
type VoiceState struct { UserID string `json:"user_id"` SessionID string `json:"session_id"` ChannelID string `json:"channel_id"` GuildID string `json:"guild_id"` Suppress bool `json:"suppress"` SelfMute bool `json:"self_mute"` SelfDeaf bool `json:"self_deaf"` Mute bool `json:"mute"` Deaf bool `json:"deaf"` }
A VoiceState stores the voice states of Guilds
func (VoiceState) MarshalEasyJSON ¶
func (v VoiceState) MarshalEasyJSON(w *jwriter.Writer)
func (VoiceState) MarshalJSON ¶
func (v VoiceState) MarshalJSON() ([]byte, error)
func (*VoiceState) UnmarshalEasyJSON ¶
func (v *VoiceState) UnmarshalEasyJSON(l *jlexer.Lexer)
func (*VoiceState) UnmarshalJSON ¶
func (v *VoiceState) UnmarshalJSON(data []byte) error