@mx-space/api-client 0.3.3 → 0.3.4

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.
Files changed (64) hide show
  1. package/build/index.cjs.js +9 -9
  2. package/build/index.cjs.js.map +1 -1
  3. package/build/index.cjs.min.js +1 -1
  4. package/build/index.cjs.min.js.map +1 -1
  5. package/build/index.d.ts +210 -119
  6. package/build/index.esm.js +9 -9
  7. package/build/index.esm.js.map +1 -1
  8. package/build/index.esm.min.js +1 -1
  9. package/build/index.esm.min.js.map +1 -1
  10. package/build/index.umd.js +9 -9
  11. package/build/index.umd.js.map +1 -1
  12. package/build/index.umd.min.js +1 -1
  13. package/build/index.umd.min.js.map +1 -1
  14. package/esm/core/controllers/aggregate.d.ts +5 -7
  15. package/esm/core/controllers/aggregate.js.map +1 -1
  16. package/esm/core/controllers/base.d.ts +5 -7
  17. package/esm/core/controllers/base.js.map +1 -1
  18. package/esm/core/controllers/category.d.ts +6 -16
  19. package/esm/core/controllers/category.js +2 -2
  20. package/esm/core/controllers/category.js.map +1 -1
  21. package/esm/core/controllers/comment.d.ts +2 -1
  22. package/esm/core/controllers/comment.js.map +1 -1
  23. package/esm/core/controllers/note.d.ts +3 -2
  24. package/esm/core/controllers/note.js.map +1 -1
  25. package/esm/core/controllers/page.d.ts +2 -1
  26. package/esm/core/controllers/page.js.map +1 -1
  27. package/esm/core/controllers/recently.d.ts +2 -1
  28. package/esm/core/controllers/recently.js.map +1 -1
  29. package/esm/core/controllers/say.d.ts +2 -1
  30. package/esm/core/controllers/say.js.map +1 -1
  31. package/esm/core/controllers/search.d.ts +6 -6
  32. package/esm/core/controllers/snippet.d.ts +2 -1
  33. package/esm/core/controllers/snippet.js.map +1 -1
  34. package/esm/core/controllers/user.d.ts +2 -1
  35. package/esm/core/controllers/user.js.map +1 -1
  36. package/esm/models/aggregate.d.ts +2 -1
  37. package/esm/models/aggregate.js.map +1 -1
  38. package/esm/models/post.d.ts +1 -9
  39. package/lib/core/controllers/aggregate.d.ts +5 -7
  40. package/lib/core/controllers/aggregate.js.map +1 -1
  41. package/lib/core/controllers/base.d.ts +5 -7
  42. package/lib/core/controllers/base.js.map +1 -1
  43. package/lib/core/controllers/category.d.ts +6 -16
  44. package/lib/core/controllers/category.js +3 -3
  45. package/lib/core/controllers/category.js.map +1 -1
  46. package/lib/core/controllers/comment.d.ts +2 -1
  47. package/lib/core/controllers/comment.js.map +1 -1
  48. package/lib/core/controllers/note.d.ts +3 -2
  49. package/lib/core/controllers/note.js.map +1 -1
  50. package/lib/core/controllers/page.d.ts +2 -1
  51. package/lib/core/controllers/page.js.map +1 -1
  52. package/lib/core/controllers/recently.d.ts +2 -1
  53. package/lib/core/controllers/recently.js.map +1 -1
  54. package/lib/core/controllers/say.d.ts +2 -1
  55. package/lib/core/controllers/say.js.map +1 -1
  56. package/lib/core/controllers/search.d.ts +6 -6
  57. package/lib/core/controllers/snippet.d.ts +2 -1
  58. package/lib/core/controllers/snippet.js.map +1 -1
  59. package/lib/core/controllers/user.d.ts +2 -1
  60. package/lib/core/controllers/user.js.map +1 -1
  61. package/lib/models/aggregate.d.ts +2 -1
  62. package/lib/models/aggregate.js.map +1 -1
  63. package/lib/models/post.d.ts +1 -9
  64. package/package.json +5 -5
package/build/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- // Generated by dts-bundle-generator v5.9.0
1
+ // Generated by dts-bundle-generator v6.1.0
2
2
 
3
3
  export declare type Class<T> = new (...args: any[]) => T;
4
4
  export declare type SelectFields<T extends string> = `${"+" | "-" | ""}${T}`[];
@@ -48,6 +48,70 @@ export declare type ResponseProxyExtraRaw<T, R = any> = T & {
48
48
  };
49
49
  };
50
50
  export declare type SortOrder = "asc" | "desc";
51
+ export interface Count {
52
+ read: number;
53
+ like: number;
54
+ }
55
+ export interface Image {
56
+ height: number;
57
+ width: number;
58
+ type: string;
59
+ accent?: string;
60
+ src: string;
61
+ }
62
+ export interface Pager {
63
+ total: number;
64
+ size: number;
65
+ currentPage: number;
66
+ totalPage: number;
67
+ hasPrevPage: boolean;
68
+ hasNextPage: boolean;
69
+ }
70
+ export interface PaginateResult<T> {
71
+ data: T[];
72
+ pagination: Pager;
73
+ }
74
+ declare class BaseModel {
75
+ created?: Date;
76
+ id?: string;
77
+ }
78
+ export interface PostModel {
79
+ commentsIndex: number;
80
+ allowComment: boolean;
81
+ hide: boolean;
82
+ copyright: boolean;
83
+ tags: string[];
84
+ count: Count;
85
+ id: string;
86
+ text: string;
87
+ title: string;
88
+ slug: string;
89
+ categoryId: string;
90
+ images: Image[];
91
+ modified: string;
92
+ created: string;
93
+ category: CategoryModel;
94
+ }
95
+ declare enum CategoryType {
96
+ Category = 0,
97
+ Tag = 1
98
+ }
99
+ export interface CategoryModel {
100
+ type: CategoryType;
101
+ count: number;
102
+ id: string;
103
+ created: string;
104
+ slug: string;
105
+ name: string;
106
+ modified: string;
107
+ }
108
+ export declare type CategoryWithChildrenModel = CategoryModel & {
109
+ children: Pick<PostModel, "id" | "title" | "slug" | "modified" | "created">[];
110
+ };
111
+ export interface TagModel {
112
+ count: number;
113
+ name: string;
114
+ }
51
115
  export interface NoteModel {
52
116
  id: string;
53
117
  hide: boolean;
@@ -106,59 +170,6 @@ export interface PageModel {
106
170
  /** Other Options */
107
171
  options?: object;
108
172
  }
109
- export interface Count {
110
- read: number;
111
- like: number;
112
- }
113
- export interface Image {
114
- height: number;
115
- width: number;
116
- type: string;
117
- accent?: string;
118
- src: string;
119
- }
120
- export interface Pager {
121
- total: number;
122
- size: number;
123
- currentPage: number;
124
- totalPage: number;
125
- hasPrevPage: boolean;
126
- hasNextPage: boolean;
127
- }
128
- export interface PaginateResult<T> {
129
- data: T[];
130
- pagination: Pager;
131
- }
132
- declare class BaseModel {
133
- created?: Date;
134
- id?: string;
135
- }
136
- export interface PostModel {
137
- commentsIndex: number;
138
- allowComment: boolean;
139
- hide: boolean;
140
- copyright: boolean;
141
- tags: string[];
142
- count: Count;
143
- id: string;
144
- text: string;
145
- title: string;
146
- slug: string;
147
- categoryId: string;
148
- images: Image[];
149
- modified: string;
150
- created: string;
151
- category: CategoryModel;
152
- }
153
- export interface CategoryModel {
154
- type: number;
155
- count: number;
156
- id: string;
157
- name: string;
158
- slug: string;
159
- created: Date;
160
- categoryId: string;
161
- }
162
173
  export interface SayModel {
163
174
  id?: string;
164
175
  text: string;
@@ -249,40 +260,33 @@ export declare class AggregateController implements IController {
249
260
  /**
250
261
  * 获取聚合数据
251
262
  */
252
- getAggregateData(): RequestProxyResult;
263
+ getAggregateData(): RequestProxyResult<AggregateRoot>;
253
264
  /**
254
265
  * 获取最新发布的内容
255
266
  */
256
- getTop(size?: number): RequestProxyResult;
267
+ getTop(size?: number): RequestProxyResult<AggregateTop, {
268
+ [key: string]: any;
269
+ data: AggregateTop;
270
+ }>;
257
271
  getTimeline(options?: {
258
272
  sort?: SortOrder;
259
273
  type?: TimelineType;
260
274
  year?: number;
261
- }): RequestProxyResult;
275
+ }): RequestProxyResult<{
276
+ data: TimelineData;
277
+ }, {
278
+ [key: string]: any;
279
+ data: {
280
+ data: TimelineData;
281
+ };
282
+ }>;
262
283
  /**
263
284
  * 获取聚合数据统计
264
285
  */
265
- getStat(): RequestProxyResult;
266
- }
267
- declare enum CategoryType {
268
- Category = 0,
269
- Tag = 1
270
- }
271
- export interface CategoryModel {
272
- type: CategoryType;
273
- count: number;
274
- id: string;
275
- created: string;
276
- slug: string;
277
- name: string;
278
- modified: string;
279
- }
280
- export declare type CategoryWithChildrenModel = CategoryModel & {
281
- children: Pick<PostModel, "id" | "title" | "slug" | "modified" | "created">[];
282
- };
283
- export interface TagModel {
284
- count: number;
285
- name: string;
286
+ getStat(): RequestProxyResult<AggregateStat, {
287
+ [key: string]: any;
288
+ data: AggregateStat;
289
+ }>;
286
290
  }
287
291
  export declare class CategoryController implements IController {
288
292
  private client;
@@ -290,21 +294,11 @@ export declare class CategoryController implements IController {
290
294
  base: string;
291
295
  constructor(client: HTTPClient);
292
296
  private get proxy();
293
- getAllCategories(): import("~/interfaces/request").RequestProxyResult<{
297
+ getAllCategories(): RequestProxyResult<{
294
298
  data: CategoryModel[];
295
- }, {
296
- [key: string]: any;
297
- data: {
298
- data: CategoryModel[];
299
- };
300
299
  }>;
301
- getAllTags(): import("~/interfaces/request").RequestProxyResult<{
300
+ getAllTags(): RequestProxyResult<{
302
301
  data: TagModel[];
303
- }, {
304
- [key: string]: any;
305
- data: {
306
- data: TagModel[];
307
- };
308
302
  }>;
309
303
  getCategoryDetail(id: string): Promise<ResponseProxyExtraRaw<CategoryWithChildrenModel>>;
310
304
  getCategoryDetail(ids: string[]): Promise<ResponseProxyExtraRaw<Map<string, CategoryWithChildrenModel>>>;
@@ -360,20 +354,32 @@ export declare class CommentController implements IController {
360
354
  /**
361
355
  * 根据 comment id 获取评论, 包括子评论
362
356
  */
363
- getById(id: string): RequestProxyResult;
357
+ getById(id: string): import("~/interfaces/request").RequestProxyResult<CommentModel, {
358
+ [key: string]: any;
359
+ data: CommentModel;
360
+ }>;
364
361
  /**
365
362
  * 获取文章的评论列表
366
363
  * @param refId 文章 Id
367
364
  */
368
- getByRefId(refId: string, pagination?: PaginationParams): RequestProxyResult;
365
+ getByRefId(refId: string, pagination?: PaginationParams): import("~/interfaces/request").RequestProxyResult<PaginateResult<CommentModel>, {
366
+ [key: string]: any;
367
+ data: PaginateResult<CommentModel>;
368
+ }>;
369
369
  /**
370
370
  * 评论
371
371
  */
372
- comment(refId: string, data: CommentDto): RequestProxyResult;
372
+ comment(refId: string, data: CommentDto): import("~/interfaces/request").RequestProxyResult<CommentModel, {
373
+ [key: string]: any;
374
+ data: CommentModel;
375
+ }>;
373
376
  /**
374
377
  * 回复评论
375
378
  */
376
- reply(commentId: string, data: CommentDto): RequestProxyResult;
379
+ reply(commentId: string, data: CommentDto): import("~/interfaces/request").RequestProxyResult<CommentModel, {
380
+ [key: string]: any;
381
+ data: CommentModel;
382
+ }>;
377
383
  }
378
384
  declare enum LinkType {
379
385
  Friend = 0,
@@ -397,14 +403,24 @@ declare abstract class BaseCrudController<T> {
397
403
  base: string;
398
404
  constructor(client: HTTPClient);
399
405
  protected get proxy(): IRequestHandler;
400
- getById(id: string): RequestProxyResult;
401
- getAll(): RequestProxyResult;
406
+ getById(id: string): RequestProxyResult<T>;
407
+ getAll(): RequestProxyResult<{
408
+ data: T[];
409
+ }, {
410
+ [key: string]: any;
411
+ data: {
412
+ data: T[];
413
+ };
414
+ }>;
402
415
  /**
403
416
  * 带分页的查询
404
417
  * @param page
405
418
  * @param perPage
406
419
  */
407
- getAllPaginated(page?: number, perPage?: number): RequestProxyResult;
420
+ getAllPaginated(page?: number, perPage?: number): RequestProxyResult<PaginateResult<T>, {
421
+ [key: string]: any;
422
+ data: PaginateResult<T>;
423
+ }>;
408
424
  }
409
425
  export declare class LinkController extends BaseCrudController<LinkModel> {
410
426
  protected readonly client: HTTPClient;
@@ -427,25 +443,46 @@ export declare class NoteController implements IController {
427
443
  /**
428
444
  * 最新日记
429
445
  */
430
- getLatest(): RequestProxyResult;
446
+ getLatest(): import("~/interfaces/request").RequestProxyResult<NoteWrappedPayload, {
447
+ [key: string]: any;
448
+ data: NoteWrappedPayload;
449
+ }>;
431
450
  /**
432
451
  * 获取一篇日记
433
452
  * @param id id | nid
434
453
  * @param password 访问密码
435
454
  */
436
- getNoteById(id: string | number, password?: string): RequestProxyResult;
455
+ getNoteById(id: string | number, password?: string): import("~/interfaces/request").RequestProxyResult<NoteWrappedPayload, {
456
+ [key: string]: any;
457
+ data: NoteWrappedPayload;
458
+ }>;
437
459
  /**
438
460
  * 日记列表分页
439
461
  */
440
- getList(page?: number, perPage?: number, options?: NoteListOptions): RequestProxyResult;
462
+ getList(page?: number, perPage?: number, options?: NoteListOptions): import("~/interfaces/request").RequestProxyResult<PaginateResult<NoteModel>, {
463
+ [key: string]: any;
464
+ data: PaginateResult<NoteModel>;
465
+ }>;
441
466
  /**
442
467
  * 获取当前日记的上下各 n / 2 篇日记
443
468
  */
444
- getMiddleList(id: string, size?: number): RequestProxyResult;
469
+ getMiddleList(id: string, size?: number): import("~/interfaces/request").RequestProxyResult<{
470
+ data: Pick<NoteModel, "id" | "title" | "nid" | "created">[];
471
+ size: number;
472
+ }, {
473
+ [key: string]: any;
474
+ data: {
475
+ data: Pick<NoteModel, "id" | "title" | "nid" | "created">[];
476
+ size: number;
477
+ };
478
+ }>;
445
479
  /**
446
480
  * 喜欢这篇日记
447
481
  */
448
- likeIt(id: string): RequestProxyResult;
482
+ likeIt(id: string): import("~/interfaces/request").RequestProxyResult<never, {
483
+ [key: string]: any;
484
+ data: never;
485
+ }>;
449
486
  }
450
487
  export declare type PageListOptions = {
451
488
  select?: SelectFields<keyof PageModel>;
@@ -461,17 +498,26 @@ export declare class PageController implements IController {
461
498
  /**
462
499
  * 页面列表
463
500
  */
464
- getList(page?: number, perPage?: number, options?: PageListOptions): RequestProxyResult;
501
+ getList(page?: number, perPage?: number, options?: PageListOptions): import("~/interfaces/request").RequestProxyResult<PaginateResult<PageModel>, {
502
+ [key: string]: any;
503
+ data: PaginateResult<PageModel>;
504
+ }>;
465
505
  /**
466
506
  * 页面详情
467
507
  */
468
- getById(id: string): RequestProxyResult;
508
+ getById(id: string): import("~/interfaces/request").RequestProxyResult<PageModel, {
509
+ [key: string]: any;
510
+ data: PageModel;
511
+ }>;
469
512
  /**
470
513
  * 根据路径获取页面
471
514
  * @param slug 路径
472
515
  * @returns
473
516
  */
474
- getBySlug(slug: string): RequestProxyResult;
517
+ getBySlug(slug: string): import("~/interfaces/request").RequestProxyResult<PageModel, {
518
+ [key: string]: any;
519
+ data: PageModel;
520
+ }>;
475
521
  }
476
522
  export declare type PostListOptions = {
477
523
  select?: SelectFields<keyof PostModel>;
@@ -552,9 +598,26 @@ export declare class RecentlyController implements IController {
552
598
  /**
553
599
  * 获取最新一条
554
600
  */
555
- getLatestOne(): RequestProxyResult;
556
- getAll(): RequestProxyResult;
557
- getList(before?: string | undefined, after?: string | undefined, size?: number | number): RequestProxyResult;
601
+ getLatestOne(): import("~/interfaces/request").RequestProxyResult<RecentlyModel, {
602
+ [key: string]: any;
603
+ data: RecentlyModel;
604
+ }>;
605
+ getAll(): import("~/interfaces/request").RequestProxyResult<{
606
+ data: RecentlyModel[];
607
+ }, {
608
+ [key: string]: any;
609
+ data: {
610
+ data: RecentlyModel[];
611
+ };
612
+ }>;
613
+ getList(before?: string | undefined, after?: string | undefined, size?: number | number): import("~/interfaces/request").RequestProxyResult<{
614
+ data: RecentlyModel[];
615
+ }, {
616
+ [key: string]: any;
617
+ data: {
618
+ data: RecentlyModel[];
619
+ };
620
+ }>;
558
621
  }
559
622
  export declare class SayController extends BaseCrudController<SayModel> implements IController {
560
623
  protected client: HTTPClient;
@@ -565,7 +628,14 @@ export declare class SayController extends BaseCrudController<SayModel> implemen
565
628
  /**
566
629
  * 获取随机一条
567
630
  */
568
- getRandom(): RequestProxyResult;
631
+ getRandom(): import("~/interfaces/request").RequestProxyResult<{
632
+ data: SayModel | null;
633
+ }, {
634
+ [key: string]: any;
635
+ data: {
636
+ data: SayModel | null;
637
+ };
638
+ }>;
569
639
  }
570
640
  export declare type SearchOption = {
571
641
  orderBy?: string;
@@ -577,7 +647,7 @@ export declare class SearchController implements IController {
577
647
  base: string;
578
648
  name: string;
579
649
  constructor(client: HTTPClient);
580
- get proxy(): import("~/interfaces/request").IRequestHandler;
650
+ get proxy(): IRequestHandler;
581
651
  search(type: "note", keyword: string, options?: Omit<SearchOption, "rawAlgolia">): Promise<RequestProxyResult<PaginateResult<Pick<NoteModel, "modified" | "id" | "title" | "created" | "nid">>>>;
582
652
  search(type: "post", keyword: string, options?: Omit<SearchOption, "rawAlgolia">): Promise<RequestProxyResult<PaginateResult<Pick<PostModel, "modified" | "id" | "title" | "created" | "slug" | "category">>>>;
583
653
  /**
@@ -587,14 +657,14 @@ export declare class SearchController implements IController {
587
657
  * @param options
588
658
  * @returns
589
659
  */
590
- searchByAlgolia(keyword: string, options?: SearchOption): RequestProxyResult<RequestProxyResult<PaginateResult<Pick<PostModel, "created" | "id" | "modified" | "title" | "slug" | "category">> & {
660
+ searchByAlgolia(keyword: string, options?: SearchOption): RequestProxyResult<RequestProxyResult<PaginateResult<Pick<PostModel, "id" | "title" | "slug" | "modified" | "created" | "category">> & {
591
661
  /**
592
662
  * @see: algoliasearch <https://www.algolia.com/doc/api-reference/api-methods/search/>
593
663
  */
594
664
  raw?: any;
595
665
  }, {
596
666
  [key: string]: any;
597
- data: PaginateResult<Pick<PostModel, "created" | "id" | "modified" | "title" | "slug" | "category">> & {
667
+ data: PaginateResult<Pick<PostModel, "id" | "title" | "slug" | "modified" | "created" | "category">> & {
598
668
  /**
599
669
  * @see: algoliasearch <https://www.algolia.com/doc/api-reference/api-methods/search/>
600
670
  */
@@ -602,14 +672,14 @@ export declare class SearchController implements IController {
602
672
  };
603
673
  }>, {
604
674
  [key: string]: any;
605
- data: RequestProxyResult<PaginateResult<Pick<PostModel, "created" | "id" | "modified" | "title" | "slug" | "category">> & {
675
+ data: RequestProxyResult<PaginateResult<Pick<PostModel, "id" | "title" | "slug" | "modified" | "created" | "category">> & {
606
676
  /**
607
677
  * @see: algoliasearch <https://www.algolia.com/doc/api-reference/api-methods/search/>
608
678
  */
609
679
  raw?: any;
610
680
  }, {
611
681
  [key: string]: any;
612
- data: PaginateResult<Pick<PostModel, "created" | "id" | "modified" | "title" | "slug" | "category">> & {
682
+ data: PaginateResult<Pick<PostModel, "id" | "title" | "slug" | "modified" | "created" | "category">> & {
613
683
  /**
614
684
  * @see: algoliasearch <https://www.algolia.com/doc/api-reference/api-methods/search/>
615
685
  */
@@ -637,8 +707,14 @@ export declare class SnippetController implements IController {
637
707
  name: string;
638
708
  constructor(client: HTTPClient);
639
709
  get proxy(): IRequestHandler;
640
- getById(id: string): RequestProxyResult;
641
- getByReferenceAndName(reference: string, name: string): RequestProxyResult;
710
+ getById(id: string): import("~/interfaces/request").RequestProxyResult<SnippetModel, {
711
+ [key: string]: any;
712
+ data: SnippetModel;
713
+ }>;
714
+ getByReferenceAndName(reference: string, name: string): import("~/interfaces/request").RequestProxyResult<SnippetModel, {
715
+ [key: string]: any;
716
+ data: SnippetModel;
717
+ }>;
642
718
  }
643
719
  export declare class UserController implements IController {
644
720
  private readonly client;
@@ -646,9 +722,24 @@ export declare class UserController implements IController {
646
722
  base: string;
647
723
  name: string;
648
724
  protected get proxy(): IRequestHandler;
649
- getMasterInfo(): RequestProxyResult;
650
- login(username: string, password: string): RequestProxyResult;
651
- checkTokenValid(token: string): RequestProxyResult;
725
+ getMasterInfo(): import("~/interfaces/request").RequestProxyResult<UserModel, {
726
+ [key: string]: any;
727
+ data: UserModel;
728
+ }>;
729
+ login(username: string, password: string): import("~/interfaces/request").RequestProxyResult<TLogin, {
730
+ [key: string]: any;
731
+ data: TLogin;
732
+ }>;
733
+ checkTokenValid(token: string): import("~/interfaces/request").RequestProxyResult<{
734
+ ok: number;
735
+ isGuest: boolean;
736
+ }, {
737
+ [key: string]: any;
738
+ data: {
739
+ ok: number;
740
+ isGuest: boolean;
741
+ };
742
+ }>;
652
743
  }
653
744
  export declare const allControllers: (typeof AggregateController | typeof CategoryController | typeof CommentController | typeof LinkController | typeof NoteController | typeof PageController | typeof PostController | typeof ProjectController | typeof RecentlyController | typeof SayController | typeof SearchController | typeof SnippetController | typeof UserController)[];
654
745
  export declare const allContollerNames: string[];
@@ -478,6 +478,15 @@ var CategoryType;
478
478
  CategoryType[CategoryType["Tag"] = 1] = "Tag";
479
479
  })(CategoryType || (CategoryType = {}));
480
480
 
481
+ class RequestError extends Error {
482
+ constructor(message, status, path, raw) {
483
+ super(message);
484
+ this.status = status;
485
+ this.path = path;
486
+ this.raw = raw;
487
+ }
488
+ }
489
+
481
490
  class CategoryController {
482
491
  constructor(client) {
483
492
  this.client = client;
@@ -944,15 +953,6 @@ class HTTPControllerDefine {
944
953
  }
945
954
  }
946
955
 
947
- class RequestError extends Error {
948
- constructor(message, status, path, raw) {
949
- super(message);
950
- this.status = status;
951
- this.path = path;
952
- this.raw = raw;
953
- }
954
- }
955
-
956
956
  class HTTPClient extends HTTPControllerDefine {
957
957
  // define all clients
958
958
  constructor(_endpoint, _instance) {