Bot Client for GradientChat
Project description
gradientchat
gradientchat is the official Python bot client module for GradientChat that is OOP-based.
Example
TestBot
import gradientchat
myBot = gradientchat.Bot("TestBot [t!]") # No prefix arg makes prefix first letter of name + "!"
@myBot.cmd
def ping():
"""Returns \"Pong!\"""" # Docstring is used as description for the command
return "Pong!"
myBot.connect()
Docs
gradientchat.Bot(name, pref)
If name is not str, raises TypeError, however if pref is not string and name is str, prefix will be lowercase of first character of name and a exclamation mark.
gradientchat.Bot.connect(servUrl)
Connects to server; if servUrl is str, connects to URL specified on servUrl; raises Exception if already connected.
@gradientchat.Bot.cmd
Decorator for adding a command; if called with a command name, command name will be set to the specified command name.
gradientchat.Bot.sendMsg
Sends a message.
Project details
Release history Release notifications | RSS feed
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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file gradientchat-2024.1.4.1.tar.gz.
File metadata
- Download URL: gradientchat-2024.1.4.1.tar.gz
- Upload date:
- Size: 2.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
020e11e0762127130e840fcc082b38245d601af42743db50b69b44a618235a68
|
|
| MD5 |
62b7996a49e9297160ae0f254772174e
|
|
| BLAKE2b-256 |
fe5d0e432c3a6ab5bda951e64a31b851463dc2454af8a7b88ecd22659090569f
|
File details
Details for the file gradientchat-2024.1.4.1-py3-none-any.whl.
File metadata
- Download URL: gradientchat-2024.1.4.1-py3-none-any.whl
- Upload date:
- Size: 2.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5fdaaacc701d8dc8bc6c178845485549372470acd93f22c553c245cef8e7aa42
|
|
| MD5 |
3be553c7341022f4afd6b930f9d3c5ba
|
|
| BLAKE2b-256 |
bbdcfd6fde046004cc73652cd309f438d620469c12f41d213bffb24914418217
|