MCPcopy Create free account
hub / github.com/Semporia/Scripts / getRandomCode

Function getRandomCode

jd_syj.js:727–746  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

725 })
726}
727async function getRandomCode() {
728 await $.http.get({url: ``, timeout: 10000}).then(async (resp) => {
729 if (resp.statusCode === 200) {
730 try {
731 let { body } = resp;
732 body = JSON.parse(body);
733 if (body && body['code'] === 200) {
734 console.log(`随机取【赚京豆-瓜分京豆】${randomCount}个邀请码成功\n`);
735 $.body = [];
736 $.body1 = [];
737 $.body.map(item => {
738 // $.body1.push(JSON.parse(item));
739 })
740 }
741 } catch (e) {
742 console.log(`随机取【赚京豆-瓜分京豆】${randomCount}个邀请码异常:${e}`);
743 }
744 }
745 }).catch((e) => console.log(`随机取【赚京豆-瓜分京豆】${randomCount}个邀请码异常:${e}`));
746}
747//======================赚京豆开团===========END=====
748function taskUrl(function_id, body = {}) {
749 return {

Callers 1

jd_syj.jsFile · 0.70

Calls 2

getMethod · 0.45
logMethod · 0.45

Tested by

no test coverage detected