Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // DiscordToken holds the API Token for discord. DiscordToken string // DiscordAppID holds the application ID for the bot. DiscordAppID string // DiscordGuildID holds a GuildID to restring the bot to a single guild. DiscordGuildID string // OpenAIKey holds the API key for OpenAI. OpenAIKey string // GoogleAPIKey holds the API key for Google. GoogleAPIKey string // AdminUserID holds primary admin's DiscordID AdminUserID string // EIUserID holds the DiscordID used for EI API calls requiring Ultra (Periodicals) EIUserID string // EIUserIDBasic holds the DiscordID used for non-Ultra responses EIUserIDBasic string // AdminUsers holds a list of DiscordIDs for other admins AdminUsers []string // TestMode is true if the bot is running in test mode. TestMode bool // DevBotAppID is the application ID for the development bot. DevBotAppID string // FeatureFlags is a list of feature flags for the bot. FeatureFlags []string // EventsURL is the URL for the carpet-wasmegg events page. EventsURL string // RocketsURL is the URL for the carpet-wasmegg rockets page]. RocketsURL string // GistToken is the token used to access the gist. GistToken string // GistID is the ID of the gist used for storage. GistID string // BannerPath is the path to the banner image and font files. BannerPath string // BannerOutputPath is the path where the compsited banner image will be saved. BannerOutputPath string // BannerURL is the URL to the banner image. BannerURL string // DevelopmentStaff is a list of user IDs for development staff. DevelopmentStaff []string // Key is the encryption key used for encrypting sensitive data. Key string )
Functions ¶
func DecryptCombined ¶
DecryptCombined performs AES-GCM decryption on a combined byte slice. It splits the nonce from the ciphertext and then decrypts the data.
func EncryptAndCombine ¶
EncryptAndCombine performs AES-GCM encryption and returns the nonce and ciphertext combined into a single byte slice.
func GenerateKey ¶
GenerateKey creates a new, random 32-byte key for AES-256.
func IsDevBot ¶
func IsDevBot() bool
IsDevBot returns true if the bot is running in development mode.
func ReadConfig ¶
ReadConfig will load the configuration files for API tokens.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.