-
Notifications
You must be signed in to change notification settings - Fork 3
Config
AstralBot uses multiple locations for different configuration purposes:
The most basic options for AstralBot are stored in the config file in the usual location (the config folder). It has the following options:
Type: String
Default: ""
Discord token for the bot. Can also be supplied via DISCORD_TOKEN environment variable.
Type: String
Default: ""
URL to the webhook where the messages will be sent from. Can be left empty, in which case the Bot will choose the first one available and create one if none exist.
Type: boolean
Default: true
Whether to use the configured webhook for sending messages from MC to Discord.
Type: boolean
Default: false
Whether to imitate user's linked Discord accounts when sending messages from MC to Discord. This means that the Discord user's avatar will be used instead of their Minecraft Head.
Type: String
Default: "https://mc-heads.net/head/{{uuid}}"
API that returns images based on Minecraft users. {{uuid}} and {{name}} can be used. By default, this uses the MCHeads API.
Type: boolean
Default: false
AstralBot can be used for whitelisting in two different configurations. Either as an option for being whitelisted or as a requirement for being whitelisted. By default, it's configured as an option.
See:
Type: String
Default: ""
The discord link where the user is supposed to run the /link command to whitelist themselves.
See:
Type: long
Default: -1
Numeric ID of the Discord text channel where chat messages are synchronized.
For convenience, this is set when executing the /chatsync command.
See:
Type: long
Default: -1
Numeric ID of the Discord guild (server) where the chat messages are synchronized.
For convenience, this is set when executing the /chatsync command.
See:
Type: long
Default: -1
Numeric ID of the Discord role that is given to linked accounts.
For convenience, this is configurable with the /linkrole command.
See:
Type: boolean
Default: true
Discord messages that are synchronized into the Minecraft chat can be formatted with a click event that links to the corresponding message on Discord. This is enabled by default.
Type: boolean
Default: true
Discord messages can have so-called Embeds, for example sent images, website previews, etc.
AstralBot can format these by including them after the message content.
See:
Type: boolean
Default: true
If the handling of Embeds is enabled, AstralBot can format them into clickable links. This is enabled by default, but not every Embed is turned into a clickable link as some URLs are blocked.
See:
Type: List<String>
Default: List of certain NSFW URLs
AstralBot can make links into clickable parts of a Minecraft chat message. The URL blocklist exists to prevent certain URLs from being handled.
See:
Type: List<String>
Default: List containing the name of all commands the bot supports
As a server owner you may want to disable certain commands. To do so, remove
its name from this list and run /reload.
See:
In the astralbot folder inside the root directory of the server installation is a file called whitelist.txt that
contains the template for the message shown to users when they're not whitelisted yet.
There are three placeholders that will be replaced with the respective values:
-
{{USER}}: the Minecraft username that tried to join and will get the message -
{{DISCORD}}: the link to the Discord server as configured indiscordLink -
{{CODE}}: the link code the user needs to use with the/linkcommand on Discord
The rest of the text used in AstralBot can be configured in astralbot-text.toml. The comments in that file will explain
all the possible options.