faker3/jd_superbrandhall.js
2024-07-11 11:28:42 +08:00

16 lines
26 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

/*
活动名称:超级品牌殿堂
环境变量jd_superbrandhall_interval // 自定义运行间隔时长整数单位毫秒默认1000
jd_superbrandhall_notify // 是否推送通知true/false默认不推送
jd_superbrandhall_pinFilter // 账号pin过滤多个用@进行分割
cron:18 8,18 * * *
*/
const $ = new Env('超级品牌殿堂')
const _0x5b37a3=_0x9bcc;(function(_0x26fc0f,_0xbb1009){const _0x2576e8=_0x9bcc,_0x3a04d0=_0x26fc0f();while(!![]){try{const _0x5336f3=parseInt(_0x2576e8(0xbb,'nxP('))/0x1+-parseInt(_0x2576e8(0xda,'nxP('))/0x2*(parseInt(_0x2576e8(0xe9,'^oca'))/0x3)+parseInt(_0x2576e8(0xed,'30Ja'))/0x4+-parseInt(_0x2576e8(0x72,'2kd!'))/0x5*(-parseInt(_0x2576e8(0xea,'ad8X'))/0x6)+parseInt(_0x2576e8(0x8a,'%1zR'))/0x7+-parseInt(_0x2576e8(0x9a,'Ysfq'))/0x8+parseInt(_0x2576e8(0x89,'ca3z'))/0x9;if(_0x5336f3===_0xbb1009)break;else _0x3a04d0['push'](_0x3a04d0['shift']());}catch(_0x570bf3){_0x3a04d0['push'](_0x3a04d0['shift']());}}}(_0x728e,0xb03f7));function _0x728e(){const _0x521133=['4PY7moADS+EELUISI+AYR8oR','ndJcS8kEW6zI','WR55Fbn8nJX8','W6ZdKSkN','qSkwjGSFnZi','W4ldOZ3cVLBcIchcPYxcJI0BW7u','q01c','W7BcVCkoW4dcJhnibmolhG','W5yXWRnYW5bmwa','WPpdR8kA','hh4VWPm','WOhdULddJ8ocEmopWOa','WPRdTf4','WQH5W6aDc8kV','E8kJWOqnWP4','W4iMeMRdTIhdOCoTzJL6','EbVdJMRcVsRdGNBcO3XSmSkqga','W4vVWPOoWPDnWRfODcldGmogWPCD','WPVdSLC','W45LWOK','W5W3W73dVeOdxq1IW5C','W7BdIaPTWPXw','j8oCW4j2m8oyWRJcVa','W71yWOBdKHDVW4pcJq','WOJcRMeLWOBdIum','WP8Mz1mHrYTlkXXV','WQOoWRxdMCk2fa','px51ghZdLW','t8kCj2tdI8kuWQTH','jEs7PowlUUwNG+I0MSod','WRTYCrH9oG','6Asw6Aoi5AEX6lwmhq','WOvsnZhdRSoGAK/cOmkD','WOzwnX0','DSoUW43cIa','q8kCiWa','56wnW7VOVQNOOytPLjRPMRBML5JPLRi','mJRcM8o5fuKcWPhcKmoAtG','WO5yja','naT4bGZcPaFcUq','xmo+AmkatIhdGCk2b8kBf1S9hW','WQ7cKSkQdqvNx8kCaCkS','W6lcNCoJWRafWRa','WOVdU8kfya','W6lcL8oQWPidWQO','fq5fW7NdH8oHpG','bLhcPW','WPJcOMGtWOxdMq','W49VWP0XWPLnWR0','W4rVbNJdOSkpWQndu2PsW5VcOcC','WPxcRmkzbSkuW4y','os7cRSkqW7vK','f8kdECkjWRBdKgpcLmolW57dTCoPW6nvnCouW6rdz8kwW7ZcJbq8','5Bww6k+Q576T6lET6l226l+/6kgX5B+i5yI+6lsD5y6U','W7FdNmkPhq','mcjR','WR7cPb0DW4xcNq','W6NcNCo5WPidWQOVWQddMr1w','oWTX','5lIb55cX5B2d5yspWRhcS0i','fMqyeSk7hSk/D8oth8kJWRDpwCkIWR7dUSoUW5CfjajVomkkWRVdKd1ykb7dR8oOWRm3s8oFWPVcH8kSyCo1WQ5xgSoyWPeuWROZWOtcU8o3W6ZcKgJdHmk8WORcPNxcMmoMW5dcVvHdWQW/WQyWrSkciG','wmoJBq','WPVcVgm','W5mZW7RdOv0zqbHeW5eotmknFfO','kCo/W41lW4NdLmk+zubjWQC3h8k7rHxdJg1HW5/cJq','CXhdNq','W4KMceJdSdS','WQRINQxdJW','uCoODCkoxsC','W6mXWQ8','n8k2e8kyWPCCW43cImkvu8kzWRC','W4/dLbzSWPTbwSkxDmkgW5T1WR3dJG','WPzHWRzQW5LxAmom','vmkskq','fMqyeSk7hSk/D8ochCkLW71haCoMWRFdUSoNW5XgAa','4PYCWP3MNOhOG7/MRitNO5/LP5hNK58m','5lUl5PEP5Pwk5REY5yQm','W5aMWRz7','jbbKddBcOH3cTfm','vSkyk3tdJCkyWQTRW73dJw3dU8kMemoMuSkNW61Oy8on','W4qZfKpdRtddR8oRqIvZW5FdIZT5dqdcNYClnmkPp2BdNc/cQmoLFSohWQhdPSot','gWHy','gNeyaW','WR0zWRFdK8kL','WQ/ORQNMSORLPjFOTP9T4P+4bq','W7VdHW1P','W6ryWOldGW','FrFdGgRcVshdJa','fVc0GAxcOUI8L+IHREE6J+AFPbC','m8osW49N','WRJKUkpLIAFLPyFOT5JdSW','W4xORk/MSOtLPyFOT5JcIokDJSoN5PE95zgo5BIx5PsS5OYM','wtXGySo5W4XJW7C','W5zzWOX4pCk6E2qfWOZcTGRcGdtdRSobm8oOWP/cUKC','cxHz','fmofDfbMCM3cNgldVSoLzmoi','W4hcOGVcGSkIjSkwWO1xuLpcR1W','6lwa5y+I5Pwr5PwQ','WO9KWRRcHbHahazHW5GsB8kv','CSomW6VdPW','WOFcPMm','r01auKCNaq','WPlcUCkVaG','WOXyna','WPldU8kbCCouW57cPCkq','WPxdTf3dNG','W4fLWOmYWPrpWQXVsdJdP8oEWOmj','cLhcS8kOWQjzW6SpnJv0WOJdNmkf','6AE96Agx5AEX6lEKWP4','WQdcRGK','W4DKWO0WWOfAWQXhvcxdImovWOWdy3BcGmk8ha','ws7dJh8','yLqVxgNdS0tcTh/dSCo5W5fb','ex3cHa','fNunbSkTvSoJ','FSoiW6FdRmkjvde','cgOOWPO','W7ldHWK','sZnQzmouW5v6W4lcQSkyESoVysxcPSon','BCkaWPy/wSkmW6JdPbeJ','duVcUa','Amk3WOmg','WOpcSNFdRcVdL2lcTq','WPxdPmkIW4vzExFdH2P4AuDniCo7WPZcJCkscSk1nmoFWOjUW6unWOu','p3zTdq','nLRdONy','b03cPW','cNRdLG','WRj7W7OBha','k8o1W48','5lM15yMz5yQA6kk/5Awa6lE9gW','6AA26Akg5Aw26lwacG','WRSeWQhdMq','44oN5OYd56s+44kw6k6q5yE26i6M5yYxm8kIdHhdMM4','WONdTCkp','nmoCW59J','DSojW5NdSCkYutKkFZVcNCkYeCohW7m6umkPWQBdJbFcMM7cRSoIBW','jJ/cSSkEW69RW4VdG8oL','WRZdR8ktW4jjz2BcMfXZEeW','W4y9WRLDW55lwa','WPJcSNuJWOFdIq','gvFcRSkeWQTt','n3H+','e3eTeG','8kkQU3K','W4ZcTSomWOyDF2VdNL5Tsq','WOVdQ8oleSo8vSkRW6G','5y+a6ysn54Mg5OgV57IL5P6qWQdcGSoXotZcNqa3W6tcPa','W4a1WRD/','W4KNW6FdTeeu','ostcPW','WP0Tzq','u8kgnWaJac3cL2JdSmozB8onWQXVeGRdRa','zCo1r8oFW4jKW63cVmk0','WRLYEHTBnZrGW69RF8oHxfS/W4DSecZcNmkd','WOVdQ8oleG','W5LFWP11gCk2yNi9WOJcMaa','WPRdVLFdNmoIEq','4PQ4W6lOHjRLR7tKUR/OVj/OO5hPLyVPMzJML7lPLB7ORj7NVzpPLjpORly','W7K4AGTGpIOGW4TRxSoRx0mjW5faecZcS8k/WQBdJSoZWOngcW','WPvwkGG','xmkCoNe','xJ3dNx/dM8oc','tY56F8okW4TJW7FcTSkdxSoRBZq','eCkiqq','ttRdI3y','WRJdRmoAWP7dLa','oqTH','lCo1W4fb','W4f9axa','zMNdNSkmvK0uWOJcI8ooAa','hqnGW4NdNCo1pSksymogDSkiWOtdUSoBW6xdJvXwW6RdHM/cJSov','WPj6vbBcSgtcUSo3zJH+WQ3dSa','FCkSWOy','5y6d5ykN5lQ15yQX776fWQy','rJXLESoYWPq/WQpdQq','W4RcS8opWOaDo1ZdVK1GxfK','W5bVWP83WP1zWQW','pcxcO8kBW7rOW4FdLG','xSoIF8km','zMNdNSkasLmsWPtcO8o+ybtcKmkzt8kI','6ls55y6j6l295RUnW6HLW7i','W4y7WQXYW5rouW','rfnBy0WnbvnU','nYlcUSk0W65OW4C','DrRdPvRcPZxdJg3cPfHSmmkbfCoazCojFXqVWRy0vSkIWORcOW','44cq6lwm5y2B','W707WRTtW5y5','cCopneJdR8kfWPnb','zrldHsq','xEISKoAXPowqT+w5L8ka','W43cUmoypSoyr8ktW4G','WR0bW5RcLNe+W4tcSf5lotC','5Rwl6kwkfowEL+EWMow9G+wEPoE5RUA3QUwkSG','WP7dS8koW59lzW','WPz3uXRcTwxdJ8ogBWnqWQi','6yku55YD5OYL6yows8o4gW','b2xdGu7cOahcV8kss050exBdQvmybmkSm8kpfsPnxCkjW6LNWQ9/g2yYoq','W47cSmonWOy','B8oyW7BdP8k1yY4zCY3cUmkZiCooW6e9','WRqeWQi','WOtcPNtdOHxdVgpcOb7cQtiFW5bKW7COW4inWO5vl8oAWPZcPvO/W6pdPtK','WQSEWRxdMCkLiSo5WPRcQSkmW6ldNHZcR8k1DG','W507W6FdKemCvW','fha8','WOtdUCkCBmo2W57cVmkmWPddUq','WPpcVgRdOG'];_0x728e=function(){return _0x521133;};return _0x728e();}const jdCookie=require(_0x5b37a3(0x122,'@$oa')),notify=require(_0x5b37a3(0xc9,'^f)p')),common=require('./utils/Rebels_jdCommon');let taskThreads=process[_0x5b37a3(0x136,'(aGC')][_0x5b37a3(0xe3,'5qv*')]||'1';const runInterval=process['env'][_0x5b37a3(0xb2,'i2xT')]||_0x5b37a3(0xf0,'nxP('),isNotify=(process[_0x5b37a3(0xd7,'MF94')][_0x5b37a3(0xd5,'8f1j')]||process[_0x5b37a3(0xc1,'yZ#H')][_0x5b37a3(0x12d,'wzQM')])===_0x5b37a3(0x77,'2kd!'),pinFilter=(process['env'][_0x5b37a3(0xa5,'nxP(')]||'')['split']('@'),maxThreads=0x1;let cookiesArr=Object['keys'](jdCookie)[_0x5b37a3(0x9f,'^aUl')](_0x2fbc19=>jdCookie[_0x2fbc19])[_0x5b37a3(0x114,'I#x1')](_0x4c78a8=>_0x4c78a8);function _0x9bcc(_0x404544,_0x3acc46){const _0x728e6a=_0x728e();return _0x9bcc=function(_0x9bcc4c,_0x32d635){_0x9bcc4c=_0x9bcc4c-0x69;let _0x516bfc=_0x728e6a[_0x9bcc4c];if(_0x9bcc['CrJECI']===undefined){var _0xff3d02=function(_0x4c78a8){const _0x5bda1f='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x19e25a='',_0x2582b0='';for(let _0x295dbf=0x0,_0x4f825d,_0x4876c3,_0x4d38af=0x0;_0x4876c3=_0x4c78a8['charAt'](_0x4d38af++);~_0x4876c3&&(_0x4f825d=_0x295dbf%0x4?_0x4f825d*0x40+_0x4876c3:_0x4876c3,_0x295dbf++%0x4)?_0x19e25a+=String['fromCharCode'](0xff&_0x4f825d>>(-0x2*_0x295dbf&0x6)):0x0){_0x4876c3=_0x5bda1f['indexOf'](_0x4876c3);}for(let _0x16a9ad=0x0,_0x158a66=_0x19e25a['length'];_0x16a9ad<_0x158a66;_0x16a9ad++){_0x2582b0+='%'+('00'+_0x19e25a['charCodeAt'](_0x16a9ad)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x2582b0);};const _0x2fbc19=function(_0x5519cf,_0x1f7b75){let _0x9243e8=[],_0x40d7a9=0x0,_0x4a1ea9,_0x66c32='';_0x5519cf=_0xff3d02(_0x5519cf);let _0x34a9b2;for(_0x34a9b2=0x0;_0x34a9b2<0x100;_0x34a9b2++){_0x9243e8[_0x34a9b2]=_0x34a9b2;}for(_0x34a9b2=0x0;_0x34a9b2<0x100;_0x34a9b2++){_0x40d7a9=(_0x40d7a9+_0x9243e8[_0x34a9b2]+_0x1f7b75['charCodeAt'](_0x34a9b2%_0x1f7b75['length']))%0x100,_0x4a1ea9=_0x9243e8[_0x34a9b2],_0x9243e8[_0x34a9b2]=_0x9243e8[_0x40d7a9],_0x9243e8[_0x40d7a9]=_0x4a1ea9;}_0x34a9b2=0x0,_0x40d7a9=0x0;for(let _0x568597=0x0;_0x568597<_0x5519cf['length'];_0x568597++){_0x34a9b2=(_0x34a9b2+0x1)%0x100,_0x40d7a9=(_0x40d7a9+_0x9243e8[_0x34a9b2])%0x100,_0x4a1ea9=_0x9243e8[_0x34a9b2],_0x9243e8[_0x34a9b2]=_0x9243e8[_0x40d7a9],_0x9243e8[_0x40d7a9]=_0x4a1ea9,_0x66c32+=String['fromCharCode'](_0x5519cf['charCodeAt'](_0x568597)^_0x9243e8[(_0x9243e8[_0x34a9b2]+_0x9243e8[_0x40d7a9])%0x100]);}return _0x66c32;};_0x9bcc['TdgYfC']=_0x2fbc19,_0x404544=arguments,_0x9bcc['CrJECI']=!![];}const _0x1b3ba9=_0x728e6a[0x0],_0xf7b2d9=_0x9bcc4c+_0x1b3ba9,_0x4c185e=_0x404544[_0xf7b2d9];return!_0x4c185e?(_0x9bcc['AzNopu']===undefined&&(_0x9bcc['AzNopu']=!![]),_0x516bfc=_0x9bcc['TdgYfC'](_0x516bfc,_0x32d635),_0x404544[_0xf7b2d9]=_0x516bfc):_0x516bfc=_0x4c185e,_0x516bfc;},_0x9bcc(_0x404544,_0x3acc46);}!cookiesArr[0x0]&&($[_0x5b37a3(0x127,'W0ug')]($['name'],_0x5b37a3(0xaf,'0ZZn')),process[_0x5b37a3(0xe7,'q!]M')](0x1));!(async()=>{const _0x1e6330=_0x5b37a3;notify['config']({'title':$[_0x1e6330(0x80,'ad8X')]}),await Main(),isNotify&&notify[_0x1e6330(0x119,'Q*^X')]()&&await notify[_0x1e6330(0x9e,')^vx')]();})()[_0x5b37a3(0x107,'MF94')](_0x5bda1f=>$[_0x5b37a3(0x125,'t*eE')](_0x5bda1f))[_0x5b37a3(0xf5,'c&G3')](()=>$[_0x5b37a3(0xf8,'0ZZn')]());async function Main(){const _0x252f65=_0x5b37a3;try{try{const _0x2582b0=parseInt(taskThreads);_0x2582b0>0x0&&_0x2582b0!==0x1&&(taskThreads=_0x2582b0);}catch{taskThreads=0x1;}taskThreads=Math[_0x252f65(0x10b,'%1zR')](taskThreads,maxThreads),$[_0x252f65(0x110,'ad8X')]=null;if(runInterval)try{const _0x295dbf=parseInt(runInterval);_0x295dbf>=0x0&&($[_0x252f65(0x115,'SIkt')]=_0x295dbf);}catch{console[_0x252f65(0xa8,'W0ug')](_0x252f65(0xc8,'MF94'));}console[_0x252f65(0xce,'wzQM')](_0x252f65(0x100,'Ysa7')+$[_0x252f65(0x124,')70(')]+'变量开启状态=========='),console['log'](_0x252f65(0x134,'Q*^X')+common['getProxyStatus']()+']'),console['log']('间隔时长:\x20['+$[_0x252f65(0x92,')70(')]/0x3e8+_0x252f65(0x11d,'^aUl')),console[_0x252f65(0x102,'nxP(')](_0x252f65(0xee,'t*eE')+(isNotify?'开启':'关闭')+']'),console[_0x252f65(0xfc,'@$oa')](_0x252f65(0xdf,'5qv*')+pinFilter[_0x252f65(0xd2,'a&54')](',\x20')+']'),console[_0x252f65(0xf6,')^vx')](_0x252f65(0xa1,'v%iC')+$[_0x252f65(0x8d,'i2xT')]+_0x252f65(0xbd,'MF94')),console[_0x252f65(0xb0,')70(')](''),$['needRemoveCookieIndex']=[],await common[_0x252f65(0x120,'Ysfq')](taskThreads,cookiesArr,taskFnc),$[_0x252f65(0x69,'c&G3')]=![],$[_0x252f65(0xbf,'c&G3')]=![];$[_0x252f65(0x79,'SIkt')][_0x252f65(0xc7,'%1zR')]>0x0&&(cookiesArr=cookiesArr['filter']((_0x4f825d,_0x4876c3)=>!$['needRemoveCookieIndex'][_0x252f65(0xdc,'ziLf')](_0x4876c3+0x1)),$[_0x252f65(0x87,'@K%(')]=[]);const _0x19e25a=notify[_0x252f65(0x10d,'c&G3')]();_0x19e25a&&console[_0x252f65(0x11f,'Q*^X')](_0x252f65(0x82,'i2xT')+_0x19e25a[_0x252f65(0x101,'2kd!')](//g,_0x252f65(0x6d,'ad8X')));}catch(_0x4d38af){console[_0x252f65(0xb8,'I#x1')]('❌\x20脚本运行遇到了错误\x0a'+_0x4d38af);}}async function taskFnc(_0x16a9ad,_0x158a66){const _0x161c9a=_0x5b37a3;if($[_0x161c9a(0xb6,'nal4')])return{'runEnd':!![]};const _0x5519cf=decodeURIComponent(common[_0x161c9a(0x109,'5qv*')](_0x16a9ad,_0x161c9a(0x12b,'8%ib')));function _0x1f7b75(_0x25ad85,_0x525ad1){const _0x3fb9e3=_0x161c9a;if(_0x25ad85[_0x3fb9e3(0x6e,'(aGC')]<=0x4)return _0x25ad85;else{const _0x57afec=_0x25ad85[_0x3fb9e3(0xaa,'5rU9')](0x0,0x2),_0x4f7dca=_0x25ad85[_0x3fb9e3(0xd0,'Ysa7')](-0x2),_0x4109a4=Math[_0x3fb9e3(0x8e,'nal4')](_0x525ad1-_0x57afec[_0x3fb9e3(0x117,'^f)p')]-_0x4f7dca[_0x3fb9e3(0x123,'t*eE')],0x0),_0x4802d0='*'[_0x3fb9e3(0x113,'H5!5')](_0x4109a4);return _0x57afec+_0x4802d0+_0x4f7dca;}}const _0x9243e8=decodeURIComponent(_0x5519cf),_0x40d7a9=_0x1f7b75(_0x9243e8,0x6),_0x4a1ea9=_0x161c9a(0xe4,'q!]M')+_0x158a66+'】'+_0x40d7a9+'',_0x66c32=notify[_0x161c9a(0xcc,'E1MX')](_0x158a66,_0x5519cf);if(pinFilter[_0x161c9a(0x6c,'30Ja')]>0x0&&(pinFilter[_0x161c9a(0xfb,'^f)p')](_0x5519cf)||pinFilter['includes'](encodeURIComponent(_0x5519cf)))){_0x66c32[_0x161c9a(0xff,'cp6X')](_0x161c9a(0x12e,'2kd!')),console[_0x161c9a(0xa9,'dr*l')](_0x66c32[_0x161c9a(0xde,'l%rQ')]()),$[_0x161c9a(0x6a,'a&54')][_0x161c9a(0xa3,'MF94')](_0x158a66);return;}const _0x34a9b2=await common[_0x161c9a(0x10a,'*3A*')](_0x16a9ad);if(!_0x34a9b2&&typeof _0x34a9b2===_0x161c9a(0xe0,'2kd!')){console['log'](_0x4a1ea9+'账号无效'),_0x66c32[_0x161c9a(0xa2,'W0ug')](_0x161c9a(0x8b,'dr*l')),$[_0x161c9a(0xc4,'^f)p')][_0x161c9a(0xcf,'E1MX')](_0x158a66);return;}const _0x568597=common['genUA'](_0x5519cf);let _0xe50b67=![],_0x50adab,_0x4c5aea,_0x229982,_0x32e9c9,_0x4d60ba;_0x4c5aea='',await _0xbf55e9('superBrandSecondFloorMainPage'),await $['wait'](parseInt($[_0x161c9a(0x104,'%1zR')]*0x1+0x1f4,0xa));if($[_0x161c9a(0xb7,'W0ug')]||_0xe50b67)return;if(_0x4c5aea){const _0x1fa3e3=_0x4c5aea['activityBaseInfo'],_0x32eb02=_0x1fa3e3?.[_0x161c9a(0xc6,'@K%(')]||'';_0x32e9c9=_0x1fa3e3?.[_0x161c9a(0xf7,')70(')],_0x229982=_0x1fa3e3?.[_0x161c9a(0xa0,'ilmy')];if(_0x32eb02){_0x50adab='',await _0xbf55e9(_0x161c9a(0xc2,'ca3z')),await $[_0x161c9a(0x12f,'@$oa')](parseInt($[_0x161c9a(0x10f,'v%iC')]*0x1+0x1f4,0xa));if(_0x50adab)for(const _0x27e408 of _0x50adab?.[_0x161c9a(0xa4,'0ZZn')]||[]){_0x4d60ba=_0x27e408;if(_0x4d60ba[_0x161c9a(0x94,'*3A*')]){console[_0x161c9a(0x6f,'l)Q@')](_0x4a1ea9+'['+_0x4d60ba[_0x161c9a(0x12a,'*kE(')]+']任务已完成');continue;}console['log'](_0x4a1ea9+_0x161c9a(0xd8,'SIkt')+_0x4d60ba[_0x161c9a(0xcd,'ilmy')]+']'),await $[_0x161c9a(0xc5,'^oca')](parseInt($[_0x161c9a(0x86,'ilmy')]*0x1+0x1f4,0xa));let _0x1dec8b;_0x4d60ba['assignmentName']==_0x161c9a(0xeb,'ZBJq')?_0x1dec8b=0x2:_0x1dec8b=0x1;for(let _0x34ea2d=0x0;_0x34ea2d<_0x1dec8b;_0x34ea2d++){await _0xbf55e9(_0x161c9a(0xf4,'H5!5')),await $['wait'](parseInt($['waitTime']*0x1+0x3e8,0xa));}}}else console[_0x161c9a(0x105,'%1zR')](_0x4a1ea9+_0x161c9a(0x76,'l%rQ'));}if($['runEnd'])return{'runEnd':!![]};await $[_0x161c9a(0xca,'Q*^X')](parseInt($[_0x161c9a(0xbc,'^oca')]*0x1+0x1f4,0xa));async function _0x13c3bc(_0xff2948,_0x47d901){const _0x4c0e33=_0x161c9a;try{switch(_0xff2948){case _0x4c0e33(0xf3,'0ZZn'):_0x47d901[_0x4c0e33(0x11c,'ca3z')]==='0'&&_0x47d901['data']?_0x47d901[_0x4c0e33(0xbe,'2kd!')][_0x4c0e33(0x126,'8f1j')]==='0'?_0x4c5aea=_0x47d901[_0x4c0e33(0xd3,'*kE(')]?.[_0x4c0e33(0xe5,'l)Q@')]:(msg=common[_0x4c0e33(0x108,'30Ja')](_0x47d901[_0x4c0e33(0xa6,'I#x1')]),_0x47d901['data'][_0x4c0e33(0xe2,'ziLf')]==='2001'?console[_0x4c0e33(0x6b,'5qv*')](_0x4a1ea9+_0x4c0e33(0xad,'ca3z')+_0x47d901[_0x4c0e33(0x7f,'^aUl')][_0x4c0e33(0x8f,'cp6X')]+']:风控'):console[_0x4c0e33(0x10c,'*3A*')](_0x4a1ea9+_0x4c0e33(0x118,'@$oa')+_0x47d901[_0x4c0e33(0x7c,'qnB$')]['bizCode']+']'+msg)):(msg=common[_0x4c0e33(0xd4,'l%rQ')](_0x47d901),console[_0x4c0e33(0xf2,'H5!5')](_0x4a1ea9+_0x4c0e33(0x96,'W0ug')+_0x47d901[_0x4c0e33(0xdd,'(aGC')]+']'+msg));break;case'superBrandTaskList':_0x47d901[_0x4c0e33(0x83,'v%iC')]==='0'&&_0x47d901[_0x4c0e33(0xb9,')GIx')]?_0x47d901[_0x4c0e33(0x11a,'Q*^X')][_0x4c0e33(0x111,'nal4')]==='0'?_0x50adab=_0x47d901[_0x4c0e33(0xcb,'SIkt')]?.[_0x4c0e33(0x128,'nal4')]:(msg=common[_0x4c0e33(0x132,'t*eE')](_0x47d901[_0x4c0e33(0x103,')^vx')]),console[_0x4c0e33(0x97,'GMiS')](_0x4a1ea9+'任务列表失败['+_0x47d901['data']['bizCode']+']'+msg)):(msg=common[_0x4c0e33(0x112,'yZ#H')](_0x47d901),console[_0x4c0e33(0xa8,'W0ug')](_0x4a1ea9+_0x4c0e33(0xac,'t*eE')+_0x47d901['code']+']'+msg));break;case _0x4c0e33(0xf1,'i2xT'):if(_0x47d901[_0x4c0e33(0xae,'H5!5')]==='0'&&_0x47d901[_0x4c0e33(0x103,')^vx')]){if(_0x47d901[_0x4c0e33(0x7c,'qnB$')][_0x4c0e33(0x81,'5qv*')]==='0'){let _0x5dbf04=_0x47d901['data']?.[_0x4c0e33(0x131,'GMiS')]['rewards']||[];if(_0x5dbf04&&_0x5dbf04[_0x4c0e33(0x12c,'ziLf')]>0x0)for(const _0x5a3af6 of _0x5dbf04){const _0x4977fd=_0x5a3af6['awardType'];switch(_0x4977fd){case 0x3:console['log'](''+_0x4a1ea9+_0x5a3af6[_0x4c0e33(0xc3,'ZBJq')]+'['+_0x5a3af6[_0x4c0e33(0x9d,'i2xT')]+'豆子🐶]'),_0x66c32[_0x4c0e33(0x106,'5rU9')](_0x5a3af6['awardName']+'['+_0x5a3af6[_0x4c0e33(0xfd,'ca3z')]+'豆子🐶]');break;default:console[_0x4c0e33(0xab,'a&54')](''+_0x4a1ea9+_0x5a3af6[_0x4c0e33(0xe1,'cp6X')]),_0x66c32[_0x4c0e33(0x10e,'^aUl')](''+_0x5a3af6[_0x4c0e33(0xe1,'cp6X')]);break;}}else console[_0x4c0e33(0xb0,')70(')](_0x4a1ea9+'['+_0x4d60ba['assignmentName']+']任务完成但未获得奖品');}else msg=common['getErrorMsg'](_0x47d901[_0x4c0e33(0xa6,'I#x1')]),console[_0x4c0e33(0x7b,'8f1j')](_0x4a1ea9+'['+_0x4d60ba[_0x4c0e33(0x95,'W0ug')]+_0x4c0e33(0x84,'8%ib')+_0x47d901[_0x4c0e33(0x99,'E1MX')][_0x4c0e33(0xb5,'2kd!')]+']'+msg);}else msg=common[_0x4c0e33(0xd4,'l%rQ')](_0x47d901),console[_0x4c0e33(0xc0,'ziLf')](_0x4a1ea9+'['+_0x4d60ba[_0x4c0e33(0x121,'(aGC')]+_0x4c0e33(0x116,')^vx')+_0x47d901[_0x4c0e33(0x93,'%1zR')]+']'+msg);break;}}catch(_0x2406be){console[_0x4c0e33(0x133,'Ysfq')](_0x4c0e33(0x75,'v%iC')+_0xff2948+_0x4c0e33(0xe8,'wzQM')+(_0x2406be[_0x4c0e33(0x129,'*3A*')]||_0x2406be));}}async function _0xbf55e9(_0x254615){const _0x7897e0=_0x161c9a;if($[_0x7897e0(0xbf,'c&G3')])return;let _0x4437d2='',_0x5b2df8=null,_0x15283a=null,_0x2a62c7=_0x7897e0(0xa7,'dr*l');switch(_0x254615){case'superBrandSecondFloorMainPage':_0x4437d2=_0x7897e0(0x74,'qnB$'),_0x5b2df8={'functionId':_0x254615,'body':JSON[_0x7897e0(0x78,'Ysfq')]({'source':'hall_1111'}),'appid':'ProductZ4Brand','t':Date[_0x7897e0(0x91,'Q*^X')](),'client':'wh5'};break;case'superBrandTaskList':_0x4437d2=_0x7897e0(0x74,'qnB$'),_0x5b2df8={'functionId':_0x254615,'body':JSON['stringify']({'source':_0x7897e0(0xd9,'ilmy'),'activityId':_0x32e9c9}),'appid':_0x7897e0(0x71,'^aUl'),'t':Date[_0x7897e0(0xd1,'Ysfq')](),'client':_0x7897e0(0x88,'qnB$')};break;case _0x7897e0(0xf1,'i2xT'):_0x4437d2='https://api.m.jd.com/',_0x5b2df8={'functionId':_0x254615,'body':JSON[_0x7897e0(0xb3,'ziLf')]({'source':'hall_1111','activityId':_0x32e9c9,'completionFlag':0x1,'encryptProjectId':_0x229982,'encryptAssignmentId':_0x4d60ba[_0x7897e0(0x98,'*3A*')],'assignmentType':0x0,'actionType':0x0}),'appid':'ProductZ4Brand','t':Date['now'](),'client':_0x7897e0(0x9b,'dr*l')};break;default:console[_0x7897e0(0x137,'0ZZn')](_0x7897e0(0xf9,')GIx')+_0x254615);return;}const _0x395182={};_0x5b2df8&&Object[_0x7897e0(0xec,'nxP(')](_0x5b2df8,_0x395182);_0x15283a&&Object[_0x7897e0(0xfa,'ziLf')](_0x15283a,_0x395182);const _0x15a427={'url':_0x4437d2,'method':_0x2a62c7,'headers':{'origin':'https://prodev.m.jd.com','Referer':_0x7897e0(0x135,'qnB$'),'User-Agent':_0x568597,'Cookie':_0x16a9ad,'content-type':_0x7897e0(0x7a,'30Ja'),'accept':_0x7897e0(0xef,'dr*l')},'params':_0x15283a,'data':_0x5b2df8,'timeout':0x7530};_0x2a62c7===_0x7897e0(0x130,'8f1j')&&(delete _0x15a427[_0x7897e0(0xd3,'*kE(')],delete _0x15a427[_0x7897e0(0x9c,'qnB$')][_0x7897e0(0xb4,'nxP(')]);const _0x4c0b29=0x1;let _0x2a1045=0x0,_0x50288e=null;while(_0x2a1045<_0x4c0b29){_0x2a1045>0x0&&await $[_0x7897e0(0x90,'8%ib')](0x3e8);const _0x4ba409=await common[_0x7897e0(0xdb,'*3A*')](_0x15a427);if(!_0x4ba409['success']){_0x50288e='🚫\x20'+_0x254615+_0x7897e0(0x7e,'l)Q@')+_0x4ba409[_0x7897e0(0x7d,'H5!5')],_0x2a1045++;continue;}if(!_0x4ba409[_0x7897e0(0xb1,'v%iC')]){_0x50288e=_0x7897e0(0xba,')GIx')+_0x254615+_0x7897e0(0x85,'8%ib'),_0x2a1045++;continue;}await _0x13c3bc(_0x254615,_0x4ba409[_0x7897e0(0x11b,'03tj')]);break;}_0x2a1045>=_0x4c0b29&&console[_0x7897e0(0x73,'SIkt')](_0x50288e);}}
// 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)}