A general purpose library for command-based iteraction made for bots
Project description
Command For Bot
command4bot
is a general purpose library for command-based iteraction made for bots.
Installation
pip install command4bot
Quick Start
from command4bot import CommandsManager
mgr = CommandsManager()
@mgr.command
def greet(payload):
return f"Hello, {payload}!"
mgr.exec('greet John') # 'Hello, John!'
Features
- Register command with a simple decorator
- Managing command open and closed status with ease
- Automatically manage command's dependency (a.k.a.
context
) with its status - Fallback handlers if no command found
Documentation
:warning: The documentation is still working in progress!
https://command4bot.readthedocs.io/en/latest/
Todo
- Support for commands need interaction
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
command4bot-0.4.1.tar.gz
(8.5 kB
view hashes)
Built Distribution
Close
Hashes for command4bot-0.4.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 88a8f87cd415f0b2193b3ae6f3e147263885789179a9bc7f9f8a17022d63a589 |
|
MD5 | 7ccb1ae447d51ae3708d869f9b000e4b |
|
BLAKE2b-256 | 7a59530afe682b0b4238874fe82c612996916ae0efda5ff5e79d49f8ab1aee26 |