@layerzerolabs/lz-sui-sdk-v2 3.0.134 → 3.0.135-sui.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 +8 -0
- package/deployments/sui-sandbox-local/blocked_message_lib.json +18 -18
- package/deployments/sui-sandbox-local/blocked_msglib_ptb_builder.json +22 -22
- package/deployments/sui-sandbox-local/call.json +18 -19
- package/deployments/sui-sandbox-local/counter.json +79 -44
- package/deployments/sui-sandbox-local/dvn.json +15 -14
- package/deployments/sui-sandbox-local/dvn_call_type.json +28 -28
- package/deployments/sui-sandbox-local/dvn_fee_lib.json +27 -27
- package/deployments/sui-sandbox-local/dvn_layerzero.json +19 -19
- package/deployments/sui-sandbox-local/dvn_ptb_builder.json +14 -14
- package/deployments/sui-sandbox-local/endpoint_ptb_builder.json +31 -31
- package/deployments/sui-sandbox-local/endpoint_v2.json +26 -26
- package/deployments/sui-sandbox-local/executor.json +23 -22
- package/deployments/sui-sandbox-local/executor_call_type.json +28 -28
- package/deployments/sui-sandbox-local/executor_fee_lib.json +32 -32
- package/deployments/sui-sandbox-local/executor_layerzero.json +25 -25
- package/deployments/sui-sandbox-local/executor_ptb_builder.json +21 -21
- package/deployments/sui-sandbox-local/layerzero_views.json +21 -21
- package/deployments/sui-sandbox-local/message_lib_common.json +21 -21
- package/deployments/sui-sandbox-local/msglib_ptb_builder_call_types.json +13 -13
- package/deployments/sui-sandbox-local/multi_call.json +45 -0
- package/deployments/sui-sandbox-local/oapp.json +23 -21
- package/deployments/sui-sandbox-local/object-BlockedMessageLib.json +5 -5
- package/deployments/sui-sandbox-local/object-BlockedMsglibPtbBuilder.json +5 -5
- package/deployments/sui-sandbox-local/object-Counter.json +5 -5
- package/deployments/sui-sandbox-local/object-CounterAdminCap.json +5 -5
- package/deployments/sui-sandbox-local/object-CounterOApp.json +5 -5
- package/deployments/sui-sandbox-local/object-DVN.json +2 -2
- package/deployments/sui-sandbox-local/object-DVNCap.json +5 -5
- package/deployments/sui-sandbox-local/object-DVNFeeLib.json +5 -5
- package/deployments/sui-sandbox-local/object-EndpointPtbBuilder.json +5 -5
- package/deployments/sui-sandbox-local/object-EndpointPtbBuilderAdminCap.json +5 -5
- package/deployments/sui-sandbox-local/object-EndpointV2.json +5 -5
- package/deployments/sui-sandbox-local/object-EndpointV2AdminCap.json +5 -5
- package/deployments/sui-sandbox-local/object-Executor.json +2 -2
- package/deployments/sui-sandbox-local/object-ExecutorCap.json +5 -5
- package/deployments/sui-sandbox-local/object-ExecutorFeeLib.json +5 -5
- package/deployments/sui-sandbox-local/object-ExecutorOwnerCap.json +2 -2
- package/deployments/sui-sandbox-local/object-PackageWhitelistValidator.json +5 -5
- package/deployments/sui-sandbox-local/object-PriceFeed.json +5 -5
- package/deployments/sui-sandbox-local/object-PriceFeedOwnerCap.json +5 -5
- package/deployments/sui-sandbox-local/object-SimpleMessageLib.json +5 -5
- package/deployments/sui-sandbox-local/object-SimpleMessageLibAdminCap.json +5 -5
- package/deployments/sui-sandbox-local/object-SmlPtbBuilder.json +5 -5
- package/deployments/sui-sandbox-local/object-Treasury.json +5 -5
- package/deployments/sui-sandbox-local/object-TreasuryAdminCap.json +5 -5
- package/deployments/sui-sandbox-local/object-ULN302.json +5 -5
- package/deployments/sui-sandbox-local/object-ULN302AdminCap.json +5 -5
- package/deployments/sui-sandbox-local/object-Uln302PtbBuilder.json +5 -5
- package/deployments/sui-sandbox-local/object-Uln302Verification.json +5 -5
- package/deployments/sui-sandbox-local/object-WorkerRegistry.json +9 -0
- package/deployments/sui-sandbox-local/package_whitelist_validator.json +45 -45
- package/deployments/sui-sandbox-local/price_feed.json +39 -39
- package/deployments/sui-sandbox-local/price_feed_call_types.json +19 -19
- package/deployments/sui-sandbox-local/ptb_move_call.json +20 -20
- package/deployments/sui-sandbox-local/simple_message_lib.json +29 -29
- package/deployments/sui-sandbox-local/simple_msglib_ptb_builder.json +18 -18
- package/deployments/sui-sandbox-local/treasury.json +38 -38
- package/deployments/sui-sandbox-local/uln_302.json +43 -47
- package/deployments/sui-sandbox-local/uln_302_ptb_builder.json +25 -25
- package/deployments/sui-sandbox-local/uln_common.json +49 -0
- package/deployments/sui-sandbox-local/worker_common.json +21 -20
- package/deployments/sui-sandbox-local/worker_registry.json +58 -0
- package/deployments/sui-testnet/blocked_message_lib.json +25 -25
- package/deployments/sui-testnet/blocked_msglib_ptb_builder.json +25 -25
- package/deployments/sui-testnet/call.json +14 -15
- package/deployments/sui-testnet/counter.json +41 -34
- package/deployments/sui-testnet/dvn.json +22 -21
- package/deployments/sui-testnet/dvn_call_type.json +19 -19
- package/deployments/sui-testnet/dvn_fee_lib.json +26 -26
- package/deployments/sui-testnet/dvn_layerzero.json +24 -24
- package/deployments/sui-testnet/dvn_ptb_builder.json +13 -13
- package/deployments/sui-testnet/endpoint_ptb_builder.json +25 -25
- package/deployments/sui-testnet/endpoint_v2.json +30 -30
- package/deployments/sui-testnet/executor.json +14 -13
- package/deployments/sui-testnet/executor_call_type.json +12 -12
- package/deployments/sui-testnet/executor_fee_lib.json +26 -26
- package/deployments/sui-testnet/executor_layerzero.json +25 -25
- package/deployments/sui-testnet/executor_ptb_builder.json +13 -13
- package/deployments/sui-testnet/layerzero_views.json +13 -13
- package/deployments/sui-testnet/message_lib_common.json +21 -21
- package/deployments/sui-testnet/msglib_ptb_builder_call_types.json +13 -13
- package/deployments/sui-testnet/multi_call.json +45 -0
- package/deployments/sui-testnet/oapp.json +23 -21
- package/deployments/sui-testnet/object-BlockedMessageLib.json +5 -5
- package/deployments/sui-testnet/object-BlockedMsglibPtbBuilder.json +5 -5
- package/deployments/sui-testnet/object-Counter.json +5 -5
- package/deployments/sui-testnet/object-CounterAdminCap.json +5 -5
- package/deployments/sui-testnet/object-CounterOApp.json +5 -5
- package/deployments/sui-testnet/object-DVN.json +2 -2
- package/deployments/sui-testnet/object-DVNCap.json +5 -5
- package/deployments/sui-testnet/object-DVNFeeLib.json +5 -5
- package/deployments/sui-testnet/object-EndpointPtbBuilder.json +5 -5
- package/deployments/sui-testnet/object-EndpointPtbBuilderAdminCap.json +5 -5
- package/deployments/sui-testnet/object-EndpointV2.json +5 -5
- package/deployments/sui-testnet/object-EndpointV2AdminCap.json +5 -5
- package/deployments/sui-testnet/object-Executor.json +2 -2
- package/deployments/sui-testnet/object-ExecutorCap.json +5 -5
- package/deployments/sui-testnet/object-ExecutorFeeLib.json +5 -5
- package/deployments/sui-testnet/object-ExecutorOwnerCap.json +2 -2
- package/deployments/sui-testnet/object-PackageWhitelistValidator.json +5 -5
- package/deployments/sui-testnet/object-PriceFeed.json +5 -5
- package/deployments/sui-testnet/object-PriceFeedOwnerCap.json +5 -5
- package/deployments/sui-testnet/object-SimpleMessageLib.json +5 -5
- package/deployments/sui-testnet/object-SimpleMessageLibAdminCap.json +5 -5
- package/deployments/sui-testnet/object-SmlPtbBuilder.json +5 -5
- package/deployments/sui-testnet/object-Treasury.json +5 -5
- package/deployments/sui-testnet/object-TreasuryAdminCap.json +5 -5
- package/deployments/sui-testnet/object-ULN302.json +5 -5
- package/deployments/sui-testnet/object-ULN302AdminCap.json +5 -5
- package/deployments/sui-testnet/object-Uln302PtbBuilder.json +5 -5
- package/deployments/sui-testnet/object-Uln302Verification.json +5 -5
- package/deployments/sui-testnet/object-WorkerRegistry.json +9 -0
- package/deployments/sui-testnet/object-ZroCoinMetadata.json +5 -5
- package/deployments/sui-testnet/object-ZroTreasuryCap.json +5 -5
- package/deployments/sui-testnet/package_whitelist_validator.json +51 -51
- package/deployments/sui-testnet/price_feed.json +34 -34
- package/deployments/sui-testnet/price_feed_call_types.json +19 -19
- package/deployments/sui-testnet/ptb_move_call.json +21 -21
- package/deployments/sui-testnet/simple_message_lib.json +29 -29
- package/deployments/sui-testnet/simple_msglib_ptb_builder.json +22 -22
- package/deployments/sui-testnet/treasury.json +30 -58
- package/deployments/sui-testnet/uln_302.json +46 -50
- package/deployments/sui-testnet/uln_302_ptb_builder.json +25 -25
- package/deployments/sui-testnet/uln_common.json +49 -0
- package/deployments/sui-testnet/utils.json +20 -20
- package/deployments/sui-testnet/worker_common.json +21 -20
- package/deployments/sui-testnet/worker_registry.json +58 -0
- package/deployments/sui-testnet/zro.json +28 -28
- package/dist/index.cjs +1231 -464
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +728 -379
- package/dist/index.d.ts +728 -379
- package/dist/index.mjs +1220 -464
- package/dist/index.mjs.map +1 -1
- package/package.json +7 -7
- package/src/bcs/index.ts +2 -1
- package/src/bcs/oapp.ts +14 -0
- package/src/generated/addresses.ts +124 -106
- package/src/module-manager.ts +15 -3
- package/src/modules/call.ts +16 -6
- package/src/modules/endpoint.ts +54 -53
- package/src/modules/message-libs/simple-message-lib.ts +3 -2
- package/src/modules/message-libs/uln302.ts +28 -26
- package/src/modules/oapps/counter.ts +34 -53
- package/src/modules/oapps/oapp.ts +489 -74
- package/src/modules/ptb-builders/endpoint-ptb-builder.ts +9 -3
- package/src/modules/ptb-builders/ptb-builder.ts +19 -4
- package/src/modules/ptb-builders/uln302-ptb-builder.ts +5 -0
- package/src/modules/workers/dvn-layerzero.ts +9 -0
- package/src/modules/workers/dvn.ts +214 -6
- package/src/modules/workers/executor-fee-lib.ts +11 -3
- package/src/modules/workers/executor-layerzero.ts +9 -0
- package/src/modules/workers/executor.ts +115 -0
- package/src/modules/workers/index.ts +1 -0
- package/src/modules/workers/treasury.ts +4 -4
- package/src/modules/workers/worker-registry.ts +110 -0
- package/src/resource.ts +3 -0
- package/src/sdk.ts +7 -2
- package/src/types/endpoint.ts +2 -1
- package/src/types/modules.ts +1 -0
- package/src/types/oapp.ts +6 -0
- package/src/types/options.ts +15 -0
- package/src/utils/transaction.ts +3 -3
package/dist/index.d.mts
CHANGED
|
@@ -113,6 +113,14 @@ interface PackageOptions {
|
|
|
113
113
|
* The blocked message library PTB builder object address.
|
|
114
114
|
*/
|
|
115
115
|
blockedMessageLibPtbBuilder: string;
|
|
116
|
+
/**
|
|
117
|
+
* The worker registry address.
|
|
118
|
+
*/
|
|
119
|
+
workerRegistry: string;
|
|
120
|
+
/**
|
|
121
|
+
* The worker common address.
|
|
122
|
+
*/
|
|
123
|
+
workerCommon: string;
|
|
116
124
|
/**
|
|
117
125
|
* Allow additional properties beyond the explicitly defined ones
|
|
118
126
|
*/
|
|
@@ -234,6 +242,10 @@ interface ObjectOptions {
|
|
|
234
242
|
* The default package whitelist validator object address.
|
|
235
243
|
*/
|
|
236
244
|
packageWhitelistValidator: string;
|
|
245
|
+
/**
|
|
246
|
+
* The worker registry object address.
|
|
247
|
+
*/
|
|
248
|
+
workerRegistry: string;
|
|
237
249
|
/**
|
|
238
250
|
* Allow additional properties beyond the explicitly defined ones
|
|
239
251
|
*/
|
|
@@ -294,7 +306,8 @@ declare enum Modules {
|
|
|
294
306
|
PriceFeed = "priceFeed",
|
|
295
307
|
Counter = "counter",
|
|
296
308
|
DvnPtbBuilder = "dvnPtbBuilder",
|
|
297
|
-
ExecutorPtbBuilder = "executorPtbBuilder"
|
|
309
|
+
ExecutorPtbBuilder = "executorPtbBuilder",
|
|
310
|
+
WorkerRegistry = "workerRegistry"
|
|
298
311
|
}
|
|
299
312
|
|
|
300
313
|
/**
|
|
@@ -509,6 +522,10 @@ interface Timeout {
|
|
|
509
522
|
/**
|
|
510
523
|
* LayerZero protocol version constants
|
|
511
524
|
*/
|
|
525
|
+
declare const OAppInfoVersion: {
|
|
526
|
+
readonly VERSION_1: 1;
|
|
527
|
+
readonly VERSION_2: 2;
|
|
528
|
+
};
|
|
512
529
|
declare const LzReceiveVersion: {
|
|
513
530
|
readonly VERSION_1: 1;
|
|
514
531
|
};
|
|
@@ -578,7 +595,7 @@ declare class ModuleManager {
|
|
|
578
595
|
getTreasury(): Treasury;
|
|
579
596
|
getLayerZeroViews(): LayerZeroViews;
|
|
580
597
|
getPtbBuilder(): PtbBuilder;
|
|
581
|
-
getOApp(): OApp;
|
|
598
|
+
getOApp(client: SuiClient, callCapId: string, options?: ModuleOptions): OApp;
|
|
582
599
|
getCounter(client: SuiClient, options?: ModuleOptions): Counter;
|
|
583
600
|
getExecutor(client: SuiClient, options?: ModuleOptions): Executor;
|
|
584
601
|
getDvn(client: SuiClient, options?: ModuleOptions): DVN;
|
|
@@ -594,6 +611,7 @@ declare class ModuleManager {
|
|
|
594
611
|
getEndpointPtbBuilder(client: SuiClient, options?: ModuleOptions): EndpointPtbBuilder;
|
|
595
612
|
getSimpleMessageLibPtbBuilder(client: SuiClient, options?: ModuleOptions): SimpleMessageLibPtbBuilder;
|
|
596
613
|
getBlockedMessageLibPtbBuilder(client: SuiClient, options?: ModuleOptions): BlockedMessageLibPtbBuilder;
|
|
614
|
+
getWorkerRegistry(client: SuiClient, options?: ModuleOptions): WorkerRegistry;
|
|
597
615
|
/**
|
|
598
616
|
* Merge objects configuration with options, avoiding unnecessary object spreading
|
|
599
617
|
*/
|
|
@@ -644,15 +662,19 @@ declare const EndpointErrorCode: {
|
|
|
644
662
|
readonly MessagingChannel_EPayloadHashNotFound: 9;
|
|
645
663
|
readonly MessagingChannel_ESendReentrancy: 10;
|
|
646
664
|
readonly MessagingChannel_EUninitializedChannel: 11;
|
|
647
|
-
readonly
|
|
648
|
-
readonly
|
|
649
|
-
readonly
|
|
650
|
-
readonly
|
|
665
|
+
readonly MessagingComposer_EComposeExists: 1;
|
|
666
|
+
readonly MessagingComposer_EComposeMessageMismatch: 2;
|
|
667
|
+
readonly MessagingComposer_EComposeNotFound: 3;
|
|
668
|
+
readonly MessagingComposer_EComposerNotRegistered: 4;
|
|
669
|
+
readonly MessagingComposer_EComposerRegistered: 5;
|
|
670
|
+
readonly OAppRegistry_EOAppNotRegistered: 1;
|
|
671
|
+
readonly OAppRegistry_EOAppRegistered: 2;
|
|
651
672
|
readonly Endpoint_EAlreadyInitialized: 1;
|
|
652
673
|
readonly Endpoint_EInvalidEid: 2;
|
|
653
674
|
readonly Endpoint_ENotInitialized: 3;
|
|
654
675
|
readonly Endpoint_ERefundAddressNotFound: 4;
|
|
655
|
-
readonly
|
|
676
|
+
readonly Endpoint_EUnauthorizedOApp: 5;
|
|
677
|
+
readonly Endpoint_EUnauthorizedSendLibrary: 6;
|
|
656
678
|
};
|
|
657
679
|
declare class Endpoint {
|
|
658
680
|
#private;
|
|
@@ -671,9 +693,10 @@ declare class Endpoint {
|
|
|
671
693
|
* Register an OApp with the endpoint
|
|
672
694
|
* @param tx - The transaction to add the move call to
|
|
673
695
|
* @param oappCap - The OApp capability object ID or transaction argument
|
|
674
|
-
* @param
|
|
696
|
+
* @param oappInfo - OApp information including lz_receive execution information
|
|
697
|
+
* @returns Transaction result containing the messaging channel address
|
|
675
698
|
*/
|
|
676
|
-
registerOAppMoveCall(tx: Transaction, oappCap: string | TransactionArgument,
|
|
699
|
+
registerOAppMoveCall(tx: Transaction, oappCap: string | TransactionArgument, oappInfo: Uint8Array | TransactionArgument): TransactionResult;
|
|
677
700
|
/**
|
|
678
701
|
* Set a delegate for an OApp
|
|
679
702
|
* @param tx - The transaction to add the move call to
|
|
@@ -682,13 +705,13 @@ declare class Endpoint {
|
|
|
682
705
|
*/
|
|
683
706
|
setDelegateMoveCall(tx: Transaction, oappCap: string | TransactionArgument, newDelegate: string | TransactionArgument): void;
|
|
684
707
|
/**
|
|
685
|
-
* Set
|
|
708
|
+
* Set OApp information for an OApp
|
|
686
709
|
* @param tx - The transaction to add the move call to
|
|
687
710
|
* @param callerCap - The caller capability object ID or transaction argument
|
|
688
711
|
* @param oapp - The OApp address or transaction argument
|
|
689
|
-
* @param
|
|
712
|
+
* @param oappInfo - The OApp information including lz_receive execution information as bytes or transaction argument
|
|
690
713
|
*/
|
|
691
|
-
|
|
714
|
+
setOappInfoMoveCall(tx: Transaction, callerCap: string | TransactionArgument, oapp: string | TransactionArgument, oappInfo: Uint8Array | TransactionArgument): void;
|
|
692
715
|
/**
|
|
693
716
|
* Initialize a messaging channel between local and remote OApps
|
|
694
717
|
* @param tx - The transaction to add the move call to
|
|
@@ -828,16 +851,17 @@ declare class Endpoint {
|
|
|
828
851
|
* Register a composer with the endpoint
|
|
829
852
|
* @param tx - The transaction to add the move call to
|
|
830
853
|
* @param composerCap - The composer capability object ID or transaction argument
|
|
831
|
-
* @param
|
|
854
|
+
* @param composerInfo - Composer information including lz_compose execution information as bytes
|
|
855
|
+
* @returns Transaction result containing the compose queue address
|
|
832
856
|
*/
|
|
833
|
-
registerComposerMoveCall(tx: Transaction, composerCap: string | TransactionArgument,
|
|
857
|
+
registerComposerMoveCall(tx: Transaction, composerCap: string | TransactionArgument, composerInfo: Uint8Array | TransactionArgument): TransactionResult;
|
|
834
858
|
/**
|
|
835
|
-
* Set
|
|
859
|
+
* Set composer information for a composer
|
|
836
860
|
* @param tx - The transaction to add the move call to
|
|
837
861
|
* @param composerCap - The composer capability object ID or transaction argument
|
|
838
|
-
* @param
|
|
862
|
+
* @param composerInfo - Composer information including lz_compose execution information as bytes or transaction argument
|
|
839
863
|
*/
|
|
840
|
-
|
|
864
|
+
setComposerInfoMoveCall(tx: Transaction, composerCap: string | TransactionArgument, composerInfo: Uint8Array | TransactionArgument): void;
|
|
841
865
|
/**
|
|
842
866
|
* Send compose message to queue
|
|
843
867
|
* @param tx - The transaction to add the move call to
|
|
@@ -993,18 +1017,18 @@ declare class Endpoint {
|
|
|
993
1017
|
*/
|
|
994
1018
|
getMessagingChannel(oapp: string): Promise<string>;
|
|
995
1019
|
/**
|
|
996
|
-
* Get
|
|
1020
|
+
* Get OApp information for an OApp
|
|
997
1021
|
* @param tx - The transaction to add the move call to
|
|
998
1022
|
* @param oapp - The OApp address or transaction argument
|
|
999
|
-
* @returns Transaction result containing the
|
|
1023
|
+
* @returns Transaction result containing the OApp information including lz_receive execution information
|
|
1000
1024
|
*/
|
|
1001
|
-
|
|
1025
|
+
getOappInfoMoveCall(tx: Transaction, oapp: string | TransactionArgument): TransactionResult;
|
|
1002
1026
|
/**
|
|
1003
|
-
* Get
|
|
1027
|
+
* Get OApp information for an OApp
|
|
1004
1028
|
* @param oapp - The OApp address
|
|
1005
|
-
* @returns Promise<Uint8Array> - The
|
|
1029
|
+
* @returns Promise<Uint8Array> - The OApp information including lz_receive execution information as bytes
|
|
1006
1030
|
*/
|
|
1007
|
-
|
|
1031
|
+
getOappInfo(oapp: string): Promise<Uint8Array>;
|
|
1008
1032
|
/**
|
|
1009
1033
|
* Get delegate address for an OApp
|
|
1010
1034
|
* @param tx - The transaction to add the move call to
|
|
@@ -1045,18 +1069,18 @@ declare class Endpoint {
|
|
|
1045
1069
|
*/
|
|
1046
1070
|
getComposeQueue(composer: string): Promise<string>;
|
|
1047
1071
|
/**
|
|
1048
|
-
* Get
|
|
1072
|
+
* Get composer information for a registered composer
|
|
1049
1073
|
* @param tx - The transaction to add the move call to
|
|
1050
1074
|
* @param composer - The composer address or transaction argument
|
|
1051
|
-
* @returns Transaction result containing the
|
|
1075
|
+
* @returns Transaction result containing the composer information
|
|
1052
1076
|
*/
|
|
1053
|
-
|
|
1077
|
+
getComposerInfoMoveCall(tx: Transaction, composer: string | TransactionArgument): TransactionResult;
|
|
1054
1078
|
/**
|
|
1055
|
-
* Get
|
|
1079
|
+
* Get composer information for a registered composer
|
|
1056
1080
|
* @param composer - The composer address
|
|
1057
|
-
* @returns Promise<Uint8Array> - The
|
|
1081
|
+
* @returns Promise<Uint8Array> - The composer information as bytes
|
|
1058
1082
|
*/
|
|
1059
|
-
|
|
1083
|
+
getComposerInfo(composer: string): Promise<Uint8Array>;
|
|
1060
1084
|
/**
|
|
1061
1085
|
* Get composer address from compose queue
|
|
1062
1086
|
* @param tx - The transaction to add the move call to
|
|
@@ -1529,7 +1553,7 @@ declare class Endpoint {
|
|
|
1529
1553
|
* @throws Error if simulation fails or validation errors occur
|
|
1530
1554
|
* @returns Promise<MoveCall[]> - The final move calls that are built
|
|
1531
1555
|
*/
|
|
1532
|
-
populateLzReceiveTransaction(tx: Transaction, lzReceiveCall: TransactionResult, oapp: string, // receiver oapp
|
|
1556
|
+
populateLzReceiveTransaction(tx: Transaction, lzReceiveCall: TransactionResult, oapp: string | TransactionArgument, // receiver oapp
|
|
1533
1557
|
sender?: string | undefined, validators?: IPTBValidator[], maxSimulationTimes?: number): Promise<MoveCall[]>;
|
|
1534
1558
|
/**
|
|
1535
1559
|
* Populate a transaction with all necessary move calls for LayerZero compose
|
|
@@ -1545,7 +1569,7 @@ declare class Endpoint {
|
|
|
1545
1569
|
* @throws Error if simulation fails or validation errors occur
|
|
1546
1570
|
* @returns Promise<MoveCall[]> - The final move calls that are built
|
|
1547
1571
|
*/
|
|
1548
|
-
populateLzComposeTransaction(tx: Transaction, endpointLzComposeCall: TransactionResult, composer: string, sender?: string | undefined, validators?: IPTBValidator[], maxSimulationTimes?: number): Promise<MoveCall[]>;
|
|
1572
|
+
populateLzComposeTransaction(tx: Transaction, endpointLzComposeCall: TransactionResult, composer: string | TransactionArgument, sender?: string | undefined, validators?: IPTBValidator[], maxSimulationTimes?: number): Promise<MoveCall[]>;
|
|
1549
1573
|
}
|
|
1550
1574
|
|
|
1551
1575
|
declare const BlockedMessageLibErrorCode: {
|
|
@@ -1590,8 +1614,9 @@ declare class BlockedMessageLib {
|
|
|
1590
1614
|
}
|
|
1591
1615
|
|
|
1592
1616
|
declare const SimpleMessageLibErrorCode: {
|
|
1593
|
-
readonly
|
|
1617
|
+
readonly SimpleMessageLib_ENotImplemented: 1;
|
|
1594
1618
|
readonly SimpleMessageLib_EZROFeeNotEnabled: 2;
|
|
1619
|
+
readonly SimpleMessageLib_EInvalidEid: 3;
|
|
1595
1620
|
};
|
|
1596
1621
|
declare class SimpleMessageLib {
|
|
1597
1622
|
#private;
|
|
@@ -1698,10 +1723,22 @@ declare const Uln302ErrorCode: {
|
|
|
1698
1723
|
readonly ReceiveUln302_EInvalidEid: 3;
|
|
1699
1724
|
readonly ReceiveUln302_EOAppUlnConfigNotFound: 4;
|
|
1700
1725
|
readonly ReceiveUln302_EVerifying: 5;
|
|
1701
|
-
readonly
|
|
1702
|
-
readonly
|
|
1703
|
-
readonly
|
|
1704
|
-
readonly
|
|
1726
|
+
readonly Uln302_EInvalidConfigType: 1;
|
|
1727
|
+
readonly Uln302_EInvalidMessagingChannel: 2;
|
|
1728
|
+
readonly Uln302_EUnsupportedEid: 3;
|
|
1729
|
+
readonly UlnConfig_EAtLeastOneDVN: 1;
|
|
1730
|
+
readonly UlnConfig_EDuplicateOptionalDVNs: 2;
|
|
1731
|
+
readonly UlnConfig_EDuplicateRequiredDVNs: 3;
|
|
1732
|
+
readonly UlnConfig_EInvalidOptionalDVNCount: 4;
|
|
1733
|
+
readonly UlnConfig_EInvalidOptionalDVNThreshold: 5;
|
|
1734
|
+
readonly UlnConfig_EInvalidRequiredDVNCount: 6;
|
|
1735
|
+
readonly UlnConfig_EInvalidUlnConfigBytes: 7;
|
|
1736
|
+
readonly OAppUlnConfig_EInvalidConfirmations: 1;
|
|
1737
|
+
readonly OAppUlnConfig_EInvalidRequiredDVNs: 2;
|
|
1738
|
+
readonly OAppUlnConfig_EInvalidOptionalDVNs: 3;
|
|
1739
|
+
readonly ExecutorConfig_EInvalidExecutorAddress: 1;
|
|
1740
|
+
readonly ExecutorConfig_EInvalidExecutorBytes: 2;
|
|
1741
|
+
readonly ExecutorConfig_EZeroMessageSize: 3;
|
|
1705
1742
|
};
|
|
1706
1743
|
declare class Uln302 {
|
|
1707
1744
|
#private;
|
|
@@ -1756,16 +1793,13 @@ declare class Uln302 {
|
|
|
1756
1793
|
*/
|
|
1757
1794
|
setConfigMoveCall(tx: Transaction, call: TransactionArgument): void;
|
|
1758
1795
|
/**
|
|
1759
|
-
* Verify packet move call with DVN
|
|
1760
|
-
* Note: This is typically called by DVNs, not directly by users
|
|
1796
|
+
* Verify packet move call with DVN call (new API)
|
|
1797
|
+
* Note: This is typically called by DVNs via Call objects, not directly by users
|
|
1761
1798
|
* @param tx - The transaction to add the move call to
|
|
1762
1799
|
* @param verification - The verification object address or transaction argument
|
|
1763
|
-
* @param
|
|
1764
|
-
* @param packetHeader - The packet header as bytes or transaction argument
|
|
1765
|
-
* @param payloadHash - The payload hash as bytes or transaction argument
|
|
1766
|
-
* @param confirmations - Required confirmations count or transaction argument
|
|
1800
|
+
* @param call - The DVN verification call containing verification parameters
|
|
1767
1801
|
*/
|
|
1768
|
-
verifyMoveCall(tx: Transaction, verification: string | TransactionArgument,
|
|
1802
|
+
verifyMoveCall(tx: Transaction, verification: string | TransactionArgument, call: TransactionArgument): void;
|
|
1769
1803
|
/**
|
|
1770
1804
|
* Commit verification move call after all DVN verifications are complete
|
|
1771
1805
|
* Note: This is typically called by relayers/executors, not directly by users
|
|
@@ -2017,6 +2051,17 @@ declare const DVNErrorCode: {
|
|
|
2017
2051
|
readonly DVN_EEidNotSupported: 2;
|
|
2018
2052
|
readonly DVN_EHashAlreadyUsed: 3;
|
|
2019
2053
|
readonly DVN_EPtbBuilderAlreadyInitialized: 4;
|
|
2054
|
+
readonly Multisig_EDuplicatedSigner: 1;
|
|
2055
|
+
readonly Multisig_EInvalidSignatureLength: 2;
|
|
2056
|
+
readonly Multisig_EInvalidSignerLength: 3;
|
|
2057
|
+
readonly Multisig_EQuorumIsZero: 4;
|
|
2058
|
+
readonly Multisig_ESignaturesLessThanQuorum: 5;
|
|
2059
|
+
readonly Multisig_ESignerAlreadyExists: 6;
|
|
2060
|
+
readonly Multisig_ESignerNotFound: 7;
|
|
2061
|
+
readonly Multisig_ESignerNotInCommittee: 8;
|
|
2062
|
+
readonly Multisig_ESignersSizeIsLessThanQuorum: 9;
|
|
2063
|
+
readonly DVNInfoV1_EInvalidData: 1;
|
|
2064
|
+
readonly DVNInfoV1_EInvalidVersion: 2;
|
|
2020
2065
|
};
|
|
2021
2066
|
declare class DVN {
|
|
2022
2067
|
#private;
|
|
@@ -2101,6 +2146,16 @@ declare class DVN {
|
|
|
2101
2146
|
* @returns Transaction result containing the set PTB builder call
|
|
2102
2147
|
*/
|
|
2103
2148
|
setPtbBuilderMoveCallsMoveCall(tx: Transaction, adminCap: string | TransactionArgument, targetPtbBuilder: string | TransactionArgument, getFeeMoveCalls: TransactionArgument, assignJobMoveCalls: TransactionArgument, expiration: bigint | number | string | TransactionArgument, signatures: Uint8Array | TransactionArgument): TransactionResult;
|
|
2149
|
+
/**
|
|
2150
|
+
* Set supported message library (admin with signatures)
|
|
2151
|
+
* @param tx - The transaction to add the move call to
|
|
2152
|
+
* @param adminCap - The admin capability object ID
|
|
2153
|
+
* @param messageLib - The message library address
|
|
2154
|
+
* @param supported - Whether to support or remove support for the message library
|
|
2155
|
+
* @param expiration - Signature expiration timestamp
|
|
2156
|
+
* @param signatures - Multisig signatures for authorization
|
|
2157
|
+
*/
|
|
2158
|
+
setSupportedMessageLibMoveCall(tx: Transaction, adminCap: string | TransactionArgument, messageLib: string | TransactionArgument, supported: boolean | TransactionArgument, expiration: bigint | number | string | TransactionArgument, signatures: Uint8Array | TransactionArgument): void;
|
|
2104
2159
|
/**
|
|
2105
2160
|
* Set allowlist status for an OApp sender (admin with signatures)
|
|
2106
2161
|
* @param tx - The transaction to add the move call to
|
|
@@ -2159,17 +2214,18 @@ declare class DVN {
|
|
|
2159
2214
|
*/
|
|
2160
2215
|
quorumChangeAdminMoveCall(tx: Transaction, admin: string | TransactionArgument, active: boolean | TransactionArgument, expiration: bigint | number | string | TransactionArgument, signatures: Uint8Array | TransactionArgument): void;
|
|
2161
2216
|
/**
|
|
2162
|
-
* Verify a packet with DVN signatures (admin with signatures)
|
|
2217
|
+
* Verify a packet with DVN signatures (admin with signatures) - returns Call object for ULN302
|
|
2163
2218
|
* @param tx - The transaction to add the move call to
|
|
2164
2219
|
* @param adminCap - The admin capability object ID
|
|
2165
|
-
* @param
|
|
2220
|
+
* @param targetMessageLib - The target message library address (usually ULN302)
|
|
2166
2221
|
* @param packetHeader - The packet header as bytes
|
|
2167
2222
|
* @param payloadHash - The payload hash as bytes
|
|
2168
2223
|
* @param confirmations - Required confirmations count
|
|
2169
2224
|
* @param expiration - Signature expiration timestamp
|
|
2170
2225
|
* @param signatures - DVN multisig signatures
|
|
2226
|
+
* @returns Transaction result containing the verification Call object
|
|
2171
2227
|
*/
|
|
2172
|
-
verifyMoveCall(tx: Transaction, adminCap: string | TransactionArgument,
|
|
2228
|
+
verifyMoveCall(tx: Transaction, adminCap: string | TransactionArgument, targetMessageLib: string | TransactionArgument, packetHeader: Uint8Array | TransactionArgument, payloadHash: Uint8Array | TransactionArgument, confirmations: bigint | number | string | TransactionArgument, expiration: bigint | number | string | TransactionArgument, signatures: Uint8Array | TransactionArgument): TransactionResult;
|
|
2173
2229
|
/**
|
|
2174
2230
|
* Assign verification job for DVN (called via PTB with MultiCall created by send function in ULN302)
|
|
2175
2231
|
* @param tx - The transaction to add the move call to
|
|
@@ -2294,6 +2350,19 @@ declare class DVN {
|
|
|
2294
2350
|
* @returns Promise<boolean> - True if the address is an admin
|
|
2295
2351
|
*/
|
|
2296
2352
|
isAdminAddress(admin: string): Promise<boolean>;
|
|
2353
|
+
/**
|
|
2354
|
+
* Check if a message library is supported by this DVN
|
|
2355
|
+
* @param tx - The transaction to add the move call to
|
|
2356
|
+
* @param messageLib - The message library address to check
|
|
2357
|
+
* @returns Transaction result containing the support status
|
|
2358
|
+
*/
|
|
2359
|
+
isSupportedMessageLibMoveCall(tx: Transaction, messageLib: string | TransactionArgument): TransactionResult;
|
|
2360
|
+
/**
|
|
2361
|
+
* Check if a message library is supported by this DVN
|
|
2362
|
+
* @param messageLib - The message library address to check
|
|
2363
|
+
* @returns Promise<boolean> - True if the message library is supported
|
|
2364
|
+
*/
|
|
2365
|
+
isSupportedMessageLib(messageLib: string): Promise<boolean>;
|
|
2297
2366
|
/**
|
|
2298
2367
|
* Check if an address is allowlisted
|
|
2299
2368
|
* @param tx - The transaction to add the move call to
|
|
@@ -2458,6 +2527,20 @@ declare class DVN {
|
|
|
2458
2527
|
* @returns Promise<boolean> - True if the PTB builder has been initialized
|
|
2459
2528
|
*/
|
|
2460
2529
|
isPtbBuilderInitialized(): Promise<boolean>;
|
|
2530
|
+
/**
|
|
2531
|
+
* Get DVN object address from worker registry using this DVN's worker capability (as a move call)
|
|
2532
|
+
* This function chains Move calls to decode worker info and extract the DVN object address
|
|
2533
|
+
* @param tx - The transaction to add the move call to
|
|
2534
|
+
* @returns Transaction result containing the DVN object address
|
|
2535
|
+
*/
|
|
2536
|
+
getDvnObjectAddressMoveCall(tx: Transaction): TransactionResult;
|
|
2537
|
+
/**
|
|
2538
|
+
* Get DVN object address from worker registry using this DVN's worker capability
|
|
2539
|
+
* This function uses Move calls to decode worker info and extract the DVN object address
|
|
2540
|
+
* @returns Promise<string> - The DVN object address
|
|
2541
|
+
* @throws Will throw an error if worker info is not found or if decoding fails
|
|
2542
|
+
*/
|
|
2543
|
+
getDvnObjectAddress(): Promise<string>;
|
|
2461
2544
|
/**
|
|
2462
2545
|
* Create a LayerZero witness for DVN package whitelist registration
|
|
2463
2546
|
* @param tx - The transaction to add the move call to
|
|
@@ -2608,6 +2691,19 @@ declare class DVN {
|
|
|
2608
2691
|
* @returns Transaction result containing the set PTB builder move calls hash
|
|
2609
2692
|
*/
|
|
2610
2693
|
createSetPtbBuilderMoveCallsHashMoveCall(tx: Transaction, targetPtbBuilder: string | TransactionArgument, getFeeMoveCalls: TransactionArgument, assignJobMoveCalls: TransactionArgument, vid: number | TransactionArgument, expiration: bigint | number | string | TransactionArgument): TransactionResult;
|
|
2694
|
+
/**
|
|
2695
|
+
* Populate verify with DVN verification and ULN verify call
|
|
2696
|
+
* @param tx - The transaction to add the move call to
|
|
2697
|
+
* @param adminCap - The admin capability object ID
|
|
2698
|
+
* @param targetMessageLib - The target message library address (usually ULN302)
|
|
2699
|
+
* @param targetVerification - The verification object address for the target message library
|
|
2700
|
+
* @param packetHeader - The packet header as bytes
|
|
2701
|
+
* @param payloadHash - The payload hash as bytes
|
|
2702
|
+
* @param confirmations - Required confirmations count
|
|
2703
|
+
* @param expiration - Signature expiration timestamp
|
|
2704
|
+
* @param signatures - DVN multisig signatures
|
|
2705
|
+
*/
|
|
2706
|
+
populateVerify(tx: Transaction, adminCap: string | TransactionArgument, targetMessageLib: string, targetVerification: string, packetHeader: Uint8Array | TransactionArgument, payloadHash: Uint8Array | TransactionArgument, confirmations: bigint | number | string | TransactionArgument, expiration: bigint | number | string | TransactionArgument, signatures: Uint8Array | TransactionArgument): void;
|
|
2611
2707
|
}
|
|
2612
2708
|
|
|
2613
2709
|
declare const DVNFeeLibErrorCode: {
|
|
@@ -2647,6 +2743,9 @@ declare class DVNFeeLib {
|
|
|
2647
2743
|
confirmGetFeeMoveCall(tx: Transaction, feelibCall: TransactionArgument, priceFeedCall: TransactionArgument): void;
|
|
2648
2744
|
}
|
|
2649
2745
|
|
|
2746
|
+
declare const DVNLayerzeroErrorCode: {
|
|
2747
|
+
readonly DVNLayerzero_EWorkerCapNotFromPackage: 1;
|
|
2748
|
+
};
|
|
2650
2749
|
declare class DvnLayerZero {
|
|
2651
2750
|
#private;
|
|
2652
2751
|
private readonly moduleManager;
|
|
@@ -2660,6 +2759,7 @@ declare class DvnLayerZero {
|
|
|
2660
2759
|
* @param workerCap - Worker capability object ID or transaction argument
|
|
2661
2760
|
* @param vid - Verifier ID for the DVN or transaction argument
|
|
2662
2761
|
* @param depositAddress - Address for fee deposits or transaction argument
|
|
2762
|
+
* @param supportedMessageLibs - Array of supported message library addresses or transaction argument
|
|
2663
2763
|
* @param priceFeed - Price feed object address or transaction argument
|
|
2664
2764
|
* @param workerFeeLib - Worker fee library address or transaction argument
|
|
2665
2765
|
* @param defaultMultiplierBps - Default multiplier in basis points or transaction argument
|
|
@@ -2667,12 +2767,14 @@ declare class DvnLayerZero {
|
|
|
2667
2767
|
* @param signers - Array of signer public keys as bytes or transaction argument
|
|
2668
2768
|
* @param quorum - Required signature threshold or transaction argument
|
|
2669
2769
|
*/
|
|
2670
|
-
initDvnMoveCall(tx: Transaction, workerCap: string | TransactionArgument, vid: number | TransactionArgument, depositAddress: string | TransactionArgument, priceFeed: string | TransactionArgument, workerFeeLib: string | TransactionArgument, defaultMultiplierBps: number | TransactionArgument, admins: string[] | TransactionArgument, signers: Uint8Array[] | TransactionArgument, quorum: bigint | number | string | TransactionArgument): void;
|
|
2770
|
+
initDvnMoveCall(tx: Transaction, workerCap: string | TransactionArgument, vid: number | TransactionArgument, depositAddress: string | TransactionArgument, supportedMessageLibs: string[] | TransactionArgument, priceFeed: string | TransactionArgument, workerFeeLib: string | TransactionArgument, defaultMultiplierBps: number | TransactionArgument, admins: string[] | TransactionArgument, signers: Uint8Array[] | TransactionArgument, quorum: bigint | number | string | TransactionArgument): void;
|
|
2671
2771
|
}
|
|
2672
2772
|
|
|
2673
2773
|
declare const ExecutorErrorCode: {
|
|
2674
2774
|
readonly Executor_EEidNotSupported: 1;
|
|
2675
2775
|
readonly Executor_EInvalidNativeDropAmount: 2;
|
|
2776
|
+
readonly ExecutorInfoV1_EInvalidData: 1;
|
|
2777
|
+
readonly ExecutorInfoV1_EInvalidVersion: 2;
|
|
2676
2778
|
};
|
|
2677
2779
|
declare class Executor {
|
|
2678
2780
|
#private;
|
|
@@ -2851,6 +2953,14 @@ declare class Executor {
|
|
|
2851
2953
|
* @param active - Whether to grant or revoke admin role
|
|
2852
2954
|
*/
|
|
2853
2955
|
setAdminMoveCall(tx: Transaction, ownerCap: string | TransactionArgument, admin: string | TransactionArgument, active: boolean | TransactionArgument): void;
|
|
2956
|
+
/**
|
|
2957
|
+
* Set supported message library (owner only)
|
|
2958
|
+
* @param tx - The transaction to add the move call to
|
|
2959
|
+
* @param ownerCap - The owner capability object ID
|
|
2960
|
+
* @param messageLib - The message library address
|
|
2961
|
+
* @param supported - Whether to support or remove support for the message library
|
|
2962
|
+
*/
|
|
2963
|
+
setSupportedMessageLibMoveCall(tx: Transaction, ownerCap: string | TransactionArgument, messageLib: string | TransactionArgument, supported: boolean | TransactionArgument): void;
|
|
2854
2964
|
/**
|
|
2855
2965
|
* Set allowlist status for an OApp sender (owner only)
|
|
2856
2966
|
* @param tx - The transaction to add the move call to
|
|
@@ -2970,6 +3080,19 @@ declare class Executor {
|
|
|
2970
3080
|
* @returns Promise<boolean> - True if the address is an admin
|
|
2971
3081
|
*/
|
|
2972
3082
|
isAdminAddress(admin: string): Promise<boolean>;
|
|
3083
|
+
/**
|
|
3084
|
+
* Check if a message library is supported by this executor
|
|
3085
|
+
* @param tx - The transaction to add the move call to
|
|
3086
|
+
* @param messageLib - The message library address to check
|
|
3087
|
+
* @returns Transaction result containing the support status
|
|
3088
|
+
*/
|
|
3089
|
+
isSupportedMessageLibMoveCall(tx: Transaction, messageLib: string | TransactionArgument): TransactionResult;
|
|
3090
|
+
/**
|
|
3091
|
+
* Check if a message library is supported by this executor
|
|
3092
|
+
* @param messageLib - The message library address to check
|
|
3093
|
+
* @returns Promise<boolean> - True if the message library is supported
|
|
3094
|
+
*/
|
|
3095
|
+
isSupportedMessageLib(messageLib: string): Promise<boolean>;
|
|
2973
3096
|
/**
|
|
2974
3097
|
* Check if an address is allowlisted
|
|
2975
3098
|
* @param tx - The transaction to add the move call to
|
|
@@ -3066,13 +3189,33 @@ declare class Executor {
|
|
|
3066
3189
|
* @returns Promise<string> - The admin capability ID
|
|
3067
3190
|
*/
|
|
3068
3191
|
adminCapId(admin: string): Promise<string>;
|
|
3192
|
+
/**
|
|
3193
|
+
* Get Executor object address from worker registry using this Executor's worker capability (as a move call)
|
|
3194
|
+
* This function chains Move calls to decode worker info and extract the Executor object address
|
|
3195
|
+
* @param tx - The transaction to add the move call to
|
|
3196
|
+
* @returns Transaction result containing the Executor object address
|
|
3197
|
+
*/
|
|
3198
|
+
getExecutorObjectAddressMoveCall(tx: Transaction): TransactionResult;
|
|
3199
|
+
/**
|
|
3200
|
+
* Get Executor object address from worker registry using this Executor's worker capability
|
|
3201
|
+
* This function uses Move calls to decode worker info and extract the Executor object address
|
|
3202
|
+
* @returns Promise<string> - The Executor object address
|
|
3203
|
+
* @throws Will throw an error if worker info is not found or if decoding fails
|
|
3204
|
+
*/
|
|
3205
|
+
getExecutorObjectAddress(): Promise<string>;
|
|
3069
3206
|
private parseDstConfig;
|
|
3070
3207
|
}
|
|
3071
3208
|
|
|
3072
3209
|
declare const ExecutorFeeLibErrorCode: {
|
|
3073
3210
|
readonly ExecutorFeeLib_EEidNotSupported: 1;
|
|
3074
|
-
readonly
|
|
3075
|
-
readonly
|
|
3211
|
+
readonly ExecutorOption_ENoOptions: 1;
|
|
3212
|
+
readonly ExecutorOption_EUnsupportedOptionType: 2;
|
|
3213
|
+
readonly ExecutorOption_EZeroLzReceiveGasProvided: 3;
|
|
3214
|
+
readonly ExecutorOption_EZeroLzComposeGasProvided: 4;
|
|
3215
|
+
readonly ExecutorOption_ENativeAmountExceedsCap: 5;
|
|
3216
|
+
readonly ExecutorOption_EInvalidLzReceiveOption: 6;
|
|
3217
|
+
readonly ExecutorOption_EInvalidNativeDropOption: 7;
|
|
3218
|
+
readonly ExecutorOption_EInvalidLzComposeOption: 8;
|
|
3076
3219
|
};
|
|
3077
3220
|
declare class ExecutorFeeLib {
|
|
3078
3221
|
#private;
|
|
@@ -3105,6 +3248,9 @@ declare class ExecutorFeeLib {
|
|
|
3105
3248
|
confirmGetFeeMoveCall(tx: Transaction, feelibCall: TransactionArgument, priceFeedCall: TransactionArgument): void;
|
|
3106
3249
|
}
|
|
3107
3250
|
|
|
3251
|
+
declare const ExecutorLayerzeroErrorCode: {
|
|
3252
|
+
readonly ExecutorLayerzero_EWorkerCapNotFromPackage: 1;
|
|
3253
|
+
};
|
|
3108
3254
|
declare class ExecutorLayerZero {
|
|
3109
3255
|
#private;
|
|
3110
3256
|
private readonly moduleManager;
|
|
@@ -3117,13 +3263,14 @@ declare class ExecutorLayerZero {
|
|
|
3117
3263
|
* @param tx - The transaction to add the move call to
|
|
3118
3264
|
* @param workerCap - Worker capability object ID or transaction argument
|
|
3119
3265
|
* @param depositAddress - Address for fee deposits or transaction argument
|
|
3266
|
+
* @param supportedMessageLibs - Array of supported message library addresses or transaction argument
|
|
3120
3267
|
* @param priceFeed - Price feed object address or transaction argument
|
|
3121
3268
|
* @param workerFeeLib - Worker fee library address or transaction argument
|
|
3122
3269
|
* @param defaultMultiplierBps - Default multiplier in basis points or transaction argument
|
|
3123
3270
|
* @param owner - Owner address for the executor or transaction argument
|
|
3124
3271
|
* @param admins - Array of admin addresses or transaction argument
|
|
3125
3272
|
*/
|
|
3126
|
-
initExecutorMoveCall(tx: Transaction, workerCap: string | TransactionArgument, depositAddress: string | TransactionArgument, priceFeed: string | TransactionArgument, workerFeeLib: string | TransactionArgument, defaultMultiplierBps: number | TransactionArgument, owner: string | TransactionArgument, admins: string[] | TransactionArgument): void;
|
|
3273
|
+
initExecutorMoveCall(tx: Transaction, workerCap: string | TransactionArgument, depositAddress: string | TransactionArgument, supportedMessageLibs: string[] | TransactionArgument, priceFeed: string | TransactionArgument, workerFeeLib: string | TransactionArgument, defaultMultiplierBps: number | TransactionArgument, owner: string | TransactionArgument, admins: string[] | TransactionArgument): void;
|
|
3127
3274
|
}
|
|
3128
3275
|
|
|
3129
3276
|
declare const PriceFeedErrorCode: {
|
|
@@ -3338,9 +3485,9 @@ declare class PriceFeed {
|
|
|
3338
3485
|
}
|
|
3339
3486
|
|
|
3340
3487
|
declare const TreasuryErrorCode: {
|
|
3341
|
-
readonly
|
|
3342
|
-
readonly
|
|
3343
|
-
readonly
|
|
3488
|
+
readonly TREASURY_EInvalidFeeRecipient: 1;
|
|
3489
|
+
readonly TREASURY_EInvalidNativeFeeBp: 2;
|
|
3490
|
+
readonly TREASURY_EZroNotEnabled: 3;
|
|
3344
3491
|
};
|
|
3345
3492
|
declare class Treasury {
|
|
3346
3493
|
#private;
|
|
@@ -3451,6 +3598,55 @@ declare class Treasury {
|
|
|
3451
3598
|
feeEnabled(): Promise<boolean>;
|
|
3452
3599
|
}
|
|
3453
3600
|
|
|
3601
|
+
declare const WorkerRegistryErrorCode: {
|
|
3602
|
+
readonly EWorkerInfoInvalid: 1;
|
|
3603
|
+
readonly EWorkerInfoNotFound: 2;
|
|
3604
|
+
};
|
|
3605
|
+
/**
|
|
3606
|
+
* WorkerRegistry provides access to the worker registry contract functionality
|
|
3607
|
+
* This module maintains mappings between worker addresses and their associated information.
|
|
3608
|
+
*/
|
|
3609
|
+
declare class WorkerRegistry {
|
|
3610
|
+
#private;
|
|
3611
|
+
private readonly moduleManager;
|
|
3612
|
+
packageId: string;
|
|
3613
|
+
readonly client: SuiClient;
|
|
3614
|
+
private readonly objects;
|
|
3615
|
+
/**
|
|
3616
|
+
* Create a new WorkerRegistry instance
|
|
3617
|
+
* @param packageId - The package ID of the worker registry contract
|
|
3618
|
+
* @param client - The Sui client instance
|
|
3619
|
+
* @param objects - Object options containing contract object IDs
|
|
3620
|
+
* @param moduleManager - Module manager for handling dependencies
|
|
3621
|
+
*/
|
|
3622
|
+
constructor(packageId: string, client: SuiClient, objects: ObjectOptions, moduleManager: ModuleManager);
|
|
3623
|
+
/**
|
|
3624
|
+
* Get worker info for a specific worker address (as a move call)
|
|
3625
|
+
* This creates a move call that can be used in a PTB (Programmable Transaction Block)
|
|
3626
|
+
* @param tx - The transaction to add the move call to
|
|
3627
|
+
* @param worker - The worker address or transaction argument
|
|
3628
|
+
* @returns TransactionResult - The move call result containing worker info bytes
|
|
3629
|
+
* @throws Will throw an error if worker info is not found (EWorkerInfoNotFound)
|
|
3630
|
+
*/
|
|
3631
|
+
getWorkerInfoMoveCall(tx: Transaction, worker: string | TransactionArgument): TransactionResult;
|
|
3632
|
+
/**
|
|
3633
|
+
* Get worker info for a specific worker address
|
|
3634
|
+
* Executes the get_worker_info function and returns the worker information bytes
|
|
3635
|
+
* @param worker - The worker address to get info for
|
|
3636
|
+
* @returns Promise<Uint8Array> - The worker information bytes containing encoded worker data
|
|
3637
|
+
* @throws Will throw an error if worker info is not found (EWorkerInfoNotFound)
|
|
3638
|
+
*/
|
|
3639
|
+
getWorkerInfo(worker: string): Promise<Uint8Array>;
|
|
3640
|
+
/**
|
|
3641
|
+
* Check if worker info exists for a specific worker address
|
|
3642
|
+
* This is a convenience method that catches EWorkerInfoNotFound errors
|
|
3643
|
+
* @param worker - The worker address to check
|
|
3644
|
+
* @returns Promise<boolean> - True if worker info exists, false if not found
|
|
3645
|
+
* @throws Will re-throw any errors other than EWorkerInfoNotFound
|
|
3646
|
+
*/
|
|
3647
|
+
hasWorkerInfo(worker: string): Promise<boolean>;
|
|
3648
|
+
}
|
|
3649
|
+
|
|
3454
3650
|
declare class DvnPtbBuilder {
|
|
3455
3651
|
#private;
|
|
3456
3652
|
private readonly moduleManager;
|
|
@@ -3469,8 +3665,14 @@ declare class DvnPtbBuilder {
|
|
|
3469
3665
|
buildDvnPtbMoveCall(tx: Transaction, dvnAddress: string | TransactionArgument, feelibAddress: string | TransactionArgument, priceFeedAddress: string | TransactionArgument): TransactionResult;
|
|
3470
3666
|
}
|
|
3471
3667
|
|
|
3472
|
-
declare const
|
|
3473
|
-
readonly
|
|
3668
|
+
declare const EndpointPtbBuilderErrorCode: {
|
|
3669
|
+
readonly EndpointPtbBuilder_EBuilderNotFound: 1;
|
|
3670
|
+
readonly EndpointPtbBuilder_EBuilderRegistered: 2;
|
|
3671
|
+
readonly EndpointPtbBuilder_EBuilderUnsupported: 3;
|
|
3672
|
+
readonly EndpointPtbBuilder_EInvalidBounds: 4;
|
|
3673
|
+
readonly EndpointPtbBuilder_EInvalidBuilderAddress: 5;
|
|
3674
|
+
readonly EndpointPtbBuilder_EInvalidLibrary: 6;
|
|
3675
|
+
readonly EndpointPtbBuilder_EUnauthorized: 7;
|
|
3474
3676
|
};
|
|
3475
3677
|
declare class EndpointPtbBuilder {
|
|
3476
3678
|
#private;
|
|
@@ -3746,6 +3948,11 @@ declare class PackageWhitelistValidator {
|
|
|
3746
3948
|
validate(packageAddresses: string[]): Promise<boolean>;
|
|
3747
3949
|
}
|
|
3748
3950
|
|
|
3951
|
+
declare const PtbBuilderErrorCode: {
|
|
3952
|
+
readonly MoveCallsBuilder_EInvalidMoveCallResult: 1;
|
|
3953
|
+
readonly MoveCallsBuilder_EResultIDNotFound: 2;
|
|
3954
|
+
readonly Argument_EInvalidArgument: 1;
|
|
3955
|
+
};
|
|
3749
3956
|
declare class PtbBuilder {
|
|
3750
3957
|
#private;
|
|
3751
3958
|
packageId: string;
|
|
@@ -3814,6 +4021,9 @@ declare class SimpleMessageLibPtbBuilder {
|
|
|
3814
4021
|
getPtbBuilderInfoMoveCall(tx: Transaction): TransactionResult;
|
|
3815
4022
|
}
|
|
3816
4023
|
|
|
4024
|
+
declare const Uln302PtbBuilderErrorCode: {
|
|
4025
|
+
readonly Uln302PtbBuilder_EWorkerPtbsNotFound: 1;
|
|
4026
|
+
};
|
|
3817
4027
|
declare class Uln302PtbBuilder {
|
|
3818
4028
|
#private;
|
|
3819
4029
|
private readonly moduleManager;
|
|
@@ -3914,72 +4124,289 @@ declare class BlockedMessageLibPtbBuilder {
|
|
|
3914
4124
|
getPtbBuilderInfoMoveCall(tx: Transaction): TransactionResult;
|
|
3915
4125
|
}
|
|
3916
4126
|
|
|
3917
|
-
|
|
3918
|
-
|
|
3919
|
-
|
|
3920
|
-
|
|
3921
|
-
|
|
3922
|
-
|
|
3923
|
-
|
|
3924
|
-
|
|
3925
|
-
|
|
3926
|
-
|
|
3927
|
-
|
|
3928
|
-
|
|
3929
|
-
|
|
3930
|
-
|
|
3931
|
-
|
|
3932
|
-
|
|
3933
|
-
|
|
3934
|
-
|
|
3935
|
-
|
|
3936
|
-
|
|
3937
|
-
|
|
3938
|
-
|
|
3939
|
-
|
|
3940
|
-
|
|
4127
|
+
/**
|
|
4128
|
+
* Type guard to check if a value is already a TransactionArgument
|
|
4129
|
+
* TransactionArgument can be:
|
|
4130
|
+
* 1. Argument object with $kind property
|
|
4131
|
+
* 2. Synchronous function: (tx: Transaction) => Argument
|
|
4132
|
+
* 3. Asynchronous function: AsyncTransactionThunk
|
|
4133
|
+
*/
|
|
4134
|
+
declare function isTransactionArgument(value: unknown): value is TransactionArgument;
|
|
4135
|
+
/**
|
|
4136
|
+
* Convert value to TransactionArgument using a simple converter function
|
|
4137
|
+
* @param value - The value to convert (primitive type or TransactionArgument)
|
|
4138
|
+
* @param converter - Function to convert primitive type to TransactionArgument
|
|
4139
|
+
* @returns TransactionArgument
|
|
4140
|
+
*/
|
|
4141
|
+
declare function asArg<T>(value: T | TransactionArgument, converter: (val: T) => TransactionArgument): TransactionArgument;
|
|
4142
|
+
/**
|
|
4143
|
+
* Convert value to TransactionArgument using a converter that requires Transaction
|
|
4144
|
+
* @param tx - The transaction
|
|
4145
|
+
* @param value - The value to convert
|
|
4146
|
+
* @param converter - Function to convert value using transaction
|
|
4147
|
+
* @returns TransactionArgument
|
|
4148
|
+
*/
|
|
4149
|
+
declare function asArgWithTx<T>(tx: Transaction, value: T | TransactionArgument, converter: (tx: Transaction, val: T) => TransactionArgument): TransactionArgument;
|
|
4150
|
+
/**
|
|
4151
|
+
* Async version: Convert value to TransactionArgument using an async converter that requires Transaction
|
|
4152
|
+
* @param tx - The transaction
|
|
4153
|
+
* @param value - The value to convert
|
|
4154
|
+
* @param converter - Async function to convert value using transaction
|
|
4155
|
+
* @returns Promise<TransactionArgument>
|
|
4156
|
+
*/
|
|
4157
|
+
declare function asArgWithTxAsync<T>(tx: Transaction, value: T | TransactionArgument, converter: (tx: Transaction, val: T) => Promise<TransactionArgument>): Promise<TransactionArgument>;
|
|
4158
|
+
/**
|
|
4159
|
+
* Convert to object reference TransactionArgument
|
|
4160
|
+
*/
|
|
4161
|
+
declare function asObject(tx: Transaction, value: string | TransactionArgument): TransactionArgument;
|
|
4162
|
+
/**
|
|
4163
|
+
* Convert to address TransactionArgument
|
|
4164
|
+
*/
|
|
4165
|
+
declare function asAddress(tx: Transaction, value: string | TransactionArgument): TransactionArgument;
|
|
4166
|
+
/**
|
|
4167
|
+
* Convert to u8 TransactionArgument
|
|
4168
|
+
*/
|
|
4169
|
+
declare function asU8(tx: Transaction, value: number | TransactionArgument): TransactionArgument;
|
|
4170
|
+
/**
|
|
4171
|
+
* Convert to u16 TransactionArgument
|
|
4172
|
+
*/
|
|
4173
|
+
declare function asU16(tx: Transaction, value: number | TransactionArgument): TransactionArgument;
|
|
4174
|
+
/**
|
|
4175
|
+
* Convert to u32 TransactionArgument
|
|
4176
|
+
*/
|
|
4177
|
+
declare function asU32(tx: Transaction, value: number | TransactionArgument): TransactionArgument;
|
|
4178
|
+
/**
|
|
4179
|
+
* Convert to u64 TransactionArgument (supports bigint, number, or string)
|
|
4180
|
+
*/
|
|
4181
|
+
declare function asU64(tx: Transaction, value: bigint | number | string | TransactionArgument): TransactionArgument;
|
|
4182
|
+
/**
|
|
4183
|
+
* Convert to u128 TransactionArgument (supports bigint, number, or string)
|
|
4184
|
+
*/
|
|
4185
|
+
declare function asU128(tx: Transaction, value: bigint | number | string | TransactionArgument): TransactionArgument;
|
|
4186
|
+
/**
|
|
4187
|
+
* Convert to u256 TransactionArgument (supports bigint, number, or string)
|
|
4188
|
+
*/
|
|
4189
|
+
declare function asU256(tx: Transaction, value: bigint | number | string | TransactionArgument): TransactionArgument;
|
|
4190
|
+
/**
|
|
4191
|
+
* Convert Uint8Array to Bytes32 using moduleManager's fromBytesMoveCall
|
|
4192
|
+
* @param tx - The transaction
|
|
4193
|
+
* @param value - Uint8Array or TransactionArgument
|
|
4194
|
+
* @param utils - utils Module
|
|
4195
|
+
* @returns TransactionArgument
|
|
4196
|
+
*/
|
|
4197
|
+
declare function asBytes32(tx: Transaction, value: Uint8Array | TransactionArgument, utils: Utils): TransactionArgument;
|
|
4198
|
+
/**
|
|
4199
|
+
* Convert Uint8Array to serialized bytes vector TransactionArgument
|
|
4200
|
+
* @param tx - The transaction
|
|
4201
|
+
* @param value - Uint8Array or TransactionArgument
|
|
4202
|
+
* @returns TransactionArgument
|
|
4203
|
+
*/
|
|
4204
|
+
declare function asBytes(tx: Transaction, value: Uint8Array | TransactionArgument): TransactionArgument;
|
|
4205
|
+
/**
|
|
4206
|
+
* Convert Uint8Array Vector to serialized bytes vector TransactionArgument
|
|
4207
|
+
* @param tx - The transaction
|
|
4208
|
+
* @param value - Uint8Array or TransactionArgument
|
|
4209
|
+
* @returns TransactionArgument
|
|
4210
|
+
*/
|
|
4211
|
+
declare function asBytesVector(tx: Transaction, value: Uint8Array[] | TransactionArgument): TransactionArgument;
|
|
4212
|
+
/**
|
|
4213
|
+
* Convert string to string TransactionArgument
|
|
4214
|
+
* @param tx - The transaction
|
|
4215
|
+
* @param value - string or TransactionArgument
|
|
4216
|
+
* @returns TransactionArgument
|
|
4217
|
+
*/
|
|
4218
|
+
declare function asString(tx: Transaction, value: string | TransactionArgument): TransactionArgument;
|
|
4219
|
+
/**
|
|
4220
|
+
* Convert address array to serialized vector<address> TransactionArgument
|
|
4221
|
+
* @param tx - The transaction
|
|
4222
|
+
* @param value - string[] or TransactionArgument
|
|
4223
|
+
* @returns TransactionArgument
|
|
4224
|
+
*/
|
|
4225
|
+
declare function asAddressVector(tx: Transaction, value: string[] | TransactionArgument): TransactionArgument;
|
|
4226
|
+
/**
|
|
4227
|
+
* Convert boolean to boolean TransactionArgument
|
|
4228
|
+
* @param tx - The transaction
|
|
4229
|
+
* @param value - boolean or TransactionArgument
|
|
4230
|
+
* @returns TransactionArgument
|
|
4231
|
+
*/
|
|
4232
|
+
declare function asBool(tx: Transaction, value: boolean | TransactionArgument): TransactionArgument;
|
|
4233
|
+
|
|
4234
|
+
declare function simulateTransaction(suiClient: SuiClient, tx: Transaction, sender?: string): Promise<SimulateResult[]>;
|
|
4235
|
+
declare function simulateTransactionMultiResult(suiClient: SuiClient, tx: Transaction, resultIndex: number[], sender?: string): Promise<SimulateResult[][]>;
|
|
4236
|
+
declare function validateTransaction(client: SuiClient, signer: Keypair, tx: Transaction): Promise<SuiTransactionBlockResponse>;
|
|
4237
|
+
/**
|
|
4238
|
+
* Execute simulate using a moveCall function
|
|
4239
|
+
* @param client - The Sui client
|
|
4240
|
+
* @param moveCallFn - Function that adds moveCall to the transaction (supports both sync and async, any return type)
|
|
4241
|
+
* @param parser - Function to parse the result
|
|
4242
|
+
* @returns The parsed result
|
|
4243
|
+
*/
|
|
4244
|
+
declare function executeSimulate<T>(client: SuiClient, moveCallFn: (tx: Transaction) => unknown, parser: (result: {
|
|
4245
|
+
value: Uint8Array;
|
|
4246
|
+
}[]) => T): Promise<T>;
|
|
4247
|
+
declare function handleError(e: string): unknown;
|
|
4248
|
+
|
|
4249
|
+
/**
|
|
4250
|
+
* PackageAllowlistValidator ensures all function calls and objects belong to allowlisted packages
|
|
4251
|
+
* This validator checks that:
|
|
4252
|
+
* 1. All function calls target approved packages
|
|
4253
|
+
* 2. All object arguments come from approved packages
|
|
4254
|
+
*
|
|
4255
|
+
* If local packageWhitelist is empty, it will use the PTB whitelist contract for validation
|
|
4256
|
+
* If local packageWhitelist is provided, it will use only the local whitelist (contract is ignored)
|
|
4257
|
+
*/
|
|
4258
|
+
declare class PackageAllowlistValidator implements IPTBValidator {
|
|
4259
|
+
private packageWhitelist;
|
|
4260
|
+
private validator?;
|
|
4261
|
+
constructor(packageWhitelist?: string[], validator?: PackageWhitelistValidator);
|
|
3941
4262
|
/**
|
|
3942
|
-
*
|
|
3943
|
-
* @param
|
|
3944
|
-
* @
|
|
3945
|
-
* @param options - Execution options as bytes
|
|
3946
|
-
* @param payInZero - Whether to pay in ZRO tokens
|
|
3947
|
-
* @returns Promise<MessagingFee> - The calculated messaging fees
|
|
4263
|
+
* Validates that all function calls and object arguments belong to whitelisted packages
|
|
4264
|
+
* @param moveCallsWithDetails - Array of move calls with object details
|
|
4265
|
+
* @throws Error if any function call or object belongs to a non-whitelisted package
|
|
3948
4266
|
*/
|
|
3949
|
-
|
|
4267
|
+
validate(moveCallsWithDetails: MoveCallWithObjectDetails[]): Promise<void>;
|
|
3950
4268
|
/**
|
|
3951
|
-
*
|
|
3952
|
-
* @param
|
|
3953
|
-
* @
|
|
3954
|
-
* @param dstEid - Destination endpoint ID
|
|
3955
|
-
* @param msgType - Message type (SEND or SEND_AND_CALL)
|
|
3956
|
-
* @param options - Execution options as bytes
|
|
3957
|
-
* @param sendValue - Value to send with the message
|
|
3958
|
-
* @param nativeFee - Native token fee amount
|
|
3959
|
-
* @param zroFee - ZRO token fee amount
|
|
3960
|
-
* @param refundAddress - Address for fee refunds
|
|
4269
|
+
* Validate multiple packages at once
|
|
4270
|
+
* @param packages - Array of package IDs to validate
|
|
4271
|
+
* @returns Object mapping package ID to validation result
|
|
3961
4272
|
*/
|
|
3962
|
-
|
|
4273
|
+
private validatePackages;
|
|
3963
4274
|
/**
|
|
3964
|
-
*
|
|
4275
|
+
* Extracts package ID from object type string
|
|
4276
|
+
* Object types are in format: "packageId::module::struct<generics>"
|
|
4277
|
+
* @param objectType - The object type string
|
|
4278
|
+
* @returns The package ID or null if extraction fails
|
|
4279
|
+
*/
|
|
4280
|
+
private extractPackageIdFromType;
|
|
4281
|
+
/**
|
|
4282
|
+
* Get available packages for error messages
|
|
4283
|
+
*/
|
|
4284
|
+
private getAvailablePackagesList;
|
|
4285
|
+
}
|
|
4286
|
+
|
|
4287
|
+
/**
|
|
4288
|
+
* NonSenderObjectValidator ensures objects are not owned by the transaction sender
|
|
4289
|
+
*
|
|
4290
|
+
* In Sui, this validator checks that objects are:
|
|
4291
|
+
* - Shared: globally accessible, mutations require consensus
|
|
4292
|
+
* - Immutable: can't change after creation
|
|
4293
|
+
* - Owned by another address (not the sender)
|
|
4294
|
+
*
|
|
4295
|
+
* This prevents the sender from using their own owned objects in the transaction
|
|
4296
|
+
*/
|
|
4297
|
+
declare class NonSenderObjectValidator implements IPTBValidator {
|
|
4298
|
+
private sender;
|
|
4299
|
+
constructor(sender: string);
|
|
4300
|
+
/**
|
|
4301
|
+
* Validates that objects are not owned by the sender
|
|
4302
|
+
* @param moveCallsWithDetails - Array of move calls with object details
|
|
4303
|
+
* @throws Error if any object is owned by the sender
|
|
4304
|
+
*/
|
|
4305
|
+
validate(moveCallsWithDetails: MoveCallWithObjectDetails[]): void;
|
|
4306
|
+
/**
|
|
4307
|
+
* Checks if the ownership is valid (not owned by sender)
|
|
4308
|
+
* @param owner - The object owner to check
|
|
4309
|
+
* @returns true if ownership is valid (Shared, Immutable, or owned by another address)
|
|
4310
|
+
*/
|
|
4311
|
+
private isValidOwnership;
|
|
4312
|
+
/**
|
|
4313
|
+
* Gets a human-readable description of the ownership type
|
|
4314
|
+
* @param owner - The object owner
|
|
4315
|
+
* @returns String description of ownership type
|
|
4316
|
+
*/
|
|
4317
|
+
private getOwnershipType;
|
|
4318
|
+
}
|
|
4319
|
+
|
|
4320
|
+
/**
|
|
4321
|
+
* ShareObjectValidator ensures all object arguments are Shared or Immutable
|
|
4322
|
+
* This is the default validator for PTB operations
|
|
4323
|
+
*/
|
|
4324
|
+
declare class ShareObjectValidator implements IPTBValidator {
|
|
4325
|
+
/**
|
|
4326
|
+
* Validates move calls with pre-fetched object details
|
|
4327
|
+
* @param moveCallsWithDetails - Array of move calls with object details
|
|
4328
|
+
* @throws Error if any object is not Shared/Immutable
|
|
4329
|
+
*/
|
|
4330
|
+
validate(moveCallsWithDetails: MoveCallWithObjectDetails[]): void;
|
|
4331
|
+
/**
|
|
4332
|
+
* Checks if an object owner is Shared or Immutable
|
|
4333
|
+
* @param owner - The object owner to check
|
|
4334
|
+
* @returns true if the owner is Shared or Immutable, false otherwise
|
|
4335
|
+
*/
|
|
4336
|
+
protected isSharedOrImmutable(owner: ObjectOwner): boolean;
|
|
4337
|
+
}
|
|
4338
|
+
|
|
4339
|
+
/**
|
|
4340
|
+
* Validates move calls using multiple validators with a single object fetch
|
|
4341
|
+
* @param client - SuiClient instance
|
|
4342
|
+
* @param moveCalls - Array of move calls to validate
|
|
4343
|
+
* @param validators - Array of validators to run
|
|
4344
|
+
* @param options - Options for what object data to fetch
|
|
4345
|
+
* @param batchSize - Batch size for object fetching
|
|
4346
|
+
*/
|
|
4347
|
+
declare function validateWithDetails(client: SuiClient, moveCalls: MoveCall[], validators: IPTBValidator[], sender?: string, userOptions?: ObjectFetchOptions, batchSize?: number): Promise<void>;
|
|
4348
|
+
|
|
4349
|
+
declare const CounterErrorCode: {
|
|
4350
|
+
readonly Counter_EInvalidMsgType: 0;
|
|
4351
|
+
readonly Counter_EInvalidValue: 1;
|
|
4352
|
+
readonly Counter_EInvalidNonce: 2;
|
|
4353
|
+
readonly Counter_EOnlyEndpoint: 3;
|
|
4354
|
+
readonly Counter_ESelfComposeOnly: 4;
|
|
4355
|
+
readonly Counter_EInvalidOApp: 5;
|
|
4356
|
+
readonly OptionsBuilder_EInvalidSize: 1;
|
|
4357
|
+
};
|
|
4358
|
+
declare class Counter {
|
|
4359
|
+
#private;
|
|
4360
|
+
private readonly moduleManager;
|
|
4361
|
+
packageId: string;
|
|
4362
|
+
readonly client: SuiClient;
|
|
4363
|
+
private readonly objects;
|
|
4364
|
+
constructor(packageId: string, client: SuiClient, objects: ObjectOptions, moduleManager: ModuleManager);
|
|
4365
|
+
/**
|
|
4366
|
+
* Initialize counter with LayerZero receive and compose information
|
|
3965
4367
|
* @param tx - The transaction to add the move call to
|
|
3966
|
-
* @param
|
|
3967
|
-
* @param
|
|
3968
|
-
* @param peer - The peer counter address as bytes or transaction argument
|
|
4368
|
+
* @param lzReceiveInfo - LayerZero receive information transaction argument
|
|
4369
|
+
* @param lzComposeInfo - LayerZero compose information transaction argument
|
|
3969
4370
|
*/
|
|
3970
|
-
|
|
4371
|
+
initCounterMoveCall(tx: Transaction, lzReceiveInfo: TransactionArgument, lzComposeInfo: TransactionArgument): void;
|
|
3971
4372
|
/**
|
|
3972
|
-
*
|
|
4373
|
+
* Quote messaging fees for sending counter increment
|
|
4374
|
+
* @param dstEid - Destination endpoint ID
|
|
4375
|
+
* @param msgType - Message type (SEND or SEND_AND_CALL)
|
|
4376
|
+
* @param options - Execution options as bytes
|
|
4377
|
+
* @param payInZero - Whether to pay in ZRO tokens
|
|
4378
|
+
* @returns Promise<MessagingFee> - The calculated messaging fees
|
|
4379
|
+
*/
|
|
4380
|
+
quote(dstEid: EndpointId | TransactionArgument, msgType: number | TransactionArgument, options: Uint8Array | TransactionArgument, payInZero: boolean | TransactionArgument, validators?: IPTBValidator[]): Promise<MessagingFee>;
|
|
4381
|
+
/**
|
|
4382
|
+
* Increment counter on destination chain
|
|
3973
4383
|
* @param tx - The transaction to add the move call to
|
|
3974
|
-
* @param
|
|
4384
|
+
* @param sender - Sender address for ZRO token operations
|
|
4385
|
+
* @param dstEid - Destination endpoint ID
|
|
4386
|
+
* @param msgType - Message type (SEND or SEND_AND_CALL)
|
|
4387
|
+
* @param options - Execution options as bytes
|
|
4388
|
+
* @param nativeFee - Native token fee amount
|
|
4389
|
+
* @param zroFee - ZRO token fee amount
|
|
4390
|
+
* @param refundAddress - Address for fee refunds
|
|
4391
|
+
*/
|
|
4392
|
+
incrementMoveCall(tx: Transaction, sender: string, dstEid: EndpointId | TransactionArgument, msgType: number | TransactionArgument, options: Uint8Array | TransactionArgument, nativeFee: bigint | TransactionArgument, zroFee: bigint | TransactionArgument, refundAddress: string | TransactionArgument, validators?: IPTBValidator[]): Promise<void>;
|
|
4393
|
+
/**
|
|
4394
|
+
* Set composer information for counter
|
|
4395
|
+
* @param tx - The transaction to add the move call to
|
|
4396
|
+
* @param composerInfo - Composer information including lz_compose execution information as bytes
|
|
3975
4397
|
*/
|
|
3976
|
-
|
|
4398
|
+
setComposerInfoMoveCall(tx: Transaction, composerInfo: Uint8Array | TransactionArgument): void;
|
|
3977
4399
|
/**
|
|
3978
|
-
*
|
|
4400
|
+
* Get counter EID
|
|
3979
4401
|
* @param tx - The transaction to add the move call to
|
|
3980
|
-
* @
|
|
4402
|
+
* @returns Transaction result containing the counter EID
|
|
4403
|
+
*/
|
|
4404
|
+
getEidMoveCall(tx: Transaction): TransactionResult;
|
|
4405
|
+
/**
|
|
4406
|
+
* Get counter EID
|
|
4407
|
+
* @returns Promise<number> - The counter EID
|
|
3981
4408
|
*/
|
|
3982
|
-
|
|
4409
|
+
getEid(): Promise<number>;
|
|
3983
4410
|
/**
|
|
3984
4411
|
* Get call capability address for counter
|
|
3985
4412
|
* @param tx - The transaction to add the move call to
|
|
@@ -4060,25 +4487,38 @@ declare class Counter {
|
|
|
4060
4487
|
lzComposeInfoMoveCall(tx: Transaction): TransactionResult;
|
|
4061
4488
|
}
|
|
4062
4489
|
|
|
4490
|
+
interface OAppInfoV1 {
|
|
4491
|
+
oapp_object: string;
|
|
4492
|
+
next_nonce_info: number[];
|
|
4493
|
+
lz_receive_info: number[];
|
|
4494
|
+
extra_info: number[];
|
|
4495
|
+
}
|
|
4496
|
+
|
|
4063
4497
|
declare const OAppErrorCode: {
|
|
4064
|
-
readonly
|
|
4065
|
-
readonly
|
|
4066
|
-
readonly
|
|
4067
|
-
readonly
|
|
4068
|
-
readonly
|
|
4069
|
-
readonly
|
|
4070
|
-
readonly
|
|
4071
|
-
readonly
|
|
4072
|
-
readonly
|
|
4073
|
-
readonly
|
|
4498
|
+
readonly OApp_EInvalidAdminCap: 1;
|
|
4499
|
+
readonly OApp_EInvalidOAppCap: 2;
|
|
4500
|
+
readonly OApp_EInvalidRefundAddress: 3;
|
|
4501
|
+
readonly OApp_EInvalidSendingCall: 4;
|
|
4502
|
+
readonly OApp_EOnlyEndpoint: 5;
|
|
4503
|
+
readonly OApp_EOnlyPeer: 6;
|
|
4504
|
+
readonly OApp_ESendingInProgress: 7;
|
|
4505
|
+
readonly OAppPeer_EPeerNotFound: 0;
|
|
4506
|
+
readonly OAppPeer_EInvalidPeer: 1;
|
|
4507
|
+
readonly EnforcedOptions_EEnforcedOptionsNotFound: 1;
|
|
4508
|
+
readonly EnforcedOptions_EInvalidOptionsLength: 2;
|
|
4509
|
+
readonly EnforcedOptions_EInvalidOptionsType: 3;
|
|
4510
|
+
readonly OAppInfoV1_EInvalidData: 1;
|
|
4511
|
+
readonly OAppInfoV1_EInvalidVersion: 2;
|
|
4074
4512
|
};
|
|
4075
4513
|
declare class OApp {
|
|
4076
4514
|
#private;
|
|
4077
4515
|
private readonly moduleManager;
|
|
4078
4516
|
packageId: string;
|
|
4517
|
+
oappCallCapId: string;
|
|
4079
4518
|
readonly client: SuiClient;
|
|
4519
|
+
oappInfo: OAppInfoV1 | null;
|
|
4080
4520
|
private readonly objects;
|
|
4081
|
-
constructor(packageId: string, client: SuiClient, objects: ObjectOptions, moduleManager: ModuleManager);
|
|
4521
|
+
constructor(packageId: string, oappCallCapId: string, client: SuiClient, objects: ObjectOptions, moduleManager: ModuleManager);
|
|
4082
4522
|
/**
|
|
4083
4523
|
* Set enforced options for OApp messaging
|
|
4084
4524
|
* @param tx - The transaction to add the move call to
|
|
@@ -4088,7 +4528,7 @@ declare class OApp {
|
|
|
4088
4528
|
* @param msgType - Message type or transaction argument
|
|
4089
4529
|
* @param options - Enforced options as bytes or transaction argument
|
|
4090
4530
|
*/
|
|
4091
|
-
setEnforcedOptionsMoveCall(tx: Transaction,
|
|
4531
|
+
setEnforcedOptionsMoveCall(tx: Transaction, eid: number | TransactionArgument, msgType: number | TransactionArgument, options: Uint8Array | TransactionArgument): Promise<void>;
|
|
4092
4532
|
/**
|
|
4093
4533
|
* Set peer OApp on another chain
|
|
4094
4534
|
* @param tx - The transaction to add the move call to
|
|
@@ -4097,33 +4537,33 @@ declare class OApp {
|
|
|
4097
4537
|
* @param eid - Peer endpoint ID or transaction argument
|
|
4098
4538
|
* @param peer - Peer OApp address as bytes or transaction argument
|
|
4099
4539
|
*/
|
|
4100
|
-
setPeerMoveCall(tx: Transaction,
|
|
4540
|
+
setPeerMoveCall(tx: Transaction, eid: number | TransactionArgument, peer: Uint8Array | TransactionArgument): Promise<void>;
|
|
4101
4541
|
/**
|
|
4102
|
-
* Get admin address for OApp
|
|
4542
|
+
* Get admin capability address for OApp
|
|
4103
4543
|
* @param tx - The transaction to add the move call to
|
|
4104
4544
|
* @param oapp - The OApp object ID or transaction argument
|
|
4105
|
-
* @returns Transaction result containing the admin address
|
|
4545
|
+
* @returns Transaction result containing the admin capability address
|
|
4106
4546
|
*/
|
|
4107
|
-
|
|
4547
|
+
getAdminCapMoveCall(tx: Transaction, oapp: string | TransactionArgument): TransactionResult;
|
|
4108
4548
|
/**
|
|
4109
|
-
* Get admin address for OApp
|
|
4549
|
+
* Get admin capability address for OApp
|
|
4110
4550
|
* @param oapp - The OApp object ID
|
|
4111
|
-
* @returns Promise<string> - The admin address
|
|
4551
|
+
* @returns Promise<string> - The admin capability address
|
|
4112
4552
|
*/
|
|
4113
|
-
|
|
4553
|
+
getAdminCap(oapp: string): Promise<string>;
|
|
4114
4554
|
/**
|
|
4115
|
-
* Get OApp
|
|
4555
|
+
* Get OApp CallCap identifier
|
|
4116
4556
|
* @param tx - The transaction to add the move call to
|
|
4117
4557
|
* @param oapp - The OApp object ID or transaction argument
|
|
4118
|
-
* @returns Transaction result containing the OApp
|
|
4558
|
+
* @returns Transaction result containing the OApp CallCap identifier
|
|
4119
4559
|
*/
|
|
4120
|
-
|
|
4560
|
+
getOAppCapIdMoveCall(tx: Transaction): Promise<TransactionResult>;
|
|
4121
4561
|
/**
|
|
4122
|
-
* Get OApp
|
|
4123
|
-
* @param oapp - The OApp object ID
|
|
4124
|
-
* @returns Promise<string> - The OApp
|
|
4562
|
+
* Get OApp CallCap identifier
|
|
4563
|
+
* @param oapp - The OApp object ID (optional, uses configured oapp if not provided)
|
|
4564
|
+
* @returns Promise<string> - The OApp CallCap identifier
|
|
4125
4565
|
*/
|
|
4126
|
-
|
|
4566
|
+
getOAppCapId(): Promise<string>;
|
|
4127
4567
|
/**
|
|
4128
4568
|
* Combine enforced options with extra options for message execution
|
|
4129
4569
|
* @param tx - The transaction to add the move call to
|
|
@@ -4133,7 +4573,7 @@ declare class OApp {
|
|
|
4133
4573
|
* @param extraOptions - Extra options to combine with enforced options or transaction argument
|
|
4134
4574
|
* @returns Transaction result containing combined options
|
|
4135
4575
|
*/
|
|
4136
|
-
combineOptionsMoveCall(tx: Transaction,
|
|
4576
|
+
combineOptionsMoveCall(tx: Transaction, eid: number | TransactionArgument, msgType: number | TransactionArgument, extraOptions: Uint8Array | TransactionArgument): Promise<TransactionResult>;
|
|
4137
4577
|
/**
|
|
4138
4578
|
* Combine enforced options with extra options for message execution
|
|
4139
4579
|
* @param oapp - The OApp object ID
|
|
@@ -4142,7 +4582,7 @@ declare class OApp {
|
|
|
4142
4582
|
* @param extraOptions - Extra options to combine with enforced options
|
|
4143
4583
|
* @returns Promise<Uint8Array> - Combined options as bytes
|
|
4144
4584
|
*/
|
|
4145
|
-
combineOptions(
|
|
4585
|
+
combineOptions(eid: number, msgType: number, extraOptions: Uint8Array): Promise<Uint8Array>;
|
|
4146
4586
|
/**
|
|
4147
4587
|
* Get enforced options for a specific destination and message type
|
|
4148
4588
|
* @param tx - The transaction to add the move call to
|
|
@@ -4151,7 +4591,7 @@ declare class OApp {
|
|
|
4151
4591
|
* @param msgType - Message type or transaction argument
|
|
4152
4592
|
* @returns Transaction result containing enforced options
|
|
4153
4593
|
*/
|
|
4154
|
-
getEnforcedOptionsMoveCall(tx: Transaction,
|
|
4594
|
+
getEnforcedOptionsMoveCall(tx: Transaction, eid: number | TransactionArgument, msgType: number | TransactionArgument): Promise<TransactionResult>;
|
|
4155
4595
|
/**
|
|
4156
4596
|
* Get enforced options for a specific destination and message type
|
|
4157
4597
|
* @param oapp - The OApp object ID
|
|
@@ -4159,7 +4599,7 @@ declare class OApp {
|
|
|
4159
4599
|
* @param msgType - Message type
|
|
4160
4600
|
* @returns Promise<Uint8Array> - Enforced options as bytes
|
|
4161
4601
|
*/
|
|
4162
|
-
getEnforcedOptions(
|
|
4602
|
+
getEnforcedOptions(eid: number, msgType: number): Promise<Uint8Array>;
|
|
4163
4603
|
/**
|
|
4164
4604
|
* Check if a peer is configured for a specific destination chain
|
|
4165
4605
|
* @param tx - The transaction to add the move call to
|
|
@@ -4167,14 +4607,14 @@ declare class OApp {
|
|
|
4167
4607
|
* @param dstEid - Destination endpoint ID or transaction argument
|
|
4168
4608
|
* @returns Transaction result containing boolean result
|
|
4169
4609
|
*/
|
|
4170
|
-
hasPeerMoveCall(tx: Transaction,
|
|
4610
|
+
hasPeerMoveCall(tx: Transaction, dstEid: number | TransactionArgument): Promise<TransactionResult>;
|
|
4171
4611
|
/**
|
|
4172
4612
|
* Check if a peer is configured for a specific destination chain
|
|
4173
4613
|
* @param oapp - The OApp object ID
|
|
4174
4614
|
* @param dstEid - Destination endpoint ID
|
|
4175
4615
|
* @returns Promise<boolean> - True if peer is configured, false otherwise
|
|
4176
4616
|
*/
|
|
4177
|
-
hasPeer(
|
|
4617
|
+
hasPeer(dstEid: number): Promise<boolean>;
|
|
4178
4618
|
/**
|
|
4179
4619
|
* Get the configured peer address for a specific destination chain
|
|
4180
4620
|
* @param tx - The transaction to add the move call to
|
|
@@ -4182,14 +4622,111 @@ declare class OApp {
|
|
|
4182
4622
|
* @param dstEid - Destination endpoint ID or transaction argument
|
|
4183
4623
|
* @returns Transaction result containing peer address
|
|
4184
4624
|
*/
|
|
4185
|
-
getPeerMoveCall(tx: Transaction,
|
|
4625
|
+
getPeerMoveCall(tx: Transaction, dstEid: number | TransactionArgument): Promise<TransactionResult>;
|
|
4186
4626
|
/**
|
|
4187
4627
|
* Get the configured peer address for a specific destination chain
|
|
4188
4628
|
* @param oapp - The OApp object ID
|
|
4189
4629
|
* @param dstEid - Destination endpoint ID
|
|
4190
4630
|
* @returns Promise<Uint8Array> - Peer address as bytes32
|
|
4191
4631
|
*/
|
|
4192
|
-
getPeer(
|
|
4632
|
+
getPeer(dstEid: number): Promise<Uint8Array>;
|
|
4633
|
+
getOAppInfoV1MoveCall(tx: Transaction): TransactionResult;
|
|
4634
|
+
getOAppInfoV1(): Promise<OAppInfoV1>;
|
|
4635
|
+
/**
|
|
4636
|
+
* Register OApp with the endpoint
|
|
4637
|
+
* @param tx - The transaction to add the move call to
|
|
4638
|
+
* @param oappInfo - OApp information as bytes (optional)
|
|
4639
|
+
* @returns Transaction result containing the messaging channel address
|
|
4640
|
+
*/
|
|
4641
|
+
registerOAppMoveCall(tx: Transaction, oappInfo?: Uint8Array | TransactionArgument): Promise<TransactionResult>;
|
|
4642
|
+
/**
|
|
4643
|
+
* Set delegate for OApp
|
|
4644
|
+
* @param tx - The transaction to add the move call to
|
|
4645
|
+
* @param newDelegate - New delegate address
|
|
4646
|
+
*/
|
|
4647
|
+
setDelegateMoveCall(tx: Transaction, newDelegate: string | TransactionArgument): Promise<void>;
|
|
4648
|
+
/**
|
|
4649
|
+
* Set OApp information in the endpoint
|
|
4650
|
+
* @param tx - The transaction to add the move call to
|
|
4651
|
+
* @param oappInfo - OApp information as bytes
|
|
4652
|
+
*/
|
|
4653
|
+
setOAppInfoMoveCall(tx: Transaction, oappInfo: Uint8Array | TransactionArgument): Promise<void>;
|
|
4654
|
+
/**
|
|
4655
|
+
* Initialize channel with remote OApp
|
|
4656
|
+
* @param tx - The transaction to add the move call to
|
|
4657
|
+
* @param remoteEid - Remote endpoint ID
|
|
4658
|
+
* @param remoteOApp - Remote OApp address as bytes32
|
|
4659
|
+
*/
|
|
4660
|
+
initChannelMoveCall(tx: Transaction, remoteEid: number | TransactionArgument, remoteOApp: Uint8Array | TransactionArgument): Promise<void>;
|
|
4661
|
+
/**
|
|
4662
|
+
* Clear a message from the messaging channel
|
|
4663
|
+
* @param tx - The transaction to add the move call to
|
|
4664
|
+
* @param srcEid - Source endpoint ID
|
|
4665
|
+
* @param sender - Sender address as bytes32
|
|
4666
|
+
* @param nonce - Message nonce
|
|
4667
|
+
* @param guid - Message GUID as bytes32
|
|
4668
|
+
* @param message - Message payload
|
|
4669
|
+
*/
|
|
4670
|
+
clearMoveCall(tx: Transaction, srcEid: number | TransactionArgument, sender: Uint8Array | TransactionArgument, nonce: number | bigint | TransactionArgument, guid: Uint8Array | TransactionArgument, message: Uint8Array | TransactionArgument): Promise<void>;
|
|
4671
|
+
/**
|
|
4672
|
+
* Skip a message in the messaging channel
|
|
4673
|
+
* @param tx - The transaction to add the move call to
|
|
4674
|
+
* @param srcEid - Source endpoint ID
|
|
4675
|
+
* @param sender - Sender address as bytes32
|
|
4676
|
+
* @param nonce - Message nonce
|
|
4677
|
+
*/
|
|
4678
|
+
skipMoveCall(tx: Transaction, srcEid: number | TransactionArgument, sender: Uint8Array | TransactionArgument, nonce: number | bigint | TransactionArgument): Promise<void>;
|
|
4679
|
+
/**
|
|
4680
|
+
* Nilify a message in the messaging channel
|
|
4681
|
+
* @param tx - The transaction to add the move call to
|
|
4682
|
+
* @param srcEid - Source endpoint ID
|
|
4683
|
+
* @param sender - Sender address as bytes32
|
|
4684
|
+
* @param nonce - Message nonce
|
|
4685
|
+
* @param payloadHash - Payload hash as bytes32
|
|
4686
|
+
*/
|
|
4687
|
+
nilifyMoveCall(tx: Transaction, srcEid: number | TransactionArgument, sender: Uint8Array | TransactionArgument, nonce: number | bigint | TransactionArgument, payloadHash: Uint8Array | TransactionArgument): Promise<void>;
|
|
4688
|
+
/**
|
|
4689
|
+
* Burn a message in the messaging channel
|
|
4690
|
+
* @param tx - The transaction to add the move call to
|
|
4691
|
+
* @param srcEid - Source endpoint ID
|
|
4692
|
+
* @param sender - Sender address as bytes32
|
|
4693
|
+
* @param nonce - Message nonce
|
|
4694
|
+
* @param payloadHash - Payload hash as bytes32
|
|
4695
|
+
*/
|
|
4696
|
+
burnMoveCall(tx: Transaction, srcEid: number | TransactionArgument, sender: Uint8Array | TransactionArgument, nonce: number | bigint | TransactionArgument, payloadHash: Uint8Array | TransactionArgument): Promise<void>;
|
|
4697
|
+
/**
|
|
4698
|
+
* Set send library for a destination chain
|
|
4699
|
+
* @param tx - The transaction to add the move call to
|
|
4700
|
+
* @param dstEid - Destination endpoint ID
|
|
4701
|
+
* @param sendLibrary - Send library address
|
|
4702
|
+
*/
|
|
4703
|
+
setSendLibraryMoveCall(tx: Transaction, dstEid: number | TransactionArgument, sendLibrary: string | TransactionArgument): Promise<void>;
|
|
4704
|
+
/**
|
|
4705
|
+
* Set receive library for a source chain
|
|
4706
|
+
* @param tx - The transaction to add the move call to
|
|
4707
|
+
* @param srcEid - Source endpoint ID
|
|
4708
|
+
* @param receiveLibrary - Receive library address
|
|
4709
|
+
* @param gracePeriod - Grace period in seconds
|
|
4710
|
+
*/
|
|
4711
|
+
setReceiveLibraryMoveCall(tx: Transaction, srcEid: number | TransactionArgument, receiveLibrary: string | TransactionArgument, gracePeriod: number | bigint | TransactionArgument): Promise<void>;
|
|
4712
|
+
/**
|
|
4713
|
+
* Set receive library timeout for a source chain
|
|
4714
|
+
* @param tx - The transaction to add the move call to
|
|
4715
|
+
* @param srcEid - Source endpoint ID
|
|
4716
|
+
* @param receiveLibrary - Receive library address
|
|
4717
|
+
* @param expiry - Expiry timestamp in seconds
|
|
4718
|
+
*/
|
|
4719
|
+
setReceiveLibraryTimeoutMoveCall(tx: Transaction, srcEid: number | TransactionArgument, receiveLibrary: string | TransactionArgument, expiry: number | bigint | TransactionArgument): Promise<void>;
|
|
4720
|
+
/**
|
|
4721
|
+
* Set configuration for a message library
|
|
4722
|
+
* @param tx - The transaction to add the move call to
|
|
4723
|
+
* @param lib - Library address
|
|
4724
|
+
* @param eid - Endpoint ID
|
|
4725
|
+
* @param configType - Configuration type
|
|
4726
|
+
* @param config - Configuration data as bytes
|
|
4727
|
+
* @returns Transaction result containing Call<MessageLibSetConfigParam, Void>
|
|
4728
|
+
*/
|
|
4729
|
+
setConfigMoveCall(tx: Transaction, lib: string | TransactionArgument, eid: number | TransactionArgument, configType: number | TransactionArgument, config: Uint8Array | TransactionArgument): Promise<TransactionResult>;
|
|
4193
4730
|
}
|
|
4194
4731
|
|
|
4195
4732
|
/**
|
|
@@ -4248,13 +4785,19 @@ declare class LayerZeroViews {
|
|
|
4248
4785
|
}
|
|
4249
4786
|
|
|
4250
4787
|
declare const CallErrorCode: {
|
|
4251
|
-
readonly
|
|
4788
|
+
readonly Call_ECallNotActive: 1;
|
|
4252
4789
|
readonly Call_ECallNotCompleted: 2;
|
|
4253
|
-
readonly
|
|
4790
|
+
readonly Call_ECallNotCreating: 3;
|
|
4254
4791
|
readonly Call_ECallNotRoot: 4;
|
|
4255
|
-
readonly
|
|
4256
|
-
readonly
|
|
4257
|
-
readonly
|
|
4792
|
+
readonly Call_ECallNotWaiting: 5;
|
|
4793
|
+
readonly Call_EInvalidChild: 6;
|
|
4794
|
+
readonly Call_EInvalidNonce: 7;
|
|
4795
|
+
readonly Call_EInvalidParent: 8;
|
|
4796
|
+
readonly Call_EParameterNotMutable: 9;
|
|
4797
|
+
readonly Call_EUnauthorized: 10;
|
|
4798
|
+
readonly CallCap_EBadWitness: 1;
|
|
4799
|
+
readonly MultiCall_ENoMoreCalls: 1;
|
|
4800
|
+
readonly MultiCall_EUnauthorized: 2;
|
|
4258
4801
|
};
|
|
4259
4802
|
declare class Call {
|
|
4260
4803
|
#private;
|
|
@@ -4781,228 +5324,6 @@ declare class Zro {
|
|
|
4781
5324
|
noneOptionMoveCall(tx: Transaction): TransactionResult;
|
|
4782
5325
|
}
|
|
4783
5326
|
|
|
4784
|
-
/**
|
|
4785
|
-
* Type guard to check if a value is already a TransactionArgument
|
|
4786
|
-
* TransactionArgument can be:
|
|
4787
|
-
* 1. Argument object with $kind property
|
|
4788
|
-
* 2. Synchronous function: (tx: Transaction) => Argument
|
|
4789
|
-
* 3. Asynchronous function: AsyncTransactionThunk
|
|
4790
|
-
*/
|
|
4791
|
-
declare function isTransactionArgument(value: unknown): value is TransactionArgument;
|
|
4792
|
-
/**
|
|
4793
|
-
* Convert value to TransactionArgument using a simple converter function
|
|
4794
|
-
* @param value - The value to convert (primitive type or TransactionArgument)
|
|
4795
|
-
* @param converter - Function to convert primitive type to TransactionArgument
|
|
4796
|
-
* @returns TransactionArgument
|
|
4797
|
-
*/
|
|
4798
|
-
declare function asArg<T>(value: T | TransactionArgument, converter: (val: T) => TransactionArgument): TransactionArgument;
|
|
4799
|
-
/**
|
|
4800
|
-
* Convert value to TransactionArgument using a converter that requires Transaction
|
|
4801
|
-
* @param tx - The transaction
|
|
4802
|
-
* @param value - The value to convert
|
|
4803
|
-
* @param converter - Function to convert value using transaction
|
|
4804
|
-
* @returns TransactionArgument
|
|
4805
|
-
*/
|
|
4806
|
-
declare function asArgWithTx<T>(tx: Transaction, value: T | TransactionArgument, converter: (tx: Transaction, val: T) => TransactionArgument): TransactionArgument;
|
|
4807
|
-
/**
|
|
4808
|
-
* Async version: Convert value to TransactionArgument using an async converter that requires Transaction
|
|
4809
|
-
* @param tx - The transaction
|
|
4810
|
-
* @param value - The value to convert
|
|
4811
|
-
* @param converter - Async function to convert value using transaction
|
|
4812
|
-
* @returns Promise<TransactionArgument>
|
|
4813
|
-
*/
|
|
4814
|
-
declare function asArgWithTxAsync<T>(tx: Transaction, value: T | TransactionArgument, converter: (tx: Transaction, val: T) => Promise<TransactionArgument>): Promise<TransactionArgument>;
|
|
4815
|
-
/**
|
|
4816
|
-
* Convert to object reference TransactionArgument
|
|
4817
|
-
*/
|
|
4818
|
-
declare function asObject(tx: Transaction, value: string | TransactionArgument): TransactionArgument;
|
|
4819
|
-
/**
|
|
4820
|
-
* Convert to address TransactionArgument
|
|
4821
|
-
*/
|
|
4822
|
-
declare function asAddress(tx: Transaction, value: string | TransactionArgument): TransactionArgument;
|
|
4823
|
-
/**
|
|
4824
|
-
* Convert to u8 TransactionArgument
|
|
4825
|
-
*/
|
|
4826
|
-
declare function asU8(tx: Transaction, value: number | TransactionArgument): TransactionArgument;
|
|
4827
|
-
/**
|
|
4828
|
-
* Convert to u16 TransactionArgument
|
|
4829
|
-
*/
|
|
4830
|
-
declare function asU16(tx: Transaction, value: number | TransactionArgument): TransactionArgument;
|
|
4831
|
-
/**
|
|
4832
|
-
* Convert to u32 TransactionArgument
|
|
4833
|
-
*/
|
|
4834
|
-
declare function asU32(tx: Transaction, value: number | TransactionArgument): TransactionArgument;
|
|
4835
|
-
/**
|
|
4836
|
-
* Convert to u64 TransactionArgument (supports bigint, number, or string)
|
|
4837
|
-
*/
|
|
4838
|
-
declare function asU64(tx: Transaction, value: bigint | number | string | TransactionArgument): TransactionArgument;
|
|
4839
|
-
/**
|
|
4840
|
-
* Convert to u128 TransactionArgument (supports bigint, number, or string)
|
|
4841
|
-
*/
|
|
4842
|
-
declare function asU128(tx: Transaction, value: bigint | number | string | TransactionArgument): TransactionArgument;
|
|
4843
|
-
/**
|
|
4844
|
-
* Convert to u256 TransactionArgument (supports bigint, number, or string)
|
|
4845
|
-
*/
|
|
4846
|
-
declare function asU256(tx: Transaction, value: bigint | number | string | TransactionArgument): TransactionArgument;
|
|
4847
|
-
/**
|
|
4848
|
-
* Convert Uint8Array to Bytes32 using moduleManager's fromBytesMoveCall
|
|
4849
|
-
* @param tx - The transaction
|
|
4850
|
-
* @param value - Uint8Array or TransactionArgument
|
|
4851
|
-
* @param utils - utils Module
|
|
4852
|
-
* @returns TransactionArgument
|
|
4853
|
-
*/
|
|
4854
|
-
declare function asBytes32(tx: Transaction, value: Uint8Array | TransactionArgument, utils: Utils): TransactionArgument;
|
|
4855
|
-
/**
|
|
4856
|
-
* Convert Uint8Array to serialized bytes vector TransactionArgument
|
|
4857
|
-
* @param tx - The transaction
|
|
4858
|
-
* @param value - Uint8Array or TransactionArgument
|
|
4859
|
-
* @returns TransactionArgument
|
|
4860
|
-
*/
|
|
4861
|
-
declare function asBytes(tx: Transaction, value: Uint8Array | TransactionArgument): TransactionArgument;
|
|
4862
|
-
/**
|
|
4863
|
-
* Convert Uint8Array Vector to serialized bytes vector TransactionArgument
|
|
4864
|
-
* @param tx - The transaction
|
|
4865
|
-
* @param value - Uint8Array or TransactionArgument
|
|
4866
|
-
* @returns TransactionArgument
|
|
4867
|
-
*/
|
|
4868
|
-
declare function asBytesVector(tx: Transaction, value: Uint8Array[] | TransactionArgument): TransactionArgument;
|
|
4869
|
-
/**
|
|
4870
|
-
* Convert string to string TransactionArgument
|
|
4871
|
-
* @param tx - The transaction
|
|
4872
|
-
* @param value - string or TransactionArgument
|
|
4873
|
-
* @returns TransactionArgument
|
|
4874
|
-
*/
|
|
4875
|
-
declare function asString(tx: Transaction, value: string | TransactionArgument): TransactionArgument;
|
|
4876
|
-
/**
|
|
4877
|
-
* Convert address array to serialized vector<address> TransactionArgument
|
|
4878
|
-
* @param tx - The transaction
|
|
4879
|
-
* @param value - string[] or TransactionArgument
|
|
4880
|
-
* @returns TransactionArgument
|
|
4881
|
-
*/
|
|
4882
|
-
declare function asAddressVector(tx: Transaction, value: string[] | TransactionArgument): TransactionArgument;
|
|
4883
|
-
/**
|
|
4884
|
-
* Convert boolean to boolean TransactionArgument
|
|
4885
|
-
* @param tx - The transaction
|
|
4886
|
-
* @param value - boolean or TransactionArgument
|
|
4887
|
-
* @returns TransactionArgument
|
|
4888
|
-
*/
|
|
4889
|
-
declare function asBool(tx: Transaction, value: boolean | TransactionArgument): TransactionArgument;
|
|
4890
|
-
|
|
4891
|
-
declare function simulateTransaction(suiClient: SuiClient, tx: Transaction, sender?: string): Promise<SimulateResult[]>;
|
|
4892
|
-
declare function simulateTransactionMultiResult(suiClient: SuiClient, tx: Transaction, resultIndex: number[], sender?: string): Promise<SimulateResult[][]>;
|
|
4893
|
-
declare function validateTransaction(client: SuiClient, signer: Keypair, tx: Transaction): Promise<SuiTransactionBlockResponse>;
|
|
4894
|
-
/**
|
|
4895
|
-
* Execute simulate using a moveCall function
|
|
4896
|
-
* @param client - The Sui client
|
|
4897
|
-
* @param moveCallFn - Function that adds moveCall to the transaction
|
|
4898
|
-
* @param parser - Function to parse the result
|
|
4899
|
-
* @returns The parsed result
|
|
4900
|
-
*/
|
|
4901
|
-
declare function executeSimulate<T>(client: SuiClient, moveCallFn: (tx: Transaction) => void, parser: (result: {
|
|
4902
|
-
value: Uint8Array;
|
|
4903
|
-
}[]) => T): Promise<T>;
|
|
4904
|
-
declare function handleError(e: string): unknown;
|
|
4905
|
-
|
|
4906
|
-
/**
|
|
4907
|
-
* PackageAllowlistValidator ensures all function calls and objects belong to allowlisted packages
|
|
4908
|
-
* This validator checks that:
|
|
4909
|
-
* 1. All function calls target approved packages
|
|
4910
|
-
* 2. All object arguments come from approved packages
|
|
4911
|
-
*
|
|
4912
|
-
* If local packageWhitelist is empty, it will use the PTB whitelist contract for validation
|
|
4913
|
-
* If local packageWhitelist is provided, it will use only the local whitelist (contract is ignored)
|
|
4914
|
-
*/
|
|
4915
|
-
declare class PackageAllowlistValidator implements IPTBValidator {
|
|
4916
|
-
private packageWhitelist;
|
|
4917
|
-
private validator?;
|
|
4918
|
-
constructor(packageWhitelist?: string[], validator?: PackageWhitelistValidator);
|
|
4919
|
-
/**
|
|
4920
|
-
* Validates that all function calls and object arguments belong to whitelisted packages
|
|
4921
|
-
* @param moveCallsWithDetails - Array of move calls with object details
|
|
4922
|
-
* @throws Error if any function call or object belongs to a non-whitelisted package
|
|
4923
|
-
*/
|
|
4924
|
-
validate(moveCallsWithDetails: MoveCallWithObjectDetails[]): Promise<void>;
|
|
4925
|
-
/**
|
|
4926
|
-
* Validate multiple packages at once
|
|
4927
|
-
* @param packages - Array of package IDs to validate
|
|
4928
|
-
* @returns Object mapping package ID to validation result
|
|
4929
|
-
*/
|
|
4930
|
-
private validatePackages;
|
|
4931
|
-
/**
|
|
4932
|
-
* Extracts package ID from object type string
|
|
4933
|
-
* Object types are in format: "packageId::module::struct<generics>"
|
|
4934
|
-
* @param objectType - The object type string
|
|
4935
|
-
* @returns The package ID or null if extraction fails
|
|
4936
|
-
*/
|
|
4937
|
-
private extractPackageIdFromType;
|
|
4938
|
-
/**
|
|
4939
|
-
* Get available packages for error messages
|
|
4940
|
-
*/
|
|
4941
|
-
private getAvailablePackagesList;
|
|
4942
|
-
}
|
|
4943
|
-
|
|
4944
|
-
/**
|
|
4945
|
-
* NonSenderObjectValidator ensures objects are not owned by the transaction sender
|
|
4946
|
-
*
|
|
4947
|
-
* In Sui, this validator checks that objects are:
|
|
4948
|
-
* - Shared: globally accessible, mutations require consensus
|
|
4949
|
-
* - Immutable: can't change after creation
|
|
4950
|
-
* - Owned by another address (not the sender)
|
|
4951
|
-
*
|
|
4952
|
-
* This prevents the sender from using their own owned objects in the transaction
|
|
4953
|
-
*/
|
|
4954
|
-
declare class NonSenderObjectValidator implements IPTBValidator {
|
|
4955
|
-
private sender;
|
|
4956
|
-
constructor(sender: string);
|
|
4957
|
-
/**
|
|
4958
|
-
* Validates that objects are not owned by the sender
|
|
4959
|
-
* @param moveCallsWithDetails - Array of move calls with object details
|
|
4960
|
-
* @throws Error if any object is owned by the sender
|
|
4961
|
-
*/
|
|
4962
|
-
validate(moveCallsWithDetails: MoveCallWithObjectDetails[]): void;
|
|
4963
|
-
/**
|
|
4964
|
-
* Checks if the ownership is valid (not owned by sender)
|
|
4965
|
-
* @param owner - The object owner to check
|
|
4966
|
-
* @returns true if ownership is valid (Shared, Immutable, or owned by another address)
|
|
4967
|
-
*/
|
|
4968
|
-
private isValidOwnership;
|
|
4969
|
-
/**
|
|
4970
|
-
* Gets a human-readable description of the ownership type
|
|
4971
|
-
* @param owner - The object owner
|
|
4972
|
-
* @returns String description of ownership type
|
|
4973
|
-
*/
|
|
4974
|
-
private getOwnershipType;
|
|
4975
|
-
}
|
|
4976
|
-
|
|
4977
|
-
/**
|
|
4978
|
-
* ShareObjectValidator ensures all object arguments are Shared or Immutable
|
|
4979
|
-
* This is the default validator for PTB operations
|
|
4980
|
-
*/
|
|
4981
|
-
declare class ShareObjectValidator implements IPTBValidator {
|
|
4982
|
-
/**
|
|
4983
|
-
* Validates move calls with pre-fetched object details
|
|
4984
|
-
* @param moveCallsWithDetails - Array of move calls with object details
|
|
4985
|
-
* @throws Error if any object is not Shared/Immutable
|
|
4986
|
-
*/
|
|
4987
|
-
validate(moveCallsWithDetails: MoveCallWithObjectDetails[]): void;
|
|
4988
|
-
/**
|
|
4989
|
-
* Checks if an object owner is Shared or Immutable
|
|
4990
|
-
* @param owner - The object owner to check
|
|
4991
|
-
* @returns true if the owner is Shared or Immutable, false otherwise
|
|
4992
|
-
*/
|
|
4993
|
-
protected isSharedOrImmutable(owner: ObjectOwner): boolean;
|
|
4994
|
-
}
|
|
4995
|
-
|
|
4996
|
-
/**
|
|
4997
|
-
* Validates move calls using multiple validators with a single object fetch
|
|
4998
|
-
* @param client - SuiClient instance
|
|
4999
|
-
* @param moveCalls - Array of move calls to validate
|
|
5000
|
-
* @param validators - Array of validators to run
|
|
5001
|
-
* @param options - Options for what object data to fetch
|
|
5002
|
-
* @param batchSize - Batch size for object fetching
|
|
5003
|
-
*/
|
|
5004
|
-
declare function validateWithDetails(client: SuiClient, moveCalls: MoveCall[], validators: IPTBValidator[], sender?: string, userOptions?: ObjectFetchOptions, batchSize?: number): Promise<void>;
|
|
5005
|
-
|
|
5006
5327
|
declare const PACKAGE_UTILS_ADDRESS: {
|
|
5007
5328
|
[stage in Stage]?: string;
|
|
5008
5329
|
};
|
|
@@ -5081,6 +5402,12 @@ declare const PACKAGE_BLOCKED_MESSAGE_LIB_ADDRESS: {
|
|
|
5081
5402
|
declare const PACKAGE_BLOCKED_MESSAGE_LIB_PTB_BUILDER_ADDRESS: {
|
|
5082
5403
|
[stage in Stage]?: string;
|
|
5083
5404
|
};
|
|
5405
|
+
declare const PACKAGE_WORKER_REGISTRY_ADDRESS: {
|
|
5406
|
+
[stage in Stage]?: string;
|
|
5407
|
+
};
|
|
5408
|
+
declare const PACKAGE_WORKER_COMMON_ADDRESS: {
|
|
5409
|
+
[stage in Stage]?: string;
|
|
5410
|
+
};
|
|
5084
5411
|
declare const OBJECT_ENDPOINT_V2_ADDRESS: {
|
|
5085
5412
|
[stage in Stage]?: string;
|
|
5086
5413
|
};
|
|
@@ -5174,6 +5501,9 @@ declare const OBJECT_PRICE_FEED_OWNER_CAP_ADDRESS: {
|
|
|
5174
5501
|
declare const OBJECT_PACKAGE_WHITELIST_VALIDATOR_ADDRESS: {
|
|
5175
5502
|
[stage in Stage]?: string;
|
|
5176
5503
|
};
|
|
5504
|
+
declare const OBJECT_WORKER_REGISTRY_ADDRESS: {
|
|
5505
|
+
[stage in Stage]?: string;
|
|
5506
|
+
};
|
|
5177
5507
|
|
|
5178
5508
|
/**
|
|
5179
5509
|
* The SDK class provides methods to interact with LayerZero on Sui.
|
|
@@ -5200,7 +5530,7 @@ declare class SDK {
|
|
|
5200
5530
|
getPtbBuilder(): PtbBuilder;
|
|
5201
5531
|
getTreasury(): Treasury;
|
|
5202
5532
|
getLayerZeroViews(): LayerZeroViews;
|
|
5203
|
-
getOApp(): OApp;
|
|
5533
|
+
getOApp(callCapId: string, options?: ModuleOptions): OApp;
|
|
5204
5534
|
getCounter(options?: ModuleOptions): Counter;
|
|
5205
5535
|
getExecutor(options?: ModuleOptions): Executor;
|
|
5206
5536
|
getDvn(options?: ModuleOptions): DVN;
|
|
@@ -5216,6 +5546,7 @@ declare class SDK {
|
|
|
5216
5546
|
getEndpointPtbBuilder(options?: ModuleOptions): EndpointPtbBuilder;
|
|
5217
5547
|
getSimpleMessageLibPtbBuilder(options?: ModuleOptions): SimpleMessageLibPtbBuilder;
|
|
5218
5548
|
getBlockedMessageLibPtbBuilder(options?: ModuleOptions): BlockedMessageLibPtbBuilder;
|
|
5549
|
+
getWorkerRegistry(options?: ModuleOptions): WorkerRegistry;
|
|
5219
5550
|
getOrCreateModule<T>(moduleName: string, options: ModuleOptions | undefined, factory: () => T): T;
|
|
5220
5551
|
}
|
|
5221
5552
|
|
|
@@ -5229,6 +5560,14 @@ declare const DvnDstConfigBcs: _mysten_sui_dist_cjs_bcs.BcsType<{
|
|
|
5229
5560
|
floor_margin_usd: string | number | bigint;
|
|
5230
5561
|
}>;
|
|
5231
5562
|
|
|
5563
|
+
declare const TimeoutBcs: _mysten_sui_dist_cjs_bcs.BcsType<{
|
|
5564
|
+
expiry: string;
|
|
5565
|
+
fallback_lib: string;
|
|
5566
|
+
}, {
|
|
5567
|
+
expiry: string | number | bigint;
|
|
5568
|
+
fallback_lib: any;
|
|
5569
|
+
}>;
|
|
5570
|
+
|
|
5232
5571
|
declare const Bytes32Bcs: _mysten_sui_dist_cjs_bcs.BcsType<{
|
|
5233
5572
|
bytes: number[];
|
|
5234
5573
|
}, {
|
|
@@ -5403,6 +5742,24 @@ declare const VectorMoveCallBCS: _mysten_sui_dist_cjs_bcs.BcsType<{
|
|
|
5403
5742
|
length: number;
|
|
5404
5743
|
}>;
|
|
5405
5744
|
|
|
5745
|
+
declare const OAppInfoV1Bcs: _mysten_sui_dist_cjs_bcs.BcsType<{
|
|
5746
|
+
oapp_object: string;
|
|
5747
|
+
next_nonce_info: number[];
|
|
5748
|
+
lz_receive_info: number[];
|
|
5749
|
+
extra_info: number[];
|
|
5750
|
+
}, {
|
|
5751
|
+
oapp_object: any;
|
|
5752
|
+
next_nonce_info: Iterable<number> & {
|
|
5753
|
+
length: number;
|
|
5754
|
+
};
|
|
5755
|
+
lz_receive_info: Iterable<number> & {
|
|
5756
|
+
length: number;
|
|
5757
|
+
};
|
|
5758
|
+
extra_info: Iterable<number> & {
|
|
5759
|
+
length: number;
|
|
5760
|
+
};
|
|
5761
|
+
}>;
|
|
5762
|
+
|
|
5406
5763
|
declare const PriceBcs: _mysten_sui_dist_cjs_bcs.BcsType<{
|
|
5407
5764
|
price_ratio: string;
|
|
5408
5765
|
gas_price_in_unit: string;
|
|
@@ -5470,12 +5827,4 @@ declare const OAppUlnConfigBcs: _mysten_sui_dist_cjs_bcs.BcsType<{
|
|
|
5470
5827
|
};
|
|
5471
5828
|
}>;
|
|
5472
5829
|
|
|
5473
|
-
|
|
5474
|
-
expiry: string;
|
|
5475
|
-
fallback_lib: string;
|
|
5476
|
-
}, {
|
|
5477
|
-
expiry: string | number | bigint;
|
|
5478
|
-
fallback_lib: any;
|
|
5479
|
-
}>;
|
|
5480
|
-
|
|
5481
|
-
export { ALL_EXECUTOR_OPTION_TYPES, type ArbitrumPriceExt, ArbitrumPriceExtBcs, type Argument, ArgumentBCS, BlockedMessageLib, BlockedMessageLibErrorCode, BlockedMessageLibPtbBuilder, type BuilderPlaceholderInfo, Bytes32Bcs, CONFIG_TYPE, Call, CallErrorCode, CallTypeName, Counter, CounterErrorCode, DEFAULT_SIMULATION_TIMES, DVN, DVNErrorCode, DVNFeeLib, DVNFeeLibErrorCode, type DstConfig, DstConfigBcs, type DvnDstConfig, DvnDstConfigBcs, DvnLayerZero, DvnPtbBuilder, Endpoint, EndpointErrorCode, EndpointExecutionState, type EndpointExecutionStateType, EndpointPtbBuilder, type ExecutableParams, Executor, type ExecutorConfig, ExecutorConfigBcs, ExecutorErrorCode, ExecutorFeeLib, ExecutorFeeLibErrorCode, ExecutorLayerZero, ExecutorOptionType, ExecutorPtbBuilder, type Function, FunctionBCS, type IPTBValidator, type InitializableParams, LayerZeroViews, LibBuilderManagerErrorCode, LzComposeVersion, LzReceiveVersion, LzTypeName, MAX_BATCH_SIZE, MessageLibType, type MessagingFee, MessagingFeeBcs, ModelType, ModelTypeBcs, type ModuleOptions, Modules, MoveAbortError, type MoveCall, MoveCallBCS, type NativeDropParams, NativeDropParamsBcs, NonSenderObjectValidator, OApp, OAppErrorCode, type OAppUlnConfig, OAppUlnConfigBcs, OBJECT_BLOCKED_MESSAGE_LIB_ADDRESS, OBJECT_BLOCKED_MESSAGE_LIB_PTB_BUILDER_ADDRESS, OBJECT_COUNTER_ADDRESS, OBJECT_COUNTER_ADMIN_CAP_ADDRESS, OBJECT_COUNTER_OAPP_ADDRESS, OBJECT_DISCOVERY_ADDRESS, OBJECT_DVN_ADDRESS, OBJECT_DVN_CAP_ADDRESS, OBJECT_DVN_FEE_LIB_ADDRESS, OBJECT_DVN_FEE_LIB_ADMIN_CAP_ADDRESS, OBJECT_ENDPOINT_ADMIN_CAP_ADDRESS, OBJECT_ENDPOINT_PTB_BUILDER_ADDRESS, OBJECT_ENDPOINT_PTB_BUILDER_ADMIN_CAP_ADDRESS, OBJECT_ENDPOINT_V2_ADDRESS, OBJECT_EXECUTOR_ADDRESS, OBJECT_EXECUTOR_CAP_ADDRESS, OBJECT_EXECUTOR_FEE_LIB_ADDRESS, OBJECT_EXECUTOR_FEE_LIB_ADMIN_CAP_ADDRESS, OBJECT_EXECUTOR_OWNER_CAP_ADDRESS, OBJECT_PACKAGE_WHITELIST_VALIDATOR_ADDRESS, OBJECT_PRICE_FEED_ADDRESS, OBJECT_PRICE_FEED_OWNER_CAP_ADDRESS, OBJECT_SIMPLE_MESSAGE_LIB_ADDRESS, OBJECT_SIMPLE_MESSAGE_LIB_ADMIN_CAP_ADDRESS, OBJECT_SIMPLE_MESSAGE_LIB_PTB_BUILDER_ADDRESS, OBJECT_TREASURY_ADDRESS, OBJECT_TREASURY_ADMIN_CAP_ADDRESS, OBJECT_ULN_302_ADDRESS, OBJECT_ULN_302_ADMIN_CAP_ADDRESS, OBJECT_ULN_302_PTB_BUILDER_ADDRESS, OBJECT_ULN_302_VERIFICATION_ADDRESS, type ObjectFetchOptions, type ObjectOptions, PACKAGE_BLOCKED_MESSAGE_LIB_ADDRESS, PACKAGE_BLOCKED_MESSAGE_LIB_PTB_BUILDER_ADDRESS, PACKAGE_CALL_ADDRESS, PACKAGE_COUNTER_V2_ADDRESS, PACKAGE_DVN_ADDRESS, PACKAGE_DVN_FEE_LIB_ADDRESS, PACKAGE_DVN_LAYERZERO_ADDRESS, PACKAGE_DVN_PTB_BUILDER_ADDRESS, PACKAGE_ENDPOINT_PTB_BUILDER_ADDRESS, PACKAGE_ENDPOINT_V2_ADDRESS, PACKAGE_EXECUTOR_ADDRESS, PACKAGE_EXECUTOR_FEE_LIB_ADDRESS, PACKAGE_EXECUTOR_LAYERZERO_ADDRESS, PACKAGE_EXECUTOR_PTB_BUILDER_ADDRESS, PACKAGE_LAYERZERO_VIEWS_ADDRESS, PACKAGE_OAPP_ADDRESS, PACKAGE_PACKAGE_WHITELIST_VALIDATOR_ADDRESS, PACKAGE_PRICE_FEED_ADDRESS, PACKAGE_PTB_MOVE_CALL_ADDRESS, PACKAGE_SIMPLE_MESSAGE_LIB_ADDRESS, PACKAGE_SIMPLE_MESSAGE_LIB_PTB_BUILDER_ADDRESS, PACKAGE_TREASURY_ADDRESS, PACKAGE_ULN_302_ADDRESS, PACKAGE_ULN_302_PTB_BUILDER_ADDRESS, PACKAGE_UTILS_ADDRESS, PACKAGE_ZRO_ADDRESS, PackageAllowlistValidator, type PackageOptions, PackageWhitelistValidator, type Price, PriceBcs, PriceFeed, PriceFeedErrorCode, PtbBuilder, SDK, type SdkOptions, type SetDstConfigEvent, ShareObjectValidator, SimpleMessageLib, SimpleMessageLibErrorCode, SimpleMessageLibPtbBuilder, type SimulateResult, type Timeout, TimeoutBcs, Treasury, TreasuryErrorCode, Uln302, Uln302ErrorCode, Uln302PtbBuilder, type UlnConfig, UlnConfigBcs, type UlnVerifiableParams, UlnVerificationState, type UlnVerificationStateType, UnclassifiedError, Utils, UtilsErrorCode, ValidatorErrorCode, VectorMoveCallBCS, type VerifiableParams, type VerifierFeePaid, type VersionInfo, Zro, asAddress, asAddressVector, asArg, asArgWithTx, asArgWithTxAsync, asBool, asBytes, asBytes32, asBytesVector, asObject, asString, asU128, asU16, asU256, asU32, asU64, asU8, executeSimulate, handleError, isTransactionArgument, simulateTransaction, simulateTransactionMultiResult, validateTransaction, validateWithDetails };
|
|
5830
|
+
export { ALL_EXECUTOR_OPTION_TYPES, type ArbitrumPriceExt, ArbitrumPriceExtBcs, type Argument, ArgumentBCS, BlockedMessageLib, BlockedMessageLibErrorCode, BlockedMessageLibPtbBuilder, type BuilderPlaceholderInfo, Bytes32Bcs, CONFIG_TYPE, Call, CallErrorCode, CallTypeName, Counter, CounterErrorCode, DEFAULT_SIMULATION_TIMES, DVN, DVNErrorCode, DVNFeeLib, DVNFeeLibErrorCode, DVNLayerzeroErrorCode, type DstConfig, DstConfigBcs, type DvnDstConfig, DvnDstConfigBcs, DvnLayerZero, DvnPtbBuilder, Endpoint, EndpointErrorCode, EndpointExecutionState, type EndpointExecutionStateType, EndpointPtbBuilder, EndpointPtbBuilderErrorCode, type ExecutableParams, Executor, type ExecutorConfig, ExecutorConfigBcs, ExecutorErrorCode, ExecutorFeeLib, ExecutorFeeLibErrorCode, ExecutorLayerZero, ExecutorLayerzeroErrorCode, ExecutorOptionType, ExecutorPtbBuilder, type Function, FunctionBCS, type IPTBValidator, type InitializableParams, LayerZeroViews, LzComposeVersion, LzReceiveVersion, LzTypeName, MAX_BATCH_SIZE, MessageLibType, type MessagingFee, MessagingFeeBcs, ModelType, ModelTypeBcs, type ModuleOptions, Modules, MoveAbortError, type MoveCall, MoveCallBCS, type NativeDropParams, NativeDropParamsBcs, NonSenderObjectValidator, OApp, OAppErrorCode, OAppInfoV1Bcs, OAppInfoVersion, type OAppUlnConfig, OAppUlnConfigBcs, OBJECT_BLOCKED_MESSAGE_LIB_ADDRESS, OBJECT_BLOCKED_MESSAGE_LIB_PTB_BUILDER_ADDRESS, OBJECT_COUNTER_ADDRESS, OBJECT_COUNTER_ADMIN_CAP_ADDRESS, OBJECT_COUNTER_OAPP_ADDRESS, OBJECT_DISCOVERY_ADDRESS, OBJECT_DVN_ADDRESS, OBJECT_DVN_CAP_ADDRESS, OBJECT_DVN_FEE_LIB_ADDRESS, OBJECT_DVN_FEE_LIB_ADMIN_CAP_ADDRESS, OBJECT_ENDPOINT_ADMIN_CAP_ADDRESS, OBJECT_ENDPOINT_PTB_BUILDER_ADDRESS, OBJECT_ENDPOINT_PTB_BUILDER_ADMIN_CAP_ADDRESS, OBJECT_ENDPOINT_V2_ADDRESS, OBJECT_EXECUTOR_ADDRESS, OBJECT_EXECUTOR_CAP_ADDRESS, OBJECT_EXECUTOR_FEE_LIB_ADDRESS, OBJECT_EXECUTOR_FEE_LIB_ADMIN_CAP_ADDRESS, OBJECT_EXECUTOR_OWNER_CAP_ADDRESS, OBJECT_PACKAGE_WHITELIST_VALIDATOR_ADDRESS, OBJECT_PRICE_FEED_ADDRESS, OBJECT_PRICE_FEED_OWNER_CAP_ADDRESS, OBJECT_SIMPLE_MESSAGE_LIB_ADDRESS, OBJECT_SIMPLE_MESSAGE_LIB_ADMIN_CAP_ADDRESS, OBJECT_SIMPLE_MESSAGE_LIB_PTB_BUILDER_ADDRESS, OBJECT_TREASURY_ADDRESS, OBJECT_TREASURY_ADMIN_CAP_ADDRESS, OBJECT_ULN_302_ADDRESS, OBJECT_ULN_302_ADMIN_CAP_ADDRESS, OBJECT_ULN_302_PTB_BUILDER_ADDRESS, OBJECT_ULN_302_VERIFICATION_ADDRESS, OBJECT_WORKER_REGISTRY_ADDRESS, type ObjectFetchOptions, type ObjectOptions, PACKAGE_BLOCKED_MESSAGE_LIB_ADDRESS, PACKAGE_BLOCKED_MESSAGE_LIB_PTB_BUILDER_ADDRESS, PACKAGE_CALL_ADDRESS, PACKAGE_COUNTER_V2_ADDRESS, PACKAGE_DVN_ADDRESS, PACKAGE_DVN_FEE_LIB_ADDRESS, PACKAGE_DVN_LAYERZERO_ADDRESS, PACKAGE_DVN_PTB_BUILDER_ADDRESS, PACKAGE_ENDPOINT_PTB_BUILDER_ADDRESS, PACKAGE_ENDPOINT_V2_ADDRESS, PACKAGE_EXECUTOR_ADDRESS, PACKAGE_EXECUTOR_FEE_LIB_ADDRESS, PACKAGE_EXECUTOR_LAYERZERO_ADDRESS, PACKAGE_EXECUTOR_PTB_BUILDER_ADDRESS, PACKAGE_LAYERZERO_VIEWS_ADDRESS, PACKAGE_OAPP_ADDRESS, PACKAGE_PACKAGE_WHITELIST_VALIDATOR_ADDRESS, PACKAGE_PRICE_FEED_ADDRESS, PACKAGE_PTB_MOVE_CALL_ADDRESS, PACKAGE_SIMPLE_MESSAGE_LIB_ADDRESS, PACKAGE_SIMPLE_MESSAGE_LIB_PTB_BUILDER_ADDRESS, PACKAGE_TREASURY_ADDRESS, PACKAGE_ULN_302_ADDRESS, PACKAGE_ULN_302_PTB_BUILDER_ADDRESS, PACKAGE_UTILS_ADDRESS, PACKAGE_WORKER_COMMON_ADDRESS, PACKAGE_WORKER_REGISTRY_ADDRESS, PACKAGE_ZRO_ADDRESS, PackageAllowlistValidator, type PackageOptions, PackageWhitelistValidator, type Price, PriceBcs, PriceFeed, PriceFeedErrorCode, PtbBuilder, PtbBuilderErrorCode, SDK, type SdkOptions, type SetDstConfigEvent, ShareObjectValidator, SimpleMessageLib, SimpleMessageLibErrorCode, SimpleMessageLibPtbBuilder, type SimulateResult, type Timeout, TimeoutBcs, Treasury, TreasuryErrorCode, Uln302, Uln302ErrorCode, Uln302PtbBuilder, Uln302PtbBuilderErrorCode, type UlnConfig, UlnConfigBcs, type UlnVerifiableParams, UlnVerificationState, type UlnVerificationStateType, UnclassifiedError, Utils, UtilsErrorCode, ValidatorErrorCode, VectorMoveCallBCS, type VerifiableParams, type VerifierFeePaid, type VersionInfo, WorkerRegistry, WorkerRegistryErrorCode, Zro, asAddress, asAddressVector, asArg, asArgWithTx, asArgWithTxAsync, asBool, asBytes, asBytes32, asBytesVector, asObject, asString, asU128, asU16, asU256, asU32, asU64, asU8, executeSimulate, handleError, isTransactionArgument, simulateTransaction, simulateTransactionMultiResult, validateTransaction, validateWithDetails };
|