mirror of
https://github.com/shufflewzc/faker2.git
synced 2025-05-07 03:48:44 +08:00
Update jd_ppdt.js
This commit is contained in:
parent
9df64e5d0b
commit
f0d68ac5cd
98
jd_ppdt.js
98
jd_ppdt.js
@ -39,8 +39,12 @@ if ($.isNode()) {
|
|||||||
}
|
}
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
await xxx7();
|
||||||
|
await $.wait(1000);
|
||||||
await xxx1();
|
await xxx1();
|
||||||
|
if ($.ban) { console.log('风控,跳出'); continue };
|
||||||
await $.wait(500);
|
await $.wait(500);
|
||||||
|
if ($.done) continue;
|
||||||
await xxx2();
|
await xxx2();
|
||||||
await $.wait(500);
|
await $.wait(500);
|
||||||
await xxx4();
|
await xxx4();
|
||||||
@ -48,6 +52,8 @@ if ($.isNode()) {
|
|||||||
await xxx3();
|
await xxx3();
|
||||||
await $.wait(500);
|
await $.wait(500);
|
||||||
await xxx5();
|
await xxx5();
|
||||||
|
await $.wait(500);
|
||||||
|
await xxx6();
|
||||||
await $.wait(2000);
|
await $.wait(2000);
|
||||||
|
|
||||||
|
|
||||||
@ -91,6 +97,12 @@ async function xxx1() {
|
|||||||
} else {
|
} else {
|
||||||
console.log(JSON.stringify(data.data?.result));
|
console.log(JSON.stringify(data.data?.result));
|
||||||
}
|
}
|
||||||
|
} else if (data.data.bizMsg.indexOf('风控') > -1) {
|
||||||
|
console.log(data.data.bizMsg);
|
||||||
|
$.ban = true;
|
||||||
|
} else if (data.data.bizMsg.indexOf('完成') > -1) {
|
||||||
|
console.log(data.data.bizMsg);
|
||||||
|
$.done = true;
|
||||||
} else {
|
} else {
|
||||||
console.log(data.data.bizMsg);
|
console.log(data.data.bizMsg);
|
||||||
}
|
}
|
||||||
@ -281,6 +293,92 @@ async function xxx5() {
|
|||||||
})
|
})
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
async function xxx6() {
|
||||||
|
let opt = {
|
||||||
|
url: `https://api.m.jd.com/?client=wh5&appid=ProductZ4Brand&functionId=superBrandDoTask&t=1674780027902&body=%7B%22source%22:%22hall_1111%22,%22activityId%22:1012475,%22completionFlag%22:1,%22encryptProjectId%22:%2247yMVdNbddRfnKm5SKuUPfuid3LT%22,%22encryptAssignmentId%22:%223nrQJYLHKg3pHFWvd2oadunRbMWx%22,%22assignmentType%22:0,%22actionType%22:0%7D`,
|
||||||
|
headers: {
|
||||||
|
'Origin': 'https://prodev.m.jd.com',
|
||||||
|
'User-Agent': $.UA,
|
||||||
|
'Cookie': cookie
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return new Promise(async (resolve) => {
|
||||||
|
$.post(opt, async (err, resp, data) => {
|
||||||
|
try {
|
||||||
|
if (err) {
|
||||||
|
console.log(`${JSON.stringify(err)}`)
|
||||||
|
console.log(` API请求失败,请检查网路重试`)
|
||||||
|
} else {
|
||||||
|
data = JSON.parse(data)
|
||||||
|
if (data.code == 0) {
|
||||||
|
if (data.data.bizCode == 0) {
|
||||||
|
if (data.data?.result?.rewards.length != 0) {
|
||||||
|
if (data.data?.result?.rewards[0].awardType === 3) {
|
||||||
|
console.log(` 恭喜获得 ${data.data?.result?.rewards[0].beanNum} 京豆`);
|
||||||
|
} else {
|
||||||
|
console.log(JSON.stringify(data.data?.result?.rewards));
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
console.log(JSON.stringify(data.data?.result));
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
console.log(data.data.bizMsg);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
console.log(data.msg)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} catch (e) {
|
||||||
|
$.logErr(e, resp)
|
||||||
|
} finally {
|
||||||
|
resolve(data)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
})
|
||||||
|
}
|
||||||
|
async function xxx7() {
|
||||||
|
let opt = {
|
||||||
|
url: `https://api.m.jd.com/?client=wh5&appid=ProductZ4Brand&functionId=superBrandDoTask&t=1674865770750&body=%7B%22source%22:%22hall_1111%22,%22activityId%22:1012476,%22completionFlag%22:1,%22encryptProjectId%22:%222GRBptWGUbVNFwfZLW6AxDQHCDTo%22,%22encryptAssignmentId%22:%223F6VgHQjejVYZqetSSqdP45bYbuq%22,%22assignmentType%22:0,%22actionType%22:0%7D`,
|
||||||
|
headers: {
|
||||||
|
'Origin': 'https://prodev.m.jd.com',
|
||||||
|
'User-Agent': $.UA,
|
||||||
|
'Cookie': cookie
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return new Promise(async (resolve) => {
|
||||||
|
$.post(opt, async (err, resp, data) => {
|
||||||
|
try {
|
||||||
|
if (err) {
|
||||||
|
console.log(`${JSON.stringify(err)}`)
|
||||||
|
console.log(` API请求失败,请检查网路重试`)
|
||||||
|
} else {
|
||||||
|
data = JSON.parse(data)
|
||||||
|
if (data.code == 0) {
|
||||||
|
if (data.data.bizCode == 0) {
|
||||||
|
if (data.data?.result?.rewards.length != 0) {
|
||||||
|
if (data.data?.result?.rewards[0].awardType === 3) {
|
||||||
|
console.log(` 恭喜获得 ${data.data?.result?.rewards[0].beanNum} 京豆`);
|
||||||
|
} else {
|
||||||
|
console.log(JSON.stringify(data.data?.result?.rewards));
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
console.log(JSON.stringify(data.data?.result));
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
console.log(data.data.bizMsg);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
console.log(data.msg)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} catch (e) {
|
||||||
|
$.logErr(e, resp)
|
||||||
|
} finally {
|
||||||
|
resolve(data)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
})
|
||||||
|
}
|
||||||
function TotalBean() {
|
function TotalBean() {
|
||||||
return new Promise((resolve) => {
|
return new Promise((resolve) => {
|
||||||
const options = {
|
const options = {
|
||||||
|
Loading…
Reference in New Issue
Block a user