2023-10-19 18:08:38 -04:00
|
|
|
package main
|
|
|
|
|
|
|
|
import "github.com/disgoorg/disgo/discord"
|
|
|
|
|
|
|
|
/*
|
|
|
|
This file is used to store the commands for the bot
|
|
|
|
and will be sent to Discord API on startup
|
|
|
|
|
|
|
|
If you came here expecting to see code for the commands,
|
|
|
|
they are in events/interaction.go
|
|
|
|
*/
|
|
|
|
|
|
|
|
var FALSE = false
|
|
|
|
|
|
|
|
func commandsJSON() (commandList []discord.ApplicationCommandCreate) {
|
|
|
|
commandList = []discord.ApplicationCommandCreate{
|
|
|
|
discord.SlashCommandCreate{
|
|
|
|
Name: "host-stats",
|
2023-10-20 01:18:13 -04:00
|
|
|
Description: "Host statistics like OS, CPU Usage, etc",
|
2023-10-19 18:08:38 -04:00
|
|
|
},
|
|
|
|
discord.SlashCommandCreate{
|
2023-10-20 01:18:13 -04:00
|
|
|
Name: "repository",
|
|
|
|
Description: "A casual button that forwards you to the bot's repository",
|
|
|
|
},
|
|
|
|
discord.SlashCommandCreate{
|
|
|
|
Name: "config",
|
|
|
|
Description: "View or change the bot's configuration",
|
|
|
|
DMPermission: &FALSE,
|
|
|
|
Options: []discord.ApplicationCommandOption{
|
|
|
|
discord.ApplicationCommandOptionChannel{
|
|
|
|
Name: "ban-records",
|
|
|
|
Description: "Set a channel that will be used to display ban records via Google Sheets",
|
|
|
|
Required: false,
|
|
|
|
ChannelTypes: []discord.ChannelType{
|
|
|
|
discord.ChannelTypeGuildText,
|
|
|
|
discord.ChannelTypeGuildForum,
|
|
|
|
discord.ChannelTypeGuildPublicThread,
|
|
|
|
discord.ChannelTypeGuildPrivateThread,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
discord.ApplicationCommandOptionString{
|
|
|
|
Name: "google-sheets",
|
|
|
|
Description: "Set the Google Sheets URL that will be used to display ban records",
|
|
|
|
Required: false,
|
|
|
|
},
|
|
|
|
},
|
2023-10-19 18:08:38 -04:00
|
|
|
},
|
|
|
|
}
|
|
|
|
return commandList
|
|
|
|
}
|