(extra = {})
| 138 | } |
| 139 | |
| 140 | headers(extra = {}) { |
| 141 | const headers = { |
| 142 | "User-Agent": USER_AGENT, |
| 143 | "Accept": "application/json, text/plain, */*", |
| 144 | "xweb_xhr": "1", |
| 145 | "Referer": "https://servicewechat.com/wx54f3e6a00f7973a7/816/page-frame.html", |
| 146 | "Accept-Language": "zh-CN,zh;q=0.9", |
| 147 | ...extra, |
| 148 | }; |
| 149 | if (this.token) headers.token = this.token; |
| 150 | return headers; |
| 151 | } |
| 152 | |
| 153 | async request(baseURL, apiPath, { method = "GET", data, params, auth = true, form = false } = {}) { |
| 154 | const options = { |