Skip to main content

Official async Python SDK and CLI for BrokenX YouTube API

Project description

🚀 BROKENXAPI

Official async Python SDK & CLI for BrokenX YouTube API Built by Broken X Network

BROKENXAPI developers ko YouTube search aur media processing (audio/video) ke liye ek fast, async aur secure API provide karta hai — jisme SDK + CLI dono available hain.


✨ Features

  • ⚡ Async Python SDK (aiohttp based)
  • 🖥️ Built-in CLI (brokenx)
  • 🔑 Secure API-key authentication
  • 🎵 Audio & 🎬 Video support
  • ☁️ Telegram-based media delivery
  • 🚀 Server-side caching & rate limits
  • 🧱 Clean, production-ready packaging

📦 Installation

pip install BROKENXAPI

Verify installation:

brokenx -v

🔑 Authentication (One-time)

CLI ke through ek baar API key authenticate karni hoti hai:

brokenx auth BROKENXAPI-XXXX

🔐 How it works

  • API key securely local machine par store hoti hai
  • Uske baad har command automatically authenticated hoti hai
  • Environment variables ki zarurat nahi

📟 Command Line Interface (CLI)

BROKENXAPI with powerful CLI :

🔢 Version

brokenx -v

🔍 Search YouTube

brokenx search "lofi beats"

Returns:

  • title
  • video_id
  • duration
  • thumbnail
  • temporary stream URL

🎵 Download Audio

brokenx download VIDEO_ID

Default mode audio hota hai.


🎬 Download Video

brokenx download VIDEO_ID -v

-v flag use karke video download hota hai.


🐍 Python SDK Usage

Basic Example

import asyncio
from brokenxapi import BrokenXAPI

async def main():
    async with BrokenXAPI(api_key="BROKENXAPI-XXXX") as api:
        result = await api.search("Arijit Singh")
        print(result)

asyncio.run(main())

Download Example

async with BrokenXAPI(api_key="BROKENXAPI-XXXX") as api:
    audio = await api.download("VIDEO_ID", "audio")
    video = await api.download("VIDEO_ID", "video")

🧠 How Authentication Works

  • API key har request ke saath backend par verify hoti hai
  • Rate limits server-side enforce hote hain
  • Invalid / expired key par request reject ho jaati hai

📚 Documentation

📘 Full Docs: 👉 DOCS


⚠️ Important Notes

  • Media files Telegram ke through deliver hote hain
  • Stream URLs temporary hote hain
  • Rate limits API key ke type par depend karte hain
  • SDK async hai — async/await required


🔒 Security & Licensing

  • Core client logic intentionally compiled (.pyc)
  • No sensitive keys repo me store nahi hoti
  • License: MIT

🤝 Contributing

Currently BROKENXAPI core is maintained by Broken X Network. Issues, feature requests aur suggestions welcome hain:

👉 DROP ISSUES


🏁 Roadmap (High-level)

  • ✅ SDK + CLI
  • 🔜 Advanced CLI flags
  • 🔜 Improved docs & examples
  • 🔜 Multi-profile auth support
  • 🔜 Production backend scaling

© License

MIT License © 2025–2026 MR BROKEN


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

brokenxapi-2.0.1.tar.gz (5.8 kB view details)

Uploaded Source

Built Distribution

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

brokenxapi-2.0.1-py3-none-any.whl (6.9 kB view details)

Uploaded Python 3

File details

Details for the file brokenxapi-2.0.1.tar.gz.

File metadata

  • Download URL: brokenxapi-2.0.1.tar.gz
  • Upload date:
  • Size: 5.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.1

File hashes

Hashes for brokenxapi-2.0.1.tar.gz
Algorithm Hash digest
SHA256 0a7a356413db62e8e9c9d77c4538d0ec5f74e06ac894b9136a7d9934085be862
MD5 b371eeea766349bab5a67274e43c690c
BLAKE2b-256 869dae4499590fafff17be0eefba7cf2ac8d16a4cb661aebb4e200c5a09f2a3a

See more details on using hashes here.

File details

Details for the file brokenxapi-2.0.1-py3-none-any.whl.

File metadata

  • Download URL: brokenxapi-2.0.1-py3-none-any.whl
  • Upload date:
  • Size: 6.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.1

File hashes

Hashes for brokenxapi-2.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 09d814672979809a54c1f6bcffe22ff8fb9373b3e1b2357c4aab7d891b1c5137
MD5 57e114b1449775c81e49e4d43990bcb8
BLAKE2b-256 48ad410138de195ed2d75b16b4abf9848e63b99209bd8c9217d28935d6eca956

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