Documentation ¶
Overview ¶
Package mockrest provides functionality for creating an http.RoundTripper that can be used with an *http.Client in a *discordgo.Session to handle Discord REST API endpoints and maintain state with a given *discordgo.State.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewTransport ¶
func NewTransport(state *discordgo.State) http.RoundTripper
NewTransport returns a new http.RoundTripper that handles requests with respect to the given state.
Types ¶
type RoundTripper ¶
type RoundTripper struct {
// contains filtered or unexported fields
}
RoundTripper satisfies http.RoundTripper and handles requests using its internal *discordgo.State.
Click to show internal directories.
Click to hide internal directories.