MCPcopy Create free account
hub / github.com/smallfawn/QLScriptPublic / headers

Method headers

wxapp/jingjianx_all.js:299–313  ·  view source on GitHub ↗
(shopId = "", token = "", extra = {})

Source from the content-addressed store, hash-verified

297 }
298
299 headers(shopId = "", token = "", extra = {}) {
300 const headers = {
301 "User-Agent": USER_AGENT,
302 "Referer": `https://servicewechat.com/${this.app.appid}/1/page-frame.html`,
303 "content-type": "application/json",
304 "JJ-CHAINID": this.app.chainId,
305 "BDSZH-SHOPID": shopId,
306 "JJ-SHOPID": shopId,
307 "JJ-MiniAppVersion": this.app.version,
308 "JJ-AppId": this.app.appid,
309 ...extra,
310 };
311 if (token) headers.Authorization = `Bearer ${token}`;
312 return headers;
313 }
314
315 async request({ method = "GET", apiPath, shopId = "", token = "", params = {}, data = {}, bizCode = "" }) {
316 const options = {

Callers 1

requestMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected