A package allowing you to display interactive help in Discord easily
Discord Interactive Help
A Discord python framework to display an interactive help easily.
- 🔆 Easy to naviguate : Use reactions to naviguate through the Help manual.
- ⚙ Customized reaction : Use any emoji as naviguation icon.
- 🎮 Commands support : Go even further with interactive commands.
Install the package :
pip install discord-interactive
Help objects into your bot's code, and create your own help manual :
from discord_interactive import Page, Help # Define each page root = Page('Welcome !\n') page_1 = Page('This is page 1') page_2 = Page('This is page 2') # Link pages together page_1.link(page_2, description='Click this icon to access page 2', reaction='💩') root.link(page_1, description='Click this icon to access page 1') # Set the root page as the root of other page (so user can come back with a specific reaction) root.root_of([page_1, page_2]) # Create the Help object client = discord.Client() h = Help(client, root) ... # And display the help ! @client.event async def on_message(message): if message.author != client.user: # Do not answer to myself if message.content.startswith('/help'): await h.display(message.author)
You can try the interactive help in this Discord server !
Simply join the server, and type
/help in the chat.
Also, take a look at the code for this interactive help ! Check out the script
If you are interested in advanced usage such as interactive commands, take a look at the full documentation.
Example of advanced usage :
Running in Docker
A Dockerfile is available to run the example easily. Just build the image :
docker build -t discord_interactive_help .
And then start it with your Discord bot token :
DISCORD_BOT_SECRET="<your_token>" docker run -e DISCORD_BOT_SECRET discord_interactive_help
This idea was already known for some time, I didn't get the idea myself. I just wanted to share an easy framework to implement it for your own bot.
This is working only with the Python Discord API.
Release history Release notifications | RSS feed
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Hashes for discord_interactive-4.1.0.tar.gz
Hashes for discord_interactive-4.1.0-py3-none-any.whl