MoonTv 一键搭建数据接口
使用方法: https://video.gaojilingjuli.top/?url=https://raw.githubusercontent.com/666zmy/MoonTV/refs/heads/main/config.json&pretty=true addEventListener ( 'fetch' , event => { event . respondWith ( handleRequest ( event . request )) } ) async function handleRequest ( request ) { try { // 解析 URL 参数 const url = new URL ( request . url ) const targetUrl = url . searchParams . get ( 'url' ) if ( !targetUrl ) { return new Response ( 'Missing url parameter' , { status : 400 } ) } // 验证 URL 格式 try { new URL ( targetUrl ) } catch { return new Response ( 'Invalid URL format' , { status : 400 } ) } // 从远程获取 JSON const response = await fetch ( targetUrl ) ...