Skip to main content

DDnet api

Project description

ddapi is an api from the ddnet and qwik website

Installation

  pip install ddapi

or

  pip install git+https://github.com/ByFox213/ddapi

Usage/Examples

DDnet

import asyncio
from ddapi import DDnetApi, DDPlayer


async def main():
    obj = DDnetApi()
    nickname = "Cor"
    user: DDPlayer = await obj.player(nickname)
    if user is None:
        return "Player not found"

    print(f"{user.player}: {user.points.points}")
    # Cor: 31473 
    await obj.close()  # Closing client Not necessary
    assert isinstance(user, DDPlayer)


asyncio.run(main())

Tested on Python

3.9 3.10 3.11 3.12
? ?

other examples

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

ddapi-0.10.0.tar.gz (8.6 kB view details)

Uploaded Source

Built Distribution

ddapi-0.10.0-py3-none-any.whl (9.3 kB view details)

Uploaded Python 3

File details

Details for the file ddapi-0.10.0.tar.gz.

File metadata

  • Download URL: ddapi-0.10.0.tar.gz
  • Upload date:
  • Size: 8.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.6

File hashes

Hashes for ddapi-0.10.0.tar.gz
Algorithm Hash digest
SHA256 fd4d53d4db7499f987fb9829f89e1bd1697276d3d6074710f2bfbf26faa804d9
MD5 9b9afd867cfca6145c2a8c2bb678aa54
BLAKE2b-256 3029a11ce3c7e2ca2606601879475e77c68bf8acbe90564190bb1d080e3bb414

See more details on using hashes here.

File details

Details for the file ddapi-0.10.0-py3-none-any.whl.

File metadata

  • Download URL: ddapi-0.10.0-py3-none-any.whl
  • Upload date:
  • Size: 9.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.6

File hashes

Hashes for ddapi-0.10.0-py3-none-any.whl
Algorithm Hash digest
SHA256 bcd4eec8b53d7ce514896768f3fc7b7a79b82a2832826d0501990a8827d1acc7
MD5 d05aa33b4c068ec675d826227e9f45b7
BLAKE2b-256 4a10dbddedd4bbfbf2c9569a404d4f05e78066ff168746458f9d66c5efa2ee8d

See more details on using hashes here.

Supported by

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