PROMO Get 10% off any server with code: START Limited-time offer

Discord bot β€” Python

Discord.py, Disnake and Nextcord on Python 3.12.

Dependencies

Put a requirements.txt file in the root directory β€” packages are installed on startup:

requirements.txt
discord.py>=2.3
python-dotenv
main.py
import os, discord
from dotenv import load_dotenv

load_dotenv()
client = discord.Client(intents=discord.Intents.default())

@client.event
async def on_ready():
    print(f"Logged in as {client.user}")

client.run(os.getenv("DISCORD_TOKEN"))