A powerful, fast, and independent video downloader for YouTube, TikTok, and more.
Project description
h4x-xd: High-Performance Independent Video Downloader
h4x-xd is a powerful, lightweight, and extremely fast Python library designed for downloading high-quality videos from various platforms. Unlike other tools, h4x-xd is built from the ground up with independent extractors and a multi-threaded download engine, making it ideal for web applications, Telegram bots, and automated workflows.
Key Features
- Independent Extractors: Custom logic for YouTube, TikTok, and more – no reliance on
yt-dlp. - Maximum Speed: Built-in multi-chunked downloader that bypasses standard connection throttling.
- Highest Quality: Automatically identifies and merges the best available video and audio streams.
- Async-First: Fully compatible with
asynciofor high-concurrency environments. - Bot-Ready: Seamless integration for Telegram bots (stream to buffer) and Web APIs (stream to response).
Installation
# Clone the repository and install dependencies
git clone https://github.com/your-repo/h4x-xd.git
cd h4x-xd
pip install aiohttp httpx tqdm
Quick Start
import asyncio
from h4x_xd import Downloader
async def main():
dl = Downloader(output_dir="videos", num_chunks=16)
# Download in highest quality
path = await dl.download("https://www.youtube.com/watch?v=...")
print(f"Downloaded to: {path}")
asyncio.run(main())
Integration Examples
Telegram Bot (Telethon)
from h4x_xd import TelegramHelper
helper = TelegramHelper()
buffer = await helper.stream_to_buffer("https://tiktok.com/...")
await client.send_file(chat_id, buffer, caption="Downloaded via h4x-xd")
Web API (FastAPI)
from fastapi import FastAPI
from h4x_xd import web_router
app = FastAPI()
app.include_router(web_router, prefix="/api/v1")
Why h4x-xd?
| Feature | yt-dlp | h4x-xd |
|---|---|---|
| Dependency | Heavy | Lightweight |
| Architecture | CLI-first | Library-first |
| Speed | Standard | Multi-chunked (Turbo) |
| Async | Wrapper | Native |
| Integration | Complex | Plug-and-play |
License
MIT License
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file h4x_xd-1.0.0.tar.gz.
File metadata
- Download URL: h4x_xd-1.0.0.tar.gz
- Upload date:
- Size: 8.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.0rc1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c628c4a32b705acdeaed24f5c27ce136e689b1e9692c477d211c1b3976ec8744
|
|
| MD5 |
81f50d74b9c51180b704e30594456a36
|
|
| BLAKE2b-256 |
3c7ae16d7d746fab2bdbb8ef44e841251cbd6a5b488eadc52841a09a0aed366e
|
File details
Details for the file h4x_xd-1.0.0-py3-none-any.whl.
File metadata
- Download URL: h4x_xd-1.0.0-py3-none-any.whl
- Upload date:
- Size: 10.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.0rc1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b88b1a30c33d07f2a5270435a310dbc1239e1d7393b11b340385ba08311f565b
|
|
| MD5 |
e39238020ab65642dfc104960b209ac1
|
|
| BLAKE2b-256 |
40c0b8bf4952a8b80be154a4fcf8f707badf8b303e7d06f4066f1d15159b9dec
|