discord-kagebot/src/main/resources/config.toml
kageru 7ebafc9958
Completely rewrote config
Added a rawconfig as an intermediate step when parsing the TOML.
This will make nullability much more reliable and also gives me lots of
options in the future. It also broke all tests because reading the
config (not the raw config) now depends on the discord API. :tehe:
2019-06-12 23:43:36 +02:00

78 lines
2.1 KiB
TOML

[system]
serverId = "356414885292277771"
color = "#1793d0"
[localization]
permissionDenied = "You do not have permission to use this command."
# results in <name> says <message>
redirectedMessage = "says"
messageDeleted = "Your message was deleted because it contained a banned word or phrase."
# If this is enabled, every new user will receive a welcome message.
# If the user has disabled their DMs, the fallbackMessage will be sent in the fallbackChannel instead.
# If no fallback channel or message is specified, no fallback will be sent.
[feature.welcome]
enabled = true
fallbackChannel = 555097559023222825
fallbackMessage = "@@ I would like to greet you, but I can’t. :("
# This is a list of pairs where the key is the title and the value the content of the paragraph.
# Do not use empty strings to get empty headings or paragraphs. The discord API rejects those.
[feature.welcome.content]
"Welcome to the Server" = "This is the content of the first paragraph"
"Second paragraph heading" = "Second paragraph content"
[[command]]
trigger = "!ping"
response = "pong"
[[command]]
trigger = "somewhere"
response = "found it"
matchType = "CONTAINS"
[[command]]
trigger = "A.+B"
response = "regex matched"
matchType = "REGEX"
[[command]]
trigger = "answer me"
# this will @mention the user who triggered the command,
# i.e. “@author there you go”
response = "@@ there you go"
[[command]]
trigger = "delet this"
[command.action]
delete = true
[[command]]
trigger = "!restricted"
response = "access granted"
[command.permissions]
hasOneOf = [
"452034011393425409",
"446668543816106004"
]
[[command]]
trigger = "!almostUnrestricted"
response = "access granted"
[command.permissions]
hasNoneOf = ["452034011393425409"]
# redirect every message that starts with !redirect to channel 555097559023222825
[[command]]
trigger = "!redirect"
response = "redirected"
[command.action.redirect]
target = "testchannel"
# the same, but without the original username
[[command]]
trigger = "!anonRedirect"
response = "redirected"
[command.action.redirect]
target = "555097559023222825"
anonymous = true