2023-09-27 09:06:49 +08:00
|
|
|
|
/*
|
|
|
|
|
活动名称:店铺签到 · 超级无线/超级会员
|
|
|
|
|
活动链接:https://lzkj-isv.isvjd.com/sign/signActivity2?activityId=<活动id>
|
|
|
|
|
https://lzkj-isv.isvjd.com/sign/sevenDay/signActivity?activityId=<活动id>
|
|
|
|
|
https://cjhy-isv.isvjcloud.com/sign/signActivity?activityId=<活动id>
|
|
|
|
|
https://cjhy-isv.isvjcloud.com/sign/sevenDay/signActivity?activityId=<活动id>
|
|
|
|
|
环境变量:jd_wxSign_sign_lzkj_Ids // 超级无线签到有礼活动id(旧变量 LZKJ_SIGN)
|
|
|
|
|
jd_wxSign_sevenDay_lzkj_Ids // 超级无线7日签到活动id(旧变量 LZKJ_SEVENDAY)
|
|
|
|
|
jd_wxSign_sign_cjhy_Ids // 超级会员签到有礼活动id(旧变量 CJHY_SIGN)
|
|
|
|
|
jd_wxSign_sevenDay_cjhy_Ids // 超级会员7日签到活动id(旧变量 CJHY_SEVENDAY)
|
|
|
|
|
jd_wxSign_lzkjInterval // 自定义超级无线活动签到间隔(整数),默认1秒
|
|
|
|
|
jd_wxSign_cjhyInterval // 自定义超级会员活动签到间隔(整数),默认1秒
|
|
|
|
|
jd_wxSign_lzkjFilter // 账号pin过滤(跳过不跑),多个用户名用@分割
|
|
|
|
|
jd_wxSign_cjhyFilter // 账号pin过滤(跳过不跑),多个用户名用@分割
|
|
|
|
|
jd_wxSign_Notify // 是否推送通知(true/false),默认不推送
|
|
|
|
|
|
|
|
|
|
不同环境变量对应不同链接类型注意区分,环境变量所对应活动类型的排列顺序与链接的排列顺序一致,如果有多个活动ID用英文逗号分割即可实现多活动签到
|
|
|
|
|
|
|
|
|
|
cron: 7 7 7 7 * jd_wxSign.js
|
|
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
const $ = new Env('店铺签到(超级无线/超级会员)')
|
2023-10-26 23:05:34 +08:00
|
|
|
|
var version_='jsjiami.com.v7';const i1li1i1I=I1lIiiiI;(function(iI11lIii,ll11ll1I,Il1Il1I1,ii1lliIl,lil1iIIi,lii111I1,I1iIIIII){return iI11lIii=iI11lIii>>0x2,lii111I1='hs',I1iIIIII='hs',function(ll1li1l,iIll1lil,IIIIl1i1,IlliIliI,lI1IiiI){const liIllIIl=I1lIiiiI;IlliIliI='tfi',lii111I1=IlliIliI+lii111I1,lI1IiiI='up',I1iIIIII+=lI1IiiI,lii111I1=IIIIl1i1(lii111I1),I1iIIIII=IIIIl1i1(I1iIIIII),IIIIl1i1=0x0;const iIlllI1i=ll1li1l();while(!![]&&--ii1lliIl+iIll1lil){try{IlliIliI=parseInt(liIllIIl(0x34a,'8Adi'))/0x1+-parseInt(liIllIIl(0x26e,'pOn3'))/0x2+parseInt(liIllIIl(0x371,'Q3SU'))/0x3+parseInt(liIllIIl(0x4df,'frro'))/0x4*(parseInt(liIllIIl(0x328,'Apb8'))/0x5)+parseInt(liIllIIl(0x194,'QD@8'))/0x6*(parseInt(liIllIIl(0x44d,'k6N&'))/0x7)+parseInt(liIllIIl(0x352,'I6iu'))/0x8+-parseInt(liIllIIl(0x2a6,'lxUq'))/0x9;}catch(il1iI1l){IlliIliI=IIIIl1i1;}finally{lI1IiiI=iIlllI1i[lii111I1]();if(iI11lIii<=ii1lliIl)IIIIl1i1?lil1iIIi?IlliIliI=lI1IiiI:lil1iIIi=lI1IiiI:IIIIl1i1=lI1IiiI;else{if(IIIIl1i1==lil1iIIi['replace'](/[GCQRgUrwTMfeXEAKdup=]/g,'')){if(IlliIliI===iIll1lil){iIlllI1i['un'+lii111I1](lI1IiiI);break;}iIlllI1i[I1iIIIII](lI1IiiI);}}}}}(Il1Il1I1,ll11ll1I,function(iII1IIii,l11ll1l1,iII1I1I,llil1ilI,Iiilii1l,ii11Ii1i,l1l11iii){return l11ll1l1='\x73\x70\x6c\x69\x74',iII1IIii=arguments[0x0],iII1IIii=iII1IIii[l11ll1l1](''),iII1I1I=`\x72\x65\x76\x65\x72\x73\x65`,iII1IIii=iII1IIii[iII1I1I]('\x76'),llil1ilI=`\x6a\x6f\x69\x6e`,(0x14497f,iII1IIii[llil1ilI](''));});}(0x320,0xd532b,Iiill1i,0xca),Iiill1i)&&(version_=i1li1i1I(0x4b1,'rvfq'));const IiiII1li=require(i1li1i1I(0x1a0,'eZaH')),iI1liiil=require('./function/jdCommon'),I1lIIil1=require(i1li1i1I(0x417,'IpO$')),i1li11ll=require(i1li1i1I(0x489,'P(OR')),{wuxian_savePrize:Il1lIIIi}=require(i1li1i1I(0x40d,'sT]B')),ll1IIiIi=require(i1li1i1I(0x3a1,')FEA')),I1Illii=process[i1li1i1I(0x206,'$FO9')]['jd_wxSign_lzkjInterval']||'',I1Iiliii=process['env']['jd_wxSign_cjhyInterval']||'',IIiIliil=process[i1li1i1I(0x2d5,'4iE3')]['jd_wxSign_Notify']==='true';let iiI1ii1I=(process[i1li1i1I(0x206,'$FO9')][i1li1i1I(0x4cd,'iMt[')]||process['env'][i1li1i1I(0x119,'iHEk')]||'')[i1li1i1I(0x3ba,'8Adi')](','),il1l1iII=(process[i1li1i1I(0x49d,'FKS)')][i1li1i1I(0x469,'gk[E')]||process[i1li1i1I(0x36b,'eZaH')]['LZKJ_SIGN']||'')[i1li1i1I(0x464,'Lw)r')](','),Ii1IlII1=(process[i1li1i1I(0x49f,'iMt[')]['jd_wxSign_sevenDay_cjhy_Ids']||process['env'][i1li1i1I(0x31c,'Q3SU')]||'')[i1li1i1I(0x3dc,'n54c')](','),iliIlII1=(process['env'][i1li1i1I(0x1ed,'$FO9')]||process['env']['CJHY_SIGN']||'')[i1li1i1I(0x23c,'FKS)')](','),illIiI1I=(process[i1li1i1I(0x22e,'a^Zs')][i1li1i1I(0x157,'pOn3')]||'')[i1li1i1I(0x156,')FEA')]('@'),l1I11II1=(process[i1li1i1I(0x22e,'a^Zs')][i1li1i1I(0x39d,'QJ*j')]||'')[i1li1i1I(0x103,'&(j!')]('@'),llli111='',IIliill1={};const iliIlil1=Object[i1li1i1I(0x42c,'8Adi')](IiiII1li)[i1li1i1I(0xe7,'o9Na')](i1Ii1IIl=>IiiII1li[i1Ii1IIl])[i1li1i1I(0x2d6,'Apb8')](iiiIl1il=>iiiIl1il);!iliIlil1[0x0]&&($['msg']($[i1li1i1I(0x291,'FKS)')],i1li1i1I(0x3be,'a^Zs')),process[i1li1i1I(0xde,'IpO$')](0x1));function I1lIiiiI(_0x4bf96c,_0x4c5450){const _0x131ad9=Iiill1i();return I1lIiiiI=function(_0xb8b71b,_0x2f8459){_0xb8b71b=_0xb8b71b-0xc5;let _0x3eeaaa=_0x131ad9[_0xb8b71b];if(I1lIiiiI['UJmukq']===undefined){var _0x50b26a=function(_0x28732b){const _0x850b17='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x15da8f='',_0x21d75f='';for(let _0x4592df=0x0,_0x4d6a7b,_0x2ecb20,_0x2016f0=0x0;_0x2ecb20=_0x28732b['charAt'](_0x2016f0++);~_0x2ecb20&&(_0x4d6a7b=_0x4592df%0x4?_0x4d6a7b*0x40+_0x2ecb20:_0x2ecb20,_0x4592df++%0x4)?_0x15da8f+=String['fromCharCode'](0xff&_0x4d6a7b>>(-0x2*_0x4592df&0x6)):0x0){_0x2ecb20=_0x850b17['indexOf'](_0x2ecb20);}for(let _0x1c2b12=0x0,_0x2fd787=_0x15da8f['length'];_0x1c2b12<_0x2fd787;_0x1c2b12++){_0x21d75f+='%'+('00'+_0x15da8f['charCodeAt'](_0x1c2b12)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x21d75f);};const _0x2a51af=function(_0x328bde,_0x316b9f){let _0x2a1f77=[],_0x188432=0x0,_0x360e04,_0x4b4dab='';_0x328bde=_0x50b26a(_0x328bde);let _0x308e1c;for(_0x308e1c=0x0;_0x308e1c<
|
|
|
|
|
|
2023-09-27 09:06:49 +08:00
|
|
|
|
// prettier-ignore
|
2023-10-26 23:05:34 +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"])
|
|
|
|
|
|