@privy-io/api-types 0.3.4 → 0.5.0
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/CHANGELOG.md +82 -0
- package/LICENSE +1 -1
- package/README.md +31 -0
- package/client.d.mts +21 -11
- package/client.d.mts.map +1 -1
- package/client.d.ts +21 -11
- package/client.d.ts.map +1 -1
- package/client.js +20 -3
- package/client.js.map +1 -1
- package/client.mjs +20 -3
- package/client.mjs.map +1 -1
- package/internal/parse.d.mts.map +1 -1
- package/internal/parse.d.ts.map +1 -1
- package/internal/parse.js +5 -0
- package/internal/parse.js.map +1 -1
- package/internal/parse.mjs +5 -0
- package/internal/parse.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/aggregations.d.mts +507 -0
- package/resources/aggregations.d.mts.map +1 -0
- package/resources/aggregations.d.ts +507 -0
- package/resources/aggregations.d.ts.map +1 -0
- package/resources/aggregations.js +9 -0
- package/resources/aggregations.js.map +1 -0
- package/resources/aggregations.mjs +5 -0
- package/resources/aggregations.mjs.map +1 -0
- package/resources/client-auth.d.mts +183 -24
- package/resources/client-auth.d.mts.map +1 -1
- package/resources/client-auth.d.ts +183 -24
- package/resources/client-auth.d.ts.map +1 -1
- package/resources/funding.d.mts +4 -4
- package/resources/funding.d.mts.map +1 -1
- package/resources/funding.d.ts +4 -4
- package/resources/funding.d.ts.map +1 -1
- package/resources/index.d.mts +7 -4
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +7 -4
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +7 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +3 -0
- package/resources/index.mjs.map +1 -1
- package/resources/key-quorums.d.mts +4 -1
- package/resources/key-quorums.d.mts.map +1 -1
- package/resources/key-quorums.d.ts +4 -1
- package/resources/key-quorums.d.ts.map +1 -1
- package/resources/policies.d.mts +89 -135
- package/resources/policies.d.mts.map +1 -1
- package/resources/policies.d.ts +89 -135
- package/resources/policies.d.ts.map +1 -1
- package/resources/policies.js.map +1 -1
- package/resources/policies.mjs.map +1 -1
- package/resources/users.d.mts +679 -415
- package/resources/users.d.mts.map +1 -1
- package/resources/users.d.ts +679 -415
- package/resources/users.d.ts.map +1 -1
- package/resources/wallets/balance.d.mts +11 -6
- package/resources/wallets/balance.d.mts.map +1 -1
- package/resources/wallets/balance.d.ts +11 -6
- package/resources/wallets/balance.d.ts.map +1 -1
- package/resources/wallets/balance.js +1 -2
- package/resources/wallets/balance.js.map +1 -1
- package/resources/wallets/balance.mjs +1 -2
- package/resources/wallets/balance.mjs.map +1 -1
- package/resources/wallets/index.d.mts +1 -1
- package/resources/wallets/index.d.mts.map +1 -1
- package/resources/wallets/index.d.ts +1 -1
- package/resources/wallets/index.d.ts.map +1 -1
- package/resources/wallets/index.js.map +1 -1
- package/resources/wallets/index.mjs.map +1 -1
- package/resources/wallets/transactions.d.mts +3 -3
- package/resources/wallets/transactions.d.mts.map +1 -1
- package/resources/wallets/transactions.d.ts +3 -3
- package/resources/wallets/transactions.d.ts.map +1 -1
- package/resources/wallets/wallets.d.mts +347 -65
- package/resources/wallets/wallets.d.mts.map +1 -1
- package/resources/wallets/wallets.d.ts +347 -65
- package/resources/wallets/wallets.d.ts.map +1 -1
- package/resources/wallets/wallets.js +1 -1
- package/resources/wallets/wallets.js.map +1 -1
- package/resources/wallets/wallets.mjs +1 -1
- package/resources/wallets/wallets.mjs.map +1 -1
- package/resources/webhooks.d.mts +940 -0
- package/resources/webhooks.d.mts.map +1 -0
- package/resources/webhooks.d.ts +940 -0
- package/resources/webhooks.d.ts.map +1 -0
- package/resources/webhooks.js +9 -0
- package/resources/webhooks.js.map +1 -0
- package/resources/webhooks.mjs +5 -0
- package/resources/webhooks.mjs.map +1 -0
- package/resources/yield.d.mts +264 -0
- package/resources/yield.d.mts.map +1 -0
- package/resources/yield.d.ts +264 -0
- package/resources/yield.d.ts.map +1 -0
- package/resources/yield.js +9 -0
- package/resources/yield.js.map +1 -0
- package/resources/yield.mjs +5 -0
- package/resources/yield.mjs.map +1 -0
- package/src/client.ts +331 -16
- package/src/internal/parse.ts +6 -0
- package/src/resources/aggregations.ts +853 -0
- package/src/resources/client-auth.ts +309 -35
- package/src/resources/funding.ts +4 -1
- package/src/resources/index.ts +156 -9
- package/src/resources/key-quorums.ts +4 -1
- package/src/resources/policies.ts +129 -214
- package/src/resources/users.ts +974 -650
- package/src/resources/wallets/balance.ts +24 -6
- package/src/resources/wallets/index.ts +13 -3
- package/src/resources/wallets/transactions.ts +11 -3
- package/src/resources/wallets/wallets.ts +468 -91
- package/src/resources/webhooks.ts +1287 -0
- package/src/resources/yield.ts +330 -0
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -17,7 +17,7 @@ export class Wallets extends APIResource {
|
|
|
17
17
|
balance: BalanceAPI.Balance = new BalanceAPI.Balance(this._client);
|
|
18
18
|
|
|
19
19
|
/**
|
|
20
|
-
*
|
|
20
|
+
* Creates a new wallet on the requested chain and for the requested owner.
|
|
21
21
|
*
|
|
22
22
|
* @example
|
|
23
23
|
* ```ts
|
|
@@ -270,6 +270,13 @@ export class Wallets extends APIResource {
|
|
|
270
270
|
|
|
271
271
|
export type WalletsCursor = Cursor<Wallet>;
|
|
272
272
|
|
|
273
|
+
/**
|
|
274
|
+
* The response body from revoking a wallet delegation.
|
|
275
|
+
*/
|
|
276
|
+
export interface WalletRevokeResponse {
|
|
277
|
+
message: string;
|
|
278
|
+
}
|
|
279
|
+
|
|
273
280
|
/**
|
|
274
281
|
* The wallet chain types that support curve-based signing.
|
|
275
282
|
*/
|
|
@@ -285,11 +292,171 @@ export type CurveSigningChainType =
|
|
|
285
292
|
| 'ton'
|
|
286
293
|
| 'starknet';
|
|
287
294
|
|
|
295
|
+
/**
|
|
296
|
+
* The wallet chain types that are not first class chains.
|
|
297
|
+
*/
|
|
298
|
+
export type ExtendedChainType =
|
|
299
|
+
| 'cosmos'
|
|
300
|
+
| 'stellar'
|
|
301
|
+
| 'sui'
|
|
302
|
+
| 'aptos'
|
|
303
|
+
| 'movement'
|
|
304
|
+
| 'tron'
|
|
305
|
+
| 'bitcoin-segwit'
|
|
306
|
+
| 'near'
|
|
307
|
+
| 'ton'
|
|
308
|
+
| 'starknet'
|
|
309
|
+
| 'spark';
|
|
310
|
+
|
|
288
311
|
/**
|
|
289
312
|
* The wallet chain types that offer first class support.
|
|
290
313
|
*/
|
|
291
314
|
export type FirstClassChainType = 'ethereum' | 'solana';
|
|
292
315
|
|
|
316
|
+
/**
|
|
317
|
+
* The wallet chain types.
|
|
318
|
+
*/
|
|
319
|
+
export type WalletChainType =
|
|
320
|
+
| 'ethereum'
|
|
321
|
+
| 'solana'
|
|
322
|
+
| 'cosmos'
|
|
323
|
+
| 'stellar'
|
|
324
|
+
| 'sui'
|
|
325
|
+
| 'aptos'
|
|
326
|
+
| 'movement'
|
|
327
|
+
| 'tron'
|
|
328
|
+
| 'bitcoin-segwit'
|
|
329
|
+
| 'near'
|
|
330
|
+
| 'ton'
|
|
331
|
+
| 'starknet'
|
|
332
|
+
| 'spark';
|
|
333
|
+
|
|
334
|
+
/**
|
|
335
|
+
* Information about the custodian managing this wallet.
|
|
336
|
+
*/
|
|
337
|
+
export interface WalletCustodian {
|
|
338
|
+
name: string;
|
|
339
|
+
}
|
|
340
|
+
|
|
341
|
+
/**
|
|
342
|
+
* The provider of the custodial wallet.
|
|
343
|
+
*/
|
|
344
|
+
export type CustodialWalletProvider = 'bridge';
|
|
345
|
+
|
|
346
|
+
/**
|
|
347
|
+
* The chain type of the custodial wallet.
|
|
348
|
+
*/
|
|
349
|
+
export type CustodialWalletChainType = 'ethereum';
|
|
350
|
+
|
|
351
|
+
/**
|
|
352
|
+
* The input for creating a custodial wallet.
|
|
353
|
+
*/
|
|
354
|
+
export interface CustodialWalletCreateInput {
|
|
355
|
+
/**
|
|
356
|
+
* The chain type of the custodial wallet.
|
|
357
|
+
*/
|
|
358
|
+
chain_type: CustodialWalletChainType;
|
|
359
|
+
|
|
360
|
+
/**
|
|
361
|
+
* The provider of the custodial wallet.
|
|
362
|
+
*/
|
|
363
|
+
provider: CustodialWalletProvider;
|
|
364
|
+
|
|
365
|
+
/**
|
|
366
|
+
* The resource ID of the beneficiary of the custodial wallet, given by the
|
|
367
|
+
* licensing provider.
|
|
368
|
+
*/
|
|
369
|
+
provider_user_id: string;
|
|
370
|
+
|
|
371
|
+
additional_signers?: Array<CustodialWalletCreateInput.AdditionalSigner>;
|
|
372
|
+
|
|
373
|
+
owner?: CustodialWalletCreateInput.UserID | CustodialWalletCreateInput.PublicKey | null;
|
|
374
|
+
|
|
375
|
+
policy_ids?: Array<string>;
|
|
376
|
+
}
|
|
377
|
+
|
|
378
|
+
export namespace CustodialWalletCreateInput {
|
|
379
|
+
export interface AdditionalSigner {
|
|
380
|
+
signer_id: string;
|
|
381
|
+
|
|
382
|
+
override_policy_ids?: Array<string>;
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
export interface UserID {
|
|
386
|
+
user_id: string;
|
|
387
|
+
}
|
|
388
|
+
|
|
389
|
+
export interface PublicKey {
|
|
390
|
+
public_key: string;
|
|
391
|
+
}
|
|
392
|
+
}
|
|
393
|
+
|
|
394
|
+
/**
|
|
395
|
+
* Information about a custodial wallet.
|
|
396
|
+
*/
|
|
397
|
+
export interface CustodialWallet {
|
|
398
|
+
id: string;
|
|
399
|
+
|
|
400
|
+
address: string;
|
|
401
|
+
|
|
402
|
+
/**
|
|
403
|
+
* The chain type of the custodial wallet.
|
|
404
|
+
*/
|
|
405
|
+
chain_type: CustodialWalletChainType;
|
|
406
|
+
|
|
407
|
+
owner_id: string | null;
|
|
408
|
+
|
|
409
|
+
/**
|
|
410
|
+
* The provider of the custodial wallet.
|
|
411
|
+
*/
|
|
412
|
+
provider: CustodialWalletProvider;
|
|
413
|
+
|
|
414
|
+
additional_signers?: Array<CustodialWallet.AdditionalSigner>;
|
|
415
|
+
|
|
416
|
+
policy_ids?: Array<string>;
|
|
417
|
+
}
|
|
418
|
+
|
|
419
|
+
export namespace CustodialWallet {
|
|
420
|
+
export interface AdditionalSigner {
|
|
421
|
+
signer_id: string;
|
|
422
|
+
|
|
423
|
+
override_policy_ids?: Array<string>;
|
|
424
|
+
}
|
|
425
|
+
}
|
|
426
|
+
|
|
427
|
+
/**
|
|
428
|
+
* Optional HPKE configuration for wallet import decryption. These parameters allow
|
|
429
|
+
* importing wallets encrypted by external providers that use different HPKE
|
|
430
|
+
* configurations.
|
|
431
|
+
*/
|
|
432
|
+
export interface HpkeImportConfig {
|
|
433
|
+
/**
|
|
434
|
+
* Additional Authenticated Data (AAD) used during encryption. Should be
|
|
435
|
+
* base64-encoded bytes.
|
|
436
|
+
*/
|
|
437
|
+
aad?: string;
|
|
438
|
+
|
|
439
|
+
/**
|
|
440
|
+
* The AEAD algorithm used for encryption. Defaults to CHACHA20_POLY1305 if not
|
|
441
|
+
* specified.
|
|
442
|
+
*/
|
|
443
|
+
aead_algorithm?: 'CHACHA20_POLY1305' | 'AES_GCM256';
|
|
444
|
+
|
|
445
|
+
/**
|
|
446
|
+
* Application-specific context information (INFO) used during HPKE encryption.
|
|
447
|
+
* Should be base64-encoded bytes.
|
|
448
|
+
*/
|
|
449
|
+
info?: string;
|
|
450
|
+
}
|
|
451
|
+
|
|
452
|
+
/**
|
|
453
|
+
* SUI transaction commands allowlist for raw_sign endpoint policy evaluation
|
|
454
|
+
*/
|
|
455
|
+
export type SuiCommandName = 'TransferObjects' | 'SplitCoins' | 'MergeCoins';
|
|
456
|
+
|
|
457
|
+
/**
|
|
458
|
+
* A wallet managed by Privy's wallet infrastructure.
|
|
459
|
+
*/
|
|
293
460
|
export interface Wallet {
|
|
294
461
|
/**
|
|
295
462
|
* Unique ID of the wallet. This will be the primary identifier when using the
|
|
@@ -359,51 +526,136 @@ export namespace Wallet {
|
|
|
359
526
|
}
|
|
360
527
|
|
|
361
528
|
/**
|
|
362
|
-
*
|
|
529
|
+
* Input for a single wallet in a batch creation request.
|
|
363
530
|
*/
|
|
364
|
-
export
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
531
|
+
export interface WalletBatchItemInput {
|
|
532
|
+
/**
|
|
533
|
+
* The wallet chain types.
|
|
534
|
+
*/
|
|
535
|
+
chain_type: WalletChainType;
|
|
536
|
+
|
|
537
|
+
/**
|
|
538
|
+
* Additional signers for the wallet.
|
|
539
|
+
*/
|
|
540
|
+
additional_signers?: Array<WalletBatchItemInput.AdditionalSigner>;
|
|
541
|
+
|
|
542
|
+
/**
|
|
543
|
+
* The owner of the resource. If you provide this, do not specify an owner_id as it
|
|
544
|
+
* will be generated automatically. When updating a wallet, you can set the owner
|
|
545
|
+
* to null to remove the owner.
|
|
546
|
+
*/
|
|
547
|
+
owner?: WalletBatchItemInput.PublicKeyOwner | WalletBatchItemInput.UserOwner | null;
|
|
548
|
+
|
|
549
|
+
/**
|
|
550
|
+
* The key quorum ID to set as the owner of the resource. If you provide this, do
|
|
551
|
+
* not specify an owner.
|
|
552
|
+
*/
|
|
553
|
+
owner_id?: string;
|
|
554
|
+
|
|
555
|
+
/**
|
|
556
|
+
* List of policy IDs for policies that should be enforced on the wallet.
|
|
557
|
+
* Currently, only one policy is supported per wallet.
|
|
558
|
+
*/
|
|
559
|
+
policy_ids?: Array<string>;
|
|
560
|
+
}
|
|
561
|
+
|
|
562
|
+
export namespace WalletBatchItemInput {
|
|
563
|
+
export interface AdditionalSigner {
|
|
564
|
+
signer_id: string;
|
|
565
|
+
|
|
566
|
+
/**
|
|
567
|
+
* The array of policy IDs that will be applied to wallet requests. If specified,
|
|
568
|
+
* this will override the base policy IDs set on the wallet.
|
|
569
|
+
*/
|
|
570
|
+
override_policy_ids?: Array<string>;
|
|
571
|
+
}
|
|
572
|
+
|
|
573
|
+
/**
|
|
574
|
+
* The P-256 public key of the owner of the resource, in base64-encoded DER format.
|
|
575
|
+
* If you provide this, do not specify an owner_id as it will be generated
|
|
576
|
+
* automatically.
|
|
577
|
+
*/
|
|
578
|
+
export interface PublicKeyOwner {
|
|
579
|
+
public_key: string;
|
|
580
|
+
}
|
|
581
|
+
|
|
582
|
+
/**
|
|
583
|
+
* The user ID of the owner of the resource. The user must already exist, and this
|
|
584
|
+
* value must start with "did:privy:". If you provide this, do not specify an
|
|
585
|
+
* owner_id as it will be generated automatically.
|
|
586
|
+
*/
|
|
587
|
+
export interface UserOwner {
|
|
588
|
+
user_id: string;
|
|
589
|
+
}
|
|
590
|
+
}
|
|
378
591
|
|
|
379
592
|
/**
|
|
380
|
-
*
|
|
593
|
+
* Request body for batch wallet creation.
|
|
381
594
|
*/
|
|
382
|
-
export interface
|
|
383
|
-
|
|
595
|
+
export interface WalletBatchCreateInput {
|
|
596
|
+
/**
|
|
597
|
+
* Array of wallet creation requests. Minimum 1, maximum 100.
|
|
598
|
+
*/
|
|
599
|
+
wallets: Array<WalletBatchItemInput>;
|
|
384
600
|
}
|
|
385
601
|
|
|
386
602
|
/**
|
|
387
|
-
*
|
|
603
|
+
* A single result from a batch wallet creation operation.
|
|
388
604
|
*/
|
|
389
|
-
export type
|
|
390
|
-
|
|
|
391
|
-
|
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
605
|
+
export type WalletBatchCreateResult =
|
|
606
|
+
| WalletBatchCreateResult.WalletBatchCreateSuccess
|
|
607
|
+
| WalletBatchCreateResult.WalletBatchCreateFailure;
|
|
608
|
+
|
|
609
|
+
export namespace WalletBatchCreateResult {
|
|
610
|
+
/**
|
|
611
|
+
* A successful wallet creation result within a batch operation.
|
|
612
|
+
*/
|
|
613
|
+
export interface WalletBatchCreateSuccess {
|
|
614
|
+
/**
|
|
615
|
+
* The index of the wallet in the original request array.
|
|
616
|
+
*/
|
|
617
|
+
index: number;
|
|
618
|
+
|
|
619
|
+
success: true;
|
|
620
|
+
|
|
621
|
+
/**
|
|
622
|
+
* A wallet managed by Privy's wallet infrastructure.
|
|
623
|
+
*/
|
|
624
|
+
wallet: WalletsAPI.Wallet;
|
|
625
|
+
}
|
|
626
|
+
|
|
627
|
+
/**
|
|
628
|
+
* A failed wallet creation result within a batch operation.
|
|
629
|
+
*/
|
|
630
|
+
export interface WalletBatchCreateFailure {
|
|
631
|
+
/**
|
|
632
|
+
* A PrivyErrorCode string identifying the error type (e.g., "invalid_data",
|
|
633
|
+
* "resource_conflict").
|
|
634
|
+
*/
|
|
635
|
+
code: string;
|
|
636
|
+
|
|
637
|
+
/**
|
|
638
|
+
* A human-readable error message with details about what went wrong.
|
|
639
|
+
*/
|
|
640
|
+
error: string;
|
|
641
|
+
|
|
642
|
+
/**
|
|
643
|
+
* The index of the wallet in the original request array.
|
|
644
|
+
*/
|
|
645
|
+
index: number;
|
|
646
|
+
|
|
647
|
+
success: false;
|
|
648
|
+
}
|
|
649
|
+
}
|
|
401
650
|
|
|
402
651
|
/**
|
|
403
|
-
*
|
|
652
|
+
* Response for a batch wallet creation request.
|
|
404
653
|
*/
|
|
405
|
-
export interface
|
|
406
|
-
|
|
654
|
+
export interface WalletBatchCreateResponse {
|
|
655
|
+
/**
|
|
656
|
+
* Array of results for each wallet creation request, in the same order as input.
|
|
657
|
+
*/
|
|
658
|
+
results: Array<WalletBatchCreateResult>;
|
|
407
659
|
}
|
|
408
660
|
|
|
409
661
|
/**
|
|
@@ -447,6 +699,8 @@ export namespace EthereumSignTransactionRpcInput {
|
|
|
447
699
|
|
|
448
700
|
export namespace Params {
|
|
449
701
|
export interface Transaction {
|
|
702
|
+
authorization_list?: Array<Transaction.AuthorizationList>;
|
|
703
|
+
|
|
450
704
|
chain_id?: string | number;
|
|
451
705
|
|
|
452
706
|
data?: string;
|
|
@@ -465,10 +719,26 @@ export namespace EthereumSignTransactionRpcInput {
|
|
|
465
719
|
|
|
466
720
|
to?: string;
|
|
467
721
|
|
|
468
|
-
type?: 0 | 1 | 2;
|
|
722
|
+
type?: 0 | 1 | 2 | 4;
|
|
469
723
|
|
|
470
724
|
value?: string | number;
|
|
471
725
|
}
|
|
726
|
+
|
|
727
|
+
export namespace Transaction {
|
|
728
|
+
export interface AuthorizationList {
|
|
729
|
+
chain_id: string | number;
|
|
730
|
+
|
|
731
|
+
contract: string;
|
|
732
|
+
|
|
733
|
+
nonce: string | number;
|
|
734
|
+
|
|
735
|
+
r: string;
|
|
736
|
+
|
|
737
|
+
s: string;
|
|
738
|
+
|
|
739
|
+
y_parity: number;
|
|
740
|
+
}
|
|
741
|
+
}
|
|
472
742
|
}
|
|
473
743
|
}
|
|
474
744
|
|
|
@@ -496,6 +766,8 @@ export namespace EthereumSendTransactionRpcInput {
|
|
|
496
766
|
|
|
497
767
|
export namespace Params {
|
|
498
768
|
export interface Transaction {
|
|
769
|
+
authorization_list?: Array<Transaction.AuthorizationList>;
|
|
770
|
+
|
|
499
771
|
chain_id?: string | number;
|
|
500
772
|
|
|
501
773
|
data?: string;
|
|
@@ -514,10 +786,26 @@ export namespace EthereumSendTransactionRpcInput {
|
|
|
514
786
|
|
|
515
787
|
to?: string;
|
|
516
788
|
|
|
517
|
-
type?: 0 | 1 | 2;
|
|
789
|
+
type?: 0 | 1 | 2 | 4;
|
|
518
790
|
|
|
519
791
|
value?: string | number;
|
|
520
792
|
}
|
|
793
|
+
|
|
794
|
+
export namespace Transaction {
|
|
795
|
+
export interface AuthorizationList {
|
|
796
|
+
chain_id: string | number;
|
|
797
|
+
|
|
798
|
+
contract: string;
|
|
799
|
+
|
|
800
|
+
nonce: string | number;
|
|
801
|
+
|
|
802
|
+
r: string;
|
|
803
|
+
|
|
804
|
+
s: string;
|
|
805
|
+
|
|
806
|
+
y_parity: number;
|
|
807
|
+
}
|
|
808
|
+
}
|
|
521
809
|
}
|
|
522
810
|
}
|
|
523
811
|
|
|
@@ -757,10 +1045,14 @@ export namespace EthereumSendTransactionRpcResponse {
|
|
|
757
1045
|
transaction_id?: string;
|
|
758
1046
|
|
|
759
1047
|
transaction_request?: Data.TransactionRequest;
|
|
1048
|
+
|
|
1049
|
+
user_operation_hash?: string;
|
|
760
1050
|
}
|
|
761
1051
|
|
|
762
1052
|
export namespace Data {
|
|
763
1053
|
export interface TransactionRequest {
|
|
1054
|
+
authorization_list?: Array<TransactionRequest.AuthorizationList>;
|
|
1055
|
+
|
|
764
1056
|
chain_id?: string | number;
|
|
765
1057
|
|
|
766
1058
|
data?: string;
|
|
@@ -779,10 +1071,26 @@ export namespace EthereumSendTransactionRpcResponse {
|
|
|
779
1071
|
|
|
780
1072
|
to?: string;
|
|
781
1073
|
|
|
782
|
-
type?: 0 | 1 | 2;
|
|
1074
|
+
type?: 0 | 1 | 2 | 4;
|
|
783
1075
|
|
|
784
1076
|
value?: string | number;
|
|
785
1077
|
}
|
|
1078
|
+
|
|
1079
|
+
export namespace TransactionRequest {
|
|
1080
|
+
export interface AuthorizationList {
|
|
1081
|
+
chain_id: string | number;
|
|
1082
|
+
|
|
1083
|
+
contract: string;
|
|
1084
|
+
|
|
1085
|
+
nonce: string | number;
|
|
1086
|
+
|
|
1087
|
+
r: string;
|
|
1088
|
+
|
|
1089
|
+
s: string;
|
|
1090
|
+
|
|
1091
|
+
y_parity: number;
|
|
1092
|
+
}
|
|
1093
|
+
}
|
|
786
1094
|
}
|
|
787
1095
|
}
|
|
788
1096
|
|
|
@@ -1135,11 +1443,21 @@ export namespace WalletCreateParams {
|
|
|
1135
1443
|
}
|
|
1136
1444
|
|
|
1137
1445
|
export interface WalletListParams extends CursorParams {
|
|
1446
|
+
/**
|
|
1447
|
+
* Filter wallets by authorization public key. Returns wallets owned by key quorums
|
|
1448
|
+
* that include the specified P-256 public key (base64-encoded DER format). Cannot
|
|
1449
|
+
* be used together with user_id.
|
|
1450
|
+
*/
|
|
1451
|
+
authorization_key?: string;
|
|
1452
|
+
|
|
1138
1453
|
/**
|
|
1139
1454
|
* The wallet chain types.
|
|
1140
1455
|
*/
|
|
1141
1456
|
chain_type?: WalletChainType;
|
|
1142
1457
|
|
|
1458
|
+
/**
|
|
1459
|
+
* Filter wallets by user ID. Cannot be used together with authorization_key.
|
|
1460
|
+
*/
|
|
1143
1461
|
user_id?: string;
|
|
1144
1462
|
}
|
|
1145
1463
|
|
|
@@ -1259,12 +1577,12 @@ export namespace WalletRawSignParams {
|
|
|
1259
1577
|
/**
|
|
1260
1578
|
* The encoding scheme for the bytes.
|
|
1261
1579
|
*/
|
|
1262
|
-
encoding: 'utf-8' | 'hex';
|
|
1580
|
+
encoding: 'utf-8' | 'hex' | 'base64';
|
|
1263
1581
|
|
|
1264
1582
|
/**
|
|
1265
1583
|
* The hash function to hash the bytes.
|
|
1266
1584
|
*/
|
|
1267
|
-
hash_function: 'keccak256' | 'sha256';
|
|
1585
|
+
hash_function: 'keccak256' | 'sha256' | 'blake2b256';
|
|
1268
1586
|
}
|
|
1269
1587
|
}
|
|
1270
1588
|
|
|
@@ -1283,22 +1601,22 @@ export type WalletRpcParams =
|
|
|
1283
1601
|
export declare namespace WalletRpcParams {
|
|
1284
1602
|
export interface EthereumPersonalSignRpcInput {
|
|
1285
1603
|
/**
|
|
1286
|
-
* Body param
|
|
1604
|
+
* Body param
|
|
1287
1605
|
*/
|
|
1288
1606
|
method: 'personal_sign';
|
|
1289
1607
|
|
|
1290
1608
|
/**
|
|
1291
|
-
* Body param
|
|
1609
|
+
* Body param
|
|
1292
1610
|
*/
|
|
1293
1611
|
params: EthereumPersonalSignRpcInput.Params;
|
|
1294
1612
|
|
|
1295
1613
|
/**
|
|
1296
|
-
* Body param
|
|
1614
|
+
* Body param
|
|
1297
1615
|
*/
|
|
1298
1616
|
address?: string;
|
|
1299
1617
|
|
|
1300
1618
|
/**
|
|
1301
|
-
* Body param
|
|
1619
|
+
* Body param
|
|
1302
1620
|
*/
|
|
1303
1621
|
chain_type?: 'ethereum';
|
|
1304
1622
|
|
|
@@ -1325,22 +1643,22 @@ export declare namespace WalletRpcParams {
|
|
|
1325
1643
|
|
|
1326
1644
|
export interface EthereumSignTypedDataRpcInput {
|
|
1327
1645
|
/**
|
|
1328
|
-
* Body param
|
|
1646
|
+
* Body param
|
|
1329
1647
|
*/
|
|
1330
1648
|
method: 'eth_signTypedData_v4';
|
|
1331
1649
|
|
|
1332
1650
|
/**
|
|
1333
|
-
* Body param
|
|
1651
|
+
* Body param
|
|
1334
1652
|
*/
|
|
1335
1653
|
params: EthereumSignTypedDataRpcInput.Params;
|
|
1336
1654
|
|
|
1337
1655
|
/**
|
|
1338
|
-
* Body param
|
|
1656
|
+
* Body param
|
|
1339
1657
|
*/
|
|
1340
1658
|
address?: string;
|
|
1341
1659
|
|
|
1342
1660
|
/**
|
|
1343
|
-
* Body param
|
|
1661
|
+
* Body param
|
|
1344
1662
|
*/
|
|
1345
1663
|
chain_type?: 'ethereum';
|
|
1346
1664
|
|
|
@@ -1385,22 +1703,22 @@ export declare namespace WalletRpcParams {
|
|
|
1385
1703
|
|
|
1386
1704
|
export interface EthereumSignTransactionRpcInput {
|
|
1387
1705
|
/**
|
|
1388
|
-
* Body param
|
|
1706
|
+
* Body param
|
|
1389
1707
|
*/
|
|
1390
1708
|
method: 'eth_signTransaction';
|
|
1391
1709
|
|
|
1392
1710
|
/**
|
|
1393
|
-
* Body param
|
|
1711
|
+
* Body param
|
|
1394
1712
|
*/
|
|
1395
1713
|
params: EthereumSignTransactionRpcInput.Params;
|
|
1396
1714
|
|
|
1397
1715
|
/**
|
|
1398
|
-
* Body param
|
|
1716
|
+
* Body param
|
|
1399
1717
|
*/
|
|
1400
1718
|
address?: string;
|
|
1401
1719
|
|
|
1402
1720
|
/**
|
|
1403
|
-
* Body param
|
|
1721
|
+
* Body param
|
|
1404
1722
|
*/
|
|
1405
1723
|
chain_type?: 'ethereum';
|
|
1406
1724
|
|
|
@@ -1424,6 +1742,8 @@ export declare namespace WalletRpcParams {
|
|
|
1424
1742
|
|
|
1425
1743
|
export namespace Params {
|
|
1426
1744
|
export interface Transaction {
|
|
1745
|
+
authorization_list?: Array<Transaction.AuthorizationList>;
|
|
1746
|
+
|
|
1427
1747
|
chain_id?: string | number;
|
|
1428
1748
|
|
|
1429
1749
|
data?: string;
|
|
@@ -1442,31 +1762,47 @@ export declare namespace WalletRpcParams {
|
|
|
1442
1762
|
|
|
1443
1763
|
to?: string;
|
|
1444
1764
|
|
|
1445
|
-
type?: 0 | 1 | 2;
|
|
1765
|
+
type?: 0 | 1 | 2 | 4;
|
|
1446
1766
|
|
|
1447
1767
|
value?: string | number;
|
|
1448
1768
|
}
|
|
1769
|
+
|
|
1770
|
+
export namespace Transaction {
|
|
1771
|
+
export interface AuthorizationList {
|
|
1772
|
+
chain_id: string | number;
|
|
1773
|
+
|
|
1774
|
+
contract: string;
|
|
1775
|
+
|
|
1776
|
+
nonce: string | number;
|
|
1777
|
+
|
|
1778
|
+
r: string;
|
|
1779
|
+
|
|
1780
|
+
s: string;
|
|
1781
|
+
|
|
1782
|
+
y_parity: number;
|
|
1783
|
+
}
|
|
1784
|
+
}
|
|
1449
1785
|
}
|
|
1450
1786
|
}
|
|
1451
1787
|
|
|
1452
1788
|
export interface EthereumSignUserOperationRpcInput {
|
|
1453
1789
|
/**
|
|
1454
|
-
* Body param
|
|
1790
|
+
* Body param
|
|
1455
1791
|
*/
|
|
1456
1792
|
method: 'eth_signUserOperation';
|
|
1457
1793
|
|
|
1458
1794
|
/**
|
|
1459
|
-
* Body param
|
|
1795
|
+
* Body param
|
|
1460
1796
|
*/
|
|
1461
1797
|
params: EthereumSignUserOperationRpcInput.Params;
|
|
1462
1798
|
|
|
1463
1799
|
/**
|
|
1464
|
-
* Body param
|
|
1800
|
+
* Body param
|
|
1465
1801
|
*/
|
|
1466
1802
|
address?: string;
|
|
1467
1803
|
|
|
1468
1804
|
/**
|
|
1469
|
-
* Body param
|
|
1805
|
+
* Body param
|
|
1470
1806
|
*/
|
|
1471
1807
|
chain_type?: 'ethereum';
|
|
1472
1808
|
|
|
@@ -1523,32 +1859,32 @@ export declare namespace WalletRpcParams {
|
|
|
1523
1859
|
|
|
1524
1860
|
export interface EthereumSendTransactionRpcInput {
|
|
1525
1861
|
/**
|
|
1526
|
-
* Body param
|
|
1862
|
+
* Body param
|
|
1527
1863
|
*/
|
|
1528
1864
|
caip2: string;
|
|
1529
1865
|
|
|
1530
1866
|
/**
|
|
1531
|
-
* Body param
|
|
1867
|
+
* Body param
|
|
1532
1868
|
*/
|
|
1533
1869
|
method: 'eth_sendTransaction';
|
|
1534
1870
|
|
|
1535
1871
|
/**
|
|
1536
|
-
* Body param
|
|
1872
|
+
* Body param
|
|
1537
1873
|
*/
|
|
1538
1874
|
params: EthereumSendTransactionRpcInput.Params;
|
|
1539
1875
|
|
|
1540
1876
|
/**
|
|
1541
|
-
* Body param
|
|
1877
|
+
* Body param
|
|
1542
1878
|
*/
|
|
1543
1879
|
address?: string;
|
|
1544
1880
|
|
|
1545
1881
|
/**
|
|
1546
|
-
* Body param
|
|
1882
|
+
* Body param
|
|
1547
1883
|
*/
|
|
1548
1884
|
chain_type?: 'ethereum';
|
|
1549
1885
|
|
|
1550
1886
|
/**
|
|
1551
|
-
* Body param
|
|
1887
|
+
* Body param
|
|
1552
1888
|
*/
|
|
1553
1889
|
sponsor?: boolean;
|
|
1554
1890
|
|
|
@@ -1572,6 +1908,8 @@ export declare namespace WalletRpcParams {
|
|
|
1572
1908
|
|
|
1573
1909
|
export namespace Params {
|
|
1574
1910
|
export interface Transaction {
|
|
1911
|
+
authorization_list?: Array<Transaction.AuthorizationList>;
|
|
1912
|
+
|
|
1575
1913
|
chain_id?: string | number;
|
|
1576
1914
|
|
|
1577
1915
|
data?: string;
|
|
@@ -1590,31 +1928,47 @@ export declare namespace WalletRpcParams {
|
|
|
1590
1928
|
|
|
1591
1929
|
to?: string;
|
|
1592
1930
|
|
|
1593
|
-
type?: 0 | 1 | 2;
|
|
1931
|
+
type?: 0 | 1 | 2 | 4;
|
|
1594
1932
|
|
|
1595
1933
|
value?: string | number;
|
|
1596
1934
|
}
|
|
1935
|
+
|
|
1936
|
+
export namespace Transaction {
|
|
1937
|
+
export interface AuthorizationList {
|
|
1938
|
+
chain_id: string | number;
|
|
1939
|
+
|
|
1940
|
+
contract: string;
|
|
1941
|
+
|
|
1942
|
+
nonce: string | number;
|
|
1943
|
+
|
|
1944
|
+
r: string;
|
|
1945
|
+
|
|
1946
|
+
s: string;
|
|
1947
|
+
|
|
1948
|
+
y_parity: number;
|
|
1949
|
+
}
|
|
1950
|
+
}
|
|
1597
1951
|
}
|
|
1598
1952
|
}
|
|
1599
1953
|
|
|
1600
1954
|
export interface EthereumSign7702AuthorizationRpcInput {
|
|
1601
1955
|
/**
|
|
1602
|
-
* Body param
|
|
1956
|
+
* Body param
|
|
1603
1957
|
*/
|
|
1604
1958
|
method: 'eth_sign7702Authorization';
|
|
1605
1959
|
|
|
1606
1960
|
/**
|
|
1607
|
-
* Body param
|
|
1961
|
+
* Body param
|
|
1608
1962
|
*/
|
|
1609
1963
|
params: EthereumSign7702AuthorizationRpcInput.Params;
|
|
1610
1964
|
|
|
1611
1965
|
/**
|
|
1612
|
-
* Body param
|
|
1966
|
+
* Body param
|
|
1613
1967
|
*/
|
|
1614
1968
|
address?: string;
|
|
1615
1969
|
|
|
1616
1970
|
/**
|
|
1617
|
-
* Body param
|
|
1971
|
+
* Body param
|
|
1618
1972
|
*/
|
|
1619
1973
|
chain_type?: 'ethereum';
|
|
1620
1974
|
|
|
@@ -1643,22 +1997,22 @@ export declare namespace WalletRpcParams {
|
|
|
1643
1997
|
|
|
1644
1998
|
export interface EthereumSecp256k1SignRpcInput {
|
|
1645
1999
|
/**
|
|
1646
|
-
* Body param
|
|
2000
|
+
* Body param
|
|
1647
2001
|
*/
|
|
1648
2002
|
method: 'secp256k1_sign';
|
|
1649
2003
|
|
|
1650
2004
|
/**
|
|
1651
|
-
* Body param
|
|
2005
|
+
* Body param
|
|
1652
2006
|
*/
|
|
1653
2007
|
params: EthereumSecp256k1SignRpcInput.Params;
|
|
1654
2008
|
|
|
1655
2009
|
/**
|
|
1656
|
-
* Body param
|
|
2010
|
+
* Body param
|
|
1657
2011
|
*/
|
|
1658
2012
|
address?: string;
|
|
1659
2013
|
|
|
1660
2014
|
/**
|
|
1661
|
-
* Body param
|
|
2015
|
+
* Body param
|
|
1662
2016
|
*/
|
|
1663
2017
|
chain_type?: 'ethereum';
|
|
1664
2018
|
|
|
@@ -1683,22 +2037,22 @@ export declare namespace WalletRpcParams {
|
|
|
1683
2037
|
|
|
1684
2038
|
export interface SolanaSignMessageRpcInput {
|
|
1685
2039
|
/**
|
|
1686
|
-
* Body param
|
|
2040
|
+
* Body param
|
|
1687
2041
|
*/
|
|
1688
2042
|
method: 'signMessage';
|
|
1689
2043
|
|
|
1690
2044
|
/**
|
|
1691
|
-
* Body param
|
|
2045
|
+
* Body param
|
|
1692
2046
|
*/
|
|
1693
2047
|
params: SolanaSignMessageRpcInput.Params;
|
|
1694
2048
|
|
|
1695
2049
|
/**
|
|
1696
|
-
* Body param
|
|
2050
|
+
* Body param
|
|
1697
2051
|
*/
|
|
1698
2052
|
address?: string;
|
|
1699
2053
|
|
|
1700
2054
|
/**
|
|
1701
|
-
* Body param
|
|
2055
|
+
* Body param
|
|
1702
2056
|
*/
|
|
1703
2057
|
chain_type?: 'solana';
|
|
1704
2058
|
|
|
@@ -1725,22 +2079,22 @@ export declare namespace WalletRpcParams {
|
|
|
1725
2079
|
|
|
1726
2080
|
export interface SolanaSignTransactionRpcInput {
|
|
1727
2081
|
/**
|
|
1728
|
-
* Body param
|
|
2082
|
+
* Body param
|
|
1729
2083
|
*/
|
|
1730
2084
|
method: 'signTransaction';
|
|
1731
2085
|
|
|
1732
2086
|
/**
|
|
1733
|
-
* Body param
|
|
2087
|
+
* Body param
|
|
1734
2088
|
*/
|
|
1735
2089
|
params: SolanaSignTransactionRpcInput.Params;
|
|
1736
2090
|
|
|
1737
2091
|
/**
|
|
1738
|
-
* Body param
|
|
2092
|
+
* Body param
|
|
1739
2093
|
*/
|
|
1740
2094
|
address?: string;
|
|
1741
2095
|
|
|
1742
2096
|
/**
|
|
1743
|
-
* Body param
|
|
2097
|
+
* Body param
|
|
1744
2098
|
*/
|
|
1745
2099
|
chain_type?: 'solana';
|
|
1746
2100
|
|
|
@@ -1767,32 +2121,32 @@ export declare namespace WalletRpcParams {
|
|
|
1767
2121
|
|
|
1768
2122
|
export interface SolanaSignAndSendTransactionRpcInput {
|
|
1769
2123
|
/**
|
|
1770
|
-
* Body param
|
|
2124
|
+
* Body param
|
|
1771
2125
|
*/
|
|
1772
2126
|
caip2: string;
|
|
1773
2127
|
|
|
1774
2128
|
/**
|
|
1775
|
-
* Body param
|
|
2129
|
+
* Body param
|
|
1776
2130
|
*/
|
|
1777
2131
|
method: 'signAndSendTransaction';
|
|
1778
2132
|
|
|
1779
2133
|
/**
|
|
1780
|
-
* Body param
|
|
2134
|
+
* Body param
|
|
1781
2135
|
*/
|
|
1782
2136
|
params: SolanaSignAndSendTransactionRpcInput.Params;
|
|
1783
2137
|
|
|
1784
2138
|
/**
|
|
1785
|
-
* Body param
|
|
2139
|
+
* Body param
|
|
1786
2140
|
*/
|
|
1787
2141
|
address?: string;
|
|
1788
2142
|
|
|
1789
2143
|
/**
|
|
1790
|
-
* Body param
|
|
2144
|
+
* Body param
|
|
1791
2145
|
*/
|
|
1792
2146
|
chain_type?: 'solana';
|
|
1793
2147
|
|
|
1794
2148
|
/**
|
|
1795
|
-
* Body param
|
|
2149
|
+
* Body param
|
|
1796
2150
|
*/
|
|
1797
2151
|
sponsor?: boolean;
|
|
1798
2152
|
|
|
@@ -1868,6 +2222,13 @@ export namespace WalletSubmitImportParams {
|
|
|
1868
2222
|
* The index of the wallet to import.
|
|
1869
2223
|
*/
|
|
1870
2224
|
index: number;
|
|
2225
|
+
|
|
2226
|
+
/**
|
|
2227
|
+
* Optional HPKE configuration for wallet import decryption. These parameters allow
|
|
2228
|
+
* importing wallets encrypted by external providers that use different HPKE
|
|
2229
|
+
* configurations.
|
|
2230
|
+
*/
|
|
2231
|
+
hpke_config?: WalletsAPI.HpkeImportConfig;
|
|
1871
2232
|
}
|
|
1872
2233
|
|
|
1873
2234
|
export interface PrivateKeySubmitInput {
|
|
@@ -1899,6 +2260,13 @@ export namespace WalletSubmitImportParams {
|
|
|
1899
2260
|
encryption_type: 'HPKE';
|
|
1900
2261
|
|
|
1901
2262
|
entropy_type: 'private-key';
|
|
2263
|
+
|
|
2264
|
+
/**
|
|
2265
|
+
* Optional HPKE configuration for wallet import decryption. These parameters allow
|
|
2266
|
+
* importing wallets encrypted by external providers that use different HPKE
|
|
2267
|
+
* configurations.
|
|
2268
|
+
*/
|
|
2269
|
+
hpke_config?: WalletsAPI.HpkeImportConfig;
|
|
1902
2270
|
}
|
|
1903
2271
|
|
|
1904
2272
|
export interface AdditionalSigner {
|
|
@@ -1930,8 +2298,7 @@ export interface WalletUpdateParams {
|
|
|
1930
2298
|
owner?: WalletUpdateParams.PublicKeyOwner | WalletUpdateParams.UserOwner | null;
|
|
1931
2299
|
|
|
1932
2300
|
/**
|
|
1933
|
-
* Body param
|
|
1934
|
-
* provide this, do not specify an owner.
|
|
2301
|
+
* Body param
|
|
1935
2302
|
*/
|
|
1936
2303
|
owner_id?: string | null;
|
|
1937
2304
|
|
|
@@ -2056,13 +2423,23 @@ Wallets.Balance = Balance;
|
|
|
2056
2423
|
|
|
2057
2424
|
export declare namespace Wallets {
|
|
2058
2425
|
export {
|
|
2426
|
+
type WalletRevokeResponse as WalletRevokeResponse,
|
|
2059
2427
|
type CurveSigningChainType as CurveSigningChainType,
|
|
2428
|
+
type ExtendedChainType as ExtendedChainType,
|
|
2060
2429
|
type FirstClassChainType as FirstClassChainType,
|
|
2061
|
-
type Wallet as Wallet,
|
|
2062
2430
|
type WalletChainType as WalletChainType,
|
|
2063
|
-
type WalletRevokeResponse as WalletRevokeResponse,
|
|
2064
|
-
type ExtendedChainType as ExtendedChainType,
|
|
2065
2431
|
type WalletCustodian as WalletCustodian,
|
|
2432
|
+
type CustodialWalletProvider as CustodialWalletProvider,
|
|
2433
|
+
type CustodialWalletChainType as CustodialWalletChainType,
|
|
2434
|
+
type CustodialWalletCreateInput as CustodialWalletCreateInput,
|
|
2435
|
+
type CustodialWallet as CustodialWallet,
|
|
2436
|
+
type HpkeImportConfig as HpkeImportConfig,
|
|
2437
|
+
type SuiCommandName as SuiCommandName,
|
|
2438
|
+
type Wallet as Wallet,
|
|
2439
|
+
type WalletBatchItemInput as WalletBatchItemInput,
|
|
2440
|
+
type WalletBatchCreateInput as WalletBatchCreateInput,
|
|
2441
|
+
type WalletBatchCreateResult as WalletBatchCreateResult,
|
|
2442
|
+
type WalletBatchCreateResponse as WalletBatchCreateResponse,
|
|
2066
2443
|
type EthereumPersonalSignRpcInput as EthereumPersonalSignRpcInput,
|
|
2067
2444
|
type EthereumSignTransactionRpcInput as EthereumSignTransactionRpcInput,
|
|
2068
2445
|
type EthereumSendTransactionRpcInput as EthereumSendTransactionRpcInput,
|