/*
活动名称：账号健康检查 · 超级无线/超级会员

用于检测账号是否黑了，没有变量直接运行即可不适用一般活动

⚠ 请勿定时或频繁运行！

7 7 7 7 * 

*/

const $ = new Env('账号健康检查（超级无线/超级会员）')
const jdCookie = require('./jdCookie')
const common = require('./function/jdCommon')
const notify = require('./function/sendJDNotify')
const getToken = require('./function/getToken')

var version_='jsjiami.com.v7';const IIiii11l=iIii1iiI;function iIii1iiI(_0x553d04,_0x3205f5){const _0xf03b8c=i1IIIl11();return iIii1iiI=function(_0x491b35,_0x121d3d){_0x491b35=_0x491b35-0x14c;let _0x4ff889=_0xf03b8c[_0x491b35];if(iIii1iiI['eSwiqK']===undefined){var _0x3339c6=function(_0x598876){const _0xae0ae0='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x20157f='',_0x1bfae8='';for(let _0x2d478b=0x0,_0x59f2fe,_0x1e15e4,_0x74ae7f=0x0;_0x1e15e4=_0x598876['charAt'](_0x74ae7f++);~_0x1e15e4&&(_0x59f2fe=_0x2d478b%0x4?_0x59f2fe*0x40+_0x1e15e4:_0x1e15e4,_0x2d478b++%0x4)?_0x20157f+=String['fromCharCode'](0xff&_0x59f2fe>>(-0x2*_0x2d478b&0x6)):0x0){_0x1e15e4=_0xae0ae0['indexOf'](_0x1e15e4);}for(let _0x109875=0x0,_0x4a120f=_0x20157f['length'];_0x109875<_0x4a120f;_0x109875++){_0x1bfae8+='%'+('00'+_0x20157f['charCodeAt'](_0x109875)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x1bfae8);};iIii1iiI['cXoMCQ']=_0x3339c6,_0x553d04=arguments,iIii1iiI['eSwiqK']=!![];}const _0x63b9b6=_0xf03b8c[0x0],_0x5556ca=_0x491b35+_0x63b9b6,_0x2db445=_0x553d04[_0x5556ca];return!_0x2db445?(_0x4ff889=iIii1iiI['cXoMCQ'](_0x4ff889),_0x553d04[_0x5556ca]=_0x4ff889):_0x4ff889=_0x2db445,_0x4ff889;},iIii1iiI(_0x553d04,_0x3205f5);}(function(iiIIii1l,iI11l1I,llIililI,l11iIli,Il1llii1,ilIii,i1ll11l){return iiIIii1l=iiIIii1l>>0x1,ilIii='hs',i1ll11l='hs',function(IiIliii,IlilIIl1,iillIlII,I11i11li,IliiiII){const l1I1ii1I=iIii1iiI;I11i11li='tfi',ilIii=I11i11li+ilIii,IliiiII='up',i1ll11l+=IliiiII,ilIii=iillIlII(ilIii),i1ll11l=iillIlII(i1ll11l),iillIlII=0x0;const lli1Il11=IiIliii();while(!![]&&--l11iIli+IlilIIl1){try{I11i11li=-parseInt(l1I1ii1I(0x219))/0x1*(parseInt(l1I1ii1I(0x1b7))/0x2)+parseInt(l1I1ii1I(0x183))/0x3+parseInt(l1I1ii1I(0x215))/0x4*(parseInt(l1I1ii1I(0x1f1))/0x5)+parseInt(l1I1ii1I(0x195))/0x6+parseInt(l1I1ii1I(0x23e))/0x7*(-parseInt(l1I1ii1I(0x1b4))/0x8)+-parseInt(l1I1ii1I(0x23c))/0x9+-parseInt(l1I1ii1I(0x166))/0xa*(-parseInt(l1I1ii1I(0x1d9))/0xb);}catch(iIiIl1i1){I11i11li=iillIlII;}finally{IliiiII=lli1Il11[ilIii]();if(iiIIii1l<=l11iIli)iillIlII?Il1llii1?I11i11li=IliiiII:Il1llii1=IliiiII:iillIlII=IliiiII;else{if(iillIlII==Il1llii1['replace'](/[JeDgAQWRnIkfNVGOTMyF=]/g,'')){if(I11i11li===IlilIIl1){lli1Il11['un'+ilIii](IliiiII);break;}lli1Il11[i1ll11l](IliiiII);}}}}}(llIililI,iI11l1I,function(iIIil11i,II1lI1i1,li1l11lI,l1Iilil,lIi1I1,il1iIliI,lil1IIli){return II1lI1i1='\x73\x70\x6c\x69\x74',iIIil11i=arguments[0x0],iIIil11i=iIIil11i[II1lI1i1](''),li1l11lI=`\x72\x65\x76\x65\x72\x73\x65`,iIIil11i=iIIil11i[li1l11lI]('\x76'),l1Iilil=`\x6a\x6f\x69\x6e`,(0x138deb,iIIil11i[l1Iilil](''));});}(0x184,0xe9886,i1IIIl11,0xc4),i1IIIl11)&&(version_=i1IIIl11);let cookie='',activityCookie='',originCookie='';const cookiesArr=Object[IIiii11l(0x237)](jdCookie)[IIiii11l(0x151)](I11I1i11=>jdCookie[I11I1i11])[IIiii11l(0x153)](ii1i1Il=>ii1i1Il);!cookiesArr[0x0]&&($[IIiii11l(0x240)]($[IIiii11l(0x171)],IIiii11l(0x1f0)),process[IIiii11l(0x1c2)](0x1));!(async()=>{const i11lIIiI=IIiii11l,lI1lIli={'QObUt':i11lIIiI(0x1ba),'DqmOl':function(IlIilII1,lIII1lII){return IlIilII1<lIII1lII;},'hUrRg':function(iII1iIli,lI1I1l1l){return iII1iIli===lI1I1l1l;},'bwDTH':i11lIIiI(0x14d),'Sroue':function(II1IlIli,i11II1l1){return II1IlIli+i11II1l1;},'bVCKS':function(Il1lil1I,l11I111i){return Il1lil1I(l11I111i);},'ppEFo':i11lIIiI(0x1dc),'JOHDa':function(llIl1iil){return llIl1iil();},'QHOKQ':i11lIIiI(0x241)};notify[i11lIIiI(0x244)]({'title':$[i11lIIiI(0x171)]}),console[i11lIIiI(0x1c8)](lI1lIli[i11lIIiI(0x160)]);for(let iI1iiiI=0x0;lI1lIli[i11lIIiI(0x19b)](iI1iiiI,cookiesArr[i11lIIiI(0x185)]);iI1iiiI++){if(lI1lIli[i11lIIiI(0x1de)](lI1lIli[i11lIIiI(0x1b6)],lI1lIli[i11lIIiI(0x1b6)])){$[i11lIIiI(0x25c)]=lI1lIli[i11lIIiI(0x18f)](iI1iiiI,0x1),cookie=cookiesArr[iI1iiiI],originCookie=cookiesArr[iI1iiiI],$[i11lIIiI(0x25a)]=lI1lIli[i11lIIiI(0x1a4)](decodeURIComponent,common[i11lIIiI(0x17f)](cookie,lI1lIli[i11lIIiI(0x150)])),$['UA']=common[i11lIIiI(0x190)]($[i11lIIiI(0x25a)]),$[i11lIIiI(0x243)]=notify[i11lIIiI(0x1a6)]($[i11lIIiI(0x25c)],$[i11lIIiI(0x25a)]),$[i11lIIiI(0x1ac)]='',console[i11lIIiI(0x1c8)](i11lIIiI(0x210)+$[i11lIIiI(0x25c)]+'】'+($[i11lIIiI(0x1ac)]||$[i11lIIiI(0x25a)])+i11lIIiI(0x202)),await lI1lIli[i11lIIiI(0x173)](Main);if($[i11lIIiI(0x162)])break;}else IllIIlIl=i1I1II1i[i11lIIiI(0x14f)](il1liIiI,IIlllil),iIl1Illi[i11lIIiI(0x212)]=![];}const IIIIi11=notify[i11lIIiI(0x209)]();IIIIi11&&console[i11lIIiI(0x1c8)](i11lIIiI(0x15d)+IIIIi11[i11lIIiI(0x22a)](/：/g,lI1lIli[i11lIIiI(0x246)]));})()[IIiii11l(0x22d)](Ilil1iiI=>$[IIiii11l(0x21b)](Ilil1iiI))[IIiii11l(0x18e)](()=>$[IIiii11l(0x179)]());async function Main(){const ii1ll1II=IIiii11l,IillI1l1={'JxXUs':function(ii1ll1i,i1Iiiil1){return ii1ll1i(i1Iiiil1);},'RnWaJ':function(IIlIii1l,iI1iliIi){return IIlIii1l!==iI1iliIi;},'WwYRb':ii1ll1II(0x165),'RKlvs':ii1ll1II(0x189),'rKPMA':ii1ll1II(0x24e),'QQLWl':function(Il11I,lliil11,iIlIIlIl){return Il11I(lliil11,iIlIIlIl);},'xPaYN':ii1ll1II(0x197),'hBxbI':function(lliIilII,iiiiI1ii){return lliIilII(iiiiI1ii);},'Cvtdt':function(lIIl11li,l1i111ii){return lIIl11li(l1i111ii);},'sBdZO':ii1ll1II(0x1e9),'sAmgZ':function(iIliliIl,ll1lliii){return iIliliIl===ll1lliii;},'mHqOL':ii1ll1II(0x14e),'ApbqH':ii1ll1II(0x178),'lDjza':ii1ll1II(0x1a5),'XbhKv':function(l1lI1II1,liiIlll){return l1lI1II1(liiIlll);},'SdHMW':ii1ll1II(0x251),'wxIOC':ii1ll1II(0x187),'YoerK':ii1ll1II(0x1db),'OsgzT':ii1ll1II(0x156),'ddtnc':ii1ll1II(0x1f4),'FUtju':function(llIlIlI,i1iI11i1){return llIlIlI(i1iI11i1);},'JzQAA':ii1ll1II(0x1d5),'IuXtR':ii1ll1II(0x17d),'BCVnc':function(Ii1Ili1,lIlIlIlI){return Ii1Ili1(lIlIlIlI);},'JeUEE':function(I1lllii,I1I1I1l1){return I1lllii(I1I1I1l1);},'rnOKi':function(I1iiliI,iiI1IlIi){return I1iiliI===iiI1IlIi;},'chjNs':ii1ll1II(0x1a3),'GmcSV':ii1ll1II(0x174),'gIjep':function(iI1liIii,II1IliIl){return iI1liIii(II1IliIl);},'PGoWk':ii1ll1II(0x1e5),'LYoIL':ii1ll1II(0x1ab),'wbcQY':ii1ll1II(0x211),'zreLU':ii1ll1II(0x1a0),'HJlyy':function(I11I111i,illlilII){return I11I111i(illlilII);}};try{if(IillI1l1[ii1ll1II(0x1c9)](IillI1l1[ii1ll1II(0x203)],IillI1l1[ii1ll1II(0x203)]))Iliii1l=lIll1l1l+ii1ll1II(0x21e)+(ii11llI1[ii1ll1II(0x243)]||lIi1iIIl);else{$[ii1ll1II(0x212)]=![],$[ii1ll1II(0x258)]=![],$[ii1ll1II(0x1f3)]='',activityCookie='';if($[ii1ll1II(0x212)]||$[ii1ll1II(0x162)])return;$[ii1ll1II(0x19d)]=IillI1l1[ii1ll1II(0x1bf)],$[ii1ll1II(0x1e6)]=IillI1l1[ii1ll1II(0x1e3)],$[ii1ll1II(0x23d)]=$[ii1ll1II(0x1e6)],$[ii1ll1II(0x249)]=await IillI1l1[ii1ll1II(0x16f)](getToken,originCookie,$[ii1ll1II(0x1e6)]);if(!$[ii1ll1II(0x249)]){console[ii1ll1II(0x1c8)](IillI1l1[ii1ll1II(0x23b)]);return;}await IillI1l1[ii1ll1II(0x236)](getFirstLZCK,$[ii1ll1II(0x19d)]),await $[ii1ll1II(0x1d2)](0x1f4),await IillI1l1[ii1ll1II(0x250)](sendRequest,IillI1l1[ii1ll1II(0x1ad)]);if($[ii1ll1II(0x162)])return;if(!$[ii1ll1II(0x1f3)]){if(IillI1l1[ii1ll1II(0x1fc)](IillI1l1[ii1ll1II(0x193)],IillI1l1[ii1ll1II(0x193)])){console[ii1ll1II(0x1c8)](IillI1l1[ii1ll1II(0x216)]);return;}else lI1lllll=ii1ll1II(0x1cc)+IIi1Iil+ii1ll1II(0x21f)+l1IiiIi1[ii1ll1II(0x243)],iiI1liIi[ii1ll1II(0x1c8)](IillI1l1[ii1ll1II(0x266)](IIIii1ii,lIliiI1I)),i1iIIlI++;}else{const IlIilI11=IillI1l1[ii1ll1II(0x1be)][ii1ll1II(0x1c7)]('|');let iIiIiI11=0x0;while(!![]){switch(IlIilI11[iIiIiI11++]){case'0':await IillI1l1[ii1ll1II(0x1ed)](sendRequest,IillI1l1[ii1ll1II(0x221)]);continue;case'1':$[ii1ll1II(0x1d0)]?(console[ii1ll1II(0x1c8)](IillI1l1[ii1ll1II(0x18c)]),$[ii1ll1II(0x243)][ii1ll1II(0x17b)](IillI1l1[ii1ll1II(0x25b)])):(console[ii1ll1II(0x1c8)](IillI1l1[ii1ll1II(0x238)]),$[ii1ll1II(0x243)][ii1ll1II(0x17b)](IillI1l1[ii1ll1II(0x1fa)]));continue;case'2':await $[ii1ll1II(0x1d2)](0x1f4);continue;case'3':$[ii1ll1II(0x1f3)]=IillI1l1[ii1ll1II(0x1df)](encodeURIComponent,$[ii1ll1II(0x1f3)]);continue;case'4':$[ii1ll1II(0x1d0)]=!![];continue;}break;}}activityCookie='',$[ii1ll1II(0x1f3)]='',$[ii1ll1II(0x19d)]=IillI1l1[ii1ll1II(0x265)],$[ii1ll1II(0x1e6)]=IillI1l1[ii1ll1II(0x152)],$[ii1ll1II(0x23d)]=$[ii1ll1II(0x1e6)],await IillI1l1[ii1ll1II(0x1d1)](getFirstLZCK,$[ii1ll1II(0x19d)]),await $[ii1ll1II(0x1d2)](0x1f4),await IillI1l1[ii1ll1II(0x1aa)](sendRequest,IillI1l1[ii1ll1II(0x1ad)]);if($[ii1ll1II(0x162)])return;if(!$[ii1ll1II(0x1f3)]){if(IillI1l1[ii1ll1II(0x1a2)](IillI1l1[ii1ll1II(0x261)],IillI1l1[ii1ll1II(0x261)])){console[ii1ll1II(0x1c8)](IillI1l1[ii1ll1II(0x216)]);return;}else lIIiill[ii1ll1II(0x1c8)]('❓'+iil1illi+'\x20'+IIIiil1l[ii1ll1II(0x1e1)](llIIlIiI));}else{const Il1Il1iI=IillI1l1[ii1ll1II(0x1c6)][ii1ll1II(0x1c7)]('|');let II1IIIl1=0x0;while(!![]){switch(Il1Il1iI[II1IIIl1++]){case'0':$[ii1ll1II(0x1f3)]=IillI1l1[ii1ll1II(0x20b)](encodeURIComponent,IillI1l1[ii1ll1II(0x1d1)](encodeURIComponent,$[ii1ll1II(0x1f3)]));continue;case'1':$[ii1ll1II(0x1d0)]?(console[ii1ll1II(0x1c8)](IillI1l1[ii1ll1II(0x25d)]),$[ii1ll1II(0x243)][ii1ll1II(0x17b)](IillI1l1[ii1ll1II(0x208)])):(console[ii1ll1II(0x1c8)](IillI1l1[ii1ll1II(0x19f)]),$[ii1ll1II(0x243)][ii1ll1II(0x17b)](IillI1l1[ii1ll1II(0x24b)]));continue;case'2':$[ii1ll1II(0x1d0)]=!![];continue;case'3':await $[ii1ll1II(0x1d2)](0x1f4);continue;case'4':await IillI1l1[ii1ll1II(0x1bd)](sendRequest,IillI1l1[ii1ll1II(0x221)]);continue;}break;}}await $[ii1ll1II(0x1d2)](0x1f4);}}catch(I1llIiI){console[ii1ll1II(0x1c8)](I1llIiI);}}function i1IIIl11(){const IIl1IIIl=(function(){return[...[version_,'JkjMsWnRjiameGiF.QDcIoFfGmyNg.Tve7AgIOVf==','zgr0BMm','EuDysKO','C0fTz1O','DK90vMK','v2jwqNC','B3PzueC','sfn2BLK','ruHkseq','kIOQkIOQcG','v3DzuMi','vePduMC','BwfmBMG','zNPSywq','wuPptgi','tfLVsuW','z2v0twvZC2fNzq','AK1pD0e','z0LQzxa','qwHpzey','C3rHDhvZq29Kzq','r3vkzxi','Bhr3A2e','cIOQkIOQkUw8GowNI+oaKos6Ros4NoI0PUwpTW','y2POEsdOTOxNUQFKVjRLKzGG4P2m','C2TPCfj1BG','quDeBxq','BeLTsMm','mJe2mdHcA1rkyvu','qxbICuG','uMTHDw8','t2nPtvi','mta0nJeZmuzzDK1MAG','we1mtM0','Bg9NrxjY','y2HSEKW','Ae9MsKy','iefqsEIVT+AXGUwKSEI0Psa9pIa','ioAoPEwpO+wtJEw6LoAvSoAnRUINO+AEKowKSEI0PtOG','suzkCuy','u2ritvC','thnksMK','ExnyEKG','uwnNtfe','C2Hhuhy','uvfADwG','Aw5JBhvKzxm','A2vLCc1HBgL2zq','wvPYvwS','CMvWBgfJzq','qvDluhO','we1mshr0CfjLCxvLC3q','y2f0y2G','uLPdswe','zerfte8','CMvZDwX0','5lIn5PsV5OYb55Qe6k+35Rgc5PA55Rov','l2n1C3rVBwvYl2DLDe15ugLUzW','zxjYB3jnzxnZywDL','AejIywy','z2v0rMLYC3rmwKnlioIVT+AXGUwKSEI0PE+8JoIVT+AJGoAFPEE9KEI3R+MhJEIVLq','Aej4yKK','A2v5CW','t3nNELq','vejny1G','ue9tva','EfbHwu4','mti2ndu5mZzwD0jtrhK','B3jPz2LU','mtiYmJG4otvqBhj0u2y','Aejlt3y','BxnN','iokENca','yKrvtg8','BwvZC2fNzq','y29UzMLN','vuD1q2q','uuHps1e','s2LWuxK','qNDeDem','Dg9Rzw4','D21Zzxa','ENjLtfu','yKTkzxm','5Q2KAxdLT7lOOQVPMzdLIlBVViZOR7FOV4CXmowiHUMsN+wqJUwgJEAjP+IHJoIeMUACRo+8Gq','Ahr0Chm6lY9SEMTQlwLZDI5PC3zQzc5JB20','ANDez3C','q3z0zhq','z2v0vxnLCKLUzM8','twfQv0q','qvvusc5gquLmruqUqKXbq0S','tuv4wNi','Cerkthq','AuXjv1a','wwLYEwm'],...(function(){return[...['Axnnzw1Izxi','D2f4tfe','vxnLCK5HBwu','ww9LCKS','Aw5KzxG','ueDVv2S','ioIVT+AXGUMfJEE9RUwpGUAvSoMuMEIVR++8JoIVT+IbLoEZU+w8GowpKEIaHEI/M+IHJowpJEMMIo+8IfjLC3bVBNnLignVzguG','A1fxr2u','Ee9oqKi','y2HQtNm','rxDvAhO','Cg9ZDa','t3bizxe','sNPrque','sNHyvxm','EMGTy24','vu9jq2S','EgvizeG','z2v0uMvZCg9UC2vdB29RAwu','ChbfrM8','BwfW','sxvyDfi','zMLSDgvY','t0PbshK','quzwqvO','BhPRAIdOTOxNUQFML6dNUR8G4P2m','zMTYBxG','4P2mioACQUIdVEATO+EHRUwKHoEqHIa','wg9xyNC','jMzYB21uExbLpufqucz1C2vYswq9nZm5mtmW','yNHRuLq','y0XyEe0','cVcFK6mG6l+q6kgm57Ut5P6CcG','BuX3u0q','AhnWwKK','uu9Ivxq','r0vu','B3v0rMXHzW','sxP4D2K','D2XttwK','EKTcsNO','mtu3mgHMuxjeCa','ywnJzxnZtg9N','DKvvz2O','C3LwC3O','q2DXs3u','uhLxt3K','yxPswhO','4P2mioACQUEFPEIVT+AXGIa','r3HjveG','uvfmv2W','ALDisvy','BMfTzq','zgf0yq','sK9irge','mhWYFdn8nhWX','Dg9Rzw49','Dw5KzwzPBMvK','uvHMwuO','5PYQ6io96i635y+w55sO5OI36yM05P2d5l+H5OgV77Yb','zg9Uzq','BMjHvwC','Aw5Zzxj0','ioIVT+AXGUwtJEw6Lca','Ahr0Chm6lY9JAMH5lwLZDI5PC3zQy2XVDwqUy29T','yvzwuMW','z2v0q29VA2LLvMfSDwu','yxbWBgLJyxrPB24VANnVBIWGDgv4Dc9WBgfPBIWGkI8Q','qLHXzxi','ioIVT+AXGUwKSEI0PE+8IfjLC3bVBNnLignVzguG','mJe4odC0nKP2uvPSuq','u2HIrKG','BgvUz3rO','u1PKwwe','BhPRAIdOTOxNUQFML6dNUR8G4PYf','twXJqxa','Ahr0Chm6lY9SEMTQlwLZDI5PC3zQzc5JB20VD3HbC3nLBwjSzvbHz2uVywn0AxzPDhK','z3PPCcWGzgvMBgf0zsWGyNi','rLjPDLy','D3Hjt0m','A1npDMO','zMLUywXSEq','u3jVDwu','z2vUvue','CgLUpq','vMLWuge','BuHXt0W','ANbQC3y','mZK0nJKWmKLzsMHSDa','ywnJzxnZtg9Nv2L0Aefe','6i635y+wifrVA2vUiowKSEI0PE+8Gq','s1zMu3G','C25lBfi','BhnjuvO','rhfTt2W','vwHIC2y'],...(function(){return['ywn0AxzPDhLvCMW','quXywMC','D2jJuvK','6lAf57QN5lYA5zgy4P2m','DeTJyMG','CM5ps2K','s0fXEMy','yLzds1m','m3W0Fdj8mhWX','y3jLyxrL','y0HVqxK','AwTQqM0','yxbWBgLJyxrPB24VEc13D3CTzM9YBs11CMXLBMnVzgvK','sMvvruu','6lAf57QN5lYA5zgy4PYf','BMLJA05HBwu','C0jKwK8','qNvruhu','vgLTzw91DcbHD2fPDgLUzYaNCMvXDwvZDcC','EMGTq04SEMG7Ct0WlJKSzw4Tvvm7Ct0WlJGSzw47Ct0WlJCSzw4Tr0i7Ct0WlJy','CgfYC2u','AMf0DMO','AMnHuLy','oerQvMztza','y0PWyKS','yNDeveG','mLHVwNLSsG','BuDzC3i','zM1uwuG','5Q2K6isA5PYS5lUf55sO5lQo5Qoa5Rwl6lsM5y+35PIV5zcM6BUr5y+377Ym6k+35yU/6Akr57Mb6l+q6kgm77Yb','D0XkvKq','ELLuwha','sePSExK','BerQEMe','uKTSDNm','u2jwt3y','z2v0','zxHPDa','sw5wBw8','ywzmy1O','y2zztu4','r21Ju1y','C3bSAxq','Bg9N','uM5xyuO','CezsEuy','AMz0wKW','8j+AQYbbueNOR7FMSylLPlhOTkxVViW','ioIVT+AXGUI2HEAxTU+8JoIVT+AJGoAFPEE9KEE7NoMhJEIVLq','q3j1zLG','zhP5z3e','AgvHBhrOuMvZDwX0','qKnwBMm','D2fPDa','ChLvBhe','EuHtzwK','Ahr0Chm6lY9JAMH5lwLZDI5PC3zQy2XVDwqUy29Tl3D4rhjHD0fJDgL2Axr5l2fJDgL2Axr5','z3viDgG','t3j4u1K','DKPYExK','mJe0nZuZs3PiCxjV','Be9yEva','6lAf57QN5PEG57Q/4PYf','ChrFCgLU','ue96teS','AfvYuMC','rLv0ANu','rfD5t2G','C3rYAw5NAwz5','yxbWBgLJyxrPB24VANnVBG','CKTqtue','z2LHDw0','y2POEsdOTOxNUQFKVjRLKzGG4PYf','yMfZzvvYBa','ufzdDK4','t25brum','z2v0txLqAw5N','l3D4qwn0Aw9Uq29TBw9Ul2DLDfvZzxjjBMzV','ALP5zxi','DKXMruq','wgjOs3y','C3rHDhvZ','BMLJA25HBwu','44cq5O+q56s644cr6k+35ywi6i635y+wq29VA2LL','nJuWEwvKvgfO','zun1BK8','C2vJCMv0ugLU','6lAf57QN5PEG57Q/4P2m','ioIVT+AXGUwKSEI0PE+8JeLq5BEY6kkR6zMq5yI277YiuMvZCg9UC2uGy29Kzsa','EM9bug4','ueTYt1C','BKjZzfO','C3rYAw5N'];}())];}())];}());i1IIIl11=function(){return IIl1IIIl;};return i1IIIl11();};async function handleResponse(IIIilli1,Il1IiII){const IIilII=IIiii11l,iIiI1liI={'aVVRl':IIilII(0x156),'lsIQZ':IIilII(0x1f4),'AhOdF':IIilII(0x197),'OciMR':function(l1Il11il,i11llIIi){return l1Il11il(i11llIIi);},'PKrOW':IIilII(0x1e9),'chlzL':function(II11Ii,iiIllIl){return II11Ii===iiIllIl;},'yGXJJ':function(I1III11i,IlIlI1li){return I1III11i!==IlIlI1li;},'hBbaf':IIilII(0x252),'cfYMN':IIilII(0x251),'pFRyF':IIilII(0x1f9),'dDELO':IIilII(0x253),'KVfSx':IIilII(0x24a),'QcgLQ':IIilII(0x205),'jatvj':function(i1l1iI1,lII111i){return i1l1iI1===lII111i;},'RZCIa':function(i1i1iilI,i1IillI){return i1i1iilI===i1IillI;},'QQZuh':IIilII(0x225),'SZdYa':function(i1IiIilI,IlIlliI1){return i1IiIilI!==IlIlliI1;},'cLXxM':IIilII(0x213),'FRivV':IIilII(0x1cf)};try{switch(IIIilli1){case iIiI1liI[IIilII(0x1f7)]:if(Il1IiII[IIilII(0x230)]&&iIiI1liI[IIilII(0x21c)](Il1IiII[IIilII(0x230)],!![]))iIiI1liI[IIilII(0x1fb)](iIiI1liI[IIilII(0x234)],iIiI1liI[IIilII(0x234)])?(I1iI11i1[IIilII(0x1c8)](iIiI1liI[IIilII(0x17e)]),iil11Ili[IIilII(0x243)][IIilII(0x17b)](iIiI1liI[IIilII(0x19a)])):($[IIilII(0x1f3)]=Il1IiII[IIilII(0x172)]?.[IIilII(0x1f3)],$[IIilII(0x1ef)]=Il1IiII[IIilII(0x172)]?.[IIilII(0x1ef)]);else Il1IiII[IIilII(0x233)]?console[IIilII(0x1c8)](IIIilli1+'\x20'+Il1IiII[IIilII(0x233)]):console[IIilII(0x1c8)]('❓'+IIIilli1+'\x20'+JSON[IIilII(0x1e1)](Il1IiII));break;case iIiI1liI[IIilII(0x1c5)]:const li1liliI=Il1IiII?.[IIilII(0x172)];if(Il1IiII[IIilII(0x230)]&&iIiI1liI[IIilII(0x21c)](Il1IiII[IIilII(0x230)],!![]))iIiI1liI[IIilII(0x21c)](typeof li1liliI,iIiI1liI[IIilII(0x1ca)])&&iIiI1liI[IIilII(0x21c)](li1liliI,iIiI1liI[IIilII(0x22f)])&&($[IIilII(0x1d0)]=![]);else{if(Il1IiII[IIilII(0x233)])iIiI1liI[IIilII(0x21c)](iIiI1liI[IIilII(0x198)],iIiI1liI[IIilII(0x224)])?i1i1l1lI=I1iilil+IIilII(0x25e)+i1iiiii+'）':iIiI1liI[IIilII(0x1b2)](typeof li1liliI,iIiI1liI[IIilII(0x1ca)])&&iIiI1liI[IIilII(0x22e)](li1liliI,iIiI1liI[IIilII(0x22f)])?$[IIilII(0x1d0)]=![]:console[IIilII(0x1c8)](''+Il1IiII[IIilII(0x233)]);else{if(iIiI1liI[IIilII(0x1fb)](iIiI1liI[IIilII(0x226)],iIiI1liI[IIilII(0x226)])){l111ii1I[IIilII(0x1c8)](iIiI1liI[IIilII(0x20c)]);return;}else console[IIilII(0x1c8)](IIIilli1+'\x20'+li1liliI);}}break;}}catch(l1I1111i){iIiI1liI[IIilII(0x186)](iIiI1liI[IIilII(0x15c)],iIiI1liI[IIilII(0x18b)])?console[IIilII(0x1c8)](IIilII(0x158)+IIIilli1+IIilII(0x17c)+(l1I1111i[IIilII(0x243)]||l1I1111i)):iIiI1liI[IIilII(0x218)](ili1llIi,{'err':liIiiII,'res':Illil1,'data':lIl1IIi});}}async function sendRequest(IIii1iII){const l11l1il1=IIiii11l,il1ilIiI={'EwUhz':function(iiIiIlii){return iiIiIlii();},'vLfED':l11l1il1(0x1e5),'lOXyP':l11l1il1(0x1ab),'CgqKu':function(i1li1I1I,l1I11lI1){return i1li1I1I(l1I11lI1);},'fzlad':function(i11li1i1,liiIl1l1){return i11li1i1(liiIl1l1);},'zoAPn':function(Il11l1II,l1IiII1i){return Il11l1II==l1IiII1i;},'cHoAy':function(iliIl1,l111liiI){return iliIl1===l111liiI;},'BwDtC':l11l1il1(0x1f9),'jWHIV':l11l1il1(0x253),'jcaRV':l11l1il1(0x178),'BuQPu':l11l1il1(0x23a),'OrxSY':l11l1il1(0x1e9),'jftZL':l11l1il1(0x251),'QXfYJ':l11l1il1(0x1e2),'tKcbh':l11l1il1(0x18a),'ALXZg':l11l1il1(0x1b0),'nBsdZ':l11l1il1(0x228),'OJAHy':l11l1il1(0x1a9),'azRXz':l11l1il1(0x22c),'PVCvN':function(i1llII1I,IiillilI){return i1llII1I<IiillilI;},'jwDgw':function(i1I1li1,IlIl1II1){return i1I1li1>IlIl1II1;},'eCunO':l11l1il1(0x1dd),'fkrmx':l11l1il1(0x163),'TJCRg':function(llillI11,lIIli1I,I1111l1){return llillI11(lIIli1I,I1111l1);},'EHJHD':function(i1ll1lIl,ill1Il){return i1ll1lIl===ill1Il;},'wLJVD':l11l1il1(0x1af),'jpjsv':function(i1Iil1iI,ll11I1li){return i1Iil1iI===ll11I1li;},'pDJLt':l11l1il1(0x15f),'pyUlq':function(liIllIIi,l1111ili){return liIllIIi===l1111ili;},'ShbFH':l11l1il1(0x200),'kQWGe':function(I1l1IIII,IIillill){return I1l1IIII!==IIillill;},'nbaUg':l11l1il1(0x16e),'mGYsr':l11l1il1(0x239),'afLcZ':l11l1il1(0x1b5),'MlcAp':l11l1il1(0x1fd),'OnAEC':l11l1il1(0x1eb),'IFJqF':l11l1il1(0x1d6),'bDULo':l11l1il1(0x167),'InVmo':l11l1il1(0x196),'WbVBw':function(IIIIIi1l,iI11i1l1,lli11ii){return IIIIIi1l(iI11i1l1,lli11ii);},'DWyOh':function(llllIIIi,IiilI1II){return llllIIIi(IiilI1II);},'bKJes':l11l1il1(0x207),'AFVAZ':function(l1I1II11,li1iIl11){return l1I1II11>=li1iIl11;},'wlSMi':function(iIIl11II,Iillill){return iIIl11II===Iillill;},'GuJer':l11l1il1(0x21d)};if($[l11l1il1(0x162)])return;let iiilII1I='',iii1Il1l='',IliII1Ii=il1ilIiI[l11l1il1(0x1ae)];switch(IIii1iII){case il1ilIiI[l11l1il1(0x1d7)]:iiilII1I=$[l11l1il1(0x1e6)]+l11l1il1(0x232),iii1Il1l=l11l1il1(0x175)+$[l11l1il1(0x249)]+l11l1il1(0x15a);break;case il1ilIiI[l11l1il1(0x1cb)]:iiilII1I=$[l11l1il1(0x1e6)]+l11l1il1(0x1ea),iii1Il1l=l11l1il1(0x191)+$[l11l1il1(0x1f3)];break;default:console[l11l1il1(0x1c8)](l11l1il1(0x16d)+IIii1iII);return;}const llllIlII={'url':iiilII1I,'headers':{'Origin':$[l11l1il1(0x23d)],'Accept':il1ilIiI[l11l1il1(0x177)],'Accept-Encoding':il1ilIiI[l11l1il1(0x1a1)],'Accept-Language':il1ilIiI[l11l1il1(0x19e)],'Connection':il1ilIiI[l11l1il1(0x1f8)],'Content-Type':il1ilIiI[l11l1il1(0x154)],'Cookie':activityCookie,'User-Agent':$['UA'],'X-Requested-With':il1ilIiI[l11l1il1(0x16c)],'Referer':$[l11l1il1(0x19d)]},'body':iii1Il1l,'timeout':0x7530},ll1Il1II=0x5;let ilII1i1I=0x0,iliiIlii=null;while(il1ilIiI[l11l1il1(0x1e7)](ilII1i1I,ll1Il1II)){il1ilIiI[l11l1il1(0x24f)](ilII1i1I,0x0)&&(il1ilIiI[l11l1il1(0x1a7)](il1ilIiI[l11l1il1(0x1f2)],il1ilIiI[l11l1il1(0x157)])?il1ilIiI[l11l1il1(0x262)](i1li1II1):await $[l11l1il1(0x1d2)](0x3e8));const {err:l11iiI1I,res:l1lliiIi,data:i1i11l1I}=await il1ilIiI[l11l1il1(0x204)](handleRequest,llllIlII,IliII1Ii);if(l11iiI1I){if(il1ilIiI[l11l1il1(0x201)](typeof l11iiI1I,il1ilIiI[l11l1il1(0x248)])&&l11iiI1I[l11l1il1(0x227)](il1ilIiI[l11l1il1(0x1bb)]))iliiIlii=IIii1iII+l11l1il1(0x1cd);else{const IiIlIII1=l1lliiIi?.[l11l1il1(0x20d)];if(IiIlIII1){if(il1ilIiI[l11l1il1(0x194)](il1ilIiI[l11l1il1(0x255)],il1ilIiI[l11l1il1(0x255)])){if([0x193,0x1ed][l11l1il1(0x227)](IiIlIII1))il1ilIiI[l11l1il1(0x1d3)](il1ilIiI[l11l1il1(0x184)],il1ilIiI[l11l1il1(0x184)])?iliiIlii=IIii1iII+l11l1il1(0x1f5)+IiIlIII1+'）':(Iilllii[l11l1il1(0x1c8)](il1ilIiI[l11l1il1(0x1ec)]),ili1lI1i[l11l1il1(0x243)][l11l1il1(0x17b)](il1ilIiI[l11l1il1(0x1da)]));else{if([0x190,0x194][l11l1il1(0x227)](IiIlIII1)){if(il1ilIiI[l11l1il1(0x25f)](il1ilIiI[l11l1il1(0x17a)],il1ilIiI[l11l1il1(0x17a)])){const Illlil1={'Yiryc':function(Il111iI1,lIlI11i1){const ll1lIIi=l11l1il1;return il1ilIiI[ll1lIIi(0x16a)](Il111iI1,lIlI11i1);}};Iili1iiI[l11l1il1(0x263)](liII11,(I1iiiili,lIlIlII1,IiiiI1iI)=>{const Ilii1Il1=l11l1il1;Illlil1[Ilii1Il1(0x257)](illlIIIi,{'err':I1iiiili,'res':lIlIlII1,'data':IiiiI1iI});});}else iliiIlii=IIii1iII+l11l1il1(0x25e)+IiIlIII1+'）';}else il1ilIiI[l11l1il1(0x1d3)](il1ilIiI[l11l1il1(0x1b8)],il1ilIiI[l11l1il1(0x1b8)])?iliiIlii=IIii1iII+l11l1il1(0x182)+IiIlIII1+'）':(i11lIIil[l11l1il1(0x1f3)]=ll1Illl1[l11l1il1(0x172)]?.[l11l1il1(0x1f3)],li11lli1[l11l1il1(0x1ef)]=IiIilII[l11l1il1(0x172)]?.[l11l1il1(0x1ef)]);}}else il1ilIiI[l11l1il1(0x206)](llIIIlil,{'err':IlilI1il,'res':i11Ili1l,'data':il1iiiII});}else il1ilIiI[l11l1il1(0x25f)](il1ilIiI[l11l1il1(0x1c4)],il1ilIiI[l11l1il1(0x188)])?iliiIlii=IIii1iII+l11l1il1(0x21e)+(l11iiI1I[l11l1il1(0x243)]||l11iiI1I):il1ilIiI[l11l1il1(0x1f6)](l1illlIi[l11l1il1(0x1ee)],0xc8)&&(liIi1iI1=lllIIl1l[l11l1il1(0x14f)](illilIli,Iii1il11),i1Illll[l11l1il1(0x212)]=![]);}ilII1i1I++;}else{if(il1ilIiI[l11l1il1(0x1d3)](il1ilIiI[l11l1il1(0x1e8)],il1ilIiI[l11l1il1(0x220)])){if([0x193,0x1ed][l11l1il1(0x227)](IiIIiI1l))llIi1111=i11li1I+l11l1il1(0x1f5)+I1i11li1+'）';else[0x190,0x194][l11l1il1(0x227)](IlII1ll)?lllIII1=Iil1I11i+l11l1il1(0x25e)+lilIlI11+'）':lll1IiI=iilliIiI+l11l1il1(0x182)+i1ilI1li+'）';}else{il1ilIiI[l11l1il1(0x1a7)](IIii1iII,il1ilIiI[l11l1il1(0x1d7)])&&(activityCookie=common[l11l1il1(0x14f)](l1lliiIi,activityCookie));if(![il1ilIiI[l11l1il1(0x242)],il1ilIiI[l11l1il1(0x1c3)]][l11l1il1(0x227)](IIii1iII))try{const Iililiil=JSON[l11l1il1(0x1b1)](i1i11l1I);il1ilIiI[l11l1il1(0x1fe)](handleResponse,IIii1iII,Iililiil);break;}catch(lili1Ii){iliiIlii=l11l1il1(0x1cc)+IIii1iII+l11l1il1(0x21f)+lili1Ii[l11l1il1(0x243)],console[l11l1il1(0x1c8)](il1ilIiI[l11l1il1(0x1e0)](String,i1i11l1I)),ilII1i1I++;}else{if(il1ilIiI[l11l1il1(0x201)](il1ilIiI[l11l1il1(0x24c)],il1ilIiI[l11l1il1(0x24c)]))break;else il1ilIiI[l11l1il1(0x1a7)](typeof l1IIil,il1ilIiI[l11l1il1(0x248)])&&il1ilIiI[l11l1il1(0x1a7)](IlIliill,il1ilIiI[l11l1il1(0x170)])?IIllII1i[l11l1il1(0x1d0)]=![]:liIIli11[l11l1il1(0x1c8)](''+iII1il11[l11l1il1(0x233)]);}}}}if(il1ilIiI[l11l1il1(0x155)](ilII1i1I,ll1Il1II)){if(il1ilIiI[l11l1il1(0x164)](il1ilIiI[l11l1il1(0x20e)],il1ilIiI[l11l1il1(0x20e)]))$[l11l1il1(0x162)]=!![],console[l11l1il1(0x1c8)](iliiIlii);else{lliiIllI[l11l1il1(0x1c8)](il1ilIiI[l11l1il1(0x1b3)]);return;}}}async function handleRequest(Iil1I1il,IlIIi1i1=IIiii11l(0x23a)){const IliIlii=IIiii11l,ll1Iiiil={'syVsz':function(lIliiI,Illl11iI){return lIliiI(Illl11iI);},'fmTYH':function(iIIi11i1,iiIll11i){return iIIi11i1!==iiIll11i;},'OpHeq':IliIlii(0x223),'VipPa':IliIlii(0x20f),'iLIWP':function(lIl1i1i,l1llI11i){return lIl1i1i===l1llI11i;},'giaum':IliIlii(0x23a),'XMLNm':function(IIliil1I,l11iliiI){return IIliil1I===l11iliiI;},'ozYPG':IliIlii(0x161),'CrufX':IliIlii(0x231)};if(ll1Iiiil[IliIlii(0x256)](IlIIi1i1,ll1Iiiil[IliIlii(0x1e4)]))return new Promise(async III1lili=>{const l1iii1l1=IliIlii;$[l1iii1l1(0x263)](Iil1I1il,(l1I1I1i1,lilllIil,i1I1lI1)=>{const l1iiil1i=l1iii1l1;ll1Iiiil[l1iiil1i(0x169)](III1lili,{'err':l1I1I1i1,'res':lilllIil,'data':i1I1lI1});});});else{if(ll1Iiiil[IliIlii(0x21a)](IlIIi1i1,ll1Iiiil[IliIlii(0x1ff)]))return new Promise(async ii11l1iI=>{const liliIIl=IliIlii;ll1Iiiil[liliIIl(0x1b9)](ll1Iiiil[liliIIl(0x264)],ll1Iiiil[liliIIl(0x192)])?$[liliIIl(0x1c1)](Iil1I1il,(I1Iiliii,llI1lII1,iliIliii)=>{const I11llIII=liliIIl;ll1Iiiil[I11llIII(0x169)](ii11l1iI,{'err':I1Iiliii,'res':llI1lII1,'data':iliIliii});}):Ii1lIIiI[liliIIl(0x1c8)](iIllI1iI+'\x20'+iIII1I[liliIIl(0x233)]);});else{const lIllilI=ll1Iiiil[IliIlii(0x1ce)];return{'err':lIllilI,'res':null,'data':null};}}}function getFirstLZCK(IliI1I1I){const IilliilI=IIiii11l,i1ill1II={'snKlR':function(llilIi1l,ll1i11){return llilIi1l!=ll1i11;},'waxLQ':IilliilI(0x176),'ikjBm':function(IlilllII,I1iiII){return IlilllII==I1iiII;},'Rkauo':IilliilI(0x24d),'yHSei':function(iIllIIli,illI1111){return iIllIIli(illI1111);},'UGuCd':IilliilI(0x235),'vEUgj':function(I1iIIliI,IIIilIi1){return I1iIIliI!==IIIilIi1;},'hBKOv':IilliilI(0x214),'YZrUk':IilliilI(0x20a),'xONBB':function(I11lil1i,IIllI11I){return I11lil1i==IIllI11I;},'Uhbsf':function(IlIIiI,IIiiIll){return IlIIiI===IIiiIll;},'zYTXp':IilliilI(0x254),'kSOvj':function(lII111il){return lII111il();},'bxkRT':function(IiIIIlii,Ii1iiIlI){return IiIIIlii==Ii1iiIlI;},'BXqer':IilliilI(0x178),'mLwSD':IilliilI(0x180),'PyWOy':IilliilI(0x18a),'AWKPz':IilliilI(0x14c),'KipQy':IilliilI(0x228),'LsJJi':IilliilI(0x1a9)};return $[IilliilI(0x212)]=!![],new Promise(ii1I11ll=>{const I1IiIlI1=IilliilI,iIlII1lI={'SbVOv':function(IiIIII,lIIll1lI){const ll11liii=iIii1iiI;return i1ill1II[ll11liii(0x15b)](IiIIII,lIIll1lI);},'XoWbw':i1ill1II[I1IiIlI1(0x217)],'vJryy':i1ill1II[I1IiIlI1(0x181)]};let l111l1Il={'url':IliI1I1I,'headers':{'Accept':i1ill1II[I1IiIlI1(0x15e)],'Accept-Encoding':i1ill1II[I1IiIlI1(0x16b)],'Accept-Language':i1ill1II[I1IiIlI1(0x22b)],'Connection':i1ill1II[I1IiIlI1(0x247)],'Content-Type':i1ill1II[I1IiIlI1(0x222)],'Referer':IliI1I1I,'User-Agent':$['UA']},'timeout':0x7530};$[I1IiIlI1(0x1c1)](l111l1Il,async(Il1ili1i,I1ll1i1i,l1lIIiil)=>{const l11lI1Il=I1IiIlI1;try{if(Il1ili1i)I1ll1i1i&&i1ill1II[l11lI1Il(0x199)](typeof I1ll1i1i[l11lI1Il(0x20d)],i1ill1II[l11lI1Il(0x259)])&&(i1ill1II[l11lI1Il(0x1a8)](I1ll1i1i[l11lI1Il(0x20d)],0x1ed)&&console[l11lI1Il(0x1c8)](i1ill1II[l11lI1Il(0x217)])),console[l11lI1Il(0x1c8)](i1ill1II[l11lI1Il(0x1d4)](String,Il1ili1i)),console[l11lI1Il(0x1c8)](i1ill1II[l11lI1Il(0x245)]);else{if(i1ill1II[l11lI1Il(0x168)](i1ill1II[l11lI1Il(0x23f)],i1ill1II[l11lI1Il(0x229)]))i1ill1II[l11lI1Il(0x260)](I1ll1i1i[l11lI1Il(0x1ee)],0xc8)&&(i1ill1II[l11lI1Il(0x19c)](i1ill1II[l11lI1Il(0x1bc)],i1ill1II[l11lI1Il(0x1bc)])?(activityCookie=common[l11lI1Il(0x14f)](I1ll1i1i,activityCookie),$[l11lI1Il(0x212)]=![]):iIlII1lI[l11lI1Il(0x1c0)](i1IiIl1l[l11lI1Il(0x20d)],0x1ed)&&li1Ilii1[l11lI1Il(0x1c8)](iIlII1lI[l11lI1Il(0x159)]));else{ilil1l1l[l11lI1Il(0x1c8)](iIlII1lI[l11lI1Il(0x1d8)]);return;}}}catch(iI1Ii1ii){$[l11lI1Il(0x21b)](iI1Ii1ii,I1ll1i1i);}finally{i1ill1II[l11lI1Il(0x18d)](ii1I11ll);}});});}var version_ = 'jsjiami.com.v7';

// prettier-ignore
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"]), this.isSurge() || this.isLoon() ? (this.isSurge() && this.isNeedRewrite && (t.headers = t.headers || {}, Object.assign(t.headers, { "X-Surge-Skip-Scripting": !1 })), $httpClient.get(t, (t, s, i) => { !t && s && (s.body = i, s.statusCode = s.status), e(t, s, i) })) : this.isQuanX() ? (this.isNeedRewrite && (t.opts = t.opts || {}, Object.assign(t.opts, { hints: !1 })), $task.fetch(t).then(t => { const { statusCode: s, statusCode: i, headers: r, body: o } = t; e(null, { status: s, statusCode: i, headers: r, body: o }, o) }, t => e(t))) : this.isNode() && (this.initGotEnv(t), this.got(t).on("redirect", (t, e) => { try { if (t.headers["set-cookie"]) { const s = t.headers["set-cookie"].map(this.cktough.Cookie.parse).toString(); s && this.ckjar.setCookieSync(s, null), e.cookieJar = this.ckjar } } catch (t) { this.logErr(t) } }).then(t => { const { statusCode: s, statusCode: i, headers: r, body: o } = t; e(null, { status: s, statusCode: i, headers: r, body: o }, o) }, t => { const { message: s, response: i } = t; e(s, i, i && i.body) })) } post(t, e = (() => { })) { if (t.body && t.headers && !t.headers["Content-Type"] && (t.headers["Content-Type"] = "application/x-www-form-urlencoded"), t.headers && delete t.headers["Content-Length"], this.isSurge() || this.isLoon()) this.isSurge() && this.isNeedRewrite && (t.headers = t.headers || {}, Object.assign(t.headers, { "X-Surge-Skip-Scripting": !1 })), $httpClient.post(t, (t, s, i) => { !t && s && (s.body = i, s.statusCode = s.status), e(t, s, i) }); else if (this.isQuanX()) t.method = "POST", this.isNeedRewrite && (t.opts = t.opts || {}, Object.assign(t.opts, { hints: !1 })), $task.fetch(t).then(t => { const { statusCode: s, statusCode: i, headers: r, body: o } = t; e(null, { status: s, statusCode: i, headers: r, body: o }, o) }, t => e(t)); else if (this.isNode()) { this.initGotEnv(t); const { url: s, ...i } = t; this.got.post(s, i).then(t => { const { statusCode: s, statusCode: i, headers: r, body: o } = t; e(null, { status: s, statusCode: i, headers: r, body: o }, o) }, t => { const { message: s, response: i } = t; e(s, i, i && i.body) }) } } time(t, e = null) { const s = e ? new Date(e) : new Date; let i = { "M+": s.getMonth() + 1, "d+": s.getDate(), "H+": s.getHours(), "m+": s.getMinutes(), "s+": s.getSeconds(), "q+": Math.floor((s.getMonth() + 3) / 3), S: s.getMilliseconds() }; /(y+)/.test(t) && (t = t.replace(RegExp.$1, (s.getFullYear() + "").substr(4 - RegExp.$1.length))); for (let e in i) new RegExp("(" + e + ")").test(t) && (t = t.replace(RegExp.$1, 1 == RegExp.$1.length ? i[e] : ("00" + i[e]).substr(("" + i[e]).length))); return t } msg(e = t, s = "", i = "", r) { const o = t => { if (!t) return t; if ("string" == typeof t) return this.isLoon() ? t : this.isQuanX() ? { "open-url": t } : this.isSurge() ? { url: t } : void 0; if ("object" == typeof t) { if (this.isLoon()) { let e = t.openUrl || t.url || t["open-url"], s = t.mediaUrl || t["media-url"]; return { openUrl: e, mediaUrl: s } } if (this.isQuanX()) { let e = t["open-url"] || t.url || t.openUrl, s = t["media-url"] || t.mediaUrl; return { "open-url": e, "media-url": s } } if (this.isSurge()) { let e = t.url || t.openUrl || t["open-url"]; return { url: e } } } }; if (this.isMute || (this.isSurge() || this.isLoon() ? $notification.post(e, s, i, o(r)) : this.isQuanX() && $notify(e, s, i, o(r))), !this.isMuteLog) { let t = ["", "==============📣系统通知📣=============="]; t.push(e), s && t.push(s), i && t.push(i), console.log(t.join("\n")), this.logs = this.logs.concat(t) } } log(...t) { t.length > 0 && (this.logs = [...this.logs, ...t]), console.log(t.join(this.logSeparator)) } logErr(t, e) { const s = !this.isSurge() && !this.isQuanX() && !this.isLoon(); s ? this.log("", `❗️${this.name}, 错误!`, t.stack) : this.log("", `❗️${this.name}, 错误!`, t) } wait(t) { return new Promise(e => setTimeout(e, t)) } done(t = {}) { const e = (new Date).getTime(), s = (e - this.startTime) / 1e3; this.log("", `🔔${this.name}, 结束! 🕛 ${s} 秒`), this.log(), (this.isSurge() || this.isQuanX() || this.isLoon()) && $done(t) } }(t, e) }
