Unofficial Dynamic Help Command for interactions.py
Project description
Dynamic Help
Description
A dynamically generated help command for interactions.py that allows for >100 character command descriptions
Usage
Install via pypi
pip install interactions-dynamic-help
Then load the extension into your bot
from interactions import Client
bot = Client()
...
bot.load_extension("interactions.ext.dynhelp")
bot.start("Token")
Using longer descriptions
Longer description is done with a docstring.
If you are using a docstring longer than 100 chars, you MUST provide a description in the slash_command
from interactions import Client, slash_command
bot = Client()
@slash_command(
name="test",
description="This is a test command",
)
async def test(ctx):
"""This is a test command (parsed as a short description and ignored if a long description is provided)
This is a longer description that will be used in the help command and is longer than 100 chars
- this is parsed as part of the long description
"""
await ctx.respond("Test")
bot.load_extension("interactions.ext.dynhelp")
bot.start("Token")
You can specify to combine the short and long description by adding combine=True
to the decorator
bot.load_extension("interactions.ext.dynhelp", combine=True)
Skipping commands and/or options
By defualt the ctx
and bot
parameters are skipped, but you can skip more by adding skip_coms
adn skip_opts
to
the decorator
bot.load_extension("interactions.ext.dynhelp", skip_coms=["test"], skip_opts=["test"])
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for interactions_dynamic_help-1.0.3.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9585dd2251bf4e6dc87000c9038aa9ba7318f5dec4b0812f98f27cfb21633bd4 |
|
MD5 | 16074039c51e9cf289cae4c5b6ca3738 |
|
BLAKE2b-256 | e83937ce81cb895f166b3e5fa27d551544184ba42a4451a902977f958c03d294 |
Close
Hashes for interactions_dynamic_help-1.0.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ca7599b5aae35a482c2d10f369110c8dac63032de45ec81ee650918fb6e21d67 |
|
MD5 | b32a9b4078ef0dad31e0cce989f2cab2 |
|
BLAKE2b-256 | 2db55432c2da2031cf2deadd2d9230a5bcae2d97730f79a584b6118c4da14031 |