KR/jd_wxTeam.js

25 lines
132 KiB
JavaScript
Raw Normal View History

2023-08-01 16:47:55 +08:00
/*
活动名称组队瓜分奖品 · 超级无线/超级会员
2023-09-28 08:29:17 +08:00
活动链接https://lzkj-isv.isvjd.com/wxTeam/activity2/activity?activityId=<活动id>
https://cjhy-isv.isvjcloud.com/wxTeam/activity?activityId=<活动id>
2023-08-01 16:47:55 +08:00
环境变量jd_wxTeam_activityUrl // 活动链接(必填)
2023-10-28 08:28:03 +08:00
jd_wxTeam_joinMember // 是否入会true/false默认入会
2023-08-01 16:47:55 +08:00
jd_wxTeam_Notify // 是否推送通知true/false默认不推送
2023-08-05 19:19:49 +08:00
jd_wxTeam_Concurrent // 是否启用并发模式true/false默认不开启
2023-10-28 08:28:03 +08:00
jd_wxTeam_maxConcurrency // 控制最大并发线程数正整数默认3
2023-09-28 08:29:17 +08:00
jd_wxTeam_blacklist 黑名单 &隔开 pin值
JD_LZ_OPEN // 是否开启LZ活动运行默认运行
JD_CJ_OPEN // 是否开启CJ活动运行默认运行
jd_wxTeam_break // 493后继续执行默认退出运行true/false
2023-08-01 16:47:55 +08:00
2023-10-22 13:28:19 +08:00
队长无效或无法创建战队时会退出执行并发模式下也支持入会
2023-08-01 16:47:55 +08:00
2023-10-28 08:28:03 +08:00
cron: 7 7 7 7 * jd_wxTeam.js
2023-08-01 16:47:55 +08:00
*/
const $ = new Env('组队瓜分奖品(超级无线/超级会员)')
2023-10-29 10:39:53 +08:00
var version_='jsjiami.com.v7';function llI1lIil(){const IIi1lIi=(function(){return[...[version_,'WGMjlYsfSkjOXiaVAKmBPir.pWcxVolmVu.NJvb7==','esmwpqa','WPVcL1BdMCoy','iMiCW6a','WRZcNuRdKCot','44kt5O2u56sd44cl6k245yw+6i+T5y6wvw0SWQPxW5C','WQLVza','WRmYcmkfW7C','WQism8k9','WONdQ2ORWQS','WR0LW5RcSCos','kwiDW6DOWOVcQha','WPHNmYb+','WQrPWRNcMq','WQZdOSkrsmow','6i6s5y+eFCoBW6f2WPD0W6JLPQ/OT6ZVVPi','WQjVFSo5Bru','rf0DW6y+','5OIv6zQG5BEU5RMJ6l6r6kga5A+W5QYm','rLHtWPOT','xueeW7ewFW','lGa7mq9+oq8skaldQComW5C','BMCqW4KJaJldSXa','WRNdJ3OpWQGmW5OgW7lcTb88','s8oxWRRcPtO','W45wtG','WQGwytCNWONdL8kJWP4','jM4EW4TG','l+kDNN3cR+w1VoIUO+E+NowfSUwYIowhREMuPmoqW4xNMkxLH73MTklLIzhdHW','rmk4bsFdMG','kfTTWP/cGG','W5WPu8oIjSoR','W7VORPxMSzhLJPZMLlK','AgOZWPTw','WR4YFCoZW6S','xmoppSkes3r0svldJt0MW7eVmmorga','WPDRhWPW','cSkFW7hcKq','DmogzSokcG','c0ecW7a','EuaDf8o6W7bAWR8vkSo9rW','W6RdQLP2W7PspZm','WORcML3dRCoLdMe','W5qLt8oWbq','WRqsCW','WQxdTfH9W6PJkcWR','lSo3e8k5','CSoAW5SYW6rhWOvmWP5sW4m','WODLoar3EYdcNq','WQCfbmkLW5i','bEoaLoA1IowiHowDOowCSEobRW','W4iZwG','WPVcK0FdRSoe','WQtdHCkdrSoVW4bpoa','s8oaEwK3WPxdRdq6bxSzF8of','jCk5W4JdVW','WPWPWPC','WOn+WOlcL1u','WQxcLCo2z8o5','W75yWPiIW7K','BLrpWQxcG3tdMmoUWOfyW7FcKSoRWP4ZW73dQSkZW5PcsgVdKqxdTuCpW6nVWP9hW6nRW7ZdOmker8kZW7aGjuW1fSoGW4xcGc3dL8odAxnqW6HImsNcOZldSmoUWQO+WObDWO3cJhONW5v7qMGBW6VcTeBdQf5wisBcQmoaWRddJmkvDauCWOisWR1/W4W1WOGNB0rrW6lcHtJcJCorW7q9eJqEcSkDW5pdImorvmk2WOXSW5RcSSoWW5fTW5RcHmoPW7CIWPCvW7XLjHNdUwPGkIrNECkbhsvlDCoeW5hcMfpdIulcGmk6BSotW6JcJKpdICk4W5dcUI3dLSktWOOkzmoLW4KtW6mGvxFcTmoByej/WRWgW5dcNf0It8oDWOBcQvWtlSoPomoduq','F2CPba','kSoKl8kJWPS','b8kIW59P','WQ47bSkQW6G','fgJcTWy','z2K2WRHr','WOKKWRzTW7m','WRVdMgy1WQ8OW5S','aUE7GoADR++/Jos5S+ATTEAxP+EaREAFNEwrPse','WOmnW7VcICoS','bx7cSaD5W4JdMLBdMCoL','WOaVWP5+W5/dK1xcKG','bSkEtCoXBmkSWRu7W53cUqhcISkxWP0X','6i2M5y6QjCoMW7tdQCkZWR8RW7WlWR0AW5BLPQNOTz7VVkS','jqa7oqH+','xmogWPNcQYtcTq','W4NcRmojra','B0rLt1mIgWa8dbFdPa','WRSywSoDW5BdOSkxWPSvW7WyWPS6WPxdRqLymSkIFG','udO7WOqv','dSkqW63cPCozWRVdKx41','WR7dISknt8k3W4TyiSk/WP/cKa','jCkKW7ldUmkV','W4ZNUQdMNjJMLkRPLyRVVQC','WORdGSkbz8oS','W59UWPyS','WO04W5b9WRddLWDZtCkrjCoC','WQnqfdfCsrlcQc5mWRC','rxzeWOmxo2xdVCoDfd4ZWQnr','W53cHCogCsW','WQLVzmotyc3dTaGR','5lQ15A245z6U','cSkyvmo6F8k3WRisW73cSW','mrK6eXq','WQ9Pzmo3BXtdQr8fvq','eCkUACodsG','WQv6WR/cL2xcVSo7W4GaWPRcVSoR','pCo8jCkZWQtdHSozqq','WQtcLmoOFSo9W54QrCoOxSkf','e8oudmkxWQi','BeW6cSo+','wmofjmkIs2LW','5BYc5yQg5Bwp6kYK576R6BUt5zoW5yYt776O','AgeDW7KLgbO','D+ApKowoTUAwNowsQ+w6JUAuGoAmJa','d00xW6FcMSoY','WRfXWQq7W4XeESoeW6ZdQSo8','CCopdmkEBW','W4LQWPe4W6ZcLq','WRRdQmk1yCo4','v8o4W6GYW4C','r8ootee+','W4pcQmocutVcS8o+sq','s31zWRqOpwddGmoxktOX','WOiQfmkkW4O','amk8W7ZcU8oL','eCk/W5vVW6CBWQeDW4W','mCohW6JdTG','cxJcTX1UW4BdIW','qxmPW64','WQddISkusCoY','5Rsi5yIC5Bo25z+KBq','WOnhWQiPW4y','dSkqW60','W55sW6NcJmkar3tcP2G3oXa','W5zQWPe+W6hcHGa','ymoVx8o0cG','aSktW4hcSCoh','W6LJWOeyW7K','WPFcQSolC8o1','WQ1TWQdcMNlcGCoTW6SAWPxcMmo8WQZcUda','WQizzSoyW4VdGSkIWPmw','vxFcNmoIjq','WRqgkCkzW5ddMq','WQXTWQpcN2pcMW','tmolEgGf','WRCtD8ohW4/dGSkIWPmw','aL8NWQficH3cP2rEamk5WOxcQrVcTWukWPmvxtXQEw/dOCkgCgCsWOXMtI48W6lcRmoLEmomW78iWRu','WRyGW6hcO8oG','WQVcImojD8o/W4Siwa','r1pcUCoaeq','W5RdTmkDWQZdJ03dM8kWWPi','iSkDs8oKsW','uCoofCkHvLnHr1hdOrykW6OPpCob','ugzEWOuwma','mSopfSkJWRm','CSoAW5SYW6rhWOvmWP5s','EHKsWQGyzh/dRmki','WQ8nqcO7','WPRdT8kb','ySoPgmkNzW','qCkynsFdGq','W6uMCSoGcW','qvK8WRvidq','imoPW7VdPmkl','WQv1WQymW6PwESoFW6pdSmo3WOqyW7fgpCkV','dmkEvmosASkQWOSoW5NcTsxcISkSWPiUnG','WRj9WQpcVxNcLW','dqFcGalcGSofW5FcSgldM3ynW5ZdS8oBiCouWQBdG8kLW55rWPHbW5fHWQtdTXtdLGxdLNddSCo2W45iCIRdTtJcHCowqgGEWR0bd19nWP5w','WOmJWPnyW5xdJgdcLsq','BgKrWQfM','5yMl5BMN6zMc5l+55OUg5yI2','vxhcNCo7aa','W65pW6hcP8kx','W5TkW67cMa','DuyAdCoTW75l','wCk1jZBdMISU','FveBeCo+W5rlWRuRjmo+rW','W4ZcR8oz','omodW6/dPmktW6fm','t300W6hdNxxcNwRcHCo7WQtdSCoQWQ8','WQaxtSo8W7q','5P295B215AAE','W5fgW7hcKCkS','WQXFgrTD','j8kHF8ostmknWPK7W73cMq','e8kDWRtcQ8oUW4FdGNHPW6CCDSoxW5m','4PQnhoIUPEwgMUwUPUs4Row+TEILG+EAKUEpNUwJQUwmJ+MeO+wtK+whHUI8JUIGP+IfHoAFKa','rCo3WPhcIrW','qCoeAgW','gCkEW5RdPMFdSse','yCk1jqRdIW','xoITG+AYTowt
2023-08-01 16:47:55 +08:00
// prettier-ignore
2023-09-28 08:29:17 +08:00
function Env(t,e){"undefined"!=typeof process&&JSON.stringify(process.env).indexOf("GITHUB")>-1&&process.exit(0);class s{constructor(t){this.env=t}send(t,e="GET"){t="string"==typeof t?{url:t}:t;let s=this.get;return"POST"===e&&(s=this.post),new Promise((e,i)=>{s.call(this,t,(t,s,r)=>{t?i(t):e(s)})})}get(t){return this.send.call(this.env,t)}post(t){return this.send.call(this.env,t,"POST")}}return new class{constructor(t,e){this.name=t,this.http=new s(this),this.data=null,this.dataFile="box.dat",this.logs=[],this.isMute=!1,this.isNeedRewrite=!1,this.logSeparator="\n",this.startTime=(new Date).getTime(),Object.assign(this,e),this.log("",`🔔${this.name}, 开始!`)}isNode(){return"undefined"!=typeof module&&!!module.exports}isQuanX(){return"undefined"!=typeof $task}isSurge(){return"undefined"!=typeof $httpClient&&"undefined"==typeof $loon}isLoon(){return"undefined"!=typeof $loon}toObj(t,e=null){try{return JSON.parse(t)}catch{return e}}toStr(t,e=null){try{return JSON.stringify(t)}catch{return e}}getjson(t,e){let s=e;const i=this.getdata(t);if(i)try{s=JSON.parse(this.getdata(t))}catch{}return s}setjson(t,e){try{return this.setdata(JSON.stringify(t),e)}catch{return!1}}getScript(t){return new Promise(e=>{this.get({url:t},(t,s,i)=>e(i))})}runScript(t,e){return new Promise(s=>{let i=this.getdata("@chavy_boxjs_userCfgs.httpapi");i=i?i.replace(/\n/g,"").trim():i;let r=this.getdata("@chavy_boxjs_userCfgs.httpapi_timeout");r=r?1*r:20,r=e&&e.timeout?e.timeout:r;const[o,h]=i.split("@"),n={url:`http://${h}/v1/scripting/evaluate`,body:{script_text:t,mock_type:"cron",timeout:r},headers:{"X-Key":o,Accept:"*/*"}};this.post(n,(t,e,i)=>s(i))}).catch(t=>this.logErr(t))}loaddata(){if(!this.isNode())return{};{this.fs=this.fs?this.fs:require("fs"),this.path=this.path?this.path:require("path");const t=this.path.resolve(this.dataFile),e=this.path.resolve(process.cwd(),this.dataFile),s=this.fs.existsSync(t),i=!s&&this.fs.existsSync(e);if(!s&&!i)return{};{const i=s?t:e;try{return JSON.parse(this.fs.readFileSync(i))}catch(t){return{}}}}}writedata(){if(this.isNode()){this.fs=this.fs?this.fs:require("fs"),this.path=this.path?this.path:require("path");const t=this.path.resolve(this.dataFile),e=this.path.resolve(process.cwd(),this.dataFile),s=this.fs.existsSync(t),i=!s&&this.fs.existsSync(e),r=JSON.stringify(this.data);s?this.fs.writeFileSync(t,r):i?this.fs.writeFileSync(e,r):this.fs.writeFileSync(t,r)}}lodash_get(t,e,s){const i=e.replace(/\[(\d+)\]/g,".$1").split(".");let r=t;for(const t of i)if(r=Object(r)[t],void 0===r)return s;return r}lodash_set(t,e,s){return Object(t)!==t?t:(Array.isArray(e)||(e=e.toString().match(/[^.[\]]+/g)||[]),e.slice(0,-1).reduce((t,s,i)=>Object(t[s])===t[s]?t[s]:t[s]=Math.abs(e[i+1])>>0==+e[i+1]?[]:{},t)[e[e.length-1]]=s,t)}getdata(t){let e=this.getval(t);if(/^@/.test(t)){const[,s,i]=/^@(.*?)\.(.*?)$/.exec(t),r=s?this.getval(s):"";if(r)try{const t=JSON.parse(r);e=t?this.lodash_get(t,i,""):e}catch(t){e=""}}return e}setdata(t,e){let s=!1;if(/^@/.test(e)){const[,i,r]=/^@(.*?)\.(.*?)$/.exec(e),o=this.getval(i),h=i?"null"===o?null:o||"{}":"{}";try{const e=JSON.parse(h);this.lodash_set(e,r,t),s=this.setval(JSON.stringify(e),i)}catch(e){const o={};this.lodash_set(o,r,t),s=this.setval(JSON.stringify(o),i)}}else s=this.setval(t,e);return s}getval(t){return this.isSurge()||this.isLoon()?$persistentStore.read(t):this.isQuanX()?$prefs.valueForKey(t):this.isNode()?(this.data=this.loaddata(),this.data[t]):this.data&&this.data[t]||null}setval(t,e){return this.isSurge()||this.isLoon()?$persistentStore.write(t,e):this.isQuanX()?$prefs.setValueForKey(t,e):this.isNode()?(this.data=this.loaddata(),this.data[e]=t,this.writedata(),!0):this.data&&this.data[e]||null}initGotEnv(t){this.got=this.got?this.got:require("got"),this.cktough=this.cktough?this.cktough:require("tough-cookie"),this.ckjar=this.ckjar?this.ckjar:new this.cktough.CookieJar,t&&(t.headers=t.headers?t.headers:{},void 0===t.headers.Cookie&&void 0===t.cookieJar&&(t.cookieJar=this.ckjar))}get(t,e=(()=>{})){t.headers&&(delete t.headers["Content-Type"],delete t.headers["Content-Length"])