API Drama

API Documentation

One unified JSON API for short-drama platforms. Home feeds, search, titles with full episode lists, and episode stream links — the same shape for every platform.

Download Postman collection Test your key live

Quick startAuthenticationEndpointsPlatforms & languagesErrorsCode examples

Quick start

1. Get a key — message us on Telegram or pick a plan.

2. Base URL: https://www.darkapis.cyou

3. Send your key in the X-API-Key header on every request.

4. Flow for one video: home → pick an id → detail → pick an episode → video.

Authentication

Every request needs your API key. Send it as a header (recommended) or as a query parameter:

X-API-Key: YOUR_API_KEY

# or
https://www.darkapis.cyou/api/v2/home?category_p=bilitv&lang=en&key=YOUR_API_KEY

Your key decides which platforms and languages you can call, and your daily request limit. Check them any time with /api/v2/key/status.

Endpoints

All endpoints are GET and return JSON. Base URL https://www.darkapis.cyou

GET/api/v2/home

Home feed for a platform in one language.

ParameterRequiredDescription
category_pYesPlatform slug, e.g. bilitv
langYesLanguage code, e.g. en

Example response (shortened):

{ "success": true, "platform": "FreeReels", "total": 53, "data": [ { "id": "xkAVGzmPMl", "title": "…", "author": "…", "cover": "https://…", "synopsis": "…", "status": "Completed", "genres": ["Drama"], "chapters": "100", "views": "17.8M", "tags": ["Drama"] } ] }

GET/api/v2/discover

Same list as home, paginated.

ParameterRequiredDescription
category_pYesPlatform slug
langYesLanguage code
pageNoPage number, default 1
limitNoItems per page, default 20, max 100

Example response (shortened):

{ "success": true, "platform": "FreeReels", "total": 53, "data": [ { "id": "xkAVGzmPMl", "title": "…", "author": "…", "cover": "https://…", "synopsis": "…", "status": "Completed", "genres": ["Drama"], "chapters": "100", "views": "17.8M", "tags": ["Drama"] } ] }

GET/api/v2/banner

Promotional / featured titles.

ParameterRequiredDescription
category_pYesPlatform slug
langYesLanguage code

Example response (shortened):

{ "success": true, "platform": "FreeReels", "total": 53, "data": [ { "id": "xkAVGzmPMl", "title": "…", "author": "…", "cover": "https://…", "synopsis": "…", "status": "Completed", "genres": ["Drama"], "chapters": "100", "views": "17.8M", "tags": ["Drama"] } ] }

GET/api/v2/search

Search titles by keyword.

ParameterRequiredDescription
category_pYesPlatform slug
qYesKeyword
langYesLanguage code
pageNoPage number
limitNoItems per page

Example response (shortened):

{ "success": true, "platform": "FreeReels", "total": 53, "data": [ { "id": "xkAVGzmPMl", "title": "…", "author": "…", "cover": "https://…", "synopsis": "…", "status": "Completed", "genres": ["Drama"], "chapters": "100", "views": "17.8M", "tags": ["Drama"] } ] }

GET/api/v2/detail

One title with its full episode list.

ParameterRequiredDescription
category_pYesPlatform slug
idYesTitle id from home/discover/search
langYesLanguage code

Example response (shortened):

{ "success": true, "platform": "FreeReels", "data": { "id": "xkAVGzmPMl", "title": "…", "total_episodes": 100, "chapters": [ { "id": 1, "index": 1, "title": "Episode 1" }, { "id": 2, "index": 2, "title": "Episode 2" } ] } }

GET/api/v2/video

Stream link (and subtitles) for one episode.

ParameterRequiredDescription
category_pYesPlatform slug
idYesTitle id
chapterIdYesEpisode number from detail
langYesLanguage code

Example response (shortened):

{ "success": true, "data": { "streams": [ { "quality": "auto", "url": "https://…", "duration": 72 } ], "subtitles": [ { "language": "en-US", "format": "webvtt", "url": "https://…" } ], "episode_index": 1, "total_episodes": 100, "next_video_id": 2, "prev_video_id": 0, "is_free": true } }

GET/api/v2/categories

Platforms your key can use.

No parameters.

GET/api/v2/languages

Languages your key can use.

No parameters.

GET/api/v2/key/status

Your key: plan, daily limit, used today, expiry, allowed platforms and languages.

No parameters.

Example response (shortened):

{ "success": true, "data": { "status": "active", "plan": "custom", "daily_limit": 5000, "used_today": 12, "expires_at": null, "allowed_platforms": ["all"], "allowed_languages": ["all"] } }

Platforms & languages

Use these exact values for category_p and lang. Your key may cover only some of them — /api/v2/categories and /api/v2/languages list the ones you can use.

category_p (28)

bilitvcubetvdramabitedramaboxdramanovadramapopsdramarushdramawaveflextvflickreelsfreereelsfundramagoodshortidramamelolomeloshortnetshortrapidtvreelalareelifereelshortshortmaxshortwaveshotshortsnackshortsodareelsstardusttvstarshort

lang (24)

arbnzhcsenfilfrdeelhiiditjakomsplptroestethtrukvi

Errors

Errors are JSON: { "success": false, "error": "message" } with one of these status codes.

HTTPMeaning
400Missing a required parameter (category_p, id, chapterId, q…) or unknown endpoint.
401No API key sent. Send header X-API-Key, or ?key=…
403Invalid, revoked or expired key — or your key has no access to that platform / language.
404Unknown platform, title or episode.
429Your daily request limit is used up. It resets every day.
502The content source could not be reached. Try again shortly.

Code examples

cURL
JavaScript
Python
PHP
curl -H "X-API-Key: YOUR_API_KEY" \
  "https://www.darkapis.cyou/api/v2/home?category_p=bilitv&lang=en"
const BASE = 'https://www.darkapis.cyou';
const KEY = 'YOUR_API_KEY';

async function api(path, params = {}) {
  const url = BASE + path + '?' + new URLSearchParams(params);
  const res = await fetch(url, { headers: { 'X-API-Key': KEY } });
  return res.json();
}

const home = await api('/api/v2/home', { category_p: 'bilitv', lang: 'en' });
const detail = await api('/api/v2/detail', { category_p: 'bilitv', id: home.data[0].id, lang: 'en' });
const video = await api('/api/v2/video', { category_p: 'bilitv', id: home.data[0].id, chapterId: 1, lang: 'en' });
console.log(video.data.streams[0].url);
import requests

BASE = 'https://www.darkapis.cyou'
KEY = 'YOUR_API_KEY'

def api(path, **params):
    r = requests.get(BASE + path, params=params, headers={'X-API-Key': KEY}, timeout=30)
    return r.json()

home = api('/api/v2/home', category_p='bilitv', lang='en')
item = home['data'][0]
detail = api('/api/v2/detail', category_p='bilitv', id=item['id'], lang='en')
video = api('/api/v2/video', category_p='bilitv', id=item['id'], chapterId=1, lang='en')
print(video['data']['streams'][0]['url'])
<?php
$base = 'https://www.darkapis.cyou';
$key  = 'YOUR_API_KEY';

function api($path, $params = []) {
    global $base, $key;
    $ch = curl_init($base . $path . '?' . http_build_query($params));
    curl_setopt_array($ch, [CURLOPT_RETURNTRANSFER => true, CURLOPT_HTTPHEADER => ['X-API-Key: ' . $key]]);
    $out = json_decode(curl_exec($ch), true);
    curl_close($ch);
    return $out;
}

$home  = api('/api/v2/home', ['category_p' => 'bilitv', 'lang' => 'en']);
$video = api('/api/v2/video', ['category_p' => 'bilitv', 'id' => $home['data'][0]['id'], 'chapterId' => 1, 'lang' => 'en']);
echo $video['data']['streams'][0]['url'];

Prefer clicking over coding? Import the Postman collection, set api_key once, and every endpoint is ready to run.