@newbeebox/newbeebox-client-web-sdk 1.0.19 → 1.0.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +462 -459
- package/dist/index.d.ts +3 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,459 +1,462 @@
|
|
|
1
|
-
## 新手盒子客户端SDK
|
|
2
|
-
|
|
3
|
-
用于Web类第三方应用调用新手盒子客户端相关功能的开发组件。
|
|
4
|
-
|
|
5
|
-
### 目录
|
|
6
|
-
|
|
7
|
-
- [安装](#安装)
|
|
8
|
-
- [快速上手](#快速上手)
|
|
9
|
-
- [API](#api)
|
|
10
|
-
- [Init](#init) — 初始化并连接客户端
|
|
11
|
-
- [GetClientVersion](#getclientversion) — 获取客户端版本号
|
|
12
|
-
- [ShowSubscriptionPage](#showsubscriptionpage) — 打开应用订阅界面
|
|
13
|
-
- [GetUserSubscription](#getusersubscription) — 获取当前用户订阅信息
|
|
14
|
-
- [GetUserInfo](#getuserinfo) — 获取当前登录用户信息
|
|
15
|
-
- [GetWoWCurrentVersion](#getwowcurrentversion) — 获取当前选中的游戏版本
|
|
16
|
-
- [InstallWoWAddon](#installwowaddon) — 安装魔兽世界插件
|
|
17
|
-
- [Patch](#patch) — 通用请求接口
|
|
18
|
-
- [数据结构](#数据结构)
|
|
19
|
-
- [UserSubscribeInfo](#usersubscribeinfo)
|
|
20
|
-
- [UserAccountInfo](#useraccountinfo)
|
|
21
|
-
- [UserInfo](#userinfo)
|
|
22
|
-
- [UserVipInfo](#uservipinfo)
|
|
23
|
-
- [WoWGameVersion](#wowgameversion)
|
|
24
|
-
- [SUBSCRIBE_MODE](#subscribe_mode)
|
|
25
|
-
- [其他导出](#其他导出)
|
|
26
|
-
- [错误处理](#错误处理)
|
|
27
|
-
|
|
28
|
-
### 安装
|
|
29
|
-
|
|
30
|
-
```bash
|
|
31
|
-
npm install @newbeebox/newbeebox-client-web-sdk
|
|
32
|
-
```
|
|
33
|
-
|
|
34
|
-
### 快速上手
|
|
35
|
-
|
|
36
|
-
```javascript
|
|
37
|
-
import { NewBeeClient } from "@newbeebox/newbeebox-client-web-sdk"
|
|
38
|
-
|
|
39
|
-
// 1.初始化客户端
|
|
40
|
-
let client = new NewBeeClient();
|
|
41
|
-
await client.Init("your_app_id");
|
|
42
|
-
|
|
43
|
-
// 2.功能调用
|
|
44
|
-
// 打开应用订阅界面
|
|
45
|
-
await client.ShowSubscriptionPage();
|
|
46
|
-
|
|
47
|
-
// 获取当前用户订阅信息
|
|
48
|
-
let info = await client.GetUserSubscription();
|
|
49
|
-
console.log(info);
|
|
50
|
-
|
|
51
|
-
// 获取当前登录用户信息
|
|
52
|
-
let user = await client.GetUserInfo();
|
|
53
|
-
console.log(user);
|
|
54
|
-
|
|
55
|
-
// 获取客户端当前选中的魔兽世界版本
|
|
56
|
-
let version = await client.GetWoWCurrentVersion();
|
|
57
|
-
console.log(version); // { id: 8, name: "燃烧的远征" }
|
|
58
|
-
|
|
59
|
-
// 获取新手盒子客户端版本号
|
|
60
|
-
let clientVersion = client.GetClientVersion();
|
|
61
|
-
console.log(clientVersion); // "0.70.41"
|
|
62
|
-
```
|
|
63
|
-
|
|
64
|
-
### API
|
|
65
|
-
|
|
66
|
-
除 `GetClientVersion` 为同步方法外,其余均为异步接口,需 `await`。
|
|
67
|
-
调用任何接口前必须先调用 [Init](#init)。
|
|
68
|
-
|
|
69
|
-
---
|
|
70
|
-
|
|
71
|
-
#### Init
|
|
72
|
-
|
|
73
|
-
初始化SDK,扫描本地端口连接新手盒子客户端。
|
|
74
|
-
|
|
75
|
-
```typescript
|
|
76
|
-
Init(app_id: string): Promise<void>
|
|
77
|
-
```
|
|
78
|
-
|
|
79
|
-
**入参**
|
|
80
|
-
|
|
81
|
-
| 参数 | 类型 | 必填 | 说明 |
|
|
82
|
-
|------|------|------|------|
|
|
83
|
-
| app_id | string | 是 | 应用ID,从后台获取 |
|
|
84
|
-
|
|
85
|
-
**出参**
|
|
86
|
-
|
|
87
|
-
| 字段 | 类型 | 说明 |
|
|
88
|
-
|------|------|------|
|
|
89
|
-
| (返回值) | void | 无返回值。未检测到客户端时抛出错误 |
|
|
90
|
-
|
|
91
|
-
---
|
|
92
|
-
|
|
93
|
-
#### GetClientVersion
|
|
94
|
-
|
|
95
|
-
获取新手盒子客户端的版本号。同步方法,无需 `await`。
|
|
96
|
-
|
|
97
|
-
```typescript
|
|
98
|
-
GetClientVersion(): string
|
|
99
|
-
```
|
|
100
|
-
|
|
101
|
-
**入参**
|
|
102
|
-
|
|
103
|
-
无。
|
|
104
|
-
|
|
105
|
-
**出参**
|
|
106
|
-
|
|
107
|
-
| 字段 | 类型 | 说明 |
|
|
108
|
-
|------|------|------|
|
|
109
|
-
| (返回值) | string | 客户端版本号,形如 `主.次.修订`;客户端未提供版本号时为空字符串 |
|
|
110
|
-
|
|
111
|
-
```javascript
|
|
112
|
-
"0.70.41"
|
|
113
|
-
```
|
|
114
|
-
|
|
115
|
-
版本号比较时需按段拆成数字,不能直接比较字符串。
|
|
116
|
-
|
|
117
|
-
---
|
|
118
|
-
|
|
119
|
-
#### ShowSubscriptionPage
|
|
120
|
-
|
|
121
|
-
打开应用订阅界面。
|
|
122
|
-
|
|
123
|
-
```typescript
|
|
124
|
-
ShowSubscriptionPage(): Promise<boolean>
|
|
125
|
-
```
|
|
126
|
-
|
|
127
|
-
**入参**
|
|
128
|
-
|
|
129
|
-
无。
|
|
130
|
-
|
|
131
|
-
**出参**
|
|
132
|
-
|
|
133
|
-
| 字段 | 类型 | 说明 |
|
|
134
|
-
|------|------|------|
|
|
135
|
-
| (返回值) | boolean | 打开成功返回 `true`,失败时抛出错误 |
|
|
136
|
-
|
|
137
|
-
---
|
|
138
|
-
|
|
139
|
-
#### GetUserSubscription
|
|
140
|
-
|
|
141
|
-
获取当前用户的订阅信息。
|
|
142
|
-
|
|
143
|
-
```typescript
|
|
144
|
-
GetUserSubscription(): Promise<UserSubscribeInfo>
|
|
145
|
-
```
|
|
146
|
-
|
|
147
|
-
**入参**
|
|
148
|
-
|
|
149
|
-
无。
|
|
150
|
-
|
|
151
|
-
**出参**
|
|
152
|
-
|
|
153
|
-
| 字段 | 类型 | 说明 |
|
|
154
|
-
|------|------|------|
|
|
155
|
-
| app_id | string | 应用ID |
|
|
156
|
-
| user | object | 用户信息,见 [UserInfo](#userinfo) |
|
|
157
|
-
| user.open_id | string | 用户在本应用下的唯一标识 |
|
|
158
|
-
| user.nickname | string | 用户昵称 |
|
|
159
|
-
| user.avatar | string | 用户头像地址 |
|
|
160
|
-
| subscribe_mode | number | 订阅模式,见 [SUBSCRIBE_MODE](#subscribe_mode) |
|
|
161
|
-
| end_time | number | 订阅到期时间戳(毫秒),`0` 表示无到期时间 |
|
|
162
|
-
| level | number | 订阅等级 |
|
|
163
|
-
| level_label | string | 订阅等级标签 |
|
|
164
|
-
| is_yearly | boolean | 是否年订阅 |
|
|
165
|
-
| timestamp | number | 服务端时间戳(毫秒) |
|
|
166
|
-
| nonce | number | 随机数,用于验签 |
|
|
167
|
-
| sign | string | 签名,用于服务端校验数据未被篡改 |
|
|
168
|
-
|
|
169
|
-
```javascript
|
|
170
|
-
{
|
|
171
|
-
"app_id": "nb1a2b3c4d",
|
|
172
|
-
"user": {
|
|
173
|
-
"open_id": "nb0a1b2c3d4e5f6a7b8c9d0",
|
|
174
|
-
"nickname": "示例用户",
|
|
175
|
-
"avatar": "https://cdn8.newbeebox.com/user/avatar/0/0a1b2c3d4e5f6a7b8c9d0e1f2a3b4c5d.png"
|
|
176
|
-
},
|
|
177
|
-
"subscribe_mode": 1,
|
|
178
|
-
"end_time": 0,
|
|
179
|
-
"level": 0,
|
|
180
|
-
"level_label": "",
|
|
181
|
-
"is_yearly": false,
|
|
182
|
-
"timestamp": 1700000000000,
|
|
183
|
-
"nonce": 1234567890,
|
|
184
|
-
"sign": "3f2a1c9d8e7b6a5f4e3d2c1b0a9f8e7d"
|
|
185
|
-
}
|
|
186
|
-
```
|
|
187
|
-
|
|
188
|
-
`timestamp`、`nonce`、`sign` 供第三方服务端校验使用,不要在浏览器端直接信任订阅结果。
|
|
189
|
-
|
|
190
|
-
---
|
|
191
|
-
|
|
192
|
-
#### GetUserInfo
|
|
193
|
-
|
|
194
|
-
获取当前登录用户的基础信息。用户未登录时抛出错误。
|
|
195
|
-
|
|
196
|
-
```typescript
|
|
197
|
-
GetUserInfo(): Promise<UserAccountInfo>
|
|
198
|
-
```
|
|
199
|
-
|
|
200
|
-
**入参**
|
|
201
|
-
|
|
202
|
-
无。
|
|
203
|
-
|
|
204
|
-
**出参**
|
|
205
|
-
|
|
206
|
-
| 字段 | 类型 | 说明 |
|
|
207
|
-
|------|------|------|
|
|
208
|
-
| id | number | 用户ID |
|
|
209
|
-
|
|
|
210
|
-
|
|
|
211
|
-
|
|
|
212
|
-
|
|
|
213
|
-
| vip
|
|
214
|
-
| vip.
|
|
215
|
-
| vip.
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
"
|
|
221
|
-
"
|
|
222
|
-
"
|
|
223
|
-
"
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
"
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
```
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
|
278
|
-
|
|
279
|
-
|
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
|
286
|
-
|
|
287
|
-
|
|
|
288
|
-
|
|
|
289
|
-
|
|
|
290
|
-
| secret_write
|
|
291
|
-
| secret_write.
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
"
|
|
298
|
-
"
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
"
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
"
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
```
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
1
|
+
## 新手盒子客户端SDK
|
|
2
|
+
|
|
3
|
+
用于Web类第三方应用调用新手盒子客户端相关功能的开发组件。
|
|
4
|
+
|
|
5
|
+
### 目录
|
|
6
|
+
|
|
7
|
+
- [安装](#安装)
|
|
8
|
+
- [快速上手](#快速上手)
|
|
9
|
+
- [API](#api)
|
|
10
|
+
- [Init](#init) — 初始化并连接客户端
|
|
11
|
+
- [GetClientVersion](#getclientversion) — 获取客户端版本号
|
|
12
|
+
- [ShowSubscriptionPage](#showsubscriptionpage) — 打开应用订阅界面
|
|
13
|
+
- [GetUserSubscription](#getusersubscription) — 获取当前用户订阅信息
|
|
14
|
+
- [GetUserInfo](#getuserinfo) — 获取当前登录用户信息
|
|
15
|
+
- [GetWoWCurrentVersion](#getwowcurrentversion) — 获取当前选中的游戏版本
|
|
16
|
+
- [InstallWoWAddon](#installwowaddon) — 安装魔兽世界插件
|
|
17
|
+
- [Patch](#patch) — 通用请求接口
|
|
18
|
+
- [数据结构](#数据结构)
|
|
19
|
+
- [UserSubscribeInfo](#usersubscribeinfo)
|
|
20
|
+
- [UserAccountInfo](#useraccountinfo)
|
|
21
|
+
- [UserInfo](#userinfo)
|
|
22
|
+
- [UserVipInfo](#uservipinfo)
|
|
23
|
+
- [WoWGameVersion](#wowgameversion)
|
|
24
|
+
- [SUBSCRIBE_MODE](#subscribe_mode)
|
|
25
|
+
- [其他导出](#其他导出)
|
|
26
|
+
- [错误处理](#错误处理)
|
|
27
|
+
|
|
28
|
+
### 安装
|
|
29
|
+
|
|
30
|
+
```bash
|
|
31
|
+
npm install @newbeebox/newbeebox-client-web-sdk
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
### 快速上手
|
|
35
|
+
|
|
36
|
+
```javascript
|
|
37
|
+
import { NewBeeClient } from "@newbeebox/newbeebox-client-web-sdk"
|
|
38
|
+
|
|
39
|
+
// 1.初始化客户端
|
|
40
|
+
let client = new NewBeeClient();
|
|
41
|
+
await client.Init("your_app_id");
|
|
42
|
+
|
|
43
|
+
// 2.功能调用
|
|
44
|
+
// 打开应用订阅界面
|
|
45
|
+
await client.ShowSubscriptionPage();
|
|
46
|
+
|
|
47
|
+
// 获取当前用户订阅信息
|
|
48
|
+
let info = await client.GetUserSubscription();
|
|
49
|
+
console.log(info);
|
|
50
|
+
|
|
51
|
+
// 获取当前登录用户信息
|
|
52
|
+
let user = await client.GetUserInfo();
|
|
53
|
+
console.log(user);
|
|
54
|
+
|
|
55
|
+
// 获取客户端当前选中的魔兽世界版本
|
|
56
|
+
let version = await client.GetWoWCurrentVersion();
|
|
57
|
+
console.log(version); // { id: 8, name: "燃烧的远征" }
|
|
58
|
+
|
|
59
|
+
// 获取新手盒子客户端版本号
|
|
60
|
+
let clientVersion = client.GetClientVersion();
|
|
61
|
+
console.log(clientVersion); // "0.70.41"
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
### API
|
|
65
|
+
|
|
66
|
+
除 `GetClientVersion` 为同步方法外,其余均为异步接口,需 `await`。
|
|
67
|
+
调用任何接口前必须先调用 [Init](#init)。
|
|
68
|
+
|
|
69
|
+
---
|
|
70
|
+
|
|
71
|
+
#### Init
|
|
72
|
+
|
|
73
|
+
初始化SDK,扫描本地端口连接新手盒子客户端。
|
|
74
|
+
|
|
75
|
+
```typescript
|
|
76
|
+
Init(app_id: string): Promise<void>
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
**入参**
|
|
80
|
+
|
|
81
|
+
| 参数 | 类型 | 必填 | 说明 |
|
|
82
|
+
|------|------|------|------|
|
|
83
|
+
| app_id | string | 是 | 应用ID,从后台获取 |
|
|
84
|
+
|
|
85
|
+
**出参**
|
|
86
|
+
|
|
87
|
+
| 字段 | 类型 | 说明 |
|
|
88
|
+
|------|------|------|
|
|
89
|
+
| (返回值) | void | 无返回值。未检测到客户端时抛出错误 |
|
|
90
|
+
|
|
91
|
+
---
|
|
92
|
+
|
|
93
|
+
#### GetClientVersion
|
|
94
|
+
|
|
95
|
+
获取新手盒子客户端的版本号。同步方法,无需 `await`。
|
|
96
|
+
|
|
97
|
+
```typescript
|
|
98
|
+
GetClientVersion(): string
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
**入参**
|
|
102
|
+
|
|
103
|
+
无。
|
|
104
|
+
|
|
105
|
+
**出参**
|
|
106
|
+
|
|
107
|
+
| 字段 | 类型 | 说明 |
|
|
108
|
+
|------|------|------|
|
|
109
|
+
| (返回值) | string | 客户端版本号,形如 `主.次.修订`;客户端未提供版本号时为空字符串 |
|
|
110
|
+
|
|
111
|
+
```javascript
|
|
112
|
+
"0.70.41"
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
版本号比较时需按段拆成数字,不能直接比较字符串。
|
|
116
|
+
|
|
117
|
+
---
|
|
118
|
+
|
|
119
|
+
#### ShowSubscriptionPage
|
|
120
|
+
|
|
121
|
+
打开应用订阅界面。
|
|
122
|
+
|
|
123
|
+
```typescript
|
|
124
|
+
ShowSubscriptionPage(): Promise<boolean>
|
|
125
|
+
```
|
|
126
|
+
|
|
127
|
+
**入参**
|
|
128
|
+
|
|
129
|
+
无。
|
|
130
|
+
|
|
131
|
+
**出参**
|
|
132
|
+
|
|
133
|
+
| 字段 | 类型 | 说明 |
|
|
134
|
+
|------|------|------|
|
|
135
|
+
| (返回值) | boolean | 打开成功返回 `true`,失败时抛出错误 |
|
|
136
|
+
|
|
137
|
+
---
|
|
138
|
+
|
|
139
|
+
#### GetUserSubscription
|
|
140
|
+
|
|
141
|
+
获取当前用户的订阅信息。
|
|
142
|
+
|
|
143
|
+
```typescript
|
|
144
|
+
GetUserSubscription(): Promise<UserSubscribeInfo>
|
|
145
|
+
```
|
|
146
|
+
|
|
147
|
+
**入参**
|
|
148
|
+
|
|
149
|
+
无。
|
|
150
|
+
|
|
151
|
+
**出参**
|
|
152
|
+
|
|
153
|
+
| 字段 | 类型 | 说明 |
|
|
154
|
+
|------|------|------|
|
|
155
|
+
| app_id | string | 应用ID |
|
|
156
|
+
| user | object | 用户信息,见 [UserInfo](#userinfo) |
|
|
157
|
+
| user.open_id | string | 用户在本应用下的唯一标识 |
|
|
158
|
+
| user.nickname | string | 用户昵称 |
|
|
159
|
+
| user.avatar | string | 用户头像地址 |
|
|
160
|
+
| subscribe_mode | number | 订阅模式,见 [SUBSCRIBE_MODE](#subscribe_mode) |
|
|
161
|
+
| end_time | number | 订阅到期时间戳(毫秒),`0` 表示无到期时间 |
|
|
162
|
+
| level | number | 订阅等级 |
|
|
163
|
+
| level_label | string | 订阅等级标签 |
|
|
164
|
+
| is_yearly | boolean | 是否年订阅 |
|
|
165
|
+
| timestamp | number | 服务端时间戳(毫秒) |
|
|
166
|
+
| nonce | number | 随机数,用于验签 |
|
|
167
|
+
| sign | string | 签名,用于服务端校验数据未被篡改 |
|
|
168
|
+
|
|
169
|
+
```javascript
|
|
170
|
+
{
|
|
171
|
+
"app_id": "nb1a2b3c4d",
|
|
172
|
+
"user": {
|
|
173
|
+
"open_id": "nb0a1b2c3d4e5f6a7b8c9d0",
|
|
174
|
+
"nickname": "示例用户",
|
|
175
|
+
"avatar": "https://cdn8.newbeebox.com/user/avatar/0/0a1b2c3d4e5f6a7b8c9d0e1f2a3b4c5d.png"
|
|
176
|
+
},
|
|
177
|
+
"subscribe_mode": 1,
|
|
178
|
+
"end_time": 0,
|
|
179
|
+
"level": 0,
|
|
180
|
+
"level_label": "",
|
|
181
|
+
"is_yearly": false,
|
|
182
|
+
"timestamp": 1700000000000,
|
|
183
|
+
"nonce": 1234567890,
|
|
184
|
+
"sign": "3f2a1c9d8e7b6a5f4e3d2c1b0a9f8e7d"
|
|
185
|
+
}
|
|
186
|
+
```
|
|
187
|
+
|
|
188
|
+
`timestamp`、`nonce`、`sign` 供第三方服务端校验使用,不要在浏览器端直接信任订阅结果。
|
|
189
|
+
|
|
190
|
+
---
|
|
191
|
+
|
|
192
|
+
#### GetUserInfo
|
|
193
|
+
|
|
194
|
+
获取当前登录用户的基础信息。用户未登录时抛出错误。
|
|
195
|
+
|
|
196
|
+
```typescript
|
|
197
|
+
GetUserInfo(): Promise<UserAccountInfo>
|
|
198
|
+
```
|
|
199
|
+
|
|
200
|
+
**入参**
|
|
201
|
+
|
|
202
|
+
无。
|
|
203
|
+
|
|
204
|
+
**出参**
|
|
205
|
+
|
|
206
|
+
| 字段 | 类型 | 说明 |
|
|
207
|
+
|------|------|------|
|
|
208
|
+
| id | number | 用户ID |
|
|
209
|
+
| openid | string | 用户在本应用下的唯一标识,客户端未返回时为空字符串 |
|
|
210
|
+
| username | string | 用户名 |
|
|
211
|
+
| avatar | string | 用户头像地址 |
|
|
212
|
+
| isVip | boolean | 是否是 VIP |
|
|
213
|
+
| vip | object \| null | VIP 信息,见 [UserVipInfo](#uservipinfo);非 VIP 时为 `null` |
|
|
214
|
+
| vip.isYearly | boolean | 是否年费会员 |
|
|
215
|
+
| vip.adFree | boolean | 是否免广告 |
|
|
216
|
+
| vip.endTime | number \| null | 会员到期时间戳(毫秒) |
|
|
217
|
+
|
|
218
|
+
```javascript
|
|
219
|
+
{
|
|
220
|
+
"id": 10001,
|
|
221
|
+
"openid": "nb0a1b2c3d4e5f6a7b8c9d0",
|
|
222
|
+
"username": "示例用户",
|
|
223
|
+
"avatar": "https://cdn8.newbeebox.com/user/avatar/0/0a1b2c3d4e5f6a7b8c9d0e1f2a3b4c5d.png",
|
|
224
|
+
"isVip": true,
|
|
225
|
+
"vip": {
|
|
226
|
+
"isYearly": false,
|
|
227
|
+
"adFree": true,
|
|
228
|
+
"endTime": 1790000000000
|
|
229
|
+
}
|
|
230
|
+
}
|
|
231
|
+
```
|
|
232
|
+
|
|
233
|
+
---
|
|
234
|
+
|
|
235
|
+
#### GetWoWCurrentVersion
|
|
236
|
+
|
|
237
|
+
获取客户端当前选中的魔兽世界游戏版本。
|
|
238
|
+
|
|
239
|
+
```typescript
|
|
240
|
+
GetWoWCurrentVersion(): Promise<WoWGameVersion>
|
|
241
|
+
```
|
|
242
|
+
|
|
243
|
+
**入参**
|
|
244
|
+
|
|
245
|
+
无。
|
|
246
|
+
|
|
247
|
+
**出参**
|
|
248
|
+
|
|
249
|
+
| 字段 | 类型 | 说明 |
|
|
250
|
+
|------|------|------|
|
|
251
|
+
| id | number | 游戏版本ID,可直接作为 [InstallWoWAddon](#installwowaddon) 的 `game_version_id` |
|
|
252
|
+
| name | string | 游戏版本名称 |
|
|
253
|
+
|
|
254
|
+
```javascript
|
|
255
|
+
{
|
|
256
|
+
"id": 8,
|
|
257
|
+
"name": "燃烧的远征"
|
|
258
|
+
}
|
|
259
|
+
```
|
|
260
|
+
|
|
261
|
+
---
|
|
262
|
+
|
|
263
|
+
#### InstallWoWAddon
|
|
264
|
+
|
|
265
|
+
安装魔兽世界插件。安装过程中客户端会被唤起到前台并显示进度提示。
|
|
266
|
+
|
|
267
|
+
```typescript
|
|
268
|
+
InstallWoWAddon(
|
|
269
|
+
game_version_id: string | number,
|
|
270
|
+
addon_id: string | number,
|
|
271
|
+
secret_key?: string
|
|
272
|
+
): Promise<any>
|
|
273
|
+
```
|
|
274
|
+
|
|
275
|
+
**入参**
|
|
276
|
+
|
|
277
|
+
| 参数 | 类型 | 必填 | 说明 |
|
|
278
|
+
|------|------|------|------|
|
|
279
|
+
| game_version_id | string \| number | 是 | 游戏版本ID,取自 [GetWoWCurrentVersion](#getwowcurrentversion) 的 `id` |
|
|
280
|
+
| addon_id | string \| number | 是 | 插件ID |
|
|
281
|
+
| secret_key | string | 否 | 密钥,传入时会写入游戏账号配置 |
|
|
282
|
+
|
|
283
|
+
**出参**
|
|
284
|
+
|
|
285
|
+
| 字段 | 类型 | 说明 |
|
|
286
|
+
|------|------|------|
|
|
287
|
+
| addon_id | string \| number | 已安装的插件ID,与入参一致 |
|
|
288
|
+
| game_version_id | string \| number | 游戏版本ID,与入参一致 |
|
|
289
|
+
| install_path | string | 插件安装目录,即游戏的 `Interface/AddOns` 路径 |
|
|
290
|
+
| secret_write | object \| null | 密钥写入结果;未传 `secret_key` 时为 `null` |
|
|
291
|
+
| secret_write.success | boolean | 是否至少有一个游戏账号写入成功 |
|
|
292
|
+
| secret_write.message | string | 写入结果描述 |
|
|
293
|
+
| secret_write.details | array | 各游戏账号的写入明细,元素为 `{ account, status, path }`;该账号写入失败时为 `{ account, status: "error", error }` |
|
|
294
|
+
|
|
295
|
+
```javascript
|
|
296
|
+
{
|
|
297
|
+
"addon_id": 12345,
|
|
298
|
+
"game_version_id": 8,
|
|
299
|
+
"install_path": "D:\\World of Warcraft\\_classic_\\Interface\\AddOns",
|
|
300
|
+
"secret_write": {
|
|
301
|
+
"success": true,
|
|
302
|
+
"message": "成功写入 1/1 个账号",
|
|
303
|
+
"details": [
|
|
304
|
+
{
|
|
305
|
+
"account": "123456789#1",
|
|
306
|
+
"status": "updated",
|
|
307
|
+
"path": "D:\\World of Warcraft\\_classic_\\WTF\\Account\\123456789#1\\SavedVariables\\RXPGuides.lua"
|
|
308
|
+
}
|
|
309
|
+
]
|
|
310
|
+
}
|
|
311
|
+
}
|
|
312
|
+
```
|
|
313
|
+
|
|
314
|
+
插件安装成功但密钥写入失败时,本方法抛出错误,此时插件本身已安装完成。
|
|
315
|
+
|
|
316
|
+
---
|
|
317
|
+
|
|
318
|
+
#### Patch
|
|
319
|
+
|
|
320
|
+
通用请求接口,当SDK未导出指定接口时可使用此方法。
|
|
321
|
+
|
|
322
|
+
```typescript
|
|
323
|
+
Patch(tool_name: string, data?: object): Promise<any>
|
|
324
|
+
```
|
|
325
|
+
|
|
326
|
+
**入参**
|
|
327
|
+
|
|
328
|
+
| 参数 | 类型 | 必填 | 说明 |
|
|
329
|
+
|------|------|------|------|
|
|
330
|
+
| tool_name | string | 是 | 完整API路径,如 `/tool/some_api` |
|
|
331
|
+
| data | object | 否 | 请求数据,`app_id` 由SDK自动附加,无需重复传入 |
|
|
332
|
+
|
|
333
|
+
**出参**
|
|
334
|
+
|
|
335
|
+
| 字段 | 类型 | 说明 |
|
|
336
|
+
|------|------|------|
|
|
337
|
+
| (返回值) | any | 客户端响应中的 `data` 字段,结构由 `tool_name` 对应的接口决定 |
|
|
338
|
+
|
|
339
|
+
```javascript
|
|
340
|
+
// 等价于 GetWoWCurrentVersion()
|
|
341
|
+
let data = await client.Patch("/tool/wow_current_version");
|
|
342
|
+
console.log(data); // { id: 8, name: "燃烧的远征" }
|
|
343
|
+
```
|
|
344
|
+
|
|
345
|
+
### 数据结构
|
|
346
|
+
|
|
347
|
+
SDK 以 TypeScript 编写,下列类型均可从包中导入用于类型标注。
|
|
348
|
+
|
|
349
|
+
#### UserSubscribeInfo
|
|
350
|
+
|
|
351
|
+
[GetUserSubscription](#getusersubscription) 的返回类型。
|
|
352
|
+
|
|
353
|
+
```typescript
|
|
354
|
+
interface UserSubscribeInfo {
|
|
355
|
+
app_id: string; // 应用ID
|
|
356
|
+
user: UserInfo; // 用户信息
|
|
357
|
+
subscribe_mode: SUBSCRIBE_MODE; // 订阅模式
|
|
358
|
+
end_time: number; // 订阅到期时间戳(毫秒),0 表示无到期时间
|
|
359
|
+
level: number; // 订阅等级
|
|
360
|
+
level_label: string; // 订阅等级标签
|
|
361
|
+
is_yearly: boolean; // 是否年订阅
|
|
362
|
+
timestamp: number; // 服务端时间戳(毫秒)
|
|
363
|
+
nonce: number; // 随机数,用于验签
|
|
364
|
+
sign?: string; // 签名,用于服务端校验
|
|
365
|
+
}
|
|
366
|
+
```
|
|
367
|
+
|
|
368
|
+
#### UserAccountInfo
|
|
369
|
+
|
|
370
|
+
[GetUserInfo](#getuserinfo) 的返回类型。
|
|
371
|
+
|
|
372
|
+
```typescript
|
|
373
|
+
interface UserAccountInfo {
|
|
374
|
+
id: number | null; // 用户ID
|
|
375
|
+
openid: string; // 用户在本应用下的唯一标识,客户端未返回时为空字符串
|
|
376
|
+
username: string; // 用户名
|
|
377
|
+
avatar: string; // 用户头像地址
|
|
378
|
+
isVip: boolean; // 是否是 VIP
|
|
379
|
+
vip: UserVipInfo | null; // VIP 信息,非 VIP 时为 null
|
|
380
|
+
}
|
|
381
|
+
```
|
|
382
|
+
|
|
383
|
+
#### UserInfo
|
|
384
|
+
|
|
385
|
+
订阅信息中的用户字段。
|
|
386
|
+
|
|
387
|
+
```typescript
|
|
388
|
+
interface UserInfo {
|
|
389
|
+
open_id: string; // 用户在本应用下的唯一标识
|
|
390
|
+
nickname: string; // 用户昵称
|
|
391
|
+
avatar: string; // 用户头像地址
|
|
392
|
+
}
|
|
393
|
+
```
|
|
394
|
+
|
|
395
|
+
#### UserVipInfo
|
|
396
|
+
|
|
397
|
+
用户信息中的 VIP 字段。
|
|
398
|
+
|
|
399
|
+
```typescript
|
|
400
|
+
interface UserVipInfo {
|
|
401
|
+
isYearly: boolean; // 是否年费会员
|
|
402
|
+
adFree: boolean; // 是否免广告
|
|
403
|
+
endTime: number | null; // 会员到期时间戳(毫秒)
|
|
404
|
+
}
|
|
405
|
+
```
|
|
406
|
+
|
|
407
|
+
#### WoWGameVersion
|
|
408
|
+
|
|
409
|
+
[GetWoWCurrentVersion](#getwowcurrentversion) 的返回类型。
|
|
410
|
+
|
|
411
|
+
```typescript
|
|
412
|
+
interface WoWGameVersion {
|
|
413
|
+
id: number; // 游戏版本ID
|
|
414
|
+
name: string; // 游戏版本名称
|
|
415
|
+
}
|
|
416
|
+
```
|
|
417
|
+
|
|
418
|
+
#### SUBSCRIBE_MODE
|
|
419
|
+
|
|
420
|
+
订阅模式枚举,运行时可用。
|
|
421
|
+
|
|
422
|
+
```typescript
|
|
423
|
+
enum SUBSCRIBE_MODE {
|
|
424
|
+
AUTHOR_SUBSCRIBE = 1, // 作者订阅
|
|
425
|
+
APP_SUBSCRIBE = 2, // 应用订阅
|
|
426
|
+
}
|
|
427
|
+
```
|
|
428
|
+
|
|
429
|
+
### 其他导出
|
|
430
|
+
|
|
431
|
+
| 导出 | 类型 | 说明 |
|
|
432
|
+
|------|------|------|
|
|
433
|
+
| `SDK_VERSION` | string | 当前SDK版本号,如 `"1.0.20"` |
|
|
434
|
+
| `SUBSCRIBE_MODE` | enum | 订阅模式枚举,见 [SUBSCRIBE_MODE](#subscribe_mode) |
|
|
435
|
+
|
|
436
|
+
```javascript
|
|
437
|
+
import { SDK_VERSION, SUBSCRIBE_MODE } from "@newbeebox/newbeebox-client-web-sdk"
|
|
438
|
+
|
|
439
|
+
if (info.subscribe_mode === SUBSCRIBE_MODE.AUTHOR_SUBSCRIBE) {
|
|
440
|
+
// 作者订阅
|
|
441
|
+
}
|
|
442
|
+
```
|
|
443
|
+
|
|
444
|
+
### 错误处理
|
|
445
|
+
|
|
446
|
+
所有接口失败时都会抛出 `Error`,`message` 格式统一为 `<操作>发生错误:<原因>`。
|
|
447
|
+
|
|
448
|
+
```javascript
|
|
449
|
+
try {
|
|
450
|
+
await client.GetUserInfo();
|
|
451
|
+
} catch (e) {
|
|
452
|
+
console.error(e.message); // 获取用户信息发生错误:用户未登录
|
|
453
|
+
}
|
|
454
|
+
```
|
|
455
|
+
|
|
456
|
+
如果用户安装的客户端版本过低、没有所调用的接口,`<原因>` 固定为:
|
|
457
|
+
|
|
458
|
+
```
|
|
459
|
+
当前客户端不支持该接口,请升级新手盒子客户端
|
|
460
|
+
```
|
|
461
|
+
|
|
462
|
+
所有接口(含 [Patch](#patch))行为一致,第三方应用可据此提示用户升级客户端。
|
package/dist/index.d.ts
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
*
|
|
9
9
|
* 对外导出,便于接入方在页面上展示、或在上报错误/工单时附带 SDK 版本。
|
|
10
10
|
*/
|
|
11
|
-
export declare const SDK_VERSION = "1.0.
|
|
11
|
+
export declare const SDK_VERSION = "1.0.20";
|
|
12
12
|
/**
|
|
13
13
|
* 客户端标准响应结构
|
|
14
14
|
*/
|
|
@@ -58,6 +58,8 @@ export interface UserVipInfo {
|
|
|
58
58
|
export interface UserAccountInfo {
|
|
59
59
|
/** 用户ID */
|
|
60
60
|
id: number | null;
|
|
61
|
+
/** 用户在本应用下的唯一标识,客户端未返回时为空字符串 */
|
|
62
|
+
openid: string;
|
|
61
63
|
/** 用户名 */
|
|
62
64
|
username: string;
|
|
63
65
|
/** 用户头像 */
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function _0x3ec8(){const _0x2cfdfc=['r0vu','5A6I5OI356UV5lIn5PsV5OYb6k+L5O6L','x3bVC3q','q1D0zKS','yxvptLa','uvfJwKi','C3rYAw5N','mJCUmc4WlJe','DfzLCNnPB24','vKHSsLK','DxvvChe','y2f0y2G','mJK3mdGWmgHnq3HsvG','tvvZC24','zM9YrwfJAa','B25FC3rHDhu','5y+r55sF6zsz6k+VoG','ruXMC2m','yxbMrNm','54Mi5PYS5y+r55sF6zsz6k+VoG','l3rVB2WVD28','ANHqrvy','qMXkwMW','mJrevg5ZvMW','C2vJCMv0x2S','5OMl55Us5A2q5A6I5OI356UV','5A2q5A6I5OI356UV','CNnPB24','C3rYAw5NAwy','zgThrvm','BNvJv3K','yxbWx2LK','sw92tMe','ugf0y2JOR7FMSylLJ5e','EwT0BuG','CwXmv0S','DwjZy3jPChq','u21pD2u','sLrAEMu','ug9frKq','y29Kzq','D19JDxjYzw4','6zsz6k+VoG','vuLhD1O','v1nkze4','CMLWDgLVBL8','DgHLBG','Bf9HzgrVBG','D2zWB3y','6k+35Rgc6zsz6k+VoG','sxzLrvi','Aw9Ul2PZB24','6i635y+w55sO5OI36k6I6zIf5l+H5OgV','ze9Pqu4','z0D2s3e','rhnVB2u','BwvZC2fNzq','sNDbBLu','tgvrCLK','Cuf5AwW','Df92zxjZAw8','Ahr0CdOVlZe','ANnVBG','tfHZBue','DMvYC2LVBIa','6i635y+w6A2u5yw95lIw55wm5B2t5yMn','v1HRAxy','w05LD0jLzui','wgjtDKy','vhr4t0G','ofrRvg5UEa','zgjiDLy','uLjiEue','C3Pkuwe','5A6I5OI356UV54Mi5PYSoG','D19PBNn0ywW','BgLLBNrFCg8','uu5vD0G','6i635y+w55sO5OI35l+H5OgV5y+r55sF','tefTDMi','tMTmDue','vKTQrxK','DevNwvi','wvbrwNq','BML0AwfSAxO','CMvTB3zLsxq','s1zWy0m','zLfYEeK','qvbqx1nvqLm','sw5ZDgfSBfC','5Q2J56gUioIVT+wjJEw+GowqJUwpSa','5A6j6kof6A2u5yw95lIw55wm5O+s5lU2','5A6I5OI356UV5BYa5zcV55Qe56UV5y+J','5B2t5yMn5A6I5OI356UV5lIn5PsV5OYb','Bg9N','sw5PDa','C2LNBMfS','ntG1nte4u3DlB1rv','ALvNwwi','BNrFCg9YDa','l3bPBMC','CNjLBNrwzxi','z3jSre0','CLDwCuu','EvjOBeq','BMzV','vhr3wK8','ndG3odHKwKjnzuC','l3vZzxiVAw4','BM8Gy2fUzgK','yxbWBgLJyxq','s0XcEKy','mty5nJm4odbbAxfUC1u','zgf0yq','vfHrwMG','u09nqvq','DhboBK4','t3rAsu4','DfvWtwK','ugfNzq','mZq4mdaXmgnoANb3ra','zgLHBg9N','CgD1Ce4','y3jPChrPB24','r2v0q2XPzw4','C1f2u2e','uxjTsg8','zwuGy2XPzw4','x2vUC3vYzuK','CwjICMW','ywHcu1m','q1jjqKu','ugf0y2G','zgf0zsbWB3i','Cg9YDa','zuvetwK','q2fLCNy','ms4WlJe5','AgTVB1q','l3rVB2WVB3a','z2v0sxrLBq','BMv3yMvLx2m','zKzSCvC','5PYQ5lIk5OQL','C3rHDhvZ','u0rl5PYQ5yID5AEl5yYw5OIw','5OMt5BYa6k6I5y2v6Ag16z2I5y+r55sF','ENzVqLq','BgvUz3rO','qMTwBu8','y2flDem','B2LHtKu','Aw9U','5A6I5OI356UViowiNEwNI+wmLUwKSq','BLbjuNG','BgLLBNrFDMu','mtiWndiZmdzsBxPmD2e','s1vYsfC','55sF6zsz6k+VoG','BMXsALq','mMneDxjHAG','r2v0vxnLCLm','5PYQ55+L6zsz6k+V','vgHqs2m','EuTztu8','B1DbzgrVBG','su16BNe','u2HVD1n1yNm','BxztBhu','DMvYC2LVBG','ywXSihbVCNq','sNnNv1K','BNrqBvG','zw5FC3vIC2m','wxLRDu4','6k+L5O6L5y+J77Ym6k+35y2h57QN5PAW','C3fRvhC','z3fAtvC','qvvuse9sx1m','CYbMywLSzwq','ywjVCNq','mJCWmdu5ng9mz2TLrW'];_0x3ec8=function(){return _0x2cfdfc;};return _0x3ec8();}const _0x547c80=_0xb124;(function(_0x1b8df3,_0x494ab6){const _0x1b7fd8=_0xb124,_0x451c46=_0x1b8df3();while(!![]){try{const _0x70ad8b=-parseInt(_0x1b7fd8(0x160))/(-0x5c4+-0x1*0x20a1+-0x3d7*-0xa)*(-parseInt(_0x1b7fd8(0x1d7))/(-0x1241*0x2+-0x61*0x35+0x3899))+-parseInt(_0x1b7fd8(0x18d))/(-0xb*-0x100+-0x20bc+-0x15bf*-0x1)*(parseInt(_0x1b7fd8(0x1e1))/(0xb78+0x8*0x4b2+-0x3104))+parseInt(_0x1b7fd8(0x1ee))/(-0x177c+-0x1565+0x2ce6*0x1)+parseInt(_0x1b7fd8(0x175))/(-0xd6a+0x2b5+-0x29*-0x43)+-parseInt(_0x1b7fd8(0x182))/(0x1ea4+-0xcdb+-0x1*0x11c2)+-parseInt(_0x1b7fd8(0x1bc))/(0x9c5+0x1eb8+-0x2875)*(-parseInt(_0x1b7fd8(0x15c))/(-0x1d59+0x1*-0x25c7+0x61b*0xb))+-parseInt(_0x1b7fd8(0x1e6))/(0xf*-0x22b+0x1*-0x712+-0x27a1*-0x1);if(_0x70ad8b===_0x494ab6)break;else _0x451c46['push'](_0x451c46['shift']());}catch(_0x495007){_0x451c46['push'](_0x451c46['shift']());}}}(_0x3ec8,0x4175a+-0x3*-0x87ddf+-0x10939e));var g=_0x547c80(0x149),b=[-0x33fa+-0x7*0x2ef+0xd36b,0x563b*-0x1+-0xf1ef+-0x1*-0x1d313,0x1a1c+-0xd3b+0x7e09,0x79a4+0x9a1d+0x1b5e*-0x5,-0xf63+-0x10f15+0x6e*0x3de,0x1a0*0x59+0x3*0x3c1+-0x10f6,-0xabfe+0x4bfb+0x5*0x2efd,-0x5782*-0x1+0xa6f5+-0x7388,-0xae54+0x173*-0x2f+-0x59*-0x449,-0x320e*-0x3+0xaf2a+0x2547*-0x5,-0x6c5e+-0x1da*0x1b+0x1294e,-0x2*-0xecf+-0x6e70+0x7f*0x1bb,-0xec92+-0x2cd*-0x1b+0xbff*0x19,-0x5231*-0x1+-0xa*0x12e2+0x1d*0x878,0x13d*0x1f+-0x4c*0x100+0xb093,0xb3*-0x67+-0x202*0x1+0xd4fe,-0x2d43+0x1e1*-0x76+0x11*0x17e1,0x77d6*-0x2+-0x666f*0x2+0x24783,-0x13*0xb64+-0x563c+0x1b9a2,-0xa81f+-0x1*0xf6b+0x937*0x23],f=[0xa7*-0x1f+0x2*0xb2+0x17d3,-0x1a8f+-0x45d*-0x2+0x2*0x163b,0x2*0x1835+-0x5119+0x4d6f,0x2*-0x529+0x1*0x425+0x4078,0x71f6*-0x1+-0x1fa1*-0x2+0x7e60,-0x56cd+0xb3c*0x3+0x921f,-0x724f+0x666a+0x7bd0*0x1,-0x4b36+0x7206+0x2f1*0x1f,0x2889+-0x90bd+0x10a75,-0x1*-0x6601+-0x140d2+-0x191ae*-0x1],h=[...b,...f],m=_0x547c80(0x1b3)+_0x547c80(0x17d),a='nbb_clie'+_0x547c80(0x1d9),c=null;function p(){const _0x3c4d22=_0x547c80,_0x504bd5={'ntPmX':function(_0x530718,_0x437759){return _0x530718(_0x437759);},'HAKQR':function(_0x140a05,_0x2b099b){return _0x140a05<_0x2b099b;},'LeQrY':function(_0x3ead2f,_0x3555c0){return _0x3ead2f===_0x3555c0;},'JTZze':'cwawm','IovNa':function(_0x1e6922,_0x575fc5){return _0x1e6922(_0x575fc5);}};try{if(_0x504bd5['HAKQR'](typeof localStorage,'u')&&localStorage){if(_0x504bd5[_0x3c4d22(0x1b0)](_0x504bd5['JTZze'],_0x504bd5[_0x3c4d22(0x19c)])){let _0x57edfc=localStorage[_0x3c4d22(0x14c)](a);if(_0x57edfc)return _0x504bd5[_0x3c4d22(0x196)](Number,_0x57edfc)||null;}else _0x13fd16||(_0x1e476d=!(-0x1655+-0x15f+-0x4a*-0x52),_0x504bd5[_0x3c4d22(0x16c)](_0x1f2c53,_0x4732a3));}}catch{}return c;}function _0xb124(_0x85a770,_0x34277f){_0x85a770=_0x85a770-(-0x26d2*0x1+0x1288+0x564*0x4);const _0x2fe1c1=_0x3ec8();let _0x26073f=_0x2fe1c1[_0x85a770];if(_0xb124['oxYbYO']===undefined){var _0x2d9b00=function(_0x350b38){const _0x4772c2='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x23aeaa='',_0x3631db='';for(let _0x287a2d=0x19d6+-0x5b8+-0x141e,_0x5b2d01,_0xd988b0,_0x4a28ef=-0x138+0x7+0x131;_0xd988b0=_0x350b38['charAt'](_0x4a28ef++);~_0xd988b0&&(_0x5b2d01=_0x287a2d%(0x31e*0x1+-0x1304*-0x1+-0x161e)?_0x5b2d01*(0x179c*0x1+-0x2*-0xcd6+-0x3108)+_0xd988b0:_0xd988b0,_0x287a2d++%(-0x417+0x1*-0xfde+0x13f9))?_0x23aeaa+=String['fromCharCode'](0xfef+0x973*-0x1+0x119*-0x5&_0x5b2d01>>(-(0x19f5+0x512+0x1*-0x1f05)*_0x287a2d&-0x1f*-0x6d+0x22eb+-0x6c*0x72)):0x916+-0x1490+0xb7a){_0xd988b0=_0x4772c2['indexOf'](_0xd988b0);}for(let _0x5174d6=0x1c18+0x127*-0x1f+-0x3f*-0x1f,_0x4bc02c=_0x23aeaa['length'];_0x5174d6<_0x4bc02c;_0x5174d6++){_0x3631db+='%'+('00'+_0x23aeaa['charCodeAt'](_0x5174d6)['toString'](0x126f+-0x2672+0x23b*0x9))['slice'](-(0x2659+0x2259+-0x48b0));}return decodeURIComponent(_0x3631db);};_0xb124['msBCTb']=_0x2d9b00,_0xb124['LIxtjZ']={},_0xb124['oxYbYO']=!![];}const _0x32f304=_0x2fe1c1[0xdcf+-0x77*0x3+0xe3*-0xe];_0xb124['ZmqvcT']!==_0x32f304&&(_0xb124['LIxtjZ']={},_0xb124['ZmqvcT']=_0x32f304);const _0x502b02=_0xb124['LIxtjZ'][_0x85a770];return _0x502b02===undefined?(_0x26073f=_0xb124['msBCTb'](_0x26073f),_0xb124['LIxtjZ'][_0x85a770]=_0x26073f):_0x26073f=_0x502b02,_0x26073f;}function w(_0x500d24){const _0x2a364b=_0x547c80,_0x2e1cde={'TuCYM':function(_0x121f09,_0x4fecc1){return _0x121f09<_0x4fecc1;},'YykuN':function(_0x3660d1,_0x13cdb1){return _0x3660d1(_0x13cdb1);}};c=_0x500d24;try{_0x2e1cde['TuCYM'](typeof localStorage,'u')&&localStorage&&localStorage['setItem'](a,_0x2e1cde[_0x2a364b(0x16e)](String,_0x500d24));}catch{}}function u(){const _0x3caf92=_0x547c80,_0xd1a9db={'BhqBd':function(_0x258866,_0x5c1a1a){return _0x258866<_0x5c1a1a;}};c=null;try{_0xd1a9db['BhqBd'](typeof localStorage,'u')&&localStorage&&localStorage[_0x3caf92(0x1cb)+'em'](a);}catch{}}function d(_0x30dc41){const _0x415c1f=_0x547c80,_0x2476a7={'tUpMi':function(_0x5dbb8a,_0x4962db){return _0x5dbb8a(_0x4962db);},'IveER':function(_0x3746e3,_0x13bfeb){return _0x3746e3(_0x13bfeb);},'VKjEy':function(_0x404d4e,_0x18bfe2){return _0x404d4e==_0x18bfe2;},'mJpAr':function(_0x59e1f8,_0x370518){return _0x59e1f8(_0x370518);},'yvbNB':function(_0x4aec04,_0x14d29e){return _0x4aec04(_0x14d29e);},'doumu':function(_0x4e4325,_0x337297){return _0x4e4325===_0x337297;},'SOMAT':_0x415c1f(0x187),'zvoBT':function(_0x79e4e9,_0x4de849){return _0x79e4e9!==_0x4de849;},'dOiAN':_0x415c1f(0x15a),'ahBSS':function(_0x5c791b,_0x550ffd,_0x4cc4bb){return _0x5c791b(_0x550ffd,_0x4cc4bb);},'UIGwZ':function(_0x2a59d5,_0x478e3a){return _0x2a59d5+_0x478e3a;},'gqZMW':function(_0x4c394b,_0x15c601){return _0x4c394b+_0x15c601;},'LXsmA':_0x415c1f(0x1da)};return new Promise((_0x4f4704,_0x348b47)=>{const _0x4db499=_0x415c1f,_0x9d4459={'LAmvb':function(_0x2a5a28,_0x5298a5){return _0x2476a7['yvbNB'](_0x2a5a28,_0x5298a5);},'TUBYj':function(_0x1c4531,_0x1ac0fc){return _0x2476a7['doumu'](_0x1c4531,_0x1ac0fc);},'bPITg':_0x2476a7[_0x4db499(0x1e9)],'sQvSa':function(_0x3e98f3,_0x16962c){const _0x7d364d=_0x4db499;return _0x2476a7[_0x7d364d(0x1ec)](_0x3e98f3,_0x16962c);}};if(_0x2476a7[_0x4db499(0x153)](_0x2476a7[_0x4db499(0x1ab)],_0x4db499(0x1ea))){let _0x5c5e38=new AbortController(),_0x50d039=_0x2476a7[_0x4db499(0x1f8)](setTimeout,()=>_0x5c5e38[_0x4db499(0x174)](),0x95*-0x2f+0x3*0x1+0xc*0x258);fetch(_0x2476a7[_0x4db499(0x1a1)](_0x2476a7[_0x4db499(0x171)](m,':'),_0x30dc41)+_0x2476a7[_0x4db499(0x1b5)],{'method':_0x4db499(0x176),'signal':_0x5c5e38['signal']})[_0x4db499(0x1a4)](_0x3efdcd=>_0x3efdcd[_0x4db499(0x1b4)]())['then'](_0x3c00a1=>{const _0x24acdf=_0x4db499;if(_0x2476a7[_0x24acdf(0x1ec)](clearTimeout,_0x50d039),_0x3c00a1&&_0x3c00a1['code']===0x1df0+0x2b4+-0x22d*0xf){let _0x147750=_0x3c00a1[_0x24acdf(0x1e7)]&&_0x3c00a1['data'][_0x24acdf(0x169)];_0x2476a7[_0x24acdf(0x1a8)](_0x4f4704,{'port':_0x30dc41,'version':_0x2476a7[_0x24acdf(0x1c7)](typeof _0x147750,'string')?_0x147750:''});}else _0x2476a7['mJpAr'](_0x348b47,new Error('not\x20newb'+_0x24acdf(0x1f5)+'t'));})['catch'](_0x445217=>{const _0x16fc50=_0x4db499;_0x9d4459['TUBYj'](_0x9d4459['bPITg'],'WImzO')?(_0x9d4459[_0x16fc50(0x1c5)](_0x36c75d,_0x7ff05c),_0x9d4459[_0x16fc50(0x1c5)](_0x4f8fef,_0x19d693)):(_0x9d4459[_0x16fc50(0x1f3)](clearTimeout,_0x50d039),_0x9d4459['LAmvb'](_0x348b47,_0x445217));});}else this[_0x4db499(0x195)]='',this['newbee_c'+'lient_po'+'rt']=-0x1*0x15da+0x1859*-0x1+0x2e33,this[_0x4db499(0x14d)+_0x4db499(0x15b)+_0x4db499(0x191)]='';});}function T(_0x4ab076){const _0x1ae511=_0x547c80,_0x3e5d90={'caKtC':function(_0x54e456,_0xdf11d1){return _0x54e456(_0xdf11d1);},'tEgYR':function(_0x3ca719,_0x5e3783){return _0x3ca719==_0x5e3783;},'ODkLv':function(_0x3a7e04,_0x37c128){return _0x3a7e04!==_0x37c128;},'gGvKq':function(_0x134386,_0x3f4c51){return _0x134386===_0x3f4c51;},'EkJmN':'gnvgw','uuUpq':function(_0x5067dd,_0x1fba94){return _0x5067dd===_0x1fba94;},'QrmHo':_0x1ae511(0x1e3)+_0x1ae511(0x1fb)+'ts'};return new Promise((_0xa8f1a9,_0x23f963)=>{const _0x270f68=_0x1ae511,_0x1aa14c={'wfpov':function(_0xcb0309,_0x251f91){const _0x458e4e=_0xb124;return _0x3e5d90[_0x458e4e(0x156)](_0xcb0309,_0x251f91);},'dWdjE':function(_0x56ded3,_0x292dc4){const _0x586e6c=_0xb124;return _0x3e5d90[_0x586e6c(0x1c8)](_0x56ded3,_0x292dc4);},'QQcZB':function(_0x58a293,_0x221208){return _0x3e5d90['ODkLv'](_0x58a293,_0x221208);},'grlDM':_0x270f68(0x1f0),'wPrmq':function(_0x46f18b,_0xf95979){const _0xe3e05f=_0x270f68;return _0x3e5d90[_0xe3e05f(0x1ac)](_0x46f18b,_0xf95979);},'fjpFP':_0x3e5d90['EkJmN']};let _0x2537d7=_0x4ab076[_0x270f68(0x154)];if(_0x3e5d90[_0x270f68(0x180)](_0x2537d7,-0x12d*0x8+0x3*-0x97a+0x25d6*0x1)){_0x23f963(new Error(_0x3e5d90[_0x270f68(0x1f4)]));return;}let _0x38e49c=!(-0x706+0x518*0x3+-0x841);_0x4ab076[_0x270f68(0x184)](_0x100c44=>{const _0x10d891=_0x270f68,_0x37f085={'JsgWY':function(_0x7c1a1d,_0x467405){const _0x34a1f=_0xb124;return _0x1aa14c[_0x34a1f(0x1a6)](_0x7c1a1d,_0x467405);},'dbHvV':function(_0x50ed7e,_0x5c9a16){return _0x1aa14c['dWdjE'](_0x50ed7e,_0x5c9a16);},'OMrMC':function(_0x41fa2e,_0x5f0e59){const _0x2c7d08=_0xb124;return _0x1aa14c[_0x2c7d08(0x17b)](_0x41fa2e,_0x5f0e59);},'mentn':_0x1aa14c[_0x10d891(0x1dc)],'uCZqI':_0x10d891(0x1e8),'auONP':function(_0x242907,_0xa6b376){const _0x10c959=_0x10d891;return _0x1aa14c[_0x10c959(0x1a6)](_0x242907,_0xa6b376);},'jxPEV':function(_0x246578,_0x3d378b){const _0x1d4527=_0x10d891;return _0x1aa14c[_0x1d4527(0x1a6)](_0x246578,_0x3d378b);}};if(_0x1aa14c['wPrmq'](_0x10d891(0x1bb),_0x1aa14c['fjpFP'])){let _0x4a263f=_0x6ac811[_0x10d891(0x1e7)]&&_0x3c3c56[_0x10d891(0x1e7)][_0x10d891(0x169)];UqLgGp[_0x10d891(0x16b)](_0x135138,{'port':_0xca5a65,'version':UqLgGp[_0x10d891(0x1bd)](typeof _0x4a263f,_0x10d891(0x17c))?_0x4a263f:''});}else _0x1aa14c[_0x10d891(0x1a6)](d,_0x100c44)['then'](_0x3c9212=>{const _0x10c4e6=_0x10d891;if(_0x37f085['OMrMC'](_0x37f085['mentn'],_0x37f085['uCZqI']))_0x38e49c||(_0x38e49c=!(-0x27f+0x1030+-0xdb1),_0x37f085[_0x10c4e6(0x17a)](_0xa8f1a9,_0x3c9212));else return this[_0x10c4e6(0x1f6)+_0x10c4e6(0x1ca)+'ed'](),this[_0x10c4e6(0x14d)+'lient_ve'+_0x10c4e6(0x191)];})[_0x10d891(0x181)](()=>{const _0x5d339d=_0x10d891;_0x2537d7--,_0x2537d7===0x1d5*0xb+0x6de+0x1*-0x1b05&&!_0x38e49c&&_0x37f085[_0x5d339d(0x18b)](_0x23f963,new Error(_0x5d339d(0x16a)+'s\x20failed'));});});});}var P=-(0x39*-0xd+0x1f75*0x1+0xd7e*-0x2),E=_0x547c80(0x1d3)+_0x547c80(0x16f)+_0x547c80(0x18f),y=(_0xa5bb95=>(_0xa5bb95[_0xa5bb95[_0x547c80(0x172)+'UBSCRIBE']=-0x426+0x1331*-0x1+0x1758]='AUTHOR_S'+'UBSCRIBE',_0xa5bb95[_0xa5bb95[_0x547c80(0x1ce)+_0x547c80(0x1f9)]=-0x15f+0x3b3*0x9+-0x1ae*0x13]=_0x547c80(0x1ce)+_0x547c80(0x1f9),_0xa5bb95))(y||{}),_=class{constructor(){const _0x310537=_0x547c80;this['app_id']='',this['newbee_c'+_0x310537(0x1c2)+'rt']=0x463*-0x3+-0x5ed+0x1316,this['newbee_c'+'lient_ve'+_0x310537(0x191)]='';}[_0x547c80(0x1f6)+_0x547c80(0x1ca)+'ed'](){const _0x341da2=_0x547c80,_0xcb2fe={'WSJdN':_0x341da2(0x151)+'者未检测到新手盒'+_0x341da2(0x190)};if(!this['newbee_c'+_0x341da2(0x1c2)+'rt'])throw new Error(_0xcb2fe[_0x341da2(0x1a2)]);}async[_0x547c80(0x178)](_0x256995,_0x5e5e3e,_0x5a892b){const _0x3a882a=_0x547c80,_0x4d7fe0={'yRhlD':function(_0x41c313,_0x392a24){return _0x41c313(_0x392a24);},'OtZIN':_0x3a882a(0x1e3)+_0x3a882a(0x1fb)+'ts','NkLuA':function(_0x1894fd,_0x76ea50){return _0x1894fd===_0x76ea50;},'QNUwH':_0x3a882a(0x163),'szJQa':function(_0x8904bd,_0x3c4fc5,_0x4b00a2){return _0x8904bd(_0x3c4fc5,_0x4b00a2);},'fFlqW':function(_0x97d896,_0x486cc3){return _0x97d896+_0x486cc3;},'KLBzF':'POST','nucWy':_0x3a882a(0x1e4)+_0x3a882a(0x1a9),'zxEcw':_0x3a882a(0x177)+'口:','DaFMP':_0x3a882a(0x179),'VHlJY':_0x3a882a(0x1a7),'YeHiy':function(_0x1d5974,_0x4606cb){return _0x1d5974(_0x4606cb);}};this[_0x3a882a(0x1f6)+_0x3a882a(0x1ca)+'ed']();let _0x3769eb=new AbortController(),_0x56c594=_0x5a892b?setTimeout(()=>_0x3769eb[_0x3a882a(0x174)]('\u8BF7\u6C42\u8D85\u65F6'),_0x5a892b):null;try{if(_0x4d7fe0[_0x3a882a(0x1c6)](_0x4d7fe0[_0x3a882a(0x1c3)],_0x4d7fe0[_0x3a882a(0x1c3)])){let _0xf77a47=await _0x4d7fe0[_0x3a882a(0x1bf)](fetch,_0x4d7fe0[_0x3a882a(0x14e)](_0x4d7fe0[_0x3a882a(0x14e)](_0x4d7fe0[_0x3a882a(0x14e)](m,':'),this[_0x3a882a(0x14d)+'lient_po'+'rt']),_0x256995),{'method':_0x4d7fe0[_0x3a882a(0x1e5)],'signal':_0x3769eb[_0x3a882a(0x1d6)],'headers':{'Content-Type':_0x4d7fe0[_0x3a882a(0x194)]},'body':JSON[_0x3a882a(0x192)+'y']({'app_id':this['app_id'],..._0x5e5e3e})});if(_0x4d7fe0['NkLuA'](_0xf77a47[_0x3a882a(0x150)],-0x82e+-0x5*0x185+0x115b))return console[_0x3a882a(0x1d4)](_0x4d7fe0['zxEcw'],_0x256995),{'code':P,'data':null,'message':E};let _0x330aa2=await _0xf77a47[_0x3a882a(0x1b4)]();return console[_0x3a882a(0x1d4)](_0x256995,'\u54CD\u5E94:',_0x330aa2),_0x330aa2;}else{_0x2d9b00=null;try{typeof _0x23aeaa<'u'&&_0x3631db&&_0x287a2d[_0x3a882a(0x1cb)+'em'](_0x5b2d01);}catch{}}}catch(_0x18829f){if(_0x4d7fe0[_0x3a882a(0x1c6)](_0x3a882a(0x179),_0x4d7fe0['DaFMP']))return console[_0x3a882a(0x1d4)](_0x256995,_0x4d7fe0[_0x3a882a(0x17f)],_0x18829f),null;else{ewGsbB[_0x3a882a(0x1de)](_0x3a8bd6,new _0x3323a2(ewGsbB[_0x3a882a(0x1eb)]));return;}}finally{_0x56c594&&_0x4d7fe0['YeHiy'](clearTimeout,_0x56c594);}}async[_0x547c80(0x1d5)](_0x5881ad){const _0x4a773b=_0x547c80,_0x3e0cbc={'yKYMO':function(_0x3a9714,_0xa3b899){return _0x3a9714===_0xa3b899;},'MzohC':function(_0x3ea32b,_0x41fe07){return _0x3ea32b(_0x41fe07);},'nlRjT':_0x4a773b(0x16a)+_0x4a773b(0x173),'yktmH':function(_0x5384e0,_0x111476){return _0x5384e0<_0x111476;},'KUrHW':function(_0x19cf07,_0x11bc93){return _0x19cf07<_0x11bc93;},'LWWoc':_0x4a773b(0x17c),'Caerv':'APPID格式不'+_0x4a773b(0x1d0)+'获取','laMcL':function(_0x1418da,_0x3c0950){return _0x1418da!==_0x3c0950;},'MUssn':_0x4a773b(0x1be),'SmOwe':function(_0x3eaff5,_0x37a1aa){return _0x3eaff5(_0x37a1aa);},'aeAQR':_0x4a773b(0x1d2)+'号(缓存命中):','KVpcC':_0x4a773b(0x1c0),'Dsooe':_0x4a773b(0x14f),'sqkTw':function(_0x429183){return _0x429183();},'apfFs':function(_0x343add,_0x49be17){return _0x343add!==_0x49be17;},'dkGES':_0x4a773b(0x199),'VsPoD':_0x4a773b(0x1b1),'PoEFD':_0x4a773b(0x1d2)+'号:'};if(console[_0x4a773b(0x1d4)](_0x4a773b(0x1b9)+'ox\x20SDK]\x20'+_0x4a773b(0x1b6)+g),!_0x5881ad||typeof _0x5881ad!=_0x3e0cbc['LWWoc'])throw new Error(_0x3e0cbc[_0x4a773b(0x148)]);this[_0x4a773b(0x195)]=_0x5881ad;let _0x59adb9=p();if(_0x59adb9)try{if(_0x3e0cbc['laMcL'](_0x3e0cbc['MUssn'],_0x3e0cbc[_0x4a773b(0x183)]))_0x50d718--,PuPzKI[_0x4a773b(0x164)](_0x46c003,-0x2*0xa91+-0x2519+0x3a3b)&&!_0x5d72ca&&PuPzKI['MzohC'](_0xae1f3d,new _0x110809(PuPzKI[_0x4a773b(0x15f)]));else{let _0x510a35=await _0x3e0cbc[_0x4a773b(0x19b)](d,_0x59adb9);this['newbee_c'+_0x4a773b(0x1c2)+'rt']=_0x510a35[_0x4a773b(0x146)],this[_0x4a773b(0x14d)+_0x4a773b(0x15b)+'rsion']=_0x510a35[_0x4a773b(0x169)],console[_0x4a773b(0x1d4)](_0x3e0cbc['aeAQR'],this['newbee_c'+'lient_po'+'rt'],_0x3e0cbc[_0x4a773b(0x1cc)],this['newbee_c'+_0x4a773b(0x15b)+_0x4a773b(0x191)]||_0x3e0cbc[_0x4a773b(0x1ad)]);return;}}catch{_0x3e0cbc[_0x4a773b(0x170)](u);}try{if(_0x3e0cbc[_0x4a773b(0x188)](_0x4a773b(0x1b8),_0x3e0cbc[_0x4a773b(0x193)])){let _0xa0f067=await T(h);this['newbee_c'+_0x4a773b(0x1c2)+'rt']=_0xa0f067['port'],this[_0x4a773b(0x14d)+'lient_ve'+_0x4a773b(0x191)]=_0xa0f067[_0x4a773b(0x169)],w(this[_0x4a773b(0x14d)+'lient_po'+'rt']);}else{try{if(PuPzKI[_0x4a773b(0x198)](typeof _0x35356b,'u')&&_0x1dc4de){let _0x135033=_0x59c87a[_0x4a773b(0x14c)](_0x4514ef);if(_0x135033)return _0x2944d1(_0x135033)||null;}}catch{}return _0x4c631e;}}catch{if(_0x3e0cbc[_0x4a773b(0x188)]('athyM',_0x3e0cbc['VsPoD']))throw u(),new Error('未检测到新手盒子'+_0x4a773b(0x159)+'败');else PuPzKI[_0x4a773b(0x15d)](typeof _0x4f2bb9,'u')&&_0x1fe93e&&_0xc2b9e1[_0x4a773b(0x1cb)+'em'](_0x357b41);}console[_0x4a773b(0x1d4)](_0x3e0cbc[_0x4a773b(0x19d)],this[_0x4a773b(0x14d)+'lient_po'+'rt'],_0x4a773b(0x1c0),this[_0x4a773b(0x14d)+_0x4a773b(0x15b)+'rsion']||_0x4a773b(0x14f));}[_0x547c80(0x1f2)+_0x547c80(0x17e)](){const _0xd8c0d2=_0x547c80;return this[_0xd8c0d2(0x1f6)+_0xd8c0d2(0x1ca)+'ed'](),this[_0xd8c0d2(0x14d)+_0xd8c0d2(0x15b)+_0xd8c0d2(0x191)];}async[_0x547c80(0x167)+_0x547c80(0x1f1)+_0x547c80(0x1ed)](){const _0x2c30ca=_0x547c80,_0xb68979={'hkooT':function(_0x1ce37c,_0x14effe){return _0x1ce37c!==_0x14effe;},'tGDxJ':_0x2c30ca(0x152)+_0x2c30ca(0x1a0),'TtwZO':'\u672A\u77E5\u9519\u8BEF'};let _0x9fb8bf=await this[_0x2c30ca(0x178)](_0x2c30ca(0x14b)+_0x2c30ca(0x16d)+_0x2c30ca(0x1a3)+_0x2c30ca(0x1ef),null,-0x1fa2+-0xc2*-0x1d+-0x6c8*-0x2);if(!_0x9fb8bf||_0xb68979[_0x2c30ca(0x14a)](_0x9fb8bf[_0x2c30ca(0x19e)],0x37*0x3+-0x1ddc+0x1d38))throw new Error(_0xb68979['tGDxJ']+(_0x9fb8bf?.[_0x2c30ca(0x1ae)]||_0xb68979[_0x2c30ca(0x1e0)]));return!(0x11*0x131+0xefd+0x233e*-0x1);}async[_0x547c80(0x161)+_0x547c80(0x19a)+_0x547c80(0x158)](){const _0x43d1cb=_0x547c80,_0x46be1d={'JwAnU':'/tool/su'+'bscripti'+_0x43d1cb(0x185)+'s','XbSvF':function(_0x4eb008,_0x15ec4b){return _0x4eb008+_0x15ec4b;},'mvSlu':_0x43d1cb(0x1aa)+'发生错误:'};let _0x8080a2=await this['_post'](_0x46be1d[_0x43d1cb(0x1af)]);if(!_0x8080a2||_0x8080a2[_0x43d1cb(0x19e)]!==-0x1*-0x48b+0xe5b+-0x1*0x12e5||!_0x8080a2[_0x43d1cb(0x1e7)])throw new Error(_0x46be1d[_0x43d1cb(0x1ba)](_0x46be1d[_0x43d1cb(0x168)],_0x8080a2?.[_0x43d1cb(0x1ae)]||_0x43d1cb(0x162)));return _0x8080a2['data'];}async['GetUserI'+_0x547c80(0x1df)](){const _0x52fa56=_0x547c80,_0x58488e={'BkVmO':function(_0x408949,_0x3beaf7){return _0x408949+_0x3beaf7;},'uhnYr':_0x52fa56(0x1c4)+_0x52fa56(0x1a0),'BlJZl':_0x52fa56(0x162)};let _0x47521d=await this[_0x52fa56(0x178)](_0x52fa56(0x1e2)+'fo');if(!_0x47521d||_0x47521d[_0x52fa56(0x19e)]!==0x2173+-0x1*-0x6d9+0x5*-0x80f||!_0x47521d[_0x52fa56(0x1e7)])throw new Error(_0x58488e[_0x52fa56(0x155)](_0x58488e['uhnYr'],_0x47521d?.[_0x52fa56(0x1ae)]||_0x58488e[_0x52fa56(0x18c)]));return _0x47521d['data'];}async['GetWoWCu'+_0x547c80(0x1db)+'sion'](){const _0x3b3ff1=_0x547c80,_0xa2a74={'YPQZt':_0x3b3ff1(0x18a)+_0x3b3ff1(0x19f)+_0x3b3ff1(0x1b2)+'n','jUgYb':function(_0x290982,_0x50580d){return _0x290982!==_0x50580d;},'oiaNE':function(_0x4c0879,_0x552c08){return _0x4c0879+_0x552c08;},'IMznq':_0x3b3ff1(0x1b7)+_0x3b3ff1(0x189)};let _0x3b2336=await this[_0x3b3ff1(0x178)](_0xa2a74[_0x3b3ff1(0x1c9)]);if(!_0x3b2336||_0xa2a74[_0x3b3ff1(0x1d8)](_0x3b2336[_0x3b3ff1(0x19e)],-0x4c+0x125b+-0x2*0x907)||!_0x3b2336[_0x3b3ff1(0x1e7)])throw new Error(_0xa2a74[_0x3b3ff1(0x157)](_0xa2a74[_0x3b3ff1(0x166)],_0x3b2336?.[_0x3b3ff1(0x1ae)]||_0x3b3ff1(0x162)));return _0x3b2336[_0x3b3ff1(0x1e7)];}async[_0x547c80(0x1cf)+_0x547c80(0x165)](_0x47c991,_0x408cf9,_0xb0d8e){const _0x2f7bb4=_0x547c80,_0x5e8e30={'byukm':function(_0x3ac917,_0x54b169){return _0x3ac917!==_0x54b169;},'XUReb':_0x2f7bb4(0x1d1)+_0x2f7bb4(0x186),'eEDMi':_0x2f7bb4(0x162)};let _0x59be48={'game_version_id':_0x47c991,'addon_id':_0x408cf9};_0xb0d8e&&(_0x59be48[_0x2f7bb4(0x18e)+'ey']=_0xb0d8e);let _0x4012ce=await this[_0x2f7bb4(0x178)](_0x2f7bb4(0x18a)+_0x2f7bb4(0x1c1)+_0x2f7bb4(0x1a5),_0x59be48);if(!_0x4012ce||_0x5e8e30['byukm'](_0x4012ce['code'],0x9d1*-0x1+-0x9d0+0x13a2))throw new Error(_0x5e8e30['XUReb']+(_0x4012ce?.[_0x2f7bb4(0x1ae)]||_0x5e8e30[_0x2f7bb4(0x147)]));return _0x4012ce[_0x2f7bb4(0x1e7)];}async[_0x547c80(0x1fa)](_0x521746,_0x367494){const _0x28a3bf=_0x547c80,_0x177a29={'rWVqE':function(_0xb94a21,_0x5e7ccf){return _0xb94a21!==_0x5e7ccf;},'fQrxI':function(_0x406820,_0x123423){return _0x406820+_0x123423;},'qbbrl':_0x28a3bf(0x162)};let _0x1e8b04=await this['_post'](_0x521746,_0x367494);if(!_0x1e8b04||_0x177a29[_0x28a3bf(0x1dd)](_0x1e8b04[_0x28a3bf(0x19e)],0x594+-0xe76+0x8e3))throw new Error(_0x177a29[_0x28a3bf(0x1cd)](_0x28a3bf(0x197)+_0x28a3bf(0x15e),_0x1e8b04?.[_0x28a3bf(0x1ae)]||_0x177a29[_0x28a3bf(0x1f7)]));return _0x1e8b04[_0x28a3bf(0x1e7)];}};export{_ as NewBeeClient,g as SDK_VERSION,y as SUBSCRIBE_MODE};
|
|
1
|
+
const _0x5f1079=_0x47ad;(function(_0x7b3225,_0x187a7e){const _0x34fec5=_0x47ad,_0xc387f7=_0x7b3225();while(!![]){try{const _0x23cac3=parseInt(_0x34fec5(0xa5))/(-0x1748+-0x526*0x7+0x3b53)*(parseInt(_0x34fec5(0xd7))/(0x1ab*0x1+-0x30*0x2c+0x697))+parseInt(_0x34fec5(0x113))/(-0x2*0x7d5+0x2414+-0x3*0x6cd)+parseInt(_0x34fec5(0x116))/(-0x2418+0x1ecf+-0x54d*-0x1)+parseInt(_0x34fec5(0xb8))/(-0xcf+0x33*-0xbb+0x1*0x2615)+parseInt(_0x34fec5(0x14c))/(0x937+0x1f75+0x56*-0x79)*(-parseInt(_0x34fec5(0x120))/(0x34*-0x52+0x1*-0x232b+0x33da))+-parseInt(_0x34fec5(0x122))/(0x21b4+0x281*-0xf+0x3e3)*(-parseInt(_0x34fec5(0xd3))/(0x1a66+0x141d+-0x2e7a))+-parseInt(_0x34fec5(0x13e))/(-0x10bf+0x254b+-0x1482);if(_0x23cac3===_0x187a7e)break;else _0xc387f7['push'](_0xc387f7['shift']());}catch(_0x4ca2a5){_0xc387f7['push'](_0xc387f7['shift']());}}}(_0x4b79,-0x2d177+0x33c34+0x1b338));var g=_0x5f1079(0x13c),b=[-0x35c9*-0x5+0x13*-0xa1d+0x3e22,-0x16bc*-0xa+-0x11497+0xbc28,0x9*0x16+-0x25*-0x72d+-0x7f5d,0xe0d6+0x7561*0x2+0xb*-0x1d27,-0x247d+0x1*0x3e27+0x5f6*0x13,0x4291*0x1+-0x2*-0x7f6+0x3870,-0xa31f*-0x1+0x67ae+0x7fdf*-0x1,-0x1082b+0xf8e+0x1838c,0x1946*0x5+0xd5f4+-0xc962,0x108df+0xaf3d+0x12d2b*-0x1,0x2ad7*0x3+-0x3a14+-0x1*-0x4481,-0x4538+-0xdbe2+-0x8eaf*-0x3,-0xcb31+0x2ea1+0x12784,0xb420+-0x2*0xae5+-0x1361,0x1*-0xb6b7+0x31*-0x25f+0x1b5dc,0x2bd4+0x1f*0x92+-0x4d75*-0x1,-0x1b04+0x3931+0x6ccb,0xdbe4+0x17*-0x1d7+-0x269a,0x7*-0x8eb+0x5706+0x7*0x1057,0x31da+-0x50*-0x1ea+-0x3fff],f=[-0xab6+0x142b+-0x477,-0x1*0x2806+0x1a64+0x2843,-0xdc2+-0x2240+0x5cc2,-0x5ee8*0x1+-0x1*-0x667+-0x1d5c*-0x5,0x94f5+0x2*0x13c3+0x70cf*-0x1,0x9dcb+0x1*-0x4e2f+0xd6a,-0x775f*-0x1+0x8960+0x34*-0x2c9,-0x2*0x1646+0xfc4b*0x1+-0x4dc0,0x1c*0x7a7+0x73d+-0x3b40,-0xd59b+0x1*0x2fdb+-0x5*-0x45b9],p=[...b,...f],d=_0x5f1079(0x14b)+'27.0.0.1',a=_0x5f1079(0xef)+_0x5f1079(0xf9),c=null;function h(){const _0x4da618=_0x5f1079,_0x34b844={'rneAS':_0x4da618(0x104)+_0x4da618(0xf3)+_0x4da618(0xbc),'GeiNn':function(_0x58bcf6,_0x2a7bdc){return _0x58bcf6!==_0x2a7bdc;},'IQiwK':_0x4da618(0x115),'JPFlE':'uAUMN','VZMXN':function(_0x2c602b,_0x9fb877){return _0x2c602b<_0x9fb877;},'tRrWI':function(_0x5b9c81,_0x68bfeb){return _0x5b9c81(_0x68bfeb);}};try{if(_0x34b844[_0x4da618(0x124)](_0x34b844[_0x4da618(0xd9)],_0x34b844[_0x4da618(0x9f)])){if(_0x34b844['VZMXN'](typeof localStorage,'u')&&localStorage){let _0x100f0e=localStorage[_0x4da618(0x144)](a);if(_0x100f0e)return _0x34b844[_0x4da618(0x126)](Number,_0x100f0e)||null;}}else{if(!this[_0x4da618(0x9e)+'lient_po'+'rt'])throw new _0x5c4e8b(_0x34b844[_0x4da618(0xb4)]);}}catch{}return c;}function w(_0x4311aa){const _0x5623e1=_0x5f1079,_0x3e5d48={'Opzwb':function(_0x524d3a,_0x3ab0dc){return _0x524d3a<_0x3ab0dc;}};c=_0x4311aa;try{_0x3e5d48[_0x5623e1(0x13d)](typeof localStorage,'u')&&localStorage&&localStorage[_0x5623e1(0xd4)](a,String(_0x4311aa));}catch{}}function u(){const _0x4a3406=_0x5f1079;c=null;try{typeof localStorage<'u'&&localStorage&&localStorage[_0x4a3406(0x14a)+'em'](a);}catch{}}function m(_0xb347e1){const _0x3f985a=_0x5f1079,_0x55d37a={'MPRfH':function(_0x32fd79,_0x5c6c2e){return _0x32fd79==_0x5c6c2e;},'bhycB':_0x3f985a(0x9a),'JfUGU':function(_0x57fdea,_0x1f0238){return _0x57fdea(_0x1f0238);},'nITHb':'not\x20newb'+_0x3f985a(0xcf)+'t','Rpgby':function(_0x6bd93,_0x3c2431,_0x2f989e){return _0x6bd93(_0x3c2431,_0x2f989e);},'qgvCb':function(_0x5777af,_0x77905e,_0x316fa2){return _0x5777af(_0x77905e,_0x316fa2);},'IgXmi':'/ping','lbAJY':function(_0x3d205a,_0x3b59a8){return _0x3d205a!==_0x3b59a8;},'VkIuY':_0x3f985a(0xde),'RANRP':_0x3f985a(0xfa),'LyuxG':function(_0x16ed89,_0x48d9e2){return _0x16ed89+_0x48d9e2;},'vIBXX':function(_0x2d62c0,_0x38728c){return _0x2d62c0+_0x38728c;},'jPlnr':function(_0x2c69ae,_0x594d36){return _0x2c69ae+_0x594d36;},'VIXrk':_0x3f985a(0xb6)};return new Promise((_0x45231f,_0x1208a7)=>{const _0x2d203f=_0x3f985a,_0x143291={'BkNTo':function(_0x878c7b,_0x10c3f9){return _0x878c7b(_0x10c3f9);},'tGoeJ':_0x55d37a[_0x2d203f(0xcc)],'UeTzS':function(_0x4f8c27,_0x34339d){return _0x55d37a['JfUGU'](_0x4f8c27,_0x34339d);},'tdCwz':function(_0x30af9c,_0x2cef15,_0x5a4d52){const _0x30973d=_0x2d203f;return _0x55d37a[_0x30973d(0xfd)](_0x30af9c,_0x2cef15,_0x5a4d52);},'fQWWN':function(_0x3ecd36,_0x2c372a,_0x3105e8){const _0x2816b6=_0x2d203f;return _0x55d37a[_0x2816b6(0xf7)](_0x3ecd36,_0x2c372a,_0x3105e8);},'MILqc':function(_0x3541e2,_0x3552eb){return _0x3541e2+_0x3552eb;},'qcvGw':_0x55d37a[_0x2d203f(0x10a)],'CdBec':_0x2d203f(0xb6)};if(_0x55d37a['lbAJY'](_0x55d37a['VkIuY'],_0x55d37a[_0x2d203f(0xc0)])){let _0x1160e6=new AbortController(),_0x484a9a=setTimeout(()=>_0x1160e6[_0x2d203f(0x141)](),-0x11*0x114+-0x411*0x5+0x1b7*0x17);_0x55d37a[_0x2d203f(0xfd)](fetch,_0x55d37a[_0x2d203f(0x133)](_0x55d37a[_0x2d203f(0x9d)](_0x55d37a['jPlnr'](d,':'),_0xb347e1),_0x55d37a[_0x2d203f(0x10a)]),{'method':_0x55d37a['VIXrk'],'signal':_0x1160e6[_0x2d203f(0xc9)]})['then'](_0x12ca00=>_0x12ca00[_0x2d203f(0xd5)]())[_0x2d203f(0x130)](_0x110b25=>{const _0x55f211=_0x2d203f;if(clearTimeout(_0x484a9a),_0x110b25&&_0x110b25['code']===-0x93e+0x40c+-0xb*-0x79){let _0x5aed9c=_0x110b25[_0x55f211(0xd2)]&&_0x110b25[_0x55f211(0xd2)][_0x55f211(0xe8)];_0x45231f({'port':_0xb347e1,'version':_0x55d37a[_0x55f211(0xea)](typeof _0x5aed9c,_0x55d37a[_0x55f211(0xcc)])?_0x5aed9c:''});}else _0x55d37a['JfUGU'](_0x1208a7,new Error(_0x55d37a[_0x55f211(0xa4)]));})['catch'](_0x4d7347=>{const _0x46fad3=_0x2d203f;_0x143291[_0x46fad3(0x9c)](clearTimeout,_0x484a9a),_0x1208a7(_0x4d7347);});}else{const _0x3c8e01={'fuzsX':function(_0x557356,_0x4d4c3a){return _0x557356(_0x4d4c3a);},'OAWlf':function(_0x5e7769,_0x47388a){return _0x5e7769==_0x47388a;},'BiXGh':_0x143291[_0x2d203f(0xa2)],'yHdRV':'not\x20newb'+_0x2d203f(0xcf)+'t','SxOdG':function(_0x250faa,_0x25d281){const _0x2ae0e5=_0x2d203f;return _0x143291[_0x2ae0e5(0x102)](_0x250faa,_0x25d281);}};let _0x25c12f=new _0x566ab7(),_0x449b0b=_0x143291[_0x2d203f(0x147)](_0x265012,()=>_0x25c12f[_0x2d203f(0x141)](),-0x1a5*-0x1+0x9ff+-0xadc);_0x143291['fQWWN'](_0xd4882f,_0x143291['MILqc'](_0x143291[_0x2d203f(0x107)](_0x1a41be,':')+_0x27f940,_0x143291[_0x2d203f(0x11b)]),{'method':_0x143291['CdBec'],'signal':_0x25c12f[_0x2d203f(0xc9)]})[_0x2d203f(0x130)](_0x38f59e=>_0x38f59e[_0x2d203f(0xd5)]())[_0x2d203f(0x130)](_0x5eab11=>{const _0x2ebb6b=_0x2d203f;if(_0x207e90(_0x449b0b),_0x5eab11&&_0x5eab11[_0x2ebb6b(0xe9)]===-0x16e8+-0x3*0x48f+0x619*0x6){let _0x4fe1d8=_0x5eab11['data']&&_0x5eab11[_0x2ebb6b(0xd2)]['version'];_0x3c8e01[_0x2ebb6b(0xfb)](_0x1fc50d,{'port':_0x5d1053,'version':_0x3c8e01['OAWlf'](typeof _0x4fe1d8,_0x3c8e01[_0x2ebb6b(0xf1)])?_0x4fe1d8:''});}else _0x4452ab(new _0xc9409b(_0x3c8e01['yHdRV']));})[_0x2d203f(0x138)](_0x1f9464=>{const _0x3eee54=_0x2d203f;_0x3c8e01[_0x3eee54(0xa6)](_0x7ad9ed,_0x449b0b),_0x3c8e01[_0x3eee54(0xfb)](_0x4d4255,_0x1f9464);});}});}function T(_0x371bd9){const _0x43403=_0x5f1079,_0x2d7e57={'tMhmC':function(_0x5cd5c7,_0x414f6e){return _0x5cd5c7==_0x414f6e;},'NVjHv':function(_0xc2f2b3,_0x2674ef){return _0xc2f2b3!==_0x2674ef;},'BUOmR':_0x43403(0x11e),'yHzuM':function(_0x52380e,_0x292199){return _0x52380e(_0x292199);},'nHstY':function(_0x4429ce,_0x12ae97){return _0x4429ce<_0x12ae97;},'wlHwl':function(_0x350a1f,_0x3c49e0){return _0x350a1f===_0x3c49e0;},'vbKjc':'xGPUa','cYIBw':function(_0x420869,_0xe76be3){return _0x420869===_0xe76be3;},'upMhc':function(_0x1baf11,_0xd36b2d){return _0x1baf11(_0xd36b2d);},'mxBTj':_0x43403(0xdb)+'date\x20por'+'ts'};return new Promise((_0x2a0601,_0x1851a7)=>{const _0x274a9a=_0x43403,_0x1a2383={'aKVLI':function(_0x1da4f0,_0x2fa445){return _0x2d7e57['tMhmC'](_0x1da4f0,_0x2fa445);},'mSlsc':function(_0x16d08b,_0xc0fc64){const _0x4eab63=_0x47ad;return _0x2d7e57[_0x4eab63(0xe4)](_0x16d08b,_0xc0fc64);},'wfFBZ':_0x2d7e57[_0x274a9a(0xbf)],'lLnXa':function(_0x505097,_0x26938d){const _0x47c51c=_0x274a9a;return _0x2d7e57[_0x47c51c(0xdc)](_0x505097,_0x26938d);},'PQvxp':function(_0x2bd4de,_0x155c8c){const _0x32cd5d=_0x274a9a;return _0x2d7e57[_0x32cd5d(0x103)](_0x2bd4de,_0x155c8c);}};if(_0x2d7e57[_0x274a9a(0x10c)](_0x2d7e57[_0x274a9a(0x127)],_0x2d7e57['vbKjc'])){let _0xef4ba0=_0x371bd9[_0x274a9a(0xf4)];if(_0x2d7e57[_0x274a9a(0x136)](_0xef4ba0,0x2*-0xcfe+0x1877*-0x1+0x3273)){_0x2d7e57[_0x274a9a(0x100)](_0x1851a7,new Error(_0x2d7e57[_0x274a9a(0x10f)]));return;}let _0x177d1b=!(0x1*0x136d+-0x8*-0x423+-0x3484);_0x371bd9[_0x274a9a(0xfe)](_0xc1af2e=>{const _0x4f90c1=_0x274a9a,_0x2df0ee={'VglgY':function(_0x4cf970,_0x3ee0d7){const _0x424e79=_0x47ad;return _0x1a2383[_0x424e79(0xb2)](_0x4cf970,_0x3ee0d7);},'VkdQS':_0x4f90c1(0x14d)+_0x4f90c1(0x146)};_0x1a2383[_0x4f90c1(0xb2)](m,_0xc1af2e)['then'](_0x108929=>{const _0x127e5a=_0x4f90c1,_0x23f7ee={'SoGxC':function(_0x1f1852,_0x61ed0e){return _0x1f1852(_0x61ed0e);},'dYmnW':function(_0x352492,_0x56ffec){const _0x413a92=_0x47ad;return _0x1a2383[_0x413a92(0x139)](_0x352492,_0x56ffec);}};if(_0x1a2383[_0x127e5a(0x129)](_0x1a2383[_0x127e5a(0xf5)],_0x1a2383[_0x127e5a(0xf5)])){let _0x5c5e55=_0x4bcdcc['data']&&_0x5975ff[_0x127e5a(0xd2)][_0x127e5a(0xe8)];fGHTIT[_0x127e5a(0x97)](_0x12dc20,{'port':_0xfb6d2a,'version':fGHTIT[_0x127e5a(0xd8)](typeof _0x5c5e55,'string')?_0x5c5e55:''});}else _0x177d1b||(_0x177d1b=!(0xb3c+-0x1a0f+-0xfd*-0xf),_0x1a2383[_0x127e5a(0xb2)](_0x2a0601,_0x108929));})[_0x4f90c1(0x138)](()=>{const _0xa33d97=_0x4f90c1;_0xef4ba0--,_0xef4ba0===-0x5e4+-0x1003+0x59*0x3f&&!_0x177d1b&&_0x2df0ee['VglgY'](_0x1851a7,new Error(_0x2df0ee[_0xa33d97(0xd0)]));});});}else XOAYhn[_0x274a9a(0xad)](typeof _0x190441,'u')&&_0x1a8d01&&_0x2ec06a['removeIt'+'em'](_0x52830f);});}function _0x4b79(){const _0x15ec7c=['sw5ZDgfSBfC','qLvpBvi','uKfouLa','5A6j6kof6A2u5yw95lIw55wm5O+s5lU2','DMDdzK8','yNnJCMLWDgK','5OMt5BYa6k6I5y2v6Ag16z2I5y+r55sF','Bg9N','C3rHDhvZ','ugf0y2G','r1reB3i','C2LNBMfS','D3bhrvK','qvbqx1nvqLm','yMH5y0i','C3LjEMS','r2v0q2XPzw4','zwuGy2XPzw4','vMTKuvm','ugf0y2JOR7FMSylLJ5e','zgf0yq','nduYmZiYt1LRrvjO','C2v0sxrLBq','ANnVBG','A0DxD2q','mte5ndqYsMnND2zn','zfLTBLC','svfPD0S','Cu5Ku3C','BM8Gy2fUzgK','EuH6Du0','z1DJy20','BuDHy20','DMvYC2LVBIa','EM1sq0C','suHNDNm','CeP3Dgi','5y+3koE8K+wTMowrVEs4RsK6','tLzQshy','5Q2J56gUioIVT+wjJEw+GowqJUwpSa','sLjgvM4','qvvuse9sx1m','DMvYC2LVBG','y29Kzq','tvbszKG','BgLLBNrFDMu','yvr6Axa','CMLWDgLVBL8','y3jPChrPB24','BMjIx2nSAwu','CNnPB24','qMLyr2G','uK9VDM8','6icf5PYQ5Qoa5Rwl5yIW5PAW5OMl55Us','BgvUz3rO','D2zgqLO','qvbqsutMOlZLVi/KUi0','CwD2q2i','C2vJCMv0x2S','BNrFCg9YDa','zNjOu1O','zNv6C1G','54Mi5PYS5y+r55sF6zsz6k+VoG','uNbNyNK','zM9YrwfJAa','5PYQ55+L6zsz6k+V','DxbnAgm','s0LqEfe','vwvuELm','BKHZDfK','u0rl5PYQ5yID5AEl5yYw5OIw','CNfqrKy','C2LVBG','tuLmCwm','6k+L5O6L5y+J77Ym6k+35y2h57QN5PAW','B25FC3rHDhu','swDyBwK','ww1LuLe','D2XiD2W','D19PBNn0ywW','BwvZC2fNzq','BxHcvgO','x3bVC3q','DfzLCNnPB24','5y+r55sF6zsz6k+VoG','mZK5mdCYCNjeCLn2','x2vUC3vYzuK','AxjIs3K','mJy0mty0yvLduwL5','DfjTtgC','DxP1r3C','zvbyAxq','vePlvgC','Cwn2r3C','5A6I5OI356UV5BYa5zcV55Qe56UV5y+J','5B2t5yMn5A6I5OI356UV5lIn5PsV5OYb','twDwDfm','DND5sxC','ntuXoti5C0Tvtw5d','rxf0u3a','ndbWrxLmr0W','w05LD0jLzui','r2vPtM4','BefjDuG','DfjYv0K','DMjlAMm','B1DbzgrVBG','BvnSC2m','q1jjqKu','ENbnr3y','yMT6zgW','rMXusfK','r2v0v29xq3u','l3rVB2WVC3u','DgHLBG','B2nqAK8','A3bvrwC','thL1EeC','yxbWx2LK','CNjLBNrwzxi','y1LjqNC','u2HVD1n1yNm','y2f0y2G','yuTwteK','z2TIsNe','l3rVB2WVD28','ms4WlJiW','t3b6D2i','nta0mZy0mffQB0nnuq','DwjZy3jPChq','Df92zxjZAw8','ywjVCNq','ue9tva','l3rVB2WVB3a','z2v0sxrLBq','AfLrugG','CYbMywLSzwq','DgrdD3O','y1LIr24','r05Xsvi','CMvTB3zLsxq','Ahr0CdOVlZe','nLLbCvbjDG','ywXSihbVCNq','u29hEem','r2v0vxnLCKK','tM91t3q','C3rYAw5N','BML0AwfSAxO','qMTovg8','DKLcwfG','BMv3yMvLx2m','sLbgBeu','sLPjrgW','C3rYAw5NAwy','DeDVzuO','vujtq1jjqKu','BKLusgi','mwDYqwvNvq','u3HpzeC','AMvsB0y','55sF6zsz6k+VoG','y0XOr1C','wMX1vMq','y0ngqLa','y29oDLG','uff2Eha','C1D6DfC','zffeseS','5OMl55Us5A2q5A6I5OI356UV','qxbVDuG','BeXUwge','BgLLBNrFCg8','CM5Lqvm','sw5PDa','r0vu','Cg9YDa','mta1otm4mhvgtvnKuG','6i635y+w55sO5OI36k6I6zIf5l+H5OgV','5PYQ5lIk5OQL','DLLQtwe','5A2q5A6I5OI356UV','5A6I5OI356UV5lIn5PsV5OYb6k+L5O6L'];_0x4b79=function(){return _0x15ec7c;};return _0x4b79();}var P=-(0x1e2a+-0xc77+0x1*-0x101f),E=_0x5f1079(0x11d)+_0x5f1079(0x108)+_0x5f1079(0xb0),y=(_0x5cb473=>(_0x5cb473[_0x5cb473[_0x5f1079(0xe7)+_0x5f1079(0xa3)]=-0x6*0x43e+0xaec+0xe89]=_0x5f1079(0xe7)+_0x5f1079(0xa3),_0x5cb473[_0x5cb473[_0x5f1079(0xcb)+'CRIBE']=0x1b18+-0xdff+-0x3*0x45d]=_0x5f1079(0xcb)+_0x5f1079(0x12a),_0x5cb473))(y||{}),_=class{constructor(){const _0x41d910=_0x5f1079;this[_0x41d910(0x134)]='',this[_0x41d910(0x9e)+_0x41d910(0xb3)+'rt']=0x6e6+0x24ed+0x2bd3*-0x1,this['newbee_c'+_0x41d910(0xeb)+_0x41d910(0xf0)]='';}[_0x5f1079(0x114)+'nitializ'+'ed'](){const _0x2f2ad9=_0x5f1079,_0x5f80={'coNvX':'SDK未初始化或'+'者未检测到新手盒'+_0x2f2ad9(0xbc)};if(!this[_0x2f2ad9(0x9e)+_0x2f2ad9(0xb3)+'rt'])throw new Error(_0x5f80[_0x2f2ad9(0xac)]);}async[_0x5f1079(0x110)](_0x2563c7,_0x28126a,_0x293ac6){const _0x5c2d51=_0x5f1079,_0x12cf15={'NouOt':function(_0xf6ade4,_0x26e5d4){return _0xf6ade4(_0x26e5d4);},'GTDor':_0x5c2d51(0xdb)+'date\x20por'+'ts','bkzdl':function(_0x17f377,_0x421f17,_0x78b611){return _0x17f377(_0x421f17,_0x78b611);},'cLhGW':function(_0x1b1f5,_0x514372){return _0x1b1f5!==_0x514372;},'vgCfO':_0x5c2d51(0xae),'qNdSw':function(_0x40f35a,_0xd8bbbb,_0x1e3885){return _0x40f35a(_0xd8bbbb,_0x1e3885);},'GNqIR':function(_0x3f4f39,_0x5da92f){return _0x3f4f39+_0x5da92f;},'ApouH':function(_0x154fc6,_0x5de86b){return _0x154fc6+_0x5de86b;},'QmNOz':_0x5c2d51(0x142),'wpGEY':'applicat'+'ion/json','cYbGn':_0x5c2d51(0xbd)+'口:','ocPjO':'\u54CD\u5E94:','ZluVd':'\u8BF7\u6C42\u9519\u8BEF:'};this[_0x5c2d51(0x114)+'nitializ'+'ed']();let _0x144a20=new AbortController(),_0x223666=_0x293ac6?_0x12cf15[_0x5c2d51(0x12c)](setTimeout,()=>_0x144a20[_0x5c2d51(0x141)]('\u8BF7\u6C42\u8D85\u65F6'),_0x293ac6):null;try{if(_0x12cf15[_0x5c2d51(0xa9)](_0x5c2d51(0x12d),_0x12cf15[_0x5c2d51(0xc2)])){let _0x12c1fa=await _0x12cf15[_0x5c2d51(0xda)](fetch,_0x12cf15[_0x5c2d51(0x149)](_0x12cf15[_0x5c2d51(0xb1)](d,':')+this['newbee_c'+_0x5c2d51(0xb3)+'rt'],_0x2563c7),{'method':_0x12cf15['QmNOz'],'signal':_0x144a20[_0x5c2d51(0xc9)],'headers':{'Content-Type':_0x12cf15[_0x5c2d51(0xca)]},'body':JSON[_0x5c2d51(0xa1)+'y']({'app_id':this['app_id'],..._0x28126a})});if(_0x12c1fa[_0x5c2d51(0xc6)]===0x96b*-0x3+-0xab*0x20+0x3335)return console['log'](_0x12cf15[_0x5c2d51(0x148)],_0x2563c7),{'code':P,'data':null,'message':E};let _0x47f9ee=await _0x12c1fa['json']();return console[_0x5c2d51(0xc5)](_0x2563c7,_0x12cf15[_0x5c2d51(0x131)],_0x47f9ee),_0x47f9ee;}else{rRrjuV[_0x5c2d51(0x99)](_0x28d146,new _0x257e86(rRrjuV[_0x5c2d51(0xc8)]));return;}}catch(_0x4c8361){return console[_0x5c2d51(0xc5)](_0x2563c7,_0x12cf15[_0x5c2d51(0xaa)],_0x4c8361),null;}finally{_0x223666&&_0x12cf15['NouOt'](clearTimeout,_0x223666);}}async[_0x5f1079(0xb5)](_0xe6c9ba){const _0x48da27=_0x5f1079,_0x57fc3a={'lAIuH':_0x48da27(0x9a),'JZIDl':_0x48da27(0xf6)+_0x48da27(0xe5)+'获取','vYjMa':function(_0x43ac9b,_0x1f5f07){return _0x43ac9b(_0x1f5f07);},'zpMGv':'客户端开启的端口'+_0x48da27(0xe3),'KIPxQ':'\u5BA2\u6237\u7AEF\u7248\u672C:','EaOoB':_0x48da27(0xba),'dQDHK':function(_0x117a4b){return _0x117a4b();},'vwyIw':function(_0x3b46f8,_0x3d734f){return _0x3b46f8(_0x3d734f);},'bRTDC':function(_0x3214f7,_0x24a4ca){return _0x3214f7(_0x24a4ca);},'Aisyr':function(_0x1cc018){return _0x1cc018();},'kGWwd':'未检测到新手盒子'+'客户端\x20初始化失'+'败','kpUEg':_0x48da27(0x11c)+'号:'};if(console['log'](_0x48da27(0x123)+'ox\x20SDK]\x20'+_0x48da27(0xdf)+g),!_0xe6c9ba||typeof _0xe6c9ba!=_0x57fc3a[_0x48da27(0x125)])throw new Error(_0x57fc3a[_0x48da27(0xa0)]);this[_0x48da27(0x134)]=_0xe6c9ba;let _0x2ad188=h();if(_0x2ad188)try{let _0x4a418b=await _0x57fc3a[_0x48da27(0xbb)](m,_0x2ad188);this[_0x48da27(0x9e)+_0x48da27(0xb3)+'rt']=_0x4a418b[_0x48da27(0xb7)],this[_0x48da27(0x9e)+'lient_ve'+'rsion']=_0x4a418b['version'],console['log'](_0x57fc3a[_0x48da27(0x12b)],this[_0x48da27(0x9e)+_0x48da27(0xb3)+'rt'],_0x57fc3a[_0x48da27(0x101)],this[_0x48da27(0x9e)+_0x48da27(0xeb)+_0x48da27(0xf0)]||_0x57fc3a['EaOoB']);return;}catch{_0x57fc3a[_0x48da27(0xaf)](u);}try{let _0x4ffcdc=await _0x57fc3a[_0x48da27(0x11f)](T,p);this[_0x48da27(0x9e)+_0x48da27(0xb3)+'rt']=_0x4ffcdc[_0x48da27(0xb7)],this[_0x48da27(0x9e)+_0x48da27(0xeb)+_0x48da27(0xf0)]=_0x4ffcdc[_0x48da27(0xe8)],_0x57fc3a['bRTDC'](w,this[_0x48da27(0x9e)+'lient_po'+'rt']);}catch{throw _0x57fc3a['Aisyr'](u),new Error(_0x57fc3a[_0x48da27(0xd6)]);}console[_0x48da27(0xc5)](_0x57fc3a[_0x48da27(0x132)],this[_0x48da27(0x9e)+_0x48da27(0xb3)+'rt'],_0x57fc3a[_0x48da27(0x101)],this[_0x48da27(0x9e)+_0x48da27(0xeb)+_0x48da27(0xf0)]||_0x48da27(0xba));}[_0x5f1079(0xce)+_0x5f1079(0x111)](){const _0x5e85d7=_0x5f1079;return this[_0x5e85d7(0x114)+_0x5e85d7(0x9b)+'ed'](),this[_0x5e85d7(0x9e)+'lient_ve'+_0x5e85d7(0xf0)];}async[_0x5f1079(0x137)+_0x5f1079(0xee)+'Page'](){const _0x500e79=_0x5f1079,_0x3768fc={'DNUIz':_0x500e79(0x143)+'en_subsc'+_0x500e79(0xed)+'dialog','TJKTg':function(_0x34f82b,_0x39c29f){return _0x34f82b!==_0x39c29f;},'pDnpm':function(_0x514c65,_0x52860d){return _0x514c65+_0x52860d;},'JRFVn':_0x500e79(0xc4)+'错误:','cCFBP':'\u672A\u77E5\u9519\u8BEF'};let _0x7464de=await this[_0x500e79(0x110)](_0x3768fc['DNUIz'],null,-0x2*0x238+-0x40e+0xc66);if(!_0x7464de||_0x3768fc[_0x500e79(0x11a)](_0x7464de[_0x500e79(0xe9)],0xa73+-0x18fe+0xe8c))throw new Error(_0x3768fc['pDnpm'](_0x3768fc[_0x500e79(0xe6)],_0x7464de?.[_0x500e79(0x10e)]||_0x3768fc[_0x500e79(0xab)]));return!(-0x20fa+-0xe*-0x214+0x1f1*0x2);}async['GetUserS'+_0x5f1079(0x13f)+'ion'](){const _0x6e8a6a=_0x5f1079,_0x335d23={'uzuGw':_0x6e8a6a(0x12f)+_0x6e8a6a(0xc3)+_0x6e8a6a(0x109)+'s','ijJRY':function(_0x56abbb,_0xb52532){return _0x56abbb!==_0xb52532;},'tRmLg':function(_0x489a7b,_0x468c81){return _0x489a7b+_0x468c81;},'ROovo':_0x6e8a6a(0xb9)+_0x6e8a6a(0x112),'rqPFF':_0x6e8a6a(0xff)};let _0x232ac6=await this['_post'](_0x335d23[_0x6e8a6a(0x118)]);if(!_0x232ac6||_0x335d23['ijJRY'](_0x232ac6[_0x6e8a6a(0xe9)],-0xa6*0x33+0x2e*-0x9d+0x3d49)||!_0x232ac6[_0x6e8a6a(0xd2)])throw new Error(_0x335d23[_0x6e8a6a(0x117)](_0x335d23[_0x6e8a6a(0xf2)],_0x232ac6?.['message']||_0x335d23[_0x6e8a6a(0x105)]));return _0x232ac6['data'];}async[_0x5f1079(0x98)+'nfo'](){const _0x5371a6=_0x5f1079,_0x20294d={'aTzip':'/user/in'+'fo','jeRoF':function(_0x399092,_0x563cd7){return _0x399092!==_0x563cd7;},'gWccm':function(_0x2af66d,_0x48abfc){return _0x2af66d+_0x48abfc;},'pJwtb':_0x5371a6(0xff)};let _0x59d33c=await this['_post'](_0x20294d[_0x5371a6(0xec)]);if(!_0x59d33c||_0x20294d[_0x5371a6(0xa7)](_0x59d33c['code'],0x98+0x1f31+-0x1fc8)||!_0x59d33c[_0x5371a6(0xd2)])throw new Error(_0x20294d[_0x5371a6(0xdd)]('获取用户信息发生'+'错误:',_0x59d33c?.[_0x5371a6(0x10e)]||_0x20294d[_0x5371a6(0xe2)]));return{'openid':'',..._0x59d33c[_0x5371a6(0xd2)]};}async[_0x5f1079(0x12e)+_0x5f1079(0x135)+_0x5f1079(0x106)](){const _0x53c4e2=_0x5f1079,_0x421d5c={'hYQPh':_0x53c4e2(0x13b)+'w_curren'+_0x53c4e2(0x140)+'n','xUyHh':function(_0x5383cc,_0x5472a8){return _0x5383cc!==_0x5472a8;},'IHgvs':'获取魔兽世界当前'+_0x53c4e2(0xfc)};let _0x537367=await this[_0x53c4e2(0x110)](_0x421d5c[_0x53c4e2(0x145)]);if(!_0x537367||_0x421d5c['xUyHh'](_0x537367[_0x53c4e2(0xe9)],0xcec+0x653*-0x1+-0x698)||!_0x537367[_0x53c4e2(0xd2)])throw new Error(_0x421d5c[_0x53c4e2(0xe1)]+(_0x537367?.[_0x53c4e2(0x10e)]||_0x53c4e2(0xff)));return _0x537367[_0x53c4e2(0xd2)];}async[_0x5f1079(0xbe)+_0x5f1079(0x128)](_0x409d05,_0x16debf,_0x558288){const _0x3660d2=_0x5f1079,_0x1d4dd2={'syIzk':'/tool/wo'+_0x3660d2(0x10d)+'l_addon','ePXit':function(_0x495354,_0x334f3f){return _0x495354+_0x334f3f;},'EqtSp':_0x3660d2(0xff)};let _0x4989fe={'game_version_id':_0x409d05,'addon_id':_0x16debf};_0x558288&&(_0x4989fe[_0x3660d2(0xf8)+'ey']=_0x558288);let _0x23149d=await this[_0x3660d2(0x110)](_0x1d4dd2[_0x3660d2(0xcd)],_0x4989fe);if(!_0x23149d||_0x23149d[_0x3660d2(0xe9)]!==-0xa31*-0x2+-0x3*0x97+0x2*-0x94e)throw new Error(_0x1d4dd2[_0x3660d2(0x119)](_0x3660d2(0xc1)+_0x3660d2(0x112),_0x23149d?.[_0x3660d2(0x10e)]||_0x1d4dd2[_0x3660d2(0x121)]));return _0x23149d[_0x3660d2(0xd2)];}async[_0x5f1079(0xc7)](_0x427355,_0x40757c){const _0x4d2f94=_0x5f1079,_0x2dbcc4={'YmeRQ':function(_0x563dbb,_0x2b5b33){return _0x563dbb!==_0x2b5b33;},'gkbJq':function(_0x38355b,_0x3398e2){return _0x38355b+_0x3398e2;},'kAHuS':_0x4d2f94(0xd1)+_0x4d2f94(0xa8),'zmRCG':_0x4d2f94(0xff)};let _0x28524a=await this['_post'](_0x427355,_0x40757c);if(!_0x28524a||_0x2dbcc4[_0x4d2f94(0x10b)](_0x28524a[_0x4d2f94(0xe9)],-0x1bf1+-0x5db+-0x1fd*-0x11))throw new Error(_0x2dbcc4[_0x4d2f94(0x13a)](_0x2dbcc4['kAHuS'],_0x28524a?.[_0x4d2f94(0x10e)]||_0x2dbcc4[_0x4d2f94(0xe0)]));return _0x28524a[_0x4d2f94(0xd2)];}};function _0x47ad(_0x2d0df6,_0x117e63){_0x2d0df6=_0x2d0df6-(0x2f5*-0xd+0x10f6+0x1612);const _0x254401=_0x4b79();let _0x225104=_0x254401[_0x2d0df6];if(_0x47ad['EthVEo']===undefined){var _0x1d0745=function(_0x2d5f27){const _0x1ad942='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x17314d='',_0x47f566='';for(let _0x2187ba=0x2479+-0xa94+0x1*-0x19e5,_0x190441,_0x1a8d01,_0x2ec06a=-0x20*-0x54+0xf09+-0x1989;_0x1a8d01=_0x2d5f27['charAt'](_0x2ec06a++);~_0x1a8d01&&(_0x190441=_0x2187ba%(0x35*-0x3d+0x27a+0x89*0x13)?_0x190441*(-0x18f7+-0x5*0x6a+-0x7f*-0x37)+_0x1a8d01:_0x1a8d01,_0x2187ba++%(0x27*0xbf+0x13a9+-0x30be))?_0x17314d+=String['fromCharCode'](0x1396+0x13*-0xc1+-0x444&_0x190441>>(-(0x5b7+0x1279+0x4d6*-0x5)*_0x2187ba&-0xaa*0x7+0xb94+-0x2*0x374)):-0x1*-0xc23+0x1b23*-0x1+-0x300*-0x5){_0x1a8d01=_0x1ad942['indexOf'](_0x1a8d01);}for(let _0x52830f=0x1ca5+0x2*0x115a+0x3f59*-0x1,_0x4e0392=_0x17314d['length'];_0x52830f<_0x4e0392;_0x52830f++){_0x47f566+='%'+('00'+_0x17314d['charCodeAt'](_0x52830f)['toString'](0x1edd+0x250b+-0x2*0x21ec))['slice'](-(0x1*-0x2301+0x709*0x1+0x1bfa));}return decodeURIComponent(_0x47f566);};_0x47ad['FvWadh']=_0x1d0745,_0x47ad['EXYVwU']={},_0x47ad['EthVEo']=!![];}const _0x7e9b2d=_0x254401[0x1b33+-0xc2*-0x2b+-0x1*0x3bc9];_0x47ad['fSSjcO']!==_0x7e9b2d&&(_0x47ad['EXYVwU']={},_0x47ad['fSSjcO']=_0x7e9b2d);const _0x2da734=_0x47ad['EXYVwU'][_0x2d0df6];return _0x2da734===undefined?(_0x225104=_0x47ad['FvWadh'](_0x225104),_0x47ad['EXYVwU'][_0x2d0df6]=_0x225104):_0x225104=_0x2da734,_0x225104;}export{_ as NewBeeClient,g as SDK_VERSION,y as SUBSCRIBE_MODE};
|