Skip to main content

An async Python wrapper for the MCTiers API

Project description

mctiers

An async Python wrapper for the MCTiers API.

The library is built with an aiohttp HTTP layer and a higher-level client that returns Python model objects.

Documentation: https://mctiers.readthedocs.io/en/latest/

Installing

python -m pip install mctiers

To install the local project while developing:

python -m pip install -e .

Quick Example

import asyncio

import mctiers


async def main() -> None:
    async with mctiers.Client() as client:
        profile = await client.fetch_player_profile_by_name(
            "ItzRealMe",
            badges=True,
            tests=True
        )

        print(profile.name)
        print(profile.points)


asyncio.run(main())

Proxy Support

client = mctiers.Client(
    proxy_url="http://127.0.0.1:8080"
)

proxy_auth accepts aiohttp.BasicAuth.

Requirements

  • Python 3.9+
  • aiohttp

License

MIT

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

mctiers-0.1.1.tar.gz (10.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mctiers-0.1.1-py3-none-any.whl (11.0 kB view details)

Uploaded Python 3

File details

Details for the file mctiers-0.1.1.tar.gz.

File metadata

  • Download URL: mctiers-0.1.1.tar.gz
  • Upload date:
  • Size: 10.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.12

File hashes

Hashes for mctiers-0.1.1.tar.gz
Algorithm Hash digest
SHA256 523d85eaf2b35a9d8f61578e024769dea617e2399cb7499cefb8ec876ae19c1f
MD5 4dd5c22caf142da6e2827492fae1a0c4
BLAKE2b-256 9445bda51739e0322b66cc6eea7e990d4552f089c19962d79898eac601652c2a

See more details on using hashes here.

File details

Details for the file mctiers-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: mctiers-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 11.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.12

File hashes

Hashes for mctiers-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 b24f46e92854ee86714f689f697deb00b2a5f63a6283007455f7dffa702492b7
MD5 b1369eb97060d3a6911e6c6cc22f2520
BLAKE2b-256 da37e2c5520544e225919b0616f3ac17341492580185fb2d99ebf73eb8a1fcd0

See more details on using hashes here.

Supported by

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