@polyester/sdk 0.28.1 → 0.29.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.
Files changed (29) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/dist/index.d.ts +2 -2
  3. package/dist/services/address-book/address-book.schemas.d.ts +209 -85
  4. package/dist/services/address-book/address-book.schemas.d.ts.map +1 -1
  5. package/dist/services/address-book/address-book.schemas.js +22 -3
  6. package/dist/services/address-book/address-book.schemas.js.map +1 -1
  7. package/dist/services/address-book/address-book.types.d.ts +2 -2
  8. package/dist/services/address-book/index.d.ts +1 -1
  9. package/dist/services/api-keys/api-keys.schemas.d.ts +3 -3
  10. package/dist/services/api-keys/api-keys.schemas.d.ts.map +1 -1
  11. package/dist/services/api-keys/api-keys.schemas.js +2 -2
  12. package/dist/services/api-keys/api-keys.schemas.js.map +1 -1
  13. package/dist/services/candles/candles.schemas.d.ts +10 -10
  14. package/dist/services/heatmap/heatmap.schemas.d.ts +13 -13
  15. package/dist/services/market-overview/market-overview.schemas.d.ts +3 -3
  16. package/dist/services/orderbook/orderbook.schemas.d.ts +1 -1
  17. package/dist/services/orders/orders-output.schemas.d.ts +6 -6
  18. package/dist/services/policies/api-key-policies/api-key-policies.schemas.d.ts +1 -1
  19. package/dist/services/policies/api-key-policies/api-key-policies.schemas.js +1 -1
  20. package/dist/services/policies/api-key-policies/api-key-policies.schemas.js.map +1 -1
  21. package/dist/services/subaccounts/subaccounts.schemas.d.ts +2 -2
  22. package/dist/services/subaccounts/subaccounts.schemas.d.ts.map +1 -1
  23. package/dist/services/subaccounts/subaccounts.schemas.js +3 -3
  24. package/dist/services/subaccounts/subaccounts.schemas.js.map +1 -1
  25. package/dist/services/triggers/trigger-input.schemas.d.ts +1 -1
  26. package/dist/services/triggers/triggers-output.schemas.d.ts +15 -15
  27. package/dist/shared/schemas.js +3 -1
  28. package/dist/shared/schemas.js.map +1 -1
  29. package/package.json +1 -1
@@ -275,12 +275,28 @@ declare const GetAddressBookViewInputSchema: v.SchemaWithPipe<readonly [v.Strict
275
275
  minimumViewRevision: bigint | undefined;
276
276
  }>]>;
277
277
  type GetAddressBookViewInput = v.InferInput<typeof GetAddressBookViewInputSchema>;
278
+ type AddressBookAccountScope = {
279
+ scopeType: "root";
280
+ rootAccountId: string;
281
+ } | {
282
+ scopeType: "subaccount";
283
+ rootAccountId: string;
284
+ subaccountId: string;
285
+ } | {
286
+ scopeType: "unspecified";
287
+ rootAccountId: string;
288
+ subaccountId?: string;
289
+ };
278
290
  declare const AddressBookSchema: v.ObjectSchema<{
279
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
291
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
280
292
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
281
293
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
282
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
283
- }, undefined>, undefined>;
294
+ readonly subaccountId: v.BigintSchema<undefined>;
295
+ }, undefined>, v.TransformAction<{
296
+ scopeType: "unspecified" | "subaccount" | "root";
297
+ rootAccountId: string;
298
+ subaccountId: bigint;
299
+ }, AddressBookAccountScope>]>, undefined>;
284
300
  readonly callerRole: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "owner" | "admin" | "treasury" | "leveraged_trader" | "trader" | "viewer">]>;
285
301
  readonly label: v.StringSchema<undefined>;
286
302
  readonly ownerUsername: v.StringSchema<undefined>;
@@ -295,11 +311,15 @@ declare const AddressBookTagSummarySchema: v.ObjectSchema<{
295
311
  type AddressBookTagSummary = v.InferOutput<typeof AddressBookTagSummarySchema>;
296
312
  declare const AddressBookTagSchema: v.ObjectSchema<{
297
313
  readonly tagId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
298
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
314
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
299
315
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
300
316
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
301
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
302
- }, undefined>, undefined>;
317
+ readonly subaccountId: v.BigintSchema<undefined>;
318
+ }, undefined>, v.TransformAction<{
319
+ scopeType: "unspecified" | "subaccount" | "root";
320
+ rootAccountId: string;
321
+ subaccountId: bigint;
322
+ }, AddressBookAccountScope>]>, undefined>;
303
323
  readonly name: v.StringSchema<undefined>;
304
324
  readonly color: v.StringSchema<undefined>;
305
325
  readonly createdAt: v.SchemaWithPipe<readonly [v.OptionalSchema<v.ObjectSchema<{
@@ -320,11 +340,15 @@ declare const AddressBookTagSchema: v.ObjectSchema<{
320
340
  type AddressBookTag = v.InferOutput<typeof AddressBookTagSchema>;
321
341
  declare const AddressBookEntrySchema: v.ObjectSchema<{
322
342
  readonly addressBookEntryId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
323
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
343
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
324
344
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
325
345
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
326
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
327
- }, undefined>, undefined>;
346
+ readonly subaccountId: v.BigintSchema<undefined>;
347
+ }, undefined>, v.TransformAction<{
348
+ scopeType: "unspecified" | "subaccount" | "root";
349
+ rootAccountId: string;
350
+ subaccountId: bigint;
351
+ }, AddressBookAccountScope>]>, undefined>;
328
352
  readonly kind: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "external" | "internal">]>;
329
353
  readonly label: v.StringSchema<undefined>;
330
354
  readonly note: v.StringSchema<undefined>;
@@ -364,11 +388,15 @@ declare const AddressBookEntrySchema: v.ObjectSchema<{
364
388
  }, undefined>], undefined>;
365
389
  readonly tags: v.ArraySchema<v.ObjectSchema<{
366
390
  readonly tagId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
367
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
391
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
368
392
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
369
393
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
370
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
371
- }, undefined>, undefined>;
394
+ readonly subaccountId: v.BigintSchema<undefined>;
395
+ }, undefined>, v.TransformAction<{
396
+ scopeType: "unspecified" | "subaccount" | "root";
397
+ rootAccountId: string;
398
+ subaccountId: bigint;
399
+ }, AddressBookAccountScope>]>, undefined>;
372
400
  readonly name: v.StringSchema<undefined>;
373
401
  readonly color: v.StringSchema<undefined>;
374
402
  readonly createdAt: v.SchemaWithPipe<readonly [v.OptionalSchema<v.ObjectSchema<{
@@ -391,11 +419,15 @@ declare const AddressBookEntrySchema: v.ObjectSchema<{
391
419
  type AddressBookEntry = v.InferOutput<typeof AddressBookEntrySchema>;
392
420
  declare const AddressBookEntriesSchema: v.ArraySchema<v.ObjectSchema<{
393
421
  readonly addressBookEntryId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
394
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
422
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
395
423
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
396
424
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
397
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
398
- }, undefined>, undefined>;
425
+ readonly subaccountId: v.BigintSchema<undefined>;
426
+ }, undefined>, v.TransformAction<{
427
+ scopeType: "unspecified" | "subaccount" | "root";
428
+ rootAccountId: string;
429
+ subaccountId: bigint;
430
+ }, AddressBookAccountScope>]>, undefined>;
399
431
  readonly kind: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "external" | "internal">]>;
400
432
  readonly label: v.StringSchema<undefined>;
401
433
  readonly note: v.StringSchema<undefined>;
@@ -435,11 +467,15 @@ declare const AddressBookEntriesSchema: v.ArraySchema<v.ObjectSchema<{
435
467
  }, undefined>], undefined>;
436
468
  readonly tags: v.ArraySchema<v.ObjectSchema<{
437
469
  readonly tagId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
438
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
470
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
439
471
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
440
472
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
441
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
442
- }, undefined>, undefined>;
473
+ readonly subaccountId: v.BigintSchema<undefined>;
474
+ }, undefined>, v.TransformAction<{
475
+ scopeType: "unspecified" | "subaccount" | "root";
476
+ rootAccountId: string;
477
+ subaccountId: bigint;
478
+ }, AddressBookAccountScope>]>, undefined>;
443
479
  readonly name: v.StringSchema<undefined>;
444
480
  readonly color: v.StringSchema<undefined>;
445
481
  readonly createdAt: v.SchemaWithPipe<readonly [v.OptionalSchema<v.ObjectSchema<{
@@ -462,11 +498,15 @@ declare const AddressBookEntriesSchema: v.ArraySchema<v.ObjectSchema<{
462
498
  type AddressBookEntries = v.InferOutput<typeof AddressBookEntriesSchema>;
463
499
  declare const TransferCounterpartySchema: v.ObjectSchema<{
464
500
  readonly counterpartyId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
465
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
501
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
466
502
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
467
503
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
468
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
469
- }, undefined>, undefined>;
504
+ readonly subaccountId: v.BigintSchema<undefined>;
505
+ }, undefined>, v.TransformAction<{
506
+ scopeType: "unspecified" | "subaccount" | "root";
507
+ rootAccountId: string;
508
+ subaccountId: bigint;
509
+ }, AddressBookAccountScope>]>, undefined>;
470
510
  readonly direction: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "withdrawTo" | "depositFrom" | "internalTransferFrom" | "internalTransferTo">]>;
471
511
  readonly kind: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "external" | "internal">]>;
472
512
  readonly saved: v.BooleanSchema<undefined>;
@@ -510,11 +550,15 @@ declare const TransferCounterpartySchema: v.ObjectSchema<{
510
550
  type TransferCounterparty = v.InferOutput<typeof TransferCounterpartySchema>;
511
551
  declare const TransferCounterpartiesSchema: v.ArraySchema<v.ObjectSchema<{
512
552
  readonly counterpartyId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
513
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
553
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
514
554
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
515
555
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
516
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
517
- }, undefined>, undefined>;
556
+ readonly subaccountId: v.BigintSchema<undefined>;
557
+ }, undefined>, v.TransformAction<{
558
+ scopeType: "unspecified" | "subaccount" | "root";
559
+ rootAccountId: string;
560
+ subaccountId: bigint;
561
+ }, AddressBookAccountScope>]>, undefined>;
518
562
  readonly direction: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "withdrawTo" | "depositFrom" | "internalTransferFrom" | "internalTransferTo">]>;
519
563
  readonly kind: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "external" | "internal">]>;
520
564
  readonly saved: v.BooleanSchema<undefined>;
@@ -557,22 +601,30 @@ declare const TransferCounterpartiesSchema: v.ArraySchema<v.ObjectSchema<{
557
601
  }, undefined>, undefined>;
558
602
  type TransferCounterparties = v.InferOutput<typeof TransferCounterpartiesSchema>;
559
603
  declare const TransferDestinationSchema: v.ObjectSchema<{
560
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
604
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
561
605
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
562
606
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
563
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
564
- }, undefined>, undefined>;
607
+ readonly subaccountId: v.BigintSchema<undefined>;
608
+ }, undefined>, v.TransformAction<{
609
+ scopeType: "unspecified" | "subaccount" | "root";
610
+ rootAccountId: string;
611
+ subaccountId: bigint;
612
+ }, AddressBookAccountScope>]>, undefined>;
565
613
  readonly kind: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "external" | "internal">]>;
566
614
  readonly saved: v.BooleanSchema<undefined>;
567
615
  readonly whitelisted: v.BooleanSchema<undefined>;
568
616
  readonly whitelistStatus: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "active" | "notWhitelisted" | "unresolved">]>;
569
617
  readonly addressBookEntry: v.OptionalSchema<v.ObjectSchema<{
570
618
  readonly addressBookEntryId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
571
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
619
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
572
620
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
573
621
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
574
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
575
- }, undefined>, undefined>;
622
+ readonly subaccountId: v.BigintSchema<undefined>;
623
+ }, undefined>, v.TransformAction<{
624
+ scopeType: "unspecified" | "subaccount" | "root";
625
+ rootAccountId: string;
626
+ subaccountId: bigint;
627
+ }, AddressBookAccountScope>]>, undefined>;
576
628
  readonly kind: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "external" | "internal">]>;
577
629
  readonly label: v.StringSchema<undefined>;
578
630
  readonly note: v.StringSchema<undefined>;
@@ -612,11 +664,15 @@ declare const TransferDestinationSchema: v.ObjectSchema<{
612
664
  }, undefined>], undefined>;
613
665
  readonly tags: v.ArraySchema<v.ObjectSchema<{
614
666
  readonly tagId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
615
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
667
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
616
668
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
617
669
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
618
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
619
- }, undefined>, undefined>;
670
+ readonly subaccountId: v.BigintSchema<undefined>;
671
+ }, undefined>, v.TransformAction<{
672
+ scopeType: "unspecified" | "subaccount" | "root";
673
+ rootAccountId: string;
674
+ subaccountId: bigint;
675
+ }, AddressBookAccountScope>]>, undefined>;
620
676
  readonly name: v.StringSchema<undefined>;
621
677
  readonly color: v.StringSchema<undefined>;
622
678
  readonly createdAt: v.SchemaWithPipe<readonly [v.OptionalSchema<v.ObjectSchema<{
@@ -673,22 +729,30 @@ declare const TransferDestinationSchema: v.ObjectSchema<{
673
729
  }, undefined>;
674
730
  type TransferDestination = v.InferOutput<typeof TransferDestinationSchema>;
675
731
  declare const TransferDestinationsSchema: v.ArraySchema<v.ObjectSchema<{
676
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
732
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
677
733
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
678
734
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
679
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
680
- }, undefined>, undefined>;
735
+ readonly subaccountId: v.BigintSchema<undefined>;
736
+ }, undefined>, v.TransformAction<{
737
+ scopeType: "unspecified" | "subaccount" | "root";
738
+ rootAccountId: string;
739
+ subaccountId: bigint;
740
+ }, AddressBookAccountScope>]>, undefined>;
681
741
  readonly kind: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "external" | "internal">]>;
682
742
  readonly saved: v.BooleanSchema<undefined>;
683
743
  readonly whitelisted: v.BooleanSchema<undefined>;
684
744
  readonly whitelistStatus: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "active" | "notWhitelisted" | "unresolved">]>;
685
745
  readonly addressBookEntry: v.OptionalSchema<v.ObjectSchema<{
686
746
  readonly addressBookEntryId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
687
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
747
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
688
748
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
689
749
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
690
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
691
- }, undefined>, undefined>;
750
+ readonly subaccountId: v.BigintSchema<undefined>;
751
+ }, undefined>, v.TransformAction<{
752
+ scopeType: "unspecified" | "subaccount" | "root";
753
+ rootAccountId: string;
754
+ subaccountId: bigint;
755
+ }, AddressBookAccountScope>]>, undefined>;
692
756
  readonly kind: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "external" | "internal">]>;
693
757
  readonly label: v.StringSchema<undefined>;
694
758
  readonly note: v.StringSchema<undefined>;
@@ -728,11 +792,15 @@ declare const TransferDestinationsSchema: v.ArraySchema<v.ObjectSchema<{
728
792
  }, undefined>], undefined>;
729
793
  readonly tags: v.ArraySchema<v.ObjectSchema<{
730
794
  readonly tagId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
731
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
795
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
732
796
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
733
797
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
734
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
735
- }, undefined>, undefined>;
798
+ readonly subaccountId: v.BigintSchema<undefined>;
799
+ }, undefined>, v.TransformAction<{
800
+ scopeType: "unspecified" | "subaccount" | "root";
801
+ rootAccountId: string;
802
+ subaccountId: bigint;
803
+ }, AddressBookAccountScope>]>, undefined>;
736
804
  readonly name: v.StringSchema<undefined>;
737
805
  readonly color: v.StringSchema<undefined>;
738
806
  readonly createdAt: v.SchemaWithPipe<readonly [v.OptionalSchema<v.ObjectSchema<{
@@ -790,11 +858,15 @@ declare const TransferDestinationsSchema: v.ArraySchema<v.ObjectSchema<{
790
858
  type TransferDestinations = v.InferOutput<typeof TransferDestinationsSchema>;
791
859
  declare const InternalTransferWhitelistEntrySchema: v.ObjectSchema<{
792
860
  readonly entryId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
793
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
861
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
794
862
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
795
863
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
796
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
797
- }, undefined>, undefined>;
864
+ readonly subaccountId: v.BigintSchema<undefined>;
865
+ }, undefined>, v.TransformAction<{
866
+ scopeType: "unspecified" | "subaccount" | "root";
867
+ rootAccountId: string;
868
+ subaccountId: bigint;
869
+ }, AddressBookAccountScope>]>, undefined>;
798
870
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
799
871
  readonly targetAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
800
872
  readonly targetScopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
@@ -820,11 +892,15 @@ declare const InternalTransferWhitelistEntrySchema: v.ObjectSchema<{
820
892
  type InternalTransferWhitelistEntry = v.InferOutput<typeof InternalTransferWhitelistEntrySchema>;
821
893
  declare const InternalTransferWhitelistEntriesSchema: v.ArraySchema<v.ObjectSchema<{
822
894
  readonly entryId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
823
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
895
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
824
896
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
825
897
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
826
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
827
- }, undefined>, undefined>;
898
+ readonly subaccountId: v.BigintSchema<undefined>;
899
+ }, undefined>, v.TransformAction<{
900
+ scopeType: "unspecified" | "subaccount" | "root";
901
+ rootAccountId: string;
902
+ subaccountId: bigint;
903
+ }, AddressBookAccountScope>]>, undefined>;
828
904
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
829
905
  readonly targetAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
830
906
  readonly targetScopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
@@ -862,11 +938,15 @@ declare const MirroredWithdrawWhitelistEntrySchema: v.ObjectSchema<{
862
938
  }, undefined>;
863
939
  type MirroredWithdrawWhitelistEntry = v.InferOutput<typeof MirroredWithdrawWhitelistEntrySchema>;
864
940
  declare const WithdrawWhitelistViewSchema: v.ObjectSchema<{
865
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
941
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
866
942
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
867
943
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
868
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
869
- }, undefined>, undefined>;
944
+ readonly subaccountId: v.BigintSchema<undefined>;
945
+ }, undefined>, v.TransformAction<{
946
+ scopeType: "unspecified" | "subaccount" | "root";
947
+ rootAccountId: string;
948
+ subaccountId: bigint;
949
+ }, AddressBookAccountScope>]>, undefined>;
870
950
  readonly externalWhitelistRequired: v.BooleanSchema<undefined>;
871
951
  readonly internalWhitelistRequired: v.BooleanSchema<undefined>;
872
952
  readonly activeEntries: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
@@ -886,11 +966,15 @@ type WithdrawWhitelistView = v.InferOutput<typeof WithdrawWhitelistViewSchema>;
886
966
  declare const AddressBookEntriesViewSchema: v.ObjectSchema<{
887
967
  readonly external: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
888
968
  readonly addressBookEntryId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
889
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
969
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
890
970
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
891
971
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
892
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
893
- }, undefined>, undefined>;
972
+ readonly subaccountId: v.BigintSchema<undefined>;
973
+ }, undefined>, v.TransformAction<{
974
+ scopeType: "unspecified" | "subaccount" | "root";
975
+ rootAccountId: string;
976
+ subaccountId: bigint;
977
+ }, AddressBookAccountScope>]>, undefined>;
894
978
  readonly label: v.StringSchema<undefined>;
895
979
  readonly note: v.StringSchema<undefined>;
896
980
  readonly tagIds: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>, undefined>, readonly []>;
@@ -915,11 +999,15 @@ declare const AddressBookEntriesViewSchema: v.ObjectSchema<{
915
999
  }, undefined>, undefined>, readonly []>;
916
1000
  readonly internal: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
917
1001
  readonly addressBookEntryId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
918
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
1002
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
919
1003
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
920
1004
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
921
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
922
- }, undefined>, undefined>;
1005
+ readonly subaccountId: v.BigintSchema<undefined>;
1006
+ }, undefined>, v.TransformAction<{
1007
+ scopeType: "unspecified" | "subaccount" | "root";
1008
+ rootAccountId: string;
1009
+ subaccountId: bigint;
1010
+ }, AddressBookAccountScope>]>, undefined>;
923
1011
  readonly label: v.StringSchema<undefined>;
924
1012
  readonly note: v.StringSchema<undefined>;
925
1013
  readonly tagIds: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>, undefined>, readonly []>;
@@ -950,11 +1038,15 @@ declare const AddressBookEntriesViewSchema: v.ObjectSchema<{
950
1038
  type AddressBookEntriesView = v.InferOutput<typeof AddressBookEntriesViewSchema>;
951
1039
  declare const AddressBookRecentDestinationsViewSchema: v.ObjectSchema<{
952
1040
  readonly external: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
953
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
1041
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
954
1042
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
955
1043
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
956
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
957
- }, undefined>, undefined>;
1044
+ readonly subaccountId: v.BigintSchema<undefined>;
1045
+ }, undefined>, v.TransformAction<{
1046
+ scopeType: "unspecified" | "subaccount" | "root";
1047
+ rootAccountId: string;
1048
+ subaccountId: bigint;
1049
+ }, AddressBookAccountScope>]>, undefined>;
958
1050
  readonly lastDirection: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "withdrawTo" | "depositFrom" | "internalTransferFrom" | "internalTransferTo">]>;
959
1051
  readonly saved: v.BooleanSchema<undefined>;
960
1052
  readonly addressBookEntryId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
@@ -970,11 +1062,15 @@ declare const AddressBookRecentDestinationsViewSchema: v.ObjectSchema<{
970
1062
  readonly address: v.StringSchema<undefined>;
971
1063
  }, undefined>, undefined>, readonly []>;
972
1064
  readonly internal: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
973
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
1065
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
974
1066
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
975
1067
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
976
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
977
- }, undefined>, undefined>;
1068
+ readonly subaccountId: v.BigintSchema<undefined>;
1069
+ }, undefined>, v.TransformAction<{
1070
+ scopeType: "unspecified" | "subaccount" | "root";
1071
+ rootAccountId: string;
1072
+ subaccountId: bigint;
1073
+ }, AddressBookAccountScope>]>, undefined>;
978
1074
  readonly lastDirection: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "withdrawTo" | "depositFrom" | "internalTransferFrom" | "internalTransferTo">]>;
979
1075
  readonly saved: v.BooleanSchema<undefined>;
980
1076
  readonly addressBookEntryId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
@@ -997,11 +1093,15 @@ declare const AddressBookRecentDestinationsViewSchema: v.ObjectSchema<{
997
1093
  type AddressBookRecentDestinationsView = v.InferOutput<typeof AddressBookRecentDestinationsViewSchema>;
998
1094
  declare const AddressBookViewSchema: v.ObjectSchema<{
999
1095
  readonly books: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1000
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
1096
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
1001
1097
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
1002
1098
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
1003
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
1004
- }, undefined>, undefined>;
1099
+ readonly subaccountId: v.BigintSchema<undefined>;
1100
+ }, undefined>, v.TransformAction<{
1101
+ scopeType: "unspecified" | "subaccount" | "root";
1102
+ rootAccountId: string;
1103
+ subaccountId: bigint;
1104
+ }, AddressBookAccountScope>]>, undefined>;
1005
1105
  readonly callerRole: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "owner" | "admin" | "treasury" | "leveraged_trader" | "trader" | "viewer">]>;
1006
1106
  readonly label: v.StringSchema<undefined>;
1007
1107
  readonly ownerUsername: v.StringSchema<undefined>;
@@ -1010,11 +1110,15 @@ declare const AddressBookViewSchema: v.ObjectSchema<{
1010
1110
  readonly entries: v.OptionalSchema<v.ObjectSchema<{
1011
1111
  readonly external: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1012
1112
  readonly addressBookEntryId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
1013
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
1113
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
1014
1114
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
1015
1115
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
1016
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
1017
- }, undefined>, undefined>;
1116
+ readonly subaccountId: v.BigintSchema<undefined>;
1117
+ }, undefined>, v.TransformAction<{
1118
+ scopeType: "unspecified" | "subaccount" | "root";
1119
+ rootAccountId: string;
1120
+ subaccountId: bigint;
1121
+ }, AddressBookAccountScope>]>, undefined>;
1018
1122
  readonly label: v.StringSchema<undefined>;
1019
1123
  readonly note: v.StringSchema<undefined>;
1020
1124
  readonly tagIds: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>, undefined>, readonly []>;
@@ -1039,11 +1143,15 @@ declare const AddressBookViewSchema: v.ObjectSchema<{
1039
1143
  }, undefined>, undefined>, readonly []>;
1040
1144
  readonly internal: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1041
1145
  readonly addressBookEntryId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
1042
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
1146
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
1043
1147
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
1044
1148
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
1045
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
1046
- }, undefined>, undefined>;
1149
+ readonly subaccountId: v.BigintSchema<undefined>;
1150
+ }, undefined>, v.TransformAction<{
1151
+ scopeType: "unspecified" | "subaccount" | "root";
1152
+ rootAccountId: string;
1153
+ subaccountId: bigint;
1154
+ }, AddressBookAccountScope>]>, undefined>;
1047
1155
  readonly label: v.StringSchema<undefined>;
1048
1156
  readonly note: v.StringSchema<undefined>;
1049
1157
  readonly tagIds: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>, undefined>, readonly []>;
@@ -1073,11 +1181,15 @@ declare const AddressBookViewSchema: v.ObjectSchema<{
1073
1181
  }, undefined>, undefined>;
1074
1182
  readonly recentDestinations: v.OptionalSchema<v.ObjectSchema<{
1075
1183
  readonly external: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1076
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
1184
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
1077
1185
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
1078
1186
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
1079
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
1080
- }, undefined>, undefined>;
1187
+ readonly subaccountId: v.BigintSchema<undefined>;
1188
+ }, undefined>, v.TransformAction<{
1189
+ scopeType: "unspecified" | "subaccount" | "root";
1190
+ rootAccountId: string;
1191
+ subaccountId: bigint;
1192
+ }, AddressBookAccountScope>]>, undefined>;
1081
1193
  readonly lastDirection: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "withdrawTo" | "depositFrom" | "internalTransferFrom" | "internalTransferTo">]>;
1082
1194
  readonly saved: v.BooleanSchema<undefined>;
1083
1195
  readonly addressBookEntryId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
@@ -1093,11 +1205,15 @@ declare const AddressBookViewSchema: v.ObjectSchema<{
1093
1205
  readonly address: v.StringSchema<undefined>;
1094
1206
  }, undefined>, undefined>, readonly []>;
1095
1207
  readonly internal: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1096
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
1208
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
1097
1209
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
1098
1210
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
1099
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
1100
- }, undefined>, undefined>;
1211
+ readonly subaccountId: v.BigintSchema<undefined>;
1212
+ }, undefined>, v.TransformAction<{
1213
+ scopeType: "unspecified" | "subaccount" | "root";
1214
+ rootAccountId: string;
1215
+ subaccountId: bigint;
1216
+ }, AddressBookAccountScope>]>, undefined>;
1101
1217
  readonly lastDirection: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "withdrawTo" | "depositFrom" | "internalTransferFrom" | "internalTransferTo">]>;
1102
1218
  readonly saved: v.BooleanSchema<undefined>;
1103
1219
  readonly addressBookEntryId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
@@ -1123,11 +1239,15 @@ declare const AddressBookViewSchema: v.ObjectSchema<{
1123
1239
  readonly color: v.StringSchema<undefined>;
1124
1240
  }, undefined>, undefined>, readonly []>;
1125
1241
  readonly withdrawWhitelist: v.OptionalSchema<v.ObjectSchema<{
1126
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
1242
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
1127
1243
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
1128
1244
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
1129
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
1130
- }, undefined>, undefined>;
1245
+ readonly subaccountId: v.BigintSchema<undefined>;
1246
+ }, undefined>, v.TransformAction<{
1247
+ scopeType: "unspecified" | "subaccount" | "root";
1248
+ rootAccountId: string;
1249
+ subaccountId: bigint;
1250
+ }, AddressBookAccountScope>]>, undefined>;
1131
1251
  readonly externalWhitelistRequired: v.BooleanSchema<undefined>;
1132
1252
  readonly internalWhitelistRequired: v.BooleanSchema<undefined>;
1133
1253
  readonly activeEntries: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
@@ -1148,11 +1268,15 @@ declare const AddressBookViewSchema: v.ObjectSchema<{
1148
1268
  }, undefined>;
1149
1269
  type AddressBookView = v.InferOutput<typeof AddressBookViewSchema>;
1150
1270
  declare const AddressBookViewInvalidatedSchema: v.ObjectSchema<{
1151
- readonly scope: v.OptionalSchema<v.ObjectSchema<{
1271
+ readonly scope: v.OptionalSchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
1152
1272
  readonly scopeType: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.TransformAction<number, "unspecified" | "subaccount" | "root">]>;
1153
1273
  readonly rootAccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
1154
- readonly subaccountId: v.SchemaWithPipe<readonly [v.BigintSchema<undefined>, v.TransformAction<bigint, string>]>;
1155
- }, undefined>, undefined>;
1274
+ readonly subaccountId: v.BigintSchema<undefined>;
1275
+ }, undefined>, v.TransformAction<{
1276
+ scopeType: "unspecified" | "subaccount" | "root";
1277
+ rootAccountId: string;
1278
+ subaccountId: bigint;
1279
+ }, AddressBookAccountScope>]>, undefined>;
1156
1280
  readonly invalidatedAt: v.SchemaWithPipe<readonly [v.ObjectSchema<{
1157
1281
  readonly seconds: v.BigintSchema<undefined>;
1158
1282
  readonly nanos: v.OptionalSchema<v.NumberSchema<undefined>, 0>;
@@ -1164,5 +1288,5 @@ declare const AddressBookViewInvalidatedSchema: v.ObjectSchema<{
1164
1288
  }, undefined>;
1165
1289
  type AddressBookViewInvalidated = v.InferOutput<typeof AddressBookViewInvalidatedSchema>;
1166
1290
  //#endregion
1167
- export { AddressBook, AddressBookEntries, AddressBookEntriesSchema, AddressBookEntriesView, AddressBookEntriesViewSchema, AddressBookEntry, AddressBookEntrySchema, AddressBookRecentDestinationsView, AddressBookRecentDestinationsViewSchema, AddressBookSchema, AddressBookTag, AddressBookTagSchema, AddressBookTagSummary, AddressBookTagSummarySchema, AddressBookView, AddressBookViewInvalidated, AddressBookViewInvalidatedSchema, AddressBookViewSchema, CopyAddressBookEntryInput, CopyAddressBookEntryInputSchema, CreateAddressBookEntryInput, CreateAddressBookEntryInputSchema, CreateAddressBookTagInput, CreateAddressBookTagInputSchema, DeleteAddressBookEntryInput, DeleteAddressBookEntryInputSchema, DeleteAddressBookTagInput, DeleteAddressBookTagInputSchema, GetAddressBookViewInput, GetAddressBookViewInputSchema, InternalTransferWhitelistEntries, InternalTransferWhitelistEntriesSchema, InternalTransferWhitelistEntry, InternalTransferWhitelistEntrySchema, ListAddressBookEntriesInput, ListAddressBookEntriesInputSchema, ListInternalTransferWhitelistEntriesInput, ListInternalTransferWhitelistEntriesInputSchema, ListTransferCounterpartiesInput, ListTransferCounterpartiesInputSchema, ListTransferDestinationsInput, ListTransferDestinationsInputSchema, MirroredWithdrawWhitelistEntry, MirroredWithdrawWhitelistEntrySchema, SubaccountScopedInput, SubaccountScopedInputSchema, TransferCounterparties, TransferCounterpartiesSchema, TransferCounterparty, TransferCounterpartySchema, TransferDestination, TransferDestinationSchema, TransferDestinations, TransferDestinationsSchema, UpdateAddressBookEntryInput, UpdateAddressBookEntryInputSchema, UpdateAddressBookTagInput, UpdateAddressBookTagInputSchema, WithdrawWhitelistView, WithdrawWhitelistViewSchema, validateCreateAddressBookEntryInput };
1291
+ export { AddressBook, AddressBookAccountScope, AddressBookEntries, AddressBookEntriesSchema, AddressBookEntriesView, AddressBookEntriesViewSchema, AddressBookEntry, AddressBookEntrySchema, AddressBookRecentDestinationsView, AddressBookRecentDestinationsViewSchema, AddressBookSchema, AddressBookTag, AddressBookTagSchema, AddressBookTagSummary, AddressBookTagSummarySchema, AddressBookView, AddressBookViewInvalidated, AddressBookViewInvalidatedSchema, AddressBookViewSchema, CopyAddressBookEntryInput, CopyAddressBookEntryInputSchema, CreateAddressBookEntryInput, CreateAddressBookEntryInputSchema, CreateAddressBookTagInput, CreateAddressBookTagInputSchema, DeleteAddressBookEntryInput, DeleteAddressBookEntryInputSchema, DeleteAddressBookTagInput, DeleteAddressBookTagInputSchema, GetAddressBookViewInput, GetAddressBookViewInputSchema, InternalTransferWhitelistEntries, InternalTransferWhitelistEntriesSchema, InternalTransferWhitelistEntry, InternalTransferWhitelistEntrySchema, ListAddressBookEntriesInput, ListAddressBookEntriesInputSchema, ListInternalTransferWhitelistEntriesInput, ListInternalTransferWhitelistEntriesInputSchema, ListTransferCounterpartiesInput, ListTransferCounterpartiesInputSchema, ListTransferDestinationsInput, ListTransferDestinationsInputSchema, MirroredWithdrawWhitelistEntry, MirroredWithdrawWhitelistEntrySchema, SubaccountScopedInput, SubaccountScopedInputSchema, TransferCounterparties, TransferCounterpartiesSchema, TransferCounterparty, TransferCounterpartySchema, TransferDestination, TransferDestinationSchema, TransferDestinations, TransferDestinationsSchema, UpdateAddressBookEntryInput, UpdateAddressBookEntryInputSchema, UpdateAddressBookTagInput, UpdateAddressBookTagInputSchema, WithdrawWhitelistView, WithdrawWhitelistViewSchema, validateCreateAddressBookEntryInput };
1168
1292
  //# sourceMappingURL=address-book.schemas.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"address-book.schemas.d.ts","names":[],"sources":["../../../src/services/address-book/address-book.schemas.ts"],"mappings":";;;cAmDa,mCAAiC,EAAA,yBAAA,EAAA;;;;;;;;;;;;;;;;;;;;KAelC,8BAA8B,EAAE,kBAAkB;cAEjD,mCAAiC,EAAA,yBAAA,EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAwClC,8BAA8B,EAAE,kBAAkB;iBAE9C,oCAAoC,OAAO;cAkB9C,mCAAiC,EAAA,yBAAA,EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KA0BlC,8BAA8B,EAAE,kBAAkB;cAEjD,mCAAiC,EAAA;;;KAIlC,8BAA8B,EAAE,kBAAkB;cAEjD,iCAA+B,EAAA;;;;KAKhC,4BAA4B,EAAE,kBAAkB;cAE/C,iCAA+B,EAAA,yBAAA,EAAA;;;;;;;;;;;;;;;;;KAYhC,4BAA4B,EAAE,kBAAkB;cAE/C,iCAA+B,EAAA,yBAAA,EAAA;;;;;;;;;KAYhC,4BAA4B,EAAE,kBAAkB;cAE/C,iCAA+B,EAAA;;;KAIhC,4BAA4B,EAAE,kBAAkB;cAE/C,uCAAqC,EAAA,yBAAA,EAAA;;;;;;;;;;;;;;;;;;;;KAiBtC,kCAAkC,EAAE,kBACrC;cAGE,qCAAmC,EAAA,yBAAA,EAAA;;;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;;;;;;;;;;;;;;;;;;;;;;;;KAO5B,wBAAwB,EAAE,mBAAmB;cAE5C,8BAA4B,EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KA2C7B,yBAAyB,EAAE,mBAAmB;cAE7C,yCAAuC,EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAqCxC,oCAAoC,EAAE,mBACvC;cAGE,uBAAqB,EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAUtB,kBAAkB,EAAE,mBAAmB;cAEtC,kCAAgC,EAAA;;;;;;;;;;;;;;;;;;;KAMjC,6BAA6B,EAAE,mBAAmB"}
@@ -1,4 +1,5 @@
1
1
  import { enumLabelSchema } from "../../shared/proto-enum-codec.js";
2
+ import { formatId } from "../../utils/base58-id.js";
2
3
  import { BigIntStringSchema, OptionalTimestampMsSchema, PublicIdSchema, TimestampMsSchema as TimestampMsSchema$1, idInputSchema, optionalSubaccountIdInputSchema, positiveBigintStringInputSchema } from "../../shared/schemas.js";
3
4
  import { parse } from "../../shared/validation.js";
4
5
  import { PositiveUint32InputSchema } from "../shared.js";
@@ -158,11 +159,29 @@ const GetAddressBookViewInputSchema = v.pipe(v.strictObject({
158
159
  minimumViewRevision
159
160
  })));
160
161
  const CountSchema = v.pipe(v.bigint(), v.transform((value) => Number(value)));
161
- const AccountScopeSchema = v.object({
162
+ const AccountScopeSchema = v.pipe(v.object({
162
163
  scopeType: enumLabelSchema(AccountScopeTypeCodec.protoToOutput),
163
164
  rootAccountId: PublicIdSchema,
164
- subaccountId: PublicIdSchema
165
- });
165
+ subaccountId: v.bigint()
166
+ }), v.transform(({ scopeType, rootAccountId, subaccountId }) => {
167
+ if (scopeType === "root") return {
168
+ scopeType,
169
+ rootAccountId
170
+ };
171
+ if (scopeType === "subaccount") return {
172
+ scopeType,
173
+ rootAccountId,
174
+ subaccountId: formatId(subaccountId)
175
+ };
176
+ return subaccountId ? {
177
+ scopeType,
178
+ rootAccountId,
179
+ subaccountId: formatId(subaccountId)
180
+ } : {
181
+ scopeType,
182
+ rootAccountId
183
+ };
184
+ }));
166
185
  const ExternalWithdrawAddressSchema = v.object({
167
186
  polychainChainId: v.pipe(v.number(), v.integer()),
168
187
  address: v.string()