aiordr 0.3.0

Creator: bradpython12

Last updated:

Add to Cart

Description:

aiordr 0.3.0

Simple and fast asynchronous library for the o!rdr API.

Features

Support for modern async syntax (async with)
Event decorators
Rate limit handling
Easy to use



Installing
Python 3.9 or higher is required
To install the library, simply run the following commands
# Linux/macOS
python3 -m pip install -U aiordr

# Windows
py -3 -m pip install -U aiordr
To install the development version, do the following:
$ git clone https://github.com/NiceAesth/aiordr
$ cd aiordr
$ python3 -m pip install -U .


API Example
import aiordr
import asyncio


async def main():
client = aiordr.ordrClient(verification_key="verylongstring")

await client.create_render(
"username",
"YUGEN",
replay_url="https://url.to.replay",
)

@client.on_render_added
async def on_render_added(event: aiordr.models.RenderAddEvent) -> None:
print(event)

@client.on_render_progress
async def on_render_progress(event: aiordr.models.RenderProgressEvent) -> None:
print(event)

@client.on_render_fail
async def on_render_fail(event: aiordr.models.RenderFailEvent) -> None:
print(event)

@client.on_render_finish
async def on_render_finish(event: aiordr.models.RenderFinishEvent) -> None:
print(event)


if __name__ == "__main__":
asyncio.run(main())


Contributing
Please read the CONTRIBUTING.rst to learn how to contribute to aiordr!


Acknowledgments

discord.py
for README formatting
aiosu
sister library for the osu! API

License

For personal and professional use. You cannot resell or redistribute these repositories in their original state.

Customer Reviews

There are no reviews.