interactions

package
v0.0.0-...-b4c7db4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 22, 2021 License: ISC Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func VerifyRequest

func VerifyRequest(h http.Header, body []byte, key ed25519.PublicKey) bool

VerifyRequest verifies that a request with the given headers and body is from Discord itself.

Types

type Client

type Client struct {
	*httputil.Client
	ID discord.AppID
}

func New

func New(appid discord.AppID) *Client

func (*Client) DeleteInitial

func (c *Client) DeleteInitial(tok string) error

func (*Client) DeleteMessage

func (c *Client) DeleteMessage(tok string, id discord.MessageID) error

func (*Client) EditInitial

func (c *Client) EditInitial(tok string, data webhook.EditMessageData) (*discord.Message, error)

func (*Client) EditMessage

func (c *Client) EditMessage(tok string, id discord.MessageID, data webhook.EditMessageData) (*discord.Message, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL