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

Function request

wxapp/oppo.js:85–97  ·  view source on GitHub ↗
(options)

Source from the content-addressed store, hash-verified

83}
84
85async function request(options) {
86 const res = await axios.request({
87 timeout: 25000,
88 validateStatus: () => true,
89 ...options,
90 headers: {
91 "User-Agent": USER_AGENT,
92 Accept: "application/json, text/plain, */*",
93 ...(options.headers || {}),
94 },
95 });
96 return { status: res.status, headers: res.headers || {}, data: res.data };
97}
98
99async function getWxCode(openid) {
100 if (!WX_AUTH) throw new Error("未配置 wx_auth,无法从 wx_server 获取 code");

Callers 4

getWxCodeFunction · 0.70
miniRequestMethod · 0.70
h5RequestMethod · 0.70
loginMethod · 0.70

Calls 1

requestMethod · 0.45

Tested by

no test coverage detected