A simple Discord bot template using Node.js.
- Node.js
- npm
- Discord bot token
npm install-
Copy the environment file:
cp .env.example .env
-
Edit
.envand set your bot token:DISCORD_TOKEN=your_bot_token_here DISCORD_CLIENT_ID=your_client_id_here LOG_LEVEL=INFO
npm start- Do not commit your
.envfile - Make sure the bot has the required intents enabled in Discord Developer Portal