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

Function getTel

wxapp/zhanma.js:189–220  ·  view source on GitHub ↗

* 获取手机号 *

(timeout = 2 * 1000)

Source from the content-addressed store, hash-verified

187 *
188 */
189function getTel (timeout = 2 * 1000) {
190 return new Promise((resolve) => {
191 let url = {
192 url: `https://zm.t7a.cn/api/getuserinfo.php?safe=${zmnlxq}`,
193 headers: {
194 'Host': 'zm.t7a.cn',
195 'user-agent': 'Mozilla/5.0 (Linux; Android 10; MI 8 Build/QKQ1.190828.002; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/86.0.4240.99 XWEB/3235 MMWEBSDK/20220204 Mobile Safari/537.36 MMWEBID/6242 MicroMessenger/8.0.20.2080(0x28001435) Process/appbrand0 WeChat/arm64 Weixin NetType/WIFI Language/zh_CN ABI/arm64 miniProgram/wx532ecb3bdaaf92f9'
196 },
197 // body: '',
198
199 }
200 $.get(url, async (error, response, data) => {
201 try {
202 result = JSON.parse(data)
203
204 if (result.status == 1) {
205
206 console.log(result.msg)
207
208 } else {
209
210 console.log(result.msg)
211
212 }
213 } catch (e) {
214 console.log(e)
215 } finally {
216 resolve(result.tel);
217 }
218 }, timeout)
219 })
220}
221
222/**
223 * 签到

Callers 1

getuserFunction · 0.85

Calls 2

getMethod · 0.45
logMethod · 0.45

Tested by

no test coverage detected