From a1a3a35b39b020444ac11b338d0c10d35d082d50 Mon Sep 17 00:00:00 2001 From: yeyin <959567563@qq.com> Date: Wed, 14 Jan 2026 11:42:39 +0000 Subject: [PATCH] =?UTF-8?q?=E4=B8=8A=E4=BC=A0=E6=96=87=E4=BB=B6=E8=87=B3?= =?UTF-8?q?=20gtly/lib?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- gtly/lib/啦啦DJ.js | 22 +++++++ gtly/lib/快看.js | 42 ++++++++++++++ gtly/lib/酷云77.js | 140 +++++++++++++++++++++++++++++++++++++++++++++ gtly/lib/酷奇MV.js | 25 ++++++++ gtly/lib/酷狗MV.js | 21 +++++++ 5 files changed, 250 insertions(+) create mode 100644 gtly/lib/啦啦DJ.js create mode 100644 gtly/lib/快看.js create mode 100644 gtly/lib/酷云77.js create mode 100644 gtly/lib/酷奇MV.js create mode 100644 gtly/lib/酷狗MV.js diff --git a/gtly/lib/啦啦DJ.js b/gtly/lib/啦啦DJ.js new file mode 100644 index 0000000..363d506 --- /dev/null +++ b/gtly/lib/啦啦DJ.js @@ -0,0 +1,22 @@ +var rule = { + title:'啦啦DJ', + host:'http://www.laladj.com', + // url: '/dance/id-fyclass-fypage.html', + url: '/fyclass-0-0-fypage', + searchUrl: '/search?search=**&page=fypage', + searchable:2, + quickSearch:0, + headers:{ + 'User-Agent': 'PC_UA' + }, + timeout:5000,//网站的全局请求超时,默认是3000毫秒 + class_parse:'.navbar&&.xcls0;a&&Text;a&&href;com/(.*)', + play_parse:true, + lazy:'js:input=input.replace("www","m")', + limit:6, + 推荐: '.center_fl&&.recommended-list;li;img&&alt;img&&src;.index-music-hit--b&&Text;a&&href', + double: true, // 推荐内容是否双层定位 + 一级:'.list_musiclist&&.sbg;.t1&&Text;img&&src;.sc_2:eq(0)&&Text;a&&href', + 二级: "*", + 搜索: "*", +} \ No newline at end of file diff --git a/gtly/lib/快看.js b/gtly/lib/快看.js new file mode 100644 index 0000000..35e7762 --- /dev/null +++ b/gtly/lib/快看.js @@ -0,0 +1,42 @@ +var rule={ + title:'快看', + host:'https://www.kuaikanys.net', + // homeUrl:'/', + url:'/s/fyfilter/page/fypage.html', + filterable:1,//是否启用分类筛选, + filter_url:'{{fl.cateId}}', + filter: {"dianying":[{"key":"cateId","name":"类型","value":[{"n":"全部","v":"dianying"},{"n":"动作片","v":"dongzuopian"},{"n":"喜剧片","v":"xijupian"},{"n":"爱情片","v":"aiqingpian"},{"n":"科幻片","v":"kehuanpian"},{"n":"言情片","v":"yanqingpian"},{"n":"恐怖片","v":"kongbupian"},{"n":"剧情片","v":"juqingpian"},{"n":"战争片","v":"zhanzhengpian"}]}],"lianxuju":[{"key":"cateId","name":"类型","value":[{"n":"全部","v":"lianxuju"},{"n":"国产剧","v":"guochanju"},{"n":"港台剧","v":"gangtaiju"},{"n":"日韩剧","v":"rihanju"},{"n":"欧美剧","v":"oumeiju"},{"n":"其他剧","v":"qitaju"}]}]}, + filter_def:{ + dianying:{cateId:'dianying'}, + lianxuju:{cateId:'lianxuju'}, + zongyi:{cateId:'zongyi'}, + dongman:{cateId:'dongman'} + }, + searchUrl:'/vodsearch/-------------.html?wd=**&submit=', + searchable:2,//是否启用全局搜索, + quickSearch:0,//是否启用快速搜索, + headers:{//网站的请求头,完整支持所有的,常带ua和cookies + 'User-Agent':'MOBILE_UA', + // "Cookie": "searchneed=ok" + }, + class_parse:'nav ul li;a&&Text;a&&href;.*/(.*?)\.html', + cate_exclude:'专题', + play_parse:true, + lazy:'', + limit:6, + 推荐:'.show:eq(1);ul&&li;*;*;*;*', + double:true, // 推荐内容是否双层定位 + 一级:'.show&&ul&&li;a&&title;img&&src;.score&&Text;a&&href', + // 二级:{"title":"h1&&Text;.info&&ul&&p&&Text","img":"img&&src","desc":".info&&ul&&p:eq(-2)&&Text;.info&&ul&&p:eq(-1)&&Text;.info&&ul&&p:eq(0)&&Text;.info&&ul&&p:eq(1)&&Text;.info&&ul&&p:eq(2)&&Text;.info&&ul&&p:eq(3)&&Text","content":".text&&Text","tabs":".play&&span","lists":".playlist&&ul:eq(#id) li"}, + 二级:{ + "title":"h1&&Text;.info&&ul&&p&&Text", + "img":"img&&src", + "desc":";;;.info ul li:eq(0)&&Text;.info ul li:eq(1)&&Text;.info&&ul&&p:eq(3)&&Text", + // "content":".text p&&Text", + "content":".text&&Text", + "tabs":".play&&span", + "lists":".playlist&&ul:eq(#id) li" + }, + 搜索:'*', + // 搜索:'*;*;*;*;*', +} diff --git a/gtly/lib/酷云77.js b/gtly/lib/酷云77.js new file mode 100644 index 0000000..7e6f6bb --- /dev/null +++ b/gtly/lib/酷云77.js @@ -0,0 +1,140 @@ +// 注意事项:此源仅支持tvbox的js1以及c#版drpy的js0,暂不支持drpy官方py版的js0 + +// 注入全局方法,方便 +globalThis.getTime = function(){ +let ts= Math.round(new Date().getTime()/1000).toString(); +log('获取时间戳:'+ts); +return ts +} + +globalThis.getHeaders= function(input,ts){ +let tkstr=input.split('?')[1].split('&').map(function(it){ + return it.split('=')[1] +}).join(''); +tkstr=input.split('?')[0].replace('https://api.tyun77.cn','')+tkstr+ts+'XSpeUFjJ'; +log('tk加密前:'+tkstr); +let TK=md5(tkstr); +log('tk加密后:'+TK); +let headers={ + "User-Agent":"okhttp/3.12.0", + "TK":TK +}; +return headers +} + +var rule = { + title:'酷云77', + host:'https://api.tyun77.cn', + hostJs:'let html=request(HOST+"/api.php/provide/getDomain");', + homeUrl:'/api.php/provide/homeBlock?type_id=0', + searchUrl:'/api.php/provide/searchVideo?searchName=**', + searchable:2, + quickSearch:0, + filterable:1, + multi:1, + // 分类链接fypage参数支持1个()表达式 + // url:'/api.php/provide/searchFilter?type_id=fyclass&pagesize=24&pagenum=fypage', // 旧的写法注释掉 + url:'/api.php/provide/searchFilter?devid=453CA5D864457C7DB4D0EAA93DE96E66&package=com.sevenVideo.app.android&pagenum=fypage&pagesize=24&version=&sj=$ts&type_id=fyclass', + // detailUrl:'/api.php/provide/videoDetail?devid=453CA5D864457C7DB4D0EAA93DE96E66&package=com.sevenVideo.app.android&version=&ids=fyid', //旧的写法注释掉 + detailUrl:'/api.php/provide/videoDetail?devid=453CA5D864457C7DB4D0EAA93DE96E66&ids=fyid&package=com.sevenVideo.app.android&version=', + filter_url:'year={{fl.y}}&category={{fl.scat}}&area={{fl.a}}', + filter:{0: [{'key': 'y', 'name': '年代', 'value': [{'n': '全部', 'v': ''},{'n': '2023', 'v': '2023'}, {'n': '2022', 'v': '2022'}, {'n': '2021', 'v': '2021'}, {'n': '2020', 'v': '2020'}, {'n': '2019', 'v': '2019'}, {'n': '2018', 'v': '2018'}, {'n': '2017', 'v': '2017'}, {'n': '2016', 'v': '2016'}, {'n': '2015', 'v': '2015'}, {'n': '2015之前', 'v': 'lt|2015'}]}, {'key': 'a', 'name': '地区', 'value': [{'n': '全部', 'v': ''}, {'n': '中国大陆', 'v': '中国大陆'}, {'n': '美国', 'v': '美国'}, {'n': '日本', 'v': '日本'}, {'n': '中国香港', 'v': '中国香港'}, {'n': '中国台湾', 'v': '中国台湾'}, {'n': '韩国', 'v': '韩国'}, {'n': '欧洲', 'v': '欧洲'}, {'n': '其他', 'v': '泰国'}]}, {'key': 'scat', 'name': '类型', 'value': [{'n': '全部', 'v': ''}, {'n': '剧情', 'v': '剧情'}, {'n': '动作', 'v': '动作'}, {'n': '科幻', 'v': '科幻'}, {'n': '喜剧', 'v': '喜剧'}, {'n': '战争', 'v': '战争'}, {'n': '爱情', 'v': '爱情'}, {'n': '恐怖', 'v': '恐怖'}, {'n': '伦理', 'v': '伦理'}]}], 1: [{'key': 'y', 'name': '年代', 'value': [{'n': '全部', 'v': ''},{'n': '2023', 'v': '2023'}, {'n': '2022', 'v': '2022'}, {'n': '2021', 'v': '2021'}, {'n': '2020', 'v': '2020'}, {'n': '2019', 'v': '2019'}, {'n': '2018', 'v': '2018'}, {'n': '2017', 'v': '2017'}, {'n': '2016', 'v': '2016'}, {'n': '2015', 'v': '2015'}, {'n': '2015之前', 'v': 'lt|2015'}]}, {'key': 'a', 'name': '地区', 'value': [{'n': '全部', 'v': ''}, {'n': '中国大陆', 'v': '中国大陆'}, {'n': '美国', 'v': '美国'}, {'n': '日本', 'v': '日本'}, {'n': '中国香港', 'v': '中国香港'}, {'n': '中国台湾', 'v': '中国台湾'}, {'n': '韩国', 'v': '韩国'}, {'n': '欧洲', 'v': '欧洲'}, {'n': '其他', 'v': '泰国'}]}, {'key': 'scat', 'name': '类型', 'value': [{'n': '全部', 'v': ''}, {'n': '剧情', 'v': '剧情'}, {'n': '动作', 'v': '动作'}, {'n': '科幻', 'v': '科幻'}, {'n': '喜剧', 'v': '喜剧'}, {'n': '战争', 'v': '战争'}, {'n': '爱情', 'v': '爱情'}, {'n': '恐怖', 'v': '恐怖'}, {'n': '伦理', 'v': '伦理'}]}], 2: [{'key': 'y', 'name': '年代', 'value': [{'n': '全部', 'v': ''},{'n': '2023', 'v': '2023'}, {'n': '2022', 'v': '2022'}, {'n': '2021', 'v': '2021'}, {'n': '2020', 'v': '2020'}, {'n': '2019', 'v': '2019'}, {'n': '2018', 'v': '2018'}, {'n': '2017', 'v': '2017'}, {'n': '2016', 'v': '2016'}, {'n': '2015', 'v': '2015'}, {'n': '2015之前', 'v': 'lt|2015'}]}, {'key': 'a', 'name': '地区', 'value': [{'n': '全部', 'v': ''}, {'n': '中国大陆', 'v': '中国大陆'}, {'n': '美国', 'v': '美国'}, {'n': '日本', 'v': '日本'}, {'n': '中国香港', 'v': '中国香港'}, {'n': '中国台湾', 'v': '中国台湾'}, {'n': '韩国', 'v': '韩国'}, {'n': '欧洲', 'v': '欧洲'}, {'n': '其他', 'v': '泰国'}]}, {'key': 'scat', 'name': '类型', 'value': [{'n': '全部', 'v': ''}, {'n': '剧情', 'v': '剧情'}, {'n': '动作', 'v': '动作'}, {'n': '科幻', 'v': '科幻'}, {'n': '喜剧', 'v': '喜剧'}, {'n': '战争', 'v': '战争'}, {'n': '爱情', 'v': '爱情'}, {'n': '恐怖', 'v': '恐怖'}, {'n': '伦理', 'v': '伦理'}]}], 3: [{'key': 'y', 'name': '年代', 'value': [{'n': '全部', 'v': ''},{'n': '2023', 'v': '2023'}, {'n': '2022', 'v': '2022'}, {'n': '2021', 'v': '2021'}, {'n': '2020', 'v': '2020'}, {'n': '2019', 'v': '2019'}, {'n': '2018', 'v': '2018'}, {'n': '2017', 'v': '2017'}, {'n': '2016', 'v': '2016'}, {'n': '2015', 'v': '2015'}, {'n': '2015之前', 'v': 'lt|2015'}]}, {'key': 'a', 'name': '地区', 'value': [{'n': '全部', 'v': ''}, {'n': '中国大陆', 'v': '中国大陆'}, {'n': '美国', 'v': '美国'}, {'n': '日本', 'v': '日本'}, {'n': '中国香港', 'v': '中国香港'}, {'n': '中国台湾', 'v': '中国台湾'}, {'n': '韩国', 'v': '韩国'}, {'n': '欧洲', 'v': '欧洲'}, {'n': '其他', 'v': '泰国'}]}, {'key': 'scat', 'name': '类型', 'value': [{'n': '全部', 'v': ''}, {'n': '剧情', 'v': '剧情'}, {'n': '动作', 'v': '动作'}, {'n': '科幻', 'v': '科幻'}, {'n': '喜剧', 'v': '喜剧'}, {'n': '战争', 'v': '战争'}, {'n': '爱情', 'v': '爱情'}, {'n': '恐怖', 'v': '恐怖'}, {'n': '伦理', 'v': '伦理'}]}], 4: [{'key': 'y', 'name': '年代', 'value': [{'n': '全部', 'v': ''},{'n': '2023', 'v': '2023'}, {'n': '2022', 'v': '2022'}, {'n': '2021', 'v': '2021'}, {'n': '2020', 'v': '2020'}, {'n': '2019', 'v': '2019'}, {'n': '2018', 'v': '2018'}, {'n': '2017', 'v': '2017'}, {'n': '2016', 'v': '2016'}, {'n': '2015', 'v': '2015'}, {'n': '2015之前', 'v': 'lt|2015'}]}, {'key': 'a', 'name': '地区', 'value': [{'n': '全部', 'v': ''}, {'n': '中国大陆', 'v': '中国大陆'}, {'n': '美国', 'v': '美国'}, {'n': '日本', 'v': '日本'}, {'n': '中国香港', 'v': '中国香港'}, {'n': '中国台湾', 'v': '中国台湾'}, {'n': '韩国', 'v': '韩国'}, {'n': '欧洲', 'v': '欧洲'}, {'n': '其他', 'v': '泰国'}]}, {'key': 'scat', 'name': '类型', 'value': [{'n': '全部', 'v': ''}, {'n': '剧情', 'v': '剧情'}, {'n': '动作', 'v': '动作'}, {'n': '科幻', 'v': '科幻'}, {'n': '喜剧', 'v': '喜剧'}, {'n': '战争', 'v': '战争'}, {'n': '爱情', 'v': '爱情'}, {'n': '恐怖', 'v': '恐怖'}, {'n': '伦理', 'v': '伦理'}]}]}, + headers:{ + "User-Agent":"okhttp/3.12.0" + }, + timeout:5000, + class_name:'全部&电影&电视剧&综艺&动漫', + class_url:'0&1&2&3&4', + limit:20, + play_parse:true, + play_json:0, + // 手动调用解析请求json的url,此lazy不方便 + // lazy:'js:input={parse:1,url:input};', + lazy:'', + lazy:'js:function GetPlayUrl(playUrl){let realPlay={parse:0,url:playUrl};if(/mgtv|sohu/.test(playUrl)){realPlay.headers={"User-Agent":"Mozilla/5.0"}}else if(/bili/.test(playUrl)){realPlay.headers={"User-Agent":"Mozilla/5.0",Referer:"https://www.bilibili.com"}}else if(/ixigua/.test(playUrl)){realPlay.headers={"User-Agent":"Mozilla/5.0",Referer:"https://www.ixigua.com"}}return realPlay}if(/\\.m3u8|\\.mp4/.test(input)){input={parse:0,url:input}}else{try{let jxUrl="http://api.tyun77.cn/api.php/provide/parserUrl?url=";var t=Math.floor((new Date).getTime()/1e3).toString();let jxExt="&retryNum=0&pcode=010110002&version=2.1&devid=f9c9ce5bb5827a266829383718e6131a&package=com.sevenVideo.app.android&sys=android&sysver=12&brand=Xiaomi&model=Mi_10_Pro&sj="+t;let url=jxUrl+input+jxExt;let TK="/api.php/provide/parserUrl"+"Xiaomif9c9ce5bb5827a266829383718e6131aMi_10_Procom.sevenVideo.app.android010110002"+0+t+"android12"+encodeURIComponent(vipUrl)+"2.1"+t+"XSpeUFjJ";let html=request(url,{headers:{Referer:jxUrl,"User-Agent":"okhttp/3.12.0",TK:md5(TK)}});let urll=JSON.parse(html).data.url;let playhtml=request(urll);let playurl=JSON.parse(playhtml).url;input=GetPlayUrl(playurl)}catch(e){input={parse:1,jx:1,url:input}}}', + 推荐:'json:data.blocks;contents;title;videoCover;msg;id', + double:true, + // 一级:'json:data.result;title;videoCover;msg;id', 旧的写法注释掉 + 一级:`js: + var d=[]; + let ts= getTime(); + input=input.replace('$ts',ts); + let html = request(input,{ + headers:getHeaders(input,ts) + }); + //print(html); + html = JSON.parse(html); + html.data.result.forEach(function(it){ + d.push({ + title:it.title, + img:it.videoCover, + desc:it.msg, + url:it.id + }) + }); + setResult(d); + `, + 二级:`js: var d = []; + VOD = { + vod_id: input + }; + let ts= getTime(); +try { + input=input+'&sj='+ts; + let html = request(input,{ + headers:getHeaders(input,ts) + }); + //print(html); + html = JSON.parse(html); + let node = html.data; + VOD = { + vod_id: node["id"], + vod_name: node["videoName"], + vod_pic: node["videoCover"], + type_name: node["subCategory"], + vod_year: node["year"], + vod_area: node["area"], + vod_remarks: node["msg"], + vod_actor: node["actor"], + vod_director: node["director"], + vod_content: node["brief"].strip() + }; + let tid = input.split("ids=")[1].split('&')[0]; + let listUrl='https://api.tyun77.cn/api.php/provide/videoPlaylist?devid=453CA5D864457C7DB4D0EAA93DE96E66&ids='+tid+'&package=com.sevenVideo.app.android&version=&sj='+ts; + html = request(listUrl,{ + headers:getHeaders(listUrl,ts) + }); + html = JSON.parse(html); + let episodes = html.data.episodes; + let playMap = {}; + if (typeof play_url === "undefined") { + var play_url = "" + } + play_url = play_url.replace("&play_url=", "&type=json&play_url="); + episodes.forEach(function(ep) { + let playurls = ep["playurls"]; + playurls.forEach(function(playurl) { + let source = playurl["playfrom"]; + if (!playMap.hasOwnProperty(source)) { + playMap[source] = [] + } + playMap[source].append(playurl["title"].strip() + "$" + play_url + urlencode(playurl["playurl"])) + }) + }); + let playFrom = []; + let playList = []; + Object.keys(playMap) + .forEach(function(key) { + playFrom.append(key); + playList.append(playMap[key].join("#")) + }); + let vod_play_from = playFrom.join("$$$"); + let vod_play_url = playList.join("$$$"); + VOD["vod_play_from"] = vod_play_from; + VOD["vod_play_url"] = vod_play_url +} catch (e) { + log("获取二级详情页发生错误:" + e.message) +}`, + 搜索:'', + 搜索:'json:data;videoName;videoCover;msg;id', +} \ No newline at end of file diff --git a/gtly/lib/酷奇MV.js b/gtly/lib/酷奇MV.js new file mode 100644 index 0000000..742bd48 --- /dev/null +++ b/gtly/lib/酷奇MV.js @@ -0,0 +1,25 @@ +var rule = { + title:'酷奇MV', + host:'https://www.kuqimv.com', + // homeUrl:'/play/', + url:'/play/fyclass_fypage.html', + searchUrl:'/search.php?key=**&pages=fypage', + searchable:2, + quickSearch:0, + // class_parse:'.main:eq(1)&&li;a&&Text;a&&href;.*/(\\d+)_1.html', + // class_parse:'.lei_class&&a;a&&Text;a&&href;.*/(\\d+)_1.html', + class_name:'华语高清&日韩精选&欧美MV&高清现场&影视MV&夜店视频&车模视频&热舞视频&美女写真&美女打碟', + class_url:'1&2&3&4&5&6&7&8&9&10', + headers:{ + 'User-Agent':'MOBILE_UA' + }, + timeout:5000, + play_parse:true, + lazy:'', + limit:6, + double:false, + 推荐:'*', + 一级:'js:var d=[];pdfh=jsp.pdfh;pdfa=jsp.pdfa;pd=jsp.pd;var html=request(input);let list=pdfa(html,".mv_list&&li");list.forEach((it)=>{d.push({title:pdfh(it,".name&&Text"),desc:"🎤"+pdfh(it,".singer&&Text")+"|"+pdfh(it,".time&&Text"),pic_url:pd(it,"img&&src"),url:pd(it,"a&&href"),})});setResult(d);', + 二级:'*', + 搜索:'.video_list&&li;a&&title;;.singer&&Text;a&&href;.t_03:eq(1)&&Text', +} \ No newline at end of file diff --git a/gtly/lib/酷狗MV.js b/gtly/lib/酷狗MV.js new file mode 100644 index 0000000..66cf93e --- /dev/null +++ b/gtly/lib/酷狗MV.js @@ -0,0 +1,21 @@ +var rule = { + title:'酷狗MV', + host:'https://www.kugou.com', + homeUrl:'/mvweb/html/', + url:'/mvweb/html/index_fyclass_fypage.html', + searchUrl:'https://api.linhun.vip/api/kgmv?apiKey=e7e165ab27316db14467c07e00f3820d&name=**&n=', + searchable:2, + quickSearch:0, + class_parse:'#radioList&ⅆa&&Text;a&&href;.*/index_(\\d+)_1.html', + headers:{ + 'User-Agent':'PC_UA' + }, + timeout:5000, + play_parse:true, + lazy:'js:if(/mp4/.test(input)){input}else{var mv_name=request(input).match(/mv_name = "(.*?)"/)[1];input=JSON.parse(request("https://api.linhun.vip/api/kgmv?apiKey=e7e165ab27316db14467c07e00f3820d&name="+mv_name+"&n=1")).video}', + limit:6, + 推荐:'*', + 一级:'.mvlist li;a&&title;img&&_src;;a&&href', + 二级:'*', + 搜索:'js:let d=[];let html=request(input);let list=JSON.parse(html).sun;for(let j=1;j<=list;j++){let t=JSON.parse(request(MY_URL+j));d.push({title:t.name,desc:t.author,img:t.img,url:t.video})}setResult(d)', +} \ No newline at end of file