In the current version of StarkNet Alpha, fees are supported but optional.
max_fee
greater than 0, the StarkNet OS will try to charge the account for this amount and the transaction will fail if it does not succeed.max_fee
equals 0, the StarkNet Os won’t charge fee for the transaction execution.You can either choose to fund your account and use the fee mechanism, or to start without it and interact with the system by setting max_fee
to 0 when sending transactions.
Deploy an account in the hackathon environment you are working on, and copy the contract address:
export STARKNET_WALLET=starkware.starknet.wallets.open_zeppelin.OpenZeppelinAccount
starknet deploy_account
If you have some Goerli ETH on L1, you are welcome to follow the tutorial below.
If not, you can contact one of StarkWare’s staff and they will happily transfer some Goerli ETH to your account on StarkNet -
ETH Bridge L1 Address
from the Environment Parameters page and paste it into the Goerli Etherscan:
Contract
tab and select Write as Proxy
Connect to Web3
buttondeposit
functionTo verify you have funded your account you can check the balanceOf
function on the ETH Token L2 Contract for your account address. To run the command, download the ABI JSON file of the Cairo ERC20 contract:
starknet call --address 0x28179321c34e2ca38beafa45d0526673fbb5f044b4f46a9bcbe78841edfbc41 \\
--abi erc20_abi.json \\
--function balanceOf \\
--max_fee 0 \\
--inputs <ACCOUNT_ADDRESS>