Documentation
¶
Index ¶
- Constants
- func FundAddress(ctx context.Context, rpc tempo.RPCClient, address common.Address) error
- func PaymentPolicy(chainID int64, recipient string) func(context.Context, tempo.ChargeRequest) error
- func Prepare(ctx context.Context, privateKeys ...string) (string, int64, error)
- func RPCURL() string
- func WaitForRPC(ctx context.Context, rpc tempo.RPCClient) (int64, error)
Constants ¶
View Source
const ( PayerPrivateKey = "0x59c6995e998f97a5a0044966f0945389dc9e86dae88c7a8412f4603b6b78690d" FeePayerPrivateKey = "0xdd83cd66cd98801a07e0b7c1a5b02364b369e696da7c0ab444acffea5cca86fc" Currency = "0x20c0000000000000000000000000000000000000" Recipient = "0x70997970c51812dc3a010c7d01b50e0d17dc79c8" Realm = "api.example.com" )
Variables ¶
This section is empty.
Functions ¶
func FundAddress ¶
FundAddress funds address from the devnet faucet and waits for the funding transactions' receipts.
func PaymentPolicy ¶ added in v0.4.0
func PaymentPolicy(chainID int64, recipient string) func(context.Context, tempo.ChargeRequest) error
PaymentPolicy permits at most one token per payment to the example payee on the configured chain. Applications should also enforce their own total budget.
func Prepare ¶ added in v0.5.1
Prepare waits for the node at RPCURL and funds the accounts of the given private keys, returning the RPC URL and chain ID for an example run.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.