A python library to use the Challonge API
Project description
achallonge
async Challonge for Python 3.5+
Modern library that is more than just a wrapper for the Challonge web API
Requirements
aiohttp
Optional:
cchardet
faster replacement for chardet, as mentionned on the aiohttp pageaiodns
for speeding up DNS resolving, highly recommended by aiohttp
Python version support
3.5
3.6
3.7
Installation
pip install achallonge
If you want to have the optional dependencies for aiohttp, you can:
pip install achallonge[speed]
Usage
import challonge
async def foo():
# Log in into Challonge with your CHALLONGE! API credentials (https://challonge.com/settings/developer).
user = await challonge.get_user('your_challonge_username', 'your_api_key')
# Retrieve your tournaments
tournaments = await user.get_tournaments()
# Tournaments, matches, and participants are all represented as Python classes
for t in tournaments:
print(t.id) # 3272
print(t.name) # 'My Awesome Tournament'
print(t.status) # 'open'
# Retrieve the participants for a given tournament.
participants = await tournaments[0].get_participants()
print(len(participants)) # 13
Documentation
The full documentation can be found on Read the docs
Author / License
Distributed under MIT license. See LICENSE
for details
Fabien Poupineau (fp12) - 2017-2019
Twitter: @fp12gaming
Join the Discord Server and discuss about this lib!
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
File details
Details for the file achallonge-compat-fork-1.9.0.tar.gz
.
File metadata
- Download URL: achallonge-compat-fork-1.9.0.tar.gz
- Upload date:
- Size: 15.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/4.0.2 CPython/3.11.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 44982cd421bdab410977acdd0de090b53ade6b1f956fcf79bc62de41f5bc2413 |
|
MD5 | 763608f6b004185bc82f07c13ad96e6c |
|
BLAKE2b-256 | d87dfda90ad898b9038994c15e809ed039afe2a0309b6c1ad78ec6b7a5cd9490 |
File details
Details for the file achallonge_compat_fork-1.9.0-py3-none-any.whl
.
File metadata
- Download URL: achallonge_compat_fork-1.9.0-py3-none-any.whl
- Upload date:
- Size: 19.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/4.0.2 CPython/3.11.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ec21593bb7f851d630b6310c705a50dfcaadad35fbb17675bfaad071d1aa2107 |
|
MD5 | 425bd1592d096109bf7576bb617e932e |
|
BLAKE2b-256 | a499376dfb259878f242c0c37ac79d8d24627cd7dda3d4ef54abd6827208bf81 |