Skip to content
This repository was archived by the owner on Aug 6, 2023. It is now read-only.

Version 0.7

Choose a tag to compare

@bclindner bclindner released this 18 Dec 00:26

No major additions, but some serious QoL improvements:

  • The RESTCommand has had a number of improvements.
    • New options field: headers (map[string]string). This lets you set headers like User-Agent, Authorization, and others to go with each request.
    • New options field: errorMessage (string). If the RESTCommand fails for any reason, you can specify a generic message in the options to respond with in Discord.
    • RESTCommand now logs every request going out and the status of responses coming in. In the event someone's trying to hack your bot via the RESTCommand interface, you'll have some logs. Still, take care in writing proper regular expressions to make it hard or impossible for them.
    • RESTCommands are now cached by default. This shouldn't be too much of a problem, but if the bot starts giving you out-of-date data, you can disable the cache by setting "disableCache": true in the command's option list.
  • Moderate refactor of the source code, allowing for a new command type - ReloadCommand, or reload in the config. This just lets you reload your active config file and re-parse your commands, so you don't have to reset your bot in the event you want to make a small change to your config.
    • If your new config fails, don't worry - it won't break the bot, it'll just continue using the previous configuration.
  • Some improvements to the IASIPCommand - it now allows for multi-line messages. It ignores said newlines, and tries to find line breaks manually, but now multi-line commands will at least work.