1
0
Fork 0
mirror of https://github.com/diamondburned/arikawa.git synced 2024-11-28 09:42:58 +00:00
arikawa/discord/user.go

48 lines
898 B
Go
Raw Normal View History

package discord
2020-01-02 05:39:52 +00:00
type User struct {
2020-01-04 04:19:24 +00:00
ID Snowflake `json:"id,string"`
Username string `json:"username"`
Discriminator string `json:"discriminator"`
Avatar Hash `json:"avatar"`
2020-01-02 05:39:52 +00:00
// These fields may be omitted
Bot bool `json:"bot,omitempty"`
MFA bool `json:"mfa_enabled,omitempty"`
DiscordSystem bool `json:"system,omitempty"`
EmailVerified bool `json:"verified,omitempty"`
Locale string `json:"locale,omitempty"`
Email string `json:"email,omitempty"`
Flags UserFlags `json:"flags,omitempty"`
2020-01-04 04:19:24 +00:00
Nitro UserNitro `json:"premium_type,omitempty"`
2020-01-02 05:39:52 +00:00
}
type UserFlags uint16
const (
NoFlag UserFlags = 0
DiscordEmployee UserFlags = 1 << iota
DiscordPartner
HypeSquadEvents
BugHunter
HouseBravery
HouseBrilliance
HouseBalance
EarlySupporter
TeamUser
System
)
2020-01-04 04:19:24 +00:00
type UserNitro uint8
2020-01-02 05:39:52 +00:00
const (
2020-01-04 04:19:24 +00:00
NoUserNitro UserNitro = iota
2020-01-02 05:39:52 +00:00
NitroClassic
NitroFull
)