Documentation
¶
Index ¶
- Constants
- func ApplyMuteDeaf(sess *discordgo.Session, guildID, userID string, mute, deaf bool) error
- func ExtractChannelIDFromText(mention string) (string, error)
- func ExtractRoleIDFromText(mention string) (string, error)
- func ExtractUserIDFromText(mention string) (string, error)
- func MentionByChannelID(channelID string) string
- func MentionByUserID(userID string) string
- func ValidateSnowflake(snowflake string) error
- type ModifyTask
- type MuteDeafenSuccessCounts
- type PatchParams
- type UserModify
- type UserModifyRequest
Constants ¶
View Source
const DiscordEpoch = 1420070400000
View Source
const IDLength = 10
Variables ¶
This section is empty.
Functions ¶
func ApplyMuteDeaf ¶
func ExtractChannelIDFromText ¶ added in v0.1.0
func ExtractRoleIDFromText ¶ added in v0.0.23
func ExtractUserIDFromText ¶ added in v0.1.0
func MentionByChannelID ¶ added in v0.0.26
func MentionByUserID ¶ added in v0.0.26
func ValidateSnowflake ¶ added in v0.0.23
Types ¶
type ModifyTask ¶
type ModifyTask struct {
GuildID uint64 `json:"guildID"`
UserID uint64 `json:"userID"`
Parameters PatchParams `json:"parameters"`
TaskID string `json:"taskID"`
}
func NewModifyTask ¶
func NewModifyTask(guildID, userID uint64, params PatchParams) ModifyTask
type MuteDeafenSuccessCounts ¶
type MuteDeafenSuccessCounts struct {
Worker int64 `json:"worker"`
Capture int64 `json:"capture"`
Official int64 `json:"official"`
RateLimit int64 `json:"ratelimit"`
}
a response indicating how the mutes/deafens were issued, and if ratelimits occurred
type PatchParams ¶
type UserModify ¶
type UserModifyRequest ¶
type UserModifyRequest struct {
Premium premium.Tier `json:"premium"`
Users []UserModify `json:"users"`
}
Click to show internal directories.
Click to hide internal directories.