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

Function getPostRequest

jd_summer_movement.js:555–570  ·  view source on GitHub ↗
(body)

Source from the content-addressed store, hash-verified

553}
554
555async function getPostRequest(body) {
556 const method = `POST`;
557 const headers = {
558 "Accept": "application/json",
559 "Accept-Encoding": "gzip, deflgetPostRequestate, br",
560 "Accept-Language": "zh-CN,zh;q=0.9,en;q=0.8",
561 "Connection": "keep-alive",
562 "Content-Type": "application/x-www-form-urlencoded",
563 'Cookie': $.cookie,
564 "Origin": "https://wbbny.m.jd.com",
565 "Referer": "https://wbbny.m.jd.com/",
566 'User-Agent': UA,
567 //'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"),
568 };
569 return { method: method, headers: headers, body: body};
570}
571
572async function getPostBody(type) {
573 return new Promise(async resolve => {

Callers 1

takePostRequestFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected