From 51f8deadaf8c968631f60dd76b90e3068221d566 Mon Sep 17 00:00:00 2001 From: shafat-96 Date: Mon, 24 Feb 2025 23:38:34 +0600 Subject: [PATCH] Update README.md --- README.md | 51 ++++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 50 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index ae5716a..d61f3bc 100644 --- a/README.md +++ b/README.md @@ -105,6 +105,55 @@ Example Request: GET http://localhost:3000/api/anime/sources?movieId=vRPjMA&episode=1&server=4&subOrDub=sub ``` +### Get HLS Link + +``` +GET /api/anime/hls/{animeId}?episode={ep}&server={id}&subOrDub={type} +``` + +Fetches HLS (HTTP Live Streaming) links with additional metadata for a specific episode. + +Query Parameters: +- `episode` (optional): Episode number (default: 1) +- `server` (optional): Server number (default: 4) +- `subOrDub` (optional): "sub" or "dub" (default: "sub") + +Example Request: +``` +GET http://localhost:3000/api/anime/hls/vRPjMA?episode=1&server=4&subOrDub=sub +``` + +Example Response: +```json +{ + "status": true, + "result": { + "sources": [ + { + "file": "https://example.com/hls/video.m3u8", + "type": "hls" + } + ], + "tracks": [ + { + "file": "https://example.com/subtitles.vtt", + "label": "English", + "kind": "captions" + } + ], + "intro": { + "start": 0, + "end": 90 + }, + "outro": { + "start": 1290, + "end": 1380 + }, + "server": 4 + } +} +``` + ### Health Check ``` @@ -124,4 +173,4 @@ The API will return appropriate error messages with corresponding HTTP status co - The API includes necessary headers for authentication - CORS is enabled for cross-origin requests -- The server runs on port 3000 by default (can be changed via PORT environment variable) \ No newline at end of file +- The server runs on port 3000 by default (can be changed via PORT environment variable)