To successfully execute these examples you'll need to configure some environment variables. To do so:
Rename the ".env.template" file located at the root of this folder to ".env"
Uncomment, and assign your Sepolia testnet endpoint to the RPC_PROVIDER_URL variable in the ".env" file
Uncomment, and assign your account address to the ACCOUNT_ADDRESS variable in the ".env" file (make sure to have a few ETH in it)
Uncomment, and assign your starknet public key to the PUBLIC_KEY variable in the ".env" file
Uncomment, and assign your private key to the PRIVATE_KEY variable in the ".env" file
The variables used vary from example to example, you'll see the required ones on each main.go file, usually after a "// Load variables from '.env' file" comment.
To run an example:
Make sure you are in the chosen example directory
Execute go run main.go to run it
Some FAQ answered by these examples
How to deploy an account via DEPLOY_TRANSACTION?
R: See deployAccount
How to estimate fees?
R: See deployAccount, line 89.
How to generate random public and private keys?
R: See deployAccount, line 46.
How to use my existing account importing my account address, and public and private keys?
R: See deployContractUDC, lines 54 and 64.