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

Function taskUrl

jd_fruit.js:1437–1446  ·  view source on GitHub ↗
(function_id, body = {})

Source from the content-addressed store, hash-verified

1435 }
1436}
1437function taskUrl(function_id, body = {}) {
1438 return {
1439 url: `${JD_API_HOST}?functionId=${function_id}&appid=wh5&body=${escape(JSON.stringify(body))}`,
1440 headers: {
1441 Cookie: cookie,
1442 UserAgent: $.isNode() ? (process.env.JD_USER_AGENT ? process.env.JD_USER_AGENT : (require('./USER_AGENTS').USER_AGENT)) : ($.getdata('JDUA') ? $.getdata('JDUA') : "jdapp;iPhone;9.4.4;14.3;network/4g;Mozilla/5.0 (iPhone; CPU iPhone OS 14_3 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/15E148;supportJDSHWK/1"),
1443 },
1444 timeout: 10000,
1445 }
1446}
1447function jsonParse(str) {
1448 if (typeof str == "string") {
1449 try {

Callers 2

getFullCollectionRewardFunction · 0.70
requestFunction · 0.70

Calls 2

isNodeMethod · 0.45
getdataMethod · 0.45

Tested by

no test coverage detected