Bots
Learn how to host Discord bots on Discloud.
π€ What is a "Bot" on Discloud?
On Discloud, a Bot is any application that runs continuously but does not require an external port for access. This typically includes:
π€ Discord Bots (discord.js, discord.py, JDA, etc.)
π¬ Telegram Bots
βοΈ Automation Scripts
β
Requirements
To host a bot, you must meet these criteria:
Any Plan β Bots can be hosted on any plan, including the Free plan (with limitations).
discloud.config β Required for most deployment methods. If using the Discord Bot's Quick Setup, the bot will guide you through the configuration.
RAM β Ensure you allocate enough RAM for your bot's needs (min. 100MB).
π Step-by-Step Hosting Guide
π Configure discloud.config
discloud.configNAME=MyCoolBot
TYPE=bot
MAIN=index.js
RAM=100
VERSION=latestTYPE=bot: Identifies the app as a bot/background service.MAIN: The entry point of your application. Learn more about the main file.RAM: Allocated memory (min. 100MB).
ποΈ Handling Build Processes
If your bot requires a build step (like TypeScript or Java), you have two options:
Let Discloud handle the build process during deployment. Add the BUILD command to your discloud.config.
BUILD=npm run build
START=npm run startBuild your project locally and upload the resulting files.
Do not use a folder named dist for your local build output. Discloud reserves the dist directory for its internal build process. Use a different name like build, out, or output.
π Upload and Deploy
You can upload your project using any of our supported methods:
π₯οΈ Dashboard
β¨οΈ CLI
π¦ VS Code Extension
π€ Discord Bot
π GitHub Integration
Last updated