@aztec/aztec.js 0.73.0 → 0.75.0-commit.c03ba01a2a4122e43e90d5133ba017e54b90e9d2
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/README.md +1 -1
- package/dest/account/contract.js +5 -3
- package/dest/account/index.js +8 -2
- package/dest/account/interface.js +4 -3
- package/dest/account/wallet.js +3 -2
- package/dest/account_manager/deploy_account_method.js +22 -25
- package/dest/account_manager/deploy_account_sent_tx.js +16 -17
- package/dest/account_manager/index.js +67 -78
- package/dest/api/abi.js +0 -1
- package/dest/api/account.js +0 -1
- package/dest/api/addresses.js +0 -1
- package/dest/api/cheat_codes.js +25 -0
- package/dest/api/deployment.js +0 -1
- package/dest/api/entrypoint.js +0 -1
- package/dest/api/eth_address.js +0 -1
- package/dest/api/ethereum/anvil_test_watcher.js +113 -0
- package/dest/api/ethereum/chain_monitor.js +69 -0
- package/dest/api/ethereum/cheat_codes.js +142 -0
- package/dest/api/ethereum/index.js +6 -0
- package/dest/api/ethereum/l1_contracts.js +13 -0
- package/dest/api/ethereum/portal_manager.js +284 -0
- package/dest/api/fee.js +0 -1
- package/dest/api/fields.js +0 -1
- package/dest/api/interfaces/pxe.js +1 -2
- package/dest/api/log.js +1 -0
- package/dest/api/log_id.js +0 -1
- package/dest/api/tx_hash.js +0 -1
- package/dest/api/wallet.js +1 -2
- package/dest/contract/base_contract_interaction.js +75 -52
- package/dest/contract/batch_call.js +57 -39
- package/dest/contract/checker.js +29 -20
- package/dest/contract/contract.js +22 -27
- package/dest/contract/contract_base.js +21 -30
- package/dest/contract/contract_function_interaction.js +48 -48
- package/dest/contract/deploy_method.js +99 -84
- package/dest/contract/deploy_proven_tx.js +8 -11
- package/dest/contract/deploy_sent_tx.js +19 -22
- package/dest/contract/get_gas_limits.js +2 -4
- package/dest/contract/index.js +4 -6
- package/dest/contract/proven_tx.js +7 -10
- package/dest/contract/sent_tx.js +32 -34
- package/dest/contract/unsafe_contract.js +2 -10
- package/dest/deployment/broadcast_function.js +28 -26
- package/dest/deployment/contract_deployer.js +15 -14
- package/dest/deployment/deploy_instance.js +1 -3
- package/dest/deployment/index.js +0 -1
- package/dest/deployment/protocol_contracts.js +2 -5
- package/dest/deployment/register_class.js +8 -8
- package/dest/entrypoint/default_entrypoint.js +8 -5
- package/dest/entrypoint/default_multi_call_entrypoint.js +66 -23
- package/dest/entrypoint/entrypoint.js +0 -1
- package/dest/entrypoint/payload.js +73 -82
- package/dest/fee/fee_juice_payment_method.js +3 -4
- package/dest/fee/fee_juice_payment_method_with_claim.js +11 -14
- package/dest/fee/fee_payment_method.js +3 -2
- package/dest/fee/no_fee_payment_method.js +2 -4
- package/dest/fee/private_fee_payment_method.js +36 -34
- package/dest/fee/public_fee_payment_method.js +34 -31
- package/dest/index.js +8 -9
- package/dest/rpc_clients/index.js +0 -1
- package/dest/rpc_clients/node/index.js +30 -16
- package/dest/rpc_clients/pxe_client.js +5 -3
- package/dest/utils/abi_types.js +1 -2
- package/dest/utils/authwit.js +15 -15
- package/dest/utils/aztec_cheatcodes.js +62 -0
- package/dest/utils/field_compressed_string.js +2 -4
- package/dest/utils/index.js +5 -12
- package/dest/utils/node.js +4 -5
- package/dest/utils/pub_key.js +1 -3
- package/dest/utils/pxe.js +3 -5
- package/dest/wallet/account_wallet.js +118 -81
- package/dest/wallet/account_wallet_with_private_key.js +9 -15
- package/dest/wallet/base_wallet.js +7 -5
- package/dest/wallet/index.js +2 -4
- package/dest/wallet/signerless_wallet.js +4 -6
- package/package.json +14 -17
- package/src/api/account.ts +7 -1
- package/src/api/cheat_codes.ts +35 -0
- package/src/{utils → api/ethereum}/anvil_test_watcher.ts +2 -1
- package/src/{utils → api/ethereum}/cheat_codes.ts +6 -109
- package/src/api/ethereum/index.ts +15 -0
- package/src/{utils → api/ethereum}/l1_contracts.ts +1 -1
- package/src/{utils → api/ethereum}/portal_manager.ts +4 -9
- package/src/api/interfaces/pxe.ts +1 -1
- package/src/api/log.ts +1 -0
- package/src/api/wallet.ts +1 -1
- package/src/contract/contract_function_interaction.ts +1 -1
- package/src/contract/index.ts +2 -2
- package/src/entrypoint/default_multi_call_entrypoint.ts +2 -1
- package/src/entrypoint/entrypoint.ts +1 -1
- package/src/fee/fee_juice_payment_method_with_claim.ts +1 -1
- package/src/index.ts +7 -35
- package/src/utils/aztec_cheatcodes.ts +75 -0
- package/src/utils/index.ts +19 -11
- package/src/utils/node.ts +2 -0
- package/src/wallet/index.ts +1 -1
- package/dest/account/contract.d.ts +0 -33
- package/dest/account/contract.d.ts.map +0 -1
- package/dest/account/index.d.ts +0 -15
- package/dest/account/index.d.ts.map +0 -1
- package/dest/account/interface.d.ts +0 -30
- package/dest/account/interface.d.ts.map +0 -1
- package/dest/account/wallet.d.ts +0 -10
- package/dest/account/wallet.d.ts.map +0 -1
- package/dest/account_manager/deploy_account_method.d.ts +0 -15
- package/dest/account_manager/deploy_account_method.d.ts.map +0 -1
- package/dest/account_manager/deploy_account_sent_tx.d.ts +0 -29
- package/dest/account_manager/deploy_account_sent_tx.d.ts.map +0 -1
- package/dest/account_manager/index.d.ts +0 -99
- package/dest/account_manager/index.d.ts.map +0 -1
- package/dest/api/abi.d.ts +0 -4
- package/dest/api/abi.d.ts.map +0 -1
- package/dest/api/account.d.ts +0 -4
- package/dest/api/account.d.ts.map +0 -1
- package/dest/api/addresses.d.ts +0 -3
- package/dest/api/addresses.d.ts.map +0 -1
- package/dest/api/deployment.d.ts +0 -4
- package/dest/api/deployment.d.ts.map +0 -1
- package/dest/api/entrypoint.d.ts +0 -2
- package/dest/api/entrypoint.d.ts.map +0 -1
- package/dest/api/eth_address.d.ts +0 -2
- package/dest/api/eth_address.d.ts.map +0 -1
- package/dest/api/ethereum.d.ts +0 -3
- package/dest/api/ethereum.d.ts.map +0 -1
- package/dest/api/ethereum.js +0 -3
- package/dest/api/fee.d.ts +0 -7
- package/dest/api/fee.d.ts.map +0 -1
- package/dest/api/fields.d.ts +0 -2
- package/dest/api/fields.d.ts.map +0 -1
- package/dest/api/interfaces/pxe.d.ts +0 -2
- package/dest/api/interfaces/pxe.d.ts.map +0 -1
- package/dest/api/log_id.d.ts +0 -2
- package/dest/api/log_id.d.ts.map +0 -1
- package/dest/api/tx_hash.d.ts +0 -2
- package/dest/api/tx_hash.d.ts.map +0 -1
- package/dest/api/wallet.d.ts +0 -2
- package/dest/api/wallet.d.ts.map +0 -1
- package/dest/barretenberg-threads.wasm.gz +0 -0
- package/dest/barretenberg.wasm.gz +0 -0
- package/dest/contract/base_contract_interaction.d.ts +0 -82
- package/dest/contract/base_contract_interaction.d.ts.map +0 -1
- package/dest/contract/batch_call.d.ts +0 -27
- package/dest/contract/batch_call.d.ts.map +0 -1
- package/dest/contract/checker.d.ts +0 -11
- package/dest/contract/checker.d.ts.map +0 -1
- package/dest/contract/contract.d.ts +0 -41
- package/dest/contract/contract.d.ts.map +0 -1
- package/dest/contract/contract_base.d.ts +0 -61
- package/dest/contract/contract_base.d.ts.map +0 -1
- package/dest/contract/contract_function_interaction.d.ts +0 -67
- package/dest/contract/contract_function_interaction.d.ts.map +0 -1
- package/dest/contract/deploy_method.d.ts +0 -110
- package/dest/contract/deploy_method.d.ts.map +0 -1
- package/dest/contract/deploy_proven_tx.d.ts +0 -19
- package/dest/contract/deploy_proven_tx.d.ts.map +0 -1
- package/dest/contract/deploy_sent_tx.d.ts +0 -43
- package/dest/contract/deploy_sent_tx.d.ts.map +0 -1
- package/dest/contract/get_gas_limits.d.ts +0 -18
- package/dest/contract/get_gas_limits.d.ts.map +0 -1
- package/dest/contract/index.d.ts +0 -45
- package/dest/contract/index.d.ts.map +0 -1
- package/dest/contract/proven_tx.d.ts +0 -16
- package/dest/contract/proven_tx.d.ts.map +0 -1
- package/dest/contract/sent_tx.d.ts +0 -60
- package/dest/contract/sent_tx.d.ts.map +0 -1
- package/dest/contract/unsafe_contract.d.ts +0 -15
- package/dest/contract/unsafe_contract.d.ts.map +0 -1
- package/dest/deployment/broadcast_function.d.ts +0 -24
- package/dest/deployment/broadcast_function.d.ts.map +0 -1
- package/dest/deployment/contract_deployer.d.ts +0 -27
- package/dest/deployment/contract_deployer.d.ts.map +0 -1
- package/dest/deployment/deploy_instance.d.ts +0 -10
- package/dest/deployment/deploy_instance.d.ts.map +0 -1
- package/dest/deployment/index.d.ts +0 -2
- package/dest/deployment/index.d.ts.map +0 -1
- package/dest/deployment/protocol_contracts.d.ts +0 -7
- package/dest/deployment/protocol_contracts.d.ts.map +0 -1
- package/dest/deployment/register_class.d.ts +0 -6
- package/dest/deployment/register_class.d.ts.map +0 -1
- package/dest/entrypoint/default_entrypoint.d.ts +0 -12
- package/dest/entrypoint/default_entrypoint.d.ts.map +0 -1
- package/dest/entrypoint/default_multi_call_entrypoint.d.ts +0 -15
- package/dest/entrypoint/default_multi_call_entrypoint.d.ts.map +0 -1
- package/dest/entrypoint/entrypoint.d.ts +0 -31
- package/dest/entrypoint/entrypoint.d.ts.map +0 -1
- package/dest/entrypoint/payload.d.ts +0 -125
- package/dest/entrypoint/payload.d.ts.map +0 -1
- package/dest/fee/fee_juice_payment_method.d.ts +0 -14
- package/dest/fee/fee_juice_payment_method.d.ts.map +0 -1
- package/dest/fee/fee_juice_payment_method_with_claim.d.ts +0 -17
- package/dest/fee/fee_juice_payment_method_with_claim.d.ts.map +0 -1
- package/dest/fee/fee_payment_method.d.ts +0 -22
- package/dest/fee/fee_payment_method.d.ts.map +0 -1
- package/dest/fee/no_fee_payment_method.d.ts +0 -13
- package/dest/fee/no_fee_payment_method.d.ts.map +0 -1
- package/dest/fee/private_fee_payment_method.d.ts +0 -51
- package/dest/fee/private_fee_payment_method.d.ts.map +0 -1
- package/dest/fee/public_fee_payment_method.d.ts +0 -41
- package/dest/fee/public_fee_payment_method.d.ts.map +0 -1
- package/dest/index.d.ts +0 -51
- package/dest/index.d.ts.map +0 -1
- package/dest/main.js +0 -2
- package/dest/main.js.LICENSE.txt +0 -25
- package/dest/rpc_clients/index.d.ts +0 -3
- package/dest/rpc_clients/index.d.ts.map +0 -1
- package/dest/rpc_clients/node/index.d.ts +0 -11
- package/dest/rpc_clients/node/index.d.ts.map +0 -1
- package/dest/rpc_clients/pxe_client.d.ts +0 -9
- package/dest/rpc_clients/pxe_client.d.ts.map +0 -1
- package/dest/utils/abi_types.d.ts +0 -26
- package/dest/utils/abi_types.d.ts.map +0 -1
- package/dest/utils/anvil_test_watcher.d.ts +0 -28
- package/dest/utils/anvil_test_watcher.d.ts.map +0 -1
- package/dest/utils/anvil_test_watcher.js +0 -108
- package/dest/utils/authwit.d.ts +0 -59
- package/dest/utils/authwit.d.ts.map +0 -1
- package/dest/utils/chain_monitor.d.ts +0 -21
- package/dest/utils/chain_monitor.d.ts.map +0 -1
- package/dest/utils/chain_monitor.js +0 -58
- package/dest/utils/cheat_codes.d.ts +0 -137
- package/dest/utils/cheat_codes.d.ts.map +0 -1
- package/dest/utils/cheat_codes.js +0 -225
- package/dest/utils/field_compressed_string.d.ts +0 -17
- package/dest/utils/field_compressed_string.d.ts.map +0 -1
- package/dest/utils/index.d.ts +0 -12
- package/dest/utils/index.d.ts.map +0 -1
- package/dest/utils/l1_contracts.d.ts +0 -3
- package/dest/utils/l1_contracts.d.ts.map +0 -1
- package/dest/utils/l1_contracts.js +0 -15
- package/dest/utils/node.d.ts +0 -4
- package/dest/utils/node.d.ts.map +0 -1
- package/dest/utils/portal_manager.d.ts +0 -130
- package/dest/utils/portal_manager.d.ts.map +0 -1
- package/dest/utils/portal_manager.js +0 -265
- package/dest/utils/pub_key.d.ts +0 -8
- package/dest/utils/pub_key.d.ts.map +0 -1
- package/dest/utils/pxe.d.ts +0 -4
- package/dest/utils/pxe.d.ts.map +0 -1
- package/dest/wallet/account_wallet.d.ts +0 -73
- package/dest/wallet/account_wallet.d.ts.map +0 -1
- package/dest/wallet/account_wallet_with_private_key.d.ts +0 -26
- package/dest/wallet/account_wallet_with_private_key.d.ts.map +0 -1
- package/dest/wallet/base_wallet.d.ts +0 -64
- package/dest/wallet/base_wallet.d.ts.map +0 -1
- package/dest/wallet/index.d.ts +0 -17
- package/dest/wallet/index.d.ts.map +0 -1
- package/dest/wallet/signerless_wallet.d.ts +0 -22
- package/dest/wallet/signerless_wallet.d.ts.map +0 -1
- package/src/api/ethereum.ts +0 -2
- /package/src/{utils → api/ethereum}/chain_monitor.ts +0 -0
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import { type FunctionCall, type TxExecutionRequest } from '@aztec/circuit-types';
|
|
2
|
-
import { type Wallet } from '../account/index.js';
|
|
3
|
-
import { BaseContractInteraction, type SendMethodOptions } from './base_contract_interaction.js';
|
|
4
|
-
import type { SimulateMethodOptions } from './contract_function_interaction.js';
|
|
5
|
-
/** A batch of function calls to be sent as a single transaction through a wallet. */
|
|
6
|
-
export declare class BatchCall extends BaseContractInteraction {
|
|
7
|
-
protected calls: FunctionCall[];
|
|
8
|
-
constructor(wallet: Wallet, calls: FunctionCall[]);
|
|
9
|
-
/**
|
|
10
|
-
* Create a transaction execution request that represents this batch, encoded and authenticated by the
|
|
11
|
-
* user's wallet, ready to be simulated.
|
|
12
|
-
* @param opts - An optional object containing additional configuration for the transaction.
|
|
13
|
-
* @returns A Promise that resolves to a transaction instance.
|
|
14
|
-
*/
|
|
15
|
-
create(opts?: SendMethodOptions): Promise<TxExecutionRequest>;
|
|
16
|
-
/**
|
|
17
|
-
* Simulate a transaction and get its return values
|
|
18
|
-
* Differs from prove in a few important ways:
|
|
19
|
-
* 1. It returns the values of the function execution
|
|
20
|
-
* 2. It supports `unconstrained`, `private` and `public` functions
|
|
21
|
-
*
|
|
22
|
-
* @param options - An optional object containing additional configuration for the transaction.
|
|
23
|
-
* @returns The result of the transaction as returned by the contract function.
|
|
24
|
-
*/
|
|
25
|
-
simulate(options?: SimulateMethodOptions): Promise<any>;
|
|
26
|
-
}
|
|
27
|
-
//# sourceMappingURL=batch_call.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"batch_call.d.ts","sourceRoot":"","sources":["../../src/contract/batch_call.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,YAAY,EAAE,KAAK,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAGlF,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,EAAE,uBAAuB,EAAE,KAAK,iBAAiB,EAAE,MAAM,gCAAgC,CAAC;AACjG,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oCAAoC,CAAC;AAEhF,qFAAqF;AACrF,qBAAa,SAAU,SAAQ,uBAAuB;IACxB,SAAS,CAAC,KAAK,EAAE,YAAY,EAAE;gBAA/C,MAAM,EAAE,MAAM,EAAY,KAAK,EAAE,YAAY,EAAE;IAI3D;;;;;OAKG;IACU,MAAM,CAAC,IAAI,CAAC,EAAE,iBAAiB,GAAG,OAAO,CAAC,kBAAkB,CAAC;IAM1E;;;;;;;;OAQG;IACU,QAAQ,CAAC,OAAO,GAAE,qBAA0B,GAAG,OAAO,CAAC,GAAG,CAAC;CA0DzE"}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { type ContractArtifact } from '@aztec/foundation/abi';
|
|
2
|
-
/**
|
|
3
|
-
* Validates the given ContractArtifact object by checking its functions and their parameters.
|
|
4
|
-
* Ensures that the ABI has at least one function, a constructor, valid bytecode, and correct parameter types.
|
|
5
|
-
* Throws an error if any inconsistency is detected during the validation process.
|
|
6
|
-
*
|
|
7
|
-
* @param artifact - The ContractArtifact object to be validated.
|
|
8
|
-
* @returns A boolean value indicating whether the artifact is valid or not.
|
|
9
|
-
*/
|
|
10
|
-
export declare function abiChecker(artifact: ContractArtifact): boolean;
|
|
11
|
-
//# sourceMappingURL=checker.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"checker.d.ts","sourceRoot":"","sources":["../../src/contract/checker.ts"],"names":[],"mappings":"AAAA,OAAO,EAAgC,KAAK,gBAAgB,EAAmB,MAAM,uBAAuB,CAAC;AAQ7G;;;;;;;GAOG;AACH,wBAAgB,UAAU,CAAC,QAAQ,EAAE,gBAAgB,WA8BpD"}
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import { PublicKeys } from '@aztec/circuits.js';
|
|
2
|
-
import { type ContractArtifact } from '@aztec/foundation/abi';
|
|
3
|
-
import { type AztecAddress } from '@aztec/foundation/aztec-address';
|
|
4
|
-
import { type Wallet } from '../account/index.js';
|
|
5
|
-
import { ContractBase } from './contract_base.js';
|
|
6
|
-
import { DeployMethod } from './deploy_method.js';
|
|
7
|
-
/**
|
|
8
|
-
* The Contract class represents a contract and provides utility methods for interacting with it.
|
|
9
|
-
* It enables the creation of ContractFunctionInteraction instances for each function in the contract's ABI,
|
|
10
|
-
* allowing users to call or send transactions to these functions. Additionally, the Contract class can be used
|
|
11
|
-
* to attach the contract instance to a deployed contract on-chain through the PXE, which facilitates
|
|
12
|
-
* interaction with Aztec's privacy protocol.
|
|
13
|
-
*/
|
|
14
|
-
export declare class Contract extends ContractBase {
|
|
15
|
-
/**
|
|
16
|
-
* Creates a contract instance.
|
|
17
|
-
* @param address - The deployed contract's address.
|
|
18
|
-
* @param artifact - Build artifact of the contract.
|
|
19
|
-
* @param wallet - The wallet to use when interacting with the contract.
|
|
20
|
-
* @returns A promise that resolves to a new Contract instance.
|
|
21
|
-
*/
|
|
22
|
-
static at(address: AztecAddress, artifact: ContractArtifact, wallet: Wallet): Promise<Contract>;
|
|
23
|
-
/**
|
|
24
|
-
* Creates a tx to deploy a new instance of a contract.
|
|
25
|
-
* @param wallet - The wallet for executing the deployment.
|
|
26
|
-
* @param artifact - Build artifact of the contract to deploy
|
|
27
|
-
* @param args - Arguments for the constructor.
|
|
28
|
-
* @param constructorName - The name of the constructor function to call.
|
|
29
|
-
*/
|
|
30
|
-
static deploy(wallet: Wallet, artifact: ContractArtifact, args: any[], constructorName?: string): DeployMethod<Contract>;
|
|
31
|
-
/**
|
|
32
|
-
* Creates a tx to deploy a new instance of a contract using the specified public keys hash to derive the address.
|
|
33
|
-
* @param publicKeys - Hash of public keys to use for deriving the address.
|
|
34
|
-
* @param wallet - The wallet for executing the deployment.
|
|
35
|
-
* @param artifact - Build artifact of the contract.
|
|
36
|
-
* @param args - Arguments for the constructor.
|
|
37
|
-
* @param constructorName - The name of the constructor function to call.
|
|
38
|
-
*/
|
|
39
|
-
static deployWithPublicKeys(publicKeys: PublicKeys, wallet: Wallet, artifact: ContractArtifact, args: any[], constructorName?: string): DeployMethod<Contract>;
|
|
40
|
-
}
|
|
41
|
-
//# sourceMappingURL=contract.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"contract.d.ts","sourceRoot":"","sources":["../../src/contract/contract.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAChD,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AAC9D,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,iCAAiC,CAAC;AAEpE,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAElD;;;;;;GAMG;AACH,qBAAa,QAAS,SAAQ,YAAY;IACxC;;;;;;OAMG;WACiB,EAAE,CAAC,OAAO,EAAE,YAAY,EAAE,QAAQ,EAAE,gBAAgB,EAAE,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,QAAQ,CAAC;IAQ5G;;;;;;OAMG;WACW,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE,gBAAgB,EAAE,IAAI,EAAE,GAAG,EAAE,EAAE,eAAe,CAAC,EAAE,MAAM;IAKtG;;;;;;;OAOG;WACW,oBAAoB,CAChC,UAAU,EAAE,UAAU,EACtB,MAAM,EAAE,MAAM,EACd,QAAQ,EAAE,gBAAgB,EAC1B,IAAI,EAAE,GAAG,EAAE,EACX,eAAe,CAAC,EAAE,MAAM;CAK3B"}
|
|
@@ -1,61 +0,0 @@
|
|
|
1
|
-
import { type ContractInstanceWithAddress } from '@aztec/circuits.js';
|
|
2
|
-
import { type ContractArtifact, type ContractNote, type FieldLayout, FunctionSelector } from '@aztec/foundation/abi';
|
|
3
|
-
import { type Wallet } from '../account/index.js';
|
|
4
|
-
import { ContractFunctionInteraction } from './contract_function_interaction.js';
|
|
5
|
-
/**
|
|
6
|
-
* Type representing a contract method that returns a ContractFunctionInteraction instance
|
|
7
|
-
* and has a readonly 'selector' property of type Buffer. Takes any number of arguments.
|
|
8
|
-
*/
|
|
9
|
-
export type ContractMethod = ((...args: any[]) => ContractFunctionInteraction) & {
|
|
10
|
-
/**
|
|
11
|
-
* The unique identifier for a contract function in bytecode.
|
|
12
|
-
*/
|
|
13
|
-
selector: () => Promise<FunctionSelector>;
|
|
14
|
-
};
|
|
15
|
-
/**
|
|
16
|
-
* Type representing the storage layout of a contract.
|
|
17
|
-
*/
|
|
18
|
-
export type ContractStorageLayout<T extends string> = {
|
|
19
|
-
[K in T]: FieldLayout;
|
|
20
|
-
};
|
|
21
|
-
/**
|
|
22
|
-
* Type representing the notes used in a contract.
|
|
23
|
-
*/
|
|
24
|
-
export type ContractNotes<T extends string> = {
|
|
25
|
-
[K in T]: ContractNote;
|
|
26
|
-
};
|
|
27
|
-
/**
|
|
28
|
-
* Abstract implementation of a contract extended by the Contract class and generated contract types.
|
|
29
|
-
*/
|
|
30
|
-
export declare class ContractBase {
|
|
31
|
-
/** The deployed contract instance definition. */
|
|
32
|
-
readonly instance: ContractInstanceWithAddress;
|
|
33
|
-
/** The Application Binary Interface for the contract. */
|
|
34
|
-
readonly artifact: ContractArtifact;
|
|
35
|
-
/** The wallet used for interacting with this contract. */
|
|
36
|
-
wallet: Wallet;
|
|
37
|
-
/**
|
|
38
|
-
* An object containing contract methods mapped to their respective names.
|
|
39
|
-
*/
|
|
40
|
-
methods: {
|
|
41
|
-
[name: string]: ContractMethod;
|
|
42
|
-
};
|
|
43
|
-
protected constructor(
|
|
44
|
-
/** The deployed contract instance definition. */
|
|
45
|
-
instance: ContractInstanceWithAddress,
|
|
46
|
-
/** The Application Binary Interface for the contract. */
|
|
47
|
-
artifact: ContractArtifact,
|
|
48
|
-
/** The wallet used for interacting with this contract. */
|
|
49
|
-
wallet: Wallet);
|
|
50
|
-
/** Address of the contract. */
|
|
51
|
-
get address(): import("@aztec/circuits.js").AztecAddress;
|
|
52
|
-
/** Partial address of the contract. */
|
|
53
|
-
get partialAddress(): Promise<import("@aztec/circuits.js").Fr>;
|
|
54
|
-
/**
|
|
55
|
-
* Creates a new instance of the contract wrapper attached to a different wallet.
|
|
56
|
-
* @param wallet - Wallet to use for sending txs.
|
|
57
|
-
* @returns A new contract instance.
|
|
58
|
-
*/
|
|
59
|
-
withWallet(wallet: Wallet): this;
|
|
60
|
-
}
|
|
61
|
-
//# sourceMappingURL=contract_base.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"contract_base.d.ts","sourceRoot":"","sources":["../../src/contract/contract_base.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,2BAA2B,EAAyB,MAAM,oBAAoB,CAAC;AAC7F,OAAO,EACL,KAAK,gBAAgB,EACrB,KAAK,YAAY,EACjB,KAAK,WAAW,EAEhB,gBAAgB,EACjB,MAAM,uBAAuB,CAAC;AAE/B,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,EAAE,2BAA2B,EAAE,MAAM,oCAAoC,CAAC;AAEjF;;;GAGG;AACH,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,2BAA2B,CAAC,GAAG;IAC/E;;OAEG;IACH,QAAQ,EAAE,MAAM,OAAO,CAAC,gBAAgB,CAAC,CAAC;CAC3C,CAAC;AAEF;;GAEG;AACH,MAAM,MAAM,qBAAqB,CAAC,CAAC,SAAS,MAAM,IAAI;KACnD,CAAC,IAAI,CAAC,GAAG,WAAW;CACtB,CAAC;AAEF;;GAEG;AACH,MAAM,MAAM,aAAa,CAAC,CAAC,SAAS,MAAM,IAAI;KAC3C,CAAC,IAAI,CAAC,GAAG,YAAY;CACvB,CAAC;AAEF;;GAEG;AACH,qBAAa,YAAY;IAOrB,iDAAiD;aACjC,QAAQ,EAAE,2BAA2B;IACrD,yDAAyD;aACzC,QAAQ,EAAE,gBAAgB;IAC1C,0DAA0D;IACnD,MAAM,EAAE,MAAM;IAXvB;;OAEG;IACI,OAAO,EAAE;QAAE,CAAC,IAAI,EAAE,MAAM,GAAG,cAAc,CAAA;KAAE,CAAM;IAExD,SAAS;IACP,iDAAiD;IACjC,QAAQ,EAAE,2BAA2B;IACrD,yDAAyD;IACzC,QAAQ,EAAE,gBAAgB;IAC1C,0DAA0D;IACnD,MAAM,EAAE,MAAM;IAmBvB,+BAA+B;IAC/B,IAAW,OAAO,8CAEjB;IAED,uCAAuC;IACvC,IAAW,cAAc,6CAExB;IAED;;;;OAIG;IACI,UAAU,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI;CAGxC"}
|
|
@@ -1,67 +0,0 @@
|
|
|
1
|
-
import type { FunctionCall, PrivateKernelProverProfileResult, TxExecutionRequest } from '@aztec/circuit-types';
|
|
2
|
-
import { type AztecAddress, type GasSettings } from '@aztec/circuits.js';
|
|
3
|
-
import { type FunctionAbi } from '@aztec/foundation/abi';
|
|
4
|
-
import { type Wallet } from '../account/wallet.js';
|
|
5
|
-
import { BaseContractInteraction, type SendMethodOptions } from './base_contract_interaction.js';
|
|
6
|
-
export { SendMethodOptions };
|
|
7
|
-
/**
|
|
8
|
-
* Represents the options for simulating a contract function interaction.
|
|
9
|
-
* Allows specifying the address from which the view method should be called.
|
|
10
|
-
* Disregarded for simulation of public functions
|
|
11
|
-
*/
|
|
12
|
-
export type SimulateMethodOptions = {
|
|
13
|
-
/** The sender's Aztec address. */
|
|
14
|
-
from?: AztecAddress;
|
|
15
|
-
/** Gas settings for the simulation. */
|
|
16
|
-
gasSettings?: GasSettings;
|
|
17
|
-
/** Simulate without checking for the validity of the resulting transaction, e.g. whether it emits any existing nullifiers. */
|
|
18
|
-
skipTxValidation?: boolean;
|
|
19
|
-
};
|
|
20
|
-
/**
|
|
21
|
-
* The result of a profile() call.
|
|
22
|
-
*/
|
|
23
|
-
export type ProfileResult = PrivateKernelProverProfileResult & {
|
|
24
|
-
/** The result of the transaction as returned by the contract function. */
|
|
25
|
-
returnValues: any;
|
|
26
|
-
};
|
|
27
|
-
/**
|
|
28
|
-
* This is the class that is returned when calling e.g. `contract.methods.myMethod(arg0, arg1)`.
|
|
29
|
-
* It contains available interactions one can call on a method, including view.
|
|
30
|
-
*/
|
|
31
|
-
export declare class ContractFunctionInteraction extends BaseContractInteraction {
|
|
32
|
-
protected contractAddress: AztecAddress;
|
|
33
|
-
protected functionDao: FunctionAbi;
|
|
34
|
-
protected args: any[];
|
|
35
|
-
constructor(wallet: Wallet, contractAddress: AztecAddress, functionDao: FunctionAbi, args: any[]);
|
|
36
|
-
/**
|
|
37
|
-
* Create a transaction execution request that represents this call, encoded and authenticated by the
|
|
38
|
-
* user's wallet, ready to be simulated.
|
|
39
|
-
* @param opts - An optional object containing additional configuration for the transaction.
|
|
40
|
-
* @returns A Promise that resolves to a transaction instance.
|
|
41
|
-
*/
|
|
42
|
-
create(opts?: SendMethodOptions): Promise<TxExecutionRequest>;
|
|
43
|
-
/**
|
|
44
|
-
* Returns an execution request that represents this operation. Useful as a building
|
|
45
|
-
* block for constructing batch requests.
|
|
46
|
-
* @returns An execution request wrapped in promise.
|
|
47
|
-
*/
|
|
48
|
-
request(): Promise<FunctionCall>;
|
|
49
|
-
/**
|
|
50
|
-
* Simulate a transaction and get its return values
|
|
51
|
-
* Differs from prove in a few important ways:
|
|
52
|
-
* 1. It returns the values of the function execution
|
|
53
|
-
* 2. It supports `unconstrained`, `private` and `public` functions
|
|
54
|
-
*
|
|
55
|
-
* @param options - An optional object containing additional configuration for the transaction.
|
|
56
|
-
* @returns The result of the transaction as returned by the contract function.
|
|
57
|
-
*/
|
|
58
|
-
simulate(options?: SimulateMethodOptions): Promise<any>;
|
|
59
|
-
/**
|
|
60
|
-
* Simulate a transaction and profile the gate count for each function in the transaction.
|
|
61
|
-
* @param options - Same options as `simulate`.
|
|
62
|
-
*
|
|
63
|
-
* @returns An object containing the function return value and profile result.
|
|
64
|
-
*/
|
|
65
|
-
simulateWithProfile(options?: SimulateMethodOptions): Promise<ProfileResult>;
|
|
66
|
-
}
|
|
67
|
-
//# sourceMappingURL=contract_function_interaction.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"contract_function_interaction.d.ts","sourceRoot":"","sources":["../../src/contract/contract_function_interaction.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,gCAAgC,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC/G,OAAO,EAAE,KAAK,YAAY,EAAE,KAAK,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACzE,OAAO,EACL,KAAK,WAAW,EAKjB,MAAM,uBAAuB,CAAC;AAE/B,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,sBAAsB,CAAC;AACnD,OAAO,EAAE,uBAAuB,EAAE,KAAK,iBAAiB,EAAE,MAAM,gCAAgC,CAAC;AAEjG,OAAO,EAAE,iBAAiB,EAAE,CAAC;AAE7B;;;;GAIG;AACH,MAAM,MAAM,qBAAqB,GAAG;IAClC,kCAAkC;IAClC,IAAI,CAAC,EAAE,YAAY,CAAC;IACpB,uCAAuC;IACvC,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,8HAA8H;IAC9H,gBAAgB,CAAC,EAAE,OAAO,CAAC;CAC5B,CAAC;AAEF;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG,gCAAgC,GAAG;IAC7D,0EAA0E;IAC1E,YAAY,EAAE,GAAG,CAAC;CACnB,CAAC;AAEF;;;GAGG;AACH,qBAAa,2BAA4B,SAAQ,uBAAuB;IAGpE,SAAS,CAAC,eAAe,EAAE,YAAY;IACvC,SAAS,CAAC,WAAW,EAAE,WAAW;IAClC,SAAS,CAAC,IAAI,EAAE,GAAG,EAAE;gBAHrB,MAAM,EAAE,MAAM,EACJ,eAAe,EAAE,YAAY,EAC7B,WAAW,EAAE,WAAW,EACxB,IAAI,EAAE,GAAG,EAAE;IASvB;;;;;OAKG;IACU,MAAM,CAAC,IAAI,GAAE,iBAAsB,GAAG,OAAO,CAAC,kBAAkB,CAAC;IAY9E;;;;OAIG;IACU,OAAO,IAAI,OAAO,CAAC,YAAY,CAAC;IAe7C;;;;;;;;OAQG;IACU,QAAQ,CAAC,OAAO,GAAE,qBAA0B,GAAG,OAAO,CAAC,GAAG,CAAC;IA2BxE;;;;;OAKG;IACU,mBAAmB,CAAC,OAAO,GAAE,qBAA0B,GAAG,OAAO,CAAC,aAAa,CAAC;CA0B9F"}
|
|
@@ -1,110 +0,0 @@
|
|
|
1
|
-
import { type TxExecutionRequest } from '@aztec/circuit-types';
|
|
2
|
-
import { AztecAddress, type ContractInstanceWithAddress, type PublicKeys } from '@aztec/circuits.js';
|
|
3
|
-
import { type ContractArtifact, type FunctionArtifact } from '@aztec/foundation/abi';
|
|
4
|
-
import { type Fr } from '@aztec/foundation/fields';
|
|
5
|
-
import { type Wallet } from '../account/index.js';
|
|
6
|
-
import { type ExecutionRequestInit } from '../entrypoint/entrypoint.js';
|
|
7
|
-
import { BaseContractInteraction, type SendMethodOptions } from './base_contract_interaction.js';
|
|
8
|
-
import { type Contract } from './contract.js';
|
|
9
|
-
import { type ContractBase } from './contract_base.js';
|
|
10
|
-
import { DeployProvenTx } from './deploy_proven_tx.js';
|
|
11
|
-
import { DeploySentTx } from './deploy_sent_tx.js';
|
|
12
|
-
/**
|
|
13
|
-
* Options for deploying a contract on the Aztec network.
|
|
14
|
-
* Allows specifying a contract address salt, and additional send method options.
|
|
15
|
-
*/
|
|
16
|
-
export type DeployOptions = {
|
|
17
|
-
/** An optional salt value used to deterministically calculate the contract address. */
|
|
18
|
-
contractAddressSalt?: Fr;
|
|
19
|
-
/** Set to true to *not* include the sender in the address computation. */
|
|
20
|
-
universalDeploy?: boolean;
|
|
21
|
-
/** Skip contract class registration. */
|
|
22
|
-
skipClassRegistration?: boolean;
|
|
23
|
-
/** Skip public deployment, instead just privately initialize the contract. */
|
|
24
|
-
skipPublicDeployment?: boolean;
|
|
25
|
-
/** Skip contract initialization. */
|
|
26
|
-
skipInitialization?: boolean;
|
|
27
|
-
} & SendMethodOptions;
|
|
28
|
-
/**
|
|
29
|
-
* Contract interaction for deployment. Handles class registration, public instance deployment,
|
|
30
|
-
* and initialization of the contract. Extends the BaseContractInteraction class.
|
|
31
|
-
*/
|
|
32
|
-
export declare class DeployMethod<TContract extends ContractBase = Contract> extends BaseContractInteraction {
|
|
33
|
-
private publicKeys;
|
|
34
|
-
private artifact;
|
|
35
|
-
private postDeployCtor;
|
|
36
|
-
private args;
|
|
37
|
-
/** The contract instance to be deployed. */
|
|
38
|
-
private instance?;
|
|
39
|
-
/** Constructor function to call. */
|
|
40
|
-
private constructorArtifact;
|
|
41
|
-
constructor(publicKeys: PublicKeys, wallet: Wallet, artifact: ContractArtifact, postDeployCtor: (address: AztecAddress, wallet: Wallet) => Promise<TContract>, args?: any[], constructorNameOrArtifact?: string | FunctionArtifact);
|
|
42
|
-
/**
|
|
43
|
-
* Create a contract deployment transaction, given the deployment options.
|
|
44
|
-
* This function internally calls `request()` and `sign()` methods to prepare
|
|
45
|
-
* the transaction for deployment. The resulting signed transaction can be
|
|
46
|
-
* later sent using the `send()` method.
|
|
47
|
-
*
|
|
48
|
-
* @param options - An object containing optional deployment settings, contractAddressSalt, and from.
|
|
49
|
-
* @returns A Promise resolving to an object containing the signed transaction data and other relevant information.
|
|
50
|
-
*/
|
|
51
|
-
create(options?: DeployOptions): Promise<TxExecutionRequest>;
|
|
52
|
-
/**
|
|
53
|
-
* Returns an array of function calls that represent this operation. Useful as a building
|
|
54
|
-
* block for constructing batch requests.
|
|
55
|
-
* @param options - Deployment options.
|
|
56
|
-
* @returns An array of function calls.
|
|
57
|
-
* @remarks This method does not have the same return type as the `request` in the ContractInteraction object,
|
|
58
|
-
* it returns a promise for an array instead of a function call directly.
|
|
59
|
-
*/
|
|
60
|
-
request(options?: DeployOptions): Promise<ExecutionRequestInit>;
|
|
61
|
-
/**
|
|
62
|
-
* Register this contract in the PXE and returns the Contract object.
|
|
63
|
-
* @param options - Deployment options.
|
|
64
|
-
*/
|
|
65
|
-
register(options?: DeployOptions): Promise<TContract>;
|
|
66
|
-
/**
|
|
67
|
-
* Returns calls for registration of the class and deployment of the instance, depending on the provided options.
|
|
68
|
-
* @param options - Deployment options.
|
|
69
|
-
* @returns A function call array with potentially requests to the class registerer and instance deployer.
|
|
70
|
-
*/
|
|
71
|
-
protected getDeploymentFunctionCalls(options?: DeployOptions): Promise<Pick<ExecutionRequestInit, 'calls' | 'authWitnesses' | 'hashedArguments'>>;
|
|
72
|
-
/**
|
|
73
|
-
* Returns the calls necessary to initialize the contract.
|
|
74
|
-
* @param options - Deployment options.
|
|
75
|
-
* @returns - An array of function calls.
|
|
76
|
-
*/
|
|
77
|
-
protected getInitializeFunctionCalls(options: DeployOptions): Promise<Pick<ExecutionRequestInit, 'calls' | 'authWitnesses' | 'hashedArguments'>>;
|
|
78
|
-
/**
|
|
79
|
-
* Send the contract deployment transaction using the provided options.
|
|
80
|
-
* This function extends the 'send' method from the ContractFunctionInteraction class,
|
|
81
|
-
* allowing us to send a transaction specifically for contract deployment.
|
|
82
|
-
*
|
|
83
|
-
* @param options - An object containing various deployment options such as contractAddressSalt and from.
|
|
84
|
-
* @returns A SentTx object that returns the receipt and the deployed contract instance.
|
|
85
|
-
*/
|
|
86
|
-
send(options?: DeployOptions): DeploySentTx<TContract>;
|
|
87
|
-
/**
|
|
88
|
-
* Builds the contract instance to be deployed and returns it.
|
|
89
|
-
*
|
|
90
|
-
* @param options - An object containing various deployment options.
|
|
91
|
-
* @returns An instance object.
|
|
92
|
-
*/
|
|
93
|
-
getInstance(options?: DeployOptions): Promise<ContractInstanceWithAddress>;
|
|
94
|
-
/**
|
|
95
|
-
* Prove the request.
|
|
96
|
-
* @param options - Deployment options.
|
|
97
|
-
* @returns The proven tx.
|
|
98
|
-
*/
|
|
99
|
-
prove(options: DeployOptions): Promise<DeployProvenTx<TContract>>;
|
|
100
|
-
/**
|
|
101
|
-
* Estimates gas cost for this deployment operation.
|
|
102
|
-
* @param options - Options.
|
|
103
|
-
*/
|
|
104
|
-
estimateGas(options?: Omit<DeployOptions, 'estimateGas' | 'skipPublicSimulation'>): Promise<Pick<import("@aztec/circuits.js").GasSettings, "gasLimits" | "teardownGasLimits">>;
|
|
105
|
-
/** Return this deployment address. */
|
|
106
|
-
get address(): AztecAddress | undefined;
|
|
107
|
-
/** Returns the partial address for this deployment. */
|
|
108
|
-
get partialAddress(): Promise<Fr> | undefined;
|
|
109
|
-
}
|
|
110
|
-
//# sourceMappingURL=deploy_method.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"deploy_method.d.ts","sourceRoot":"","sources":["../../src/contract/deploy_method.ts"],"names":[],"mappings":"AAAA,OAAO,EAAqB,KAAK,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAClF,OAAO,EACL,YAAY,EACZ,KAAK,2BAA2B,EAChC,KAAK,UAAU,EAIhB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,KAAK,gBAAgB,EAAE,KAAK,gBAAgB,EAAkB,MAAM,uBAAuB,CAAC;AACrG,OAAO,EAAE,KAAK,EAAE,EAAE,MAAM,0BAA0B,CAAC;AAEnD,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAGlD,OAAO,EAAE,KAAK,oBAAoB,EAAE,MAAM,6BAA6B,CAAC;AACxE,OAAO,EAAE,uBAAuB,EAAE,KAAK,iBAAiB,EAAE,MAAM,gCAAgC,CAAC;AACjG,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,eAAe,CAAC;AAC9C,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAEvD,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAEnD;;;GAGG;AAEH,MAAM,MAAM,aAAa,GAAG;IAC1B,uFAAuF;IACvF,mBAAmB,CAAC,EAAE,EAAE,CAAC;IACzB,0EAA0E;IAC1E,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,wCAAwC;IACxC,qBAAqB,CAAC,EAAE,OAAO,CAAC;IAChC,8EAA8E;IAC9E,oBAAoB,CAAC,EAAE,OAAO,CAAC;IAC/B,oCAAoC;IACpC,kBAAkB,CAAC,EAAE,OAAO,CAAC;CAC9B,GAAG,iBAAiB,CAAC;AAItB;;;GAGG;AACH,qBAAa,YAAY,CAAC,SAAS,SAAS,YAAY,GAAG,QAAQ,CAAE,SAAQ,uBAAuB;IAQhG,OAAO,CAAC,UAAU;IAElB,OAAO,CAAC,QAAQ;IAChB,OAAO,CAAC,cAAc;IACtB,OAAO,CAAC,IAAI;IAXd,4CAA4C;IAC5C,OAAO,CAAC,QAAQ,CAAC,CAA0C;IAE3D,oCAAoC;IACpC,OAAO,CAAC,mBAAmB,CAA+B;gBAGhD,UAAU,EAAE,UAAU,EAC9B,MAAM,EAAE,MAAM,EACN,QAAQ,EAAE,gBAAgB,EAC1B,cAAc,EAAE,CAAC,OAAO,EAAE,YAAY,EAAE,MAAM,EAAE,MAAM,KAAK,OAAO,CAAC,SAAS,CAAC,EAC7E,IAAI,GAAE,GAAG,EAAO,EACxB,yBAAyB,CAAC,EAAE,MAAM,GAAG,gBAAgB;IAMvD;;;;;;;;OAQG;IACU,MAAM,CAAC,OAAO,GAAE,aAAkB,GAAG,OAAO,CAAC,kBAAkB,CAAC;IAO7E;;;;;;;OAOG;IACU,OAAO,CAAC,OAAO,GAAE,aAAkB,GAAG,OAAO,CAAC,oBAAoB,CAAC;IA+BhF;;;OAGG;IACU,QAAQ,CAAC,OAAO,GAAE,aAAkB,GAAG,OAAO,CAAC,SAAS,CAAC;IAMtE;;;;OAIG;cACa,0BAA0B,CACxC,OAAO,GAAE,aAAkB,GAC1B,OAAO,CAAC,IAAI,CAAC,oBAAoB,EAAE,OAAO,GAAG,eAAe,GAAG,iBAAiB,CAAC,CAAC;IAuCrF;;;;OAIG;cACa,0BAA0B,CACxC,OAAO,EAAE,aAAa,GACrB,OAAO,CAAC,IAAI,CAAC,oBAAoB,EAAE,OAAO,GAAG,eAAe,GAAG,iBAAiB,CAAC,CAAC;IAerF;;;;;;;OAOG;IACa,IAAI,CAAC,OAAO,GAAE,aAAkB,GAAG,YAAY,CAAC,SAAS,CAAC;IAM1E;;;;;OAKG;IACU,WAAW,CAAC,OAAO,GAAE,aAAkB,GAAG,OAAO,CAAC,2BAA2B,CAAC;IAa3F;;;;OAIG;IACmB,KAAK,CAAC,OAAO,EAAE,aAAa,GAAG,OAAO,CAAC,cAAc,CAAC,SAAS,CAAC,CAAC;IAOvF;;;OAGG;IACa,WAAW,CAAC,OAAO,CAAC,EAAE,IAAI,CAAC,aAAa,EAAE,aAAa,GAAG,sBAAsB,CAAC;IAIjG,sCAAsC;IACtC,IAAW,OAAO,6BAEjB;IAED,uDAAuD;IACvD,IAAW,cAAc,4BAExB;CACF"}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { type PXE, type Tx } from '@aztec/circuit-types';
|
|
2
|
-
import { type AztecAddress, type ContractInstanceWithAddress } from '@aztec/circuits.js';
|
|
3
|
-
import { type Wallet } from '../account/index.js';
|
|
4
|
-
import { type Contract } from './contract.js';
|
|
5
|
-
import { DeploySentTx } from './deploy_sent_tx.js';
|
|
6
|
-
import { ProvenTx } from './proven_tx.js';
|
|
7
|
-
/**
|
|
8
|
-
* A proven transaction that can be sent to the network. Returned by the `prove` method of a contract deployment.
|
|
9
|
-
*/
|
|
10
|
-
export declare class DeployProvenTx<TContract extends Contract = Contract> extends ProvenTx {
|
|
11
|
-
private postDeployCtor;
|
|
12
|
-
private instanceGetter;
|
|
13
|
-
constructor(wallet: PXE | Wallet, tx: Tx, postDeployCtor: (address: AztecAddress, wallet: Wallet) => Promise<TContract>, instanceGetter: () => Promise<ContractInstanceWithAddress>);
|
|
14
|
-
/**
|
|
15
|
-
* Sends the transaction to the network via the provided wallet.
|
|
16
|
-
*/
|
|
17
|
-
send(): DeploySentTx<TContract>;
|
|
18
|
-
}
|
|
19
|
-
//# sourceMappingURL=deploy_proven_tx.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"deploy_proven_tx.d.ts","sourceRoot":"","sources":["../../src/contract/deploy_proven_tx.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,GAAG,EAAE,KAAK,EAAE,EAAE,MAAM,sBAAsB,CAAC;AACzD,OAAO,EAAE,KAAK,YAAY,EAAE,KAAK,2BAA2B,EAAE,MAAM,oBAAoB,CAAC;AAEzF,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,eAAe,CAAC;AAC9C,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAE1C;;GAEG;AACH,qBAAa,cAAc,CAAC,SAAS,SAAS,QAAQ,GAAG,QAAQ,CAAE,SAAQ,QAAQ;IAI/E,OAAO,CAAC,cAAc;IACtB,OAAO,CAAC,cAAc;gBAHtB,MAAM,EAAE,GAAG,GAAG,MAAM,EACpB,EAAE,EAAE,EAAE,EACE,cAAc,EAAE,CAAC,OAAO,EAAE,YAAY,EAAE,MAAM,EAAE,MAAM,KAAK,OAAO,CAAC,SAAS,CAAC,EAC7E,cAAc,EAAE,MAAM,OAAO,CAAC,2BAA2B,CAAC;IAKpE;;OAEG;IACa,IAAI,IAAI,YAAY,CAAC,SAAS,CAAC;CAOhD"}
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
import { type PXE, type TxHash, type TxReceipt } from '@aztec/circuit-types';
|
|
2
|
-
import { type AztecAddress, type ContractInstanceWithAddress } from '@aztec/circuits.js';
|
|
3
|
-
import { type FieldsOf } from '@aztec/foundation/types';
|
|
4
|
-
import { type Wallet } from '../account/index.js';
|
|
5
|
-
import { type Contract } from './contract.js';
|
|
6
|
-
import { type ContractBase } from './contract_base.js';
|
|
7
|
-
import { SentTx, type WaitOpts } from './sent_tx.js';
|
|
8
|
-
/** Options related to waiting for a deployment tx. */
|
|
9
|
-
export type DeployedWaitOpts = WaitOpts & {
|
|
10
|
-
/** Wallet to use for creating a contract instance. Uses the one set in the deployer constructor if not set. */
|
|
11
|
-
wallet?: Wallet;
|
|
12
|
-
};
|
|
13
|
-
/** Extends a transaction receipt with a contract instance that represents the newly deployed contract. */
|
|
14
|
-
export type DeployTxReceipt<TContract extends ContractBase = Contract> = FieldsOf<TxReceipt> & {
|
|
15
|
-
/** Instance of the newly deployed contract. */
|
|
16
|
-
contract: TContract;
|
|
17
|
-
};
|
|
18
|
-
/**
|
|
19
|
-
* A contract deployment transaction sent to the network, extending SentTx with methods to create a contract instance.
|
|
20
|
-
*/
|
|
21
|
-
export declare class DeploySentTx<TContract extends Contract = Contract> extends SentTx {
|
|
22
|
-
private postDeployCtor;
|
|
23
|
-
/** A getter for the deployed contract instance */
|
|
24
|
-
instanceGetter: () => Promise<ContractInstanceWithAddress>;
|
|
25
|
-
private log;
|
|
26
|
-
constructor(wallet: PXE | Wallet, txHashPromise: Promise<TxHash>, postDeployCtor: (address: AztecAddress, wallet: Wallet) => Promise<TContract>,
|
|
27
|
-
/** A getter for the deployed contract instance */
|
|
28
|
-
instanceGetter: () => Promise<ContractInstanceWithAddress>);
|
|
29
|
-
/**
|
|
30
|
-
* Awaits for the tx to be mined and returns the contract instance. Throws if tx is not mined.
|
|
31
|
-
* @param opts - Options for configuring the waiting for the tx to be mined.
|
|
32
|
-
* @returns The deployed contract instance.
|
|
33
|
-
*/
|
|
34
|
-
deployed(opts?: DeployedWaitOpts): Promise<TContract>;
|
|
35
|
-
/**
|
|
36
|
-
* Awaits for the tx to be mined and returns the receipt along with a contract instance. Throws if tx is not mined.
|
|
37
|
-
* @param opts - Options for configuring the waiting for the tx to be mined.
|
|
38
|
-
* @returns The transaction receipt with the deployed contract instance.
|
|
39
|
-
*/
|
|
40
|
-
wait(opts?: DeployedWaitOpts): Promise<DeployTxReceipt<TContract>>;
|
|
41
|
-
protected getContractObject(wallet?: Wallet): Promise<TContract>;
|
|
42
|
-
}
|
|
43
|
-
//# sourceMappingURL=deploy_sent_tx.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"deploy_sent_tx.d.ts","sourceRoot":"","sources":["../../src/contract/deploy_sent_tx.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,GAAG,EAAE,KAAK,MAAM,EAAE,KAAK,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAC7E,OAAO,EAAE,KAAK,YAAY,EAAE,KAAK,2BAA2B,EAAE,MAAM,oBAAoB,CAAC;AAEzF,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,yBAAyB,CAAC;AAExD,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,eAAe,CAAC;AAC9C,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,oBAAoB,CAAC;AACvD,OAAO,EAAE,MAAM,EAAE,KAAK,QAAQ,EAAE,MAAM,cAAc,CAAC;AAErD,sDAAsD;AACtD,MAAM,MAAM,gBAAgB,GAAG,QAAQ,GAAG;IACxC,+GAA+G;IAC/G,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF,0GAA0G;AAC1G,MAAM,MAAM,eAAe,CAAC,SAAS,SAAS,YAAY,GAAG,QAAQ,IAAI,QAAQ,CAAC,SAAS,CAAC,GAAG;IAC7F,+CAA+C;IAC/C,QAAQ,EAAE,SAAS,CAAC;CACrB,CAAC;AAEF;;GAEG;AACH,qBAAa,YAAY,CAAC,SAAS,SAAS,QAAQ,GAAG,QAAQ,CAAE,SAAQ,MAAM;IAM3E,OAAO,CAAC,cAAc;IACtB,kDAAkD;IAC3C,cAAc,EAAE,MAAM,OAAO,CAAC,2BAA2B,CAAC;IAPnE,OAAO,CAAC,GAAG,CAA0C;gBAGnD,MAAM,EAAE,GAAG,GAAG,MAAM,EACpB,aAAa,EAAE,OAAO,CAAC,MAAM,CAAC,EACtB,cAAc,EAAE,CAAC,OAAO,EAAE,YAAY,EAAE,MAAM,EAAE,MAAM,KAAK,OAAO,CAAC,SAAS,CAAC;IACrF,kDAAkD;IAC3C,cAAc,EAAE,MAAM,OAAO,CAAC,2BAA2B,CAAC;IAKnE;;;;OAIG;IACU,QAAQ,CAAC,IAAI,CAAC,EAAE,gBAAgB,GAAG,OAAO,CAAC,SAAS,CAAC;IAOlE;;;;OAIG;IACmB,IAAI,CAAC,IAAI,CAAC,EAAE,gBAAgB,GAAG,OAAO,CAAC,eAAe,CAAC,SAAS,CAAC,CAAC;cAMxE,iBAAiB,CAAC,MAAM,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,SAAS,CAAC;CASvE"}
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { type TxSimulationResult } from '@aztec/circuit-types';
|
|
2
|
-
import { type Gas } from '@aztec/circuits.js';
|
|
3
|
-
/**
|
|
4
|
-
* Returns suggested total and teardown gas limits for a simulated tx.
|
|
5
|
-
* Note that public gas usage is only accounted for if the publicOutput is present.
|
|
6
|
-
* @param pad - Percentage to pad the suggested gas limits by, (as decimal, e.g., 0.10 for 10%).
|
|
7
|
-
*/
|
|
8
|
-
export declare function getGasLimits(simulationResult: TxSimulationResult, pad?: number): {
|
|
9
|
-
/**
|
|
10
|
-
* Total gas used across private and public
|
|
11
|
-
*/
|
|
12
|
-
totalGas: Gas;
|
|
13
|
-
/**
|
|
14
|
-
* Teardown gas used
|
|
15
|
-
*/
|
|
16
|
-
teardownGas: Gas;
|
|
17
|
-
};
|
|
18
|
-
//# sourceMappingURL=get_gas_limits.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"get_gas_limits.d.ts","sourceRoot":"","sources":["../../src/contract/get_gas_limits.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC/D,OAAO,EAAE,KAAK,GAAG,EAAE,MAAM,oBAAoB,CAAC;AAE9C;;;;GAIG;AACH,wBAAgB,YAAY,CAC1B,gBAAgB,EAAE,kBAAkB,EACpC,GAAG,SAAM,GACR;IACD;;OAEG;IACH,QAAQ,EAAE,GAAG,CAAC;IACd;;OAEG;IACH,WAAW,EAAE,GAAG,CAAC;CAClB,CAKA"}
|
package/dest/contract/index.d.ts
DELETED
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* The `contract` module provides utilities for deploying and interacting with contracts, based on a
|
|
3
|
-
* `Wallet` instance and a compiled artifact. Refer to the {@link account} module for how to obtain a valid
|
|
4
|
-
* `Wallet` instance, and to the {@link https://docs.aztec.network/developers/contracts/compiling | Compiling contracts}
|
|
5
|
-
* section of the documentation for how to generate an artifact out of your Noir source code.
|
|
6
|
-
*
|
|
7
|
-
* The {@link Contract} class is the main class in this module, and provides static methods for deploying
|
|
8
|
-
* a contract or interacting with an already deployed one. The `methods` property of the contract instance
|
|
9
|
-
* provides access to private, public, and simulate methods, that can be invoked in a transaction via `send()`,
|
|
10
|
-
* or can be queried via `simulate()`.
|
|
11
|
-
*
|
|
12
|
-
* ```ts
|
|
13
|
-
* const contract = await Contract.deploy(wallet, MyContractArtifact, [...constructorArgs]).send().deployed();
|
|
14
|
-
* console.log(`Contract deployed at ${contract.address}`);
|
|
15
|
-
* ```
|
|
16
|
-
*
|
|
17
|
-
* ```ts
|
|
18
|
-
* const contract = await Contract.at(address, MyContractArtifact, wallet);
|
|
19
|
-
* await contract.methods.mint(1000, owner).send().wait();
|
|
20
|
-
* console.log(`Total supply is now ${await contract.methods.totalSupply().simulate()}`);
|
|
21
|
-
* ```
|
|
22
|
-
*
|
|
23
|
-
* The result of calling a method in a contract instance, such as `contract.methods.mint(1000, owner)`
|
|
24
|
-
* in the example, is a {@link ContractFunctionInteraction} instance. Usually this will be just sent as
|
|
25
|
-
* a transaction to the network via the `send` method, but you can also `simulate` it without sending,
|
|
26
|
-
* or obtaining the `request` for aggregating into a {@link BatchCall}.
|
|
27
|
-
*
|
|
28
|
-
* The result of `send`ing a transaction is a {@link SentTx} object, from which you can get the
|
|
29
|
-
* transaction hash, or simply `wait` until the transaction is mined and the local PXE Service
|
|
30
|
-
* has synchronized its changes.
|
|
31
|
-
*
|
|
32
|
-
* @remarks If you are using typescript, consider using the
|
|
33
|
-
* {@link https://docs.aztec.network/developers/contracts/compiling#typescript-interfaces | autogenerated type-safe interfaces}
|
|
34
|
-
* for interacting with your contracts.
|
|
35
|
-
*
|
|
36
|
-
* @packageDocumentation
|
|
37
|
-
*/
|
|
38
|
-
export { Contract } from './contract.js';
|
|
39
|
-
export { ContractFunctionInteraction, type ProfileResult, type SendMethodOptions, } from './contract_function_interaction.js';
|
|
40
|
-
export { DefaultWaitOpts, SentTx, type WaitOpts } from './sent_tx.js';
|
|
41
|
-
export { ContractBase, type ContractMethod, type ContractNotes, type ContractStorageLayout } from './contract_base.js';
|
|
42
|
-
export { BatchCall } from './batch_call.js';
|
|
43
|
-
export { type DeployOptions, DeployMethod } from './deploy_method.js';
|
|
44
|
-
export { DeploySentTx } from './deploy_sent_tx.js';
|
|
45
|
-
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/contract/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoCG;AACH,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACzC,OAAO,EACL,2BAA2B,EAC3B,KAAK,aAAa,EAClB,KAAK,iBAAiB,GACvB,MAAM,oCAAoC,CAAC;AAC5C,OAAO,EAAE,eAAe,EAAE,MAAM,EAAE,KAAK,QAAQ,EAAE,MAAM,cAAc,CAAC;AACtE,OAAO,EAAE,YAAY,EAAE,KAAK,cAAc,EAAE,KAAK,aAAa,EAAE,KAAK,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AACvH,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAC5C,OAAO,EAAE,KAAK,aAAa,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AACtE,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC"}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { type PXE, Tx } from '@aztec/circuit-types';
|
|
2
|
-
import { type Wallet } from '../account/index.js';
|
|
3
|
-
import { SentTx } from './sent_tx.js';
|
|
4
|
-
/**
|
|
5
|
-
* A proven transaction that can be sent to the network. Returned by the `prove` method of a contract interaction.
|
|
6
|
-
*/
|
|
7
|
-
export declare class ProvenTx extends Tx {
|
|
8
|
-
protected wallet: PXE | Wallet;
|
|
9
|
-
constructor(wallet: PXE | Wallet, tx: Tx);
|
|
10
|
-
protected getPlainDataTx(): Tx;
|
|
11
|
-
/**
|
|
12
|
-
* Sends the transaction to the network via the provided wallet.
|
|
13
|
-
*/
|
|
14
|
-
send(): SentTx;
|
|
15
|
-
}
|
|
16
|
-
//# sourceMappingURL=proven_tx.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"proven_tx.d.ts","sourceRoot":"","sources":["../../src/contract/proven_tx.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,GAAG,EAAE,EAAE,EAAE,MAAM,sBAAsB,CAAC;AAEpD,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AAEtC;;GAEG;AACH,qBAAa,QAAS,SAAQ,EAAE;IAClB,SAAS,CAAC,MAAM,EAAE,GAAG,GAAG,MAAM;gBAApB,MAAM,EAAE,GAAG,GAAG,MAAM,EAAE,EAAE,EAAE,EAAE;IAWlD,SAAS,CAAC,cAAc,IAAI,EAAE;IAU9B;;OAEG;IACI,IAAI,IAAI,MAAM;CAOtB"}
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
import { type GetPublicLogsResponse, type PXE, type TxHash, type TxReceipt } from '@aztec/circuit-types';
|
|
2
|
-
import { type FieldsOf } from '@aztec/foundation/types';
|
|
3
|
-
/** Options related to waiting for a tx. */
|
|
4
|
-
export type WaitOpts = {
|
|
5
|
-
/** The amount of time to ignore TxStatus.DROPPED receipts (in seconds) due to the presumption that it is being propagated by the p2p network. Defaults to 5. */
|
|
6
|
-
ignoreDroppedReceiptsFor?: number;
|
|
7
|
-
/** The maximum time (in seconds) to wait for the transaction to be mined. Defaults to 60. */
|
|
8
|
-
timeout?: number;
|
|
9
|
-
/** The maximum time (in seconds) to wait for the transaction to be proven. Defaults to 600. */
|
|
10
|
-
provenTimeout?: number;
|
|
11
|
-
/** The time interval (in seconds) between retries to fetch the transaction receipt. Defaults to 1. */
|
|
12
|
-
interval?: number;
|
|
13
|
-
/** Whether to wait for the tx to be proven. */
|
|
14
|
-
proven?: boolean;
|
|
15
|
-
/** Whether to include information useful for debugging/testing in the receipt. */
|
|
16
|
-
debug?: boolean;
|
|
17
|
-
/** Whether to accept a revert as a status code for the tx when waiting for it. If false, will throw if the tx reverts. */
|
|
18
|
-
dontThrowOnRevert?: boolean;
|
|
19
|
-
};
|
|
20
|
-
export declare const DefaultWaitOpts: WaitOpts;
|
|
21
|
-
/**
|
|
22
|
-
* The SentTx class represents a sent transaction through the PXE, providing methods to fetch
|
|
23
|
-
* its hash, receipt, and mining status.
|
|
24
|
-
*/
|
|
25
|
-
export declare class SentTx {
|
|
26
|
-
protected pxe: PXE;
|
|
27
|
-
protected txHashPromise: Promise<TxHash>;
|
|
28
|
-
constructor(pxe: PXE, txHashPromise: Promise<TxHash>);
|
|
29
|
-
/**
|
|
30
|
-
* Retrieves the transaction hash of the SentTx instance.
|
|
31
|
-
* The function internally awaits for the 'txHashPromise' to resolve, and then returns the resolved transaction hash.
|
|
32
|
-
*
|
|
33
|
-
* @returns A promise that resolves to the transaction hash of the SentTx instance.
|
|
34
|
-
* TODO(#7717): Don't throw here.
|
|
35
|
-
*/
|
|
36
|
-
getTxHash(): Promise<TxHash>;
|
|
37
|
-
/**
|
|
38
|
-
* Retrieve the transaction receipt associated with the current SentTx instance.
|
|
39
|
-
* The function fetches the transaction hash using 'getTxHash' and then queries
|
|
40
|
-
* the PXE to get the corresponding transaction receipt.
|
|
41
|
-
*
|
|
42
|
-
* @returns A promise that resolves to a TxReceipt object representing the fetched transaction receipt.
|
|
43
|
-
*/
|
|
44
|
-
getReceipt(): Promise<TxReceipt>;
|
|
45
|
-
/**
|
|
46
|
-
* Awaits for a tx to be mined and returns the receipt. Throws if tx is not mined.
|
|
47
|
-
* @param opts - Options for configuring the waiting for the tx to be mined.
|
|
48
|
-
* @returns The transaction receipt.
|
|
49
|
-
*/
|
|
50
|
-
wait(opts?: WaitOpts): Promise<FieldsOf<TxReceipt>>;
|
|
51
|
-
/**
|
|
52
|
-
* Gets public logs emitted by this tx.
|
|
53
|
-
* @remarks This function will wait for the tx to be mined if it hasn't been already.
|
|
54
|
-
* @returns The requested logs.
|
|
55
|
-
*/
|
|
56
|
-
getPublicLogs(): Promise<GetPublicLogsResponse>;
|
|
57
|
-
protected waitForReceipt(opts?: WaitOpts): Promise<TxReceipt>;
|
|
58
|
-
protected waitForProven(minedBlock: number, opts?: WaitOpts): Promise<number>;
|
|
59
|
-
}
|
|
60
|
-
//# sourceMappingURL=sent_tx.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sent_tx.d.ts","sourceRoot":"","sources":["../../src/contract/sent_tx.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,qBAAqB,EAAE,KAAK,GAAG,EAAE,KAAK,MAAM,EAAE,KAAK,SAAS,EAAY,MAAM,sBAAsB,CAAC;AAEnH,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,yBAAyB,CAAC;AAExD,2CAA2C;AAC3C,MAAM,MAAM,QAAQ,GAAG;IACrB,gKAAgK;IAChK,wBAAwB,CAAC,EAAE,MAAM,CAAC;IAClC,6FAA6F;IAC7F,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,+FAA+F;IAC/F,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,sGAAsG;IACtG,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,+CAA+C;IAC/C,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,kFAAkF;IAClF,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,0HAA0H;IAC1H,iBAAiB,CAAC,EAAE,OAAO,CAAC;CAC7B,CAAC;AAEF,eAAO,MAAM,eAAe,EAAE,QAM7B,CAAC;AAEF;;;GAGG;AACH,qBAAa,MAAM;IACL,SAAS,CAAC,GAAG,EAAE,GAAG;IAAE,SAAS,CAAC,aAAa,EAAE,OAAO,CAAC,MAAM,CAAC;gBAAlD,GAAG,EAAE,GAAG,EAAY,aAAa,EAAE,OAAO,CAAC,MAAM,CAAC;IAExE;;;;;;OAMG;IACI,SAAS,IAAI,OAAO,CAAC,MAAM,CAAC;IAInC;;;;;;OAMG;IACU,UAAU,IAAI,OAAO,CAAC,SAAS,CAAC;IAK7C;;;;OAIG;IACU,IAAI,CAAC,IAAI,CAAC,EAAE,QAAQ,GAAG,OAAO,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAC;IAuBhE;;;;OAIG;IACU,aAAa,IAAI,OAAO,CAAC,qBAAqB,CAAC;cAK5C,cAAc,CAAC,IAAI,CAAC,EAAE,QAAQ,GAAG,OAAO,CAAC,SAAS,CAAC;cA8BnD,aAAa,CAAC,UAAU,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,QAAQ;CAWlE"}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { type ContractInstanceWithAddress } from '@aztec/circuits.js';
|
|
2
|
-
import { type ContractArtifact } from '@aztec/foundation/abi';
|
|
3
|
-
import { type Wallet } from '../wallet/index.js';
|
|
4
|
-
import { ContractBase } from './contract_base.js';
|
|
5
|
-
/** Unsafe constructor for ContractBase that bypasses the check that the instance is registered in the wallet. */
|
|
6
|
-
export declare class UnsafeContract extends ContractBase {
|
|
7
|
-
constructor(
|
|
8
|
-
/** The deployed contract instance definition. */
|
|
9
|
-
instance: ContractInstanceWithAddress,
|
|
10
|
-
/** The Application Binary Interface for the contract. */
|
|
11
|
-
artifact: ContractArtifact,
|
|
12
|
-
/** The wallet used for interacting with this contract. */
|
|
13
|
-
wallet: Wallet);
|
|
14
|
-
}
|
|
15
|
-
//# sourceMappingURL=unsafe_contract.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"unsafe_contract.d.ts","sourceRoot":"","sources":["../../src/contract/unsafe_contract.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,2BAA2B,EAAE,MAAM,oBAAoB,CAAC;AACtE,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AAE9D,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAElD,iHAAiH;AACjH,qBAAa,cAAe,SAAQ,YAAY;;IAE5C,iDAAiD;IACjD,QAAQ,EAAE,2BAA2B;IACrC,yDAAyD;IACzD,QAAQ,EAAE,gBAAgB;IAC1B,0DAA0D;IAC1D,MAAM,EAAE,MAAM;CAIjB"}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { type ContractArtifact, FunctionSelector } from '@aztec/foundation/abi';
|
|
2
|
-
import { type ContractFunctionInteraction } from '../contract/contract_function_interaction.js';
|
|
3
|
-
import { type Wallet } from '../wallet/index.js';
|
|
4
|
-
/**
|
|
5
|
-
* Sets up a call to broadcast a private function's bytecode via the ClassRegisterer contract.
|
|
6
|
-
* Note that this is not required for users to call the function, but is rather a convenience to make
|
|
7
|
-
* this code publicly available so dapps or wallets do not need to redistribute it.
|
|
8
|
-
* @param wallet - Wallet to send the transaction.
|
|
9
|
-
* @param artifact - Contract artifact that contains the function to be broadcast.
|
|
10
|
-
* @param selector - Selector of the function to be broadcast.
|
|
11
|
-
* @returns A ContractFunctionInteraction object that can be used to send the transaction.
|
|
12
|
-
*/
|
|
13
|
-
export declare function broadcastPrivateFunction(wallet: Wallet, artifact: ContractArtifact, selector: FunctionSelector): Promise<ContractFunctionInteraction>;
|
|
14
|
-
/**
|
|
15
|
-
* Sets up a call to broadcast an unconstrained function's bytecode via the ClassRegisterer contract.
|
|
16
|
-
* Note that this is not required for users to call the function, but is rather a convenience to make
|
|
17
|
-
* this code publicly available so dapps or wallets do not need to redistribute it.
|
|
18
|
-
* @param wallet - Wallet to send the transaction.
|
|
19
|
-
* @param artifact - Contract artifact that contains the function to be broadcast.
|
|
20
|
-
* @param selector - Selector of the function to be broadcast.
|
|
21
|
-
* @returns A ContractFunctionInteraction object that can be used to send the transaction.
|
|
22
|
-
*/
|
|
23
|
-
export declare function broadcastUnconstrainedFunction(wallet: Wallet, artifact: ContractArtifact, selector: FunctionSelector): Promise<ContractFunctionInteraction>;
|
|
24
|
-
//# sourceMappingURL=broadcast_function.d.ts.map
|