slash_commands

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2022 License: AGPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EditResponse

EditResponse edits the passed interactions original response with the passed discordgo.WebhooKParams. This allows things like sending a notice that something will take some time and then edit the message to tell the user that the action has been done.

func GenerateEphemeralInteractionResponseTemplate

func GenerateEphemeralInteractionResponseTemplate(
	name string,
	description string,
) *discordgo.InteractionResponseData

GenerateEphemeralInteractionResponseTemplate creates a prefilled discordgo.InteractionResponseData that is prepared to be filled with specific data or errors. In addition, the discordgo.InteractionResponseData will be ephemeral and therefore only show to the user that triggered the interaction.

The template will get an empty embed with the specified name and description.

func GenerateInteractionResponseTemplate

func GenerateInteractionResponseTemplate(
	name string,
	description string,
) *discordgo.InteractionResponseData

GenerateInteractionResponseTemplate creates a prefilled discordgo.InteractionResponseData that is prepared to be filled with specific data or errors.

The template will get an empty embed with the specified name and description. The default color of the auto-generated embed equals the one defined under api.DefaultEmbedColor

func Respond

Respond to the target interaction with the passed discordgo.InteractionResponseData as a message in the channel where the interaction has been triggered.

Types

This section is empty.

Jump to

Keyboard shortcuts

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