Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Embed ¶
type Embed struct { Title string `json:"title,omitempty"` Description string `json:"description,omitempty"` URL string `json:"url"` Timestamp string `json:"timestamp,omitempty"` Color int `json:"color,omitempty"` Fields []EmbedField `json:"fields"` }
Embed is a json object that represents an embed in a MessageWithEmbed
func (Embed) MarshalEasyJSON ¶ added in v6.2.0
MarshalEasyJSON supports easyjson.Marshaler interface
func (Embed) MarshalJSON ¶ added in v6.2.0
MarshalJSON supports json.Marshaler interface
func (*Embed) UnmarshalEasyJSON ¶ added in v6.2.0
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*Embed) UnmarshalJSON ¶ added in v6.2.0
UnmarshalJSON supports json.Unmarshaler interface
type EmbedField ¶
type EmbedField struct { Name string `json:"name"` Value string `json:"value"` Inline bool `json:"inline"` }
EmbedField is a json object that represents a field in an Embed
func (EmbedField) MarshalEasyJSON ¶ added in v6.2.0
func (v EmbedField) MarshalEasyJSON(w *jwriter.Writer)
MarshalEasyJSON supports easyjson.Marshaler interface
func (EmbedField) MarshalJSON ¶ added in v6.2.0
func (v EmbedField) MarshalJSON() ([]byte, error)
MarshalJSON supports json.Marshaler interface
func (*EmbedField) UnmarshalEasyJSON ¶ added in v6.2.0
func (v *EmbedField) UnmarshalEasyJSON(l *jlexer.Lexer)
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*EmbedField) UnmarshalJSON ¶ added in v6.2.0
func (v *EmbedField) UnmarshalJSON(data []byte) error
UnmarshalJSON supports json.Unmarshaler interface
type EmbedFooter ¶
type EmbedFooter struct {
}EmbedFooter is a json object that represents the footer of an embed
func (EmbedFooter) MarshalEasyJSON ¶ added in v6.2.0
func (v EmbedFooter) MarshalEasyJSON(w *jwriter.Writer)
MarshalEasyJSON supports easyjson.Marshaler interface
func (EmbedFooter) MarshalJSON ¶ added in v6.2.0
func (v EmbedFooter) MarshalJSON() ([]byte, error)
MarshalJSON supports json.Marshaler interface
func (*EmbedFooter) UnmarshalEasyJSON ¶ added in v6.2.0
func (v *EmbedFooter) UnmarshalEasyJSON(l *jlexer.Lexer)
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*EmbedFooter) UnmarshalJSON ¶ added in v6.2.0
func (v *EmbedFooter) UnmarshalJSON(data []byte) error
UnmarshalJSON supports json.Unmarshaler interface
type GatewayResponse ¶
GatewayResponse is the json object received from the discord api when requesting gateway connection information
func (GatewayResponse) MarshalEasyJSON ¶ added in v6.2.0
func (v GatewayResponse) MarshalEasyJSON(w *jwriter.Writer)
MarshalEasyJSON supports easyjson.Marshaler interface
func (GatewayResponse) MarshalJSON ¶ added in v6.2.0
func (v GatewayResponse) MarshalJSON() ([]byte, error)
MarshalJSON supports json.Marshaler interface
func (*GatewayResponse) UnmarshalEasyJSON ¶ added in v6.2.0
func (v *GatewayResponse) UnmarshalEasyJSON(l *jlexer.Lexer)
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*GatewayResponse) UnmarshalJSON ¶ added in v6.2.0
func (v *GatewayResponse) UnmarshalJSON(data []byte) error
UnmarshalJSON supports json.Unmarshaler interface
type Message ¶
Message is the json object that is sent to the discord api to post a plain-text message to a server
func (Message) MarshalEasyJSON ¶ added in v6.2.0
MarshalEasyJSON supports easyjson.Marshaler interface
func (Message) MarshalJSON ¶ added in v6.2.0
MarshalJSON supports json.Marshaler interface
func (*Message) UnmarshalEasyJSON ¶ added in v6.2.0
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*Message) UnmarshalJSON ¶ added in v6.2.0
UnmarshalJSON supports json.Unmarshaler interface
type MessageWithEmbed ¶
type MessageWithEmbed struct { Content string `json:"content"` Tts bool `json:"tts"` Embed Embed `json:"embed"` }
MessageWithEmbed is the json object that is sent to the discord api to post an embed message to a server
func (MessageWithEmbed) MarshalEasyJSON ¶ added in v6.2.0
func (v MessageWithEmbed) MarshalEasyJSON(w *jwriter.Writer)
MarshalEasyJSON supports easyjson.Marshaler interface
func (MessageWithEmbed) MarshalJSON ¶ added in v6.2.0
func (v MessageWithEmbed) MarshalJSON() ([]byte, error)
MarshalJSON supports json.Marshaler interface
func (*MessageWithEmbed) UnmarshalEasyJSON ¶ added in v6.2.0
func (v *MessageWithEmbed) UnmarshalEasyJSON(l *jlexer.Lexer)
UnmarshalEasyJSON supports easyjson.Unmarshaler interface
func (*MessageWithEmbed) UnmarshalJSON ¶ added in v6.2.0
func (v *MessageWithEmbed) UnmarshalJSON(data []byte) error
UnmarshalJSON supports json.Unmarshaler interface