(extra = {})
| 132 | } |
| 133 | |
| 134 | headers(extra = {}) { |
| 135 | const headers = { |
| 136 | "Content-Type": "application/json", |
| 137 | "User-Agent": USER_AGENT, |
| 138 | "Accept": "*/*", |
| 139 | "Accept-Language": "zh-CN,zh;q=0.9", |
| 140 | "Referer": "https://servicewechat.com/wx6b6c5243359fe265/171/page-frame.html", |
| 141 | "xweb_xhr": "1", |
| 142 | ...extra, |
| 143 | }; |
| 144 | if (this.token) headers["X-Dts-Token"] = this.token; |
| 145 | return headers; |
| 146 | } |
| 147 | |
| 148 | async request(apiPath, { method = "GET", data = {}, auth = true } = {}) { |
| 149 | const options = { |