@0xsequence/api 1.8.1 → 1.8.3

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.
@@ -18,9 +18,9 @@ function _extends() {
18
18
  }
19
19
 
20
20
  /* eslint-disable */
21
- // sequence-api v0.4.0 e4aaaf3a3c07a1f339226fcac3b8addcb3120c7b
21
+ // sequence-api v0.4.0 8c9ba9b9d3c5836bfb8eadcc78cdc2a929fcfb0d
22
22
  // --
23
- // Code generated by webrpc-gen@v0.10.x-dev with typescript@v0.10.0 generator. DO NOT EDIT.
23
+ // Code generated by webrpc-gen@v0.12.x-dev with typescript@v0.10.0 generator. DO NOT EDIT.
24
24
  //
25
25
  // webrpc-gen -schema=api.ridl -target=typescript@v0.10.0 -client -out=./clients/api.gen.ts
26
26
 
@@ -31,7 +31,7 @@ const WebRPCVersion = 'v1';
31
31
  const WebRPCSchemaVersion = 'v0.4.0';
32
32
 
33
33
  // Schema hash generated from your RIDL schema
34
- const WebRPCSchemaHash = 'e4aaaf3a3c07a1f339226fcac3b8addcb3120c7b';
34
+ const WebRPCSchemaHash = '8c9ba9b9d3c5836bfb8eadcc78cdc2a929fcfb0d';
35
35
 
36
36
  //
37
37
  // Types
@@ -91,6 +91,15 @@ class API {
91
91
  });
92
92
  });
93
93
  };
94
+ this.clock = headers => {
95
+ return this.fetch(this.url('Clock'), createHTTPRequest({}, headers)).then(res => {
96
+ return buildResponse(res).then(_data => {
97
+ return {
98
+ serverTime: _data.serverTime
99
+ };
100
+ });
101
+ });
102
+ };
94
103
  this.getSequenceContext = headers => {
95
104
  return this.fetch(this.url('GetSequenceContext'), createHTTPRequest({}, headers)).then(res => {
96
105
  return buildResponse(res).then(_data => {
@@ -112,6 +121,18 @@ class API {
112
121
  });
113
122
  });
114
123
  };
124
+ this.getAuthToken2 = (args, headers) => {
125
+ return this.fetch(this.url('GetAuthToken2'), createHTTPRequest(args, headers)).then(res => {
126
+ return buildResponse(res).then(_data => {
127
+ return {
128
+ status: _data.status,
129
+ jwtToken: _data.jwtToken,
130
+ address: _data.address,
131
+ user: _data.user
132
+ };
133
+ });
134
+ });
135
+ };
115
136
  this.sendPasswordlessLink = (args, headers) => {
116
137
  return this.fetch(this.url('SendPasswordlessLink'), createHTTPRequest(args, headers)).then(res => {
117
138
  return buildResponse(res).then(_data => {
@@ -528,15 +549,6 @@ class API {
528
549
  });
529
550
  });
530
551
  };
531
- this.walletRecover = (args, headers) => {
532
- return this.fetch(this.url('WalletRecover'), createHTTPRequest(args, headers)).then(res => {
533
- return buildResponse(res).then(_data => {
534
- return {
535
- encryptedWallet: _data.encryptedWallet
536
- };
537
- });
538
- });
539
- };
540
552
  this.blockNumberAtTime = (args, headers) => {
541
553
  return this.fetch(this.url('BlockNumberAtTime'), createHTTPRequest(args, headers)).then(res => {
542
554
  return buildResponse(res).then(_data => {
@@ -564,6 +576,25 @@ class API {
564
576
  });
565
577
  });
566
578
  };
579
+ this.linkWallet = (args, headers) => {
580
+ return this.fetch(this.url('LinkWallet'), createHTTPRequest(args, headers)).then(res => {
581
+ return buildResponse(res).then(_data => {
582
+ return {
583
+ status: _data.status,
584
+ linkedWalletAddress: _data.linkedWalletAddress
585
+ };
586
+ });
587
+ });
588
+ };
589
+ this.getLinkedWallets = (args, headers) => {
590
+ return this.fetch(this.url('GetLinkedWallets'), createHTTPRequest(args, headers)).then(res => {
591
+ return buildResponse(res).then(_data => {
592
+ return {
593
+ linkedWallets: _data.linkedWallets
594
+ };
595
+ });
596
+ });
597
+ };
567
598
  this.hostname = hostname;
568
599
  this.fetch = (input, init) => fetch(input, init);
569
600
  }
@@ -18,9 +18,9 @@ function _extends() {
18
18
  }
19
19
 
20
20
  /* eslint-disable */
21
- // sequence-api v0.4.0 e4aaaf3a3c07a1f339226fcac3b8addcb3120c7b
21
+ // sequence-api v0.4.0 8c9ba9b9d3c5836bfb8eadcc78cdc2a929fcfb0d
22
22
  // --
23
- // Code generated by webrpc-gen@v0.10.x-dev with typescript@v0.10.0 generator. DO NOT EDIT.
23
+ // Code generated by webrpc-gen@v0.12.x-dev with typescript@v0.10.0 generator. DO NOT EDIT.
24
24
  //
25
25
  // webrpc-gen -schema=api.ridl -target=typescript@v0.10.0 -client -out=./clients/api.gen.ts
26
26
 
@@ -31,7 +31,7 @@ const WebRPCVersion = 'v1';
31
31
  const WebRPCSchemaVersion = 'v0.4.0';
32
32
 
33
33
  // Schema hash generated from your RIDL schema
34
- const WebRPCSchemaHash = 'e4aaaf3a3c07a1f339226fcac3b8addcb3120c7b';
34
+ const WebRPCSchemaHash = '8c9ba9b9d3c5836bfb8eadcc78cdc2a929fcfb0d';
35
35
 
36
36
  //
37
37
  // Types
@@ -91,6 +91,15 @@ class API {
91
91
  });
92
92
  });
93
93
  };
94
+ this.clock = headers => {
95
+ return this.fetch(this.url('Clock'), createHTTPRequest({}, headers)).then(res => {
96
+ return buildResponse(res).then(_data => {
97
+ return {
98
+ serverTime: _data.serverTime
99
+ };
100
+ });
101
+ });
102
+ };
94
103
  this.getSequenceContext = headers => {
95
104
  return this.fetch(this.url('GetSequenceContext'), createHTTPRequest({}, headers)).then(res => {
96
105
  return buildResponse(res).then(_data => {
@@ -112,6 +121,18 @@ class API {
112
121
  });
113
122
  });
114
123
  };
124
+ this.getAuthToken2 = (args, headers) => {
125
+ return this.fetch(this.url('GetAuthToken2'), createHTTPRequest(args, headers)).then(res => {
126
+ return buildResponse(res).then(_data => {
127
+ return {
128
+ status: _data.status,
129
+ jwtToken: _data.jwtToken,
130
+ address: _data.address,
131
+ user: _data.user
132
+ };
133
+ });
134
+ });
135
+ };
115
136
  this.sendPasswordlessLink = (args, headers) => {
116
137
  return this.fetch(this.url('SendPasswordlessLink'), createHTTPRequest(args, headers)).then(res => {
117
138
  return buildResponse(res).then(_data => {
@@ -528,15 +549,6 @@ class API {
528
549
  });
529
550
  });
530
551
  };
531
- this.walletRecover = (args, headers) => {
532
- return this.fetch(this.url('WalletRecover'), createHTTPRequest(args, headers)).then(res => {
533
- return buildResponse(res).then(_data => {
534
- return {
535
- encryptedWallet: _data.encryptedWallet
536
- };
537
- });
538
- });
539
- };
540
552
  this.blockNumberAtTime = (args, headers) => {
541
553
  return this.fetch(this.url('BlockNumberAtTime'), createHTTPRequest(args, headers)).then(res => {
542
554
  return buildResponse(res).then(_data => {
@@ -564,6 +576,25 @@ class API {
564
576
  });
565
577
  });
566
578
  };
579
+ this.linkWallet = (args, headers) => {
580
+ return this.fetch(this.url('LinkWallet'), createHTTPRequest(args, headers)).then(res => {
581
+ return buildResponse(res).then(_data => {
582
+ return {
583
+ status: _data.status,
584
+ linkedWalletAddress: _data.linkedWalletAddress
585
+ };
586
+ });
587
+ });
588
+ };
589
+ this.getLinkedWallets = (args, headers) => {
590
+ return this.fetch(this.url('GetLinkedWallets'), createHTTPRequest(args, headers)).then(res => {
591
+ return buildResponse(res).then(_data => {
592
+ return {
593
+ linkedWallets: _data.linkedWallets
594
+ };
595
+ });
596
+ });
597
+ };
567
598
  this.hostname = hostname;
568
599
  this.fetch = (input, init) => fetch(input, init);
569
600
  }
@@ -14,9 +14,9 @@ function _extends() {
14
14
  }
15
15
 
16
16
  /* eslint-disable */
17
- // sequence-api v0.4.0 e4aaaf3a3c07a1f339226fcac3b8addcb3120c7b
17
+ // sequence-api v0.4.0 8c9ba9b9d3c5836bfb8eadcc78cdc2a929fcfb0d
18
18
  // --
19
- // Code generated by webrpc-gen@v0.10.x-dev with typescript@v0.10.0 generator. DO NOT EDIT.
19
+ // Code generated by webrpc-gen@v0.12.x-dev with typescript@v0.10.0 generator. DO NOT EDIT.
20
20
  //
21
21
  // webrpc-gen -schema=api.ridl -target=typescript@v0.10.0 -client -out=./clients/api.gen.ts
22
22
 
@@ -27,7 +27,7 @@ const WebRPCVersion = 'v1';
27
27
  const WebRPCSchemaVersion = 'v0.4.0';
28
28
 
29
29
  // Schema hash generated from your RIDL schema
30
- const WebRPCSchemaHash = 'e4aaaf3a3c07a1f339226fcac3b8addcb3120c7b';
30
+ const WebRPCSchemaHash = '8c9ba9b9d3c5836bfb8eadcc78cdc2a929fcfb0d';
31
31
 
32
32
  //
33
33
  // Types
@@ -87,6 +87,15 @@ class API {
87
87
  });
88
88
  });
89
89
  };
90
+ this.clock = headers => {
91
+ return this.fetch(this.url('Clock'), createHTTPRequest({}, headers)).then(res => {
92
+ return buildResponse(res).then(_data => {
93
+ return {
94
+ serverTime: _data.serverTime
95
+ };
96
+ });
97
+ });
98
+ };
90
99
  this.getSequenceContext = headers => {
91
100
  return this.fetch(this.url('GetSequenceContext'), createHTTPRequest({}, headers)).then(res => {
92
101
  return buildResponse(res).then(_data => {
@@ -108,6 +117,18 @@ class API {
108
117
  });
109
118
  });
110
119
  };
120
+ this.getAuthToken2 = (args, headers) => {
121
+ return this.fetch(this.url('GetAuthToken2'), createHTTPRequest(args, headers)).then(res => {
122
+ return buildResponse(res).then(_data => {
123
+ return {
124
+ status: _data.status,
125
+ jwtToken: _data.jwtToken,
126
+ address: _data.address,
127
+ user: _data.user
128
+ };
129
+ });
130
+ });
131
+ };
111
132
  this.sendPasswordlessLink = (args, headers) => {
112
133
  return this.fetch(this.url('SendPasswordlessLink'), createHTTPRequest(args, headers)).then(res => {
113
134
  return buildResponse(res).then(_data => {
@@ -524,15 +545,6 @@ class API {
524
545
  });
525
546
  });
526
547
  };
527
- this.walletRecover = (args, headers) => {
528
- return this.fetch(this.url('WalletRecover'), createHTTPRequest(args, headers)).then(res => {
529
- return buildResponse(res).then(_data => {
530
- return {
531
- encryptedWallet: _data.encryptedWallet
532
- };
533
- });
534
- });
535
- };
536
548
  this.blockNumberAtTime = (args, headers) => {
537
549
  return this.fetch(this.url('BlockNumberAtTime'), createHTTPRequest(args, headers)).then(res => {
538
550
  return buildResponse(res).then(_data => {
@@ -560,6 +572,25 @@ class API {
560
572
  });
561
573
  });
562
574
  };
575
+ this.linkWallet = (args, headers) => {
576
+ return this.fetch(this.url('LinkWallet'), createHTTPRequest(args, headers)).then(res => {
577
+ return buildResponse(res).then(_data => {
578
+ return {
579
+ status: _data.status,
580
+ linkedWalletAddress: _data.linkedWalletAddress
581
+ };
582
+ });
583
+ });
584
+ };
585
+ this.getLinkedWallets = (args, headers) => {
586
+ return this.fetch(this.url('GetLinkedWallets'), createHTTPRequest(args, headers)).then(res => {
587
+ return buildResponse(res).then(_data => {
588
+ return {
589
+ linkedWallets: _data.linkedWallets
590
+ };
591
+ });
592
+ });
593
+ };
563
594
  this.hostname = hostname;
564
595
  this.fetch = (input, init) => fetch(input, init);
565
596
  }
@@ -1,6 +1,6 @@
1
1
  export declare const WebRPCVersion = "v1";
2
2
  export declare const WebRPCSchemaVersion = "v0.4.0";
3
- export declare const WebRPCSchemaHash = "e4aaaf3a3c07a1f339226fcac3b8addcb3120c7b";
3
+ export declare const WebRPCSchemaHash = "8c9ba9b9d3c5836bfb8eadcc78cdc2a929fcfb0d";
4
4
  export declare enum SmartRampOrderStatus {
5
5
  UNKNOWN = "UNKNOWN",
6
6
  RUNNING_CHECKS = "RUNNING_CHECKS",
@@ -31,6 +31,15 @@ export interface RuntimeStatus {
31
31
  branch: string;
32
32
  commitHash: string;
33
33
  checks: RuntimeChecks;
34
+ numTxnsRelayed: {
35
+ [key: string]: NumTxnsRelayed;
36
+ };
37
+ }
38
+ export interface NumTxnsRelayed {
39
+ chainID: number;
40
+ prev: number;
41
+ current: number;
42
+ period: number;
34
43
  }
35
44
  export interface RuntimeChecks {
36
45
  }
@@ -228,6 +237,12 @@ export interface PayCardAuth {
228
237
  card2faNeeded: boolean;
229
238
  authorization3dsUrl: string;
230
239
  }
240
+ export interface LinkedWallet {
241
+ id: number;
242
+ walletAddress: string;
243
+ linkedWalletAddress: string;
244
+ createdAt?: string;
245
+ }
231
246
  export interface Page {
232
247
  pageSize?: number;
233
248
  page?: number;
@@ -236,6 +251,7 @@ export interface Page {
236
251
  before?: any;
237
252
  after?: any;
238
253
  sort?: Array<SortBy>;
254
+ more?: boolean;
239
255
  }
240
256
  export interface SortBy {
241
257
  column: string;
@@ -245,8 +261,10 @@ export interface API {
245
261
  ping(headers?: object): Promise<PingReturn>;
246
262
  version(headers?: object): Promise<VersionReturn>;
247
263
  runtimeStatus(headers?: object): Promise<RuntimeStatusReturn>;
264
+ clock(headers?: object): Promise<ClockReturn>;
248
265
  getSequenceContext(headers?: object): Promise<GetSequenceContextReturn>;
249
266
  getAuthToken(args: GetAuthTokenArgs, headers?: object): Promise<GetAuthTokenReturn>;
267
+ getAuthToken2(args: GetAuthToken2Args, headers?: object): Promise<GetAuthToken2Return>;
250
268
  sendPasswordlessLink(args: SendPasswordlessLinkArgs, headers?: object): Promise<SendPasswordlessLinkReturn>;
251
269
  friendList(args: FriendListArgs, headers?: object): Promise<FriendListReturn>;
252
270
  getFriendByAddress(args: GetFriendByAddressArgs, headers?: object): Promise<GetFriendByAddressReturn>;
@@ -292,10 +310,11 @@ export interface API {
292
310
  getInviteInfo(headers?: object): Promise<GetInviteInfoReturn>;
293
311
  isValidAccessCode(args: IsValidAccessCodeArgs, headers?: object): Promise<IsValidAccessCodeReturn>;
294
312
  internalClaimAccessCode(args: InternalClaimAccessCodeArgs, headers?: object): Promise<InternalClaimAccessCodeReturn>;
295
- walletRecover(args: WalletRecoverArgs, headers?: object): Promise<WalletRecoverReturn>;
296
313
  blockNumberAtTime(args: BlockNumberAtTimeArgs, headers?: object): Promise<BlockNumberAtTimeReturn>;
297
314
  paperSessionSecret(args: PaperSessionSecretArgs, headers?: object): Promise<PaperSessionSecretReturn>;
298
315
  paperSessionSecret2(args: PaperSessionSecret2Args, headers?: object): Promise<PaperSessionSecret2Return>;
316
+ linkWallet(args: LinkWalletArgs, headers?: object): Promise<LinkWalletReturn>;
317
+ getLinkedWallets(args: GetLinkedWalletsArgs, headers?: object): Promise<GetLinkedWalletsReturn>;
299
318
  }
300
319
  export interface PingArgs {
301
320
  }
@@ -312,6 +331,11 @@ export interface RuntimeStatusArgs {
312
331
  export interface RuntimeStatusReturn {
313
332
  status: RuntimeStatus;
314
333
  }
334
+ export interface ClockArgs {
335
+ }
336
+ export interface ClockReturn {
337
+ serverTime: string;
338
+ }
315
339
  export interface GetSequenceContextArgs {
316
340
  }
317
341
  export interface GetSequenceContextReturn {
@@ -327,6 +351,16 @@ export interface GetAuthTokenReturn {
327
351
  address: string;
328
352
  user?: User;
329
353
  }
354
+ export interface GetAuthToken2Args {
355
+ ewtString: string;
356
+ chainID: string;
357
+ }
358
+ export interface GetAuthToken2Return {
359
+ status: boolean;
360
+ jwtToken: string;
361
+ address: string;
362
+ user?: User;
363
+ }
330
364
  export interface SendPasswordlessLinkArgs {
331
365
  email: string;
332
366
  redirectUri: string;
@@ -336,6 +370,7 @@ export interface SendPasswordlessLinkReturn {
336
370
  status: boolean;
337
371
  }
338
372
  export interface FriendListArgs {
373
+ nickname: string;
339
374
  page?: Page;
340
375
  }
341
376
  export interface FriendListReturn {
@@ -351,6 +386,7 @@ export interface GetFriendByAddressReturn {
351
386
  }
352
387
  export interface SearchFriendsArgs {
353
388
  filterUsername: string;
389
+ page?: Page;
354
390
  }
355
391
  export interface SearchFriendsReturn {
356
392
  friends: Array<Friend>;
@@ -637,13 +673,6 @@ export interface InternalClaimAccessCodeArgs {
637
673
  export interface InternalClaimAccessCodeReturn {
638
674
  status: boolean;
639
675
  }
640
- export interface WalletRecoverArgs {
641
- username: string;
642
- secretHash: string;
643
- }
644
- export interface WalletRecoverReturn {
645
- encryptedWallet: string;
646
- }
647
676
  export interface BlockNumberAtTimeArgs {
648
677
  chainId: number;
649
678
  timestamps: Array<number>;
@@ -669,6 +698,23 @@ export interface PaperSessionSecret2Args {
669
698
  export interface PaperSessionSecret2Return {
670
699
  secret: string;
671
700
  }
701
+ export interface LinkWalletArgs {
702
+ chainId: string;
703
+ walletAddress: string;
704
+ ethAuthProofString: string;
705
+ linkedWalletMessage: string;
706
+ linkedWalletSignature: string;
707
+ }
708
+ export interface LinkWalletReturn {
709
+ status: boolean;
710
+ linkedWalletAddress: string;
711
+ }
712
+ export interface GetLinkedWalletsArgs {
713
+ walletAddress: string;
714
+ }
715
+ export interface GetLinkedWalletsReturn {
716
+ linkedWallets: Array<string>;
717
+ }
672
718
  export declare class API implements API {
673
719
  protected hostname: string;
674
720
  protected fetch: Fetch;
@@ -678,8 +724,10 @@ export declare class API implements API {
678
724
  ping: (headers?: object | undefined) => Promise<PingReturn>;
679
725
  version: (headers?: object | undefined) => Promise<VersionReturn>;
680
726
  runtimeStatus: (headers?: object | undefined) => Promise<RuntimeStatusReturn>;
727
+ clock: (headers?: object | undefined) => Promise<ClockReturn>;
681
728
  getSequenceContext: (headers?: object | undefined) => Promise<GetSequenceContextReturn>;
682
729
  getAuthToken: (args: GetAuthTokenArgs, headers?: object | undefined) => Promise<GetAuthTokenReturn>;
730
+ getAuthToken2: (args: GetAuthToken2Args, headers?: object | undefined) => Promise<GetAuthToken2Return>;
683
731
  sendPasswordlessLink: (args: SendPasswordlessLinkArgs, headers?: object | undefined) => Promise<SendPasswordlessLinkReturn>;
684
732
  friendList: (args: FriendListArgs, headers?: object | undefined) => Promise<FriendListReturn>;
685
733
  getFriendByAddress: (args: GetFriendByAddressArgs, headers?: object | undefined) => Promise<GetFriendByAddressReturn>;
@@ -725,10 +773,11 @@ export declare class API implements API {
725
773
  getInviteInfo: (headers?: object | undefined) => Promise<GetInviteInfoReturn>;
726
774
  isValidAccessCode: (args: IsValidAccessCodeArgs, headers?: object | undefined) => Promise<IsValidAccessCodeReturn>;
727
775
  internalClaimAccessCode: (args: InternalClaimAccessCodeArgs, headers?: object | undefined) => Promise<InternalClaimAccessCodeReturn>;
728
- walletRecover: (args: WalletRecoverArgs, headers?: object | undefined) => Promise<WalletRecoverReturn>;
729
776
  blockNumberAtTime: (args: BlockNumberAtTimeArgs, headers?: object | undefined) => Promise<BlockNumberAtTimeReturn>;
730
777
  paperSessionSecret: (args: PaperSessionSecretArgs, headers?: object | undefined) => Promise<PaperSessionSecretReturn>;
731
778
  paperSessionSecret2: (args: PaperSessionSecret2Args, headers?: object | undefined) => Promise<PaperSessionSecret2Return>;
779
+ linkWallet: (args: LinkWalletArgs, headers?: object | undefined) => Promise<LinkWalletReturn>;
780
+ getLinkedWallets: (args: GetLinkedWalletsArgs, headers?: object | undefined) => Promise<GetLinkedWalletsReturn>;
732
781
  }
733
782
  export interface WebRPCError extends Error {
734
783
  code: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@0xsequence/api",
3
- "version": "1.8.1",
3
+ "version": "1.8.3",
4
4
  "description": "api sub-package for Sequence",
5
5
  "repository": "https://github.com/0xsequence/sequence.js/tree/master/packages/api",
6
6
  "source": "src/index.ts",
package/src/api.gen.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  /* eslint-disable */
2
- // sequence-api v0.4.0 e4aaaf3a3c07a1f339226fcac3b8addcb3120c7b
2
+ // sequence-api v0.4.0 8c9ba9b9d3c5836bfb8eadcc78cdc2a929fcfb0d
3
3
  // --
4
- // Code generated by webrpc-gen@v0.10.x-dev with typescript@v0.10.0 generator. DO NOT EDIT.
4
+ // Code generated by webrpc-gen@v0.12.x-dev with typescript@v0.10.0 generator. DO NOT EDIT.
5
5
  //
6
6
  // webrpc-gen -schema=api.ridl -target=typescript@v0.10.0 -client -out=./clients/api.gen.ts
7
7
 
@@ -12,7 +12,7 @@ export const WebRPCVersion = 'v1'
12
12
  export const WebRPCSchemaVersion = 'v0.4.0'
13
13
 
14
14
  // Schema hash generated from your RIDL schema
15
- export const WebRPCSchemaHash = 'e4aaaf3a3c07a1f339226fcac3b8addcb3120c7b'
15
+ export const WebRPCSchemaHash = '8c9ba9b9d3c5836bfb8eadcc78cdc2a929fcfb0d'
16
16
 
17
17
  //
18
18
  // Types
@@ -50,6 +50,14 @@ export interface RuntimeStatus {
50
50
  branch: string
51
51
  commitHash: string
52
52
  checks: RuntimeChecks
53
+ numTxnsRelayed: { [key: string]: NumTxnsRelayed }
54
+ }
55
+
56
+ export interface NumTxnsRelayed {
57
+ chainID: number
58
+ prev: number
59
+ current: number
60
+ period: number
53
61
  }
54
62
 
55
63
  export interface RuntimeChecks {}
@@ -268,6 +276,13 @@ export interface PayCardAuth {
268
276
  authorization3dsUrl: string
269
277
  }
270
278
 
279
+ export interface LinkedWallet {
280
+ id: number
281
+ walletAddress: string
282
+ linkedWalletAddress: string
283
+ createdAt?: string
284
+ }
285
+
271
286
  export interface Page {
272
287
  pageSize?: number
273
288
  page?: number
@@ -276,6 +291,7 @@ export interface Page {
276
291
  before?: any
277
292
  after?: any
278
293
  sort?: Array<SortBy>
294
+ more?: boolean
279
295
  }
280
296
 
281
297
  export interface SortBy {
@@ -287,8 +303,10 @@ export interface API {
287
303
  ping(headers?: object): Promise<PingReturn>
288
304
  version(headers?: object): Promise<VersionReturn>
289
305
  runtimeStatus(headers?: object): Promise<RuntimeStatusReturn>
306
+ clock(headers?: object): Promise<ClockReturn>
290
307
  getSequenceContext(headers?: object): Promise<GetSequenceContextReturn>
291
308
  getAuthToken(args: GetAuthTokenArgs, headers?: object): Promise<GetAuthTokenReturn>
309
+ getAuthToken2(args: GetAuthToken2Args, headers?: object): Promise<GetAuthToken2Return>
292
310
  sendPasswordlessLink(args: SendPasswordlessLinkArgs, headers?: object): Promise<SendPasswordlessLinkReturn>
293
311
  friendList(args: FriendListArgs, headers?: object): Promise<FriendListReturn>
294
312
  getFriendByAddress(args: GetFriendByAddressArgs, headers?: object): Promise<GetFriendByAddressReturn>
@@ -349,10 +367,11 @@ export interface API {
349
367
  getInviteInfo(headers?: object): Promise<GetInviteInfoReturn>
350
368
  isValidAccessCode(args: IsValidAccessCodeArgs, headers?: object): Promise<IsValidAccessCodeReturn>
351
369
  internalClaimAccessCode(args: InternalClaimAccessCodeArgs, headers?: object): Promise<InternalClaimAccessCodeReturn>
352
- walletRecover(args: WalletRecoverArgs, headers?: object): Promise<WalletRecoverReturn>
353
370
  blockNumberAtTime(args: BlockNumberAtTimeArgs, headers?: object): Promise<BlockNumberAtTimeReturn>
354
371
  paperSessionSecret(args: PaperSessionSecretArgs, headers?: object): Promise<PaperSessionSecretReturn>
355
372
  paperSessionSecret2(args: PaperSessionSecret2Args, headers?: object): Promise<PaperSessionSecret2Return>
373
+ linkWallet(args: LinkWalletArgs, headers?: object): Promise<LinkWalletReturn>
374
+ getLinkedWallets(args: GetLinkedWalletsArgs, headers?: object): Promise<GetLinkedWalletsReturn>
356
375
  }
357
376
 
358
377
  export interface PingArgs {}
@@ -370,6 +389,11 @@ export interface RuntimeStatusArgs {}
370
389
  export interface RuntimeStatusReturn {
371
390
  status: RuntimeStatus
372
391
  }
392
+ export interface ClockArgs {}
393
+
394
+ export interface ClockReturn {
395
+ serverTime: string
396
+ }
373
397
  export interface GetSequenceContextArgs {}
374
398
 
375
399
  export interface GetSequenceContextReturn {
@@ -386,6 +410,17 @@ export interface GetAuthTokenReturn {
386
410
  address: string
387
411
  user?: User
388
412
  }
413
+ export interface GetAuthToken2Args {
414
+ ewtString: string
415
+ chainID: string
416
+ }
417
+
418
+ export interface GetAuthToken2Return {
419
+ status: boolean
420
+ jwtToken: string
421
+ address: string
422
+ user?: User
423
+ }
389
424
  export interface SendPasswordlessLinkArgs {
390
425
  email: string
391
426
  redirectUri: string
@@ -396,6 +431,7 @@ export interface SendPasswordlessLinkReturn {
396
431
  status: boolean
397
432
  }
398
433
  export interface FriendListArgs {
434
+ nickname: string
399
435
  page?: Page
400
436
  }
401
437
 
@@ -413,6 +449,7 @@ export interface GetFriendByAddressReturn {
413
449
  }
414
450
  export interface SearchFriendsArgs {
415
451
  filterUsername: string
452
+ page?: Page
416
453
  }
417
454
 
418
455
  export interface SearchFriendsReturn {
@@ -736,14 +773,6 @@ export interface InternalClaimAccessCodeArgs {
736
773
  export interface InternalClaimAccessCodeReturn {
737
774
  status: boolean
738
775
  }
739
- export interface WalletRecoverArgs {
740
- username: string
741
- secretHash: string
742
- }
743
-
744
- export interface WalletRecoverReturn {
745
- encryptedWallet: string
746
- }
747
776
  export interface BlockNumberAtTimeArgs {
748
777
  chainId: number
749
778
  timestamps: Array<number>
@@ -772,6 +801,25 @@ export interface PaperSessionSecret2Args {
772
801
  export interface PaperSessionSecret2Return {
773
802
  secret: string
774
803
  }
804
+ export interface LinkWalletArgs {
805
+ chainId: string
806
+ walletAddress: string
807
+ ethAuthProofString: string
808
+ linkedWalletMessage: string
809
+ linkedWalletSignature: string
810
+ }
811
+
812
+ export interface LinkWalletReturn {
813
+ status: boolean
814
+ linkedWalletAddress: string
815
+ }
816
+ export interface GetLinkedWalletsArgs {
817
+ walletAddress: string
818
+ }
819
+
820
+ export interface GetLinkedWalletsReturn {
821
+ linkedWallets: Array<string>
822
+ }
775
823
 
776
824
  //
777
825
  // Client
@@ -820,6 +868,16 @@ export class API implements API {
820
868
  })
821
869
  }
822
870
 
871
+ clock = (headers?: object): Promise<ClockReturn> => {
872
+ return this.fetch(this.url('Clock'), createHTTPRequest({}, headers)).then(res => {
873
+ return buildResponse(res).then(_data => {
874
+ return {
875
+ serverTime: <string>_data.serverTime
876
+ }
877
+ })
878
+ })
879
+ }
880
+
823
881
  getSequenceContext = (headers?: object): Promise<GetSequenceContextReturn> => {
824
882
  return this.fetch(this.url('GetSequenceContext'), createHTTPRequest({}, headers)).then(res => {
825
883
  return buildResponse(res).then(_data => {
@@ -843,6 +901,19 @@ export class API implements API {
843
901
  })
844
902
  }
845
903
 
904
+ getAuthToken2 = (args: GetAuthToken2Args, headers?: object): Promise<GetAuthToken2Return> => {
905
+ return this.fetch(this.url('GetAuthToken2'), createHTTPRequest(args, headers)).then(res => {
906
+ return buildResponse(res).then(_data => {
907
+ return {
908
+ status: <boolean>_data.status,
909
+ jwtToken: <string>_data.jwtToken,
910
+ address: <string>_data.address,
911
+ user: <User>_data.user
912
+ }
913
+ })
914
+ })
915
+ }
916
+
846
917
  sendPasswordlessLink = (args: SendPasswordlessLinkArgs, headers?: object): Promise<SendPasswordlessLinkReturn> => {
847
918
  return this.fetch(this.url('SendPasswordlessLink'), createHTTPRequest(args, headers)).then(res => {
848
919
  return buildResponse(res).then(_data => {
@@ -1325,16 +1396,6 @@ export class API implements API {
1325
1396
  })
1326
1397
  }
1327
1398
 
1328
- walletRecover = (args: WalletRecoverArgs, headers?: object): Promise<WalletRecoverReturn> => {
1329
- return this.fetch(this.url('WalletRecover'), createHTTPRequest(args, headers)).then(res => {
1330
- return buildResponse(res).then(_data => {
1331
- return {
1332
- encryptedWallet: <string>_data.encryptedWallet
1333
- }
1334
- })
1335
- })
1336
- }
1337
-
1338
1399
  blockNumberAtTime = (args: BlockNumberAtTimeArgs, headers?: object): Promise<BlockNumberAtTimeReturn> => {
1339
1400
  return this.fetch(this.url('BlockNumberAtTime'), createHTTPRequest(args, headers)).then(res => {
1340
1401
  return buildResponse(res).then(_data => {
@@ -1364,6 +1425,27 @@ export class API implements API {
1364
1425
  })
1365
1426
  })
1366
1427
  }
1428
+
1429
+ linkWallet = (args: LinkWalletArgs, headers?: object): Promise<LinkWalletReturn> => {
1430
+ return this.fetch(this.url('LinkWallet'), createHTTPRequest(args, headers)).then(res => {
1431
+ return buildResponse(res).then(_data => {
1432
+ return {
1433
+ status: <boolean>_data.status,
1434
+ linkedWalletAddress: <string>_data.linkedWalletAddress
1435
+ }
1436
+ })
1437
+ })
1438
+ }
1439
+
1440
+ getLinkedWallets = (args: GetLinkedWalletsArgs, headers?: object): Promise<GetLinkedWalletsReturn> => {
1441
+ return this.fetch(this.url('GetLinkedWallets'), createHTTPRequest(args, headers)).then(res => {
1442
+ return buildResponse(res).then(_data => {
1443
+ return {
1444
+ linkedWallets: <Array<string>>_data.linkedWallets
1445
+ }
1446
+ })
1447
+ })
1448
+ }
1367
1449
  }
1368
1450
 
1369
1451
  export interface WebRPCError extends Error {