@layerzerolabs/protocol-stellar-v2 0.2.15 → 0.2.18
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/.turbo/turbo-build.log +350 -309
- package/.turbo/turbo-lint.log +146 -108
- package/.turbo/turbo-test.log +1423 -1238
- package/Cargo.lock +12 -0
- package/Cargo.toml +3 -0
- package/contracts/ERROR_SPEC.md +44 -0
- package/contracts/common-macros/src/auth.rs +113 -0
- package/contracts/common-macros/src/contract_ttl.rs +84 -0
- package/contracts/common-macros/src/lib.rs +181 -30
- package/contracts/common-macros/src/lz_contract.rs +83 -0
- package/contracts/common-macros/src/tests/{ownable.rs → auth.rs} +48 -15
- package/contracts/common-macros/src/tests/contract_ttl.rs +662 -0
- package/contracts/common-macros/src/tests/mod.rs +2 -2
- package/contracts/common-macros/src/tests/snapshots/common_macros__tests__auth__snapshot_generated_multisig_code.snap +20 -0
- package/contracts/common-macros/src/tests/snapshots/common_macros__tests__auth__snapshot_generated_ownable_code.snap +24 -0
- package/contracts/common-macros/src/tests/snapshots/{common_macros__tests__ownable__snapshot_only_owner_preserves_function_signature.snap → common_macros__tests__auth__snapshot_only_auth_preserves_function_signature.snap} +4 -4
- package/contracts/common-macros/src/tests/snapshots/{common_macros__tests__contract_impl__snapshot_generated_contract_impl_code.snap → common_macros__tests__contract_ttl__snapshot_generated_contractimpl_code.snap} +3 -3
- package/contracts/common-macros/src/tests/snapshots/common_macros__tests__contract_ttl__snapshot_generated_contracttrait_code.snap +69 -0
- package/contracts/common-macros/src/tests/snapshots/common_macros__tests__ttl_configurable__snapshot_generated_ttl_configurable_code.snap +7 -21
- package/contracts/common-macros/src/tests/snapshots/common_macros__tests__upgradeable__snapshot_generated_upgradeable_code.snap +2 -2
- package/contracts/common-macros/src/ttl_configurable.rs +19 -34
- package/contracts/common-macros/src/ttl_extendable.rs +36 -0
- package/contracts/common-macros/src/upgradeable.rs +5 -5
- package/contracts/common-macros/src/utils.rs +9 -0
- package/contracts/endpoint-v2/src/constants.rs +4 -4
- package/contracts/endpoint-v2/src/endpoint_v2.rs +38 -40
- package/contracts/endpoint-v2/src/errors.rs +4 -3
- package/contracts/endpoint-v2/src/events.rs +1 -1
- package/contracts/endpoint-v2/src/message_lib_manager.rs +18 -5
- package/contracts/endpoint-v2/src/messaging_channel.rs +11 -1
- package/contracts/endpoint-v2/src/messaging_composer.rs +11 -1
- package/contracts/endpoint-v2/src/storage.rs +1 -1
- package/contracts/endpoint-v2/src/tests/endpoint_v2/pay_messaging_fees.rs +3 -3
- package/contracts/endpoint-v2/src/tests/endpoint_v2/quote.rs +1 -1
- package/contracts/endpoint-v2/src/tests/endpoint_v2/require_oapp_auth.rs +2 -2
- package/contracts/endpoint-v2/src/tests/endpoint_v2/send.rs +3 -3
- package/contracts/endpoint-v2/src/tests/endpoint_v2/set_zro.rs +4 -4
- package/contracts/endpoint-v2/src/tests/message_lib_manager/require_receive_lib_for_eid.rs +3 -3
- package/contracts/endpoint-v2/src/tests/message_lib_manager/require_registered.rs +1 -1
- package/contracts/endpoint-v2/src/tests/message_lib_manager/require_send_lib_for_eid.rs +3 -3
- package/contracts/endpoint-v2/src/tests/message_lib_manager/require_supported_eid.rs +1 -1
- package/contracts/endpoint-v2/src/tests/messaging_channel/clear_payload.rs +4 -4
- package/contracts/endpoint-v2/src/tests/messaging_channel/inbound.rs +1 -1
- package/contracts/layerzero-views/src/layerzero_view.rs +3 -6
- package/contracts/macro-integration-tests/tests/runtime/ownable/mod.rs +2 -2
- package/contracts/macro-integration-tests/tests/runtime/ownable/{only_owner_guard.rs → only_auth_guard.rs} +1 -1
- package/contracts/macro-integration-tests/tests/runtime/ttl_configurable/configuration.rs +1 -1
- package/contracts/macro-integration-tests/tests/runtime/ttl_configurable/freeze.rs +1 -1
- package/contracts/macro-integration-tests/tests/runtime/ttl_configurable/mod.rs +0 -1
- package/contracts/macro-integration-tests/tests/ui/ownable/fail/{only_owner_missing_env.rs → only_auth_missing_env.rs} +3 -3
- package/contracts/macro-integration-tests/tests/ui/ownable/fail/{only_owner_missing_env.stderr → only_auth_missing_env.stderr} +4 -4
- package/contracts/macro-integration-tests/tests/ui/ownable/pass/namespacing_and_imports.rs +2 -3
- package/contracts/macro-integration-tests/tests/ui/ownable/pass/{only_owner_env_param_variants.rs → only_auth_env_param_variants.rs} +9 -9
- package/contracts/macro-integration-tests/tests/ui/ttl_configurable/pass/minimal_contract.rs +6 -6
- package/contracts/message-libs/message-lib-common/src/errors.rs +7 -2
- package/contracts/message-libs/message-lib-common/src/tests/packet_codec_v1/decode_packet_header.rs +3 -3
- package/contracts/message-libs/message-lib-common/src/tests/worker_options/append_lz_receive_option.rs +1 -2
- package/contracts/message-libs/message-lib-common/src/tests/worker_options/append_native_drop_option.rs +1 -2
- package/contracts/message-libs/message-lib-common/src/tests/worker_options/convert_legacy_options.rs +9 -9
- package/contracts/message-libs/message-lib-common/src/tests/worker_options/extract_type_3_options.rs +1 -1
- package/contracts/message-libs/message-lib-common/src/tests/worker_options/left_pad_to_bytes32.rs +1 -1
- package/contracts/message-libs/message-lib-common/src/tests/worker_options/split_worker_options.rs +2 -2
- package/contracts/message-libs/simple-message-lib/src/simple_message_lib.rs +7 -9
- package/contracts/message-libs/treasury/src/errors.rs +2 -2
- package/contracts/message-libs/treasury/src/events.rs +1 -1
- package/contracts/message-libs/treasury/src/interfaces/zro_fee_lib.rs +2 -2
- package/contracts/message-libs/treasury/src/storage.rs +1 -1
- package/contracts/message-libs/treasury/src/tests/treasury_tests.rs +1 -1
- package/contracts/message-libs/treasury/src/treasury.rs +14 -16
- package/contracts/message-libs/uln-302/src/receive_uln.rs +13 -2
- package/contracts/message-libs/uln-302/src/send_uln.rs +23 -3
- package/contracts/message-libs/uln-302/src/uln302.rs +6 -24
- package/contracts/oapps/counter/Cargo.toml +14 -1
- package/contracts/oapps/counter/integration_tests/mod.rs +4 -1
- package/contracts/oapps/counter/integration_tests/{setup.rs → setup_sml.rs} +48 -80
- package/contracts/oapps/counter/integration_tests/setup_uln.rs +997 -0
- package/contracts/oapps/counter/integration_tests/signing.rs +62 -0
- package/contracts/oapps/counter/integration_tests/test_with_sml.rs +24 -55
- package/contracts/oapps/counter/integration_tests/test_with_uln.rs +314 -0
- package/contracts/oapps/counter/integration_tests/utils.rs +196 -53
- package/contracts/oapps/counter/src/counter.rs +67 -43
- package/contracts/oapps/counter/src/tests/mod.rs +0 -13
- package/contracts/oapps/counter/src/tests/test_counter.rs +5 -7
- package/contracts/oapps/oapp/src/errors.rs +5 -1
- package/contracts/oapps/oapp/src/macro_tests/test_macros.rs +93 -78
- package/contracts/oapps/oapp/src/oapp_core.rs +36 -21
- package/contracts/oapps/oapp/src/oapp_options_type3.rs +48 -12
- package/contracts/oapps/oapp/src/oapp_receiver.rs +106 -41
- package/contracts/oapps/oapp/src/oapp_sender.rs +26 -34
- package/contracts/oapps/oapp/src/tests/test_oapp_core.rs +9 -8
- package/contracts/oapps/oapp/src/tests/test_oapp_options_type3.rs +25 -17
- package/contracts/oapps/oapp/src/tests/test_oapp_receiver.rs +7 -7
- package/contracts/oapps/oapp/src/tests/test_oapp_sender.rs +14 -15
- package/contracts/oapps/oapp-macros/src/generators.rs +128 -0
- package/contracts/oapps/oapp-macros/src/lib.rs +113 -56
- package/contracts/oapps/oft/integration-tests/setup.rs +25 -7
- package/contracts/oapps/oft/src/errors.rs +6 -1
- package/contracts/oapps/oft/src/extensions/oft_fee.rs +8 -8
- package/contracts/oapps/oft/src/extensions/pausable.rs +4 -4
- package/contracts/oapps/oft/src/extensions/rate_limiter.rs +5 -5
- package/contracts/oapps/oft/src/lib.rs +4 -2
- package/contracts/oapps/oft/src/oft.rs +24 -64
- package/contracts/oapps/oft/src/oft_impl.rs +201 -0
- package/contracts/oapps/oft/src/oft_types/lock_unlock.rs +1 -3
- package/contracts/oapps/oft/src/oft_types/mint_burn.rs +1 -4
- package/contracts/oapps/oft/src/storage.rs +2 -0
- package/contracts/oapps/oft/src/tests/extensions/setup.rs +36 -22
- package/contracts/oapps/oft/src/tests/extensions/test_oft_fee.rs +5 -3
- package/contracts/oapps/oft/src/tests/extensions/test_pausable.rs +5 -3
- package/contracts/oapps/oft/src/tests/extensions/test_rate_limiter.rs +5 -3
- package/contracts/oapps/oft/src/tests/test_decimals.rs +2 -2
- package/contracts/oapps/oft/src/tests/test_oft_msg_codec.rs +1 -2
- package/contracts/oapps/oft/src/tests/test_utils.rs +45 -23
- package/contracts/oapps/oft/src/types.rs +20 -0
- package/contracts/oapps/oft-std/integration-tests/setup.rs +4 -2
- package/contracts/oapps/oft-std/src/oft.rs +24 -6
- package/contracts/upgrader/src/lib.rs +4 -4
- package/contracts/utils/src/auth.rs +44 -0
- package/contracts/utils/src/errors.rs +27 -5
- package/contracts/utils/src/lib.rs +3 -0
- package/contracts/utils/src/multisig.rs +211 -0
- package/contracts/utils/src/ownable.rs +12 -10
- package/contracts/utils/src/tests/buffer_reader.rs +6 -6
- package/contracts/utils/src/tests/buffer_writer.rs +6 -6
- package/contracts/utils/src/tests/bytes_ext.rs +2 -4
- package/contracts/utils/src/tests/mod.rs +1 -0
- package/contracts/utils/src/tests/multisig.rs +731 -0
- package/contracts/utils/src/tests/option_ext.rs +2 -5
- package/contracts/utils/src/tests/ownable.rs +16 -5
- package/contracts/utils/src/tests/ttl_configurable.rs +27 -16
- package/contracts/utils/src/tests/upgradeable.rs +4 -2
- package/contracts/utils/src/ttl_configurable.rs +23 -8
- package/contracts/utils/src/ttl_extendable.rs +27 -0
- package/contracts/utils/src/upgradeable.rs +2 -0
- package/contracts/workers/dvn/Cargo.toml +1 -1
- package/contracts/workers/dvn/src/auth.rs +7 -7
- package/contracts/workers/dvn/src/dvn.rs +10 -38
- package/contracts/workers/dvn/src/errors.rs +0 -7
- package/contracts/workers/dvn/src/events.rs +1 -14
- package/contracts/workers/dvn/src/interfaces/dvn.rs +2 -2
- package/contracts/workers/dvn/src/interfaces/mod.rs +0 -2
- package/contracts/workers/dvn/src/storage.rs +3 -13
- package/contracts/workers/dvn/src/tests/auth.rs +4 -4
- package/contracts/workers/dvn/src/tests/dvn.rs +1 -2
- package/contracts/workers/dvn/src/tests/multisig/set_signer.rs +7 -8
- package/contracts/workers/dvn/src/tests/multisig/set_threshold.rs +11 -8
- package/contracts/workers/dvn/src/tests/multisig/verify_signatures.rs +11 -12
- package/contracts/workers/dvn/src/tests/setup.rs +5 -5
- package/contracts/workers/dvn-fee-lib/Cargo.toml +1 -1
- package/contracts/workers/dvn-fee-lib/src/dvn_fee_lib.rs +3 -6
- package/contracts/workers/executor/src/auth.rs +80 -16
- package/contracts/workers/executor/src/executor.rs +5 -31
- package/contracts/workers/executor/src/storage.rs +2 -9
- package/contracts/workers/executor-fee-lib/Cargo.toml +1 -1
- package/contracts/workers/executor-fee-lib/src/executor_fee_lib.rs +3 -6
- package/contracts/workers/executor-helper/Cargo.toml +1 -1
- package/contracts/workers/executor-helper/src/executor_helper.rs +53 -73
- package/contracts/workers/price-feed/Cargo.toml +1 -1
- package/contracts/workers/price-feed/src/price_feed.rs +7 -10
- package/contracts/workers/worker/src/errors.rs +4 -0
- package/contracts/workers/worker/src/tests/worker.rs +7 -6
- package/contracts/workers/worker/src/worker.rs +20 -16
- package/package.json +8 -5
- package/sdk/.turbo/turbo-build.log +1 -0
- package/sdk/.turbo/turbo-test.log +1009 -0
- package/sdk/dist/generated/bml.d.ts +65 -8
- package/sdk/dist/generated/bml.js +70 -34
- package/sdk/dist/generated/counter.d.ts +167 -42
- package/sdk/dist/generated/counter.js +86 -45
- package/sdk/dist/generated/dvn.d.ts +282 -229
- package/sdk/dist/generated/dvn.js +119 -81
- package/sdk/dist/generated/dvn_fee_lib.d.ts +142 -67
- package/sdk/dist/generated/dvn_fee_lib.js +64 -24
- package/sdk/dist/generated/endpoint.d.ts +97 -22
- package/sdk/dist/generated/endpoint.js +75 -37
- package/sdk/dist/generated/executor.d.ts +117 -85
- package/sdk/dist/generated/executor.js +102 -59
- package/sdk/dist/generated/executor_fee_lib.d.ts +162 -78
- package/sdk/dist/generated/executor_fee_lib.js +104 -57
- package/sdk/dist/generated/executor_helper.d.ts +133 -21
- package/sdk/dist/generated/executor_helper.js +99 -50
- package/sdk/dist/generated/oft_std.d.ts +233 -55
- package/sdk/dist/generated/oft_std.js +99 -54
- package/sdk/dist/generated/price_feed.d.ts +142 -67
- package/sdk/dist/generated/price_feed.js +64 -24
- package/sdk/dist/generated/sml.d.ts +113 -32
- package/sdk/dist/generated/sml.js +93 -49
- package/sdk/dist/generated/treasury.d.ts +896 -0
- package/sdk/dist/generated/treasury.js +219 -0
- package/sdk/dist/generated/uln302.d.ts +113 -32
- package/sdk/dist/generated/uln302.js +93 -49
- package/sdk/dist/generated/upgrader.d.ts +2 -2
- package/sdk/dist/generated/upgrader.js +1 -1
- package/sdk/dist/index.d.ts +2 -0
- package/sdk/dist/index.js +3 -0
- package/sdk/dist/wasm/blocked-message-lib.d.ts +1 -0
- package/sdk/dist/wasm/blocked-message-lib.js +2 -0
- package/sdk/dist/wasm/counter.d.ts +1 -0
- package/sdk/dist/wasm/counter.js +2 -0
- package/sdk/dist/wasm/dvn-fee-lib.d.ts +1 -0
- package/sdk/dist/wasm/dvn-fee-lib.js +2 -0
- package/sdk/dist/wasm/dvn.d.ts +1 -0
- package/sdk/dist/wasm/dvn.js +2 -0
- package/sdk/dist/wasm/endpoint-v2.d.ts +1 -0
- package/sdk/dist/wasm/endpoint-v2.js +2 -0
- package/sdk/dist/wasm/executor-fee-lib.d.ts +1 -0
- package/sdk/dist/wasm/executor-fee-lib.js +2 -0
- package/sdk/dist/wasm/executor-helper.d.ts +1 -0
- package/sdk/dist/wasm/executor-helper.js +2 -0
- package/sdk/dist/wasm/executor.d.ts +1 -0
- package/sdk/dist/wasm/executor.js +2 -0
- package/sdk/dist/wasm/layerzero-views.d.ts +1 -0
- package/sdk/dist/wasm/layerzero-views.js +2 -0
- package/sdk/dist/wasm/oft-std.d.ts +1 -0
- package/sdk/dist/wasm/oft-std.js +2 -0
- package/sdk/dist/wasm/price-feed.d.ts +1 -0
- package/sdk/dist/wasm/price-feed.js +2 -0
- package/sdk/dist/wasm/simple-message-lib.d.ts +1 -0
- package/sdk/dist/wasm/simple-message-lib.js +2 -0
- package/sdk/dist/wasm/treasury.d.ts +1 -0
- package/sdk/dist/wasm/treasury.js +2 -0
- package/sdk/dist/wasm/uln302.d.ts +1 -0
- package/sdk/dist/wasm/uln302.js +2 -0
- package/sdk/dist/wasm/upgrader.d.ts +1 -0
- package/sdk/dist/wasm/upgrader.js +2 -0
- package/sdk/dist/wasm.d.ts +15 -0
- package/sdk/dist/wasm.js +15 -0
- package/sdk/package.json +4 -2
- package/sdk/src/index.ts +4 -0
- package/sdk/test/counter-sml.test.ts +376 -0
- package/sdk/test/counter-uln.test.ts +493 -0
- package/sdk/test/{oft.test.ts → oft-sml.test.ts} +185 -310
- package/sdk/test/suites/constants.ts +22 -2
- package/sdk/test/suites/globalSetup.ts +450 -0
- package/sdk/test/suites/localnet.ts +23 -6
- package/sdk/test/upgrader.test.ts +7 -16
- package/sdk/test/utils.ts +558 -85
- package/sdk/vitest.config.ts +21 -0
- package/tools/ts-bindings-gen/src/main.rs +1 -0
- package/turbo.json +2 -0
- package/contracts/common-macros/src/contract_impl.rs +0 -52
- package/contracts/common-macros/src/ownable.rs +0 -41
- package/contracts/common-macros/src/tests/contract_impl.rs +0 -386
- package/contracts/common-macros/src/tests/snapshots/common_macros__tests__ownable__snapshot_generated_ownable_code.snap +0 -12
- package/contracts/macro-integration-tests/tests/runtime/ttl_configurable/extend_instance_ttl.rs +0 -50
- package/contracts/oapps/oapp-macros/src/oapp_core.rs +0 -41
- package/contracts/oapps/oapp-macros/src/oapp_full.rs +0 -21
- package/contracts/oapps/oapp-macros/src/oapp_options_type3.rs +0 -31
- package/contracts/oapps/oapp-macros/src/oapp_receiver.rs +0 -48
- package/contracts/oapps/oapp-macros/src/oapp_sender.rs +0 -21
- package/contracts/oapps/oapp-macros/src/util.rs +0 -107
- package/contracts/oapps/oft/src/constants.rs +0 -5
- package/contracts/oapps/oft/src/default_oft_impl.rs +0 -152
- package/contracts/workers/dvn/src/interfaces/multisig.rs +0 -56
- package/contracts/workers/dvn/src/multisig.rs +0 -157
- package/sdk/test/index.test.ts +0 -375
- /package/sdk/test/suites/{testUpgradeable.ts → dummyContractClient.ts} +0 -0
|
@@ -116,6 +116,9 @@ export declare const EndpointError: {
|
|
|
116
116
|
24: {
|
|
117
117
|
message: string;
|
|
118
118
|
};
|
|
119
|
+
25: {
|
|
120
|
+
message: string;
|
|
121
|
+
};
|
|
119
122
|
};
|
|
120
123
|
/**
|
|
121
124
|
* Parameters for sending a cross-chain message.
|
|
@@ -328,43 +331,52 @@ export interface FeesAndPacket {
|
|
|
328
331
|
*/
|
|
329
332
|
zro_fee_recipients: Array<FeeRecipient>;
|
|
330
333
|
}
|
|
334
|
+
/**
|
|
335
|
+
* PacketCodecV1Error: 1100-1109
|
|
336
|
+
*/
|
|
331
337
|
export declare const PacketCodecV1Error: {
|
|
332
|
-
|
|
338
|
+
1100: {
|
|
333
339
|
message: string;
|
|
334
340
|
};
|
|
335
|
-
|
|
341
|
+
1101: {
|
|
336
342
|
message: string;
|
|
337
343
|
};
|
|
338
344
|
};
|
|
345
|
+
/**
|
|
346
|
+
* WorkerOptionsError: 1110-1119
|
|
347
|
+
*/
|
|
339
348
|
export declare const WorkerOptionsError: {
|
|
340
|
-
|
|
349
|
+
1110: {
|
|
341
350
|
message: string;
|
|
342
351
|
};
|
|
343
|
-
|
|
352
|
+
1111: {
|
|
344
353
|
message: string;
|
|
345
354
|
};
|
|
346
|
-
|
|
355
|
+
1112: {
|
|
347
356
|
message: string;
|
|
348
357
|
};
|
|
349
|
-
|
|
358
|
+
1113: {
|
|
350
359
|
message: string;
|
|
351
360
|
};
|
|
352
|
-
|
|
361
|
+
1114: {
|
|
353
362
|
message: string;
|
|
354
363
|
};
|
|
355
|
-
|
|
364
|
+
1115: {
|
|
356
365
|
message: string;
|
|
357
366
|
};
|
|
358
|
-
|
|
367
|
+
1116: {
|
|
359
368
|
message: string;
|
|
360
369
|
};
|
|
361
|
-
|
|
370
|
+
1117: {
|
|
362
371
|
message: string;
|
|
363
372
|
};
|
|
364
|
-
|
|
373
|
+
1118: {
|
|
365
374
|
message: string;
|
|
366
375
|
};
|
|
367
376
|
};
|
|
377
|
+
/**
|
|
378
|
+
* BufferReaderError: 1000-1009
|
|
379
|
+
*/
|
|
368
380
|
export declare const BufferReaderError: {
|
|
369
381
|
1000: {
|
|
370
382
|
message: string;
|
|
@@ -373,40 +385,91 @@ export declare const BufferReaderError: {
|
|
|
373
385
|
message: string;
|
|
374
386
|
};
|
|
375
387
|
};
|
|
388
|
+
/**
|
|
389
|
+
* BufferWriterError: 1010-1019
|
|
390
|
+
*/
|
|
376
391
|
export declare const BufferWriterError: {
|
|
377
|
-
|
|
392
|
+
1010: {
|
|
378
393
|
message: string;
|
|
379
394
|
};
|
|
380
395
|
};
|
|
396
|
+
/**
|
|
397
|
+
* TtlConfigurableError: 1020-1029
|
|
398
|
+
*/
|
|
381
399
|
export declare const TtlConfigurableError: {
|
|
382
|
-
|
|
400
|
+
1020: {
|
|
383
401
|
message: string;
|
|
384
402
|
};
|
|
385
|
-
|
|
403
|
+
1021: {
|
|
386
404
|
message: string;
|
|
387
405
|
};
|
|
388
|
-
|
|
406
|
+
1022: {
|
|
389
407
|
message: string;
|
|
390
408
|
};
|
|
391
409
|
};
|
|
410
|
+
/**
|
|
411
|
+
* OwnableError: 1030-1039
|
|
412
|
+
*/
|
|
392
413
|
export declare const OwnableError: {
|
|
393
|
-
|
|
414
|
+
1030: {
|
|
394
415
|
message: string;
|
|
395
416
|
};
|
|
396
|
-
|
|
417
|
+
1031: {
|
|
397
418
|
message: string;
|
|
398
419
|
};
|
|
399
420
|
};
|
|
421
|
+
/**
|
|
422
|
+
* BytesExtError: 1040-1049
|
|
423
|
+
*/
|
|
400
424
|
export declare const BytesExtError: {
|
|
401
|
-
|
|
425
|
+
1040: {
|
|
402
426
|
message: string;
|
|
403
427
|
};
|
|
404
428
|
};
|
|
429
|
+
/**
|
|
430
|
+
* UpgradeableError: 1050-1059
|
|
431
|
+
*/
|
|
405
432
|
export declare const UpgradeableError: {
|
|
406
|
-
|
|
433
|
+
1050: {
|
|
407
434
|
message: string;
|
|
408
435
|
};
|
|
409
436
|
};
|
|
437
|
+
/**
|
|
438
|
+
* MultisigError: 1060-1069
|
|
439
|
+
*/
|
|
440
|
+
export declare const MultisigError: {
|
|
441
|
+
1060: {
|
|
442
|
+
message: string;
|
|
443
|
+
};
|
|
444
|
+
1061: {
|
|
445
|
+
message: string;
|
|
446
|
+
};
|
|
447
|
+
1062: {
|
|
448
|
+
message: string;
|
|
449
|
+
};
|
|
450
|
+
1063: {
|
|
451
|
+
message: string;
|
|
452
|
+
};
|
|
453
|
+
1064: {
|
|
454
|
+
message: string;
|
|
455
|
+
};
|
|
456
|
+
1065: {
|
|
457
|
+
message: string;
|
|
458
|
+
};
|
|
459
|
+
1066: {
|
|
460
|
+
message: string;
|
|
461
|
+
};
|
|
462
|
+
1067: {
|
|
463
|
+
message: string;
|
|
464
|
+
};
|
|
465
|
+
};
|
|
466
|
+
export type MultisigStorage = {
|
|
467
|
+
tag: "Signers";
|
|
468
|
+
values: void;
|
|
469
|
+
} | {
|
|
470
|
+
tag: "Threshold";
|
|
471
|
+
values: void;
|
|
472
|
+
};
|
|
410
473
|
export type OwnableStorage = {
|
|
411
474
|
tag: "Owner";
|
|
412
475
|
values: void;
|
|
@@ -438,6 +501,9 @@ export type UpgradeableStorage = {
|
|
|
438
501
|
tag: "Migrating";
|
|
439
502
|
values: void;
|
|
440
503
|
};
|
|
504
|
+
/**
|
|
505
|
+
* WorkerError: 1200-1299
|
|
506
|
+
*/
|
|
441
507
|
export declare const WorkerError: {
|
|
442
508
|
1200: {
|
|
443
509
|
message: string;
|
|
@@ -734,18 +800,9 @@ export interface Client {
|
|
|
734
800
|
simulate?: boolean;
|
|
735
801
|
}) => Promise<AssembledTransaction<null>>;
|
|
736
802
|
/**
|
|
737
|
-
* Construct and simulate a
|
|
738
|
-
* Extends the instance TTL.
|
|
739
|
-
*
|
|
740
|
-
* # Arguments
|
|
741
|
-
*
|
|
742
|
-
* * `threshold` - The threshold to extend the TTL.
|
|
743
|
-
* * `extend_to` - The TTL to extend to.
|
|
803
|
+
* Construct and simulate a authorizer transaction. Returns an `AssembledTransaction` object which will have a `result` field containing the result of the simulation. If this transaction changes contract state, you will need to call `signAndSend()` on the returned object.
|
|
744
804
|
*/
|
|
745
|
-
|
|
746
|
-
threshold: u32;
|
|
747
|
-
extend_to: u32;
|
|
748
|
-
}, txnOptions?: {
|
|
805
|
+
authorizer: (txnOptions?: {
|
|
749
806
|
/**
|
|
750
807
|
* The fee to pay for the transaction. Default: BASE_FEE
|
|
751
808
|
*/
|
|
@@ -758,7 +815,7 @@ export interface Client {
|
|
|
758
815
|
* Whether to automatically simulate the transaction when constructing the AssembledTransaction. Default: true
|
|
759
816
|
*/
|
|
760
817
|
simulate?: boolean;
|
|
761
|
-
}) => Promise<AssembledTransaction<
|
|
818
|
+
}) => Promise<AssembledTransaction<string>>;
|
|
762
819
|
/**
|
|
763
820
|
* Construct and simulate a get_fee transaction. Returns an `AssembledTransaction` object which will have a `result` field containing the result of the simulation. If this transaction changes contract state, you will need to call `signAndSend()` on the returned object.
|
|
764
821
|
* Calculates the total execution fee for a cross-chain message.
|
|
@@ -817,10 +874,24 @@ export interface Client {
|
|
|
817
874
|
simulate?: boolean;
|
|
818
875
|
}) => Promise<AssembledTransaction<readonly [u64, u32]>>;
|
|
819
876
|
/**
|
|
820
|
-
* Construct and simulate a
|
|
821
|
-
*
|
|
877
|
+
* Construct and simulate a set_ttl_configs transaction. Returns an `AssembledTransaction` object which will have a `result` field containing the result of the simulation. If this transaction changes contract state, you will need to call `signAndSend()` on the returned object.
|
|
878
|
+
* Sets TTL configs for instance and persistent storage.
|
|
879
|
+
*
|
|
880
|
+
* - `None` values remove the corresponding config (disables auto-extension for that type)
|
|
881
|
+
* - Validates that `threshold <= extend_to <= MAX_TTL`
|
|
882
|
+
*
|
|
883
|
+
* # Arguments
|
|
884
|
+
* - `instance` - TTL config for instance storage
|
|
885
|
+
* - `persistent` - TTL config for persistent storage
|
|
886
|
+
*
|
|
887
|
+
* # Panics
|
|
888
|
+
* - `TtlConfigFrozen` if configs are frozen
|
|
889
|
+
* - `InvalidTtlConfig` if validation fails
|
|
822
890
|
*/
|
|
823
|
-
|
|
891
|
+
set_ttl_configs: ({ instance, persistent }: {
|
|
892
|
+
instance: Option<TtlConfig>;
|
|
893
|
+
persistent: Option<TtlConfig>;
|
|
894
|
+
}, txnOptions?: {
|
|
824
895
|
/**
|
|
825
896
|
* The fee to pay for the transaction. Default: BASE_FEE
|
|
826
897
|
*/
|
|
@@ -833,14 +904,12 @@ export interface Client {
|
|
|
833
904
|
* Whether to automatically simulate the transaction when constructing the AssembledTransaction. Default: true
|
|
834
905
|
*/
|
|
835
906
|
simulate?: boolean;
|
|
836
|
-
}) => Promise<AssembledTransaction<
|
|
907
|
+
}) => Promise<AssembledTransaction<null>>;
|
|
837
908
|
/**
|
|
838
|
-
* Construct and simulate a
|
|
839
|
-
*
|
|
909
|
+
* Construct and simulate a ttl_configs transaction. Returns an `AssembledTransaction` object which will have a `result` field containing the result of the simulation. If this transaction changes contract state, you will need to call `signAndSend()` on the returned object.
|
|
910
|
+
* Returns the current TTL configs as (instance_config, persistent_config).
|
|
840
911
|
*/
|
|
841
|
-
|
|
842
|
-
new_owner: string;
|
|
843
|
-
}, txnOptions?: {
|
|
912
|
+
ttl_configs: (txnOptions?: {
|
|
844
913
|
/**
|
|
845
914
|
* The fee to pay for the transaction. Default: BASE_FEE
|
|
846
915
|
*/
|
|
@@ -853,12 +922,18 @@ export interface Client {
|
|
|
853
922
|
* Whether to automatically simulate the transaction when constructing the AssembledTransaction. Default: true
|
|
854
923
|
*/
|
|
855
924
|
simulate?: boolean;
|
|
856
|
-
}) => Promise<AssembledTransaction<
|
|
925
|
+
}) => Promise<AssembledTransaction<readonly [Option<TtlConfig>, Option<TtlConfig>]>>;
|
|
857
926
|
/**
|
|
858
|
-
* Construct and simulate a
|
|
859
|
-
* Permanently
|
|
927
|
+
* Construct and simulate a freeze_ttl_configs transaction. Returns an `AssembledTransaction` object which will have a `result` field containing the result of the simulation. If this transaction changes contract state, you will need to call `signAndSend()` on the returned object.
|
|
928
|
+
* Permanently freezes TTL configs, preventing any future modifications.
|
|
929
|
+
*
|
|
930
|
+
* This is irreversible and provides immutability guarantees to users.
|
|
931
|
+
* Emits `TtlConfigsFrozen` event.
|
|
932
|
+
*
|
|
933
|
+
* # Panics
|
|
934
|
+
* - `TtlConfigAlreadyFrozen` if already frozen
|
|
860
935
|
*/
|
|
861
|
-
|
|
936
|
+
freeze_ttl_configs: (txnOptions?: {
|
|
862
937
|
/**
|
|
863
938
|
* The fee to pay for the transaction. Default: BASE_FEE
|
|
864
939
|
*/
|
|
@@ -873,23 +948,35 @@ export interface Client {
|
|
|
873
948
|
simulate?: boolean;
|
|
874
949
|
}) => Promise<AssembledTransaction<null>>;
|
|
875
950
|
/**
|
|
876
|
-
* Construct and simulate a
|
|
877
|
-
*
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
951
|
+
* Construct and simulate a is_ttl_configs_frozen transaction. Returns an `AssembledTransaction` object which will have a `result` field containing the result of the simulation. If this transaction changes contract state, you will need to call `signAndSend()` on the returned object.
|
|
952
|
+
* Returns whether TTL configs are frozen.
|
|
953
|
+
*/
|
|
954
|
+
is_ttl_configs_frozen: (txnOptions?: {
|
|
955
|
+
/**
|
|
956
|
+
* The fee to pay for the transaction. Default: BASE_FEE
|
|
957
|
+
*/
|
|
958
|
+
fee?: number;
|
|
959
|
+
/**
|
|
960
|
+
* The maximum amount of time to wait for the transaction to complete. Default: DEFAULT_TIMEOUT
|
|
961
|
+
*/
|
|
962
|
+
timeoutInSeconds?: number;
|
|
963
|
+
/**
|
|
964
|
+
* Whether to automatically simulate the transaction when constructing the AssembledTransaction. Default: true
|
|
965
|
+
*/
|
|
966
|
+
simulate?: boolean;
|
|
967
|
+
}) => Promise<AssembledTransaction<boolean>>;
|
|
968
|
+
/**
|
|
969
|
+
* Construct and simulate a extend_instance_ttl transaction. Returns an `AssembledTransaction` object which will have a `result` field containing the result of the simulation. If this transaction changes contract state, you will need to call `signAndSend()` on the returned object.
|
|
970
|
+
* Extends the instance TTL.
|
|
881
971
|
*
|
|
882
972
|
* # Arguments
|
|
883
|
-
* - `instance` - TTL config for instance storage
|
|
884
|
-
* - `persistent` - TTL config for persistent storage
|
|
885
973
|
*
|
|
886
|
-
*
|
|
887
|
-
*
|
|
888
|
-
* - `InvalidTtlConfig` if validation fails
|
|
974
|
+
* * `threshold` - The threshold to extend the TTL (if current TTL is below this, extend).
|
|
975
|
+
* * `extend_to` - The TTL to extend to.
|
|
889
976
|
*/
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
977
|
+
extend_instance_ttl: ({ threshold, extend_to }: {
|
|
978
|
+
threshold: u32;
|
|
979
|
+
extend_to: u32;
|
|
893
980
|
}, txnOptions?: {
|
|
894
981
|
/**
|
|
895
982
|
* The fee to pay for the transaction. Default: BASE_FEE
|
|
@@ -905,10 +992,10 @@ export interface Client {
|
|
|
905
992
|
simulate?: boolean;
|
|
906
993
|
}) => Promise<AssembledTransaction<null>>;
|
|
907
994
|
/**
|
|
908
|
-
* Construct and simulate a
|
|
909
|
-
* Returns the current
|
|
995
|
+
* Construct and simulate a owner transaction. Returns an `AssembledTransaction` object which will have a `result` field containing the result of the simulation. If this transaction changes contract state, you will need to call `signAndSend()` on the returned object.
|
|
996
|
+
* Returns the current owner address, or None if no owner is set.
|
|
910
997
|
*/
|
|
911
|
-
|
|
998
|
+
owner: (txnOptions?: {
|
|
912
999
|
/**
|
|
913
1000
|
* The fee to pay for the transaction. Default: BASE_FEE
|
|
914
1001
|
*/
|
|
@@ -921,18 +1008,14 @@ export interface Client {
|
|
|
921
1008
|
* Whether to automatically simulate the transaction when constructing the AssembledTransaction. Default: true
|
|
922
1009
|
*/
|
|
923
1010
|
simulate?: boolean;
|
|
924
|
-
}) => Promise<AssembledTransaction<
|
|
1011
|
+
}) => Promise<AssembledTransaction<Option<string>>>;
|
|
925
1012
|
/**
|
|
926
|
-
* Construct and simulate a
|
|
927
|
-
*
|
|
928
|
-
*
|
|
929
|
-
* This is irreversible and provides immutability guarantees to users.
|
|
930
|
-
* Emits `TtlConfigsFrozen` event.
|
|
931
|
-
*
|
|
932
|
-
* # Panics
|
|
933
|
-
* - `TtlConfigAlreadyFrozen` if already frozen
|
|
1013
|
+
* Construct and simulate a transfer_ownership transaction. Returns an `AssembledTransaction` object which will have a `result` field containing the result of the simulation. If this transaction changes contract state, you will need to call `signAndSend()` on the returned object.
|
|
1014
|
+
* Transfers ownership to a new address. Requires current owner authorization.
|
|
934
1015
|
*/
|
|
935
|
-
|
|
1016
|
+
transfer_ownership: ({ new_owner }: {
|
|
1017
|
+
new_owner: string;
|
|
1018
|
+
}, txnOptions?: {
|
|
936
1019
|
/**
|
|
937
1020
|
* The fee to pay for the transaction. Default: BASE_FEE
|
|
938
1021
|
*/
|
|
@@ -947,10 +1030,10 @@ export interface Client {
|
|
|
947
1030
|
simulate?: boolean;
|
|
948
1031
|
}) => Promise<AssembledTransaction<null>>;
|
|
949
1032
|
/**
|
|
950
|
-
* Construct and simulate a
|
|
951
|
-
*
|
|
1033
|
+
* Construct and simulate a renounce_ownership transaction. Returns an `AssembledTransaction` object which will have a `result` field containing the result of the simulation. If this transaction changes contract state, you will need to call `signAndSend()` on the returned object.
|
|
1034
|
+
* Permanently renounces ownership. Requires current owner authorization.
|
|
952
1035
|
*/
|
|
953
|
-
|
|
1036
|
+
renounce_ownership: (txnOptions?: {
|
|
954
1037
|
/**
|
|
955
1038
|
* The fee to pay for the transaction. Default: BASE_FEE
|
|
956
1039
|
*/
|
|
@@ -963,7 +1046,7 @@ export interface Client {
|
|
|
963
1046
|
* Whether to automatically simulate the transaction when constructing the AssembledTransaction. Default: true
|
|
964
1047
|
*/
|
|
965
1048
|
simulate?: boolean;
|
|
966
|
-
}) => Promise<AssembledTransaction<
|
|
1049
|
+
}) => Promise<AssembledTransaction<null>>;
|
|
967
1050
|
}
|
|
968
1051
|
export declare class Client extends ContractClient {
|
|
969
1052
|
readonly options: ContractClientOptions;
|
|
@@ -985,15 +1068,16 @@ export declare class Client extends ContractClient {
|
|
|
985
1068
|
readonly fromJSON: {
|
|
986
1069
|
upgrade: (json: string) => AssembledTransaction<null>;
|
|
987
1070
|
migrate: (json: string) => AssembledTransaction<null>;
|
|
988
|
-
|
|
1071
|
+
authorizer: (json: string) => AssembledTransaction<string>;
|
|
989
1072
|
get_fee: (json: string) => AssembledTransaction<bigint>;
|
|
990
1073
|
version: (json: string) => AssembledTransaction<readonly [bigint, number]>;
|
|
991
|
-
owner: (json: string) => AssembledTransaction<Option<string>>;
|
|
992
|
-
transfer_ownership: (json: string) => AssembledTransaction<null>;
|
|
993
|
-
renounce_ownership: (json: string) => AssembledTransaction<null>;
|
|
994
1074
|
set_ttl_configs: (json: string) => AssembledTransaction<null>;
|
|
995
1075
|
ttl_configs: (json: string) => AssembledTransaction<readonly [Option<TtlConfig>, Option<TtlConfig>]>;
|
|
996
1076
|
freeze_ttl_configs: (json: string) => AssembledTransaction<null>;
|
|
997
1077
|
is_ttl_configs_frozen: (json: string) => AssembledTransaction<boolean>;
|
|
1078
|
+
extend_instance_ttl: (json: string) => AssembledTransaction<null>;
|
|
1079
|
+
owner: (json: string) => AssembledTransaction<Option<string>>;
|
|
1080
|
+
transfer_ownership: (json: string) => AssembledTransaction<null>;
|
|
1081
|
+
renounce_ownership: (json: string) => AssembledTransaction<null>;
|
|
998
1082
|
};
|
|
999
1083
|
}
|