@lzwme/m3u8-dl
Version:
Batch download of m3u8 files and convert to mp4
21 lines (20 loc) • 608 B
TypeScript
import type { ApiResponse, M3u8DLOptions, M3u8DLResult, VideoInfo } from '../types';
export declare class VideoParser {
private static readonly platforms;
/**
* 解析视频 URL
*/
parse(url: string, headers?: Record<string, string>): Promise<ApiResponse<VideoInfo>>;
download(url: string, options: M3u8DLOptions): Promise<M3u8DLResult>;
/**
* 根据 URL 获取平台标识
*/
static getPlatform(url: string): {
url: string;
platform: string;
};
/**
* 获取所有支持的平台列表
*/
getSupportedPlatforms(): string[];
}