This release is a pre-release and may not be stable for production use.
pyrevolt
Installing pyrevolt
Python 3.10 or greater is required
To install pyrevolt, you can run the following command:
# Linux/macOS command
python3 -m pip install pyrevolt
# Windows
py -m pip install pyrevolt
Using pyrevolt
This shows a very quick example of how to use pyrevolt. As a note, pyrevolt is still under heavy development and this example and the library as a whole may change.
import pyrevolt
bot = pyrevolt.Bot(prefix="!")
@pyrevolt.ReadySimplified()
async def onReady() -> None:
print("Ready!")
@bot.on(pyrevolt.GatewayEvent.OnMessage)
async def onMessage(message: pyrevolt.Message) -> None:
print(f"{message.author.username} said: {message.content}")
@bot.commands.Command(name="ping")
async def ping(message: pyrevolt.Message) -> None:
await message.Send(content=f"Pong {message.author.username}!", embed=pyrevolt.Embed.Create(title="Pong!", description=f"{message.author.mention}!", colour="#0000ff"), replies=[pyrevolt.Reply(message.messageID, True)])
@bot.commands.Command(name="hello", aliases=["hi"])
async def hello(message: pyrevolt.Message, name: str) -> None:
await message.Send(content=f"Hello {name}!")
@hello.Error
async def helloError(message: pyrevolt.Message, error: Exception) -> None:
await message.Send(content=f"{str(error)}")
bot.Run(token="TOKEN")
As the library expands, more examples will be added, but we expect users during the very initial development phases to read through the documentation and see how to use the library. If you have any questions, please join the support server and ask for help.
Useful Information
Code Quality
Repository Information
Metadata
Release files for pyrevolt 0.2.9.dev0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| pyrevolt-0.2.9.dev0.tar.gz | 18.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| pyrevolt-0.2.9.dev0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 40.8 kB
Release files / pyrevolt-0.2.9.dev0.tar.gz
| Download URL | pyrevolt-0.2.9.dev0.tar.gz |
|---|---|
| Size | 18.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
281dcd5401096e407c62c1605cfa849a502edc0b5d46c9d3c1d865461131595a
|
|
BLAKE2b-256 checksum How to use checksums |
fc5151203e20438bbedace2a68f985790d00e4e27f55488a51d8c6a7e572ca6d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.10.5
|
Release files / pyrevolt-0.2.9.dev0-py3-none-any.whl
| Download URL | pyrevolt-0.2.9.dev0-py3-none-any.whl |
|---|---|
| Size | 21.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
c6e142451638d9b36d7b75909d2d29e9747cadfcc0c88f191eee5f749c703604
|
|
BLAKE2b-256 checksum How to use checksums |
6d2a3c3a7c10916d01da9beacc4addcd3191b6e6133b56d1ed0c0e2b8747ed08
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.10.5
|