- Go to the Discord Developer Portal.
- Create a new application with some name
- After creating the application, go to the bot tab, and choose 'Add Bot'
- Keep a copy of the shown bot token. (This will go inside
keys.json
) - Ensure the
Message Content Intent
is selected. - Replace
{CLIENT_ID_GOES_HERE}
with the shown application id in the urlhttps://discord.com/api/oauth2/authorize?permissions=16851968&scope=bot%20applications.commands&client_id={CLIENT_ID_GOES_HERE}
- Use the link to invite the bot to a server.
- Place OpenAI API key and Discord bot token in keys.json (using keys.json.example as a template).
- Install dependencies using Poetry:
poetry install
- Run
poetry run python -m bot.main