diff --git a/examples/eth/build-staking-operation/main.go b/examples/eth/build-staking-operation/main.go index 7ca2e46..de939c3 100644 --- a/examples/eth/build-staking-operation/main.go +++ b/examples/eth/build-staking-operation/main.go @@ -11,6 +11,11 @@ import ( "github.com/coinbase/coinbase-sdk-go/pkg/coinbase" ) +/* + * This example code stakes ETH on the Holesky network. + * Run the code with 'go run examples/ethereum/build-staking-operation/main.go ' + */ + func main() { ctx := context.Background() @@ -21,7 +26,7 @@ func main() { log.Fatalf("error creating coinbase client: %v", err) } - address := coinbase.NewExternalAddress("ethereum-holesky", "0x57a063e1df096aaA6b2068C3C7FE6Ac4BC3c4F58") + address := coinbase.NewExternalAddress("ethereum-holesky", os.Args[2]) stakeableBalance, err := client.GetStakeableBalance(ctx, coinbase.Eth, address, coinbase.WithStakingBalanceMode(coinbase.StakingOperationModePartial)) if err != nil { diff --git a/examples/solana/build-staking-operation/main.go b/examples/solana/build-staking-operation/main.go index 1d58b76..5e740eb 100644 --- a/examples/solana/build-staking-operation/main.go +++ b/examples/solana/build-staking-operation/main.go @@ -25,6 +25,11 @@ var ( defaultPrivKeyPath = filepath.Join(home(), ".config/solana/id.json") ) +/* + * This example code stakes SOL on the devnet network. + * Run the code with 'go run examples/solana/build-staking-operation/main.go ' + */ + func main() { ctx := context.Background()