ClashAPI
Using your developer account's login email and password, update the IP address of all your existing Clash of Clans and/or Clash Royale API keys to the current one, and obtain their tokens.
Getting Started
Installing
pip install clashapi
Usage
import clashapi
# Clash of Clans
tokens = clashapi.coc("email", "password")
# Clash Royale
tokens = clashapi.cr("email", "password")
# tokens is a list of api key token strings that you can now use to access the COC/CR APIs
Quick Example
import requests
import clashapi
tokens = clashapi.coc("email", "password")
response = requests.get(url="https://api.clashofclans.com/v1/clans/%23208GJG2J", headers={"Accept": "application/json", "authorization": f"Bearer {tokens[0]}"})
print(response.json())
Metadata
Release files for clashapi 1.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| clashapi-1.4.tar.gz | 2.3 kB | Without provenance | Details for clashapi-1.4.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| clashapi-1.4-py3-none-any.whl | Python 3 | none | any | Details for clashapi-1.4-py3-none-any.whl |
Total release size: 4.7 kB
Release files / clashapi-1.4.tar.gz
| Download URL | clashapi-1.4.tar.gz |
|---|---|
| Size | 2.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
8ee2c74ed2efb8a73a45244f5d65a055398d67ab5bd1094c9f1883c6c051bb52
|
|
BLAKE2b-256 checksum How to use checksums |
1513bed99062778f6113cec1b277074d84463e56a1d204828c94b63dda68c021
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.7.1 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9
|
Release files / clashapi-1.4-py3-none-any.whl
| Download URL | clashapi-1.4-py3-none-any.whl |
|---|---|
| Size | 2.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
c0348045a9a68e00303efdf8e3957ab036e1d2bedd7fae0a2d667db66d0feb5a
|
|
BLAKE2b-256 checksum How to use checksums |
9715b567770b3a22ae3731b6757b343f2ecf91c07101ad51edd66e37812c4901
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.7.1 importlib_metadata/4.8.2 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9
|
Security for clashapi 1.4
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.