A simple async API wrapper for the mcsrvstat.us API. https://pypi.org/project/pymcsrvstatus
  • Python 76.2%
  • Nix 23.8%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Renovate 2e61826768
All checks were successful
Actions / Build (push) Successful in 36s
Actions / Lint (Python 3.10) (push) Successful in 34s
Actions / Lint (Python 3.12) (push) Successful in 30s
Actions / Lint (Python 3.11) (push) Successful in 35s
Actions / Lint (Python 3.13) (push) Successful in 34s
Actions / Lint (Python 3.14) (push) Successful in 32s
chore(deps): lock file maintenance (#123)
2026-09-13 20:06:59 -04:00
.forgejo/workflows chore(deps): update actions/upload-artifact action to v5 (#85) 2026-09-09 15:07:33 -04:00
.zed rewrite (#121) 2026-09-09 13:53:36 -04:00
LICENSES REUSE Compliance 2025-09-28 09:15:11 -05:00
pymcsrvstatus Create py.typed 2026-09-09 14:17:05 -04:00
.envrc REUSE Compliance 2025-09-28 09:15:11 -05:00
.gitignore REUSE Compliance 2025-09-28 09:15:11 -05:00
flake.lock rewrite (#121) 2026-09-09 13:53:36 -04:00
flake.nix rewrite (#121) 2026-09-09 13:53:36 -04:00
pyproject.toml rewrite (#121) 2026-09-09 13:53:36 -04:00
README.md update readme for rewrite 2026-09-09 14:04:59 -04:00
renovate.json chore: Configure Renovate (#1) 2025-06-29 08:33:58 -05:00
REUSE.toml REUSE Compliance 2025-09-28 09:15:11 -05:00
uv.lock chore(deps): lock file maintenance (#123) 2026-09-13 20:06:59 -04:00

pymcsrvstatus

Discord Actions Status PyPI - Version PyPI - Python Version PyPI - License

A simple async API wrapper for the mcsrvstat.us API.

Usage

import asyncio
from pymcsrvstatus import McSrvStatusClient

async def example(address: str) -> None:
    async with McSrvStatusClient(extra_user_agent="pymcsrvstatus example") as client:
        if await client.check_if_online(address):
            print("Wynncraft is online!")
        else:
            print("Wynncraft is offline!")

        status = await client.fetch(address)
        assert status.online is True
        print(status.protocol)  # Protocol(version=769, name='1.21.4')
        print(status.version)  # "1.21.4+"
        print(status.players)  # Players(online=2704, max=3500, players=[])

        print(client.get_icon_url(address))  # play.wynncraft.com

asyncio.run(example(address="play.wynncraft.com"))