Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

mikan-sdk

A typed Python client for the API of the mikan panel, generated from the panel's own OpenAPI spec with openapi-python-client. Every operation of the API is a function with typed parameters and typed answers, in a blocking and an asyncio version.

Every stable release of the panel has an SDK of the same number: install the one that matches your panel (Settings → System → Updates shows it), for a panel 0.5.3.0 that is 0.5.3.0. The client reads answers strictly, so one that does not match its panel can refuse an answer: a value of an enumeration it does not know yet, or a required field the panel does not send.

Install

pip install mikan-sdk==<version>

It needs Python 3.11 or later.

Sign in with an API key

Make a key in the panel: Settings → Security → API → New key. It looks like mk_... and is shown once. The client needs the key and the API address as the panel's API page shows it, https://<panel>:<port>/<secret path>/api/v1, with nothing after /api/v1.

from mikan_sdk import AuthenticatedClient
from mikan_sdk.api.users import list_users
from mikan_sdk.models import ListUsersState

client = AuthenticatedClient(
    base_url="https://vpn.example.com:8443/SECRET-PATH/api/v1",
    token="mk_...",
)

with client as client:
    response = list_users.sync_detailed(client=client, state=ListUsersState.ACTIVE, limit=10)
    if response.status_code != 200:
        raise RuntimeError(response.parsed.detail)
    for user in response.parsed.items:
        print(user.id, user.name)

Each operation lives in the module of its section: mikan_sdk.api.users.list_users, mikan_sdk.api.tariffs.list_tariffs, and so on. A module has sync, sync_detailed, asyncio and asyncio_detailed; the detailed ones give the status code, the headers and the raw body too. The bodies of requests are in mikan_sdk.models.

An error comes as the problem document of RFC 9457 (ErrorModel): detail holds the code of the error. A key with "Read" access calls only GET, and the operations marked "session only" (sign-in, keys, balance changes) refuse every key with 403 session_only. The API page of the docs has the rest: https://miroshka000.github.io/mikan/api/.

Metadata

Release files for mikan-sdk 0.5.2.1rc10

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for mikan-sdk 0.5.2.1rc10
File Size Uploaded Provenance Actions
mikan_sdk-0.5.2.1rc10.tar.gz 255.3 kB With provenance Details for mikan_sdk-0.5.2.1rc10.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for mikan-sdk 0.5.2.1rc10
File Interpreter ABI Platform Actions
mikan_sdk-0.5.2.1rc10-py3-none-any.whl Python 3 none any Details for mikan_sdk-0.5.2.1rc10-py3-none-any.whl

Total release size: 1.0 MB

Release files / mikan_sdk-0.5.2.1rc10.tar.gz

Download URL mikan_sdk-0.5.2.1rc10.tar.gz
Size 255.3 kB
Tags Source
SHA-256 checksum
How to use checksums
94d97f3ac7878e29633a34f0b314d28b988da7772e980dbd984e6cb77620c4da
BLAKE2b-256 checksum
How to use checksums
d69be14fc82b28f12d78d9dea1443ca015bcc2dc75b5e39c5be4c51f8c63092b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 12, 2026.

Transparency log

Release files / mikan_sdk-0.5.2.1rc10-py3-none-any.whl

Download URL mikan_sdk-0.5.2.1rc10-py3-none-any.whl
Size 755.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e9e4d5ba03ce8ccae70af0682669adc765c0d21a5c78e6bfc650696434f62cf9
BLAKE2b-256 checksum
How to use checksums
515287eba6d4325ff5371a8bc4aec7f77e35b4f58f9944bca738bcf9bebd64f4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 12, 2026.

Transparency log

Security for mikan-sdk 0.5.2.1rc10

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.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for mikan_sdk-0.5.2.1rc10.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 12, 2026.

Transparency log

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.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page