commands

package
v0.0.0-...-77c43e3 Latest Latest
Warning

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

Go to latest
Published: Sep 6, 2023 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DdgCommand = discordgo.ApplicationCommand{
	Name:        "ddg",
	Description: "Duckduckgo main command",
	Options: []*discordgo.ApplicationCommandOption{
		{
			Name:        "search",
			Description: "Search",
			Type:        discordgo.ApplicationCommandOptionString,
			Required:    true,
		},
	},
}
View Source
var GoogleCommand = discordgo.ApplicationCommand{
	Name:        "google",
	Description: "Google main command",
	Options: []*discordgo.ApplicationCommandOption{
		{
			Name:        "search",
			Description: "Search",
			Type:        discordgo.ApplicationCommandOptionString,
			Required:    true,
		},
	},
}
View Source
var KarmaCommand = discordgo.ApplicationCommand{
	Name:        "karma",
	Description: "Karma main command",
	Options: []*discordgo.ApplicationCommandOption{
		{
			Name:        "add",
			Description: "add karma",
			Type:        discordgo.ApplicationCommandOptionSubCommand,
			Options: []*discordgo.ApplicationCommandOption{
				{
					Type:        discordgo.ApplicationCommandOptionUser,
					Name:        "user-option",
					Description: "User option",
					Required:    true,
				},
			},
		},
		{
			Name:        "show",
			Description: "show karma",
			Type:        discordgo.ApplicationCommandOptionSubCommand,
			Options: []*discordgo.ApplicationCommandOption{
				{
					Type:        discordgo.ApplicationCommandOptionUser,
					Name:        "user-option",
					Description: "User option",
					Required:    false,
				},
			},
		},
		{
			Name:        "help",
			Description: "help",
			Type:        discordgo.ApplicationCommandOptionSubCommand,
		},
	},
}
View Source
var StartpageCommand = discordgo.ApplicationCommand{
	Name:        "startpage",
	Description: "Startpage main command",
	Options: []*discordgo.ApplicationCommandOption{
		{
			Name:        "search",
			Description: "Search",
			Type:        discordgo.ApplicationCommandOptionString,
			Required:    true,
		},
	},
}
View Source
var TagCommand = discordgo.ApplicationCommand{
	Name:        "tag",
	Description: "Tag main command",
	Options: []*discordgo.ApplicationCommandOption{
		{
			Name:        "add",
			Description: "add tag",
			Type:        discordgo.ApplicationCommandOptionSubCommand,
			Options: []*discordgo.ApplicationCommandOption{
				{
					Type:        discordgo.ApplicationCommandOptionString,
					Name:        "key-option",
					Description: "Key option",
					Required:    true,
				},
				{
					Type:        discordgo.ApplicationCommandOptionString,
					Name:        "content-option",
					Description: "Content option",
					Required:    true,
				},
				{
					Type:        discordgo.ApplicationCommandOptionString,
					Name:        "image-option",
					Description: "Image option",
					Required:    false,
				},
			},
		},
		{
			Name:        "get",
			Description: "get tag",
			Type:        discordgo.ApplicationCommandOptionSubCommand,
			Options: []*discordgo.ApplicationCommandOption{
				{
					Type:        discordgo.ApplicationCommandOptionString,
					Name:        "key-option",
					Description: "Key option",
					Required:    true,
				},
			},
		},
		{
			Name:        "delete",
			Description: "delete tag",
			Type:        discordgo.ApplicationCommandOptionSubCommand,
			Options: []*discordgo.ApplicationCommandOption{
				{
					Type:        discordgo.ApplicationCommandOptionString,
					Name:        "key-option",
					Description: "Key option",
					Required:    true,
				},
			},
		},
		{
			Name:        "list",
			Description: "list tags",
			Type:        discordgo.ApplicationCommandOptionSubCommand,
		},
		{
			Name:        "help",
			Description: "help",
			Type:        discordgo.ApplicationCommandOptionSubCommand,
		},
	},
}

Functions

func DdgCommandHandler

func DdgCommandHandler() func(s *discordgo.Session, i *discordgo.InteractionCreate)

func GetCommandHandlers

func GetCommandHandlers() map[string]func(s *discordgo.Session, i *discordgo.InteractionCreate)

func GetCommands

func GetCommands() []*discordgo.ApplicationCommand

func GoogleCommandHandler

func GoogleCommandHandler() func(s *discordgo.Session, i *discordgo.InteractionCreate)

func KarmaCommandHandler

func KarmaCommandHandler() func(s *discordgo.Session, i *discordgo.InteractionCreate)

func StartpageCommandHandler

func StartpageCommandHandler() func(s *discordgo.Session, i *discordgo.InteractionCreate)

func TagCommandHandler

func TagCommandHandler() func(s *discordgo.Session, i *discordgo.InteractionCreate)

func VersionCommand

func VersionCommand() func(s *discordgo.Session, i *discordgo.InteractionCreate)

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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