Skip to main content

AioxUI

A lightweight async Python SDK for interacting with XUI panel APIs.

Features

  • Async client based on aiohttp
  • Typed models using Pydantic
  • Client management (create, update, delete)
  • Traffic management utilities
  • Inbound attach/detach support

Installation

pip install aioxui
git clone https://github.com/DevJavad/aioxui.git
cd aioxui
pip install -e .

Quick Start

import asyncio

from aioxui import XUI

async def main():
    async with XUI(
        base_url="https://your-panel.com/",
        token="YOUR_TOKEN"
    ) as xui:

        client = await xui.client.get("Javad")
        print(client)

        clients = await xui.client.all()
        print(len(clients))

asyncio.run(main())

Example: Create Client

import asyncio
import os

from aioxui import XUI
from aioxui.models import Client
from aioxui.enums import UnitType
from aioxui.utils import DateTime, Storage
from dotenv import load_dotenv

load_dotenv()

url: str = os.getenv("URL")
token: str = os.getenv("TOKEN")

async def main():
    async with XUI(base_url=url, token=token) as xui:
        client = Client(
            totalGB=Storage.from_unit(10, UnitType.GB),
            expiryTime=DateTime.after(days=30),
            limitIp=3,
            tgId=12345678,  # Telegram user_id
        )

        add = await xui.client.add(inbound_id=[2, 3], client=client)
        print(add.email)
        print(add.sub_id)


asyncio.run(main())

Metadata

Release files for aioxui 0.0.4

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

Source distribution (sdist)

Source distribution for aioxui 0.0.4
File Size Uploaded Provenance Actions
aioxui-0.0.4.tar.gz 7.9 kB Without provenance Details for aioxui-0.0.4.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for aioxui 0.0.4
File Interpreter ABI Platform Actions
aioxui-0.0.4-py3-none-any.whl Python 3 none any Details for aioxui-0.0.4-py3-none-any.whl

Total release size: 16.4 kB

Release files / aioxui-0.0.4.tar.gz

Download URL aioxui-0.0.4.tar.gz
Size 7.9 kB
Tags Source
SHA-256 checksum
How to use checksums
190615473059e35f9572ec548641138febfc315a198bff54a4c3177f9250097c
BLAKE2b-256 checksum
How to use checksums
a90d1ec7d75206f5d48458736791e4288aa9faf11b9c99536985d706cadd7944
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.3

Release files / aioxui-0.0.4-py3-none-any.whl

Download URL aioxui-0.0.4-py3-none-any.whl
Size 8.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e9ad8557b87352c38b154a55e02eb002758ee89242bc30a69096f5f970d0e34f
BLAKE2b-256 checksum
How to use checksums
4536666b5eb07cf2dbc286542cdc60bbc7afd7f2af3cc762555645c4fbc41fe9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.3

Security for aioxui 0.0.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.

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