From 0a60a442fbc62a9c36fc0deb7178c36f0f6e9ac5 Mon Sep 17 00:00:00 2001 From: Kai Hirota <34954529+kaihirota@users.noreply.github.com> Date: Tue, 27 Feb 2024 16:29:39 +1100 Subject: [PATCH] CORE-2033 Add RegistrationV4 contract (#422) * update OpenAPI generated API client code * add prepare withdrawal v2 workflow * fix typo * update error message * rename vars * add v2 complete withdrawal * update * move location * add v4 starkex contracts * add v2 registration contract bindings * add readme * update * update * add v4 stark contract * update * add stark v4 factory * rename core factory to stark v3 * update * update examples * update * update * fix bad refs * add stark v4 factory * rename core factory to stark v3 * update * add v2 complete withdrawal * update * add v4 stark contract * update * update examples * update changelog and version * changelog * rename from v2 to v4 * bump version * update readme * minor change * update solidity contracts * update contract * bump version * regenerate --- CHANGELOG.md | 8 + contracts/{ => v3}/Core.sol | 0 contracts/{ => v3}/Registration.sol | 0 contracts/v4/CoreV4.sol | 277 ++ contracts/v4/README.md | 6 + contracts/v4/RegistrationV4.sol | 81 + hardhat.config.ts | 2 +- package.json | 2 +- .../contracts/token/ERC20/IERC20.ts | 170 +- .../contracts/token/ERC721/IERC721.ts | 324 +- .../contracts/utils/introspection/IERC165.ts | 13 +- src/contracts/common.ts | 2 + src/contracts/contracts/Registration.ts | 471 -- src/contracts/contracts/index.ts | 7 +- .../contracts/{StarkV3.ts => v3/Core.ts} | 1746 +++---- src/contracts/contracts/v3/Registration.ts | 495 ++ src/contracts/contracts/v3/index.ts | 5 + .../contracts/{StarkV4.ts => v4/CoreV4.ts} | 4266 +++++++++-------- src/contracts/contracts/v4/RegistrationV4.ts | 366 ++ src/contracts/contracts/v4/index.ts | 5 + src/contracts/factories/contracts/index.ts | 5 +- .../Core__factory.ts} | 12 +- .../{ => v3}/Registration__factory.ts | 13 +- src/contracts/factories/contracts/v3/index.ts | 5 + .../CoreV4__factory.ts} | 2219 +++++---- .../contracts/v4/RegistrationV4__factory.ts | 254 + src/contracts/factories/contracts/v4/index.ts | 5 + src/contracts/hardhat.d.ts | 18 + src/contracts/index.ts | 33 +- src/exportContracts.ts | 2 +- src/workflows/deposit/depositERC20.ts | 10 +- src/workflows/deposit/depositERC721.ts | 8 +- src/workflows/deposit/depositEth.ts | 12 +- .../withdrawal/completeERC20Withdrawal.ts | 12 +- .../withdrawal/completeERC721Withdrawal.ts | 18 +- .../withdrawal/completeEthWithdrawal.ts | 12 +- 36 files changed, 6126 insertions(+), 4758 deletions(-) rename contracts/{ => v3}/Core.sol (100%) rename contracts/{ => v3}/Registration.sol (100%) create mode 100644 contracts/v4/CoreV4.sol create mode 100644 contracts/v4/README.md create mode 100644 contracts/v4/RegistrationV4.sol delete mode 100644 src/contracts/contracts/Registration.ts rename src/contracts/contracts/{StarkV3.ts => v3/Core.ts} (55%) create mode 100644 src/contracts/contracts/v3/Registration.ts create mode 100644 src/contracts/contracts/v3/index.ts rename src/contracts/contracts/{StarkV4.ts => v4/CoreV4.ts} (63%) create mode 100644 src/contracts/contracts/v4/RegistrationV4.ts create mode 100644 src/contracts/contracts/v4/index.ts rename src/contracts/factories/contracts/{StarkV3__factory.ts => v3/Core__factory.ts} (99%) rename src/contracts/factories/contracts/{ => v3}/Registration__factory.ts (97%) create mode 100644 src/contracts/factories/contracts/v3/index.ts rename src/contracts/factories/contracts/{StarkV4__factory.ts => v4/CoreV4__factory.ts} (99%) create mode 100644 src/contracts/factories/contracts/v4/RegistrationV4__factory.ts create mode 100644 src/contracts/factories/contracts/v4/index.ts diff --git a/CHANGELOG.md b/CHANGELOG.md index ea7077d5..cbe7a626 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,8 +5,16 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [3.2.0] - 2024-02-27 + +### Added + +- Add V4 registration contract bindings. + ## [3.1.0] - 2024-02-27 +### Added + - Remove experimental flag for primary sales functions ## [3.0.0] - 2024-02-26 diff --git a/contracts/Core.sol b/contracts/v3/Core.sol similarity index 100% rename from contracts/Core.sol rename to contracts/v3/Core.sol diff --git a/contracts/Registration.sol b/contracts/v3/Registration.sol similarity index 100% rename from contracts/Registration.sol rename to contracts/v3/Registration.sol diff --git a/contracts/v4/CoreV4.sol b/contracts/v4/CoreV4.sol new file mode 100644 index 00000000..b2c0e5ce --- /dev/null +++ b/contracts/v4/CoreV4.sol @@ -0,0 +1,277 @@ +// Copyright (c) Immutable Pty Ltd 2018 - 2024 +// SPDX-License-Identifier: MIT +// +// This contract is an interface for the StarkEx Core contract v4 version. +// It is used to interact with the StarkEx Core contract from the Registration contract. +// The Core contract is used to register and withdraw users and assets from the StarkEx system. +// +// This file was generated using the abi-to-sol tool. +// the StarkEx contract ABI that was provided by StarkWare via slack. +pragma solidity ^0.8.19; + +interface CoreV4 { + fallback() external payable; + + function VERSION() external view returns (string memory); + + function initialize(bytes memory data) external; + + receive() external payable; + + event LogFrozen(); + event LogNewGovernorAccepted(address acceptedGovernor); + event LogNominatedGovernor(address nominatedGovernor); + event LogNominationCancelled(); + event LogRegistered(address entry, string entryId); + event LogRemovalIntent(address entry, string entryId); + event LogRemoved(address entry, string entryId); + event LogRemovedGovernor(address removedGovernor); + event LogUnFrozen(); + + function DEPOSIT_CANCEL_DELAY() external view returns (uint256); + + function FREEZE_GRACE_PERIOD() external view returns (uint256); + + function MAIN_GOVERNANCE_INFO_TAG() external view returns (string memory); + + function MAX_FORCED_ACTIONS_REQS_PER_BLOCK() external view returns (uint256); + + function MAX_VERIFIER_COUNT() external view returns (uint256); + + function UNFREEZE_DELAY() external view returns (uint256); + + function VERIFIER_REMOVAL_DELAY() external view returns (uint256); + + function announceAvailabilityVerifierRemovalIntent(address verifier) external; + + function announceVerifierRemovalIntent(address verifier) external; + + function getRegisteredAvailabilityVerifiers() external view returns (address[] memory _verifers); + + function getRegisteredVerifiers() external view returns (address[] memory _verifers); + + function isAvailabilityVerifier(address verifierAddress) external view returns (bool); + + function isFrozen() external view returns (bool); + + function isVerifier(address verifierAddress) external view returns (bool); + + function mainAcceptGovernance() external; + + function mainCancelNomination() external; + + function mainIsGovernor(address testGovernor) external view returns (bool); + + function mainNominateNewGovernor(address newGovernor) external; + + function mainRemoveGovernor(address governorForRemoval) external; + + function registerAvailabilityVerifier(address verifier, string memory identifier) external; + + function registerVerifier(address verifier, string memory identifier) external; + + function removeAvailabilityVerifier(address verifier) external; + + function removeVerifier(address verifier) external; + + function unFreeze() external; + + event LogDeposit( + address depositorEthKey, + uint256 starkKey, + uint256 vaultId, + uint256 assetType, + uint256 nonQuantizedAmount, + uint256 quantizedAmount + ); + event LogDepositCancel(uint256 starkKey, uint256 vaultId, uint256 assetId); + event LogDepositCancelReclaimed( + uint256 starkKey, uint256 vaultId, uint256 assetType, uint256 nonQuantizedAmount, uint256 quantizedAmount + ); + event LogDepositNftCancelReclaimed( + uint256 starkKey, uint256 vaultId, uint256 assetType, uint256 tokenId, uint256 assetId + ); + event LogMintWithdrawalPerformed( + uint256 ownerKey, uint256 assetType, uint256 nonQuantizedAmount, uint256 quantizedAmount, uint256 assetId + ); + event LogMintableWithdrawalAllowed(uint256 ownerKey, uint256 assetId, uint256 quantizedAmount); + event LogNftDeposit( + address depositorEthKey, uint256 starkKey, uint256 vaultId, uint256 assetType, uint256 tokenId, uint256 assetId + ); + event LogNftWithdrawalAllowed(uint256 ownerKey, uint256 assetId); + event LogNftWithdrawalPerformed( + uint256 ownerKey, uint256 assetType, uint256 tokenId, uint256 assetId, address recipient + ); + event LogTokenAdminAdded(address tokenAdmin); + event LogTokenAdminRemoved(address tokenAdmin); + event LogTokenRegistered(uint256 assetType, bytes assetInfo, uint256 quantum); + event LogUserRegistered(address ethKey, uint256 starkKey, address sender); + event LogWithdrawalAllowed( + uint256 ownerKey, uint256 assetType, uint256 nonQuantizedAmount, uint256 quantizedAmount + ); + event LogWithdrawalPerformed( + uint256 ownerKey, uint256 assetType, uint256 nonQuantizedAmount, uint256 quantizedAmount, address recipient + ); + + function defaultVaultWithdrawalLock() external view returns (uint256); + + function deposit(uint256 starkKey, uint256 assetType, uint256 vaultId) external payable; + + function deposit(uint256 starkKey, uint256 assetType, uint256 vaultId, uint256 quantizedAmount) external; + + function depositCancel(uint256 starkKey, uint256 assetId, uint256 vaultId) external; + + function depositERC20(uint256 starkKey, uint256 assetType, uint256 vaultId, uint256 quantizedAmount) external; + + function depositEth(uint256 starkKey, uint256 assetType, uint256 vaultId) external payable; + + function depositNft(uint256 starkKey, uint256 assetType, uint256 vaultId, uint256 tokenId) external; + + function depositNftReclaim(uint256 starkKey, uint256 assetType, uint256 vaultId, uint256 tokenId) external; + + function depositReclaim(uint256 starkKey, uint256 assetId, uint256 vaultId) external; + + function getActionCount() external view returns (uint256); + + function getActionHashByIndex(uint256 actionIndex) external view returns (bytes32); + + function getAssetInfo(uint256 assetType) external view returns (bytes memory assetInfo); + + function getCancellationRequest(uint256 starkKey, uint256 assetId, uint256 vaultId) + external + view + returns (uint256 request); + + function getDepositBalance(uint256 starkKey, uint256 assetId, uint256 vaultId) + external + view + returns (uint256 balance); + + function getEthKey(uint256 ownerKey) external view returns (address); + + function getFullWithdrawalRequest(uint256 starkKey, uint256 vaultId) external view returns (uint256 res); + + function getQuantizedDepositBalance(uint256 starkKey, uint256 assetId, uint256 vaultId) + external + view + returns (uint256 balance); + + function getQuantum(uint256 presumedAssetType) external view returns (uint256 quantum); + + function getWithdrawalBalance(uint256 ownerKey, uint256 assetId) external view returns (uint256 balance); + + function isAssetRegistered(uint256 assetType) external view returns (bool); + + function isTokenAdmin(address testedAdmin) external view returns (bool); + + function onERC721Received(address, address, uint256, bytes memory) external returns (bytes4); + + function orderRegistryAddress() external view returns (address); + + function registerAndDepositERC20( + address ethKey, + uint256 starkKey, + bytes memory signature, + uint256 assetType, + uint256 vaultId, + uint256 quantizedAmount + ) external; + + function registerAndDepositEth( + address ethKey, + uint256 starkKey, + bytes memory signature, + uint256 assetType, + uint256 vaultId + ) external payable; + + function registerEthAddress(address ethKey, uint256 starkKey, bytes memory starkSignature) external; + + function registerSender(uint256 starkKey, bytes memory starkSignature) external; + + function registerToken(uint256 assetType, bytes memory assetInfo) external; + + function registerToken(uint256 assetType, bytes memory assetInfo, uint256 quantum) external; + + function registerTokenAdmin(address newAdmin) external; + + function unregisterTokenAdmin(address oldAdmin) external; + + function withdraw(uint256 ownerKey, uint256 assetType) external; + + function withdrawAndMint(uint256 ownerKey, uint256 assetType, bytes memory mintingBlob) external; + + function withdrawNft(uint256 ownerKey, uint256 assetType, uint256 tokenId) external; + + event LogOperatorAdded(address operator); + event LogOperatorRemoved(address operator); + event LogRootUpdate(uint256 sequenceNumber, uint256 batchId, uint256 vaultRoot, uint256 orderRoot); + event LogStateTransitionFact(bytes32 stateTransitionFact); + event LogVaultBalanceChangeApplied(address ethKey, uint256 assetId, uint256 vaultId, int256 quantizedAmountChange); + + function STARKEX_MAX_DEFAULT_VAULT_LOCK() external view returns (uint256); + + function escape(uint256 starkKey, uint256 vaultId, uint256 assetId, uint256 quantizedAmount) external; + + function getLastBatchId() external view returns (uint256 batchId); + + function getOrderRoot() external view returns (uint256 root); + + function getOrderTreeHeight() external view returns (uint256 height); + + function getSequenceNumber() external view returns (uint256 seq); + + function getVaultRoot() external view returns (uint256 root); + + function getVaultTreeHeight() external view returns (uint256 height); + + function isOperator(address testedOperator) external view returns (bool); + + function registerOperator(address newOperator) external; + + function unregisterOperator(address removedOperator) external; + + function updateState(uint256[] memory publicInput, uint256[] memory applicationData) external; + + event LogFullWithdrawalRequest(uint256 starkKey, uint256 vaultId); + + function freezeRequest(uint256 starkKey, uint256 vaultId) external; + + function fullWithdrawalRequest(uint256 starkKey, uint256 vaultId) external; + + event LogDefaultVaultWithdrawalLockSet(uint256 newDefaultLockTime); + event LogDepositToVault( + address ethKey, uint256 assetId, uint256 vaultId, uint256 nonQuantizedAmount, uint256 quantizedAmount + ); + event LogVaultWithdrawalLockSet(address ethKey, uint256 assetId, uint256 vaultId, uint256 timeRelease); + event LogWithdrawalFromVault( + address ethKey, uint256 assetId, uint256 vaultId, uint256 nonQuantizedAmount, uint256 quantizedAmount + ); + + function depositERC20ToVault(uint256 assetId, uint256 vaultId, uint256 quantizedAmount) external; + + function depositEthToVault(uint256 assetId, uint256 vaultId) external payable; + + function getQuantizedVaultBalance(address ethKey, uint256 assetId, uint256 vaultId) + external + view + returns (uint256); + + function getVaultBalance(address ethKey, uint256 assetId, uint256 vaultId) external view returns (uint256); + + function getVaultWithdrawalLock(address ethKey, uint256 assetId, uint256 vaultId) external view returns (uint256); + + function isStrictVaultBalancePolicy() external view returns (bool); + + function isVaultLocked(address ethKey, uint256 assetId, uint256 vaultId) external view returns (bool); + + function lockVault(uint256 assetId, uint256 vaultId, uint256 lockTime) external; + + function setDefaultVaultWithdrawalLock(uint256 newDefaultTime) external; + + function withdrawFromVault(uint256 assetId, uint256 vaultId, uint256 quantizedAmount) external; + + event ImplementationActivationRescheduled(address indexed implementation, uint256 updatedActivationTime); + + function updateImplementationActivationTime(address implementation, bytes memory data, bool finalize) external; +} \ No newline at end of file diff --git a/contracts/v4/README.md b/contracts/v4/README.md new file mode 100644 index 00000000..fb583d81 --- /dev/null +++ b/contracts/v4/README.md @@ -0,0 +1,6 @@ +# About + +Contracts in this directory are for interacting with StarkEx contracts with version >= 4.0. + +- `Core.sol` - wrapper for StarkEx V4 contract. +- `Registration.sol` - Version 2 of the registration wrapper contract, which adds helper functions like `withdrawAll` and `registerAndWithdrawAll`, which can be used in edge cases where a user has prepared withdrawals in StarkEx v3 and v4 contract, and wishes to withdraw both in one transaction. It is named RegistrationV4 because it is designed to interact with StarkEx V4 contract. diff --git a/contracts/v4/RegistrationV4.sol b/contracts/v4/RegistrationV4.sol new file mode 100644 index 00000000..3f760668 --- /dev/null +++ b/contracts/v4/RegistrationV4.sol @@ -0,0 +1,81 @@ +// Copyright (c) Immutable Pty Ltd 2018 - 2024 +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.19; + +import {CoreV4} from "./CoreV4.sol"; + +/** + * Emitted when there are no funds to withdraw when calling `withdrawAll`. + */ +error NoFundsToWithdraw(uint256 ethKey, uint256 starkKey); + +/** + * RegistrationV4 is a wrapper around the StarkEx contract to provide a more user-friendly interface for executing multiple transactions on the StarkEx contract at once. + * This contract is not upgradeable. If an issue is found with this contract, a new version will be deployed. + */ +contract RegistrationV4 { + CoreV4 public immutable imx; + + constructor(address payable _imx) { + imx = CoreV4(_imx); + } + + function registerAndWithdrawAll(address ethKey, uint256 starkKey, bytes calldata signature, uint256 assetType) + external + { + if (!isRegistered(starkKey)) { + imx.registerEthAddress(ethKey, starkKey, signature); + } + withdrawAll(uint160(ethKey), starkKey, assetType); + } + + function withdrawAll(uint256 ethKey, uint256 starkKey, uint256 assetType) public { + uint256 ethKeyBalance = imx.getWithdrawalBalance(ethKey, assetType); + uint256 starkKeyBalance = imx.getWithdrawalBalance(starkKey, assetType); + if (ethKeyBalance == 0 && starkKeyBalance == 0) { + revert NoFundsToWithdraw(ethKey, starkKey); + } + + if (ethKeyBalance > 0) { + imx.withdraw(ethKey, assetType); + } + + if (starkKeyBalance > 0) { + imx.withdraw(starkKey, assetType); + } + } + + function registerAndWithdrawNft( + address ethKey, + uint256 starkKey, + bytes calldata signature, + uint256 assetType, + uint256 tokenId + ) external { + if (!isRegistered(starkKey)) { + imx.registerEthAddress(ethKey, starkKey, signature); + } + imx.withdrawNft(starkKey, assetType, tokenId); + } + + function registerWithdrawAndMint( + address ethKey, + uint256 starkKey, + bytes calldata signature, + uint256 assetType, + bytes calldata mintingBlob + ) external { + if (!isRegistered(starkKey)) { + imx.registerEthAddress(ethKey, starkKey, signature); + } + imx.withdrawAndMint(starkKey, assetType, mintingBlob); + } + + function getVersion() external view returns (string memory) { + return imx.VERSION(); + } + + function isRegistered(uint256 starkKey) public view returns (bool) { + return imx.getEthKey(starkKey) != address(0); + } +} \ No newline at end of file diff --git a/hardhat.config.ts b/hardhat.config.ts index 5f695911..13eae386 100644 --- a/hardhat.config.ts +++ b/hardhat.config.ts @@ -3,7 +3,7 @@ require('@typechain/hardhat'); require('@nomiclabs/hardhat-ethers'); const config = { - solidity: '0.8.11', + solidity: '0.8.19', typechain: { outDir: 'src/contracts', target: 'ethers-v5', diff --git a/package.json b/package.json index aa6e82c4..be29c4f4 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@imtbl/core-sdk", - "version": "3.1.0", + "version": "3.2.0", "description": "Immutable Core SDK", "main": "dist/index.cjs.js", "module": "dist/index.es.js", diff --git a/src/contracts/@openzeppelin/contracts/token/ERC20/IERC20.ts b/src/contracts/@openzeppelin/contracts/token/ERC20/IERC20.ts index d7090694..e99e80b8 100644 --- a/src/contracts/@openzeppelin/contracts/token/ERC20/IERC20.ts +++ b/src/contracts/@openzeppelin/contracts/token/ERC20/IERC20.ts @@ -24,6 +24,7 @@ import type { TypedEvent, TypedListener, OnEvent, + PromiseOrValue, } from "../../../../common"; export interface IERC20Interface extends utils.Interface { @@ -48,24 +49,31 @@ export interface IERC20Interface extends utils.Interface { encodeFunctionData( functionFragment: "allowance", - values: [string, string] + values: [PromiseOrValue, PromiseOrValue] ): string; encodeFunctionData( functionFragment: "approve", - values: [string, BigNumberish] + values: [PromiseOrValue, PromiseOrValue] + ): string; + encodeFunctionData( + functionFragment: "balanceOf", + values: [PromiseOrValue] ): string; - encodeFunctionData(functionFragment: "balanceOf", values: [string]): string; encodeFunctionData( functionFragment: "totalSupply", values?: undefined ): string; encodeFunctionData( functionFragment: "transfer", - values: [string, BigNumberish] + values: [PromiseOrValue, PromiseOrValue] ): string; encodeFunctionData( functionFragment: "transferFrom", - values: [string, string, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; decodeFunctionResult(functionFragment: "allowance", data: BytesLike): Result; @@ -142,181 +150,193 @@ export interface IERC20 extends BaseContract { functions: { allowance( - owner: string, - spender: string, + owner: PromiseOrValue, + spender: PromiseOrValue, overrides?: CallOverrides ): Promise<[BigNumber]>; approve( - spender: string, - amount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + spender: PromiseOrValue, + amount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - balanceOf(account: string, overrides?: CallOverrides): Promise<[BigNumber]>; + balanceOf( + account: PromiseOrValue, + overrides?: CallOverrides + ): Promise<[BigNumber]>; totalSupply(overrides?: CallOverrides): Promise<[BigNumber]>; transfer( - to: string, - amount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + to: PromiseOrValue, + amount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; transferFrom( - from: string, - to: string, - amount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + from: PromiseOrValue, + to: PromiseOrValue, + amount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; }; allowance( - owner: string, - spender: string, + owner: PromiseOrValue, + spender: PromiseOrValue, overrides?: CallOverrides ): Promise; approve( - spender: string, - amount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + spender: PromiseOrValue, + amount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - balanceOf(account: string, overrides?: CallOverrides): Promise; + balanceOf( + account: PromiseOrValue, + overrides?: CallOverrides + ): Promise; totalSupply(overrides?: CallOverrides): Promise; transfer( - to: string, - amount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + to: PromiseOrValue, + amount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; transferFrom( - from: string, - to: string, - amount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + from: PromiseOrValue, + to: PromiseOrValue, + amount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; callStatic: { allowance( - owner: string, - spender: string, + owner: PromiseOrValue, + spender: PromiseOrValue, overrides?: CallOverrides ): Promise; approve( - spender: string, - amount: BigNumberish, + spender: PromiseOrValue, + amount: PromiseOrValue, overrides?: CallOverrides ): Promise; - balanceOf(account: string, overrides?: CallOverrides): Promise; + balanceOf( + account: PromiseOrValue, + overrides?: CallOverrides + ): Promise; totalSupply(overrides?: CallOverrides): Promise; transfer( - to: string, - amount: BigNumberish, + to: PromiseOrValue, + amount: PromiseOrValue, overrides?: CallOverrides ): Promise; transferFrom( - from: string, - to: string, - amount: BigNumberish, + from: PromiseOrValue, + to: PromiseOrValue, + amount: PromiseOrValue, overrides?: CallOverrides ): Promise; }; filters: { "Approval(address,address,uint256)"( - owner?: string | null, - spender?: string | null, + owner?: PromiseOrValue | null, + spender?: PromiseOrValue | null, value?: null ): ApprovalEventFilter; Approval( - owner?: string | null, - spender?: string | null, + owner?: PromiseOrValue | null, + spender?: PromiseOrValue | null, value?: null ): ApprovalEventFilter; "Transfer(address,address,uint256)"( - from?: string | null, - to?: string | null, + from?: PromiseOrValue | null, + to?: PromiseOrValue | null, value?: null ): TransferEventFilter; Transfer( - from?: string | null, - to?: string | null, + from?: PromiseOrValue | null, + to?: PromiseOrValue | null, value?: null ): TransferEventFilter; }; estimateGas: { allowance( - owner: string, - spender: string, + owner: PromiseOrValue, + spender: PromiseOrValue, overrides?: CallOverrides ): Promise; approve( - spender: string, - amount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + spender: PromiseOrValue, + amount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - balanceOf(account: string, overrides?: CallOverrides): Promise; + balanceOf( + account: PromiseOrValue, + overrides?: CallOverrides + ): Promise; totalSupply(overrides?: CallOverrides): Promise; transfer( - to: string, - amount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + to: PromiseOrValue, + amount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; transferFrom( - from: string, - to: string, - amount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + from: PromiseOrValue, + to: PromiseOrValue, + amount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; }; populateTransaction: { allowance( - owner: string, - spender: string, + owner: PromiseOrValue, + spender: PromiseOrValue, overrides?: CallOverrides ): Promise; approve( - spender: string, - amount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + spender: PromiseOrValue, + amount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; balanceOf( - account: string, + account: PromiseOrValue, overrides?: CallOverrides ): Promise; totalSupply(overrides?: CallOverrides): Promise; transfer( - to: string, - amount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + to: PromiseOrValue, + amount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; transferFrom( - from: string, - to: string, - amount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + from: PromiseOrValue, + to: PromiseOrValue, + amount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; }; } diff --git a/src/contracts/@openzeppelin/contracts/token/ERC721/IERC721.ts b/src/contracts/@openzeppelin/contracts/token/ERC721/IERC721.ts index 4f7419c1..62aed194 100644 --- a/src/contracts/@openzeppelin/contracts/token/ERC721/IERC721.ts +++ b/src/contracts/@openzeppelin/contracts/token/ERC721/IERC721.ts @@ -24,6 +24,7 @@ import type { TypedEvent, TypedListener, OnEvent, + PromiseOrValue, } from "../../../../common"; export interface IERC721Interface extends utils.Interface { @@ -56,40 +57,56 @@ export interface IERC721Interface extends utils.Interface { encodeFunctionData( functionFragment: "approve", - values: [string, BigNumberish] + values: [PromiseOrValue, PromiseOrValue] + ): string; + encodeFunctionData( + functionFragment: "balanceOf", + values: [PromiseOrValue] ): string; - encodeFunctionData(functionFragment: "balanceOf", values: [string]): string; encodeFunctionData( functionFragment: "getApproved", - values: [BigNumberish] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "isApprovedForAll", - values: [string, string] + values: [PromiseOrValue, PromiseOrValue] ): string; encodeFunctionData( functionFragment: "ownerOf", - values: [BigNumberish] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "safeTransferFrom(address,address,uint256)", - values: [string, string, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "safeTransferFrom(address,address,uint256,bytes)", - values: [string, string, BigNumberish, BytesLike] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "setApprovalForAll", - values: [string, boolean] + values: [PromiseOrValue, PromiseOrValue] ): string; encodeFunctionData( functionFragment: "supportsInterface", - values: [BytesLike] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "transferFrom", - values: [string, string, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; decodeFunctionResult(functionFragment: "approve", data: BytesLike): Result; @@ -199,329 +216,344 @@ export interface IERC721 extends BaseContract { functions: { approve( - to: string, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + to: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; balanceOf( - owner: string, + owner: PromiseOrValue, overrides?: CallOverrides ): Promise<[BigNumber] & { balance: BigNumber }>; getApproved( - tokenId: BigNumberish, + tokenId: PromiseOrValue, overrides?: CallOverrides ): Promise<[string] & { operator: string }>; isApprovedForAll( - owner: string, - operator: string, + owner: PromiseOrValue, + operator: PromiseOrValue, overrides?: CallOverrides ): Promise<[boolean]>; ownerOf( - tokenId: BigNumberish, + tokenId: PromiseOrValue, overrides?: CallOverrides ): Promise<[string] & { owner: string }>; "safeTransferFrom(address,address,uint256)"( - from: string, - to: string, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + from: PromiseOrValue, + to: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; "safeTransferFrom(address,address,uint256,bytes)"( - from: string, - to: string, - tokenId: BigNumberish, - data: BytesLike, - overrides?: Overrides & { from?: string | Promise } + from: PromiseOrValue, + to: PromiseOrValue, + tokenId: PromiseOrValue, + data: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; setApprovalForAll( - operator: string, - _approved: boolean, - overrides?: Overrides & { from?: string | Promise } + operator: PromiseOrValue, + _approved: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; supportsInterface( - interfaceId: BytesLike, + interfaceId: PromiseOrValue, overrides?: CallOverrides ): Promise<[boolean]>; transferFrom( - from: string, - to: string, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + from: PromiseOrValue, + to: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; }; approve( - to: string, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + to: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - balanceOf(owner: string, overrides?: CallOverrides): Promise; + balanceOf( + owner: PromiseOrValue, + overrides?: CallOverrides + ): Promise; getApproved( - tokenId: BigNumberish, + tokenId: PromiseOrValue, overrides?: CallOverrides ): Promise; isApprovedForAll( - owner: string, - operator: string, + owner: PromiseOrValue, + operator: PromiseOrValue, overrides?: CallOverrides ): Promise; - ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + ownerOf( + tokenId: PromiseOrValue, + overrides?: CallOverrides + ): Promise; "safeTransferFrom(address,address,uint256)"( - from: string, - to: string, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + from: PromiseOrValue, + to: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; "safeTransferFrom(address,address,uint256,bytes)"( - from: string, - to: string, - tokenId: BigNumberish, - data: BytesLike, - overrides?: Overrides & { from?: string | Promise } + from: PromiseOrValue, + to: PromiseOrValue, + tokenId: PromiseOrValue, + data: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; setApprovalForAll( - operator: string, - _approved: boolean, - overrides?: Overrides & { from?: string | Promise } + operator: PromiseOrValue, + _approved: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; supportsInterface( - interfaceId: BytesLike, + interfaceId: PromiseOrValue, overrides?: CallOverrides ): Promise; transferFrom( - from: string, - to: string, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + from: PromiseOrValue, + to: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; callStatic: { approve( - to: string, - tokenId: BigNumberish, + to: PromiseOrValue, + tokenId: PromiseOrValue, overrides?: CallOverrides ): Promise; - balanceOf(owner: string, overrides?: CallOverrides): Promise; + balanceOf( + owner: PromiseOrValue, + overrides?: CallOverrides + ): Promise; getApproved( - tokenId: BigNumberish, + tokenId: PromiseOrValue, overrides?: CallOverrides ): Promise; isApprovedForAll( - owner: string, - operator: string, + owner: PromiseOrValue, + operator: PromiseOrValue, overrides?: CallOverrides ): Promise; - ownerOf(tokenId: BigNumberish, overrides?: CallOverrides): Promise; + ownerOf( + tokenId: PromiseOrValue, + overrides?: CallOverrides + ): Promise; "safeTransferFrom(address,address,uint256)"( - from: string, - to: string, - tokenId: BigNumberish, + from: PromiseOrValue, + to: PromiseOrValue, + tokenId: PromiseOrValue, overrides?: CallOverrides ): Promise; "safeTransferFrom(address,address,uint256,bytes)"( - from: string, - to: string, - tokenId: BigNumberish, - data: BytesLike, + from: PromiseOrValue, + to: PromiseOrValue, + tokenId: PromiseOrValue, + data: PromiseOrValue, overrides?: CallOverrides ): Promise; setApprovalForAll( - operator: string, - _approved: boolean, + operator: PromiseOrValue, + _approved: PromiseOrValue, overrides?: CallOverrides ): Promise; supportsInterface( - interfaceId: BytesLike, + interfaceId: PromiseOrValue, overrides?: CallOverrides ): Promise; transferFrom( - from: string, - to: string, - tokenId: BigNumberish, + from: PromiseOrValue, + to: PromiseOrValue, + tokenId: PromiseOrValue, overrides?: CallOverrides ): Promise; }; filters: { "Approval(address,address,uint256)"( - owner?: string | null, - approved?: string | null, - tokenId?: BigNumberish | null + owner?: PromiseOrValue | null, + approved?: PromiseOrValue | null, + tokenId?: PromiseOrValue | null ): ApprovalEventFilter; Approval( - owner?: string | null, - approved?: string | null, - tokenId?: BigNumberish | null + owner?: PromiseOrValue | null, + approved?: PromiseOrValue | null, + tokenId?: PromiseOrValue | null ): ApprovalEventFilter; "ApprovalForAll(address,address,bool)"( - owner?: string | null, - operator?: string | null, + owner?: PromiseOrValue | null, + operator?: PromiseOrValue | null, approved?: null ): ApprovalForAllEventFilter; ApprovalForAll( - owner?: string | null, - operator?: string | null, + owner?: PromiseOrValue | null, + operator?: PromiseOrValue | null, approved?: null ): ApprovalForAllEventFilter; "Transfer(address,address,uint256)"( - from?: string | null, - to?: string | null, - tokenId?: BigNumberish | null + from?: PromiseOrValue | null, + to?: PromiseOrValue | null, + tokenId?: PromiseOrValue | null ): TransferEventFilter; Transfer( - from?: string | null, - to?: string | null, - tokenId?: BigNumberish | null + from?: PromiseOrValue | null, + to?: PromiseOrValue | null, + tokenId?: PromiseOrValue | null ): TransferEventFilter; }; estimateGas: { approve( - to: string, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + to: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - balanceOf(owner: string, overrides?: CallOverrides): Promise; + balanceOf( + owner: PromiseOrValue, + overrides?: CallOverrides + ): Promise; getApproved( - tokenId: BigNumberish, + tokenId: PromiseOrValue, overrides?: CallOverrides ): Promise; isApprovedForAll( - owner: string, - operator: string, + owner: PromiseOrValue, + operator: PromiseOrValue, overrides?: CallOverrides ): Promise; ownerOf( - tokenId: BigNumberish, + tokenId: PromiseOrValue, overrides?: CallOverrides ): Promise; "safeTransferFrom(address,address,uint256)"( - from: string, - to: string, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + from: PromiseOrValue, + to: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; "safeTransferFrom(address,address,uint256,bytes)"( - from: string, - to: string, - tokenId: BigNumberish, - data: BytesLike, - overrides?: Overrides & { from?: string | Promise } + from: PromiseOrValue, + to: PromiseOrValue, + tokenId: PromiseOrValue, + data: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; setApprovalForAll( - operator: string, - _approved: boolean, - overrides?: Overrides & { from?: string | Promise } + operator: PromiseOrValue, + _approved: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; supportsInterface( - interfaceId: BytesLike, + interfaceId: PromiseOrValue, overrides?: CallOverrides ): Promise; transferFrom( - from: string, - to: string, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + from: PromiseOrValue, + to: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; }; populateTransaction: { approve( - to: string, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + to: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; balanceOf( - owner: string, + owner: PromiseOrValue, overrides?: CallOverrides ): Promise; getApproved( - tokenId: BigNumberish, + tokenId: PromiseOrValue, overrides?: CallOverrides ): Promise; isApprovedForAll( - owner: string, - operator: string, + owner: PromiseOrValue, + operator: PromiseOrValue, overrides?: CallOverrides ): Promise; ownerOf( - tokenId: BigNumberish, + tokenId: PromiseOrValue, overrides?: CallOverrides ): Promise; "safeTransferFrom(address,address,uint256)"( - from: string, - to: string, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + from: PromiseOrValue, + to: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; "safeTransferFrom(address,address,uint256,bytes)"( - from: string, - to: string, - tokenId: BigNumberish, - data: BytesLike, - overrides?: Overrides & { from?: string | Promise } + from: PromiseOrValue, + to: PromiseOrValue, + tokenId: PromiseOrValue, + data: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; setApprovalForAll( - operator: string, - _approved: boolean, - overrides?: Overrides & { from?: string | Promise } + operator: PromiseOrValue, + _approved: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; supportsInterface( - interfaceId: BytesLike, + interfaceId: PromiseOrValue, overrides?: CallOverrides ): Promise; transferFrom( - from: string, - to: string, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + from: PromiseOrValue, + to: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; }; } diff --git a/src/contracts/@openzeppelin/contracts/utils/introspection/IERC165.ts b/src/contracts/@openzeppelin/contracts/utils/introspection/IERC165.ts index bfd45609..010603d4 100644 --- a/src/contracts/@openzeppelin/contracts/utils/introspection/IERC165.ts +++ b/src/contracts/@openzeppelin/contracts/utils/introspection/IERC165.ts @@ -17,6 +17,7 @@ import type { TypedEvent, TypedListener, OnEvent, + PromiseOrValue, } from "../../../../common"; export interface IERC165Interface extends utils.Interface { @@ -28,7 +29,7 @@ export interface IERC165Interface extends utils.Interface { encodeFunctionData( functionFragment: "supportsInterface", - values: [BytesLike] + values: [PromiseOrValue] ): string; decodeFunctionResult( @@ -67,19 +68,19 @@ export interface IERC165 extends BaseContract { functions: { supportsInterface( - interfaceId: BytesLike, + interfaceId: PromiseOrValue, overrides?: CallOverrides ): Promise<[boolean]>; }; supportsInterface( - interfaceId: BytesLike, + interfaceId: PromiseOrValue, overrides?: CallOverrides ): Promise; callStatic: { supportsInterface( - interfaceId: BytesLike, + interfaceId: PromiseOrValue, overrides?: CallOverrides ): Promise; }; @@ -88,14 +89,14 @@ export interface IERC165 extends BaseContract { estimateGas: { supportsInterface( - interfaceId: BytesLike, + interfaceId: PromiseOrValue, overrides?: CallOverrides ): Promise; }; populateTransaction: { supportsInterface( - interfaceId: BytesLike, + interfaceId: PromiseOrValue, overrides?: CallOverrides ): Promise; }; diff --git a/src/contracts/common.ts b/src/contracts/common.ts index 2fc40c7f..4c90b08b 100644 --- a/src/contracts/common.ts +++ b/src/contracts/common.ts @@ -42,3 +42,5 @@ export type GetContractTypeFromFactory = F extends MinEthersFactory< export type GetARGsTypeFromFactory = F extends MinEthersFactory ? Parameters : never; + +export type PromiseOrValue = T | Promise; diff --git a/src/contracts/contracts/Registration.ts b/src/contracts/contracts/Registration.ts deleted file mode 100644 index 1f443458..00000000 --- a/src/contracts/contracts/Registration.ts +++ /dev/null @@ -1,471 +0,0 @@ -/* Autogenerated file. Do not edit manually. */ -/* tslint:disable */ -/* eslint-disable */ -import type { - BaseContract, - BigNumber, - BigNumberish, - BytesLike, - CallOverrides, - ContractTransaction, - Overrides, - PopulatedTransaction, - Signer, - utils, -} from "ethers"; -import type { FunctionFragment, Result } from "@ethersproject/abi"; -import type { Listener, Provider } from "@ethersproject/providers"; -import type { - TypedEventFilter, - TypedEvent, - TypedListener, - OnEvent, -} from "../common"; - -export interface RegistrationInterface extends utils.Interface { - functions: { - "imx()": FunctionFragment; - "isRegistered(uint256)": FunctionFragment; - "registerAndDepositNft(address,uint256,bytes,uint256,uint256,uint256)": FunctionFragment; - "registerAndWithdraw(address,uint256,bytes,uint256)": FunctionFragment; - "registerAndWithdrawNft(address,uint256,bytes,uint256,uint256)": FunctionFragment; - "registerAndWithdrawNftTo(address,uint256,bytes,uint256,uint256,address)": FunctionFragment; - "registerAndWithdrawTo(address,uint256,bytes,uint256,address)": FunctionFragment; - "regsiterAndWithdrawAndMint(address,uint256,bytes,uint256,bytes)": FunctionFragment; - }; - - getFunction( - nameOrSignatureOrTopic: - | "imx" - | "isRegistered" - | "registerAndDepositNft" - | "registerAndWithdraw" - | "registerAndWithdrawNft" - | "registerAndWithdrawNftTo" - | "registerAndWithdrawTo" - | "regsiterAndWithdrawAndMint" - ): FunctionFragment; - - encodeFunctionData(functionFragment: "imx", values?: undefined): string; - encodeFunctionData( - functionFragment: "isRegistered", - values: [BigNumberish] - ): string; - encodeFunctionData( - functionFragment: "registerAndDepositNft", - values: [ - string, - BigNumberish, - BytesLike, - BigNumberish, - BigNumberish, - BigNumberish - ] - ): string; - encodeFunctionData( - functionFragment: "registerAndWithdraw", - values: [string, BigNumberish, BytesLike, BigNumberish] - ): string; - encodeFunctionData( - functionFragment: "registerAndWithdrawNft", - values: [string, BigNumberish, BytesLike, BigNumberish, BigNumberish] - ): string; - encodeFunctionData( - functionFragment: "registerAndWithdrawNftTo", - values: [ - string, - BigNumberish, - BytesLike, - BigNumberish, - BigNumberish, - string - ] - ): string; - encodeFunctionData( - functionFragment: "registerAndWithdrawTo", - values: [string, BigNumberish, BytesLike, BigNumberish, string] - ): string; - encodeFunctionData( - functionFragment: "regsiterAndWithdrawAndMint", - values: [string, BigNumberish, BytesLike, BigNumberish, BytesLike] - ): string; - - decodeFunctionResult(functionFragment: "imx", data: BytesLike): Result; - decodeFunctionResult( - functionFragment: "isRegistered", - data: BytesLike - ): Result; - decodeFunctionResult( - functionFragment: "registerAndDepositNft", - data: BytesLike - ): Result; - decodeFunctionResult( - functionFragment: "registerAndWithdraw", - data: BytesLike - ): Result; - decodeFunctionResult( - functionFragment: "registerAndWithdrawNft", - data: BytesLike - ): Result; - decodeFunctionResult( - functionFragment: "registerAndWithdrawNftTo", - data: BytesLike - ): Result; - decodeFunctionResult( - functionFragment: "registerAndWithdrawTo", - data: BytesLike - ): Result; - decodeFunctionResult( - functionFragment: "regsiterAndWithdrawAndMint", - data: BytesLike - ): Result; - - events: {}; -} - -export interface Registration extends BaseContract { - connect(signerOrProvider: Signer | Provider | string): this; - attach(addressOrName: string): this; - deployed(): Promise; - - interface: RegistrationInterface; - - queryFilter( - event: TypedEventFilter, - fromBlockOrBlockhash?: string | number | undefined, - toBlock?: string | number | undefined - ): Promise>; - - listeners( - eventFilter?: TypedEventFilter - ): Array>; - listeners(eventName?: string): Array; - removeAllListeners( - eventFilter: TypedEventFilter - ): this; - removeAllListeners(eventName?: string): this; - off: OnEvent; - on: OnEvent; - once: OnEvent; - removeListener: OnEvent; - - functions: { - imx(overrides?: CallOverrides): Promise<[string]>; - - isRegistered( - starkKey: BigNumberish, - overrides?: CallOverrides - ): Promise<[boolean]>; - - registerAndDepositNft( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - registerAndWithdraw( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - registerAndWithdrawNft( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - registerAndWithdrawNftTo( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - tokenId: BigNumberish, - recipient: string, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - registerAndWithdrawTo( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - recipient: string, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - regsiterAndWithdrawAndMint( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - mintingBlob: BytesLike, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - }; - - imx(overrides?: CallOverrides): Promise; - - isRegistered( - starkKey: BigNumberish, - overrides?: CallOverrides - ): Promise; - - registerAndDepositNft( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - registerAndWithdraw( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - registerAndWithdrawNft( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - registerAndWithdrawNftTo( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - tokenId: BigNumberish, - recipient: string, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - registerAndWithdrawTo( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - recipient: string, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - regsiterAndWithdrawAndMint( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - mintingBlob: BytesLike, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - callStatic: { - imx(overrides?: CallOverrides): Promise; - - isRegistered( - starkKey: BigNumberish, - overrides?: CallOverrides - ): Promise; - - registerAndDepositNft( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: CallOverrides - ): Promise; - - registerAndWithdraw( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - overrides?: CallOverrides - ): Promise; - - registerAndWithdrawNft( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - tokenId: BigNumberish, - overrides?: CallOverrides - ): Promise; - - registerAndWithdrawNftTo( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - tokenId: BigNumberish, - recipient: string, - overrides?: CallOverrides - ): Promise; - - registerAndWithdrawTo( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - recipient: string, - overrides?: CallOverrides - ): Promise; - - regsiterAndWithdrawAndMint( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - mintingBlob: BytesLike, - overrides?: CallOverrides - ): Promise; - }; - - filters: {}; - - estimateGas: { - imx(overrides?: CallOverrides): Promise; - - isRegistered( - starkKey: BigNumberish, - overrides?: CallOverrides - ): Promise; - - registerAndDepositNft( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - registerAndWithdraw( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - registerAndWithdrawNft( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - registerAndWithdrawNftTo( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - tokenId: BigNumberish, - recipient: string, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - registerAndWithdrawTo( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - recipient: string, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - regsiterAndWithdrawAndMint( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - mintingBlob: BytesLike, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - }; - - populateTransaction: { - imx(overrides?: CallOverrides): Promise; - - isRegistered( - starkKey: BigNumberish, - overrides?: CallOverrides - ): Promise; - - registerAndDepositNft( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - registerAndWithdraw( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - registerAndWithdrawNft( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - registerAndWithdrawNftTo( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - tokenId: BigNumberish, - recipient: string, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - registerAndWithdrawTo( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - recipient: string, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - - regsiterAndWithdrawAndMint( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - mintingBlob: BytesLike, - overrides?: Overrides & { from?: string | Promise } - ): Promise; - }; -} diff --git a/src/contracts/contracts/index.ts b/src/contracts/contracts/index.ts index c46f6e86..f9505274 100644 --- a/src/contracts/contracts/index.ts +++ b/src/contracts/contracts/index.ts @@ -1,6 +1,7 @@ /* Autogenerated file. Do not edit manually. */ /* tslint:disable */ /* eslint-disable */ -export type { StarkV3 } from "./StarkV3"; -export type { StarkV4 } from "./StarkV4"; -export type { Registration } from "./Registration"; +import type * as v3 from "./v3"; +export type { v3 }; +import type * as v4 from "./v4"; +export type { v4 }; diff --git a/src/contracts/contracts/StarkV3.ts b/src/contracts/contracts/v3/Core.ts similarity index 55% rename from src/contracts/contracts/StarkV3.ts rename to src/contracts/contracts/v3/Core.ts index 96f3bf07..cb866ec2 100644 --- a/src/contracts/contracts/StarkV3.ts +++ b/src/contracts/contracts/v3/Core.ts @@ -25,9 +25,10 @@ import type { TypedEvent, TypedListener, OnEvent, -} from "../common"; + PromiseOrValue, +} from "../../common"; -export interface StarkV3Interface extends utils.Interface { +export interface CoreInterface extends utils.Interface { functions: { "announceAvailabilityVerifierRemovalIntent(address)": FunctionFragment; "announceVerifierRemovalIntent(address)": FunctionFragment; @@ -161,75 +162,124 @@ export interface StarkV3Interface extends utils.Interface { encodeFunctionData( functionFragment: "announceAvailabilityVerifierRemovalIntent", - values: [string] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "announceVerifierRemovalIntent", - values: [string] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "deposit(uint256,uint256,uint256)", - values: [BigNumberish, BigNumberish, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "deposit(uint256,uint256,uint256,uint256)", - values: [BigNumberish, BigNumberish, BigNumberish, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "depositCancel", - values: [BigNumberish, BigNumberish, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "depositERC20", - values: [BigNumberish, BigNumberish, BigNumberish, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "depositEth", - values: [BigNumberish, BigNumberish, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "depositNft", - values: [BigNumberish, BigNumberish, BigNumberish, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "depositNftReclaim", - values: [BigNumberish, BigNumberish, BigNumberish, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "depositReclaim", - values: [BigNumberish, BigNumberish, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "escape", - values: [BigNumberish, BigNumberish, BigNumberish, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "freezeRequest", - values: [BigNumberish, BigNumberish] + values: [PromiseOrValue, PromiseOrValue] ): string; encodeFunctionData( functionFragment: "fullWithdrawalRequest", - values: [BigNumberish, BigNumberish] + values: [PromiseOrValue, PromiseOrValue] ): string; encodeFunctionData( functionFragment: "getAssetInfo", - values: [BigNumberish] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "getCancellationRequest", - values: [BigNumberish, BigNumberish, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "getDepositBalance", - values: [BigNumberish, BigNumberish, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "getEthKey", - values: [BigNumberish] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "getFullWithdrawalRequest", - values: [BigNumberish, BigNumberish] + values: [PromiseOrValue, PromiseOrValue] ): string; encodeFunctionData( functionFragment: "getLastBatchId", @@ -245,11 +295,15 @@ export interface StarkV3Interface extends utils.Interface { ): string; encodeFunctionData( functionFragment: "getQuantizedDepositBalance", - values: [BigNumberish, BigNumberish, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "getQuantum", - values: [BigNumberish] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "getRegisteredAvailabilityVerifiers", @@ -273,20 +327,29 @@ export interface StarkV3Interface extends utils.Interface { ): string; encodeFunctionData( functionFragment: "getWithdrawalBalance", - values: [BigNumberish, BigNumberish] + values: [PromiseOrValue, PromiseOrValue] ): string; encodeFunctionData( functionFragment: "isAvailabilityVerifier", - values: [string] + values: [PromiseOrValue] ): string; encodeFunctionData(functionFragment: "isFrozen", values?: undefined): string; - encodeFunctionData(functionFragment: "isOperator", values: [string]): string; + encodeFunctionData( + functionFragment: "isOperator", + values: [PromiseOrValue] + ): string; encodeFunctionData( functionFragment: "isTokenAdmin", - values: [string] + values: [PromiseOrValue] + ): string; + encodeFunctionData( + functionFragment: "isUserAdmin", + values: [PromiseOrValue] + ): string; + encodeFunctionData( + functionFragment: "isVerifier", + values: [PromiseOrValue] ): string; - encodeFunctionData(functionFragment: "isUserAdmin", values: [string]): string; - encodeFunctionData(functionFragment: "isVerifier", values: [string]): string; encodeFunctionData( functionFragment: "mainAcceptGovernance", values?: undefined @@ -297,107 +360,139 @@ export interface StarkV3Interface extends utils.Interface { ): string; encodeFunctionData( functionFragment: "mainIsGovernor", - values: [string] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "mainNominateNewGovernor", - values: [string] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "mainRemoveGovernor", - values: [string] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "onERC721Received", - values: [string, string, BigNumberish, BytesLike] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "registerAndDepositERC20", values: [ - string, - BigNumberish, - BytesLike, - BigNumberish, - BigNumberish, - BigNumberish + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue ] ): string; encodeFunctionData( functionFragment: "registerAndDepositEth", - values: [string, BigNumberish, BytesLike, BigNumberish, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "registerAvailabilityVerifier", - values: [string, string] + values: [PromiseOrValue, PromiseOrValue] ): string; encodeFunctionData( functionFragment: "registerOperator", - values: [string] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "registerToken", - values: [BigNumberish, BytesLike] + values: [PromiseOrValue, PromiseOrValue] ): string; encodeFunctionData( functionFragment: "registerTokenAdmin", - values: [string] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "registerUser", - values: [string, BigNumberish, BytesLike] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "registerUserAdmin", - values: [string] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "registerVerifier", - values: [string, string] + values: [PromiseOrValue, PromiseOrValue] ): string; encodeFunctionData( functionFragment: "removeAvailabilityVerifier", - values: [string] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "removeVerifier", - values: [string] + values: [PromiseOrValue] ): string; encodeFunctionData(functionFragment: "unFreeze", values?: undefined): string; encodeFunctionData( functionFragment: "unregisterOperator", - values: [string] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "unregisterTokenAdmin", - values: [string] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "unregisterUserAdmin", - values: [string] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "updateState", - values: [BigNumberish[], BigNumberish[]] + values: [PromiseOrValue[], PromiseOrValue[]] ): string; encodeFunctionData( functionFragment: "withdraw", - values: [BigNumberish, BigNumberish] + values: [PromiseOrValue, PromiseOrValue] ): string; encodeFunctionData( functionFragment: "withdrawAndMint", - values: [BigNumberish, BigNumberish, BytesLike] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "withdrawNft", - values: [BigNumberish, BigNumberish, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "withdrawNftTo", - values: [BigNumberish, BigNumberish, BigNumberish, string] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "withdrawTo", - values: [BigNumberish, BigNumberish, string] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; decodeFunctionResult( @@ -864,12 +959,12 @@ export type LogWithdrawalPerformedEvent = TypedEvent< export type LogWithdrawalPerformedEventFilter = TypedEventFilter; -export interface StarkV3 extends BaseContract { +export interface Core extends BaseContract { connect(signerOrProvider: Signer | Provider | string): this; attach(addressOrName: string): this; deployed(): Promise; - interface: StarkV3Interface; + interface: CoreInterface; queryFilter( event: TypedEventFilter, @@ -892,122 +987,122 @@ export interface StarkV3 extends BaseContract { functions: { announceAvailabilityVerifierRemovalIntent( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; announceVerifierRemovalIntent( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; "deposit(uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; "deposit(uint256,uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositCancel( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositERC20( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositEth( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; depositNft( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositNftReclaim( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositReclaim( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; escape( - starkKey: BigNumberish, - vaultId: BigNumberish, - assetId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + assetId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; freezeRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; fullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; getAssetInfo( - assetType: BigNumberish, + assetType: PromiseOrValue, overrides?: CallOverrides ): Promise<[string] & { assetInfo: string }>; getCancellationRequest( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise<[BigNumber] & { request: BigNumber }>; getDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise<[BigNumber] & { balance: BigNumber }>; getEthKey( - starkKey: BigNumberish, + starkKey: PromiseOrValue, overrides?: CallOverrides ): Promise<[string] & { ethKey: string }>; getFullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise<[BigNumber] & { res: BigNumber }>; @@ -1024,23 +1119,23 @@ export interface StarkV3 extends BaseContract { ): Promise<[BigNumber] & { height: BigNumber }>; getQuantizedDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise<[BigNumber] & { balance: BigNumber }>; getQuantum( - presumedAssetType: BigNumberish, + presumedAssetType: PromiseOrValue, overrides?: CallOverrides ): Promise<[BigNumber] & { quantum: BigNumber }>; getRegisteredAvailabilityVerifiers( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; getRegisteredVerifiers( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; getSequenceNumber( @@ -1056,315 +1151,318 @@ export interface StarkV3 extends BaseContract { ): Promise<[BigNumber] & { height: BigNumber }>; getWithdrawalBalance( - ownerKey: BigNumberish, - assetId: BigNumberish, + ownerKey: PromiseOrValue, + assetId: PromiseOrValue, overrides?: CallOverrides ): Promise<[BigNumber] & { balance: BigNumber }>; isAvailabilityVerifier( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isFrozen( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isOperator( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isTokenAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isUserAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isVerifier( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainAcceptGovernance( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainCancelNomination( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainIsGovernor( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainNominateNewGovernor( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainRemoveGovernor( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; onERC721Received( - arg0: string, - arg1: string, - arg2: BigNumberish, - arg3: BytesLike, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + arg3: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerAndDepositERC20( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerAndDepositEth( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string | Promise } + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; registerAvailabilityVerifier( - arg0: string, - arg1: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerOperator( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerToken( - arg0: BigNumberish, - arg1: BytesLike, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerTokenAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerUser( - arg0: string, - arg1: BigNumberish, - arg2: BytesLike, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerUserAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerVerifier( - arg0: string, - arg1: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; removeAvailabilityVerifier( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; removeVerifier( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; unFreeze( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; unregisterOperator( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; unregisterTokenAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; unregisterUserAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; updateState( - publicInput: BigNumberish[], - applicationData: BigNumberish[], - overrides?: Overrides & { from?: string | Promise } + publicInput: PromiseOrValue[], + applicationData: PromiseOrValue[], + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdraw( - ownerKey: BigNumberish, - assetType: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawAndMint( - ownerKey: BigNumberish, - assetType: BigNumberish, - mintingBlob: BytesLike, - overrides?: Overrides & { from?: string | Promise } + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawNft( - ownerKey: BigNumberish, - assetType: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawNftTo( - arg0: BigNumberish, - arg1: BigNumberish, - arg2: BigNumberish, - arg3: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + arg3: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawTo( - arg0: BigNumberish, - arg1: BigNumberish, - arg2: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; }; announceAvailabilityVerifierRemovalIntent( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; announceVerifierRemovalIntent( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; "deposit(uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; "deposit(uint256,uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositCancel( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositERC20( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositEth( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; depositNft( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositNftReclaim( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositReclaim( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; escape( - starkKey: BigNumberish, - vaultId: BigNumberish, - assetId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + assetId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; freezeRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; fullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; getAssetInfo( - assetType: BigNumberish, + assetType: PromiseOrValue, overrides?: CallOverrides ): Promise; getCancellationRequest( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; - getEthKey(starkKey: BigNumberish, overrides?: CallOverrides): Promise; + getEthKey( + starkKey: PromiseOrValue, + overrides?: CallOverrides + ): Promise; getFullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; @@ -1375,23 +1473,23 @@ export interface StarkV3 extends BaseContract { getOrderTreeHeight(overrides?: CallOverrides): Promise; getQuantizedDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getQuantum( - presumedAssetType: BigNumberish, + presumedAssetType: PromiseOrValue, overrides?: CallOverrides ): Promise; getRegisteredAvailabilityVerifiers( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; getRegisteredVerifiers( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; getSequenceNumber(overrides?: CallOverrides): Promise; @@ -1401,318 +1499,318 @@ export interface StarkV3 extends BaseContract { getVaultTreeHeight(overrides?: CallOverrides): Promise; getWithdrawalBalance( - ownerKey: BigNumberish, - assetId: BigNumberish, + ownerKey: PromiseOrValue, + assetId: PromiseOrValue, overrides?: CallOverrides ): Promise; isAvailabilityVerifier( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isFrozen( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isOperator( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isTokenAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isUserAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isVerifier( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainAcceptGovernance( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainCancelNomination( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainIsGovernor( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainNominateNewGovernor( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainRemoveGovernor( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; onERC721Received( - arg0: string, - arg1: string, - arg2: BigNumberish, - arg3: BytesLike, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + arg3: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerAndDepositERC20( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerAndDepositEth( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string | Promise } + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; registerAvailabilityVerifier( - arg0: string, - arg1: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerOperator( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerToken( - arg0: BigNumberish, - arg1: BytesLike, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerTokenAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerUser( - arg0: string, - arg1: BigNumberish, - arg2: BytesLike, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerUserAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerVerifier( - arg0: string, - arg1: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; removeAvailabilityVerifier( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; removeVerifier( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; unFreeze( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; unregisterOperator( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; unregisterTokenAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; unregisterUserAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; updateState( - publicInput: BigNumberish[], - applicationData: BigNumberish[], - overrides?: Overrides & { from?: string | Promise } + publicInput: PromiseOrValue[], + applicationData: PromiseOrValue[], + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdraw( - ownerKey: BigNumberish, - assetType: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawAndMint( - ownerKey: BigNumberish, - assetType: BigNumberish, - mintingBlob: BytesLike, - overrides?: Overrides & { from?: string | Promise } + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawNft( - ownerKey: BigNumberish, - assetType: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawNftTo( - arg0: BigNumberish, - arg1: BigNumberish, - arg2: BigNumberish, - arg3: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + arg3: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawTo( - arg0: BigNumberish, - arg1: BigNumberish, - arg2: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; callStatic: { announceAvailabilityVerifierRemovalIntent( - arg0: string, + arg0: PromiseOrValue, overrides?: CallOverrides ): Promise; announceVerifierRemovalIntent( - arg0: string, + arg0: PromiseOrValue, overrides?: CallOverrides ): Promise; "deposit(uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; "deposit(uint256,uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, overrides?: CallOverrides ): Promise; depositCancel( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; depositERC20( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, overrides?: CallOverrides ): Promise; depositEth( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; depositNft( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, overrides?: CallOverrides ): Promise; depositNftReclaim( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, overrides?: CallOverrides ): Promise; depositReclaim( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; escape( - starkKey: BigNumberish, - vaultId: BigNumberish, - assetId: BigNumberish, - quantizedAmount: BigNumberish, + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + assetId: PromiseOrValue, + quantizedAmount: PromiseOrValue, overrides?: CallOverrides ): Promise; freezeRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; fullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getAssetInfo( - assetType: BigNumberish, + assetType: PromiseOrValue, overrides?: CallOverrides ): Promise; getCancellationRequest( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getEthKey( - starkKey: BigNumberish, + starkKey: PromiseOrValue, overrides?: CallOverrides ): Promise; getFullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; @@ -1723,14 +1821,14 @@ export interface StarkV3 extends BaseContract { getOrderTreeHeight(overrides?: CallOverrides): Promise; getQuantizedDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getQuantum( - presumedAssetType: BigNumberish, + presumedAssetType: PromiseOrValue, overrides?: CallOverrides ): Promise; @@ -1747,153 +1845,189 @@ export interface StarkV3 extends BaseContract { getVaultTreeHeight(overrides?: CallOverrides): Promise; getWithdrawalBalance( - ownerKey: BigNumberish, - assetId: BigNumberish, + ownerKey: PromiseOrValue, + assetId: PromiseOrValue, overrides?: CallOverrides ): Promise; isAvailabilityVerifier( - arg0: string, + arg0: PromiseOrValue, overrides?: CallOverrides ): Promise; isFrozen(overrides?: CallOverrides): Promise; - isOperator(arg0: string, overrides?: CallOverrides): Promise; + isOperator( + arg0: PromiseOrValue, + overrides?: CallOverrides + ): Promise; - isTokenAdmin(arg0: string, overrides?: CallOverrides): Promise; + isTokenAdmin( + arg0: PromiseOrValue, + overrides?: CallOverrides + ): Promise; - isUserAdmin(arg0: string, overrides?: CallOverrides): Promise; + isUserAdmin( + arg0: PromiseOrValue, + overrides?: CallOverrides + ): Promise; - isVerifier(arg0: string, overrides?: CallOverrides): Promise; + isVerifier( + arg0: PromiseOrValue, + overrides?: CallOverrides + ): Promise; mainAcceptGovernance(overrides?: CallOverrides): Promise; mainCancelNomination(overrides?: CallOverrides): Promise; - mainIsGovernor(arg0: string, overrides?: CallOverrides): Promise; + mainIsGovernor( + arg0: PromiseOrValue, + overrides?: CallOverrides + ): Promise; mainNominateNewGovernor( - arg0: string, + arg0: PromiseOrValue, overrides?: CallOverrides ): Promise; - mainRemoveGovernor(arg0: string, overrides?: CallOverrides): Promise; + mainRemoveGovernor( + arg0: PromiseOrValue, + overrides?: CallOverrides + ): Promise; onERC721Received( - arg0: string, - arg1: string, - arg2: BigNumberish, - arg3: BytesLike, + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + arg3: PromiseOrValue, overrides?: CallOverrides ): Promise; registerAndDepositERC20( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, overrides?: CallOverrides ): Promise; registerAndDepositEth( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; registerAvailabilityVerifier( - arg0: string, - arg1: string, + arg0: PromiseOrValue, + arg1: PromiseOrValue, overrides?: CallOverrides ): Promise; - registerOperator(arg0: string, overrides?: CallOverrides): Promise; + registerOperator( + arg0: PromiseOrValue, + overrides?: CallOverrides + ): Promise; registerToken( - arg0: BigNumberish, - arg1: BytesLike, + arg0: PromiseOrValue, + arg1: PromiseOrValue, overrides?: CallOverrides ): Promise; - registerTokenAdmin(arg0: string, overrides?: CallOverrides): Promise; + registerTokenAdmin( + arg0: PromiseOrValue, + overrides?: CallOverrides + ): Promise; registerUser( - arg0: string, - arg1: BigNumberish, - arg2: BytesLike, + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, overrides?: CallOverrides ): Promise; - registerUserAdmin(arg0: string, overrides?: CallOverrides): Promise; + registerUserAdmin( + arg0: PromiseOrValue, + overrides?: CallOverrides + ): Promise; registerVerifier( - arg0: string, - arg1: string, + arg0: PromiseOrValue, + arg1: PromiseOrValue, overrides?: CallOverrides ): Promise; removeAvailabilityVerifier( - arg0: string, + arg0: PromiseOrValue, overrides?: CallOverrides ): Promise; - removeVerifier(arg0: string, overrides?: CallOverrides): Promise; + removeVerifier( + arg0: PromiseOrValue, + overrides?: CallOverrides + ): Promise; unFreeze(overrides?: CallOverrides): Promise; - unregisterOperator(arg0: string, overrides?: CallOverrides): Promise; + unregisterOperator( + arg0: PromiseOrValue, + overrides?: CallOverrides + ): Promise; unregisterTokenAdmin( - arg0: string, + arg0: PromiseOrValue, overrides?: CallOverrides ): Promise; - unregisterUserAdmin(arg0: string, overrides?: CallOverrides): Promise; + unregisterUserAdmin( + arg0: PromiseOrValue, + overrides?: CallOverrides + ): Promise; updateState( - publicInput: BigNumberish[], - applicationData: BigNumberish[], + publicInput: PromiseOrValue[], + applicationData: PromiseOrValue[], overrides?: CallOverrides ): Promise; withdraw( - ownerKey: BigNumberish, - assetType: BigNumberish, + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, overrides?: CallOverrides ): Promise; withdrawAndMint( - ownerKey: BigNumberish, - assetType: BigNumberish, - mintingBlob: BytesLike, + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, overrides?: CallOverrides ): Promise; withdrawNft( - ownerKey: BigNumberish, - assetType: BigNumberish, - tokenId: BigNumberish, + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, overrides?: CallOverrides ): Promise; withdrawNftTo( - arg0: BigNumberish, - arg1: BigNumberish, - arg2: BigNumberish, - arg3: string, + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + arg3: PromiseOrValue, overrides?: CallOverrides ): Promise; withdrawTo( - arg0: BigNumberish, - arg1: BigNumberish, - arg2: string, + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, overrides?: CallOverrides ): Promise; }; @@ -2097,122 +2231,122 @@ export interface StarkV3 extends BaseContract { estimateGas: { announceAvailabilityVerifierRemovalIntent( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; announceVerifierRemovalIntent( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; "deposit(uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; "deposit(uint256,uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositCancel( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositERC20( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositEth( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; depositNft( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositNftReclaim( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositReclaim( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; escape( - starkKey: BigNumberish, - vaultId: BigNumberish, - assetId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + assetId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; freezeRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; fullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; getAssetInfo( - assetType: BigNumberish, + assetType: PromiseOrValue, overrides?: CallOverrides ): Promise; getCancellationRequest( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getEthKey( - starkKey: BigNumberish, + starkKey: PromiseOrValue, overrides?: CallOverrides ): Promise; getFullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; @@ -2223,23 +2357,23 @@ export interface StarkV3 extends BaseContract { getOrderTreeHeight(overrides?: CallOverrides): Promise; getQuantizedDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getQuantum( - presumedAssetType: BigNumberish, + presumedAssetType: PromiseOrValue, overrides?: CallOverrides ): Promise; getRegisteredAvailabilityVerifiers( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; getRegisteredVerifiers( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; getSequenceNumber(overrides?: CallOverrides): Promise; @@ -2249,319 +2383,319 @@ export interface StarkV3 extends BaseContract { getVaultTreeHeight(overrides?: CallOverrides): Promise; getWithdrawalBalance( - ownerKey: BigNumberish, - assetId: BigNumberish, + ownerKey: PromiseOrValue, + assetId: PromiseOrValue, overrides?: CallOverrides ): Promise; isAvailabilityVerifier( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isFrozen( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isOperator( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isTokenAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isUserAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isVerifier( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainAcceptGovernance( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainCancelNomination( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainIsGovernor( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainNominateNewGovernor( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainRemoveGovernor( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; onERC721Received( - arg0: string, - arg1: string, - arg2: BigNumberish, - arg3: BytesLike, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + arg3: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerAndDepositERC20( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerAndDepositEth( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string | Promise } + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; registerAvailabilityVerifier( - arg0: string, - arg1: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerOperator( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerToken( - arg0: BigNumberish, - arg1: BytesLike, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerTokenAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerUser( - arg0: string, - arg1: BigNumberish, - arg2: BytesLike, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerUserAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerVerifier( - arg0: string, - arg1: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; removeAvailabilityVerifier( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; removeVerifier( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; unFreeze( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; unregisterOperator( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; unregisterTokenAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; unregisterUserAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; updateState( - publicInput: BigNumberish[], - applicationData: BigNumberish[], - overrides?: Overrides & { from?: string | Promise } + publicInput: PromiseOrValue[], + applicationData: PromiseOrValue[], + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdraw( - ownerKey: BigNumberish, - assetType: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawAndMint( - ownerKey: BigNumberish, - assetType: BigNumberish, - mintingBlob: BytesLike, - overrides?: Overrides & { from?: string | Promise } + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawNft( - ownerKey: BigNumberish, - assetType: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawNftTo( - arg0: BigNumberish, - arg1: BigNumberish, - arg2: BigNumberish, - arg3: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + arg3: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawTo( - arg0: BigNumberish, - arg1: BigNumberish, - arg2: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; }; populateTransaction: { announceAvailabilityVerifierRemovalIntent( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; announceVerifierRemovalIntent( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; "deposit(uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; "deposit(uint256,uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositCancel( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositERC20( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositEth( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; depositNft( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositNftReclaim( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositReclaim( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; escape( - starkKey: BigNumberish, - vaultId: BigNumberish, - assetId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + assetId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; freezeRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; fullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; getAssetInfo( - assetType: BigNumberish, + assetType: PromiseOrValue, overrides?: CallOverrides ): Promise; getCancellationRequest( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getEthKey( - starkKey: BigNumberish, + starkKey: PromiseOrValue, overrides?: CallOverrides ): Promise; getFullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; @@ -2574,23 +2708,23 @@ export interface StarkV3 extends BaseContract { ): Promise; getQuantizedDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getQuantum( - presumedAssetType: BigNumberish, + presumedAssetType: PromiseOrValue, overrides?: CallOverrides ): Promise; getRegisteredAvailabilityVerifiers( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; getRegisteredVerifiers( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; getSequenceNumber(overrides?: CallOverrides): Promise; @@ -2602,198 +2736,198 @@ export interface StarkV3 extends BaseContract { ): Promise; getWithdrawalBalance( - ownerKey: BigNumberish, - assetId: BigNumberish, + ownerKey: PromiseOrValue, + assetId: PromiseOrValue, overrides?: CallOverrides ): Promise; isAvailabilityVerifier( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isFrozen( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isOperator( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isTokenAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isUserAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; isVerifier( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainAcceptGovernance( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainCancelNomination( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainIsGovernor( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainNominateNewGovernor( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; mainRemoveGovernor( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; onERC721Received( - arg0: string, - arg1: string, - arg2: BigNumberish, - arg3: BytesLike, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + arg3: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerAndDepositERC20( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerAndDepositEth( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string | Promise } + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; registerAvailabilityVerifier( - arg0: string, - arg1: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerOperator( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerToken( - arg0: BigNumberish, - arg1: BytesLike, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerTokenAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerUser( - arg0: string, - arg1: BigNumberish, - arg2: BytesLike, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerUserAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerVerifier( - arg0: string, - arg1: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; removeAvailabilityVerifier( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; removeVerifier( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; unFreeze( - overrides?: Overrides & { from?: string | Promise } + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; unregisterOperator( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; unregisterTokenAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; unregisterUserAdmin( - arg0: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; updateState( - publicInput: BigNumberish[], - applicationData: BigNumberish[], - overrides?: Overrides & { from?: string | Promise } + publicInput: PromiseOrValue[], + applicationData: PromiseOrValue[], + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdraw( - ownerKey: BigNumberish, - assetType: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawAndMint( - ownerKey: BigNumberish, - assetType: BigNumberish, - mintingBlob: BytesLike, - overrides?: Overrides & { from?: string | Promise } + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawNft( - ownerKey: BigNumberish, - assetType: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string | Promise } + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawNftTo( - arg0: BigNumberish, - arg1: BigNumberish, - arg2: BigNumberish, - arg3: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + arg3: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawTo( - arg0: BigNumberish, - arg1: BigNumberish, - arg2: string, - overrides?: Overrides & { from?: string | Promise } + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; }; } diff --git a/src/contracts/contracts/v3/Registration.ts b/src/contracts/contracts/v3/Registration.ts new file mode 100644 index 00000000..8dfa23e1 --- /dev/null +++ b/src/contracts/contracts/v3/Registration.ts @@ -0,0 +1,495 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, + PromiseOrValue, +} from "../../common"; + +export interface RegistrationInterface extends utils.Interface { + functions: { + "imx()": FunctionFragment; + "isRegistered(uint256)": FunctionFragment; + "registerAndDepositNft(address,uint256,bytes,uint256,uint256,uint256)": FunctionFragment; + "registerAndWithdraw(address,uint256,bytes,uint256)": FunctionFragment; + "registerAndWithdrawNft(address,uint256,bytes,uint256,uint256)": FunctionFragment; + "registerAndWithdrawNftTo(address,uint256,bytes,uint256,uint256,address)": FunctionFragment; + "registerAndWithdrawTo(address,uint256,bytes,uint256,address)": FunctionFragment; + "regsiterAndWithdrawAndMint(address,uint256,bytes,uint256,bytes)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "imx" + | "isRegistered" + | "registerAndDepositNft" + | "registerAndWithdraw" + | "registerAndWithdrawNft" + | "registerAndWithdrawNftTo" + | "registerAndWithdrawTo" + | "regsiterAndWithdrawAndMint" + ): FunctionFragment; + + encodeFunctionData(functionFragment: "imx", values?: undefined): string; + encodeFunctionData( + functionFragment: "isRegistered", + values: [PromiseOrValue] + ): string; + encodeFunctionData( + functionFragment: "registerAndDepositNft", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] + ): string; + encodeFunctionData( + functionFragment: "registerAndWithdraw", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] + ): string; + encodeFunctionData( + functionFragment: "registerAndWithdrawNft", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] + ): string; + encodeFunctionData( + functionFragment: "registerAndWithdrawNftTo", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] + ): string; + encodeFunctionData( + functionFragment: "registerAndWithdrawTo", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] + ): string; + encodeFunctionData( + functionFragment: "regsiterAndWithdrawAndMint", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] + ): string; + + decodeFunctionResult(functionFragment: "imx", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "isRegistered", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "registerAndDepositNft", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "registerAndWithdraw", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "registerAndWithdrawNft", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "registerAndWithdrawNftTo", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "registerAndWithdrawTo", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "regsiterAndWithdrawAndMint", + data: BytesLike + ): Result; + + events: {}; +} + +export interface Registration extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: RegistrationInterface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + imx(overrides?: CallOverrides): Promise<[string]>; + + isRegistered( + starkKey: PromiseOrValue, + overrides?: CallOverrides + ): Promise<[boolean]>; + + registerAndDepositNft( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdraw( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdrawNft( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdrawNftTo( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + recipient: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdrawTo( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + recipient: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + regsiterAndWithdrawAndMint( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + }; + + imx(overrides?: CallOverrides): Promise; + + isRegistered( + starkKey: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + registerAndDepositNft( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdraw( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdrawNft( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdrawNftTo( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + recipient: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdrawTo( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + recipient: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + regsiterAndWithdrawAndMint( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + callStatic: { + imx(overrides?: CallOverrides): Promise; + + isRegistered( + starkKey: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + registerAndDepositNft( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + registerAndWithdraw( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + registerAndWithdrawNft( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + registerAndWithdrawNftTo( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + recipient: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + registerAndWithdrawTo( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + recipient: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + regsiterAndWithdrawAndMint( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + }; + + filters: {}; + + estimateGas: { + imx(overrides?: CallOverrides): Promise; + + isRegistered( + starkKey: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + registerAndDepositNft( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdraw( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdrawNft( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdrawNftTo( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + recipient: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdrawTo( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + recipient: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + regsiterAndWithdrawAndMint( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + }; + + populateTransaction: { + imx(overrides?: CallOverrides): Promise; + + isRegistered( + starkKey: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + registerAndDepositNft( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdraw( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdrawNft( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdrawNftTo( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + recipient: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdrawTo( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + recipient: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + regsiterAndWithdrawAndMint( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + }; +} diff --git a/src/contracts/contracts/v3/index.ts b/src/contracts/contracts/v3/index.ts new file mode 100644 index 00000000..957b08bf --- /dev/null +++ b/src/contracts/contracts/v3/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { Core } from "./Core"; +export type { Registration } from "./Registration"; diff --git a/src/contracts/contracts/StarkV4.ts b/src/contracts/contracts/v4/CoreV4.ts similarity index 63% rename from src/contracts/contracts/StarkV4.ts rename to src/contracts/contracts/v4/CoreV4.ts index 0113f226..353a242d 100644 --- a/src/contracts/contracts/StarkV4.ts +++ b/src/contracts/contracts/v4/CoreV4.ts @@ -25,45 +25,36 @@ import type { TypedEvent, TypedListener, OnEvent, -} from "../common"; + PromiseOrValue, +} from "../../common"; -export interface StarkV4Interface extends utils.Interface { +export interface CoreV4Interface extends utils.Interface { functions: { - "VERSION()": FunctionFragment; - "initialize(bytes)": FunctionFragment; "DEPOSIT_CANCEL_DELAY()": FunctionFragment; "FREEZE_GRACE_PERIOD()": FunctionFragment; "MAIN_GOVERNANCE_INFO_TAG()": FunctionFragment; "MAX_FORCED_ACTIONS_REQS_PER_BLOCK()": FunctionFragment; "MAX_VERIFIER_COUNT()": FunctionFragment; + "STARKEX_MAX_DEFAULT_VAULT_LOCK()": FunctionFragment; "UNFREEZE_DELAY()": FunctionFragment; "VERIFIER_REMOVAL_DELAY()": FunctionFragment; + "VERSION()": FunctionFragment; "announceAvailabilityVerifierRemovalIntent(address)": FunctionFragment; "announceVerifierRemovalIntent(address)": FunctionFragment; - "getRegisteredAvailabilityVerifiers()": FunctionFragment; - "getRegisteredVerifiers()": FunctionFragment; - "isAvailabilityVerifier(address)": FunctionFragment; - "isFrozen()": FunctionFragment; - "isVerifier(address)": FunctionFragment; - "mainAcceptGovernance()": FunctionFragment; - "mainCancelNomination()": FunctionFragment; - "mainIsGovernor(address)": FunctionFragment; - "mainNominateNewGovernor(address)": FunctionFragment; - "mainRemoveGovernor(address)": FunctionFragment; - "registerAvailabilityVerifier(address,string)": FunctionFragment; - "registerVerifier(address,string)": FunctionFragment; - "removeAvailabilityVerifier(address)": FunctionFragment; - "removeVerifier(address)": FunctionFragment; - "unFreeze()": FunctionFragment; "defaultVaultWithdrawalLock()": FunctionFragment; "deposit(uint256,uint256,uint256)": FunctionFragment; "deposit(uint256,uint256,uint256,uint256)": FunctionFragment; "depositCancel(uint256,uint256,uint256)": FunctionFragment; "depositERC20(uint256,uint256,uint256,uint256)": FunctionFragment; + "depositERC20ToVault(uint256,uint256,uint256)": FunctionFragment; "depositEth(uint256,uint256,uint256)": FunctionFragment; + "depositEthToVault(uint256,uint256)": FunctionFragment; "depositNft(uint256,uint256,uint256,uint256)": FunctionFragment; "depositNftReclaim(uint256,uint256,uint256,uint256)": FunctionFragment; "depositReclaim(uint256,uint256,uint256)": FunctionFragment; + "escape(uint256,uint256,uint256,uint256)": FunctionFragment; + "freezeRequest(uint256,uint256)": FunctionFragment; + "fullWithdrawalRequest(uint256,uint256)": FunctionFragment; "getActionCount()": FunctionFragment; "getActionHashByIndex(uint256)": FunctionFragment; "getAssetInfo(uint256)": FunctionFragment; @@ -71,88 +62,88 @@ export interface StarkV4Interface extends utils.Interface { "getDepositBalance(uint256,uint256,uint256)": FunctionFragment; "getEthKey(uint256)": FunctionFragment; "getFullWithdrawalRequest(uint256,uint256)": FunctionFragment; + "getLastBatchId()": FunctionFragment; + "getOrderRoot()": FunctionFragment; + "getOrderTreeHeight()": FunctionFragment; "getQuantizedDepositBalance(uint256,uint256,uint256)": FunctionFragment; + "getQuantizedVaultBalance(address,uint256,uint256)": FunctionFragment; "getQuantum(uint256)": FunctionFragment; + "getRegisteredAvailabilityVerifiers()": FunctionFragment; + "getRegisteredVerifiers()": FunctionFragment; + "getSequenceNumber()": FunctionFragment; + "getVaultBalance(address,uint256,uint256)": FunctionFragment; + "getVaultRoot()": FunctionFragment; + "getVaultTreeHeight()": FunctionFragment; + "getVaultWithdrawalLock(address,uint256,uint256)": FunctionFragment; "getWithdrawalBalance(uint256,uint256)": FunctionFragment; + "initialize(bytes)": FunctionFragment; "isAssetRegistered(uint256)": FunctionFragment; + "isAvailabilityVerifier(address)": FunctionFragment; + "isFrozen()": FunctionFragment; + "isOperator(address)": FunctionFragment; + "isStrictVaultBalancePolicy()": FunctionFragment; "isTokenAdmin(address)": FunctionFragment; + "isVaultLocked(address,uint256,uint256)": FunctionFragment; + "isVerifier(address)": FunctionFragment; + "lockVault(uint256,uint256,uint256)": FunctionFragment; + "mainAcceptGovernance()": FunctionFragment; + "mainCancelNomination()": FunctionFragment; + "mainIsGovernor(address)": FunctionFragment; + "mainNominateNewGovernor(address)": FunctionFragment; + "mainRemoveGovernor(address)": FunctionFragment; "onERC721Received(address,address,uint256,bytes)": FunctionFragment; "orderRegistryAddress()": FunctionFragment; "registerAndDepositERC20(address,uint256,bytes,uint256,uint256,uint256)": FunctionFragment; "registerAndDepositEth(address,uint256,bytes,uint256,uint256)": FunctionFragment; + "registerAvailabilityVerifier(address,string)": FunctionFragment; "registerEthAddress(address,uint256,bytes)": FunctionFragment; + "registerOperator(address)": FunctionFragment; "registerSender(uint256,bytes)": FunctionFragment; "registerToken(uint256,bytes)": FunctionFragment; "registerToken(uint256,bytes,uint256)": FunctionFragment; "registerTokenAdmin(address)": FunctionFragment; + "registerVerifier(address,string)": FunctionFragment; + "removeAvailabilityVerifier(address)": FunctionFragment; + "removeVerifier(address)": FunctionFragment; + "setDefaultVaultWithdrawalLock(uint256)": FunctionFragment; + "unFreeze()": FunctionFragment; + "unregisterOperator(address)": FunctionFragment; "unregisterTokenAdmin(address)": FunctionFragment; + "updateImplementationActivationTime(address,bytes,bool)": FunctionFragment; + "updateState(uint256[],uint256[])": FunctionFragment; "withdraw(uint256,uint256)": FunctionFragment; "withdrawAndMint(uint256,uint256,bytes)": FunctionFragment; - "withdrawNft(uint256,uint256,uint256)": FunctionFragment; - "STARKEX_MAX_DEFAULT_VAULT_LOCK()": FunctionFragment; - "escape(uint256,uint256,uint256,uint256)": FunctionFragment; - "getLastBatchId()": FunctionFragment; - "getOrderRoot()": FunctionFragment; - "getOrderTreeHeight()": FunctionFragment; - "getSequenceNumber()": FunctionFragment; - "getVaultRoot()": FunctionFragment; - "getVaultTreeHeight()": FunctionFragment; - "isOperator(address)": FunctionFragment; - "registerOperator(address)": FunctionFragment; - "unregisterOperator(address)": FunctionFragment; - "updateState(uint256[],uint256[])": FunctionFragment; - "freezeRequest(uint256,uint256)": FunctionFragment; - "fullWithdrawalRequest(uint256,uint256)": FunctionFragment; - "depositERC20ToVault(uint256,uint256,uint256)": FunctionFragment; - "depositEthToVault(uint256,uint256)": FunctionFragment; - "getQuantizedVaultBalance(address,uint256,uint256)": FunctionFragment; - "getVaultBalance(address,uint256,uint256)": FunctionFragment; - "getVaultWithdrawalLock(address,uint256,uint256)": FunctionFragment; - "isStrictVaultBalancePolicy()": FunctionFragment; - "isVaultLocked(address,uint256,uint256)": FunctionFragment; - "lockVault(uint256,uint256,uint256)": FunctionFragment; - "setDefaultVaultWithdrawalLock(uint256)": FunctionFragment; "withdrawFromVault(uint256,uint256,uint256)": FunctionFragment; - "updateImplementationActivationTime(address,bytes,bool)": FunctionFragment; + "withdrawNft(uint256,uint256,uint256)": FunctionFragment; }; getFunction( nameOrSignatureOrTopic: - | "VERSION" - | "initialize" | "DEPOSIT_CANCEL_DELAY" | "FREEZE_GRACE_PERIOD" | "MAIN_GOVERNANCE_INFO_TAG" | "MAX_FORCED_ACTIONS_REQS_PER_BLOCK" | "MAX_VERIFIER_COUNT" + | "STARKEX_MAX_DEFAULT_VAULT_LOCK" | "UNFREEZE_DELAY" | "VERIFIER_REMOVAL_DELAY" + | "VERSION" | "announceAvailabilityVerifierRemovalIntent" | "announceVerifierRemovalIntent" - | "getRegisteredAvailabilityVerifiers" - | "getRegisteredVerifiers" - | "isAvailabilityVerifier" - | "isFrozen" - | "isVerifier" - | "mainAcceptGovernance" - | "mainCancelNomination" - | "mainIsGovernor" - | "mainNominateNewGovernor" - | "mainRemoveGovernor" - | "registerAvailabilityVerifier" - | "registerVerifier" - | "removeAvailabilityVerifier" - | "removeVerifier" - | "unFreeze" | "defaultVaultWithdrawalLock" | "deposit(uint256,uint256,uint256)" | "deposit(uint256,uint256,uint256,uint256)" | "depositCancel" | "depositERC20" + | "depositERC20ToVault" | "depositEth" + | "depositEthToVault" | "depositNft" | "depositNftReclaim" | "depositReclaim" + | "escape" + | "freezeRequest" + | "fullWithdrawalRequest" | "getActionCount" | "getActionHashByIndex" | "getAssetInfo" @@ -160,56 +151,61 @@ export interface StarkV4Interface extends utils.Interface { | "getDepositBalance" | "getEthKey" | "getFullWithdrawalRequest" + | "getLastBatchId" + | "getOrderRoot" + | "getOrderTreeHeight" | "getQuantizedDepositBalance" + | "getQuantizedVaultBalance" | "getQuantum" + | "getRegisteredAvailabilityVerifiers" + | "getRegisteredVerifiers" + | "getSequenceNumber" + | "getVaultBalance" + | "getVaultRoot" + | "getVaultTreeHeight" + | "getVaultWithdrawalLock" | "getWithdrawalBalance" + | "initialize" | "isAssetRegistered" + | "isAvailabilityVerifier" + | "isFrozen" + | "isOperator" + | "isStrictVaultBalancePolicy" | "isTokenAdmin" + | "isVaultLocked" + | "isVerifier" + | "lockVault" + | "mainAcceptGovernance" + | "mainCancelNomination" + | "mainIsGovernor" + | "mainNominateNewGovernor" + | "mainRemoveGovernor" | "onERC721Received" | "orderRegistryAddress" | "registerAndDepositERC20" | "registerAndDepositEth" + | "registerAvailabilityVerifier" | "registerEthAddress" + | "registerOperator" | "registerSender" | "registerToken(uint256,bytes)" | "registerToken(uint256,bytes,uint256)" | "registerTokenAdmin" + | "registerVerifier" + | "removeAvailabilityVerifier" + | "removeVerifier" + | "setDefaultVaultWithdrawalLock" + | "unFreeze" + | "unregisterOperator" | "unregisterTokenAdmin" + | "updateImplementationActivationTime" + | "updateState" | "withdraw" | "withdrawAndMint" - | "withdrawNft" - | "STARKEX_MAX_DEFAULT_VAULT_LOCK" - | "escape" - | "getLastBatchId" - | "getOrderRoot" - | "getOrderTreeHeight" - | "getSequenceNumber" - | "getVaultRoot" - | "getVaultTreeHeight" - | "isOperator" - | "registerOperator" - | "unregisterOperator" - | "updateState" - | "freezeRequest" - | "fullWithdrawalRequest" - | "depositERC20ToVault" - | "depositEthToVault" - | "getQuantizedVaultBalance" - | "getVaultBalance" - | "getVaultWithdrawalLock" - | "isStrictVaultBalancePolicy" - | "isVaultLocked" - | "lockVault" - | "setDefaultVaultWithdrawalLock" | "withdrawFromVault" - | "updateImplementationActivationTime" + | "withdrawNft" ): FunctionFragment; - encodeFunctionData(functionFragment: "VERSION", values?: undefined): string; - encodeFunctionData( - functionFragment: "initialize", - values: [BytesLike] - ): string; encodeFunctionData( functionFragment: "DEPOSIT_CANCEL_DELAY", values?: undefined @@ -230,6 +226,10 @@ export interface StarkV4Interface extends utils.Interface { functionFragment: "MAX_VERIFIER_COUNT", values?: undefined ): string; + encodeFunctionData( + functionFragment: "STARKEX_MAX_DEFAULT_VAULT_LOCK", + values?: undefined + ): string; encodeFunctionData( functionFragment: "UNFREEZE_DELAY", values?: undefined @@ -238,100 +238,115 @@ export interface StarkV4Interface extends utils.Interface { functionFragment: "VERIFIER_REMOVAL_DELAY", values?: undefined ): string; + encodeFunctionData(functionFragment: "VERSION", values?: undefined): string; encodeFunctionData( functionFragment: "announceAvailabilityVerifierRemovalIntent", - values: [string] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "announceVerifierRemovalIntent", - values: [string] - ): string; - encodeFunctionData( - functionFragment: "getRegisteredAvailabilityVerifiers", - values?: undefined - ): string; - encodeFunctionData( - functionFragment: "getRegisteredVerifiers", - values?: undefined - ): string; - encodeFunctionData( - functionFragment: "isAvailabilityVerifier", - values: [string] - ): string; - encodeFunctionData(functionFragment: "isFrozen", values?: undefined): string; - encodeFunctionData(functionFragment: "isVerifier", values: [string]): string; - encodeFunctionData( - functionFragment: "mainAcceptGovernance", - values?: undefined + values: [PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "mainCancelNomination", + functionFragment: "defaultVaultWithdrawalLock", values?: undefined ): string; encodeFunctionData( - functionFragment: "mainIsGovernor", - values: [string] - ): string; - encodeFunctionData( - functionFragment: "mainNominateNewGovernor", - values: [string] - ): string; - encodeFunctionData( - functionFragment: "mainRemoveGovernor", - values: [string] - ): string; - encodeFunctionData( - functionFragment: "registerAvailabilityVerifier", - values: [string, string] + functionFragment: "deposit(uint256,uint256,uint256)", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( - functionFragment: "registerVerifier", - values: [string, string] + functionFragment: "deposit(uint256,uint256,uint256,uint256)", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( - functionFragment: "removeAvailabilityVerifier", - values: [string] + functionFragment: "depositCancel", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( - functionFragment: "removeVerifier", - values: [string] + functionFragment: "depositERC20", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; - encodeFunctionData(functionFragment: "unFreeze", values?: undefined): string; encodeFunctionData( - functionFragment: "defaultVaultWithdrawalLock", - values?: undefined + functionFragment: "depositERC20ToVault", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( - functionFragment: "deposit(uint256,uint256,uint256)", - values: [BigNumberish, BigNumberish, BigNumberish] + functionFragment: "depositEth", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( - functionFragment: "deposit(uint256,uint256,uint256,uint256)", - values: [BigNumberish, BigNumberish, BigNumberish, BigNumberish] + functionFragment: "depositEthToVault", + values: [PromiseOrValue, PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "depositCancel", - values: [BigNumberish, BigNumberish, BigNumberish] + functionFragment: "depositNft", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( - functionFragment: "depositERC20", - values: [BigNumberish, BigNumberish, BigNumberish, BigNumberish] + functionFragment: "depositNftReclaim", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( - functionFragment: "depositEth", - values: [BigNumberish, BigNumberish, BigNumberish] + functionFragment: "depositReclaim", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( - functionFragment: "depositNft", - values: [BigNumberish, BigNumberish, BigNumberish, BigNumberish] + functionFragment: "escape", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( - functionFragment: "depositNftReclaim", - values: [BigNumberish, BigNumberish, BigNumberish, BigNumberish] + functionFragment: "freezeRequest", + values: [PromiseOrValue, PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "depositReclaim", - values: [BigNumberish, BigNumberish, BigNumberish] + functionFragment: "fullWithdrawalRequest", + values: [PromiseOrValue, PromiseOrValue] ): string; encodeFunctionData( functionFragment: "getActionCount", @@ -339,207 +354,309 @@ export interface StarkV4Interface extends utils.Interface { ): string; encodeFunctionData( functionFragment: "getActionHashByIndex", - values: [BigNumberish] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "getAssetInfo", - values: [BigNumberish] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "getCancellationRequest", - values: [BigNumberish, BigNumberish, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "getDepositBalance", - values: [BigNumberish, BigNumberish, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "getEthKey", - values: [BigNumberish] + values: [PromiseOrValue] ): string; encodeFunctionData( functionFragment: "getFullWithdrawalRequest", - values: [BigNumberish, BigNumberish] + values: [PromiseOrValue, PromiseOrValue] + ): string; + encodeFunctionData( + functionFragment: "getLastBatchId", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "getOrderRoot", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "getOrderTreeHeight", + values?: undefined ): string; encodeFunctionData( functionFragment: "getQuantizedDepositBalance", - values: [BigNumberish, BigNumberish, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] + ): string; + encodeFunctionData( + functionFragment: "getQuantizedVaultBalance", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "getQuantum", - values: [BigNumberish] + values: [PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "getWithdrawalBalance", - values: [BigNumberish, BigNumberish] + functionFragment: "getRegisteredAvailabilityVerifiers", + values?: undefined ): string; encodeFunctionData( - functionFragment: "isAssetRegistered", - values: [BigNumberish] + functionFragment: "getRegisteredVerifiers", + values?: undefined ): string; encodeFunctionData( - functionFragment: "isTokenAdmin", - values: [string] + functionFragment: "getSequenceNumber", + values?: undefined ): string; encodeFunctionData( - functionFragment: "onERC721Received", - values: [string, string, BigNumberish, BytesLike] + functionFragment: "getVaultBalance", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( - functionFragment: "orderRegistryAddress", + functionFragment: "getVaultRoot", values?: undefined ): string; encodeFunctionData( - functionFragment: "registerAndDepositERC20", + functionFragment: "getVaultTreeHeight", + values?: undefined + ): string; + encodeFunctionData( + functionFragment: "getVaultWithdrawalLock", values: [ - string, - BigNumberish, - BytesLike, - BigNumberish, - BigNumberish, - BigNumberish + PromiseOrValue, + PromiseOrValue, + PromiseOrValue ] ): string; encodeFunctionData( - functionFragment: "registerAndDepositEth", - values: [string, BigNumberish, BytesLike, BigNumberish, BigNumberish] + functionFragment: "getWithdrawalBalance", + values: [PromiseOrValue, PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "registerEthAddress", - values: [string, BigNumberish, BytesLike] + functionFragment: "initialize", + values: [PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "registerSender", - values: [BigNumberish, BytesLike] + functionFragment: "isAssetRegistered", + values: [PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "registerToken(uint256,bytes)", - values: [BigNumberish, BytesLike] + functionFragment: "isAvailabilityVerifier", + values: [PromiseOrValue] ): string; + encodeFunctionData(functionFragment: "isFrozen", values?: undefined): string; encodeFunctionData( - functionFragment: "registerToken(uint256,bytes,uint256)", - values: [BigNumberish, BytesLike, BigNumberish] + functionFragment: "isOperator", + values: [PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "registerTokenAdmin", - values: [string] + functionFragment: "isStrictVaultBalancePolicy", + values?: undefined ): string; encodeFunctionData( - functionFragment: "unregisterTokenAdmin", - values: [string] + functionFragment: "isTokenAdmin", + values: [PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "withdraw", - values: [BigNumberish, BigNumberish] + functionFragment: "isVaultLocked", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( - functionFragment: "withdrawAndMint", - values: [BigNumberish, BigNumberish, BytesLike] + functionFragment: "isVerifier", + values: [PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "withdrawNft", - values: [BigNumberish, BigNumberish, BigNumberish] + functionFragment: "lockVault", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( - functionFragment: "STARKEX_MAX_DEFAULT_VAULT_LOCK", + functionFragment: "mainAcceptGovernance", values?: undefined ): string; encodeFunctionData( - functionFragment: "escape", - values: [BigNumberish, BigNumberish, BigNumberish, BigNumberish] + functionFragment: "mainCancelNomination", + values?: undefined ): string; encodeFunctionData( - functionFragment: "getLastBatchId", - values?: undefined + functionFragment: "mainIsGovernor", + values: [PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "getOrderRoot", - values?: undefined + functionFragment: "mainNominateNewGovernor", + values: [PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "getOrderTreeHeight", - values?: undefined + functionFragment: "mainRemoveGovernor", + values: [PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "getSequenceNumber", - values?: undefined + functionFragment: "onERC721Received", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( - functionFragment: "getVaultRoot", + functionFragment: "orderRegistryAddress", values?: undefined ): string; encodeFunctionData( - functionFragment: "getVaultTreeHeight", - values?: undefined + functionFragment: "registerAndDepositERC20", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] + ): string; + encodeFunctionData( + functionFragment: "registerAndDepositEth", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] + ): string; + encodeFunctionData( + functionFragment: "registerAvailabilityVerifier", + values: [PromiseOrValue, PromiseOrValue] + ): string; + encodeFunctionData( + functionFragment: "registerEthAddress", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; - encodeFunctionData(functionFragment: "isOperator", values: [string]): string; encodeFunctionData( functionFragment: "registerOperator", - values: [string] + values: [PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "unregisterOperator", - values: [string] + functionFragment: "registerSender", + values: [PromiseOrValue, PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "updateState", - values: [BigNumberish[], BigNumberish[]] + functionFragment: "registerToken(uint256,bytes)", + values: [PromiseOrValue, PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "freezeRequest", - values: [BigNumberish, BigNumberish] + functionFragment: "registerToken(uint256,bytes,uint256)", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( - functionFragment: "fullWithdrawalRequest", - values: [BigNumberish, BigNumberish] + functionFragment: "registerTokenAdmin", + values: [PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "depositERC20ToVault", - values: [BigNumberish, BigNumberish, BigNumberish] + functionFragment: "registerVerifier", + values: [PromiseOrValue, PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "depositEthToVault", - values: [BigNumberish, BigNumberish] + functionFragment: "removeAvailabilityVerifier", + values: [PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "getQuantizedVaultBalance", - values: [string, BigNumberish, BigNumberish] + functionFragment: "removeVerifier", + values: [PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "getVaultBalance", - values: [string, BigNumberish, BigNumberish] + functionFragment: "setDefaultVaultWithdrawalLock", + values: [PromiseOrValue] ): string; + encodeFunctionData(functionFragment: "unFreeze", values?: undefined): string; encodeFunctionData( - functionFragment: "getVaultWithdrawalLock", - values: [string, BigNumberish, BigNumberish] + functionFragment: "unregisterOperator", + values: [PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "isStrictVaultBalancePolicy", - values?: undefined + functionFragment: "unregisterTokenAdmin", + values: [PromiseOrValue] ): string; encodeFunctionData( - functionFragment: "isVaultLocked", - values: [string, BigNumberish, BigNumberish] + functionFragment: "updateImplementationActivationTime", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( - functionFragment: "lockVault", - values: [BigNumberish, BigNumberish, BigNumberish] + functionFragment: "updateState", + values: [PromiseOrValue[], PromiseOrValue[]] ): string; encodeFunctionData( - functionFragment: "setDefaultVaultWithdrawalLock", - values: [BigNumberish] + functionFragment: "withdraw", + values: [PromiseOrValue, PromiseOrValue] + ): string; + encodeFunctionData( + functionFragment: "withdrawAndMint", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( functionFragment: "withdrawFromVault", - values: [BigNumberish, BigNumberish, BigNumberish] + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; encodeFunctionData( - functionFragment: "updateImplementationActivationTime", - values: [string, BytesLike, boolean] + functionFragment: "withdrawNft", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] ): string; - decodeFunctionResult(functionFragment: "VERSION", data: BytesLike): Result; - decodeFunctionResult(functionFragment: "initialize", data: BytesLike): Result; decodeFunctionResult( functionFragment: "DEPOSIT_CANCEL_DELAY", data: BytesLike @@ -560,6 +677,10 @@ export interface StarkV4Interface extends utils.Interface { functionFragment: "MAX_VERIFIER_COUNT", data: BytesLike ): Result; + decodeFunctionResult( + functionFragment: "STARKEX_MAX_DEFAULT_VAULT_LOCK", + data: BytesLike + ): Result; decodeFunctionResult( functionFragment: "UNFREEZE_DELAY", data: BytesLike @@ -568,6 +689,7 @@ export interface StarkV4Interface extends utils.Interface { functionFragment: "VERIFIER_REMOVAL_DELAY", data: BytesLike ): Result; + decodeFunctionResult(functionFragment: "VERSION", data: BytesLike): Result; decodeFunctionResult( functionFragment: "announceAvailabilityVerifierRemovalIntent", data: BytesLike @@ -577,258 +699,255 @@ export interface StarkV4Interface extends utils.Interface { data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "getRegisteredAvailabilityVerifiers", + functionFragment: "defaultVaultWithdrawalLock", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "getRegisteredVerifiers", + functionFragment: "deposit(uint256,uint256,uint256)", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "isAvailabilityVerifier", + functionFragment: "deposit(uint256,uint256,uint256,uint256)", data: BytesLike ): Result; - decodeFunctionResult(functionFragment: "isFrozen", data: BytesLike): Result; - decodeFunctionResult(functionFragment: "isVerifier", data: BytesLike): Result; decodeFunctionResult( - functionFragment: "mainAcceptGovernance", + functionFragment: "depositCancel", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "mainCancelNomination", + functionFragment: "depositERC20", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "mainIsGovernor", + functionFragment: "depositERC20ToVault", data: BytesLike ): Result; + decodeFunctionResult(functionFragment: "depositEth", data: BytesLike): Result; decodeFunctionResult( - functionFragment: "mainNominateNewGovernor", + functionFragment: "depositEthToVault", data: BytesLike ): Result; + decodeFunctionResult(functionFragment: "depositNft", data: BytesLike): Result; decodeFunctionResult( - functionFragment: "mainRemoveGovernor", + functionFragment: "depositNftReclaim", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "registerAvailabilityVerifier", + functionFragment: "depositReclaim", data: BytesLike ): Result; + decodeFunctionResult(functionFragment: "escape", data: BytesLike): Result; decodeFunctionResult( - functionFragment: "registerVerifier", + functionFragment: "freezeRequest", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "removeAvailabilityVerifier", + functionFragment: "fullWithdrawalRequest", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "removeVerifier", + functionFragment: "getActionCount", data: BytesLike ): Result; - decodeFunctionResult(functionFragment: "unFreeze", data: BytesLike): Result; decodeFunctionResult( - functionFragment: "defaultVaultWithdrawalLock", + functionFragment: "getActionHashByIndex", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "deposit(uint256,uint256,uint256)", + functionFragment: "getAssetInfo", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "deposit(uint256,uint256,uint256,uint256)", + functionFragment: "getCancellationRequest", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "depositCancel", + functionFragment: "getDepositBalance", data: BytesLike ): Result; + decodeFunctionResult(functionFragment: "getEthKey", data: BytesLike): Result; decodeFunctionResult( - functionFragment: "depositERC20", + functionFragment: "getFullWithdrawalRequest", data: BytesLike ): Result; - decodeFunctionResult(functionFragment: "depositEth", data: BytesLike): Result; - decodeFunctionResult(functionFragment: "depositNft", data: BytesLike): Result; decodeFunctionResult( - functionFragment: "depositNftReclaim", + functionFragment: "getLastBatchId", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "depositReclaim", + functionFragment: "getOrderRoot", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "getActionCount", + functionFragment: "getOrderTreeHeight", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "getActionHashByIndex", + functionFragment: "getQuantizedDepositBalance", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "getAssetInfo", + functionFragment: "getQuantizedVaultBalance", data: BytesLike ): Result; + decodeFunctionResult(functionFragment: "getQuantum", data: BytesLike): Result; decodeFunctionResult( - functionFragment: "getCancellationRequest", + functionFragment: "getRegisteredAvailabilityVerifiers", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "getDepositBalance", + functionFragment: "getRegisteredVerifiers", data: BytesLike ): Result; - decodeFunctionResult(functionFragment: "getEthKey", data: BytesLike): Result; decodeFunctionResult( - functionFragment: "getFullWithdrawalRequest", + functionFragment: "getSequenceNumber", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "getQuantizedDepositBalance", + functionFragment: "getVaultBalance", data: BytesLike ): Result; - decodeFunctionResult(functionFragment: "getQuantum", data: BytesLike): Result; decodeFunctionResult( - functionFragment: "getWithdrawalBalance", + functionFragment: "getVaultRoot", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "isAssetRegistered", + functionFragment: "getVaultTreeHeight", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "isTokenAdmin", + functionFragment: "getVaultWithdrawalLock", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "onERC721Received", + functionFragment: "getWithdrawalBalance", data: BytesLike ): Result; + decodeFunctionResult(functionFragment: "initialize", data: BytesLike): Result; decodeFunctionResult( - functionFragment: "orderRegistryAddress", + functionFragment: "isAssetRegistered", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "registerAndDepositERC20", + functionFragment: "isAvailabilityVerifier", data: BytesLike ): Result; + decodeFunctionResult(functionFragment: "isFrozen", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "isOperator", data: BytesLike): Result; decodeFunctionResult( - functionFragment: "registerAndDepositEth", + functionFragment: "isStrictVaultBalancePolicy", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "registerEthAddress", + functionFragment: "isTokenAdmin", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "registerSender", + functionFragment: "isVaultLocked", data: BytesLike ): Result; + decodeFunctionResult(functionFragment: "isVerifier", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "lockVault", data: BytesLike): Result; decodeFunctionResult( - functionFragment: "registerToken(uint256,bytes)", + functionFragment: "mainAcceptGovernance", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "registerToken(uint256,bytes,uint256)", + functionFragment: "mainCancelNomination", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "registerTokenAdmin", + functionFragment: "mainIsGovernor", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "unregisterTokenAdmin", + functionFragment: "mainNominateNewGovernor", data: BytesLike ): Result; - decodeFunctionResult(functionFragment: "withdraw", data: BytesLike): Result; decodeFunctionResult( - functionFragment: "withdrawAndMint", + functionFragment: "mainRemoveGovernor", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "withdrawNft", + functionFragment: "onERC721Received", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "STARKEX_MAX_DEFAULT_VAULT_LOCK", + functionFragment: "orderRegistryAddress", data: BytesLike ): Result; - decodeFunctionResult(functionFragment: "escape", data: BytesLike): Result; decodeFunctionResult( - functionFragment: "getLastBatchId", - data: BytesLike - ): Result; - decodeFunctionResult( - functionFragment: "getOrderRoot", + functionFragment: "registerAndDepositERC20", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "getOrderTreeHeight", + functionFragment: "registerAndDepositEth", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "getSequenceNumber", + functionFragment: "registerAvailabilityVerifier", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "getVaultRoot", + functionFragment: "registerEthAddress", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "getVaultTreeHeight", + functionFragment: "registerOperator", data: BytesLike ): Result; - decodeFunctionResult(functionFragment: "isOperator", data: BytesLike): Result; decodeFunctionResult( - functionFragment: "registerOperator", + functionFragment: "registerSender", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "unregisterOperator", + functionFragment: "registerToken(uint256,bytes)", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "updateState", + functionFragment: "registerToken(uint256,bytes,uint256)", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "freezeRequest", + functionFragment: "registerTokenAdmin", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "fullWithdrawalRequest", + functionFragment: "registerVerifier", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "depositERC20ToVault", + functionFragment: "removeAvailabilityVerifier", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "depositEthToVault", + functionFragment: "removeVerifier", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "getQuantizedVaultBalance", + functionFragment: "setDefaultVaultWithdrawalLock", data: BytesLike ): Result; + decodeFunctionResult(functionFragment: "unFreeze", data: BytesLike): Result; decodeFunctionResult( - functionFragment: "getVaultBalance", + functionFragment: "unregisterOperator", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "getVaultWithdrawalLock", + functionFragment: "unregisterTokenAdmin", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "isStrictVaultBalancePolicy", + functionFragment: "updateImplementationActivationTime", data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "isVaultLocked", + functionFragment: "updateState", data: BytesLike ): Result; - decodeFunctionResult(functionFragment: "lockVault", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "withdraw", data: BytesLike): Result; decodeFunctionResult( - functionFragment: "setDefaultVaultWithdrawalLock", + functionFragment: "withdrawAndMint", data: BytesLike ): Result; decodeFunctionResult( @@ -836,180 +955,117 @@ export interface StarkV4Interface extends utils.Interface { data: BytesLike ): Result; decodeFunctionResult( - functionFragment: "updateImplementationActivationTime", + functionFragment: "withdrawNft", data: BytesLike ): Result; events: { - "LogFrozen()": EventFragment; - "LogNewGovernorAccepted(address)": EventFragment; - "LogNominatedGovernor(address)": EventFragment; - "LogNominationCancelled()": EventFragment; - "LogRegistered(address,string)": EventFragment; - "LogRemovalIntent(address,string)": EventFragment; - "LogRemoved(address,string)": EventFragment; - "LogRemovedGovernor(address)": EventFragment; - "LogUnFrozen()": EventFragment; + "ImplementationActivationRescheduled(address,uint256)": EventFragment; + "LogDefaultVaultWithdrawalLockSet(uint256)": EventFragment; "LogDeposit(address,uint256,uint256,uint256,uint256,uint256)": EventFragment; "LogDepositCancel(uint256,uint256,uint256)": EventFragment; "LogDepositCancelReclaimed(uint256,uint256,uint256,uint256,uint256)": EventFragment; "LogDepositNftCancelReclaimed(uint256,uint256,uint256,uint256,uint256)": EventFragment; + "LogDepositToVault(address,uint256,uint256,uint256,uint256)": EventFragment; + "LogFrozen()": EventFragment; + "LogFullWithdrawalRequest(uint256,uint256)": EventFragment; "LogMintWithdrawalPerformed(uint256,uint256,uint256,uint256,uint256)": EventFragment; "LogMintableWithdrawalAllowed(uint256,uint256,uint256)": EventFragment; + "LogNewGovernorAccepted(address)": EventFragment; "LogNftDeposit(address,uint256,uint256,uint256,uint256,uint256)": EventFragment; "LogNftWithdrawalAllowed(uint256,uint256)": EventFragment; "LogNftWithdrawalPerformed(uint256,uint256,uint256,uint256,address)": EventFragment; - "LogTokenAdminAdded(address)": EventFragment; - "LogTokenAdminRemoved(address)": EventFragment; - "LogTokenRegistered(uint256,bytes,uint256)": EventFragment; - "LogUserRegistered(address,uint256,address)": EventFragment; - "LogWithdrawalAllowed(uint256,uint256,uint256,uint256)": EventFragment; - "LogWithdrawalPerformed(uint256,uint256,uint256,uint256,address)": EventFragment; + "LogNominatedGovernor(address)": EventFragment; + "LogNominationCancelled()": EventFragment; "LogOperatorAdded(address)": EventFragment; "LogOperatorRemoved(address)": EventFragment; + "LogRegistered(address,string)": EventFragment; + "LogRemovalIntent(address,string)": EventFragment; + "LogRemoved(address,string)": EventFragment; + "LogRemovedGovernor(address)": EventFragment; "LogRootUpdate(uint256,uint256,uint256,uint256)": EventFragment; "LogStateTransitionFact(bytes32)": EventFragment; + "LogTokenAdminAdded(address)": EventFragment; + "LogTokenAdminRemoved(address)": EventFragment; + "LogTokenRegistered(uint256,bytes,uint256)": EventFragment; + "LogUnFrozen()": EventFragment; + "LogUserRegistered(address,uint256,address)": EventFragment; "LogVaultBalanceChangeApplied(address,uint256,uint256,int256)": EventFragment; - "LogFullWithdrawalRequest(uint256,uint256)": EventFragment; - "LogDefaultVaultWithdrawalLockSet(uint256)": EventFragment; - "LogDepositToVault(address,uint256,uint256,uint256,uint256)": EventFragment; "LogVaultWithdrawalLockSet(address,uint256,uint256,uint256)": EventFragment; + "LogWithdrawalAllowed(uint256,uint256,uint256,uint256)": EventFragment; "LogWithdrawalFromVault(address,uint256,uint256,uint256,uint256)": EventFragment; - "ImplementationActivationRescheduled(address,uint256)": EventFragment; + "LogWithdrawalPerformed(uint256,uint256,uint256,uint256,address)": EventFragment; }; - getEvent(nameOrSignatureOrTopic: "LogFrozen"): EventFragment; - getEvent(nameOrSignatureOrTopic: "LogNewGovernorAccepted"): EventFragment; - getEvent(nameOrSignatureOrTopic: "LogNominatedGovernor"): EventFragment; - getEvent(nameOrSignatureOrTopic: "LogNominationCancelled"): EventFragment; - getEvent(nameOrSignatureOrTopic: "LogRegistered"): EventFragment; - getEvent(nameOrSignatureOrTopic: "LogRemovalIntent"): EventFragment; - getEvent(nameOrSignatureOrTopic: "LogRemoved"): EventFragment; - getEvent(nameOrSignatureOrTopic: "LogRemovedGovernor"): EventFragment; - getEvent(nameOrSignatureOrTopic: "LogUnFrozen"): EventFragment; + getEvent( + nameOrSignatureOrTopic: "ImplementationActivationRescheduled" + ): EventFragment; + getEvent( + nameOrSignatureOrTopic: "LogDefaultVaultWithdrawalLockSet" + ): EventFragment; getEvent(nameOrSignatureOrTopic: "LogDeposit"): EventFragment; getEvent(nameOrSignatureOrTopic: "LogDepositCancel"): EventFragment; getEvent(nameOrSignatureOrTopic: "LogDepositCancelReclaimed"): EventFragment; getEvent( nameOrSignatureOrTopic: "LogDepositNftCancelReclaimed" ): EventFragment; + getEvent(nameOrSignatureOrTopic: "LogDepositToVault"): EventFragment; + getEvent(nameOrSignatureOrTopic: "LogFrozen"): EventFragment; + getEvent(nameOrSignatureOrTopic: "LogFullWithdrawalRequest"): EventFragment; getEvent(nameOrSignatureOrTopic: "LogMintWithdrawalPerformed"): EventFragment; getEvent( nameOrSignatureOrTopic: "LogMintableWithdrawalAllowed" ): EventFragment; + getEvent(nameOrSignatureOrTopic: "LogNewGovernorAccepted"): EventFragment; getEvent(nameOrSignatureOrTopic: "LogNftDeposit"): EventFragment; getEvent(nameOrSignatureOrTopic: "LogNftWithdrawalAllowed"): EventFragment; getEvent(nameOrSignatureOrTopic: "LogNftWithdrawalPerformed"): EventFragment; - getEvent(nameOrSignatureOrTopic: "LogTokenAdminAdded"): EventFragment; - getEvent(nameOrSignatureOrTopic: "LogTokenAdminRemoved"): EventFragment; - getEvent(nameOrSignatureOrTopic: "LogTokenRegistered"): EventFragment; - getEvent(nameOrSignatureOrTopic: "LogUserRegistered"): EventFragment; - getEvent(nameOrSignatureOrTopic: "LogWithdrawalAllowed"): EventFragment; - getEvent(nameOrSignatureOrTopic: "LogWithdrawalPerformed"): EventFragment; + getEvent(nameOrSignatureOrTopic: "LogNominatedGovernor"): EventFragment; + getEvent(nameOrSignatureOrTopic: "LogNominationCancelled"): EventFragment; getEvent(nameOrSignatureOrTopic: "LogOperatorAdded"): EventFragment; getEvent(nameOrSignatureOrTopic: "LogOperatorRemoved"): EventFragment; + getEvent(nameOrSignatureOrTopic: "LogRegistered"): EventFragment; + getEvent(nameOrSignatureOrTopic: "LogRemovalIntent"): EventFragment; + getEvent(nameOrSignatureOrTopic: "LogRemoved"): EventFragment; + getEvent(nameOrSignatureOrTopic: "LogRemovedGovernor"): EventFragment; getEvent(nameOrSignatureOrTopic: "LogRootUpdate"): EventFragment; getEvent(nameOrSignatureOrTopic: "LogStateTransitionFact"): EventFragment; + getEvent(nameOrSignatureOrTopic: "LogTokenAdminAdded"): EventFragment; + getEvent(nameOrSignatureOrTopic: "LogTokenAdminRemoved"): EventFragment; + getEvent(nameOrSignatureOrTopic: "LogTokenRegistered"): EventFragment; + getEvent(nameOrSignatureOrTopic: "LogUnFrozen"): EventFragment; + getEvent(nameOrSignatureOrTopic: "LogUserRegistered"): EventFragment; getEvent( nameOrSignatureOrTopic: "LogVaultBalanceChangeApplied" ): EventFragment; - getEvent(nameOrSignatureOrTopic: "LogFullWithdrawalRequest"): EventFragment; - getEvent( - nameOrSignatureOrTopic: "LogDefaultVaultWithdrawalLockSet" - ): EventFragment; - getEvent(nameOrSignatureOrTopic: "LogDepositToVault"): EventFragment; getEvent(nameOrSignatureOrTopic: "LogVaultWithdrawalLockSet"): EventFragment; + getEvent(nameOrSignatureOrTopic: "LogWithdrawalAllowed"): EventFragment; getEvent(nameOrSignatureOrTopic: "LogWithdrawalFromVault"): EventFragment; - getEvent( - nameOrSignatureOrTopic: "ImplementationActivationRescheduled" - ): EventFragment; -} - -export interface LogFrozenEventObject {} -export type LogFrozenEvent = TypedEvent<[], LogFrozenEventObject>; - -export type LogFrozenEventFilter = TypedEventFilter; - -export interface LogNewGovernorAcceptedEventObject { - acceptedGovernor: string; -} -export type LogNewGovernorAcceptedEvent = TypedEvent< - [string], - LogNewGovernorAcceptedEventObject ->; - -export type LogNewGovernorAcceptedEventFilter = - TypedEventFilter; - -export interface LogNominatedGovernorEventObject { - nominatedGovernor: string; -} -export type LogNominatedGovernorEvent = TypedEvent< - [string], - LogNominatedGovernorEventObject ->; - -export type LogNominatedGovernorEventFilter = - TypedEventFilter; - -export interface LogNominationCancelledEventObject {} -export type LogNominationCancelledEvent = TypedEvent< - [], - LogNominationCancelledEventObject ->; - -export type LogNominationCancelledEventFilter = - TypedEventFilter; - -export interface LogRegisteredEventObject { - entry: string; - entryId: string; -} -export type LogRegisteredEvent = TypedEvent< - [string, string], - LogRegisteredEventObject ->; - -export type LogRegisteredEventFilter = TypedEventFilter; - -export interface LogRemovalIntentEventObject { - entry: string; - entryId: string; + getEvent(nameOrSignatureOrTopic: "LogWithdrawalPerformed"): EventFragment; } -export type LogRemovalIntentEvent = TypedEvent< - [string, string], - LogRemovalIntentEventObject ->; - -export type LogRemovalIntentEventFilter = - TypedEventFilter; -export interface LogRemovedEventObject { - entry: string; - entryId: string; +export interface ImplementationActivationRescheduledEventObject { + implementation: string; + updatedActivationTime: BigNumber; } -export type LogRemovedEvent = TypedEvent< - [string, string], - LogRemovedEventObject +export type ImplementationActivationRescheduledEvent = TypedEvent< + [string, BigNumber], + ImplementationActivationRescheduledEventObject >; -export type LogRemovedEventFilter = TypedEventFilter; +export type ImplementationActivationRescheduledEventFilter = + TypedEventFilter; -export interface LogRemovedGovernorEventObject { - removedGovernor: string; +export interface LogDefaultVaultWithdrawalLockSetEventObject { + newDefaultLockTime: BigNumber; } -export type LogRemovedGovernorEvent = TypedEvent< - [string], - LogRemovedGovernorEventObject +export type LogDefaultVaultWithdrawalLockSetEvent = TypedEvent< + [BigNumber], + LogDefaultVaultWithdrawalLockSetEventObject >; -export type LogRemovedGovernorEventFilter = - TypedEventFilter; - -export interface LogUnFrozenEventObject {} -export type LogUnFrozenEvent = TypedEvent<[], LogUnFrozenEventObject>; - -export type LogUnFrozenEventFilter = TypedEventFilter; +export type LogDefaultVaultWithdrawalLockSetEventFilter = + TypedEventFilter; export interface LogDepositEventObject { depositorEthKey: string; @@ -1069,6 +1125,38 @@ export type LogDepositNftCancelReclaimedEvent = TypedEvent< export type LogDepositNftCancelReclaimedEventFilter = TypedEventFilter; +export interface LogDepositToVaultEventObject { + ethKey: string; + assetId: BigNumber; + vaultId: BigNumber; + nonQuantizedAmount: BigNumber; + quantizedAmount: BigNumber; +} +export type LogDepositToVaultEvent = TypedEvent< + [string, BigNumber, BigNumber, BigNumber, BigNumber], + LogDepositToVaultEventObject +>; + +export type LogDepositToVaultEventFilter = + TypedEventFilter; + +export interface LogFrozenEventObject {} +export type LogFrozenEvent = TypedEvent<[], LogFrozenEventObject>; + +export type LogFrozenEventFilter = TypedEventFilter; + +export interface LogFullWithdrawalRequestEventObject { + starkKey: BigNumber; + vaultId: BigNumber; +} +export type LogFullWithdrawalRequestEvent = TypedEvent< + [BigNumber, BigNumber], + LogFullWithdrawalRequestEventObject +>; + +export type LogFullWithdrawalRequestEventFilter = + TypedEventFilter; + export interface LogMintWithdrawalPerformedEventObject { ownerKey: BigNumber; assetType: BigNumber; @@ -1097,7 +1185,18 @@ export type LogMintableWithdrawalAllowedEvent = TypedEvent< export type LogMintableWithdrawalAllowedEventFilter = TypedEventFilter; -export interface LogNftDepositEventObject { +export interface LogNewGovernorAcceptedEventObject { + acceptedGovernor: string; +} +export type LogNewGovernorAcceptedEvent = TypedEvent< + [string], + LogNewGovernorAcceptedEventObject +>; + +export type LogNewGovernorAcceptedEventFilter = + TypedEventFilter; + +export interface LogNftDepositEventObject { depositorEthKey: string; starkKey: BigNumber; vaultId: BigNumber; @@ -1139,104 +1238,92 @@ export type LogNftWithdrawalPerformedEvent = TypedEvent< export type LogNftWithdrawalPerformedEventFilter = TypedEventFilter; -export interface LogTokenAdminAddedEventObject { - tokenAdmin: string; +export interface LogNominatedGovernorEventObject { + nominatedGovernor: string; } -export type LogTokenAdminAddedEvent = TypedEvent< +export type LogNominatedGovernorEvent = TypedEvent< [string], - LogTokenAdminAddedEventObject + LogNominatedGovernorEventObject >; -export type LogTokenAdminAddedEventFilter = - TypedEventFilter; +export type LogNominatedGovernorEventFilter = + TypedEventFilter; -export interface LogTokenAdminRemovedEventObject { - tokenAdmin: string; -} -export type LogTokenAdminRemovedEvent = TypedEvent< - [string], - LogTokenAdminRemovedEventObject +export interface LogNominationCancelledEventObject {} +export type LogNominationCancelledEvent = TypedEvent< + [], + LogNominationCancelledEventObject >; -export type LogTokenAdminRemovedEventFilter = - TypedEventFilter; +export type LogNominationCancelledEventFilter = + TypedEventFilter; -export interface LogTokenRegisteredEventObject { - assetType: BigNumber; - assetInfo: string; - quantum: BigNumber; +export interface LogOperatorAddedEventObject { + operator: string; } -export type LogTokenRegisteredEvent = TypedEvent< - [BigNumber, string, BigNumber], - LogTokenRegisteredEventObject +export type LogOperatorAddedEvent = TypedEvent< + [string], + LogOperatorAddedEventObject >; -export type LogTokenRegisteredEventFilter = - TypedEventFilter; +export type LogOperatorAddedEventFilter = + TypedEventFilter; -export interface LogUserRegisteredEventObject { - ethKey: string; - starkKey: BigNumber; - sender: string; +export interface LogOperatorRemovedEventObject { + operator: string; } -export type LogUserRegisteredEvent = TypedEvent< - [string, BigNumber, string], - LogUserRegisteredEventObject +export type LogOperatorRemovedEvent = TypedEvent< + [string], + LogOperatorRemovedEventObject >; -export type LogUserRegisteredEventFilter = - TypedEventFilter; +export type LogOperatorRemovedEventFilter = + TypedEventFilter; -export interface LogWithdrawalAllowedEventObject { - ownerKey: BigNumber; - assetType: BigNumber; - nonQuantizedAmount: BigNumber; - quantizedAmount: BigNumber; +export interface LogRegisteredEventObject { + entry: string; + entryId: string; } -export type LogWithdrawalAllowedEvent = TypedEvent< - [BigNumber, BigNumber, BigNumber, BigNumber], - LogWithdrawalAllowedEventObject +export type LogRegisteredEvent = TypedEvent< + [string, string], + LogRegisteredEventObject >; -export type LogWithdrawalAllowedEventFilter = - TypedEventFilter; +export type LogRegisteredEventFilter = TypedEventFilter; -export interface LogWithdrawalPerformedEventObject { - ownerKey: BigNumber; - assetType: BigNumber; - nonQuantizedAmount: BigNumber; - quantizedAmount: BigNumber; - recipient: string; +export interface LogRemovalIntentEventObject { + entry: string; + entryId: string; } -export type LogWithdrawalPerformedEvent = TypedEvent< - [BigNumber, BigNumber, BigNumber, BigNumber, string], - LogWithdrawalPerformedEventObject +export type LogRemovalIntentEvent = TypedEvent< + [string, string], + LogRemovalIntentEventObject >; -export type LogWithdrawalPerformedEventFilter = - TypedEventFilter; +export type LogRemovalIntentEventFilter = + TypedEventFilter; -export interface LogOperatorAddedEventObject { - operator: string; +export interface LogRemovedEventObject { + entry: string; + entryId: string; } -export type LogOperatorAddedEvent = TypedEvent< - [string], - LogOperatorAddedEventObject +export type LogRemovedEvent = TypedEvent< + [string, string], + LogRemovedEventObject >; -export type LogOperatorAddedEventFilter = - TypedEventFilter; +export type LogRemovedEventFilter = TypedEventFilter; -export interface LogOperatorRemovedEventObject { - operator: string; +export interface LogRemovedGovernorEventObject { + removedGovernor: string; } -export type LogOperatorRemovedEvent = TypedEvent< +export type LogRemovedGovernorEvent = TypedEvent< [string], - LogOperatorRemovedEventObject + LogRemovedGovernorEventObject >; -export type LogOperatorRemovedEventFilter = - TypedEventFilter; +export type LogRemovedGovernorEventFilter = + TypedEventFilter; export interface LogRootUpdateEventObject { sequenceNumber: BigNumber; @@ -1262,57 +1349,72 @@ export type LogStateTransitionFactEvent = TypedEvent< export type LogStateTransitionFactEventFilter = TypedEventFilter; -export interface LogVaultBalanceChangeAppliedEventObject { - ethKey: string; - assetId: BigNumber; - vaultId: BigNumber; - quantizedAmountChange: BigNumber; +export interface LogTokenAdminAddedEventObject { + tokenAdmin: string; } -export type LogVaultBalanceChangeAppliedEvent = TypedEvent< - [string, BigNumber, BigNumber, BigNumber], - LogVaultBalanceChangeAppliedEventObject +export type LogTokenAdminAddedEvent = TypedEvent< + [string], + LogTokenAdminAddedEventObject >; -export type LogVaultBalanceChangeAppliedEventFilter = - TypedEventFilter; +export type LogTokenAdminAddedEventFilter = + TypedEventFilter; -export interface LogFullWithdrawalRequestEventObject { - starkKey: BigNumber; - vaultId: BigNumber; +export interface LogTokenAdminRemovedEventObject { + tokenAdmin: string; } -export type LogFullWithdrawalRequestEvent = TypedEvent< - [BigNumber, BigNumber], - LogFullWithdrawalRequestEventObject +export type LogTokenAdminRemovedEvent = TypedEvent< + [string], + LogTokenAdminRemovedEventObject >; -export type LogFullWithdrawalRequestEventFilter = - TypedEventFilter; +export type LogTokenAdminRemovedEventFilter = + TypedEventFilter; -export interface LogDefaultVaultWithdrawalLockSetEventObject { - newDefaultLockTime: BigNumber; +export interface LogTokenRegisteredEventObject { + assetType: BigNumber; + assetInfo: string; + quantum: BigNumber; } -export type LogDefaultVaultWithdrawalLockSetEvent = TypedEvent< - [BigNumber], - LogDefaultVaultWithdrawalLockSetEventObject +export type LogTokenRegisteredEvent = TypedEvent< + [BigNumber, string, BigNumber], + LogTokenRegisteredEventObject >; -export type LogDefaultVaultWithdrawalLockSetEventFilter = - TypedEventFilter; +export type LogTokenRegisteredEventFilter = + TypedEventFilter; -export interface LogDepositToVaultEventObject { +export interface LogUnFrozenEventObject {} +export type LogUnFrozenEvent = TypedEvent<[], LogUnFrozenEventObject>; + +export type LogUnFrozenEventFilter = TypedEventFilter; + +export interface LogUserRegisteredEventObject { + ethKey: string; + starkKey: BigNumber; + sender: string; +} +export type LogUserRegisteredEvent = TypedEvent< + [string, BigNumber, string], + LogUserRegisteredEventObject +>; + +export type LogUserRegisteredEventFilter = + TypedEventFilter; + +export interface LogVaultBalanceChangeAppliedEventObject { ethKey: string; assetId: BigNumber; vaultId: BigNumber; - nonQuantizedAmount: BigNumber; - quantizedAmount: BigNumber; + quantizedAmountChange: BigNumber; } -export type LogDepositToVaultEvent = TypedEvent< - [string, BigNumber, BigNumber, BigNumber, BigNumber], - LogDepositToVaultEventObject +export type LogVaultBalanceChangeAppliedEvent = TypedEvent< + [string, BigNumber, BigNumber, BigNumber], + LogVaultBalanceChangeAppliedEventObject >; -export type LogDepositToVaultEventFilter = - TypedEventFilter; +export type LogVaultBalanceChangeAppliedEventFilter = + TypedEventFilter; export interface LogVaultWithdrawalLockSetEventObject { ethKey: string; @@ -1328,6 +1430,20 @@ export type LogVaultWithdrawalLockSetEvent = TypedEvent< export type LogVaultWithdrawalLockSetEventFilter = TypedEventFilter; +export interface LogWithdrawalAllowedEventObject { + ownerKey: BigNumber; + assetType: BigNumber; + nonQuantizedAmount: BigNumber; + quantizedAmount: BigNumber; +} +export type LogWithdrawalAllowedEvent = TypedEvent< + [BigNumber, BigNumber, BigNumber, BigNumber], + LogWithdrawalAllowedEventObject +>; + +export type LogWithdrawalAllowedEventFilter = + TypedEventFilter; + export interface LogWithdrawalFromVaultEventObject { ethKey: string; assetId: BigNumber; @@ -1343,24 +1459,27 @@ export type LogWithdrawalFromVaultEvent = TypedEvent< export type LogWithdrawalFromVaultEventFilter = TypedEventFilter; -export interface ImplementationActivationRescheduledEventObject { - implementation: string; - updatedActivationTime: BigNumber; +export interface LogWithdrawalPerformedEventObject { + ownerKey: BigNumber; + assetType: BigNumber; + nonQuantizedAmount: BigNumber; + quantizedAmount: BigNumber; + recipient: string; } -export type ImplementationActivationRescheduledEvent = TypedEvent< - [string, BigNumber], - ImplementationActivationRescheduledEventObject +export type LogWithdrawalPerformedEvent = TypedEvent< + [BigNumber, BigNumber, BigNumber, BigNumber, string], + LogWithdrawalPerformedEventObject >; -export type ImplementationActivationRescheduledEventFilter = - TypedEventFilter; +export type LogWithdrawalPerformedEventFilter = + TypedEventFilter; -export interface StarkV4 extends BaseContract { +export interface CoreV4 extends BaseContract { connect(signerOrProvider: Signer | Provider | string): this; attach(addressOrName: string): this; deployed(): Promise; - interface: StarkV4Interface; + interface: CoreV4Interface; queryFilter( event: TypedEventFilter, @@ -1382,13 +1501,6 @@ export interface StarkV4 extends BaseContract { removeListener: OnEvent; functions: { - VERSION(overrides?: CallOverrides): Promise<[string]>; - - initialize( - data: BytesLike, - overrides?: Overrides & { from?: string } - ): Promise; - DEPOSIT_CANCEL_DELAY(overrides?: CallOverrides): Promise<[BigNumber]>; FREEZE_GRACE_PERIOD(overrides?: CallOverrides): Promise<[BigNumber]>; @@ -1401,447 +1513,447 @@ export interface StarkV4 extends BaseContract { MAX_VERIFIER_COUNT(overrides?: CallOverrides): Promise<[BigNumber]>; + STARKEX_MAX_DEFAULT_VAULT_LOCK( + overrides?: CallOverrides + ): Promise<[BigNumber]>; + UNFREEZE_DELAY(overrides?: CallOverrides): Promise<[BigNumber]>; VERIFIER_REMOVAL_DELAY(overrides?: CallOverrides): Promise<[BigNumber]>; - announceAvailabilityVerifierRemovalIntent( - verifier: string, - overrides?: Overrides & { from?: string } - ): Promise; - - announceVerifierRemovalIntent( - verifier: string, - overrides?: Overrides & { from?: string } - ): Promise; - - getRegisteredAvailabilityVerifiers( - overrides?: CallOverrides - ): Promise<[string[]] & { _verifers: string[] }>; - - getRegisteredVerifiers( - overrides?: CallOverrides - ): Promise<[string[]] & { _verifers: string[] }>; - - isAvailabilityVerifier( - verifierAddress: string, - overrides?: CallOverrides - ): Promise<[boolean]>; - - isFrozen(overrides?: CallOverrides): Promise<[boolean]>; - - isVerifier( - verifierAddress: string, - overrides?: CallOverrides - ): Promise<[boolean]>; - - mainAcceptGovernance( - overrides?: Overrides & { from?: string } - ): Promise; + VERSION(overrides?: CallOverrides): Promise<[string]>; - mainCancelNomination( - overrides?: Overrides & { from?: string } + announceAvailabilityVerifierRemovalIntent( + verifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - mainIsGovernor( - testGovernor: string, - overrides?: CallOverrides - ): Promise<[boolean]>; - - mainNominateNewGovernor( - newGovernor: string, - overrides?: Overrides & { from?: string } + announceVerifierRemovalIntent( + verifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - mainRemoveGovernor( - governorForRemoval: string, - overrides?: Overrides & { from?: string } - ): Promise; + defaultVaultWithdrawalLock(overrides?: CallOverrides): Promise<[BigNumber]>; - registerAvailabilityVerifier( - verifier: string, - identifier: string, - overrides?: Overrides & { from?: string } + "deposit(uint256,uint256,uint256)"( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; - registerVerifier( - verifier: string, - identifier: string, - overrides?: Overrides & { from?: string } + "deposit(uint256,uint256,uint256,uint256)"( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - removeAvailabilityVerifier( - verifier: string, - overrides?: Overrides & { from?: string } + depositCancel( + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - removeVerifier( - verifier: string, - overrides?: Overrides & { from?: string } + depositERC20( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - unFreeze( - overrides?: Overrides & { from?: string } + depositERC20ToVault( + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - defaultVaultWithdrawalLock(overrides?: CallOverrides): Promise<[BigNumber]>; - - "deposit(uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string } + depositEth( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; - "deposit(uint256,uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + depositEthToVault( + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; - depositCancel( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string } + depositNft( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - depositERC20( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + depositNftReclaim( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - depositEth( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string } + depositReclaim( + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - depositNft( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string } + escape( + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + assetId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - depositNftReclaim( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string } + freezeRequest( + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - depositReclaim( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string } + fullWithdrawalRequest( + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; getActionCount(overrides?: CallOverrides): Promise<[BigNumber]>; getActionHashByIndex( - actionIndex: BigNumberish, + actionIndex: PromiseOrValue, overrides?: CallOverrides ): Promise<[string]>; getAssetInfo( - assetType: BigNumberish, + assetType: PromiseOrValue, overrides?: CallOverrides ): Promise<[string] & { assetInfo: string }>; getCancellationRequest( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise<[BigNumber] & { request: BigNumber }>; getDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise<[BigNumber] & { balance: BigNumber }>; getEthKey( - ownerKey: BigNumberish, + ownerKey: PromiseOrValue, overrides?: CallOverrides ): Promise<[string]>; getFullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise<[BigNumber] & { res: BigNumber }>; + getLastBatchId( + overrides?: CallOverrides + ): Promise<[BigNumber] & { batchId: BigNumber }>; + + getOrderRoot( + overrides?: CallOverrides + ): Promise<[BigNumber] & { root: BigNumber }>; + + getOrderTreeHeight( + overrides?: CallOverrides + ): Promise<[BigNumber] & { height: BigNumber }>; + getQuantizedDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise<[BigNumber] & { balance: BigNumber }>; + getQuantizedVaultBalance( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + getQuantum( - presumedAssetType: BigNumberish, + presumedAssetType: PromiseOrValue, overrides?: CallOverrides ): Promise<[BigNumber] & { quantum: BigNumber }>; + getRegisteredAvailabilityVerifiers( + overrides?: CallOverrides + ): Promise<[string[]] & { _verifers: string[] }>; + + getRegisteredVerifiers( + overrides?: CallOverrides + ): Promise<[string[]] & { _verifers: string[] }>; + + getSequenceNumber( + overrides?: CallOverrides + ): Promise<[BigNumber] & { seq: BigNumber }>; + + getVaultBalance( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + + getVaultRoot( + overrides?: CallOverrides + ): Promise<[BigNumber] & { root: BigNumber }>; + + getVaultTreeHeight( + overrides?: CallOverrides + ): Promise<[BigNumber] & { height: BigNumber }>; + + getVaultWithdrawalLock( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: CallOverrides + ): Promise<[BigNumber]>; + getWithdrawalBalance( - ownerKey: BigNumberish, - assetId: BigNumberish, + ownerKey: PromiseOrValue, + assetId: PromiseOrValue, overrides?: CallOverrides ): Promise<[BigNumber] & { balance: BigNumber }>; + initialize( + data: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + isAssetRegistered( - assetType: BigNumberish, + assetType: PromiseOrValue, overrides?: CallOverrides ): Promise<[boolean]>; - isTokenAdmin( - testedAdmin: string, + isAvailabilityVerifier( + verifierAddress: PromiseOrValue, overrides?: CallOverrides ): Promise<[boolean]>; - onERC721Received( - arg0: string, - arg1: string, - arg2: BigNumberish, - arg3: BytesLike, - overrides?: Overrides & { from?: string } - ): Promise; + isFrozen(overrides?: CallOverrides): Promise<[boolean]>; - orderRegistryAddress(overrides?: CallOverrides): Promise<[string]>; + isOperator( + testedOperator: PromiseOrValue, + overrides?: CallOverrides + ): Promise<[boolean]>; - registerAndDepositERC20( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } - ): Promise; + isStrictVaultBalancePolicy(overrides?: CallOverrides): Promise<[boolean]>; - registerAndDepositEth( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string } - ): Promise; + isTokenAdmin( + testedAdmin: PromiseOrValue, + overrides?: CallOverrides + ): Promise<[boolean]>; - registerEthAddress( - ethKey: string, - starkKey: BigNumberish, - starkSignature: BytesLike, - overrides?: Overrides & { from?: string } - ): Promise; + isVaultLocked( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: CallOverrides + ): Promise<[boolean]>; - registerSender( - starkKey: BigNumberish, - starkSignature: BytesLike, - overrides?: Overrides & { from?: string } - ): Promise; + isVerifier( + verifierAddress: PromiseOrValue, + overrides?: CallOverrides + ): Promise<[boolean]>; - "registerToken(uint256,bytes)"( - assetType: BigNumberish, - assetInfo: BytesLike, - overrides?: Overrides & { from?: string } + lockVault( + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + lockTime: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - "registerToken(uint256,bytes,uint256)"( - assetType: BigNumberish, - assetInfo: BytesLike, - quantum: BigNumberish, - overrides?: Overrides & { from?: string } + mainAcceptGovernance( + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - registerTokenAdmin( - newAdmin: string, - overrides?: Overrides & { from?: string } + mainCancelNomination( + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - unregisterTokenAdmin( - oldAdmin: string, - overrides?: Overrides & { from?: string } - ): Promise; + mainIsGovernor( + testGovernor: PromiseOrValue, + overrides?: CallOverrides + ): Promise<[boolean]>; - withdraw( - ownerKey: BigNumberish, - assetType: BigNumberish, - overrides?: Overrides & { from?: string } + mainNominateNewGovernor( + newGovernor: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - withdrawAndMint( - ownerKey: BigNumberish, - assetType: BigNumberish, - mintingBlob: BytesLike, - overrides?: Overrides & { from?: string } + mainRemoveGovernor( + governorForRemoval: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - withdrawNft( - ownerKey: BigNumberish, - assetType: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string } + onERC721Received( + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + arg3: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - STARKEX_MAX_DEFAULT_VAULT_LOCK( - overrides?: CallOverrides - ): Promise<[BigNumber]>; + orderRegistryAddress(overrides?: CallOverrides): Promise<[string]>; - escape( - starkKey: BigNumberish, - vaultId: BigNumberish, - assetId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + registerAndDepositERC20( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - getLastBatchId( - overrides?: CallOverrides - ): Promise<[BigNumber] & { batchId: BigNumber }>; - - getOrderRoot( - overrides?: CallOverrides - ): Promise<[BigNumber] & { root: BigNumber }>; - - getOrderTreeHeight( - overrides?: CallOverrides - ): Promise<[BigNumber] & { height: BigNumber }>; + registerAndDepositEth( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } + ): Promise; - getSequenceNumber( - overrides?: CallOverrides - ): Promise<[BigNumber] & { seq: BigNumber }>; + registerAvailabilityVerifier( + verifier: PromiseOrValue, + identifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - getVaultRoot( - overrides?: CallOverrides - ): Promise<[BigNumber] & { root: BigNumber }>; + registerEthAddress( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + starkSignature: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - getVaultTreeHeight( - overrides?: CallOverrides - ): Promise<[BigNumber] & { height: BigNumber }>; + registerOperator( + newOperator: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - isOperator( - testedOperator: string, - overrides?: CallOverrides - ): Promise<[boolean]>; + registerSender( + starkKey: PromiseOrValue, + starkSignature: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - registerOperator( - newOperator: string, - overrides?: Overrides & { from?: string } + "registerToken(uint256,bytes)"( + assetType: PromiseOrValue, + assetInfo: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - unregisterOperator( - removedOperator: string, - overrides?: Overrides & { from?: string } + "registerToken(uint256,bytes,uint256)"( + assetType: PromiseOrValue, + assetInfo: PromiseOrValue, + quantum: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - updateState( - publicInput: BigNumberish[], - applicationData: BigNumberish[], - overrides?: Overrides & { from?: string } + registerTokenAdmin( + newAdmin: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - freezeRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string } + registerVerifier( + verifier: PromiseOrValue, + identifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - fullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string } + removeAvailabilityVerifier( + verifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - depositERC20ToVault( - assetId: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + removeVerifier( + verifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - depositEthToVault( - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string } + setDefaultVaultWithdrawalLock( + newDefaultTime: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - getQuantizedVaultBalance( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: CallOverrides - ): Promise<[BigNumber]>; + unFreeze( + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - getVaultBalance( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: CallOverrides - ): Promise<[BigNumber]>; + unregisterOperator( + removedOperator: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - getVaultWithdrawalLock( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: CallOverrides - ): Promise<[BigNumber]>; + unregisterTokenAdmin( + oldAdmin: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - isStrictVaultBalancePolicy(overrides?: CallOverrides): Promise<[boolean]>; + updateImplementationActivationTime( + implementation: PromiseOrValue, + data: PromiseOrValue, + finalize: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - isVaultLocked( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: CallOverrides - ): Promise<[boolean]>; + updateState( + publicInput: PromiseOrValue[], + applicationData: PromiseOrValue[], + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - lockVault( - assetId: BigNumberish, - vaultId: BigNumberish, - lockTime: BigNumberish, - overrides?: Overrides & { from?: string } + withdraw( + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - setDefaultVaultWithdrawalLock( - newDefaultTime: BigNumberish, - overrides?: Overrides & { from?: string } + withdrawAndMint( + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawFromVault( - assetId: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - updateImplementationActivationTime( - implementation: string, - data: BytesLike, - finalize: boolean, - overrides?: Overrides & { from?: string } + withdrawNft( + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; }; - VERSION(overrides?: CallOverrides): Promise; - - initialize( - data: BytesLike, - overrides?: Overrides & { from?: string } - ): Promise; - DEPOSIT_CANCEL_DELAY(overrides?: CallOverrides): Promise; FREEZE_GRACE_PERIOD(overrides?: CallOverrides): Promise; @@ -1854,425 +1966,431 @@ export interface StarkV4 extends BaseContract { MAX_VERIFIER_COUNT(overrides?: CallOverrides): Promise; + STARKEX_MAX_DEFAULT_VAULT_LOCK(overrides?: CallOverrides): Promise; + UNFREEZE_DELAY(overrides?: CallOverrides): Promise; VERIFIER_REMOVAL_DELAY(overrides?: CallOverrides): Promise; + VERSION(overrides?: CallOverrides): Promise; + announceAvailabilityVerifierRemovalIntent( - verifier: string, - overrides?: Overrides & { from?: string } + verifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; announceVerifierRemovalIntent( - verifier: string, - overrides?: Overrides & { from?: string } - ): Promise; - - getRegisteredAvailabilityVerifiers( - overrides?: CallOverrides - ): Promise; - - getRegisteredVerifiers(overrides?: CallOverrides): Promise; - - isAvailabilityVerifier( - verifierAddress: string, - overrides?: CallOverrides - ): Promise; - - isFrozen(overrides?: CallOverrides): Promise; - - isVerifier( - verifierAddress: string, - overrides?: CallOverrides - ): Promise; - - mainAcceptGovernance( - overrides?: Overrides & { from?: string } - ): Promise; - - mainCancelNomination( - overrides?: Overrides & { from?: string } - ): Promise; - - mainIsGovernor( - testGovernor: string, - overrides?: CallOverrides - ): Promise; - - mainNominateNewGovernor( - newGovernor: string, - overrides?: Overrides & { from?: string } - ): Promise; - - mainRemoveGovernor( - governorForRemoval: string, - overrides?: Overrides & { from?: string } - ): Promise; - - registerAvailabilityVerifier( - verifier: string, - identifier: string, - overrides?: Overrides & { from?: string } - ): Promise; - - registerVerifier( - verifier: string, - identifier: string, - overrides?: Overrides & { from?: string } - ): Promise; - - removeAvailabilityVerifier( - verifier: string, - overrides?: Overrides & { from?: string } - ): Promise; - - removeVerifier( - verifier: string, - overrides?: Overrides & { from?: string } - ): Promise; - - unFreeze( - overrides?: Overrides & { from?: string } + verifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; defaultVaultWithdrawalLock(overrides?: CallOverrides): Promise; "deposit(uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; "deposit(uint256,uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositCancel( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string } + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositERC20( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + depositERC20ToVault( + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + depositEth( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; - depositEth( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string } + depositEthToVault( + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; depositNft( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositNftReclaim( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string } + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; depositReclaim( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string } + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + escape( + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + assetId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + freezeRequest( + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + fullWithdrawalRequest( + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; getActionCount(overrides?: CallOverrides): Promise; getActionHashByIndex( - actionIndex: BigNumberish, + actionIndex: PromiseOrValue, overrides?: CallOverrides ): Promise; getAssetInfo( - assetType: BigNumberish, + assetType: PromiseOrValue, overrides?: CallOverrides ): Promise; getCancellationRequest( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; - getEthKey(ownerKey: BigNumberish, overrides?: CallOverrides): Promise; + getEthKey( + ownerKey: PromiseOrValue, + overrides?: CallOverrides + ): Promise; getFullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; + getLastBatchId(overrides?: CallOverrides): Promise; + + getOrderRoot(overrides?: CallOverrides): Promise; + + getOrderTreeHeight(overrides?: CallOverrides): Promise; + getQuantizedDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + getQuantizedVaultBalance( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getQuantum( - presumedAssetType: BigNumberish, + presumedAssetType: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + getRegisteredAvailabilityVerifiers( + overrides?: CallOverrides + ): Promise; + + getRegisteredVerifiers(overrides?: CallOverrides): Promise; + + getSequenceNumber(overrides?: CallOverrides): Promise; + + getVaultBalance( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + getVaultRoot(overrides?: CallOverrides): Promise; + + getVaultTreeHeight(overrides?: CallOverrides): Promise; + + getVaultWithdrawalLock( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getWithdrawalBalance( - ownerKey: BigNumberish, - assetId: BigNumberish, + ownerKey: PromiseOrValue, + assetId: PromiseOrValue, overrides?: CallOverrides ): Promise; + initialize( + data: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + isAssetRegistered( - assetType: BigNumberish, + assetType: PromiseOrValue, overrides?: CallOverrides ): Promise; - isTokenAdmin( - testedAdmin: string, + isAvailabilityVerifier( + verifierAddress: PromiseOrValue, overrides?: CallOverrides ): Promise; - onERC721Received( - arg0: string, - arg1: string, - arg2: BigNumberish, - arg3: BytesLike, - overrides?: Overrides & { from?: string } - ): Promise; + isFrozen(overrides?: CallOverrides): Promise; - orderRegistryAddress(overrides?: CallOverrides): Promise; + isOperator( + testedOperator: PromiseOrValue, + overrides?: CallOverrides + ): Promise; - registerAndDepositERC20( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } - ): Promise; + isStrictVaultBalancePolicy(overrides?: CallOverrides): Promise; - registerAndDepositEth( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string } - ): Promise; + isTokenAdmin( + testedAdmin: PromiseOrValue, + overrides?: CallOverrides + ): Promise; - registerEthAddress( - ethKey: string, - starkKey: BigNumberish, - starkSignature: BytesLike, - overrides?: Overrides & { from?: string } - ): Promise; + isVaultLocked( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: CallOverrides + ): Promise; - registerSender( - starkKey: BigNumberish, - starkSignature: BytesLike, - overrides?: Overrides & { from?: string } - ): Promise; + isVerifier( + verifierAddress: PromiseOrValue, + overrides?: CallOverrides + ): Promise; - "registerToken(uint256,bytes)"( - assetType: BigNumberish, - assetInfo: BytesLike, - overrides?: Overrides & { from?: string } + lockVault( + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + lockTime: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - "registerToken(uint256,bytes,uint256)"( - assetType: BigNumberish, - assetInfo: BytesLike, - quantum: BigNumberish, - overrides?: Overrides & { from?: string } + mainAcceptGovernance( + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - registerTokenAdmin( - newAdmin: string, - overrides?: Overrides & { from?: string } + mainCancelNomination( + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - unregisterTokenAdmin( - oldAdmin: string, - overrides?: Overrides & { from?: string } - ): Promise; + mainIsGovernor( + testGovernor: PromiseOrValue, + overrides?: CallOverrides + ): Promise; - withdraw( - ownerKey: BigNumberish, - assetType: BigNumberish, - overrides?: Overrides & { from?: string } + mainNominateNewGovernor( + newGovernor: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - withdrawAndMint( - ownerKey: BigNumberish, - assetType: BigNumberish, - mintingBlob: BytesLike, - overrides?: Overrides & { from?: string } + mainRemoveGovernor( + governorForRemoval: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - withdrawNft( - ownerKey: BigNumberish, - assetType: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string } + onERC721Received( + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + arg3: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - STARKEX_MAX_DEFAULT_VAULT_LOCK(overrides?: CallOverrides): Promise; + orderRegistryAddress(overrides?: CallOverrides): Promise; - escape( - starkKey: BigNumberish, - vaultId: BigNumberish, - assetId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + registerAndDepositERC20( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - getLastBatchId(overrides?: CallOverrides): Promise; - - getOrderRoot(overrides?: CallOverrides): Promise; - - getOrderTreeHeight(overrides?: CallOverrides): Promise; + registerAndDepositEth( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } + ): Promise; - getSequenceNumber(overrides?: CallOverrides): Promise; + registerAvailabilityVerifier( + verifier: PromiseOrValue, + identifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - getVaultRoot(overrides?: CallOverrides): Promise; + registerEthAddress( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + starkSignature: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - getVaultTreeHeight(overrides?: CallOverrides): Promise; + registerOperator( + newOperator: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - isOperator( - testedOperator: string, - overrides?: CallOverrides - ): Promise; + registerSender( + starkKey: PromiseOrValue, + starkSignature: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - registerOperator( - newOperator: string, - overrides?: Overrides & { from?: string } + "registerToken(uint256,bytes)"( + assetType: PromiseOrValue, + assetInfo: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - unregisterOperator( - removedOperator: string, - overrides?: Overrides & { from?: string } + "registerToken(uint256,bytes,uint256)"( + assetType: PromiseOrValue, + assetInfo: PromiseOrValue, + quantum: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - updateState( - publicInput: BigNumberish[], - applicationData: BigNumberish[], - overrides?: Overrides & { from?: string } + registerTokenAdmin( + newAdmin: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - freezeRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string } + registerVerifier( + verifier: PromiseOrValue, + identifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - fullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string } + removeAvailabilityVerifier( + verifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - depositERC20ToVault( - assetId: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + removeVerifier( + verifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - depositEthToVault( - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string } + setDefaultVaultWithdrawalLock( + newDefaultTime: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - getQuantizedVaultBalance( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: CallOverrides - ): Promise; + unFreeze( + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - getVaultBalance( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: CallOverrides - ): Promise; + unregisterOperator( + removedOperator: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - getVaultWithdrawalLock( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: CallOverrides - ): Promise; + unregisterTokenAdmin( + oldAdmin: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - isStrictVaultBalancePolicy(overrides?: CallOverrides): Promise; + updateImplementationActivationTime( + implementation: PromiseOrValue, + data: PromiseOrValue, + finalize: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - isVaultLocked( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: CallOverrides - ): Promise; + updateState( + publicInput: PromiseOrValue[], + applicationData: PromiseOrValue[], + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - lockVault( - assetId: BigNumberish, - vaultId: BigNumberish, - lockTime: BigNumberish, - overrides?: Overrides & { from?: string } + withdraw( + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - setDefaultVaultWithdrawalLock( - newDefaultTime: BigNumberish, - overrides?: Overrides & { from?: string } + withdrawAndMint( + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawFromVault( - assetId: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - updateImplementationActivationTime( - implementation: string, - data: BytesLike, - finalize: boolean, - overrides?: Overrides & { from?: string } + withdrawNft( + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; callStatic: { - VERSION(overrides?: CallOverrides): Promise; - - initialize(data: BytesLike, overrides?: CallOverrides): Promise; - DEPOSIT_CANCEL_DELAY(overrides?: CallOverrides): Promise; FREEZE_GRACE_PERIOD(overrides?: CallOverrides): Promise; @@ -2285,463 +2403,443 @@ export interface StarkV4 extends BaseContract { MAX_VERIFIER_COUNT(overrides?: CallOverrides): Promise; + STARKEX_MAX_DEFAULT_VAULT_LOCK( + overrides?: CallOverrides + ): Promise; + UNFREEZE_DELAY(overrides?: CallOverrides): Promise; VERIFIER_REMOVAL_DELAY(overrides?: CallOverrides): Promise; + VERSION(overrides?: CallOverrides): Promise; + announceAvailabilityVerifierRemovalIntent( - verifier: string, + verifier: PromiseOrValue, overrides?: CallOverrides ): Promise; announceVerifierRemovalIntent( - verifier: string, + verifier: PromiseOrValue, overrides?: CallOverrides ): Promise; - getRegisteredAvailabilityVerifiers( - overrides?: CallOverrides - ): Promise; - - getRegisteredVerifiers(overrides?: CallOverrides): Promise; - - isAvailabilityVerifier( - verifierAddress: string, - overrides?: CallOverrides - ): Promise; - - isFrozen(overrides?: CallOverrides): Promise; - - isVerifier( - verifierAddress: string, - overrides?: CallOverrides - ): Promise; - - mainAcceptGovernance(overrides?: CallOverrides): Promise; - - mainCancelNomination(overrides?: CallOverrides): Promise; - - mainIsGovernor( - testGovernor: string, - overrides?: CallOverrides - ): Promise; + defaultVaultWithdrawalLock(overrides?: CallOverrides): Promise; - mainNominateNewGovernor( - newGovernor: string, + "deposit(uint256,uint256,uint256)"( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; - mainRemoveGovernor( - governorForRemoval: string, + "deposit(uint256,uint256,uint256,uint256)"( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, overrides?: CallOverrides ): Promise; - registerAvailabilityVerifier( - verifier: string, - identifier: string, + depositCancel( + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; - registerVerifier( - verifier: string, - identifier: string, + depositERC20( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, overrides?: CallOverrides ): Promise; - removeAvailabilityVerifier( - verifier: string, + depositERC20ToVault( + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, overrides?: CallOverrides ): Promise; - removeVerifier(verifier: string, overrides?: CallOverrides): Promise; - - unFreeze(overrides?: CallOverrides): Promise; - - defaultVaultWithdrawalLock(overrides?: CallOverrides): Promise; - - "deposit(uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, + depositEth( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; - "deposit(uint256,uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, + depositEthToVault( + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; - depositCancel( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + depositNft( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, overrides?: CallOverrides ): Promise; - depositERC20( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, + depositNftReclaim( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, overrides?: CallOverrides ): Promise; - depositEth( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, + depositReclaim( + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; - depositNft( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, + escape( + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + assetId: PromiseOrValue, + quantizedAmount: PromiseOrValue, overrides?: CallOverrides ): Promise; - depositNftReclaim( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, + freezeRequest( + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; - depositReclaim( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + fullWithdrawalRequest( + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getActionCount(overrides?: CallOverrides): Promise; getActionHashByIndex( - actionIndex: BigNumberish, + actionIndex: PromiseOrValue, overrides?: CallOverrides ): Promise; getAssetInfo( - assetType: BigNumberish, + assetType: PromiseOrValue, overrides?: CallOverrides ): Promise; getCancellationRequest( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getEthKey( - ownerKey: BigNumberish, + ownerKey: PromiseOrValue, overrides?: CallOverrides ): Promise; getFullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; + getLastBatchId(overrides?: CallOverrides): Promise; + + getOrderRoot(overrides?: CallOverrides): Promise; + + getOrderTreeHeight(overrides?: CallOverrides): Promise; + getQuantizedDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + getQuantizedVaultBalance( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getQuantum( - presumedAssetType: BigNumberish, + presumedAssetType: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + getRegisteredAvailabilityVerifiers( + overrides?: CallOverrides + ): Promise; + + getRegisteredVerifiers(overrides?: CallOverrides): Promise; + + getSequenceNumber(overrides?: CallOverrides): Promise; + + getVaultBalance( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + getVaultRoot(overrides?: CallOverrides): Promise; + + getVaultTreeHeight(overrides?: CallOverrides): Promise; + + getVaultWithdrawalLock( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getWithdrawalBalance( - ownerKey: BigNumberish, - assetId: BigNumberish, + ownerKey: PromiseOrValue, + assetId: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + initialize( + data: PromiseOrValue, overrides?: CallOverrides - ): Promise; + ): Promise; isAssetRegistered( - assetType: BigNumberish, + assetType: PromiseOrValue, overrides?: CallOverrides ): Promise; - isTokenAdmin( - testedAdmin: string, + isAvailabilityVerifier( + verifierAddress: PromiseOrValue, overrides?: CallOverrides ): Promise; - onERC721Received( - arg0: string, - arg1: string, - arg2: BigNumberish, - arg3: BytesLike, + isFrozen(overrides?: CallOverrides): Promise; + + isOperator( + testedOperator: PromiseOrValue, overrides?: CallOverrides - ): Promise; + ): Promise; - orderRegistryAddress(overrides?: CallOverrides): Promise; + isStrictVaultBalancePolicy(overrides?: CallOverrides): Promise; - registerAndDepositERC20( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, + isTokenAdmin( + testedAdmin: PromiseOrValue, overrides?: CallOverrides - ): Promise; + ): Promise; - registerAndDepositEth( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, + isVaultLocked( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides - ): Promise; + ): Promise; - registerEthAddress( - ethKey: string, - starkKey: BigNumberish, - starkSignature: BytesLike, + isVerifier( + verifierAddress: PromiseOrValue, overrides?: CallOverrides - ): Promise; + ): Promise; - registerSender( - starkKey: BigNumberish, - starkSignature: BytesLike, + lockVault( + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + lockTime: PromiseOrValue, overrides?: CallOverrides ): Promise; - "registerToken(uint256,bytes)"( - assetType: BigNumberish, - assetInfo: BytesLike, + mainAcceptGovernance(overrides?: CallOverrides): Promise; + + mainCancelNomination(overrides?: CallOverrides): Promise; + + mainIsGovernor( + testGovernor: PromiseOrValue, overrides?: CallOverrides - ): Promise; + ): Promise; - "registerToken(uint256,bytes,uint256)"( - assetType: BigNumberish, - assetInfo: BytesLike, - quantum: BigNumberish, + mainNominateNewGovernor( + newGovernor: PromiseOrValue, overrides?: CallOverrides ): Promise; - registerTokenAdmin( - newAdmin: string, + mainRemoveGovernor( + governorForRemoval: PromiseOrValue, overrides?: CallOverrides ): Promise; - unregisterTokenAdmin( - oldAdmin: string, + onERC721Received( + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + arg3: PromiseOrValue, overrides?: CallOverrides - ): Promise; + ): Promise; - withdraw( - ownerKey: BigNumberish, - assetType: BigNumberish, + orderRegistryAddress(overrides?: CallOverrides): Promise; + + registerAndDepositERC20( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, overrides?: CallOverrides ): Promise; - withdrawAndMint( - ownerKey: BigNumberish, - assetType: BigNumberish, - mintingBlob: BytesLike, + registerAndDepositEth( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; - withdrawNft( - ownerKey: BigNumberish, - assetType: BigNumberish, - tokenId: BigNumberish, + registerAvailabilityVerifier( + verifier: PromiseOrValue, + identifier: PromiseOrValue, overrides?: CallOverrides ): Promise; - STARKEX_MAX_DEFAULT_VAULT_LOCK( + registerEthAddress( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + starkSignature: PromiseOrValue, overrides?: CallOverrides - ): Promise; + ): Promise; - escape( - starkKey: BigNumberish, - vaultId: BigNumberish, - assetId: BigNumberish, - quantizedAmount: BigNumberish, + registerOperator( + newOperator: PromiseOrValue, overrides?: CallOverrides ): Promise; - getLastBatchId(overrides?: CallOverrides): Promise; - - getOrderRoot(overrides?: CallOverrides): Promise; - - getOrderTreeHeight(overrides?: CallOverrides): Promise; - - getSequenceNumber(overrides?: CallOverrides): Promise; - - getVaultRoot(overrides?: CallOverrides): Promise; - - getVaultTreeHeight(overrides?: CallOverrides): Promise; - - isOperator( - testedOperator: string, + registerSender( + starkKey: PromiseOrValue, + starkSignature: PromiseOrValue, overrides?: CallOverrides - ): Promise; + ): Promise; - registerOperator( - newOperator: string, + "registerToken(uint256,bytes)"( + assetType: PromiseOrValue, + assetInfo: PromiseOrValue, overrides?: CallOverrides ): Promise; - unregisterOperator( - removedOperator: string, + "registerToken(uint256,bytes,uint256)"( + assetType: PromiseOrValue, + assetInfo: PromiseOrValue, + quantum: PromiseOrValue, overrides?: CallOverrides ): Promise; - updateState( - publicInput: BigNumberish[], - applicationData: BigNumberish[], + registerTokenAdmin( + newAdmin: PromiseOrValue, overrides?: CallOverrides ): Promise; - freezeRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, + registerVerifier( + verifier: PromiseOrValue, + identifier: PromiseOrValue, overrides?: CallOverrides ): Promise; - fullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, + removeAvailabilityVerifier( + verifier: PromiseOrValue, overrides?: CallOverrides ): Promise; - depositERC20ToVault( - assetId: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, + removeVerifier( + verifier: PromiseOrValue, overrides?: CallOverrides ): Promise; - depositEthToVault( - assetId: BigNumberish, - vaultId: BigNumberish, + setDefaultVaultWithdrawalLock( + newDefaultTime: PromiseOrValue, overrides?: CallOverrides ): Promise; - getQuantizedVaultBalance( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: CallOverrides - ): Promise; + unFreeze(overrides?: CallOverrides): Promise; - getVaultBalance( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, + unregisterOperator( + removedOperator: PromiseOrValue, overrides?: CallOverrides - ): Promise; + ): Promise; - getVaultWithdrawalLock( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, + unregisterTokenAdmin( + oldAdmin: PromiseOrValue, overrides?: CallOverrides - ): Promise; + ): Promise; - isStrictVaultBalancePolicy(overrides?: CallOverrides): Promise; + updateImplementationActivationTime( + implementation: PromiseOrValue, + data: PromiseOrValue, + finalize: PromiseOrValue, + overrides?: CallOverrides + ): Promise; - isVaultLocked( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, + updateState( + publicInput: PromiseOrValue[], + applicationData: PromiseOrValue[], overrides?: CallOverrides - ): Promise; + ): Promise; - lockVault( - assetId: BigNumberish, - vaultId: BigNumberish, - lockTime: BigNumberish, + withdraw( + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, overrides?: CallOverrides ): Promise; - setDefaultVaultWithdrawalLock( - newDefaultTime: BigNumberish, + withdrawAndMint( + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, overrides?: CallOverrides ): Promise; withdrawFromVault( - assetId: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, overrides?: CallOverrides ): Promise; - updateImplementationActivationTime( - implementation: string, - data: BytesLike, - finalize: boolean, + withdrawNft( + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, overrides?: CallOverrides ): Promise; }; filters: { - "LogFrozen()"(): LogFrozenEventFilter; - LogFrozen(): LogFrozenEventFilter; - - "LogNewGovernorAccepted(address)"( - acceptedGovernor?: null - ): LogNewGovernorAcceptedEventFilter; - LogNewGovernorAccepted( - acceptedGovernor?: null - ): LogNewGovernorAcceptedEventFilter; - - "LogNominatedGovernor(address)"( - nominatedGovernor?: null - ): LogNominatedGovernorEventFilter; - LogNominatedGovernor( - nominatedGovernor?: null - ): LogNominatedGovernorEventFilter; - - "LogNominationCancelled()"(): LogNominationCancelledEventFilter; - LogNominationCancelled(): LogNominationCancelledEventFilter; - - "LogRegistered(address,string)"( - entry?: null, - entryId?: null - ): LogRegisteredEventFilter; - LogRegistered(entry?: null, entryId?: null): LogRegisteredEventFilter; - - "LogRemovalIntent(address,string)"( - entry?: null, - entryId?: null - ): LogRemovalIntentEventFilter; - LogRemovalIntent(entry?: null, entryId?: null): LogRemovalIntentEventFilter; - - "LogRemoved(address,string)"( - entry?: null, - entryId?: null - ): LogRemovedEventFilter; - LogRemoved(entry?: null, entryId?: null): LogRemovedEventFilter; - - "LogRemovedGovernor(address)"( - removedGovernor?: null - ): LogRemovedGovernorEventFilter; - LogRemovedGovernor(removedGovernor?: null): LogRemovedGovernorEventFilter; + "ImplementationActivationRescheduled(address,uint256)"( + implementation?: PromiseOrValue | null, + updatedActivationTime?: null + ): ImplementationActivationRescheduledEventFilter; + ImplementationActivationRescheduled( + implementation?: PromiseOrValue | null, + updatedActivationTime?: null + ): ImplementationActivationRescheduledEventFilter; - "LogUnFrozen()"(): LogUnFrozenEventFilter; - LogUnFrozen(): LogUnFrozenEventFilter; + "LogDefaultVaultWithdrawalLockSet(uint256)"( + newDefaultLockTime?: null + ): LogDefaultVaultWithdrawalLockSetEventFilter; + LogDefaultVaultWithdrawalLockSet( + newDefaultLockTime?: null + ): LogDefaultVaultWithdrawalLockSetEventFilter; "LogDeposit(address,uint256,uint256,uint256,uint256,uint256)"( depositorEthKey?: null, @@ -2801,6 +2899,33 @@ export interface StarkV4 extends BaseContract { assetId?: null ): LogDepositNftCancelReclaimedEventFilter; + "LogDepositToVault(address,uint256,uint256,uint256,uint256)"( + ethKey?: null, + assetId?: null, + vaultId?: null, + nonQuantizedAmount?: null, + quantizedAmount?: null + ): LogDepositToVaultEventFilter; + LogDepositToVault( + ethKey?: null, + assetId?: null, + vaultId?: null, + nonQuantizedAmount?: null, + quantizedAmount?: null + ): LogDepositToVaultEventFilter; + + "LogFrozen()"(): LogFrozenEventFilter; + LogFrozen(): LogFrozenEventFilter; + + "LogFullWithdrawalRequest(uint256,uint256)"( + starkKey?: null, + vaultId?: null + ): LogFullWithdrawalRequestEventFilter; + LogFullWithdrawalRequest( + starkKey?: null, + vaultId?: null + ): LogFullWithdrawalRequestEventFilter; + "LogMintWithdrawalPerformed(uint256,uint256,uint256,uint256,uint256)"( ownerKey?: null, assetType?: null, @@ -2827,6 +2952,13 @@ export interface StarkV4 extends BaseContract { quantizedAmount?: null ): LogMintableWithdrawalAllowedEventFilter; + "LogNewGovernorAccepted(address)"( + acceptedGovernor?: null + ): LogNewGovernorAcceptedEventFilter; + LogNewGovernorAccepted( + acceptedGovernor?: null + ): LogNewGovernorAcceptedEventFilter; + "LogNftDeposit(address,uint256,uint256,uint256,uint256,uint256)"( depositorEthKey?: null, starkKey?: null, @@ -2868,6 +3000,67 @@ export interface StarkV4 extends BaseContract { recipient?: null ): LogNftWithdrawalPerformedEventFilter; + "LogNominatedGovernor(address)"( + nominatedGovernor?: null + ): LogNominatedGovernorEventFilter; + LogNominatedGovernor( + nominatedGovernor?: null + ): LogNominatedGovernorEventFilter; + + "LogNominationCancelled()"(): LogNominationCancelledEventFilter; + LogNominationCancelled(): LogNominationCancelledEventFilter; + + "LogOperatorAdded(address)"(operator?: null): LogOperatorAddedEventFilter; + LogOperatorAdded(operator?: null): LogOperatorAddedEventFilter; + + "LogOperatorRemoved(address)"( + operator?: null + ): LogOperatorRemovedEventFilter; + LogOperatorRemoved(operator?: null): LogOperatorRemovedEventFilter; + + "LogRegistered(address,string)"( + entry?: null, + entryId?: null + ): LogRegisteredEventFilter; + LogRegistered(entry?: null, entryId?: null): LogRegisteredEventFilter; + + "LogRemovalIntent(address,string)"( + entry?: null, + entryId?: null + ): LogRemovalIntentEventFilter; + LogRemovalIntent(entry?: null, entryId?: null): LogRemovalIntentEventFilter; + + "LogRemoved(address,string)"( + entry?: null, + entryId?: null + ): LogRemovedEventFilter; + LogRemoved(entry?: null, entryId?: null): LogRemovedEventFilter; + + "LogRemovedGovernor(address)"( + removedGovernor?: null + ): LogRemovedGovernorEventFilter; + LogRemovedGovernor(removedGovernor?: null): LogRemovedGovernorEventFilter; + + "LogRootUpdate(uint256,uint256,uint256,uint256)"( + sequenceNumber?: null, + batchId?: null, + vaultRoot?: null, + orderRoot?: null + ): LogRootUpdateEventFilter; + LogRootUpdate( + sequenceNumber?: null, + batchId?: null, + vaultRoot?: null, + orderRoot?: null + ): LogRootUpdateEventFilter; + + "LogStateTransitionFact(bytes32)"( + stateTransitionFact?: null + ): LogStateTransitionFactEventFilter; + LogStateTransitionFact( + stateTransitionFact?: null + ): LogStateTransitionFactEventFilter; + "LogTokenAdminAdded(address)"( tokenAdmin?: null ): LogTokenAdminAddedEventFilter; @@ -2889,6 +3082,9 @@ export interface StarkV4 extends BaseContract { quantum?: null ): LogTokenRegisteredEventFilter; + "LogUnFrozen()"(): LogUnFrozenEventFilter; + LogUnFrozen(): LogUnFrozenEventFilter; + "LogUserRegistered(address,uint256,address)"( ethKey?: null, starkKey?: null, @@ -2900,62 +3096,6 @@ export interface StarkV4 extends BaseContract { sender?: null ): LogUserRegisteredEventFilter; - "LogWithdrawalAllowed(uint256,uint256,uint256,uint256)"( - ownerKey?: null, - assetType?: null, - nonQuantizedAmount?: null, - quantizedAmount?: null - ): LogWithdrawalAllowedEventFilter; - LogWithdrawalAllowed( - ownerKey?: null, - assetType?: null, - nonQuantizedAmount?: null, - quantizedAmount?: null - ): LogWithdrawalAllowedEventFilter; - - "LogWithdrawalPerformed(uint256,uint256,uint256,uint256,address)"( - ownerKey?: null, - assetType?: null, - nonQuantizedAmount?: null, - quantizedAmount?: null, - recipient?: null - ): LogWithdrawalPerformedEventFilter; - LogWithdrawalPerformed( - ownerKey?: null, - assetType?: null, - nonQuantizedAmount?: null, - quantizedAmount?: null, - recipient?: null - ): LogWithdrawalPerformedEventFilter; - - "LogOperatorAdded(address)"(operator?: null): LogOperatorAddedEventFilter; - LogOperatorAdded(operator?: null): LogOperatorAddedEventFilter; - - "LogOperatorRemoved(address)"( - operator?: null - ): LogOperatorRemovedEventFilter; - LogOperatorRemoved(operator?: null): LogOperatorRemovedEventFilter; - - "LogRootUpdate(uint256,uint256,uint256,uint256)"( - sequenceNumber?: null, - batchId?: null, - vaultRoot?: null, - orderRoot?: null - ): LogRootUpdateEventFilter; - LogRootUpdate( - sequenceNumber?: null, - batchId?: null, - vaultRoot?: null, - orderRoot?: null - ): LogRootUpdateEventFilter; - - "LogStateTransitionFact(bytes32)"( - stateTransitionFact?: null - ): LogStateTransitionFactEventFilter; - LogStateTransitionFact( - stateTransitionFact?: null - ): LogStateTransitionFactEventFilter; - "LogVaultBalanceChangeApplied(address,uint256,uint256,int256)"( ethKey?: null, assetId?: null, @@ -2969,37 +3109,6 @@ export interface StarkV4 extends BaseContract { quantizedAmountChange?: null ): LogVaultBalanceChangeAppliedEventFilter; - "LogFullWithdrawalRequest(uint256,uint256)"( - starkKey?: null, - vaultId?: null - ): LogFullWithdrawalRequestEventFilter; - LogFullWithdrawalRequest( - starkKey?: null, - vaultId?: null - ): LogFullWithdrawalRequestEventFilter; - - "LogDefaultVaultWithdrawalLockSet(uint256)"( - newDefaultLockTime?: null - ): LogDefaultVaultWithdrawalLockSetEventFilter; - LogDefaultVaultWithdrawalLockSet( - newDefaultLockTime?: null - ): LogDefaultVaultWithdrawalLockSetEventFilter; - - "LogDepositToVault(address,uint256,uint256,uint256,uint256)"( - ethKey?: null, - assetId?: null, - vaultId?: null, - nonQuantizedAmount?: null, - quantizedAmount?: null - ): LogDepositToVaultEventFilter; - LogDepositToVault( - ethKey?: null, - assetId?: null, - vaultId?: null, - nonQuantizedAmount?: null, - quantizedAmount?: null - ): LogDepositToVaultEventFilter; - "LogVaultWithdrawalLockSet(address,uint256,uint256,uint256)"( ethKey?: null, assetId?: null, @@ -3013,6 +3122,19 @@ export interface StarkV4 extends BaseContract { timeRelease?: null ): LogVaultWithdrawalLockSetEventFilter; + "LogWithdrawalAllowed(uint256,uint256,uint256,uint256)"( + ownerKey?: null, + assetType?: null, + nonQuantizedAmount?: null, + quantizedAmount?: null + ): LogWithdrawalAllowedEventFilter; + LogWithdrawalAllowed( + ownerKey?: null, + assetType?: null, + nonQuantizedAmount?: null, + quantizedAmount?: null + ): LogWithdrawalAllowedEventFilter; + "LogWithdrawalFromVault(address,uint256,uint256,uint256,uint256)"( ethKey?: null, assetId?: null, @@ -3028,24 +3150,23 @@ export interface StarkV4 extends BaseContract { quantizedAmount?: null ): LogWithdrawalFromVaultEventFilter; - "ImplementationActivationRescheduled(address,uint256)"( - implementation?: string | null, - updatedActivationTime?: null - ): ImplementationActivationRescheduledEventFilter; - ImplementationActivationRescheduled( - implementation?: string | null, - updatedActivationTime?: null - ): ImplementationActivationRescheduledEventFilter; + "LogWithdrawalPerformed(uint256,uint256,uint256,uint256,address)"( + ownerKey?: null, + assetType?: null, + nonQuantizedAmount?: null, + quantizedAmount?: null, + recipient?: null + ): LogWithdrawalPerformedEventFilter; + LogWithdrawalPerformed( + ownerKey?: null, + assetType?: null, + nonQuantizedAmount?: null, + quantizedAmount?: null, + recipient?: null + ): LogWithdrawalPerformedEventFilter; }; estimateGas: { - VERSION(overrides?: CallOverrides): Promise; - - initialize( - data: BytesLike, - overrides?: Overrides & { from?: string } - ): Promise; - DEPOSIT_CANCEL_DELAY(overrides?: CallOverrides): Promise; FREEZE_GRACE_PERIOD(overrides?: CallOverrides): Promise; @@ -3058,432 +3179,434 @@ export interface StarkV4 extends BaseContract { MAX_VERIFIER_COUNT(overrides?: CallOverrides): Promise; - UNFREEZE_DELAY(overrides?: CallOverrides): Promise; - - VERIFIER_REMOVAL_DELAY(overrides?: CallOverrides): Promise; - - announceAvailabilityVerifierRemovalIntent( - verifier: string, - overrides?: Overrides & { from?: string } - ): Promise; - - announceVerifierRemovalIntent( - verifier: string, - overrides?: Overrides & { from?: string } - ): Promise; - - getRegisteredAvailabilityVerifiers( - overrides?: CallOverrides - ): Promise; - - getRegisteredVerifiers(overrides?: CallOverrides): Promise; - - isAvailabilityVerifier( - verifierAddress: string, + STARKEX_MAX_DEFAULT_VAULT_LOCK( overrides?: CallOverrides ): Promise; - isFrozen(overrides?: CallOverrides): Promise; + UNFREEZE_DELAY(overrides?: CallOverrides): Promise; - isVerifier( - verifierAddress: string, - overrides?: CallOverrides - ): Promise; + VERIFIER_REMOVAL_DELAY(overrides?: CallOverrides): Promise; - mainAcceptGovernance( - overrides?: Overrides & { from?: string } - ): Promise; + VERSION(overrides?: CallOverrides): Promise; - mainCancelNomination( - overrides?: Overrides & { from?: string } + announceAvailabilityVerifierRemovalIntent( + verifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - mainIsGovernor( - testGovernor: string, - overrides?: CallOverrides + announceVerifierRemovalIntent( + verifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - mainNominateNewGovernor( - newGovernor: string, - overrides?: Overrides & { from?: string } - ): Promise; + defaultVaultWithdrawalLock(overrides?: CallOverrides): Promise; - mainRemoveGovernor( - governorForRemoval: string, - overrides?: Overrides & { from?: string } + "deposit(uint256,uint256,uint256)"( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; - registerAvailabilityVerifier( - verifier: string, - identifier: string, - overrides?: Overrides & { from?: string } + "deposit(uint256,uint256,uint256,uint256)"( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - registerVerifier( - verifier: string, - identifier: string, - overrides?: Overrides & { from?: string } + depositCancel( + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - removeAvailabilityVerifier( - verifier: string, - overrides?: Overrides & { from?: string } + depositERC20( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - removeVerifier( - verifier: string, - overrides?: Overrides & { from?: string } + depositERC20ToVault( + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - unFreeze(overrides?: Overrides & { from?: string }): Promise; - - defaultVaultWithdrawalLock(overrides?: CallOverrides): Promise; - - "deposit(uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string } + depositEth( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; - "deposit(uint256,uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + depositEthToVault( + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; - depositCancel( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string } + depositNft( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - depositERC20( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + depositNftReclaim( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - depositEth( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string } + depositReclaim( + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - depositNft( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string } + escape( + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + assetId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - depositNftReclaim( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string } + freezeRequest( + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - depositReclaim( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string } + fullWithdrawalRequest( + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; getActionCount(overrides?: CallOverrides): Promise; getActionHashByIndex( - actionIndex: BigNumberish, + actionIndex: PromiseOrValue, overrides?: CallOverrides ): Promise; getAssetInfo( - assetType: BigNumberish, + assetType: PromiseOrValue, overrides?: CallOverrides ): Promise; getCancellationRequest( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getEthKey( - ownerKey: BigNumberish, + ownerKey: PromiseOrValue, overrides?: CallOverrides ): Promise; getFullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; + getLastBatchId(overrides?: CallOverrides): Promise; + + getOrderRoot(overrides?: CallOverrides): Promise; + + getOrderTreeHeight(overrides?: CallOverrides): Promise; + getQuantizedDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; - getQuantum( - presumedAssetType: BigNumberish, + getQuantizedVaultBalance( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; - getWithdrawalBalance( - ownerKey: BigNumberish, - assetId: BigNumberish, + getQuantum( + presumedAssetType: PromiseOrValue, overrides?: CallOverrides ): Promise; - isAssetRegistered( - assetType: BigNumberish, + getRegisteredAvailabilityVerifiers( overrides?: CallOverrides ): Promise; - isTokenAdmin( - testedAdmin: string, + getRegisteredVerifiers(overrides?: CallOverrides): Promise; + + getSequenceNumber(overrides?: CallOverrides): Promise; + + getVaultBalance( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; - onERC721Received( - arg0: string, - arg1: string, - arg2: BigNumberish, - arg3: BytesLike, - overrides?: Overrides & { from?: string } - ): Promise; + getVaultRoot(overrides?: CallOverrides): Promise; - orderRegistryAddress(overrides?: CallOverrides): Promise; + getVaultTreeHeight(overrides?: CallOverrides): Promise; - registerAndDepositERC20( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + getVaultWithdrawalLock( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: CallOverrides ): Promise; - registerAndDepositEth( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string } + getWithdrawalBalance( + ownerKey: PromiseOrValue, + assetId: PromiseOrValue, + overrides?: CallOverrides ): Promise; - registerEthAddress( - ethKey: string, - starkKey: BigNumberish, - starkSignature: BytesLike, - overrides?: Overrides & { from?: string } + initialize( + data: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - registerSender( - starkKey: BigNumberish, - starkSignature: BytesLike, - overrides?: Overrides & { from?: string } + isAssetRegistered( + assetType: PromiseOrValue, + overrides?: CallOverrides ): Promise; - "registerToken(uint256,bytes)"( - assetType: BigNumberish, - assetInfo: BytesLike, - overrides?: Overrides & { from?: string } + isAvailabilityVerifier( + verifierAddress: PromiseOrValue, + overrides?: CallOverrides ): Promise; - "registerToken(uint256,bytes,uint256)"( - assetType: BigNumberish, - assetInfo: BytesLike, - quantum: BigNumberish, - overrides?: Overrides & { from?: string } + isFrozen(overrides?: CallOverrides): Promise; + + isOperator( + testedOperator: PromiseOrValue, + overrides?: CallOverrides ): Promise; - registerTokenAdmin( - newAdmin: string, - overrides?: Overrides & { from?: string } + isStrictVaultBalancePolicy(overrides?: CallOverrides): Promise; + + isTokenAdmin( + testedAdmin: PromiseOrValue, + overrides?: CallOverrides ): Promise; - unregisterTokenAdmin( - oldAdmin: string, - overrides?: Overrides & { from?: string } + isVaultLocked( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: CallOverrides ): Promise; - withdraw( - ownerKey: BigNumberish, - assetType: BigNumberish, - overrides?: Overrides & { from?: string } + isVerifier( + verifierAddress: PromiseOrValue, + overrides?: CallOverrides ): Promise; - withdrawAndMint( - ownerKey: BigNumberish, - assetType: BigNumberish, - mintingBlob: BytesLike, - overrides?: Overrides & { from?: string } + lockVault( + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + lockTime: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + mainAcceptGovernance( + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - withdrawNft( - ownerKey: BigNumberish, - assetType: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string } + mainCancelNomination( + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - STARKEX_MAX_DEFAULT_VAULT_LOCK( + mainIsGovernor( + testGovernor: PromiseOrValue, overrides?: CallOverrides ): Promise; - escape( - starkKey: BigNumberish, - vaultId: BigNumberish, - assetId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + mainNominateNewGovernor( + newGovernor: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - getLastBatchId(overrides?: CallOverrides): Promise; + mainRemoveGovernor( + governorForRemoval: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - getOrderRoot(overrides?: CallOverrides): Promise; + onERC721Received( + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + arg3: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - getOrderTreeHeight(overrides?: CallOverrides): Promise; + orderRegistryAddress(overrides?: CallOverrides): Promise; - getSequenceNumber(overrides?: CallOverrides): Promise; + registerAndDepositERC20( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - getVaultRoot(overrides?: CallOverrides): Promise; + registerAndDepositEth( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } + ): Promise; - getVaultTreeHeight(overrides?: CallOverrides): Promise; + registerAvailabilityVerifier( + verifier: PromiseOrValue, + identifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - isOperator( - testedOperator: string, - overrides?: CallOverrides + registerEthAddress( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + starkSignature: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; registerOperator( - newOperator: string, - overrides?: Overrides & { from?: string } + newOperator: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - unregisterOperator( - removedOperator: string, - overrides?: Overrides & { from?: string } + registerSender( + starkKey: PromiseOrValue, + starkSignature: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - updateState( - publicInput: BigNumberish[], - applicationData: BigNumberish[], - overrides?: Overrides & { from?: string } + "registerToken(uint256,bytes)"( + assetType: PromiseOrValue, + assetInfo: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - freezeRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string } + "registerToken(uint256,bytes,uint256)"( + assetType: PromiseOrValue, + assetInfo: PromiseOrValue, + quantum: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - fullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string } + registerTokenAdmin( + newAdmin: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - depositERC20ToVault( - assetId: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + registerVerifier( + verifier: PromiseOrValue, + identifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - depositEthToVault( - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string } + removeAvailabilityVerifier( + verifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - getQuantizedVaultBalance( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: CallOverrides + removeVerifier( + verifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - getVaultBalance( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: CallOverrides + setDefaultVaultWithdrawalLock( + newDefaultTime: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - getVaultWithdrawalLock( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: CallOverrides + unFreeze( + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - isStrictVaultBalancePolicy(overrides?: CallOverrides): Promise; + unregisterOperator( + removedOperator: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - isVaultLocked( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: CallOverrides + unregisterTokenAdmin( + oldAdmin: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - lockVault( - assetId: BigNumberish, - vaultId: BigNumberish, - lockTime: BigNumberish, - overrides?: Overrides & { from?: string } + updateImplementationActivationTime( + implementation: PromiseOrValue, + data: PromiseOrValue, + finalize: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - setDefaultVaultWithdrawalLock( - newDefaultTime: BigNumberish, - overrides?: Overrides & { from?: string } + updateState( + publicInput: PromiseOrValue[], + applicationData: PromiseOrValue[], + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + withdraw( + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + withdrawAndMint( + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawFromVault( - assetId: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - updateImplementationActivationTime( - implementation: string, - data: BytesLike, - finalize: boolean, - overrides?: Overrides & { from?: string } + withdrawNft( + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; }; populateTransaction: { - VERSION(overrides?: CallOverrides): Promise; - - initialize( - data: BytesLike, - overrides?: Overrides & { from?: string } - ): Promise; - DEPOSIT_CANCEL_DELAY( overrides?: CallOverrides ): Promise; @@ -3504,437 +3627,444 @@ export interface StarkV4 extends BaseContract { overrides?: CallOverrides ): Promise; + STARKEX_MAX_DEFAULT_VAULT_LOCK( + overrides?: CallOverrides + ): Promise; + UNFREEZE_DELAY(overrides?: CallOverrides): Promise; VERIFIER_REMOVAL_DELAY( overrides?: CallOverrides ): Promise; + VERSION(overrides?: CallOverrides): Promise; + announceAvailabilityVerifierRemovalIntent( - verifier: string, - overrides?: Overrides & { from?: string } + verifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; announceVerifierRemovalIntent( - verifier: string, - overrides?: Overrides & { from?: string } + verifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - getRegisteredAvailabilityVerifiers( + defaultVaultWithdrawalLock( overrides?: CallOverrides ): Promise; - getRegisteredVerifiers( - overrides?: CallOverrides + "deposit(uint256,uint256,uint256)"( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; - isAvailabilityVerifier( - verifierAddress: string, - overrides?: CallOverrides + "deposit(uint256,uint256,uint256,uint256)"( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - isFrozen(overrides?: CallOverrides): Promise; - - isVerifier( - verifierAddress: string, - overrides?: CallOverrides + depositCancel( + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - mainAcceptGovernance( - overrides?: Overrides & { from?: string } + depositERC20( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - mainCancelNomination( - overrides?: Overrides & { from?: string } + depositERC20ToVault( + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - mainIsGovernor( - testGovernor: string, - overrides?: CallOverrides + depositEth( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; - mainNominateNewGovernor( - newGovernor: string, - overrides?: Overrides & { from?: string } + depositEthToVault( + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; - mainRemoveGovernor( - governorForRemoval: string, - overrides?: Overrides & { from?: string } + depositNft( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - registerAvailabilityVerifier( - verifier: string, - identifier: string, - overrides?: Overrides & { from?: string } + depositNftReclaim( + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - registerVerifier( - verifier: string, - identifier: string, - overrides?: Overrides & { from?: string } + depositReclaim( + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - removeAvailabilityVerifier( - verifier: string, - overrides?: Overrides & { from?: string } + escape( + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + assetId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - removeVerifier( - verifier: string, - overrides?: Overrides & { from?: string } + freezeRequest( + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - unFreeze( - overrides?: Overrides & { from?: string } + fullWithdrawalRequest( + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - defaultVaultWithdrawalLock( + getActionCount(overrides?: CallOverrides): Promise; + + getActionHashByIndex( + actionIndex: PromiseOrValue, overrides?: CallOverrides ): Promise; - "deposit(uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string } + getAssetInfo( + assetType: PromiseOrValue, + overrides?: CallOverrides ): Promise; - "deposit(uint256,uint256,uint256,uint256)"( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + getCancellationRequest( + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: CallOverrides ): Promise; - depositCancel( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string } + getDepositBalance( + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: CallOverrides ): Promise; - depositERC20( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + getEthKey( + ownerKey: PromiseOrValue, + overrides?: CallOverrides ): Promise; - depositEth( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string } + getFullWithdrawalRequest( + starkKey: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: CallOverrides ): Promise; - depositNft( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string } - ): Promise; + getLastBatchId(overrides?: CallOverrides): Promise; - depositNftReclaim( - starkKey: BigNumberish, - assetType: BigNumberish, - vaultId: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string } - ): Promise; + getOrderRoot(overrides?: CallOverrides): Promise; - depositReclaim( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string } + getOrderTreeHeight( + overrides?: CallOverrides ): Promise; - getActionCount(overrides?: CallOverrides): Promise; - - getActionHashByIndex( - actionIndex: BigNumberish, + getQuantizedDepositBalance( + starkKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; - getAssetInfo( - assetType: BigNumberish, + getQuantizedVaultBalance( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; - getCancellationRequest( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + getQuantum( + presumedAssetType: PromiseOrValue, overrides?: CallOverrides ): Promise; - getDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + getRegisteredAvailabilityVerifiers( overrides?: CallOverrides ): Promise; - getEthKey( - ownerKey: BigNumberish, + getRegisteredVerifiers( overrides?: CallOverrides ): Promise; - getFullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, + getSequenceNumber(overrides?: CallOverrides): Promise; + + getVaultBalance( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; - getQuantizedDepositBalance( - starkKey: BigNumberish, - assetId: BigNumberish, - vaultId: BigNumberish, + getVaultRoot(overrides?: CallOverrides): Promise; + + getVaultTreeHeight( overrides?: CallOverrides ): Promise; - getQuantum( - presumedAssetType: BigNumberish, + getVaultWithdrawalLock( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, overrides?: CallOverrides ): Promise; getWithdrawalBalance( - ownerKey: BigNumberish, - assetId: BigNumberish, + ownerKey: PromiseOrValue, + assetId: PromiseOrValue, overrides?: CallOverrides ): Promise; + initialize( + data: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + isAssetRegistered( - assetType: BigNumberish, + assetType: PromiseOrValue, overrides?: CallOverrides ): Promise; - isTokenAdmin( - testedAdmin: string, + isAvailabilityVerifier( + verifierAddress: PromiseOrValue, overrides?: CallOverrides ): Promise; - onERC721Received( - arg0: string, - arg1: string, - arg2: BigNumberish, - arg3: BytesLike, - overrides?: Overrides & { from?: string } - ): Promise; + isFrozen(overrides?: CallOverrides): Promise; - orderRegistryAddress( + isOperator( + testedOperator: PromiseOrValue, overrides?: CallOverrides ): Promise; - registerAndDepositERC20( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + isStrictVaultBalancePolicy( + overrides?: CallOverrides ): Promise; - registerAndDepositEth( - ethKey: string, - starkKey: BigNumberish, - signature: BytesLike, - assetType: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string } + isTokenAdmin( + testedAdmin: PromiseOrValue, + overrides?: CallOverrides ): Promise; - registerEthAddress( - ethKey: string, - starkKey: BigNumberish, - starkSignature: BytesLike, - overrides?: Overrides & { from?: string } + isVaultLocked( + ethKey: PromiseOrValue, + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: CallOverrides ): Promise; - registerSender( - starkKey: BigNumberish, - starkSignature: BytesLike, - overrides?: Overrides & { from?: string } + isVerifier( + verifierAddress: PromiseOrValue, + overrides?: CallOverrides ): Promise; - "registerToken(uint256,bytes)"( - assetType: BigNumberish, - assetInfo: BytesLike, - overrides?: Overrides & { from?: string } + lockVault( + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + lockTime: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - "registerToken(uint256,bytes,uint256)"( - assetType: BigNumberish, - assetInfo: BytesLike, - quantum: BigNumberish, - overrides?: Overrides & { from?: string } + mainAcceptGovernance( + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - registerTokenAdmin( - newAdmin: string, - overrides?: Overrides & { from?: string } + mainCancelNomination( + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - unregisterTokenAdmin( - oldAdmin: string, - overrides?: Overrides & { from?: string } + mainIsGovernor( + testGovernor: PromiseOrValue, + overrides?: CallOverrides ): Promise; - withdraw( - ownerKey: BigNumberish, - assetType: BigNumberish, - overrides?: Overrides & { from?: string } + mainNominateNewGovernor( + newGovernor: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - withdrawAndMint( - ownerKey: BigNumberish, - assetType: BigNumberish, - mintingBlob: BytesLike, - overrides?: Overrides & { from?: string } + mainRemoveGovernor( + governorForRemoval: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - withdrawNft( - ownerKey: BigNumberish, - assetType: BigNumberish, - tokenId: BigNumberish, - overrides?: Overrides & { from?: string } + onERC721Received( + arg0: PromiseOrValue, + arg1: PromiseOrValue, + arg2: PromiseOrValue, + arg3: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - STARKEX_MAX_DEFAULT_VAULT_LOCK( + orderRegistryAddress( overrides?: CallOverrides ): Promise; - escape( - starkKey: BigNumberish, - vaultId: BigNumberish, - assetId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + registerAndDepositERC20( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - getLastBatchId(overrides?: CallOverrides): Promise; - - getOrderRoot(overrides?: CallOverrides): Promise; - - getOrderTreeHeight( - overrides?: CallOverrides + registerAndDepositEth( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + vaultId: PromiseOrValue, + overrides?: PayableOverrides & { from?: PromiseOrValue } ): Promise; - getSequenceNumber(overrides?: CallOverrides): Promise; + registerAvailabilityVerifier( + verifier: PromiseOrValue, + identifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - getVaultRoot(overrides?: CallOverrides): Promise; + registerEthAddress( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + starkSignature: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; - getVaultTreeHeight( - overrides?: CallOverrides + registerOperator( + newOperator: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - isOperator( - testedOperator: string, - overrides?: CallOverrides + registerSender( + starkKey: PromiseOrValue, + starkSignature: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - registerOperator( - newOperator: string, - overrides?: Overrides & { from?: string } + "registerToken(uint256,bytes)"( + assetType: PromiseOrValue, + assetInfo: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - unregisterOperator( - removedOperator: string, - overrides?: Overrides & { from?: string } + "registerToken(uint256,bytes,uint256)"( + assetType: PromiseOrValue, + assetInfo: PromiseOrValue, + quantum: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - updateState( - publicInput: BigNumberish[], - applicationData: BigNumberish[], - overrides?: Overrides & { from?: string } + registerTokenAdmin( + newAdmin: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - freezeRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string } + registerVerifier( + verifier: PromiseOrValue, + identifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - fullWithdrawalRequest( - starkKey: BigNumberish, - vaultId: BigNumberish, - overrides?: Overrides & { from?: string } + removeAvailabilityVerifier( + verifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - depositERC20ToVault( - assetId: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + removeVerifier( + verifier: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - depositEthToVault( - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: PayableOverrides & { from?: string } + setDefaultVaultWithdrawalLock( + newDefaultTime: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - getQuantizedVaultBalance( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: CallOverrides + unFreeze( + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - getVaultBalance( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: CallOverrides + unregisterOperator( + removedOperator: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - getVaultWithdrawalLock( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: CallOverrides + unregisterTokenAdmin( + oldAdmin: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - isStrictVaultBalancePolicy( - overrides?: CallOverrides + updateImplementationActivationTime( + implementation: PromiseOrValue, + data: PromiseOrValue, + finalize: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - isVaultLocked( - ethKey: string, - assetId: BigNumberish, - vaultId: BigNumberish, - overrides?: CallOverrides + updateState( + publicInput: PromiseOrValue[], + applicationData: PromiseOrValue[], + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - lockVault( - assetId: BigNumberish, - vaultId: BigNumberish, - lockTime: BigNumberish, - overrides?: Overrides & { from?: string } + withdraw( + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - setDefaultVaultWithdrawalLock( - newDefaultTime: BigNumberish, - overrides?: Overrides & { from?: string } + withdrawAndMint( + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; withdrawFromVault( - assetId: BigNumberish, - vaultId: BigNumberish, - quantizedAmount: BigNumberish, - overrides?: Overrides & { from?: string } + assetId: PromiseOrValue, + vaultId: PromiseOrValue, + quantizedAmount: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; - updateImplementationActivationTime( - implementation: string, - data: BytesLike, - finalize: boolean, - overrides?: Overrides & { from?: string } + withdrawNft( + ownerKey: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise; }; } diff --git a/src/contracts/contracts/v4/RegistrationV4.ts b/src/contracts/contracts/v4/RegistrationV4.ts new file mode 100644 index 00000000..a76ce8fd --- /dev/null +++ b/src/contracts/contracts/v4/RegistrationV4.ts @@ -0,0 +1,366 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import type { + BaseContract, + BigNumber, + BigNumberish, + BytesLike, + CallOverrides, + ContractTransaction, + Overrides, + PopulatedTransaction, + Signer, + utils, +} from "ethers"; +import type { FunctionFragment, Result } from "@ethersproject/abi"; +import type { Listener, Provider } from "@ethersproject/providers"; +import type { + TypedEventFilter, + TypedEvent, + TypedListener, + OnEvent, + PromiseOrValue, +} from "../../common"; + +export interface RegistrationV4Interface extends utils.Interface { + functions: { + "getVersion()": FunctionFragment; + "imx()": FunctionFragment; + "isRegistered(uint256)": FunctionFragment; + "registerAndWithdrawAll(address,uint256,bytes,uint256)": FunctionFragment; + "registerAndWithdrawNft(address,uint256,bytes,uint256,uint256)": FunctionFragment; + "registerWithdrawAndMint(address,uint256,bytes,uint256,bytes)": FunctionFragment; + "withdrawAll(uint256,uint256,uint256)": FunctionFragment; + }; + + getFunction( + nameOrSignatureOrTopic: + | "getVersion" + | "imx" + | "isRegistered" + | "registerAndWithdrawAll" + | "registerAndWithdrawNft" + | "registerWithdrawAndMint" + | "withdrawAll" + ): FunctionFragment; + + encodeFunctionData( + functionFragment: "getVersion", + values?: undefined + ): string; + encodeFunctionData(functionFragment: "imx", values?: undefined): string; + encodeFunctionData( + functionFragment: "isRegistered", + values: [PromiseOrValue] + ): string; + encodeFunctionData( + functionFragment: "registerAndWithdrawAll", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] + ): string; + encodeFunctionData( + functionFragment: "registerAndWithdrawNft", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] + ): string; + encodeFunctionData( + functionFragment: "registerWithdrawAndMint", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] + ): string; + encodeFunctionData( + functionFragment: "withdrawAll", + values: [ + PromiseOrValue, + PromiseOrValue, + PromiseOrValue + ] + ): string; + + decodeFunctionResult(functionFragment: "getVersion", data: BytesLike): Result; + decodeFunctionResult(functionFragment: "imx", data: BytesLike): Result; + decodeFunctionResult( + functionFragment: "isRegistered", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "registerAndWithdrawAll", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "registerAndWithdrawNft", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "registerWithdrawAndMint", + data: BytesLike + ): Result; + decodeFunctionResult( + functionFragment: "withdrawAll", + data: BytesLike + ): Result; + + events: {}; +} + +export interface RegistrationV4 extends BaseContract { + connect(signerOrProvider: Signer | Provider | string): this; + attach(addressOrName: string): this; + deployed(): Promise; + + interface: RegistrationV4Interface; + + queryFilter( + event: TypedEventFilter, + fromBlockOrBlockhash?: string | number | undefined, + toBlock?: string | number | undefined + ): Promise>; + + listeners( + eventFilter?: TypedEventFilter + ): Array>; + listeners(eventName?: string): Array; + removeAllListeners( + eventFilter: TypedEventFilter + ): this; + removeAllListeners(eventName?: string): this; + off: OnEvent; + on: OnEvent; + once: OnEvent; + removeListener: OnEvent; + + functions: { + getVersion(overrides?: CallOverrides): Promise<[string]>; + + imx(overrides?: CallOverrides): Promise<[string]>; + + isRegistered( + starkKey: PromiseOrValue, + overrides?: CallOverrides + ): Promise<[boolean]>; + + registerAndWithdrawAll( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdrawNft( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerWithdrawAndMint( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + withdrawAll( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + }; + + getVersion(overrides?: CallOverrides): Promise; + + imx(overrides?: CallOverrides): Promise; + + isRegistered( + starkKey: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + registerAndWithdrawAll( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdrawNft( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerWithdrawAndMint( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + withdrawAll( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + callStatic: { + getVersion(overrides?: CallOverrides): Promise; + + imx(overrides?: CallOverrides): Promise; + + isRegistered( + starkKey: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + registerAndWithdrawAll( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + registerAndWithdrawNft( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + registerWithdrawAndMint( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + withdrawAll( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + }; + + filters: {}; + + estimateGas: { + getVersion(overrides?: CallOverrides): Promise; + + imx(overrides?: CallOverrides): Promise; + + isRegistered( + starkKey: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + registerAndWithdrawAll( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdrawNft( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerWithdrawAndMint( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + withdrawAll( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + }; + + populateTransaction: { + getVersion(overrides?: CallOverrides): Promise; + + imx(overrides?: CallOverrides): Promise; + + isRegistered( + starkKey: PromiseOrValue, + overrides?: CallOverrides + ): Promise; + + registerAndWithdrawAll( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerAndWithdrawNft( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + tokenId: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + registerWithdrawAndMint( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + signature: PromiseOrValue, + assetType: PromiseOrValue, + mintingBlob: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + + withdrawAll( + ethKey: PromiseOrValue, + starkKey: PromiseOrValue, + assetType: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise; + }; +} diff --git a/src/contracts/contracts/v4/index.ts b/src/contracts/contracts/v4/index.ts new file mode 100644 index 00000000..54b7d002 --- /dev/null +++ b/src/contracts/contracts/v4/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export type { CoreV4 } from "./CoreV4"; +export type { RegistrationV4 } from "./RegistrationV4"; diff --git a/src/contracts/factories/contracts/index.ts b/src/contracts/factories/contracts/index.ts index 4daa8254..3c54027e 100644 --- a/src/contracts/factories/contracts/index.ts +++ b/src/contracts/factories/contracts/index.ts @@ -1,6 +1,5 @@ /* Autogenerated file. Do not edit manually. */ /* tslint:disable */ /* eslint-disable */ -export { StarkV3__factory } from "./StarkV3__factory"; -export { StarkV4__factory } from "./StarkV4__factory"; -export { Registration__factory } from "./Registration__factory"; +export * as v3 from "./v3"; +export * as v4 from "./v4"; diff --git a/src/contracts/factories/contracts/StarkV3__factory.ts b/src/contracts/factories/contracts/v3/Core__factory.ts similarity index 99% rename from src/contracts/factories/contracts/StarkV3__factory.ts rename to src/contracts/factories/contracts/v3/Core__factory.ts index 5df5f91c..2373c252 100644 --- a/src/contracts/factories/contracts/StarkV3__factory.ts +++ b/src/contracts/factories/contracts/v3/Core__factory.ts @@ -4,7 +4,7 @@ import { Contract, Signer, utils } from "ethers"; import type { Provider } from "@ethersproject/providers"; -import type { StarkV3, StarkV3Interface } from "../../contracts/StarkV3"; +import type { Core, CoreInterface } from "../../../contracts/v3/Core"; const _abi = [ { @@ -1597,12 +1597,12 @@ const _abi = [ }, ]; -export class StarkV3__factory { +export class Core__factory { static readonly abi = _abi; - static createInterface(): StarkV3Interface { - return new utils.Interface(_abi) as StarkV3Interface; + static createInterface(): CoreInterface { + return new utils.Interface(_abi) as CoreInterface; } - static connect(address: string, signerOrProvider: Signer | Provider): StarkV3 { - return new Contract(address, _abi, signerOrProvider) as StarkV3; + static connect(address: string, signerOrProvider: Signer | Provider): Core { + return new Contract(address, _abi, signerOrProvider) as Core; } } diff --git a/src/contracts/factories/contracts/Registration__factory.ts b/src/contracts/factories/contracts/v3/Registration__factory.ts similarity index 97% rename from src/contracts/factories/contracts/Registration__factory.ts rename to src/contracts/factories/contracts/v3/Registration__factory.ts index 60c2f2c0..24c56a2d 100644 --- a/src/contracts/factories/contracts/Registration__factory.ts +++ b/src/contracts/factories/contracts/v3/Registration__factory.ts @@ -3,10 +3,11 @@ /* eslint-disable */ import { Signer, utils, Contract, ContractFactory, Overrides } from "ethers"; import type { Provider, TransactionRequest } from "@ethersproject/providers"; +import type { PromiseOrValue } from "../../../common"; import type { Registration, RegistrationInterface, -} from "../../contracts/Registration"; +} from "../../../contracts/v3/Registration"; const _abi = [ { @@ -258,7 +259,7 @@ const _abi = [ ]; const _bytecode = - "0x60806040523480156200001157600080fd5b5060405162001313380380620013138339818101604052810190620000379190620000fc565b806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550506200012e565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000620000b08262000083565b9050919050565b6000620000c482620000a3565b9050919050565b620000d681620000b7565b8114620000e257600080fd5b50565b600081519050620000f681620000cb565b92915050565b6000602082840312156200011557620001146200007e565b5b60006200012584828501620000e5565b91505092915050565b6111d5806200013e6000396000f3fe608060405234801561001057600080fd5b50600436106100885760003560e01c80634280d50a1161005b5780634280d50a146100ff5780634627d5981461011b578063579a698814610137578063ea864adf1461016757610088565b80630a9c3beb1461008d5780630f08025f146100a95780631259cc6c146100c7578063352eb84c146100e3575b600080fd5b6100a760048036038101906100a29190610a72565b610183565b005b6100b16102ae565b6040516100be9190610b8d565b60405180910390f35b6100e160048036038101906100dc9190610ba8565b6102d2565b005b6100fd60048036038101906100f89190610c57565b6103fd565b005b61011960048036038101906101149190610cf1565b610525565b005b61013560048036038101906101309190610da0565b610650565b005b610151600480360381019061014c9190610e3a565b610778565b60405161015e9190610e82565b60405180910390f35b610181600480360381019061017c9190610e9d565b61084a565b005b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dd2414d4888888886040518563ffffffff1660e01b81526004016101e29493929190610fa1565b600060405180830381600087803b1580156101fc57600080fd5b505af1158015610210573d6000803e3d6000fd5b5050505060008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d91443b7878585856040518563ffffffff1660e01b81526004016102739493929190610fe1565b600060405180830381600087803b15801561028d57600080fd5b505af11580156102a1573d6000803e3d6000fd5b5050505050505050505050565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dd2414d4888888886040518563ffffffff1660e01b81526004016103319493929190610fa1565b600060405180830381600087803b15801561034b57600080fd5b505af115801561035f573d6000803e3d6000fd5b5050505060008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ebef0fd0878585856040518563ffffffff1660e01b81526004016103c29493929190611021565b600060405180830381600087803b1580156103dc57600080fd5b505af11580156103f0573d6000803e3d6000fd5b5050505050505050505050565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dd2414d4878787876040518563ffffffff1660e01b815260040161045c9493929190610fa1565b600060405180830381600087803b15801561047657600080fd5b505af115801561048a573d6000803e3d6000fd5b5050505060008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663019b417a8684846040518463ffffffff1660e01b81526004016104eb93929190611066565b600060405180830381600087803b15801561050557600080fd5b505af1158015610519573d6000803e3d6000fd5b50505050505050505050565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dd2414d4888888886040518563ffffffff1660e01b81526004016105849493929190610fa1565b600060405180830381600087803b15801561059e57600080fd5b505af11580156105b2573d6000803e3d6000fd5b5050505060008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ae1cdde6878585856040518563ffffffff1660e01b8152600401610615949392919061109d565b600060405180830381600087803b15801561062f57600080fd5b505af1158015610643573d6000803e3d6000fd5b5050505050505050505050565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dd2414d4878787876040518563ffffffff1660e01b81526004016106af9493929190610fa1565b600060405180830381600087803b1580156106c957600080fd5b505af11580156106dd573d6000803e3d6000fd5b5050505060008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166314cd70e48684846040518463ffffffff1660e01b815260040161073e939291906110e2565b600060405180830381600087803b15801561075857600080fd5b505af115801561076c573d6000803e3d6000fd5b50505050505050505050565b60008073ffffffffffffffffffffffffffffffffffffffff1660008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631dbd1da7846040518263ffffffff1660e01b81526004016107ea9190611119565b602060405180830381865afa158015610807573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061082b9190611149565b73ffffffffffffffffffffffffffffffffffffffff1614159050919050565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dd2414d4868686866040518563ffffffff1660e01b81526004016108a99493929190610fa1565b600060405180830381600087803b1580156108c357600080fd5b505af11580156108d7573d6000803e3d6000fd5b5050505060008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663441a3e7085836040518363ffffffff1660e01b8152600401610936929190611176565b600060405180830381600087803b15801561095057600080fd5b505af1158015610964573d6000803e3d6000fd5b505050505050505050565b600080fd5b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006109a482610979565b9050919050565b6109b481610999565b81146109bf57600080fd5b50565b6000813590506109d1816109ab565b92915050565b6000819050919050565b6109ea816109d7565b81146109f557600080fd5b50565b600081359050610a07816109e1565b92915050565b600080fd5b600080fd5b600080fd5b60008083601f840112610a3257610a31610a0d565b5b8235905067ffffffffffffffff811115610a4f57610a4e610a12565b5b602083019150836001820283011115610a6b57610a6a610a17565b5b9250929050565b600080600080600080600060a0888a031215610a9157610a9061096f565b5b6000610a9f8a828b016109c2565b9750506020610ab08a828b016109f8565b965050604088013567ffffffffffffffff811115610ad157610ad0610974565b5b610add8a828b01610a1c565b95509550506060610af08a828b016109f8565b935050608088013567ffffffffffffffff811115610b1157610b10610974565b5b610b1d8a828b01610a1c565b925092505092959891949750929550565b6000819050919050565b6000610b53610b4e610b4984610979565b610b2e565b610979565b9050919050565b6000610b6582610b38565b9050919050565b6000610b7782610b5a565b9050919050565b610b8781610b6c565b82525050565b6000602082019050610ba26000830184610b7e565b92915050565b600080600080600080600060c0888a031215610bc757610bc661096f565b5b6000610bd58a828b016109c2565b9750506020610be68a828b016109f8565b965050604088013567ffffffffffffffff811115610c0757610c06610974565b5b610c138a828b01610a1c565b95509550506060610c268a828b016109f8565b9350506080610c378a828b016109f8565b92505060a0610c488a828b016109c2565b91505092959891949750929550565b60008060008060008060a08789031215610c7457610c7361096f565b5b6000610c8289828a016109c2565b9650506020610c9389828a016109f8565b955050604087013567ffffffffffffffff811115610cb457610cb3610974565b5b610cc089828a01610a1c565b94509450506060610cd389828a016109f8565b9250506080610ce489828a016109f8565b9150509295509295509295565b600080600080600080600060c0888a031215610d1057610d0f61096f565b5b6000610d1e8a828b016109c2565b9750506020610d2f8a828b016109f8565b965050604088013567ffffffffffffffff811115610d5057610d4f610974565b5b610d5c8a828b01610a1c565b95509550506060610d6f8a828b016109f8565b9350506080610d808a828b016109f8565b92505060a0610d918a828b016109f8565b91505092959891949750929550565b60008060008060008060a08789031215610dbd57610dbc61096f565b5b6000610dcb89828a016109c2565b9650506020610ddc89828a016109f8565b955050604087013567ffffffffffffffff811115610dfd57610dfc610974565b5b610e0989828a01610a1c565b94509450506060610e1c89828a016109f8565b9250506080610e2d89828a016109c2565b9150509295509295509295565b600060208284031215610e5057610e4f61096f565b5b6000610e5e848285016109f8565b91505092915050565b60008115159050919050565b610e7c81610e67565b82525050565b6000602082019050610e976000830184610e73565b92915050565b600080600080600060808688031215610eb957610eb861096f565b5b6000610ec7888289016109c2565b9550506020610ed8888289016109f8565b945050604086013567ffffffffffffffff811115610ef957610ef8610974565b5b610f0588828901610a1c565b93509350506060610f18888289016109f8565b9150509295509295909350565b610f2e81610999565b82525050565b610f3d816109d7565b82525050565b600082825260208201905092915050565b82818337600083830152505050565b6000601f19601f8301169050919050565b6000610f808385610f43565b9350610f8d838584610f54565b610f9683610f63565b840190509392505050565b6000606082019050610fb66000830187610f25565b610fc36020830186610f34565b8181036040830152610fd6818486610f74565b905095945050505050565b6000606082019050610ff66000830187610f34565b6110036020830186610f34565b8181036040830152611016818486610f74565b905095945050505050565b60006080820190506110366000830187610f34565b6110436020830186610f34565b6110506040830185610f34565b61105d6060830184610f25565b95945050505050565b600060608201905061107b6000830186610f34565b6110886020830185610f34565b6110956040830184610f34565b949350505050565b60006080820190506110b26000830187610f34565b6110bf6020830186610f34565b6110cc6040830185610f34565b6110d96060830184610f34565b95945050505050565b60006060820190506110f76000830186610f34565b6111046020830185610f34565b6111116040830184610f25565b949350505050565b600060208201905061112e6000830184610f34565b92915050565b600081519050611143816109ab565b92915050565b60006020828403121561115f5761115e61096f565b5b600061116d84828501611134565b91505092915050565b600060408201905061118b6000830185610f34565b6111986020830184610f34565b939250505056fea264697066735822122032218b31f9c0e88bb1991ae2275255c3d0cb01b4bf63a689bcaeccdcc791192c64736f6c634300080b0033"; + "0x60806040523480156200001157600080fd5b5060405162001313380380620013138339818101604052810190620000379190620000fc565b806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550506200012e565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000620000b08262000083565b9050919050565b6000620000c482620000a3565b9050919050565b620000d681620000b7565b8114620000e257600080fd5b50565b600081519050620000f681620000cb565b92915050565b6000602082840312156200011557620001146200007e565b5b60006200012584828501620000e5565b91505092915050565b6111d5806200013e6000396000f3fe608060405234801561001057600080fd5b50600436106100885760003560e01c80634280d50a1161005b5780634280d50a146100ff5780634627d5981461011b578063579a698814610137578063ea864adf1461016757610088565b80630a9c3beb1461008d5780630f08025f146100a95780631259cc6c146100c7578063352eb84c146100e3575b600080fd5b6100a760048036038101906100a29190610a72565b610183565b005b6100b16102ae565b6040516100be9190610b8d565b60405180910390f35b6100e160048036038101906100dc9190610ba8565b6102d2565b005b6100fd60048036038101906100f89190610c57565b6103fd565b005b61011960048036038101906101149190610cf1565b610525565b005b61013560048036038101906101309190610da0565b610650565b005b610151600480360381019061014c9190610e3a565b610778565b60405161015e9190610e82565b60405180910390f35b610181600480360381019061017c9190610e9d565b61084a565b005b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dd2414d4888888886040518563ffffffff1660e01b81526004016101e29493929190610fa1565b600060405180830381600087803b1580156101fc57600080fd5b505af1158015610210573d6000803e3d6000fd5b5050505060008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d91443b7878585856040518563ffffffff1660e01b81526004016102739493929190610fe1565b600060405180830381600087803b15801561028d57600080fd5b505af11580156102a1573d6000803e3d6000fd5b5050505050505050505050565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dd2414d4888888886040518563ffffffff1660e01b81526004016103319493929190610fa1565b600060405180830381600087803b15801561034b57600080fd5b505af115801561035f573d6000803e3d6000fd5b5050505060008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ebef0fd0878585856040518563ffffffff1660e01b81526004016103c29493929190611021565b600060405180830381600087803b1580156103dc57600080fd5b505af11580156103f0573d6000803e3d6000fd5b5050505050505050505050565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dd2414d4878787876040518563ffffffff1660e01b815260040161045c9493929190610fa1565b600060405180830381600087803b15801561047657600080fd5b505af115801561048a573d6000803e3d6000fd5b5050505060008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663019b417a8684846040518463ffffffff1660e01b81526004016104eb93929190611066565b600060405180830381600087803b15801561050557600080fd5b505af1158015610519573d6000803e3d6000fd5b50505050505050505050565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dd2414d4888888886040518563ffffffff1660e01b81526004016105849493929190610fa1565b600060405180830381600087803b15801561059e57600080fd5b505af11580156105b2573d6000803e3d6000fd5b5050505060008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ae1cdde6878585856040518563ffffffff1660e01b8152600401610615949392919061109d565b600060405180830381600087803b15801561062f57600080fd5b505af1158015610643573d6000803e3d6000fd5b5050505050505050505050565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dd2414d4878787876040518563ffffffff1660e01b81526004016106af9493929190610fa1565b600060405180830381600087803b1580156106c957600080fd5b505af11580156106dd573d6000803e3d6000fd5b5050505060008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166314cd70e48684846040518463ffffffff1660e01b815260040161073e939291906110e2565b600060405180830381600087803b15801561075857600080fd5b505af115801561076c573d6000803e3d6000fd5b50505050505050505050565b60008073ffffffffffffffffffffffffffffffffffffffff1660008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631dbd1da7846040518263ffffffff1660e01b81526004016107ea9190611119565b602060405180830381865afa158015610807573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061082b9190611149565b73ffffffffffffffffffffffffffffffffffffffff1614159050919050565b60008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dd2414d4868686866040518563ffffffff1660e01b81526004016108a99493929190610fa1565b600060405180830381600087803b1580156108c357600080fd5b505af11580156108d7573d6000803e3d6000fd5b5050505060008054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663441a3e7085836040518363ffffffff1660e01b8152600401610936929190611176565b600060405180830381600087803b15801561095057600080fd5b505af1158015610964573d6000803e3d6000fd5b505050505050505050565b600080fd5b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006109a482610979565b9050919050565b6109b481610999565b81146109bf57600080fd5b50565b6000813590506109d1816109ab565b92915050565b6000819050919050565b6109ea816109d7565b81146109f557600080fd5b50565b600081359050610a07816109e1565b92915050565b600080fd5b600080fd5b600080fd5b60008083601f840112610a3257610a31610a0d565b5b8235905067ffffffffffffffff811115610a4f57610a4e610a12565b5b602083019150836001820283011115610a6b57610a6a610a17565b5b9250929050565b600080600080600080600060a0888a031215610a9157610a9061096f565b5b6000610a9f8a828b016109c2565b9750506020610ab08a828b016109f8565b965050604088013567ffffffffffffffff811115610ad157610ad0610974565b5b610add8a828b01610a1c565b95509550506060610af08a828b016109f8565b935050608088013567ffffffffffffffff811115610b1157610b10610974565b5b610b1d8a828b01610a1c565b925092505092959891949750929550565b6000819050919050565b6000610b53610b4e610b4984610979565b610b2e565b610979565b9050919050565b6000610b6582610b38565b9050919050565b6000610b7782610b5a565b9050919050565b610b8781610b6c565b82525050565b6000602082019050610ba26000830184610b7e565b92915050565b600080600080600080600060c0888a031215610bc757610bc661096f565b5b6000610bd58a828b016109c2565b9750506020610be68a828b016109f8565b965050604088013567ffffffffffffffff811115610c0757610c06610974565b5b610c138a828b01610a1c565b95509550506060610c268a828b016109f8565b9350506080610c378a828b016109f8565b92505060a0610c488a828b016109c2565b91505092959891949750929550565b60008060008060008060a08789031215610c7457610c7361096f565b5b6000610c8289828a016109c2565b9650506020610c9389828a016109f8565b955050604087013567ffffffffffffffff811115610cb457610cb3610974565b5b610cc089828a01610a1c565b94509450506060610cd389828a016109f8565b9250506080610ce489828a016109f8565b9150509295509295509295565b600080600080600080600060c0888a031215610d1057610d0f61096f565b5b6000610d1e8a828b016109c2565b9750506020610d2f8a828b016109f8565b965050604088013567ffffffffffffffff811115610d5057610d4f610974565b5b610d5c8a828b01610a1c565b95509550506060610d6f8a828b016109f8565b9350506080610d808a828b016109f8565b92505060a0610d918a828b016109f8565b91505092959891949750929550565b60008060008060008060a08789031215610dbd57610dbc61096f565b5b6000610dcb89828a016109c2565b9650506020610ddc89828a016109f8565b955050604087013567ffffffffffffffff811115610dfd57610dfc610974565b5b610e0989828a01610a1c565b94509450506060610e1c89828a016109f8565b9250506080610e2d89828a016109c2565b9150509295509295509295565b600060208284031215610e5057610e4f61096f565b5b6000610e5e848285016109f8565b91505092915050565b60008115159050919050565b610e7c81610e67565b82525050565b6000602082019050610e976000830184610e73565b92915050565b600080600080600060808688031215610eb957610eb861096f565b5b6000610ec7888289016109c2565b9550506020610ed8888289016109f8565b945050604086013567ffffffffffffffff811115610ef957610ef8610974565b5b610f0588828901610a1c565b93509350506060610f18888289016109f8565b9150509295509295909350565b610f2e81610999565b82525050565b610f3d816109d7565b82525050565b600082825260208201905092915050565b82818337600083830152505050565b6000601f19601f8301169050919050565b6000610f808385610f43565b9350610f8d838584610f54565b610f9683610f63565b840190509392505050565b6000606082019050610fb66000830187610f25565b610fc36020830186610f34565b8181036040830152610fd6818486610f74565b905095945050505050565b6000606082019050610ff66000830187610f34565b6110036020830186610f34565b8181036040830152611016818486610f74565b905095945050505050565b60006080820190506110366000830187610f34565b6110436020830186610f34565b6110506040830185610f34565b61105d6060830184610f25565b95945050505050565b600060608201905061107b6000830186610f34565b6110886020830185610f34565b6110956040830184610f34565b949350505050565b60006080820190506110b26000830187610f34565b6110bf6020830186610f34565b6110cc6040830185610f34565b6110d96060830184610f34565b95945050505050565b60006060820190506110f76000830186610f34565b6111046020830185610f34565b6111116040830184610f25565b949350505050565b600060208201905061112e6000830184610f34565b92915050565b600081519050611143816109ab565b92915050565b60006020828403121561115f5761115e61096f565b5b600061116d84828501611134565b91505092915050565b600060408201905061118b6000830185610f34565b6111986020830184610f34565b939250505056fea2646970667358221220ec3495278afe78566e74b538d48e94b094c110ca38b03493e90e5e382cc99d0264736f6c63430008130033"; type RegistrationConstructorParams = | [signer?: Signer] @@ -278,14 +279,14 @@ export class Registration__factory extends ContractFactory { } override deploy( - _imx: string, - overrides?: Overrides & { from?: string | Promise } + _imx: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): Promise { return super.deploy(_imx, overrides || {}) as Promise; } override getDeployTransaction( - _imx: string, - overrides?: Overrides & { from?: string | Promise } + _imx: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } ): TransactionRequest { return super.getDeployTransaction(_imx, overrides || {}); } diff --git a/src/contracts/factories/contracts/v3/index.ts b/src/contracts/factories/contracts/v3/index.ts new file mode 100644 index 00000000..4811ed30 --- /dev/null +++ b/src/contracts/factories/contracts/v3/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { Core__factory } from "./Core__factory"; +export { Registration__factory } from "./Registration__factory"; diff --git a/src/contracts/factories/contracts/StarkV4__factory.ts b/src/contracts/factories/contracts/v4/CoreV4__factory.ts similarity index 99% rename from src/contracts/factories/contracts/StarkV4__factory.ts rename to src/contracts/factories/contracts/v4/CoreV4__factory.ts index 6df04295..54a2de3a 100644 --- a/src/contracts/factories/contracts/StarkV4__factory.ts +++ b/src/contracts/factories/contracts/v4/CoreV4__factory.ts @@ -4,47 +4,436 @@ import { Contract, Signer, utils } from "ethers"; import type { Provider } from "@ethersproject/providers"; -import type { StarkV4, StarkV4Interface } from "../../contracts/StarkV4"; +import type { CoreV4, CoreV4Interface } from "../../../contracts/v4/CoreV4"; const _abi = [ { - stateMutability: "payable", - type: "fallback", + anonymous: false, + inputs: [ + { + indexed: true, + internalType: "address", + name: "implementation", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "updatedActivationTime", + type: "uint256", + }, + ], + name: "ImplementationActivationRescheduled", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint256", + name: "newDefaultLockTime", + type: "uint256", + }, + ], + name: "LogDefaultVaultWithdrawalLockSet", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address", + name: "depositorEthKey", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "starkKey", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "vaultId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "assetType", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "nonQuantizedAmount", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "quantizedAmount", + type: "uint256", + }, + ], + name: "LogDeposit", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint256", + name: "starkKey", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "vaultId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "assetId", + type: "uint256", + }, + ], + name: "LogDepositCancel", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint256", + name: "starkKey", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "vaultId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "assetType", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "nonQuantizedAmount", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "quantizedAmount", + type: "uint256", + }, + ], + name: "LogDepositCancelReclaimed", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint256", + name: "starkKey", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "vaultId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "assetType", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "assetId", + type: "uint256", + }, + ], + name: "LogDepositNftCancelReclaimed", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address", + name: "ethKey", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "assetId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "vaultId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "nonQuantizedAmount", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "quantizedAmount", + type: "uint256", + }, + ], + name: "LogDepositToVault", + type: "event", }, { + anonymous: false, inputs: [], - name: "VERSION", - outputs: [ + name: "LogFrozen", + type: "event", + }, + { + anonymous: false, + inputs: [ { - internalType: "string", - name: "", - type: "string", + indexed: false, + internalType: "uint256", + name: "starkKey", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "vaultId", + type: "uint256", }, ], - stateMutability: "view", - type: "function", + name: "LogFullWithdrawalRequest", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint256", + name: "ownerKey", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "assetType", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "nonQuantizedAmount", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "quantizedAmount", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "assetId", + type: "uint256", + }, + ], + name: "LogMintWithdrawalPerformed", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint256", + name: "ownerKey", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "assetId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "quantizedAmount", + type: "uint256", + }, + ], + name: "LogMintableWithdrawalAllowed", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address", + name: "acceptedGovernor", + type: "address", + }, + ], + name: "LogNewGovernorAccepted", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address", + name: "depositorEthKey", + type: "address", + }, + { + indexed: false, + internalType: "uint256", + name: "starkKey", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "vaultId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "assetType", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "assetId", + type: "uint256", + }, + ], + name: "LogNftDeposit", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint256", + name: "ownerKey", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "assetId", + type: "uint256", + }, + ], + name: "LogNftWithdrawalAllowed", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "uint256", + name: "ownerKey", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "assetType", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + { + indexed: false, + internalType: "uint256", + name: "assetId", + type: "uint256", + }, + { + indexed: false, + internalType: "address", + name: "recipient", + type: "address", + }, + ], + name: "LogNftWithdrawalPerformed", + type: "event", }, { + anonymous: false, inputs: [ { - internalType: "bytes", - name: "data", - type: "bytes", + indexed: false, + internalType: "address", + name: "nominatedGovernor", + type: "address", }, ], - name: "initialize", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - stateMutability: "payable", - type: "receive", + name: "LogNominatedGovernor", + type: "event", }, { anonymous: false, inputs: [], - name: "LogFrozen", + name: "LogNominationCancelled", type: "event", }, { @@ -53,11 +442,11 @@ const _abi = [ { indexed: false, internalType: "address", - name: "acceptedGovernor", + name: "operator", type: "address", }, ], - name: "LogNewGovernorAccepted", + name: "LogOperatorAdded", type: "event", }, { @@ -66,17 +455,11 @@ const _abi = [ { indexed: false, internalType: "address", - name: "nominatedGovernor", + name: "operator", type: "address", }, ], - name: "LogNominatedGovernor", - type: "event", - }, - { - anonymous: false, - inputs: [], - name: "LogNominationCancelled", + name: "LogOperatorRemoved", type: "event", }, { @@ -151,331 +534,104 @@ const _abi = [ }, { anonymous: false, - inputs: [], - name: "LogUnFrozen", - type: "event", - }, - { - inputs: [], - name: "DEPOSIT_CANCEL_DELAY", - outputs: [ - { - internalType: "uint256", - name: "", - type: "uint256", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "FREEZE_GRACE_PERIOD", - outputs: [ - { - internalType: "uint256", - name: "", - type: "uint256", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "MAIN_GOVERNANCE_INFO_TAG", - outputs: [ - { - internalType: "string", - name: "", - type: "string", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "MAX_FORCED_ACTIONS_REQS_PER_BLOCK", - outputs: [ + inputs: [ { + indexed: false, internalType: "uint256", - name: "", + name: "sequenceNumber", type: "uint256", }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "MAX_VERIFIER_COUNT", - outputs: [ { + indexed: false, internalType: "uint256", - name: "", + name: "batchId", type: "uint256", }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "UNFREEZE_DELAY", - outputs: [ { + indexed: false, internalType: "uint256", - name: "", + name: "vaultRoot", type: "uint256", }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "VERIFIER_REMOVAL_DELAY", - outputs: [ { + indexed: false, internalType: "uint256", - name: "", - type: "uint256", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [ - { - internalType: "address", - name: "verifier", - type: "address", - }, - ], - name: "announceAvailabilityVerifierRemovalIntent", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [ - { - internalType: "address", - name: "verifier", - type: "address", - }, - ], - name: "announceVerifierRemovalIntent", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [], - name: "getRegisteredAvailabilityVerifiers", - outputs: [ - { - internalType: "address[]", - name: "_verifers", - type: "address[]", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "getRegisteredVerifiers", - outputs: [ - { - internalType: "address[]", - name: "_verifers", - type: "address[]", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [ - { - internalType: "address", - name: "verifierAddress", - type: "address", - }, - ], - name: "isAvailabilityVerifier", - outputs: [ - { - internalType: "bool", - name: "", - type: "bool", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "isFrozen", - outputs: [ - { - internalType: "bool", - name: "", - type: "bool", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [ - { - internalType: "address", - name: "verifierAddress", - type: "address", - }, - ], - name: "isVerifier", - outputs: [ - { - internalType: "bool", - name: "", - type: "bool", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "mainAcceptGovernance", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [], - name: "mainCancelNomination", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [ - { - internalType: "address", - name: "testGovernor", - type: "address", - }, - ], - name: "mainIsGovernor", - outputs: [ - { - internalType: "bool", - name: "", - type: "bool", + name: "orderRoot", + type: "uint256", }, ], - stateMutability: "view", - type: "function", + name: "LogRootUpdate", + type: "event", }, { + anonymous: false, inputs: [ { - internalType: "address", - name: "newGovernor", - type: "address", + indexed: false, + internalType: "bytes32", + name: "stateTransitionFact", + type: "bytes32", }, ], - name: "mainNominateNewGovernor", - outputs: [], - stateMutability: "nonpayable", - type: "function", + name: "LogStateTransitionFact", + type: "event", }, { + anonymous: false, inputs: [ { + indexed: false, internalType: "address", - name: "governorForRemoval", + name: "tokenAdmin", type: "address", }, ], - name: "mainRemoveGovernor", - outputs: [], - stateMutability: "nonpayable", - type: "function", + name: "LogTokenAdminAdded", + type: "event", }, { + anonymous: false, inputs: [ { + indexed: false, internalType: "address", - name: "verifier", + name: "tokenAdmin", type: "address", }, - { - internalType: "string", - name: "identifier", - type: "string", - }, ], - name: "registerAvailabilityVerifier", - outputs: [], - stateMutability: "nonpayable", - type: "function", + name: "LogTokenAdminRemoved", + type: "event", }, { + anonymous: false, inputs: [ { - internalType: "address", - name: "verifier", - type: "address", - }, - { - internalType: "string", - name: "identifier", - type: "string", + indexed: false, + internalType: "uint256", + name: "assetType", + type: "uint256", }, - ], - name: "registerVerifier", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [ { - internalType: "address", - name: "verifier", - type: "address", + indexed: false, + internalType: "bytes", + name: "assetInfo", + type: "bytes", }, - ], - name: "removeAvailabilityVerifier", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [ { - internalType: "address", - name: "verifier", - type: "address", + indexed: false, + internalType: "uint256", + name: "quantum", + type: "uint256", }, ], - name: "removeVerifier", - outputs: [], - stateMutability: "nonpayable", - type: "function", + name: "LogTokenRegistered", + type: "event", }, { + anonymous: false, inputs: [], - name: "unFreeze", - outputs: [], - stateMutability: "nonpayable", - type: "function", + name: "LogUnFrozen", + type: "event", }, { anonymous: false, @@ -483,7 +639,7 @@ const _abi = [ { indexed: false, internalType: "address", - name: "depositorEthKey", + name: "ethKey", type: "address", }, { @@ -494,39 +650,58 @@ const _abi = [ }, { indexed: false, - internalType: "uint256", - name: "vaultId", - type: "uint256", + internalType: "address", + name: "sender", + type: "address", + }, + ], + name: "LogUserRegistered", + type: "event", + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: "address", + name: "ethKey", + type: "address", }, { indexed: false, internalType: "uint256", - name: "assetType", + name: "assetId", type: "uint256", }, { indexed: false, internalType: "uint256", - name: "nonQuantizedAmount", + name: "vaultId", type: "uint256", }, { indexed: false, - internalType: "uint256", - name: "quantizedAmount", - type: "uint256", + internalType: "int256", + name: "quantizedAmountChange", + type: "int256", }, ], - name: "LogDeposit", + name: "LogVaultBalanceChangeApplied", type: "event", }, { anonymous: false, inputs: [ + { + indexed: false, + internalType: "address", + name: "ethKey", + type: "address", + }, { indexed: false, internalType: "uint256", - name: "starkKey", + name: "assetId", type: "uint256", }, { @@ -538,11 +713,11 @@ const _abi = [ { indexed: false, internalType: "uint256", - name: "assetId", + name: "timeRelease", type: "uint256", }, ], - name: "LogDepositCancel", + name: "LogVaultWithdrawalLockSet", type: "event", }, { @@ -551,13 +726,7 @@ const _abi = [ { indexed: false, internalType: "uint256", - name: "starkKey", - type: "uint256", - }, - { - indexed: false, - internalType: "uint256", - name: "vaultId", + name: "ownerKey", type: "uint256", }, { @@ -579,7 +748,7 @@ const _abi = [ type: "uint256", }, ], - name: "LogDepositCancelReclaimed", + name: "LogWithdrawalAllowed", type: "event", }, { @@ -587,36 +756,36 @@ const _abi = [ inputs: [ { indexed: false, - internalType: "uint256", - name: "starkKey", - type: "uint256", + internalType: "address", + name: "ethKey", + type: "address", }, { indexed: false, internalType: "uint256", - name: "vaultId", + name: "assetId", type: "uint256", }, { indexed: false, internalType: "uint256", - name: "assetType", + name: "vaultId", type: "uint256", }, { indexed: false, internalType: "uint256", - name: "tokenId", + name: "nonQuantizedAmount", type: "uint256", }, { indexed: false, internalType: "uint256", - name: "assetId", + name: "quantizedAmount", type: "uint256", }, ], - name: "LogDepositNftCancelReclaimed", + name: "LogWithdrawalFromVault", type: "event", }, { @@ -648,316 +817,297 @@ const _abi = [ }, { indexed: false, - internalType: "uint256", - name: "assetId", - type: "uint256", + internalType: "address", + name: "recipient", + type: "address", }, ], - name: "LogMintWithdrawalPerformed", + name: "LogWithdrawalPerformed", type: "event", }, { - anonymous: false, - inputs: [ - { - indexed: false, - internalType: "uint256", - name: "ownerKey", - type: "uint256", - }, - { - indexed: false, - internalType: "uint256", - name: "assetId", - type: "uint256", - }, + stateMutability: "payable", + type: "fallback", + }, + { + inputs: [], + name: "DEPOSIT_CANCEL_DELAY", + outputs: [ { - indexed: false, internalType: "uint256", - name: "quantizedAmount", + name: "", type: "uint256", }, ], - name: "LogMintableWithdrawalAllowed", - type: "event", + stateMutability: "view", + type: "function", }, { - anonymous: false, - inputs: [ - { - indexed: false, - internalType: "address", - name: "depositorEthKey", - type: "address", - }, - { - indexed: false, - internalType: "uint256", - name: "starkKey", - type: "uint256", - }, - { - indexed: false, - internalType: "uint256", - name: "vaultId", - type: "uint256", - }, + inputs: [], + name: "FREEZE_GRACE_PERIOD", + outputs: [ { - indexed: false, internalType: "uint256", - name: "assetType", + name: "", type: "uint256", }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "MAIN_GOVERNANCE_INFO_TAG", + outputs: [ { - indexed: false, - internalType: "uint256", - name: "tokenId", - type: "uint256", + internalType: "string", + name: "", + type: "string", }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "MAX_FORCED_ACTIONS_REQS_PER_BLOCK", + outputs: [ { - indexed: false, internalType: "uint256", - name: "assetId", + name: "", type: "uint256", }, ], - name: "LogNftDeposit", - type: "event", + stateMutability: "view", + type: "function", }, { - anonymous: false, - inputs: [ - { - indexed: false, - internalType: "uint256", - name: "ownerKey", - type: "uint256", - }, + inputs: [], + name: "MAX_VERIFIER_COUNT", + outputs: [ { - indexed: false, internalType: "uint256", - name: "assetId", + name: "", type: "uint256", }, ], - name: "LogNftWithdrawalAllowed", - type: "event", + stateMutability: "view", + type: "function", }, { - anonymous: false, - inputs: [ - { - indexed: false, - internalType: "uint256", - name: "ownerKey", - type: "uint256", - }, + inputs: [], + name: "STARKEX_MAX_DEFAULT_VAULT_LOCK", + outputs: [ { - indexed: false, internalType: "uint256", - name: "assetType", + name: "", type: "uint256", }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "UNFREEZE_DELAY", + outputs: [ { - indexed: false, internalType: "uint256", - name: "tokenId", + name: "", type: "uint256", }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "VERIFIER_REMOVAL_DELAY", + outputs: [ { - indexed: false, internalType: "uint256", - name: "assetId", + name: "", type: "uint256", }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "VERSION", + outputs: [ { - indexed: false, - internalType: "address", - name: "recipient", - type: "address", + internalType: "string", + name: "", + type: "string", }, ], - name: "LogNftWithdrawalPerformed", - type: "event", + stateMutability: "view", + type: "function", }, { - anonymous: false, inputs: [ { - indexed: false, internalType: "address", - name: "tokenAdmin", + name: "verifier", type: "address", }, ], - name: "LogTokenAdminAdded", - type: "event", + name: "announceAvailabilityVerifierRemovalIntent", + outputs: [], + stateMutability: "nonpayable", + type: "function", }, { - anonymous: false, inputs: [ { - indexed: false, internalType: "address", - name: "tokenAdmin", + name: "verifier", type: "address", }, ], - name: "LogTokenAdminRemoved", - type: "event", + name: "announceVerifierRemovalIntent", + outputs: [], + stateMutability: "nonpayable", + type: "function", }, { - anonymous: false, - inputs: [ - { - indexed: false, - internalType: "uint256", - name: "assetType", - type: "uint256", - }, - { - indexed: false, - internalType: "bytes", - name: "assetInfo", - type: "bytes", - }, + inputs: [], + name: "defaultVaultWithdrawalLock", + outputs: [ { - indexed: false, internalType: "uint256", - name: "quantum", + name: "", type: "uint256", }, ], - name: "LogTokenRegistered", - type: "event", + stateMutability: "view", + type: "function", }, { - anonymous: false, inputs: [ { - indexed: false, - internalType: "address", - name: "ethKey", - type: "address", + internalType: "uint256", + name: "starkKey", + type: "uint256", }, { - indexed: false, internalType: "uint256", - name: "starkKey", + name: "assetType", type: "uint256", }, { - indexed: false, - internalType: "address", - name: "sender", - type: "address", + internalType: "uint256", + name: "vaultId", + type: "uint256", }, ], - name: "LogUserRegistered", - type: "event", + name: "deposit", + outputs: [], + stateMutability: "payable", + type: "function", }, { - anonymous: false, inputs: [ { - indexed: false, internalType: "uint256", - name: "ownerKey", + name: "starkKey", type: "uint256", }, { - indexed: false, internalType: "uint256", name: "assetType", type: "uint256", }, { - indexed: false, internalType: "uint256", - name: "nonQuantizedAmount", + name: "vaultId", type: "uint256", }, { - indexed: false, internalType: "uint256", name: "quantizedAmount", type: "uint256", }, ], - name: "LogWithdrawalAllowed", - type: "event", + name: "deposit", + outputs: [], + stateMutability: "nonpayable", + type: "function", }, { - anonymous: false, inputs: [ { - indexed: false, internalType: "uint256", - name: "ownerKey", + name: "starkKey", type: "uint256", }, { - indexed: false, internalType: "uint256", - name: "assetType", + name: "assetId", type: "uint256", }, { - indexed: false, internalType: "uint256", - name: "nonQuantizedAmount", + name: "vaultId", type: "uint256", }, + ], + name: "depositCancel", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ { - indexed: false, internalType: "uint256", - name: "quantizedAmount", + name: "starkKey", type: "uint256", }, { - indexed: false, - internalType: "address", - name: "recipient", - type: "address", + internalType: "uint256", + name: "assetType", + type: "uint256", }, - ], - name: "LogWithdrawalPerformed", - type: "event", - }, - { - inputs: [], - name: "defaultVaultWithdrawalLock", - outputs: [ { internalType: "uint256", - name: "", + name: "vaultId", + type: "uint256", + }, + { + internalType: "uint256", + name: "quantizedAmount", type: "uint256", }, ], - stateMutability: "view", + name: "depositERC20", + outputs: [], + stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "uint256", - name: "starkKey", + name: "assetId", type: "uint256", }, { internalType: "uint256", - name: "assetType", + name: "vaultId", type: "uint256", }, { internalType: "uint256", - name: "vaultId", + name: "quantizedAmount", type: "uint256", }, ], - name: "deposit", + name: "depositERC20ToVault", outputs: [], - stateMutability: "payable", + stateMutability: "nonpayable", type: "function", }, { @@ -977,15 +1127,28 @@ const _abi = [ name: "vaultId", type: "uint256", }, + ], + name: "depositEth", + outputs: [], + stateMutability: "payable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "assetId", + type: "uint256", + }, { internalType: "uint256", - name: "quantizedAmount", + name: "vaultId", type: "uint256", }, ], - name: "deposit", + name: "depositEthToVault", outputs: [], - stateMutability: "nonpayable", + stateMutability: "payable", type: "function", }, { @@ -997,7 +1160,7 @@ const _abi = [ }, { internalType: "uint256", - name: "assetId", + name: "assetType", type: "uint256", }, { @@ -1005,8 +1168,13 @@ const _abi = [ name: "vaultId", type: "uint256", }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, ], - name: "depositCancel", + name: "depositNft", outputs: [], stateMutability: "nonpayable", type: "function", @@ -1030,11 +1198,11 @@ const _abi = [ }, { internalType: "uint256", - name: "quantizedAmount", + name: "tokenId", type: "uint256", }, ], - name: "depositERC20", + name: "depositNftReclaim", outputs: [], stateMutability: "nonpayable", type: "function", @@ -1048,7 +1216,7 @@ const _abi = [ }, { internalType: "uint256", - name: "assetType", + name: "assetId", type: "uint256", }, { @@ -1057,9 +1225,9 @@ const _abi = [ type: "uint256", }, ], - name: "depositEth", + name: "depositReclaim", outputs: [], - stateMutability: "payable", + stateMutability: "nonpayable", type: "function", }, { @@ -1071,21 +1239,21 @@ const _abi = [ }, { internalType: "uint256", - name: "assetType", + name: "vaultId", type: "uint256", }, { internalType: "uint256", - name: "vaultId", + name: "assetId", type: "uint256", }, { internalType: "uint256", - name: "tokenId", + name: "quantizedAmount", type: "uint256", }, ], - name: "depositNft", + name: "escape", outputs: [], stateMutability: "nonpayable", type: "function", @@ -1097,23 +1265,13 @@ const _abi = [ name: "starkKey", type: "uint256", }, - { - internalType: "uint256", - name: "assetType", - type: "uint256", - }, { internalType: "uint256", name: "vaultId", type: "uint256", }, - { - internalType: "uint256", - name: "tokenId", - type: "uint256", - }, ], - name: "depositNftReclaim", + name: "freezeRequest", outputs: [], stateMutability: "nonpayable", type: "function", @@ -1125,18 +1283,13 @@ const _abi = [ name: "starkKey", type: "uint256", }, - { - internalType: "uint256", - name: "assetId", - type: "uint256", - }, { internalType: "uint256", name: "vaultId", type: "uint256", }, ], - name: "depositReclaim", + name: "fullWithdrawalRequest", outputs: [], stateMutability: "nonpayable", type: "function", @@ -1294,28 +1447,12 @@ const _abi = [ type: "function", }, { - inputs: [ - { - internalType: "uint256", - name: "starkKey", - type: "uint256", - }, - { - internalType: "uint256", - name: "assetId", - type: "uint256", - }, - { - internalType: "uint256", - name: "vaultId", - type: "uint256", - }, - ], - name: "getQuantizedDepositBalance", + inputs: [], + name: "getLastBatchId", outputs: [ { internalType: "uint256", - name: "balance", + name: "batchId", type: "uint256", }, ], @@ -1323,18 +1460,12 @@ const _abi = [ type: "function", }, { - inputs: [ - { - internalType: "uint256", - name: "presumedAssetType", - type: "uint256", - }, - ], - name: "getQuantum", + inputs: [], + name: "getOrderRoot", outputs: [ { internalType: "uint256", - name: "quantum", + name: "root", type: "uint256", }, ], @@ -1342,23 +1473,12 @@ const _abi = [ type: "function", }, { - inputs: [ - { - internalType: "uint256", - name: "ownerKey", - type: "uint256", - }, - { - internalType: "uint256", - name: "assetId", - type: "uint256", - }, - ], - name: "getWithdrawalBalance", + inputs: [], + name: "getOrderTreeHeight", outputs: [ { internalType: "uint256", - name: "balance", + name: "height", type: "uint256", }, ], @@ -1369,82 +1489,26 @@ const _abi = [ inputs: [ { internalType: "uint256", - name: "assetType", + name: "starkKey", type: "uint256", }, - ], - name: "isAssetRegistered", - outputs: [ - { - internalType: "bool", - name: "", - type: "bool", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [ - { - internalType: "address", - name: "testedAdmin", - type: "address", - }, - ], - name: "isTokenAdmin", - outputs: [ - { - internalType: "bool", - name: "", - type: "bool", - }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [ - { - internalType: "address", - name: "", - type: "address", - }, - { - internalType: "address", - name: "", - type: "address", - }, { internalType: "uint256", - name: "", + name: "assetId", type: "uint256", }, { - internalType: "bytes", - name: "", - type: "bytes", - }, - ], - name: "onERC721Received", - outputs: [ - { - internalType: "bytes4", - name: "", - type: "bytes4", + internalType: "uint256", + name: "vaultId", + type: "uint256", }, ], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [], - name: "orderRegistryAddress", + name: "getQuantizedDepositBalance", outputs: [ { - internalType: "address", - name: "", - type: "address", + internalType: "uint256", + name: "balance", + type: "uint256", }, ], stateMutability: "view", @@ -1459,17 +1523,7 @@ const _abi = [ }, { internalType: "uint256", - name: "starkKey", - type: "uint256", - }, - { - internalType: "bytes", - name: "signature", - type: "bytes", - }, - { - internalType: "uint256", - name: "assetType", + name: "assetId", type: "uint256", }, { @@ -1477,174 +1531,158 @@ const _abi = [ name: "vaultId", type: "uint256", }, + ], + name: "getQuantizedVaultBalance", + outputs: [ { internalType: "uint256", - name: "quantizedAmount", + name: "", type: "uint256", }, ], - name: "registerAndDepositERC20", - outputs: [], - stateMutability: "nonpayable", + stateMutability: "view", type: "function", }, { inputs: [ - { - internalType: "address", - name: "ethKey", - type: "address", - }, - { - internalType: "uint256", - name: "starkKey", - type: "uint256", - }, - { - internalType: "bytes", - name: "signature", - type: "bytes", - }, { internalType: "uint256", - name: "assetType", + name: "presumedAssetType", type: "uint256", }, + ], + name: "getQuantum", + outputs: [ { internalType: "uint256", - name: "vaultId", + name: "quantum", type: "uint256", }, ], - name: "registerAndDepositEth", - outputs: [], - stateMutability: "payable", + stateMutability: "view", type: "function", }, { - inputs: [ - { - internalType: "address", - name: "ethKey", - type: "address", - }, - { - internalType: "uint256", - name: "starkKey", - type: "uint256", - }, + inputs: [], + name: "getRegisteredAvailabilityVerifiers", + outputs: [ { - internalType: "bytes", - name: "starkSignature", - type: "bytes", + internalType: "address[]", + name: "_verifers", + type: "address[]", }, ], - name: "registerEthAddress", - outputs: [], - stateMutability: "nonpayable", + stateMutability: "view", type: "function", }, { - inputs: [ - { - internalType: "uint256", - name: "starkKey", - type: "uint256", - }, + inputs: [], + name: "getRegisteredVerifiers", + outputs: [ { - internalType: "bytes", - name: "starkSignature", - type: "bytes", + internalType: "address[]", + name: "_verifers", + type: "address[]", }, ], - name: "registerSender", - outputs: [], - stateMutability: "nonpayable", + stateMutability: "view", type: "function", }, { - inputs: [ + inputs: [], + name: "getSequenceNumber", + outputs: [ { internalType: "uint256", - name: "assetType", - type: "uint256", - }, - { - internalType: "bytes", - name: "assetInfo", - type: "bytes", + name: "seq", + type: "uint256", }, ], - name: "registerToken", - outputs: [], - stateMutability: "nonpayable", + stateMutability: "view", type: "function", }, { inputs: [ + { + internalType: "address", + name: "ethKey", + type: "address", + }, { internalType: "uint256", - name: "assetType", + name: "assetId", type: "uint256", }, { - internalType: "bytes", - name: "assetInfo", - type: "bytes", + internalType: "uint256", + name: "vaultId", + type: "uint256", }, + ], + name: "getVaultBalance", + outputs: [ { internalType: "uint256", - name: "quantum", + name: "", type: "uint256", }, ], - name: "registerToken", - outputs: [], - stateMutability: "nonpayable", + stateMutability: "view", type: "function", }, { - inputs: [ + inputs: [], + name: "getVaultRoot", + outputs: [ { - internalType: "address", - name: "newAdmin", - type: "address", + internalType: "uint256", + name: "root", + type: "uint256", }, ], - name: "registerTokenAdmin", - outputs: [], - stateMutability: "nonpayable", + stateMutability: "view", type: "function", }, { - inputs: [ + inputs: [], + name: "getVaultTreeHeight", + outputs: [ { - internalType: "address", - name: "oldAdmin", - type: "address", + internalType: "uint256", + name: "height", + type: "uint256", }, ], - name: "unregisterTokenAdmin", - outputs: [], - stateMutability: "nonpayable", + stateMutability: "view", type: "function", }, { inputs: [ + { + internalType: "address", + name: "ethKey", + type: "address", + }, { internalType: "uint256", - name: "ownerKey", + name: "assetId", type: "uint256", }, { internalType: "uint256", - name: "assetType", + name: "vaultId", type: "uint256", }, ], - name: "withdraw", - outputs: [], - stateMutability: "nonpayable", + name: "getVaultWithdrawalLock", + outputs: [ + { + internalType: "uint256", + name: "", + type: "uint256", + }, + ], + stateMutability: "view", type: "function", }, { @@ -1656,152 +1694,131 @@ const _abi = [ }, { internalType: "uint256", - name: "assetType", + name: "assetId", + type: "uint256", + }, + ], + name: "getWithdrawalBalance", + outputs: [ + { + internalType: "uint256", + name: "balance", type: "uint256", }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ { internalType: "bytes", - name: "mintingBlob", + name: "data", type: "bytes", }, ], - name: "withdrawAndMint", + name: "initialize", outputs: [], stateMutability: "nonpayable", type: "function", }, { inputs: [ - { - internalType: "uint256", - name: "ownerKey", - type: "uint256", - }, { internalType: "uint256", name: "assetType", type: "uint256", }, + ], + name: "isAssetRegistered", + outputs: [ { - internalType: "uint256", - name: "tokenId", - type: "uint256", + internalType: "bool", + name: "", + type: "bool", }, ], - name: "withdrawNft", - outputs: [], - stateMutability: "nonpayable", + stateMutability: "view", type: "function", }, { - anonymous: false, inputs: [ { - indexed: false, internalType: "address", - name: "operator", + name: "verifierAddress", type: "address", }, ], - name: "LogOperatorAdded", - type: "event", + name: "isAvailabilityVerifier", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", }, { - anonymous: false, - inputs: [ + inputs: [], + name: "isFrozen", + outputs: [ { - indexed: false, - internalType: "address", - name: "operator", - type: "address", + internalType: "bool", + name: "", + type: "bool", }, ], - name: "LogOperatorRemoved", - type: "event", + stateMutability: "view", + type: "function", }, { - anonymous: false, inputs: [ { - indexed: false, - internalType: "uint256", - name: "sequenceNumber", - type: "uint256", - }, - { - indexed: false, - internalType: "uint256", - name: "batchId", - type: "uint256", - }, - { - indexed: false, - internalType: "uint256", - name: "vaultRoot", - type: "uint256", + internalType: "address", + name: "testedOperator", + type: "address", }, + ], + name: "isOperator", + outputs: [ { - indexed: false, - internalType: "uint256", - name: "orderRoot", - type: "uint256", + internalType: "bool", + name: "", + type: "bool", }, ], - name: "LogRootUpdate", - type: "event", + stateMutability: "view", + type: "function", }, { - anonymous: false, - inputs: [ + inputs: [], + name: "isStrictVaultBalancePolicy", + outputs: [ { - indexed: false, - internalType: "bytes32", - name: "stateTransitionFact", - type: "bytes32", + internalType: "bool", + name: "", + type: "bool", }, ], - name: "LogStateTransitionFact", - type: "event", + stateMutability: "view", + type: "function", }, { - anonymous: false, inputs: [ { - indexed: false, internalType: "address", - name: "ethKey", + name: "testedAdmin", type: "address", }, - { - indexed: false, - internalType: "uint256", - name: "assetId", - type: "uint256", - }, - { - indexed: false, - internalType: "uint256", - name: "vaultId", - type: "uint256", - }, - { - indexed: false, - internalType: "int256", - name: "quantizedAmountChange", - type: "int256", - }, ], - name: "LogVaultBalanceChangeApplied", - type: "event", - }, - { - inputs: [], - name: "STARKEX_MAX_DEFAULT_VAULT_LOCK", + name: "isTokenAdmin", outputs: [ { - internalType: "uint256", + internalType: "bool", name: "", - type: "uint256", + type: "bool", }, ], stateMutability: "view", @@ -1810,118 +1827,97 @@ const _abi = [ { inputs: [ { - internalType: "uint256", - name: "starkKey", - type: "uint256", - }, - { - internalType: "uint256", - name: "vaultId", - type: "uint256", + internalType: "address", + name: "ethKey", + type: "address", }, { internalType: "uint256", name: "assetId", type: "uint256", - }, - { - internalType: "uint256", - name: "quantizedAmount", - type: "uint256", - }, - ], - name: "escape", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - inputs: [], - name: "getLastBatchId", - outputs: [ + }, { internalType: "uint256", - name: "batchId", + name: "vaultId", type: "uint256", }, ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "getOrderRoot", + name: "isVaultLocked", outputs: [ { - internalType: "uint256", - name: "root", - type: "uint256", + internalType: "bool", + name: "", + type: "bool", }, ], stateMutability: "view", type: "function", }, { - inputs: [], - name: "getOrderTreeHeight", + inputs: [ + { + internalType: "address", + name: "verifierAddress", + type: "address", + }, + ], + name: "isVerifier", outputs: [ { - internalType: "uint256", - name: "height", - type: "uint256", + internalType: "bool", + name: "", + type: "bool", }, ], stateMutability: "view", type: "function", }, { - inputs: [], - name: "getSequenceNumber", - outputs: [ + inputs: [ { internalType: "uint256", - name: "seq", + name: "assetId", type: "uint256", }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "getVaultRoot", - outputs: [ { internalType: "uint256", - name: "root", + name: "vaultId", type: "uint256", }, - ], - stateMutability: "view", - type: "function", - }, - { - inputs: [], - name: "getVaultTreeHeight", - outputs: [ { internalType: "uint256", - name: "height", + name: "lockTime", type: "uint256", }, ], - stateMutability: "view", + name: "lockVault", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "mainAcceptGovernance", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [], + name: "mainCancelNomination", + outputs: [], + stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "address", - name: "testedOperator", + name: "testGovernor", type: "address", }, ], - name: "isOperator", + name: "mainIsGovernor", outputs: [ { internalType: "bool", @@ -1936,11 +1932,11 @@ const _abi = [ inputs: [ { internalType: "address", - name: "newOperator", + name: "newGovernor", type: "address", }, ], - name: "registerOperator", + name: "mainNominateNewGovernor", outputs: [], stateMutability: "nonpayable", type: "function", @@ -1949,11 +1945,11 @@ const _abi = [ inputs: [ { internalType: "address", - name: "removedOperator", + name: "governorForRemoval", type: "address", }, ], - name: "unregisterOperator", + name: "mainRemoveGovernor", outputs: [], stateMutability: "nonpayable", type: "function", @@ -1961,213 +1957,189 @@ const _abi = [ { inputs: [ { - internalType: "uint256[]", - name: "publicInput", - type: "uint256[]", + internalType: "address", + name: "", + type: "address", }, { - internalType: "uint256[]", - name: "applicationData", - type: "uint256[]", + internalType: "address", + name: "", + type: "address", }, - ], - name: "updateState", - outputs: [], - stateMutability: "nonpayable", - type: "function", - }, - { - anonymous: false, - inputs: [ { - indexed: false, internalType: "uint256", - name: "starkKey", + name: "", type: "uint256", }, { - indexed: false, - internalType: "uint256", - name: "vaultId", - type: "uint256", + internalType: "bytes", + name: "", + type: "bytes", }, ], - name: "LogFullWithdrawalRequest", - type: "event", - }, - { - inputs: [ - { - internalType: "uint256", - name: "starkKey", - type: "uint256", - }, + name: "onERC721Received", + outputs: [ { - internalType: "uint256", - name: "vaultId", - type: "uint256", + internalType: "bytes4", + name: "", + type: "bytes4", }, ], - name: "freezeRequest", - outputs: [], stateMutability: "nonpayable", type: "function", }, { - inputs: [ - { - internalType: "uint256", - name: "starkKey", - type: "uint256", - }, + inputs: [], + name: "orderRegistryAddress", + outputs: [ { - internalType: "uint256", - name: "vaultId", - type: "uint256", + internalType: "address", + name: "", + type: "address", }, ], - name: "fullWithdrawalRequest", - outputs: [], - stateMutability: "nonpayable", + stateMutability: "view", type: "function", }, { - anonymous: false, - inputs: [ - { - indexed: false, - internalType: "uint256", - name: "newDefaultLockTime", - type: "uint256", - }, - ], - name: "LogDefaultVaultWithdrawalLockSet", - type: "event", - }, - { - anonymous: false, inputs: [ { - indexed: false, internalType: "address", name: "ethKey", type: "address", }, { - indexed: false, internalType: "uint256", - name: "assetId", + name: "starkKey", type: "uint256", }, { - indexed: false, + internalType: "bytes", + name: "signature", + type: "bytes", + }, + { internalType: "uint256", - name: "vaultId", + name: "assetType", type: "uint256", }, { - indexed: false, internalType: "uint256", - name: "nonQuantizedAmount", + name: "vaultId", type: "uint256", }, { - indexed: false, internalType: "uint256", name: "quantizedAmount", type: "uint256", }, ], - name: "LogDepositToVault", - type: "event", + name: "registerAndDepositERC20", + outputs: [], + stateMutability: "nonpayable", + type: "function", }, { - anonymous: false, inputs: [ { - indexed: false, internalType: "address", name: "ethKey", type: "address", }, { - indexed: false, internalType: "uint256", - name: "assetId", + name: "starkKey", type: "uint256", }, { - indexed: false, + internalType: "bytes", + name: "signature", + type: "bytes", + }, + { internalType: "uint256", - name: "vaultId", + name: "assetType", type: "uint256", }, { - indexed: false, internalType: "uint256", - name: "timeRelease", + name: "vaultId", type: "uint256", }, ], - name: "LogVaultWithdrawalLockSet", - type: "event", + name: "registerAndDepositEth", + outputs: [], + stateMutability: "payable", + type: "function", }, { - anonymous: false, inputs: [ { - indexed: false, internalType: "address", - name: "ethKey", + name: "verifier", type: "address", }, { - indexed: false, - internalType: "uint256", - name: "assetId", - type: "uint256", + internalType: "string", + name: "identifier", + type: "string", }, + ], + name: "registerAvailabilityVerifier", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ { - indexed: false, - internalType: "uint256", - name: "vaultId", - type: "uint256", + internalType: "address", + name: "ethKey", + type: "address", }, { - indexed: false, internalType: "uint256", - name: "nonQuantizedAmount", + name: "starkKey", type: "uint256", }, { - indexed: false, - internalType: "uint256", - name: "quantizedAmount", - type: "uint256", + internalType: "bytes", + name: "starkSignature", + type: "bytes", }, ], - name: "LogWithdrawalFromVault", - type: "event", + name: "registerEthAddress", + outputs: [], + stateMutability: "nonpayable", + type: "function", }, { inputs: [ { - internalType: "uint256", - name: "assetId", - type: "uint256", + internalType: "address", + name: "newOperator", + type: "address", }, + ], + name: "registerOperator", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ { internalType: "uint256", - name: "vaultId", + name: "starkKey", type: "uint256", }, { - internalType: "uint256", - name: "quantizedAmount", - type: "uint256", + internalType: "bytes", + name: "starkSignature", + type: "bytes", }, ], - name: "depositERC20ToVault", + name: "registerSender", outputs: [], stateMutability: "nonpayable", type: "function", @@ -2176,168 +2148,201 @@ const _abi = [ inputs: [ { internalType: "uint256", - name: "assetId", + name: "assetType", type: "uint256", }, { - internalType: "uint256", - name: "vaultId", - type: "uint256", + internalType: "bytes", + name: "assetInfo", + type: "bytes", }, ], - name: "depositEthToVault", + name: "registerToken", outputs: [], - stateMutability: "payable", + stateMutability: "nonpayable", type: "function", }, { inputs: [ - { - internalType: "address", - name: "ethKey", - type: "address", - }, { internalType: "uint256", - name: "assetId", + name: "assetType", type: "uint256", }, { - internalType: "uint256", - name: "vaultId", - type: "uint256", + internalType: "bytes", + name: "assetInfo", + type: "bytes", }, - ], - name: "getQuantizedVaultBalance", - outputs: [ { internalType: "uint256", - name: "", + name: "quantum", type: "uint256", }, ], - stateMutability: "view", + name: "registerToken", + outputs: [], + stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "address", - name: "ethKey", + name: "newAdmin", type: "address", }, + ], + name: "registerTokenAdmin", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ { - internalType: "uint256", - name: "assetId", - type: "uint256", + internalType: "address", + name: "verifier", + type: "address", }, { - internalType: "uint256", - name: "vaultId", - type: "uint256", + internalType: "string", + name: "identifier", + type: "string", }, ], - name: "getVaultBalance", - outputs: [ + name: "registerVerifier", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ { - internalType: "uint256", - name: "", - type: "uint256", + internalType: "address", + name: "verifier", + type: "address", }, ], - stateMutability: "view", + name: "removeAvailabilityVerifier", + outputs: [], + stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "address", - name: "ethKey", + name: "verifier", type: "address", }, - { - internalType: "uint256", - name: "assetId", - type: "uint256", - }, - { - internalType: "uint256", - name: "vaultId", - type: "uint256", - }, ], - name: "getVaultWithdrawalLock", - outputs: [ + name: "removeVerifier", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ { internalType: "uint256", - name: "", + name: "newDefaultTime", type: "uint256", }, ], - stateMutability: "view", + name: "setDefaultVaultWithdrawalLock", + outputs: [], + stateMutability: "nonpayable", type: "function", }, { inputs: [], - name: "isStrictVaultBalancePolicy", - outputs: [ + name: "unFreeze", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ { - internalType: "bool", - name: "", - type: "bool", + internalType: "address", + name: "removedOperator", + type: "address", }, ], - stateMutability: "view", + name: "unregisterOperator", + outputs: [], + stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "address", - name: "ethKey", + name: "oldAdmin", type: "address", }, + ], + name: "unregisterTokenAdmin", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ { - internalType: "uint256", - name: "assetId", - type: "uint256", + internalType: "address", + name: "implementation", + type: "address", }, { - internalType: "uint256", - name: "vaultId", - type: "uint256", + internalType: "bytes", + name: "data", + type: "bytes", }, - ], - name: "isVaultLocked", - outputs: [ { internalType: "bool", - name: "", + name: "finalize", type: "bool", }, ], - stateMutability: "view", + name: "updateImplementationActivationTime", + outputs: [], + stateMutability: "nonpayable", type: "function", }, { inputs: [ { - internalType: "uint256", - name: "assetId", - type: "uint256", + internalType: "uint256[]", + name: "publicInput", + type: "uint256[]", }, + { + internalType: "uint256[]", + name: "applicationData", + type: "uint256[]", + }, + ], + name: "updateState", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ { internalType: "uint256", - name: "vaultId", + name: "ownerKey", type: "uint256", }, { internalType: "uint256", - name: "lockTime", + name: "assetType", type: "uint256", }, ], - name: "lockVault", + name: "withdraw", outputs: [], stateMutability: "nonpayable", type: "function", @@ -2346,11 +2351,21 @@ const _abi = [ inputs: [ { internalType: "uint256", - name: "newDefaultTime", + name: "ownerKey", + type: "uint256", + }, + { + internalType: "uint256", + name: "assetType", type: "uint256", }, + { + internalType: "bytes", + name: "mintingBlob", + type: "bytes", + }, ], - name: "setDefaultVaultWithdrawalLock", + name: "withdrawAndMint", outputs: [], stateMutability: "nonpayable", type: "function", @@ -2379,58 +2394,40 @@ const _abi = [ type: "function", }, { - anonymous: false, inputs: [ { - indexed: true, - internalType: "address", - name: "implementation", - type: "address", - }, - { - indexed: false, internalType: "uint256", - name: "updatedActivationTime", + name: "ownerKey", type: "uint256", }, - ], - name: "ImplementationActivationRescheduled", - type: "event", - }, - { - inputs: [ - { - internalType: "address", - name: "implementation", - type: "address", - }, { - internalType: "bytes", - name: "data", - type: "bytes", + internalType: "uint256", + name: "assetType", + type: "uint256", }, { - internalType: "bool", - name: "finalize", - type: "bool", + internalType: "uint256", + name: "tokenId", + type: "uint256", }, ], - name: "updateImplementationActivationTime", + name: "withdrawNft", outputs: [], stateMutability: "nonpayable", type: "function", }, -] as const; + { + stateMutability: "payable", + type: "receive", + }, +]; -export class StarkV4__factory { +export class CoreV4__factory { static readonly abi = _abi; - static createInterface(): StarkV4Interface { - return new utils.Interface(_abi) as StarkV4Interface; + static createInterface(): CoreV4Interface { + return new utils.Interface(_abi) as CoreV4Interface; } - static connect( - address: string, - signerOrProvider: Signer | Provider - ): StarkV4 { - return new Contract(address, _abi, signerOrProvider) as StarkV4; + static connect(address: string, signerOrProvider: Signer | Provider): CoreV4 { + return new Contract(address, _abi, signerOrProvider) as CoreV4; } } diff --git a/src/contracts/factories/contracts/v4/RegistrationV4__factory.ts b/src/contracts/factories/contracts/v4/RegistrationV4__factory.ts new file mode 100644 index 00000000..638c1cc2 --- /dev/null +++ b/src/contracts/factories/contracts/v4/RegistrationV4__factory.ts @@ -0,0 +1,254 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +import { Signer, utils, Contract, ContractFactory, Overrides } from "ethers"; +import type { Provider, TransactionRequest } from "@ethersproject/providers"; +import type { PromiseOrValue } from "../../../common"; +import type { + RegistrationV4, + RegistrationV4Interface, +} from "../../../contracts/v4/RegistrationV4"; + +const _abi = [ + { + inputs: [ + { + internalType: "address payable", + name: "_imx", + type: "address", + }, + ], + stateMutability: "nonpayable", + type: "constructor", + }, + { + inputs: [ + { + internalType: "uint256", + name: "ethKey", + type: "uint256", + }, + { + internalType: "uint256", + name: "starkKey", + type: "uint256", + }, + ], + name: "NoFundsToWithdraw", + type: "error", + }, + { + inputs: [], + name: "getVersion", + outputs: [ + { + internalType: "string", + name: "", + type: "string", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [], + name: "imx", + outputs: [ + { + internalType: "contract CoreV4", + name: "", + type: "address", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "starkKey", + type: "uint256", + }, + ], + name: "isRegistered", + outputs: [ + { + internalType: "bool", + name: "", + type: "bool", + }, + ], + stateMutability: "view", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "ethKey", + type: "address", + }, + { + internalType: "uint256", + name: "starkKey", + type: "uint256", + }, + { + internalType: "bytes", + name: "signature", + type: "bytes", + }, + { + internalType: "uint256", + name: "assetType", + type: "uint256", + }, + ], + name: "registerAndWithdrawAll", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "ethKey", + type: "address", + }, + { + internalType: "uint256", + name: "starkKey", + type: "uint256", + }, + { + internalType: "bytes", + name: "signature", + type: "bytes", + }, + { + internalType: "uint256", + name: "assetType", + type: "uint256", + }, + { + internalType: "uint256", + name: "tokenId", + type: "uint256", + }, + ], + name: "registerAndWithdrawNft", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "address", + name: "ethKey", + type: "address", + }, + { + internalType: "uint256", + name: "starkKey", + type: "uint256", + }, + { + internalType: "bytes", + name: "signature", + type: "bytes", + }, + { + internalType: "uint256", + name: "assetType", + type: "uint256", + }, + { + internalType: "bytes", + name: "mintingBlob", + type: "bytes", + }, + ], + name: "registerWithdrawAndMint", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, + { + inputs: [ + { + internalType: "uint256", + name: "ethKey", + type: "uint256", + }, + { + internalType: "uint256", + name: "starkKey", + type: "uint256", + }, + { + internalType: "uint256", + name: "assetType", + type: "uint256", + }, + ], + name: "withdrawAll", + outputs: [], + stateMutability: "nonpayable", + type: "function", + }, +]; + +const _bytecode = + "0x60a06040523480156200001157600080fd5b50604051620012bc380380620012bc8339818101604052810190620000379190620000dc565b8073ffffffffffffffffffffffffffffffffffffffff1660808173ffffffffffffffffffffffffffffffffffffffff1681525050506200010e565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000620000a48262000077565b9050919050565b620000b68162000097565b8114620000c257600080fd5b50565b600081519050620000d681620000ab565b92915050565b600060208284031215620000f557620000f462000072565b5b60006200010584828501620000c5565b91505092915050565b608051611145620001776000396000818161016d01528181610229015281816102c2015281816102f30152818161038501528181610429015281816104bb0152818161056e01528181610629015281816106c9015281816107c4015261085b01526111456000f3fe608060405234801561001057600080fd5b506004361061007d5760003560e01c8063352eb84c1161005b578063352eb84c146100da57806343fa186d146100f6578063579a698814610112578063d2fc99b5146101425761007d565b8063022cabbc146100825780630d8e6e2c1461009e5780630f08025f146100bc575b600080fd5b61009c600480360381019061009791906109fb565b61015e565b005b6100a6610225565b6040516100b39190610b13565b60405180910390f35b6100c46102c0565b6040516100d19190610b94565b60405180910390f35b6100f460048036038101906100ef9190610baf565b6102e4565b005b610110600480360381019061010b9190610c49565b61041a565b005b61012c60048036038101906101279190610d05565b610553565b6040516101399190610d4d565b60405180910390f35b61015c60048036038101906101579190610d68565b610625565b005b61016784610553565b6101fd577f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663bea84187868686866040518563ffffffff1660e01b81526004016101ca9493929190610e26565b600060405180830381600087803b1580156101e457600080fd5b505af11580156101f8573d6000803e3d6000fd5b505050505b61021e8573ffffffffffffffffffffffffffffffffffffffff168583610625565b5050505050565b60607f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663ffa1ad746040518163ffffffff1660e01b8152600401600060405180830381865afa158015610292573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f820116820180604052508101906102bb9190610f87565b905090565b7f000000000000000000000000000000000000000000000000000000000000000081565b6102ed85610553565b610383577f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663bea84187878787876040518563ffffffff1660e01b81526004016103509493929190610e26565b600060405180830381600087803b15801561036a57600080fd5b505af115801561037e573d6000803e3d6000fd5b505050505b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663019b417a8684846040518463ffffffff1660e01b81526004016103e093929190610fd0565b600060405180830381600087803b1580156103fa57600080fd5b505af115801561040e573d6000803e3d6000fd5b50505050505050505050565b61042386610553565b6104b9577f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663bea84187888888886040518563ffffffff1660e01b81526004016104869493929190610e26565b600060405180830381600087803b1580156104a057600080fd5b505af11580156104b4573d6000803e3d6000fd5b505050505b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663d91443b7878585856040518563ffffffff1660e01b81526004016105189493929190611007565b600060405180830381600087803b15801561053257600080fd5b505af1158015610546573d6000803e3d6000fd5b5050505050505050505050565b60008073ffffffffffffffffffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16631dbd1da7846040518263ffffffff1660e01b81526004016105c59190611047565b602060405180830381865afa1580156105e2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106069190611077565b73ffffffffffffffffffffffffffffffffffffffff1614159050919050565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663ec3161b085846040518363ffffffff1660e01b81526004016106829291906110a4565b602060405180830381865afa15801561069f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106c391906110e2565b905060007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663ec3161b085856040518363ffffffff1660e01b81526004016107229291906110a4565b602060405180830381865afa15801561073f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061076391906110e2565b90506000821480156107755750600081145b156107b95784846040517f1362cdf20000000000000000000000000000000000000000000000000000000081526004016107b09291906110a4565b60405180910390fd5b6000821115610850577f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663441a3e7086856040518363ffffffff1660e01b815260040161081d9291906110a4565b600060405180830381600087803b15801561083757600080fd5b505af115801561084b573d6000803e3d6000fd5b505050505b60008111156108e7577f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663441a3e7085856040518363ffffffff1660e01b81526004016108b49291906110a4565b600060405180830381600087803b1580156108ce57600080fd5b505af11580156108e2573d6000803e3d6000fd5b505050505b5050505050565b6000604051905090565b600080fd5b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061092d82610902565b9050919050565b61093d81610922565b811461094857600080fd5b50565b60008135905061095a81610934565b92915050565b6000819050919050565b61097381610960565b811461097e57600080fd5b50565b6000813590506109908161096a565b92915050565b600080fd5b600080fd5b600080fd5b60008083601f8401126109bb576109ba610996565b5b8235905067ffffffffffffffff8111156109d8576109d761099b565b5b6020830191508360018202830111156109f4576109f36109a0565b5b9250929050565b600080600080600060808688031215610a1757610a166108f8565b5b6000610a258882890161094b565b9550506020610a3688828901610981565b945050604086013567ffffffffffffffff811115610a5757610a566108fd565b5b610a63888289016109a5565b93509350506060610a7688828901610981565b9150509295509295909350565b600081519050919050565b600082825260208201905092915050565b60005b83811015610abd578082015181840152602081019050610aa2565b60008484015250505050565b6000601f19601f8301169050919050565b6000610ae582610a83565b610aef8185610a8e565b9350610aff818560208601610a9f565b610b0881610ac9565b840191505092915050565b60006020820190508181036000830152610b2d8184610ada565b905092915050565b6000819050919050565b6000610b5a610b55610b5084610902565b610b35565b610902565b9050919050565b6000610b6c82610b3f565b9050919050565b6000610b7e82610b61565b9050919050565b610b8e81610b73565b82525050565b6000602082019050610ba96000830184610b85565b92915050565b60008060008060008060a08789031215610bcc57610bcb6108f8565b5b6000610bda89828a0161094b565b9650506020610beb89828a01610981565b955050604087013567ffffffffffffffff811115610c0c57610c0b6108fd565b5b610c1889828a016109a5565b94509450506060610c2b89828a01610981565b9250506080610c3c89828a01610981565b9150509295509295509295565b600080600080600080600060a0888a031215610c6857610c676108f8565b5b6000610c768a828b0161094b565b9750506020610c878a828b01610981565b965050604088013567ffffffffffffffff811115610ca857610ca76108fd565b5b610cb48a828b016109a5565b95509550506060610cc78a828b01610981565b935050608088013567ffffffffffffffff811115610ce857610ce76108fd565b5b610cf48a828b016109a5565b925092505092959891949750929550565b600060208284031215610d1b57610d1a6108f8565b5b6000610d2984828501610981565b91505092915050565b60008115159050919050565b610d4781610d32565b82525050565b6000602082019050610d626000830184610d3e565b92915050565b600080600060608486031215610d8157610d806108f8565b5b6000610d8f86828701610981565b9350506020610da086828701610981565b9250506040610db186828701610981565b9150509250925092565b610dc481610922565b82525050565b610dd381610960565b82525050565b600082825260208201905092915050565b82818337600083830152505050565b6000610e058385610dd9565b9350610e12838584610dea565b610e1b83610ac9565b840190509392505050565b6000606082019050610e3b6000830187610dbb565b610e486020830186610dca565b8181036040830152610e5b818486610df9565b905095945050505050565b600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b610ea382610ac9565b810181811067ffffffffffffffff82111715610ec257610ec1610e6b565b5b80604052505050565b6000610ed56108ee565b9050610ee18282610e9a565b919050565b600067ffffffffffffffff821115610f0157610f00610e6b565b5b610f0a82610ac9565b9050602081019050919050565b6000610f2a610f2584610ee6565b610ecb565b905082815260208101848484011115610f4657610f45610e66565b5b610f51848285610a9f565b509392505050565b600082601f830112610f6e57610f6d610996565b5b8151610f7e848260208601610f17565b91505092915050565b600060208284031215610f9d57610f9c6108f8565b5b600082015167ffffffffffffffff811115610fbb57610fba6108fd565b5b610fc784828501610f59565b91505092915050565b6000606082019050610fe56000830186610dca565b610ff26020830185610dca565b610fff6040830184610dca565b949350505050565b600060608201905061101c6000830187610dca565b6110296020830186610dca565b818103604083015261103c818486610df9565b905095945050505050565b600060208201905061105c6000830184610dca565b92915050565b60008151905061107181610934565b92915050565b60006020828403121561108d5761108c6108f8565b5b600061109b84828501611062565b91505092915050565b60006040820190506110b96000830185610dca565b6110c66020830184610dca565b9392505050565b6000815190506110dc8161096a565b92915050565b6000602082840312156110f8576110f76108f8565b5b6000611106848285016110cd565b9150509291505056fea2646970667358221220c33e1830b470bf1e012ac831ec80242d6268e5e6e990b7e1574a230f71533ebd64736f6c63430008130033"; + +type RegistrationV4ConstructorParams = + | [signer?: Signer] + | ConstructorParameters; + +const isSuperArgs = ( + xs: RegistrationV4ConstructorParams +): xs is ConstructorParameters => xs.length > 1; + +export class RegistrationV4__factory extends ContractFactory { + constructor(...args: RegistrationV4ConstructorParams) { + if (isSuperArgs(args)) { + super(...args); + } else { + super(_abi, _bytecode, args[0]); + } + } + + override deploy( + _imx: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): Promise { + return super.deploy(_imx, overrides || {}) as Promise; + } + override getDeployTransaction( + _imx: PromiseOrValue, + overrides?: Overrides & { from?: PromiseOrValue } + ): TransactionRequest { + return super.getDeployTransaction(_imx, overrides || {}); + } + override attach(address: string): RegistrationV4 { + return super.attach(address) as RegistrationV4; + } + override connect(signer: Signer): RegistrationV4__factory { + return super.connect(signer) as RegistrationV4__factory; + } + + static readonly bytecode = _bytecode; + static readonly abi = _abi; + static createInterface(): RegistrationV4Interface { + return new utils.Interface(_abi) as RegistrationV4Interface; + } + static connect( + address: string, + signerOrProvider: Signer | Provider + ): RegistrationV4 { + return new Contract(address, _abi, signerOrProvider) as RegistrationV4; + } +} diff --git a/src/contracts/factories/contracts/v4/index.ts b/src/contracts/factories/contracts/v4/index.ts new file mode 100644 index 00000000..5a5a03c1 --- /dev/null +++ b/src/contracts/factories/contracts/v4/index.ts @@ -0,0 +1,5 @@ +/* Autogenerated file. Do not edit manually. */ +/* tslint:disable */ +/* eslint-disable */ +export { CoreV4__factory } from "./CoreV4__factory"; +export { RegistrationV4__factory } from "./RegistrationV4__factory"; diff --git a/src/contracts/hardhat.d.ts b/src/contracts/hardhat.d.ts index 07ef7f6e..9a274da5 100644 --- a/src/contracts/hardhat.d.ts +++ b/src/contracts/hardhat.d.ts @@ -32,6 +32,14 @@ declare module "hardhat/types/runtime" { name: "Registration", signerOrOptions?: ethers.Signer | FactoryOptions ): Promise; + getContractFactory( + name: "CoreV4", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; + getContractFactory( + name: "RegistrationV4", + signerOrOptions?: ethers.Signer | FactoryOptions + ): Promise; getContractAt( name: "IERC20", @@ -58,6 +66,16 @@ declare module "hardhat/types/runtime" { address: string, signer?: ethers.Signer ): Promise; + getContractAt( + name: "CoreV4", + address: string, + signer?: ethers.Signer + ): Promise; + getContractAt( + name: "RegistrationV4", + address: string, + signer?: ethers.Signer + ): Promise; // default types getContractFactory( diff --git a/src/contracts/index.ts b/src/contracts/index.ts index 90e26d92..7677c85f 100644 --- a/src/contracts/index.ts +++ b/src/contracts/index.ts @@ -1,21 +1,22 @@ /* Autogenerated file. Do not edit manually. */ /* tslint:disable */ /* eslint-disable */ -import type * as openzeppelin from './@openzeppelin'; +import type * as openzeppelin from "./@openzeppelin"; export type { openzeppelin }; -import type * as contracts from './contracts'; +import type * as contracts from "./contracts"; export type { contracts }; -import * as factories from './factories'; -export { factories }; -export type { IERC20 } from './@openzeppelin/contracts/token/ERC20/IERC20'; -export { IERC20__factory } from './factories/@openzeppelin/contracts/token/ERC20/IERC20__factory'; -export type { IERC721 } from './@openzeppelin/contracts/token/ERC721/IERC721'; -export { IERC721__factory } from './factories/@openzeppelin/contracts/token/ERC721/IERC721__factory'; -export type { IERC165 } from './@openzeppelin/contracts/utils/introspection/IERC165'; -export { IERC165__factory } from './factories/@openzeppelin/contracts/utils/introspection/IERC165__factory'; -export type { StarkV3 } from './contracts/StarkV3'; -export { StarkV3__factory } from './factories/contracts/StarkV3__factory'; -export type { StarkV4 } from './contracts/StarkV4'; -export { StarkV4__factory } from './factories/contracts/StarkV4__factory'; -export type { Registration } from './contracts/Registration'; -export { Registration__factory } from './factories/contracts/Registration__factory'; +export * as factories from "./factories"; +export type { IERC20 } from "./@openzeppelin/contracts/token/ERC20/IERC20"; +export { IERC20__factory } from "./factories/@openzeppelin/contracts/token/ERC20/IERC20__factory"; +export type { IERC721 } from "./@openzeppelin/contracts/token/ERC721/IERC721"; +export { IERC721__factory } from "./factories/@openzeppelin/contracts/token/ERC721/IERC721__factory"; +export type { IERC165 } from "./@openzeppelin/contracts/utils/introspection/IERC165"; +export { IERC165__factory } from "./factories/@openzeppelin/contracts/utils/introspection/IERC165__factory"; +export type { Core } from "./contracts/v3/Core"; +export { Core__factory } from "./factories/contracts/v3/Core__factory"; +export type { Registration } from "./contracts/v3/Registration"; +export { Registration__factory } from "./factories/contracts/v3/Registration__factory"; +export type { CoreV4 } from "./contracts/v4/CoreV4"; +export { CoreV4__factory } from "./factories/contracts/v4/CoreV4__factory"; +export type { RegistrationV4 } from "./contracts/v4/RegistrationV4"; +export { RegistrationV4__factory } from "./factories/contracts/v4/RegistrationV4__factory"; diff --git a/src/exportContracts.ts b/src/exportContracts.ts index dce0e68e..e667955e 100644 --- a/src/exportContracts.ts +++ b/src/exportContracts.ts @@ -1,5 +1,5 @@ export { - StarkV3__factory as StarkV3, + Core__factory as Core, Registration__factory as Registration, IERC20__factory as IERC20, IERC721__factory as IERC721, diff --git a/src/workflows/deposit/depositERC20.ts b/src/workflows/deposit/depositERC20.ts index 5705df2c..1a452fa1 100644 --- a/src/workflows/deposit/depositERC20.ts +++ b/src/workflows/deposit/depositERC20.ts @@ -3,8 +3,8 @@ import { TransactionResponse } from '@ethersproject/providers'; import { DepositsApi, EncodingApi, TokensApi, UsersApi } from '../../api'; import { parseUnits } from '@ethersproject/units'; import { - StarkV3, - StarkV3__factory, + Core, + Core__factory, IERC20__factory, Registration__factory, } from '../../contracts'; @@ -27,7 +27,7 @@ async function executeDepositERC20( assetType: string, starkPublicKey: string, vaultId: number, - contract: StarkV3, + contract: Core, ): Promise { const populatedTransaction = await contract.populateTransaction.depositERC20( starkPublicKey, @@ -45,7 +45,7 @@ async function executeRegisterAndDepositERC20( assetType: string, starkPublicKey: string, vaultId: number, - contract: StarkV3, + contract: Core, usersApi: UsersApi, ): Promise { const etherKey = await signer.getAddress(); @@ -130,7 +130,7 @@ export async function depositERC20Workflow( const vaultId = signableDepositResult.data.vault_id; const quantizedAmount = BigNumber.from(signableDepositResult.data.amount); - const coreContract = StarkV3__factory.connect( + const coreContract = Core__factory.connect( config.ethConfiguration.coreContractAddress, signer, ); diff --git a/src/workflows/deposit/depositERC721.ts b/src/workflows/deposit/depositERC721.ts index 0c0a8420..64e8209f 100644 --- a/src/workflows/deposit/depositERC721.ts +++ b/src/workflows/deposit/depositERC721.ts @@ -2,8 +2,8 @@ import { Signer } from '@ethersproject/abstract-signer'; import { TransactionResponse } from '@ethersproject/providers'; import { DepositsApi, EncodingApi, UsersApi } from '../../api'; import { - StarkV3, - StarkV3__factory, + Core, + Core__factory, IERC721__factory, Registration__factory, } from '../../contracts'; @@ -25,7 +25,7 @@ async function executeDepositERC721( assetType: string, starkPublicKey: string, vaultId: number, - contract: StarkV3, + contract: Core, ): Promise { const populatedTransaction = await contract.populateTransaction.depositNft( starkPublicKey, @@ -85,7 +85,7 @@ export async function depositERC721Workflow( const starkPublicKey = signableDepositResult.data.stark_key; const vaultId = signableDepositResult.data.vault_id; - const coreContract = StarkV3__factory.connect( + const coreContract = Core__factory.connect( config.ethConfiguration.coreContractAddress, signer, ); diff --git a/src/workflows/deposit/depositEth.ts b/src/workflows/deposit/depositEth.ts index 9f3dddbb..b04502c6 100644 --- a/src/workflows/deposit/depositEth.ts +++ b/src/workflows/deposit/depositEth.ts @@ -2,11 +2,7 @@ import { Signer } from '@ethersproject/abstract-signer'; import { TransactionResponse } from '@ethersproject/providers'; import { DepositsApi, EncodingApi, UsersApi } from '../../api'; import { parseUnits } from '@ethersproject/units'; -import { - StarkV3, - StarkV3__factory, - Registration__factory, -} from '../../contracts'; +import { Core, Core__factory, Registration__factory } from '../../contracts'; import { getSignableRegistrationOnchain, isRegisteredOnChainWorkflow, @@ -25,7 +21,7 @@ async function executeRegisterAndDepositEth( assetType: string, starkPublicKey: string, vaultId: number, - contract: StarkV3, + contract: Core, usersApi: UsersApi, ): Promise { const etherKey = await signer.getAddress(); @@ -54,7 +50,7 @@ async function executeDepositEth( assetType: string, starkPublicKey: string, vaultId: number, - contract: StarkV3, + contract: Core, ): Promise { const populatedTransaction = await contract.populateTransaction[ 'deposit(uint256,uint256,uint256)' @@ -103,7 +99,7 @@ export async function depositEthWorkflow( const starkPublicKey = signableDepositResult.data.stark_key; const vaultId = signableDepositResult.data.vault_id; - const coreContract = StarkV3__factory.connect( + const coreContract = Core__factory.connect( config.ethConfiguration.coreContractAddress, signer, ); diff --git a/src/workflows/withdrawal/completeERC20Withdrawal.ts b/src/workflows/withdrawal/completeERC20Withdrawal.ts index 40aed016..c73b4208 100644 --- a/src/workflows/withdrawal/completeERC20Withdrawal.ts +++ b/src/workflows/withdrawal/completeERC20Withdrawal.ts @@ -3,11 +3,11 @@ import { TransactionResponse } from '@ethersproject/providers'; import { EncodingApi, UsersApi } from '../../api'; import { ImmutableXConfiguration } from '../../config'; import { - StarkV3, - StarkV3__factory, + Core, + Core__factory, Registration, Registration__factory, - StarkV4__factory, + CoreV4__factory, } from '../../contracts'; import { ERC20Token } from '../../types'; import { @@ -46,7 +46,7 @@ async function executeWithdrawERC20( signer: Signer, assetType: string, starkPublicKey: string, - contract: StarkV3, + contract: Core, ): Promise { const populatedTransaction = await contract.populateTransaction.withdraw( starkPublicKey, @@ -68,7 +68,7 @@ export async function completeERC20WithdrawalV1Workflow( token_address: token.tokenAddress, }); - const coreContract = StarkV3__factory.connect( + const coreContract = Core__factory.connect( config.ethConfiguration.coreContractAddress, signer, ); @@ -111,7 +111,7 @@ export async function completeERC20WithdrawalV2Workflow( token_address: token.tokenAddress, }); - const coreContract = StarkV4__factory.connect( + const coreContract = CoreV4__factory.connect( config.ethConfiguration.coreContractAddress, signer, ); diff --git a/src/workflows/withdrawal/completeERC721Withdrawal.ts b/src/workflows/withdrawal/completeERC721Withdrawal.ts index f4fb2927..68888e00 100644 --- a/src/workflows/withdrawal/completeERC721Withdrawal.ts +++ b/src/workflows/withdrawal/completeERC721Withdrawal.ts @@ -1,11 +1,11 @@ import { Signer } from '@ethersproject/abstract-signer'; import { EncodingApi, MintsApi, UsersApi } from '../../api'; import { - StarkV3, - StarkV3__factory, + Core, + Core__factory, Registration, Registration__factory, - StarkV4__factory, + CoreV4__factory, } from '../../contracts'; import * as encUtils from 'enc-utils'; import { ERC721Token } from '../../types'; @@ -31,7 +31,7 @@ async function executeWithdrawMintableERC721( assetType: string, starkPublicKey: string, mintingBlob: string, - contract: StarkV3, + contract: Core, ): Promise { const populatedTransaction = await contract.populateTransaction.withdrawAndMint( @@ -96,7 +96,7 @@ async function completeMintableERC721WithdrawalV1( ); const mintingBlob = getMintingBlob(token); - const coreContract = StarkV3__factory.connect( + const coreContract = Core__factory.connect( config.ethConfiguration.coreContractAddress, signer, ); @@ -164,7 +164,7 @@ async function executeWithdrawERC721( assetType: string, starkPublicKey: string, tokenId: string, - contract: StarkV3, + contract: Core, ): Promise { const populatedTransaction = await contract.populateTransaction.withdrawNft( starkPublicKey, @@ -187,7 +187,7 @@ async function completeERC721WithdrawalV1( token_address: token.tokenAddress, }); - const coreContract = StarkV3__factory.connect( + const coreContract = Core__factory.connect( config.ethConfiguration.coreContractAddress, signer, ); @@ -290,7 +290,7 @@ async function completeMintableERC721WithdrawalV2( ); const mintingBlob = getMintingBlob(token); - const coreContract = StarkV4__factory.connect( + const coreContract = CoreV4__factory.connect( config.ethConfiguration.coreContractAddress, signer, ); @@ -316,7 +316,7 @@ async function completeERC721WithdrawalV2( token_address: token.tokenAddress, }); - const coreContract = StarkV4__factory.connect( + const coreContract = CoreV4__factory.connect( config.ethConfiguration.coreContractAddress, signer, ); diff --git a/src/workflows/withdrawal/completeEthWithdrawal.ts b/src/workflows/withdrawal/completeEthWithdrawal.ts index 3abe7b8c..7f73a8fb 100644 --- a/src/workflows/withdrawal/completeEthWithdrawal.ts +++ b/src/workflows/withdrawal/completeEthWithdrawal.ts @@ -3,11 +3,11 @@ import { TransactionResponse } from '@ethersproject/providers'; import { EncodingApi, UsersApi } from '../../api'; import { ImmutableXConfiguration } from '../../config'; import { - StarkV3, - StarkV3__factory, + Core, + Core__factory, Registration, Registration__factory, - StarkV4__factory, + CoreV4__factory, } from '../../contracts'; import { getSignableRegistrationOnchain, @@ -45,7 +45,7 @@ async function executeWithdrawEth( signer: Signer, assetType: string, starkPublicKey: string, - contract: StarkV3, + contract: Core, ): Promise { const populatedTransaction = await contract.populateTransaction.withdraw( starkPublicKey, @@ -64,7 +64,7 @@ export async function completeEthWithdrawalV1Workflow( ): Promise { const assetType = await getEncodeAssetInfo('asset', 'ETH', encodingApi); - const coreContract = StarkV3__factory.connect( + const coreContract = Core__factory.connect( config.ethConfiguration.coreContractAddress, signer, ); @@ -104,7 +104,7 @@ export async function completeEthWithdrawalV2Workflow( ): Promise { const assetType = await getEncodeAssetInfo('asset', 'ETH', encodingApi); - const coreContract = StarkV4__factory.connect( + const coreContract = CoreV4__factory.connect( config.ethConfiguration.coreContractAddress, signer, );