mirror of
https://github.com/diamondburned/arikawa.git
synced 2024-11-27 09:12:53 +00:00
api: remove InteractionResponseFlags in favor of discord.MessageFlags
See docs: https://discord.com/developers/docs/interactions/receiving-and-responding#interaction-response-object-messages This is an API change. Use the following commands to update your projects: $ gofmt -w -r 'api.InteractionResponseFlags -> discord.MessageFlags' $ gofmt -w -r 'api.EphemeralResponse -> discord.EphemeralMessage'
This commit is contained in:
parent
adce55b02d
commit
eb579c8e94
|
@ -28,14 +28,6 @@ const (
|
||||||
ModalResponse
|
ModalResponse
|
||||||
)
|
)
|
||||||
|
|
||||||
// InteractionResponseFlags implements flags for an
|
|
||||||
// InteractionApplicationCommandCallbackData.
|
|
||||||
//
|
|
||||||
// https://discord.com/developers/docs/interactions/slash-commands#interaction-response-object-interaction-application-command-callback-data-flags
|
|
||||||
type InteractionResponseFlags uint
|
|
||||||
|
|
||||||
const EphemeralResponse InteractionResponseFlags = 64
|
|
||||||
|
|
||||||
type InteractionResponse struct {
|
type InteractionResponse struct {
|
||||||
Type InteractionResponseType `json:"type"`
|
Type InteractionResponseType `json:"type"`
|
||||||
Data *InteractionResponseData `json:"data,omitempty"`
|
Data *InteractionResponseData `json:"data,omitempty"`
|
||||||
|
@ -69,7 +61,8 @@ type InteractionResponseData struct {
|
||||||
// AllowedMentions are the allowed mentions for the message.
|
// AllowedMentions are the allowed mentions for the message.
|
||||||
AllowedMentions *AllowedMentions `json:"allowed_mentions,omitempty"`
|
AllowedMentions *AllowedMentions `json:"allowed_mentions,omitempty"`
|
||||||
// Flags are the interaction application command callback data flags.
|
// Flags are the interaction application command callback data flags.
|
||||||
Flags InteractionResponseFlags `json:"flags,omitempty"`
|
// Only SuppressEmbeds and EphemeralMessage may be set.
|
||||||
|
Flags discord.MessageFlags `json:"flags,omitempty"`
|
||||||
|
|
||||||
// Files represents a list of files to upload. This will not be
|
// Files represents a list of files to upload. This will not be
|
||||||
// JSON-encoded and will only be available through WriteMultipart.
|
// JSON-encoded and will only be available through WriteMultipart.
|
||||||
|
|
Loading…
Reference in a new issue