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

Function taskUrl

jd_superMarket.js:1793–1804  ·  view source on GitHub ↗
(function_id, body = {})

Source from the content-addressed store, hash-verified

1791}
1792
1793function taskUrl(function_id, body = {}) {
1794 return {
1795 url: `${JD_API_HOST}?functionId=${function_id}&appid=jdsupermarket&clientVersion=8.0.0&client=m&body=${escape(JSON.stringify(body))}&t=${Date.now()}`,
1796 headers: {
1797 'User-Agent': $.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"),
1798 'Host': 'api.m.jd.com',
1799 'Cookie': cookie,
1800 'Referer': 'https://jdsupermarket.jd.com/game',
1801 'Origin': 'https://jdsupermarket.jd.com',
1802 }
1803 }
1804}
1805
1806/**
1807 * 生成随机数字

Callers 15

receiveBlueCoinFunction · 0.70
smtgSignFunction · 0.70
smtg_shopIndexFunction · 0.70
smtg_shelfUnlockFunction · 0.70
smtg_shelfUpgradeFunction · 0.70
smtg_sellMerchandiseFunction · 0.70
smtgDoShopTaskFunction · 0.70
smtgObtainShopTaskPrizeFunction · 0.70
smtgQueryShopTaskFunction · 0.70
smtgSignListFunction · 0.70
smtgQueryPkTaskFunction · 0.70
smtgDoAssistPkTaskFunction · 0.70

Calls 2

isNodeMethod · 0.45
getdataMethod · 0.45

Tested by

no test coverage detected