Skip to main content

A Python library to wrap the Revolt API, made to be easy-to-use but powerful and feature rich.

Project description

pyrevolt

A Python library to wrap the Revolt API, made to be easy-to-use but powerful and feature rich.

Version Stability

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 py   revolt
# 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()

@bot.on(pyrevolt.GatewayEvent.Ready)
async def onReady(users: dict[pyrevolt.User], channels: dict[pyrevolt.Channel], servers: dict[pyrevolt.Server]) -> None:
    print("Ready!")

@bot.on(pyrevolt.GatewayEvent.OnMessage)
async def onMessage(message: pyrevolt.Message) -> None:
    print(f"{message.author.username} said: {message.content}")
    if message.content == "!ping":
        await message.Send(content=f"Pong {message.author.username}!", embeds=[pyrevolt.Embed.Create(title="Pong!", description=f"{message.author.mention}!", colour="#0000ff")], replies=[pyrevolt.Reply(message.messageID, True)])
        logChannel: pyrevolt.Channel = await bot.GetChannel("01FYEQGD3P7WJ6ST36QFPBT10Z")
        await logChannel.Send(content=f"{message.author.username} said: {message.content}")

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 source in order to find how to develop (this will of course change over the development of the library).

Useful Information

Code Quality

CodeFactor CircleCI StyleCI

Repository Information

License: GPL v3 Percentage of issues still open

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

pyrevolt-0.1.4a0.tar.gz (22.8 kB view details)

Uploaded Source

Built Distribution

pyrevolt-0.1.4a0-py3-none-any.whl (25.7 kB view details)

Uploaded Python 3

File details

Details for the file pyrevolt-0.1.4a0.tar.gz.

File metadata

  • Download URL: pyrevolt-0.1.4a0.tar.gz
  • Upload date:
  • Size: 22.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.10.4

File hashes

Hashes for pyrevolt-0.1.4a0.tar.gz
Algorithm Hash digest
SHA256 e8ce9d565471cfcb46bbd8c2fbd88323e32cc7f230b8c69c7bb834e6462dd257
MD5 e49278a845d9e0a2028c34bceea9702b
BLAKE2b-256 47fdee6578c2bd6a43bcf007a12484d1e2b2c0f14dda0ea42938eef6b35e4b00

See more details on using hashes here.

File details

Details for the file pyrevolt-0.1.4a0-py3-none-any.whl.

File metadata

  • Download URL: pyrevolt-0.1.4a0-py3-none-any.whl
  • Upload date:
  • Size: 25.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.10.4

File hashes

Hashes for pyrevolt-0.1.4a0-py3-none-any.whl
Algorithm Hash digest
SHA256 487753def331c64d6f8d7f84f3502bc1478c8eab8c29210c936da47727f42648
MD5 629e792c5fd507d1ea4f0994185d1d12
BLAKE2b-256 02b2714047e972dbc1a2328dc1471222c867a9bcf51da5bb108e8e4f9375bbbc

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page