Async osu! Api Wrapper
Project description
AsyncOsu
Asynchronous osu! api wrapper for python using aiohttp.
OsuApiV2
This package supports osu api v2.
Basic usage with context manager:
import asyncio
from asyncosu import OsuApiV2
async def main():
async with OsuApiV2(client_id='client_id', client_secret='client_secret') as osu_api:
return await osu_api.get_user_from_username(f'heyronii')
if __name__ == "__main__":
print(asyncio.run(main()))
without context_manager:
async def main():
osu_api = OsuApiV2(client_id='client_id', client_secret='client_secret')
user_info = await osu_api.get_user_from_username(f'heyronii')
await osu_api.close() # Close the connection before creating another instance
return user_info
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
asyncosu-0.0.2.tar.gz
(4.4 kB
view details)
File details
Details for the file asyncosu-0.0.2.tar.gz
.
File metadata
- Download URL: asyncosu-0.0.2.tar.gz
- Upload date:
- Size: 4.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.9.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 28dd0a977f6492d9fa6682eb033a44b7d6fe75c01efa2e85f5f4214ee4eeb1d2 |
|
MD5 | 366149e0ea4bb00addbb4e03e60832ed |
|
BLAKE2b-256 | 109b6cc26371cdd6fa393d4bff5a50d6869f22c2527f6cb90b60bf67afe1ef40 |