Documentation ¶
Overview ¶
Package contracts handles deployment, management, and interactions of smart contracts on various chains
Index ¶
- type AFN
- type APIConsumer
- type BlockHashStore
- type ContractDeployer
- type DeviationFlaggingValidator
- type EthereumAPIConsumer
- func (e *EthereumAPIConsumer) Address() string
- func (e *EthereumAPIConsumer) CreateRequestTo(oracleAddr string, jobID [32]byte, payment *big.Int, url string, path string, ...) error
- func (e *EthereumAPIConsumer) Data(ctx context.Context) (*big.Int, error)
- func (e *EthereumAPIConsumer) Fund(ethAmount *big.Float) error
- func (e *EthereumAPIConsumer) RoundID(ctx context.Context) (*big.Int, error)
- func (e *EthereumAPIConsumer) WatchPerfEvents(ctx context.Context, eventChan chan<- *PerfEvent) error
- type EthereumBlockhashStore
- type EthereumContractDeployer
- func (e *EthereumContractDeployer) Balance() (*big.Float, error)
- func (e *EthereumContractDeployer) DeployAFN(participants []string) (AFN, error)
- func (e *EthereumContractDeployer) DeployAPIConsumer(linkAddr string) (APIConsumer, error)
- func (e *EthereumContractDeployer) DeployBlockhashStore() (BlockHashStore, error)
- func (e *EthereumContractDeployer) DeployDeviationFlaggingValidator(flags string, flaggingThreshold *big.Int) (DeviationFlaggingValidator, error)
- func (e *EthereumContractDeployer) DeployFlags(rac string) (Flags, error)
- func (e *EthereumContractDeployer) DeployFluxAggregatorContract(linkAddr string, fluxOptions FluxAggregatorOptions) (FluxAggregator, error)
- func (e *EthereumContractDeployer) DeployKeeperConsumer(updateInterval *big.Int) (KeeperConsumer, error)
- func (e *EthereumContractDeployer) DeployKeeperConsumerPerformance(testBlockRange, averageCadence, checkGasToBurn, performGasToBurn *big.Int) (KeeperConsumerPerformance, error)
- func (e *EthereumContractDeployer) DeployKeeperRegistry(opts *KeeperRegistryOpts) (KeeperRegistry, error)
- func (e *EthereumContractDeployer) DeployLinkTokenContract() (LinkToken, error)
- func (e *EthereumContractDeployer) DeployMessageExecutor(offRampAddr string, fee bool) (MessageExecutor, error)
- func (e *EthereumContractDeployer) DeployMockETHLINKFeed(answer *big.Int) (MockETHLINKFeed, error)
- func (e *EthereumContractDeployer) DeployMockGasFeed(answer *big.Int) (MockGasFeed, error)
- func (e *EthereumContractDeployer) DeployNativeTokenPool(token string, lockRate *big.Int, lockCapacity *big.Int, releaseRate *big.Int, ...) (NativeTokenPool, error)
- func (e *EthereumContractDeployer) DeployOffChainAggregator(linkAddr string, offchainOptions OffchainOptions) (OffchainAggregator, error)
- func (e *EthereumContractDeployer) DeployOffRamp(sourceChainID *big.Int, destChainID *big.Int, tokens []string, ...) (OffRamp, error)
- func (e *EthereumContractDeployer) DeployOffRampRouter(offRamps []string) (OffRampRouter, error)
- func (e *EthereumContractDeployer) DeployOnRamp(routerAddr string, destChainIDs []*big.Int, tokens []string, ...) (OnRamp, error)
- func (e *EthereumContractDeployer) DeployOnRampRouter() (OnRampRouter, error)
- func (e *EthereumContractDeployer) DeployOracle(linkAddr string) (Oracle, error)
- func (e *EthereumContractDeployer) DeployReadAccessController() (ReadAccessController, error)
- func (e *EthereumContractDeployer) DeployReceiverDapp(offRampAddr string, tokenAddr string) (ReceiverDapp, error)
- func (e *EthereumContractDeployer) DeploySenderDapp(onRampRouter string, destChainID *big.Int, destReceiverAddr string) (SenderDapp, error)
- func (e *EthereumContractDeployer) DeploySimpleMessageReceiver() (SimpleMessageReceiver, error)
- func (e *EthereumContractDeployer) DeployStorageContract() (Storage, error)
- func (e *EthereumContractDeployer) DeployUpkeepRegistrationRequests(linkAddr string, minLinkJuels *big.Int) (UpkeepRegistrar, error)
- func (e *EthereumContractDeployer) DeployVRFConsumer(linkAddr string, coordinatorAddr string) (VRFConsumer, error)
- func (e *EthereumContractDeployer) DeployVRFConsumerV2(linkAddr string, coordinatorAddr string) (VRFConsumerV2, error)
- func (e *EthereumContractDeployer) DeployVRFContract() (VRF, error)
- func (e *EthereumContractDeployer) DeployVRFCoordinator(linkAddr string, bhsAddr string) (VRFCoordinator, error)
- func (e *EthereumContractDeployer) DeployVRFCoordinatorV2(linkAddr string, bhsAddr string, linkEthFeedAddr string) (VRFCoordinatorV2, error)
- type EthereumDeviationFlaggingValidator
- type EthereumFlags
- type EthereumFluxAggregator
- func (f *EthereumFluxAggregator) Address() string
- func (f *EthereumFluxAggregator) Description(ctxt context.Context) (string, error)
- func (f *EthereumFluxAggregator) Fund(ethAmount *big.Float) error
- func (f *EthereumFluxAggregator) GetContractData(ctx context.Context) (*FluxAggregatorData, error)
- func (f *EthereumFluxAggregator) GetOracles(ctx context.Context) ([]string, error)
- func (f *EthereumFluxAggregator) LatestRoundData(ctx context.Context) (RoundData, error)
- func (f *EthereumFluxAggregator) LatestRoundID(ctx context.Context) (*big.Int, error)
- func (f *EthereumFluxAggregator) PaymentAmount(ctx context.Context) (*big.Int, error)
- func (f *EthereumFluxAggregator) RequestNewRound(ctx context.Context) error
- func (f *EthereumFluxAggregator) SetOracles(o FluxAggregatorSetOraclesOptions) error
- func (f *EthereumFluxAggregator) SetRequesterPermissions(ctx context.Context, addr common.Address, authorized bool, roundsDelay uint32) error
- func (f *EthereumFluxAggregator) UpdateAvailableFunds() error
- func (f *EthereumFluxAggregator) WatchSubmissionReceived(ctx context.Context, eventChan chan<- *SubmissionEvent) error
- func (f *EthereumFluxAggregator) WithdrawPayment(ctx context.Context, from common.Address, to common.Address, amount *big.Int) error
- func (f *EthereumFluxAggregator) WithdrawablePayment(ctx context.Context, addr common.Address) (*big.Int, error)
- type EthereumKeeperConsumer
- type EthereumKeeperConsumerPerformance
- func (v *EthereumKeeperConsumerPerformance) Address() string
- func (v *EthereumKeeperConsumerPerformance) CheckEligible(ctx context.Context) (bool, error)
- func (v *EthereumKeeperConsumerPerformance) Fund(ethAmount *big.Float) error
- func (v *EthereumKeeperConsumerPerformance) GetUpkeepCount(ctx context.Context) (*big.Int, error)
- type EthereumKeeperRegistry
- func (v *EthereumKeeperRegistry) AddUpkeepFunds(id *big.Int, amount *big.Int) error
- func (v *EthereumKeeperRegistry) Address() string
- func (v *EthereumKeeperRegistry) Fund(ethAmount *big.Float) error
- func (v *EthereumKeeperRegistry) GetKeeperInfo(ctx context.Context, keeperAddr string) (*KeeperInfo, error)
- func (v *EthereumKeeperRegistry) GetKeeperList(ctx context.Context) ([]string, error)
- func (v *EthereumKeeperRegistry) GetUpkeepInfo(ctx context.Context, id *big.Int) (*UpkeepInfo, error)
- func (v *EthereumKeeperRegistry) RegisterUpkeep(target string, gasLimit uint32, admin string, checkData []byte) error
- func (v *EthereumKeeperRegistry) SetKeepers(keepers []string, payees []string) error
- func (v *EthereumKeeperRegistry) SetRegistrar(registrarAddr string) error
- type EthereumLinkToken
- func (l *EthereumLinkToken) Address() string
- func (l *EthereumLinkToken) Approve(to string, amount *big.Int) error
- func (l *EthereumLinkToken) BalanceOf(ctx context.Context, addr string) (*big.Int, error)
- func (l *EthereumLinkToken) Deploy() (LinkToken, error)
- func (l *EthereumLinkToken) Fund(ethAmount *big.Float) error
- func (l *EthereumLinkToken) Name(ctxt context.Context) (string, error)
- func (l *EthereumLinkToken) Transfer(to string, amount *big.Int) error
- func (l *EthereumLinkToken) TransferAndCall(to string, amount *big.Int, data []byte) error
- type EthereumMockETHLINKFeed
- type EthereumMockGASFeed
- type EthereumOffchainAggregator
- func (o *EthereumOffchainAggregator) Address() string
- func (o *EthereumOffchainAggregator) Fund(ethAmount *big.Float) error
- func (o *EthereumOffchainAggregator) GetContractData(ctxt context.Context) (*OffchainAggregatorData, error)
- func (o *EthereumOffchainAggregator) GetLatestAnswer(ctxt context.Context) (*big.Int, error)
- func (o *EthereumOffchainAggregator) GetLatestRound(ctxt context.Context) (*RoundData, error)
- func (o *EthereumOffchainAggregator) RequestNewRound() error
- func (o *EthereumOffchainAggregator) SetConfig(chainlinkNodes []client.Chainlink, ocrConfig OffChainAggregatorConfig) error
- func (o *EthereumOffchainAggregator) SetPayees(transmitters, payees []string) error
- type EthereumOracle
- type EthereumReadAccessController
- type EthereumStorage
- type EthereumUpkeepRegistrationRequests
- func (v *EthereumUpkeepRegistrationRequests) Address() string
- func (v *EthereumUpkeepRegistrationRequests) EncodeRegisterRequest(name string, email []byte, upkeepAddr string, gasLimit uint32, ...) ([]byte, error)
- func (v *EthereumUpkeepRegistrationRequests) Fund(ethAmount *big.Float) error
- func (v *EthereumUpkeepRegistrationRequests) SetRegistrarConfig(autoRegister bool, windowSizeBlocks uint32, allowedPerWindow uint16, ...) error
- type EthereumVRF
- type EthereumVRFConsumer
- func (v *EthereumVRFConsumer) Address() string
- func (v *EthereumVRFConsumer) CurrentRoundID(ctx context.Context) (*big.Int, error)
- func (v *EthereumVRFConsumer) Fund(ethAmount *big.Float) error
- func (v *EthereumVRFConsumer) RandomnessOutput(ctx context.Context) (*big.Int, error)
- func (v *EthereumVRFConsumer) RequestRandomness(hash [32]byte, fee *big.Int) error
- func (v *EthereumVRFConsumer) WatchPerfEvents(ctx context.Context, eventChan chan<- *PerfEvent) error
- type EthereumVRFConsumerV2
- func (v *EthereumVRFConsumerV2) Address() string
- func (v *EthereumVRFConsumerV2) CreateFundedSubscription(funds *big.Int) error
- func (v *EthereumVRFConsumerV2) CurrentSubscription() (uint64, error)
- func (v *EthereumVRFConsumerV2) Fund(ethAmount *big.Float) error
- func (v *EthereumVRFConsumerV2) GasAvailable() (*big.Int, error)
- func (v *EthereumVRFConsumerV2) GetAllRandomWords(ctx context.Context, num int) ([]*big.Int, error)
- func (v *EthereumVRFConsumerV2) RandomnessOutput(ctx context.Context, arg0 *big.Int) (*big.Int, error)
- func (v *EthereumVRFConsumerV2) RequestRandomness(hash [32]byte, subID uint64, confs uint16, gasLimit uint32, numWords uint32) error
- func (v *EthereumVRFConsumerV2) TopUpSubscriptionFunds(funds *big.Int) error
- type EthereumVRFCoordinator
- type EthereumVRFCoordinatorV2
- func (v *EthereumVRFCoordinatorV2) Address() string
- func (v *EthereumVRFCoordinatorV2) HashOfKey(ctx context.Context, pubKey [2]*big.Int) ([32]byte, error)
- func (v *EthereumVRFCoordinatorV2) RegisterProvingKey(oracleAddr string, publicProvingKey [2]*big.Int) error
- func (v *EthereumVRFCoordinatorV2) SetConfig(minimumRequestConfirmations uint16, maxGasLimit uint32, ...) error
- type Flags
- type FluxAggregator
- type FluxAggregatorData
- type FluxAggregatorOptions
- type FluxAggregatorRoundConfirmer
- type FluxAggregatorSetOraclesOptions
- type JobByInstance
- type KeeperConsumer
- type KeeperConsumerPerformance
- type KeeperConsumerPerformanceRoundConfirmer
- type KeeperConsumerRoundConfirmer
- type KeeperInfo
- type KeeperRegistry
- type KeeperRegistryOpts
- type KeeperRegistrySettings
- type LinkToken
- type MessageExecutor
- type MockETHLINKFeed
- type MockGasFeed
- type NativeTokenPool
- type OffChainAggregatorConfig
- type OffChainAggregatorV2Config
- type OffRamp
- type OffRampRouter
- type OffchainAggregator
- type OffchainAggregatorData
- type OffchainAggregatorRoundConfirmer
- type OffchainOptions
- type OnRamp
- type OnRampRouter
- type Oracle
- type PerfEvent
- type ReadAccessController
- type ReceiverDapp
- type RoundData
- type RunlogRoundConfirmer
- type SenderDapp
- type SimpleMessageReceiver
- type Storage
- type SubmissionEvent
- type UpkeepInfo
- type UpkeepRegistrar
- type VRF
- type VRFConsumer
- type VRFConsumerRoundConfirmer
- type VRFConsumerV2
- type VRFCoordinator
- type VRFCoordinatorV2
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIConsumer ¶
type APIConsumer interface { Address() string RoundID(ctx context.Context) (*big.Int, error) Fund(ethAmount *big.Float) error Data(ctx context.Context) (*big.Int, error) CreateRequestTo( oracleAddr string, jobID [32]byte, payment *big.Int, url string, path string, times *big.Int, ) error WatchPerfEvents(ctx context.Context, eventChan chan<- *PerfEvent) error }
type BlockHashStore ¶
type BlockHashStore interface {
Address() string
}
type ContractDeployer ¶
type ContractDeployer interface { Balance() (*big.Float, error) DeployStorageContract() (Storage, error) DeployAPIConsumer(linkAddr string) (APIConsumer, error) DeployOracle(linkAddr string) (Oracle, error) DeployReadAccessController() (ReadAccessController, error) DeployFlags(rac string) (Flags, error) DeployDeviationFlaggingValidator( flags string, flaggingThreshold *big.Int, ) (DeviationFlaggingValidator, error) DeployFluxAggregatorContract(linkAddr string, fluxOptions FluxAggregatorOptions) (FluxAggregator, error) DeployLinkTokenContract() (LinkToken, error) DeployOffChainAggregator(linkAddr string, offchainOptions OffchainOptions) (OffchainAggregator, error) DeployVRFContract() (VRF, error) DeployMockETHLINKFeed(answer *big.Int) (MockETHLINKFeed, error) DeployMockGasFeed(answer *big.Int) (MockGasFeed, error) DeployUpkeepRegistrationRequests(linkAddr string, minLinkJuels *big.Int) (UpkeepRegistrar, error) DeployKeeperRegistry(opts *KeeperRegistryOpts) (KeeperRegistry, error) DeployKeeperConsumer(updateInterval *big.Int) (KeeperConsumer, error) DeployKeeperConsumerPerformance( testBlockRange, averageCadence, checkGasToBurn, performGasToBurn *big.Int, ) (KeeperConsumerPerformance, error) DeployVRFConsumer(linkAddr string, coordinatorAddr string) (VRFConsumer, error) DeployVRFConsumerV2(linkAddr string, coordinatorAddr string) (VRFConsumerV2, error) DeployVRFCoordinator(linkAddr string, bhsAddr string) (VRFCoordinator, error) DeployVRFCoordinatorV2(linkAddr string, bhsAddr string, linkEthFeedAddr string) (VRFCoordinatorV2, error) DeployBlockhashStore() (BlockHashStore, error) DeployNativeTokenPool( token string, lockRate *big.Int, lockCapacity *big.Int, releaseRate *big.Int, releaseCapacity *big.Int, ) (NativeTokenPool, error) DeployAFN(participants []string) (AFN, error) DeployOnRampRouter() (OnRampRouter, error) DeployOnRamp( routerAddr string, destChainIDs []*big.Int, tokens []string, poolAddresses []string, feedAddresses []string, afnAddress string, ) (OnRamp, error) DeployOffRampRouter(offRamps []string) (OffRampRouter, error) DeployOffRamp( sourceChainID *big.Int, destChainID *big.Int, tokens []string, poolAddresses []string, feedAddresses []string, afnAddress string, ) (OffRamp, error) DeploySimpleMessageReceiver() (SimpleMessageReceiver, error) DeployReceiverDapp(offRampAddr string, tokenAddr string) (ReceiverDapp, error) DeployMessageExecutor(offRampAddr string, fee bool) (MessageExecutor, error) DeploySenderDapp(onRampRouter string, destChainID *big.Int, destReceiverAddr string) (SenderDapp, error) }
ContractDeployer is an interface for abstracting the contract deployment methods across network implementations
func NewContractDeployer ¶
func NewContractDeployer(bcClient client.BlockchainClient) (ContractDeployer, error)
NewContractDeployer returns an instance of a contract deployer based on the client type
type DeviationFlaggingValidator ¶
type DeviationFlaggingValidator interface {
Address() string
}
DeviationFlaggingValidator contract used as an external validator, fox ex. in flux monitor rounds validation
type EthereumAPIConsumer ¶
type EthereumAPIConsumer struct {
// contains filtered or unexported fields
}
EthereumAPIConsumer API consumer for job type "directrequest" tests
func (*EthereumAPIConsumer) Address ¶
func (e *EthereumAPIConsumer) Address() string
func (*EthereumAPIConsumer) CreateRequestTo ¶
func (e *EthereumAPIConsumer) CreateRequestTo( oracleAddr string, jobID [32]byte, payment *big.Int, url string, path string, times *big.Int, ) error
CreateRequestTo creates request to an oracle for particular jobID with params
func (*EthereumAPIConsumer) WatchPerfEvents ¶ added in v0.0.7
func (e *EthereumAPIConsumer) WatchPerfEvents(ctx context.Context, eventChan chan<- *PerfEvent) error
type EthereumBlockhashStore ¶
type EthereumBlockhashStore struct {
// contains filtered or unexported fields
}
EthereumBlockhashStore represents a blockhash store for VRF contract
func (*EthereumBlockhashStore) Address ¶
func (v *EthereumBlockhashStore) Address() string
type EthereumContractDeployer ¶
type EthereumContractDeployer struct {
// contains filtered or unexported fields
}
EthereumContractDeployer provides the implementations for deploying ETH (EVM) based contracts
func NewEthereumContractDeployer ¶
func NewEthereumContractDeployer(ethClient *client.EthereumClient) *EthereumContractDeployer
NewEthereumContractDeployer returns an instantiated instance of the ETH contract deployer
func (*EthereumContractDeployer) Balance ¶ added in v0.0.5
func (e *EthereumContractDeployer) Balance() (*big.Float, error)
Balance get deployer wallet balance
func (*EthereumContractDeployer) DeployAFN ¶ added in v1.1.15
func (e *EthereumContractDeployer) DeployAFN(participants []string) (AFN, error)
func (*EthereumContractDeployer) DeployAPIConsumer ¶
func (e *EthereumContractDeployer) DeployAPIConsumer(linkAddr string) (APIConsumer, error)
DeployAPIConsumer deploys api consumer for oracle
func (*EthereumContractDeployer) DeployBlockhashStore ¶
func (e *EthereumContractDeployer) DeployBlockhashStore() (BlockHashStore, error)
DeployBlockhashStore deploys blockhash store used with VRF contract
func (*EthereumContractDeployer) DeployDeviationFlaggingValidator ¶
func (e *EthereumContractDeployer) DeployDeviationFlaggingValidator( flags string, flaggingThreshold *big.Int, ) (DeviationFlaggingValidator, error)
DeployDeviationFlaggingValidator deploys deviation flagging validator contract
func (*EthereumContractDeployer) DeployFlags ¶
func (e *EthereumContractDeployer) DeployFlags( rac string, ) (Flags, error)
DeployFlags deploys flags contract
func (*EthereumContractDeployer) DeployFluxAggregatorContract ¶
func (e *EthereumContractDeployer) DeployFluxAggregatorContract( linkAddr string, fluxOptions FluxAggregatorOptions, ) (FluxAggregator, error)
DeployFluxAggregatorContract deploys the Flux Aggregator Contract on an EVM chain
func (*EthereumContractDeployer) DeployKeeperConsumer ¶
func (e *EthereumContractDeployer) DeployKeeperConsumer(updateInterval *big.Int) (KeeperConsumer, error)
func (*EthereumContractDeployer) DeployKeeperConsumerPerformance ¶ added in v1.0.48
func (e *EthereumContractDeployer) DeployKeeperConsumerPerformance( testBlockRange, averageCadence, checkGasToBurn, performGasToBurn *big.Int, ) (KeeperConsumerPerformance, error)
func (*EthereumContractDeployer) DeployKeeperRegistry ¶
func (e *EthereumContractDeployer) DeployKeeperRegistry( opts *KeeperRegistryOpts, ) (KeeperRegistry, error)
func (*EthereumContractDeployer) DeployLinkTokenContract ¶
func (e *EthereumContractDeployer) DeployLinkTokenContract() (LinkToken, error)
DeployLinkTokenContract deploys a Link Token contract to an EVM chain
func (*EthereumContractDeployer) DeployMessageExecutor ¶ added in v1.1.15
func (e *EthereumContractDeployer) DeployMessageExecutor(offRampAddr string, fee bool) (MessageExecutor, error)
func (*EthereumContractDeployer) DeployMockETHLINKFeed ¶
func (e *EthereumContractDeployer) DeployMockETHLINKFeed(answer *big.Int) (MockETHLINKFeed, error)
func (*EthereumContractDeployer) DeployMockGasFeed ¶
func (e *EthereumContractDeployer) DeployMockGasFeed(answer *big.Int) (MockGasFeed, error)
func (*EthereumContractDeployer) DeployNativeTokenPool ¶ added in v1.1.15
func (*EthereumContractDeployer) DeployOffChainAggregator ¶
func (e *EthereumContractDeployer) DeployOffChainAggregator( linkAddr string, offchainOptions OffchainOptions, ) (OffchainAggregator, error)
DeployOffChainAggregator deploys the offchain aggregation contract to the EVM chain
func (*EthereumContractDeployer) DeployOffRamp ¶ added in v1.1.15
func (*EthereumContractDeployer) DeployOffRampRouter ¶ added in v1.1.17
func (e *EthereumContractDeployer) DeployOffRampRouter(offRamps []string) (OffRampRouter, error)
func (*EthereumContractDeployer) DeployOnRamp ¶ added in v1.1.15
func (*EthereumContractDeployer) DeployOnRampRouter ¶ added in v1.1.17
func (e *EthereumContractDeployer) DeployOnRampRouter() (OnRampRouter, error)
func (*EthereumContractDeployer) DeployOracle ¶
func (e *EthereumContractDeployer) DeployOracle(linkAddr string) (Oracle, error)
DeployOracle deploys oracle for consumer test
func (*EthereumContractDeployer) DeployReadAccessController ¶
func (e *EthereumContractDeployer) DeployReadAccessController() (ReadAccessController, error)
DeployReadAccessController deploys read/write access controller contract
func (*EthereumContractDeployer) DeployReceiverDapp ¶ added in v1.1.15
func (e *EthereumContractDeployer) DeployReceiverDapp(offRampAddr string, tokenAddr string) (ReceiverDapp, error)
func (*EthereumContractDeployer) DeploySenderDapp ¶ added in v1.1.15
func (e *EthereumContractDeployer) DeploySenderDapp(onRampRouter string, destChainID *big.Int, destReceiverAddr string) (SenderDapp, error)
func (*EthereumContractDeployer) DeploySimpleMessageReceiver ¶ added in v1.1.15
func (e *EthereumContractDeployer) DeploySimpleMessageReceiver() (SimpleMessageReceiver, error)
func (*EthereumContractDeployer) DeployStorageContract ¶
func (e *EthereumContractDeployer) DeployStorageContract() (Storage, error)
DeployStorageContract deploys a vanilla storage contract that is a value store
func (*EthereumContractDeployer) DeployUpkeepRegistrationRequests ¶
func (e *EthereumContractDeployer) DeployUpkeepRegistrationRequests(linkAddr string, minLinkJuels *big.Int) (UpkeepRegistrar, error)
func (*EthereumContractDeployer) DeployVRFConsumer ¶
func (e *EthereumContractDeployer) DeployVRFConsumer(linkAddr string, coordinatorAddr string) (VRFConsumer, error)
DeployVRFConsumer deploys VRF consumer contract
func (*EthereumContractDeployer) DeployVRFConsumerV2 ¶ added in v1.0.54
func (e *EthereumContractDeployer) DeployVRFConsumerV2(linkAddr string, coordinatorAddr string) (VRFConsumerV2, error)
DeployVRFConsumerV2 deploys VRFv@ consumer contract
func (*EthereumContractDeployer) DeployVRFContract ¶
func (e *EthereumContractDeployer) DeployVRFContract() (VRF, error)
DeployVRFContract deploy VRF contract
func (*EthereumContractDeployer) DeployVRFCoordinator ¶
func (e *EthereumContractDeployer) DeployVRFCoordinator(linkAddr string, bhsAddr string) (VRFCoordinator, error)
DeployVRFCoordinator deploys VRF coordinator contract
func (*EthereumContractDeployer) DeployVRFCoordinatorV2 ¶ added in v1.0.54
func (e *EthereumContractDeployer) DeployVRFCoordinatorV2(linkAddr string, bhsAddr string, linkEthFeedAddr string) (VRFCoordinatorV2, error)
DeployVRFCoordinatorV2 deploys VRFV2 coordinator contract
type EthereumDeviationFlaggingValidator ¶
type EthereumDeviationFlaggingValidator struct {
// contains filtered or unexported fields
}
EthereumDeviationFlaggingValidator represents deviation flagging validator contract
func (*EthereumDeviationFlaggingValidator) Address ¶
func (e *EthereumDeviationFlaggingValidator) Address() string
type EthereumFlags ¶
type EthereumFlags struct {
// contains filtered or unexported fields
}
EthereumFlags represents flags contract
func (*EthereumFlags) Address ¶
func (e *EthereumFlags) Address() string
type EthereumFluxAggregator ¶
type EthereumFluxAggregator struct {
// contains filtered or unexported fields
}
EthereumFluxAggregator represents the basic flux aggregation contract
func (*EthereumFluxAggregator) Address ¶
func (f *EthereumFluxAggregator) Address() string
func (*EthereumFluxAggregator) Description ¶
func (f *EthereumFluxAggregator) Description(ctxt context.Context) (string, error)
Description returns the description of the flux aggregator contract
func (*EthereumFluxAggregator) Fund ¶
func (f *EthereumFluxAggregator) Fund(ethAmount *big.Float) error
Fund sends specified currencies to the contract
func (*EthereumFluxAggregator) GetContractData ¶
func (f *EthereumFluxAggregator) GetContractData(ctx context.Context) (*FluxAggregatorData, error)
GetContractData retrieves basic data for the flux aggregator contract
func (*EthereumFluxAggregator) GetOracles ¶
func (f *EthereumFluxAggregator) GetOracles(ctx context.Context) ([]string, error)
func (*EthereumFluxAggregator) LatestRoundData ¶
func (f *EthereumFluxAggregator) LatestRoundData(ctx context.Context) (RoundData, error)
func (*EthereumFluxAggregator) LatestRoundID ¶
func (*EthereumFluxAggregator) PaymentAmount ¶
func (*EthereumFluxAggregator) RequestNewRound ¶
func (f *EthereumFluxAggregator) RequestNewRound(ctx context.Context) error
func (*EthereumFluxAggregator) SetOracles ¶
func (f *EthereumFluxAggregator) SetOracles(o FluxAggregatorSetOraclesOptions) error
SetOracles allows the ability to add and/or remove oracles from the contract, and to set admins
func (*EthereumFluxAggregator) SetRequesterPermissions ¶
func (*EthereumFluxAggregator) UpdateAvailableFunds ¶
func (f *EthereumFluxAggregator) UpdateAvailableFunds() error
func (*EthereumFluxAggregator) WatchSubmissionReceived ¶
func (f *EthereumFluxAggregator) WatchSubmissionReceived(ctx context.Context, eventChan chan<- *SubmissionEvent) error
WatchSubmissionReceived subscribes to any submissions on a flux feed
func (*EthereumFluxAggregator) WithdrawPayment ¶
func (*EthereumFluxAggregator) WithdrawablePayment ¶
type EthereumKeeperConsumer ¶
type EthereumKeeperConsumer struct {
// contains filtered or unexported fields
}
EthereumKeeperConsumer represents keeper consumer (upkeep) contract
func (*EthereumKeeperConsumer) Address ¶
func (v *EthereumKeeperConsumer) Address() string
type EthereumKeeperConsumerPerformance ¶ added in v1.0.48
type EthereumKeeperConsumerPerformance struct {
// contains filtered or unexported fields
}
EthereumKeeperConsumerPerformance represents a more complicated keeper consumer contract, one intended only for performance tests.
func (*EthereumKeeperConsumerPerformance) Address ¶ added in v1.0.48
func (v *EthereumKeeperConsumerPerformance) Address() string
func (*EthereumKeeperConsumerPerformance) CheckEligible ¶ added in v1.0.48
func (v *EthereumKeeperConsumerPerformance) CheckEligible(ctx context.Context) (bool, error)
func (*EthereumKeeperConsumerPerformance) Fund ¶ added in v1.0.48
func (v *EthereumKeeperConsumerPerformance) Fund(ethAmount *big.Float) error
func (*EthereumKeeperConsumerPerformance) GetUpkeepCount ¶ added in v1.0.48
type EthereumKeeperRegistry ¶
type EthereumKeeperRegistry struct {
// contains filtered or unexported fields
}
EthereumKeeperRegistry represents keeper registry contract
func (*EthereumKeeperRegistry) AddUpkeepFunds ¶
AddUpkeepFunds adds link for particular upkeep id
func (*EthereumKeeperRegistry) Address ¶
func (v *EthereumKeeperRegistry) Address() string
func (*EthereumKeeperRegistry) Fund ¶
func (v *EthereumKeeperRegistry) Fund(ethAmount *big.Float) error
func (*EthereumKeeperRegistry) GetKeeperInfo ¶
func (v *EthereumKeeperRegistry) GetKeeperInfo(ctx context.Context, keeperAddr string) (*KeeperInfo, error)
func (*EthereumKeeperRegistry) GetKeeperList ¶
func (v *EthereumKeeperRegistry) GetKeeperList(ctx context.Context) ([]string, error)
GetKeeperList get list of all registered keeper addresses
func (*EthereumKeeperRegistry) GetUpkeepInfo ¶
func (v *EthereumKeeperRegistry) GetUpkeepInfo(ctx context.Context, id *big.Int) (*UpkeepInfo, error)
GetUpkeepInfo gets upkeep info
func (*EthereumKeeperRegistry) RegisterUpkeep ¶
func (v *EthereumKeeperRegistry) RegisterUpkeep(target string, gasLimit uint32, admin string, checkData []byte) error
RegisterUpkeep registers contract to perform upkeep
func (*EthereumKeeperRegistry) SetKeepers ¶
func (v *EthereumKeeperRegistry) SetKeepers(keepers []string, payees []string) error
func (*EthereumKeeperRegistry) SetRegistrar ¶
func (v *EthereumKeeperRegistry) SetRegistrar(registrarAddr string) error
type EthereumLinkToken ¶
type EthereumLinkToken struct {
// contains filtered or unexported fields
}
EthereumLinkToken represents a LinkToken address
func (*EthereumLinkToken) Address ¶
func (l *EthereumLinkToken) Address() string
func (*EthereumLinkToken) Approve ¶
func (l *EthereumLinkToken) Approve(to string, amount *big.Int) error
func (*EthereumLinkToken) Deploy ¶ added in v0.0.25
func (l *EthereumLinkToken) Deploy() (LinkToken, error)
func (*EthereumLinkToken) Fund ¶
func (l *EthereumLinkToken) Fund(ethAmount *big.Float) error
Fund the LINK Token contract with ETH to distribute the token
func (*EthereumLinkToken) Name ¶
func (l *EthereumLinkToken) Name(ctxt context.Context) (string, error)
Name returns the name of the link token
func (*EthereumLinkToken) Transfer ¶
func (l *EthereumLinkToken) Transfer(to string, amount *big.Int) error
func (*EthereumLinkToken) TransferAndCall ¶
type EthereumMockETHLINKFeed ¶
type EthereumMockETHLINKFeed struct {
// contains filtered or unexported fields
}
EthereumMockETHLINKFeed represents mocked ETH/LINK feed contract
func (*EthereumMockETHLINKFeed) Address ¶
func (v *EthereumMockETHLINKFeed) Address() string
func (*EthereumMockETHLINKFeed) LatestRoundData ¶ added in v1.1.2
func (v *EthereumMockETHLINKFeed) LatestRoundData() (*big.Int, error)
type EthereumMockGASFeed ¶
type EthereumMockGASFeed struct {
// contains filtered or unexported fields
}
EthereumMockGASFeed represents mocked Gas feed contract
func (*EthereumMockGASFeed) Address ¶
func (v *EthereumMockGASFeed) Address() string
type EthereumOffchainAggregator ¶
type EthereumOffchainAggregator struct {
// contains filtered or unexported fields
}
EthereumOffchainAggregator represents the offchain aggregation contract
func (*EthereumOffchainAggregator) Address ¶
func (o *EthereumOffchainAggregator) Address() string
func (*EthereumOffchainAggregator) Fund ¶
func (o *EthereumOffchainAggregator) Fund(ethAmount *big.Float) error
Fund sends specified currencies to the contract
func (*EthereumOffchainAggregator) GetContractData ¶
func (o *EthereumOffchainAggregator) GetContractData(ctxt context.Context) (*OffchainAggregatorData, error)
GetContractData retrieves basic data for the offchain aggregator contract
func (*EthereumOffchainAggregator) GetLatestAnswer ¶
GetLatestAnswer returns the latest answer from the OCR contract
func (*EthereumOffchainAggregator) GetLatestRound ¶
func (o *EthereumOffchainAggregator) GetLatestRound(ctxt context.Context) (*RoundData, error)
GetLatestRound returns data from the latest round
func (*EthereumOffchainAggregator) RequestNewRound ¶
func (o *EthereumOffchainAggregator) RequestNewRound() error
RequestNewRound requests the OCR contract to create a new round
func (*EthereumOffchainAggregator) SetConfig ¶
func (o *EthereumOffchainAggregator) SetConfig( chainlinkNodes []client.Chainlink, ocrConfig OffChainAggregatorConfig, ) error
SetConfig sets the payees and the offchain reporting protocol configuration
func (*EthereumOffchainAggregator) SetPayees ¶
func (o *EthereumOffchainAggregator) SetPayees( transmitters, payees []string, ) error
SetPayees sets wallets for the contract to pay out to?
type EthereumOracle ¶
type EthereumOracle struct {
// contains filtered or unexported fields
}
EthereumOracle oracle for "directrequest" job tests
func (*EthereumOracle) Address ¶
func (e *EthereumOracle) Address() string
func (*EthereumOracle) SetFulfillmentPermission ¶
func (e *EthereumOracle) SetFulfillmentPermission(address string, allowed bool) error
SetFulfillmentPermission sets fulfillment permission for particular address
type EthereumReadAccessController ¶
type EthereumReadAccessController struct {
// contains filtered or unexported fields
}
EthereumReadAccessController represents read access controller contract
func (*EthereumReadAccessController) AddAccess ¶
func (e *EthereumReadAccessController) AddAccess(addr string) error
AddAccess grants access to particular address to raise a flag
func (*EthereumReadAccessController) Address ¶
func (e *EthereumReadAccessController) Address() string
func (*EthereumReadAccessController) DisableAccessCheck ¶
func (e *EthereumReadAccessController) DisableAccessCheck() error
DisableAccessCheck disables all access checks
type EthereumStorage ¶
type EthereumStorage struct {
// contains filtered or unexported fields
}
EthereumStorage acts as a conduit for the ethereum version of the storage contract
type EthereumUpkeepRegistrationRequests ¶
type EthereumUpkeepRegistrationRequests struct {
// contains filtered or unexported fields
}
EthereumUpkeepRegistrationRequests keeper contract to register upkeeps
func (*EthereumUpkeepRegistrationRequests) Address ¶
func (v *EthereumUpkeepRegistrationRequests) Address() string
func (*EthereumUpkeepRegistrationRequests) EncodeRegisterRequest ¶
func (v *EthereumUpkeepRegistrationRequests) EncodeRegisterRequest( name string, email []byte, upkeepAddr string, gasLimit uint32, adminAddr string, checkData []byte, amount *big.Int, source uint8, ) ([]byte, error)
EncodeRegisterRequest encodes register request to call it through link token TransferAndCall
func (*EthereumUpkeepRegistrationRequests) Fund ¶
func (v *EthereumUpkeepRegistrationRequests) Fund(ethAmount *big.Float) error
func (*EthereumUpkeepRegistrationRequests) SetRegistrarConfig ¶
func (v *EthereumUpkeepRegistrationRequests) SetRegistrarConfig( autoRegister bool, windowSizeBlocks uint32, allowedPerWindow uint16, registryAddr string, minLinkJuels *big.Int, ) error
SetRegistrarConfig sets registrar config, allowing auto register or pending requests for manual registration
type EthereumVRF ¶
type EthereumVRF struct {
// contains filtered or unexported fields
}
EthereumVRF represents a VRF contract
func (*EthereumVRF) Fund ¶
func (v *EthereumVRF) Fund(ethAmount *big.Float) error
Fund sends specified currencies to the contract
func (*EthereumVRF) ProofLength ¶
ProofLength returns the PROOFLENGTH call from the VRF contract
type EthereumVRFConsumer ¶
type EthereumVRFConsumer struct {
// contains filtered or unexported fields
}
EthereumVRFConsumer represents VRF consumer contract
func (*EthereumVRFConsumer) Address ¶
func (v *EthereumVRFConsumer) Address() string
func (*EthereumVRFConsumer) CurrentRoundID ¶ added in v0.0.5
CurrentRoundID helper roundID counter in consumer to check when all randomness requests are finished
func (*EthereumVRFConsumer) RandomnessOutput ¶
RandomnessOutput get VRF randomness output
func (*EthereumVRFConsumer) RequestRandomness ¶
func (v *EthereumVRFConsumer) RequestRandomness(hash [32]byte, fee *big.Int) error
RequestRandomness requests VRF randomness
func (*EthereumVRFConsumer) WatchPerfEvents ¶ added in v0.0.7
func (v *EthereumVRFConsumer) WatchPerfEvents(ctx context.Context, eventChan chan<- *PerfEvent) error
type EthereumVRFConsumerV2 ¶ added in v1.0.54
type EthereumVRFConsumerV2 struct {
// contains filtered or unexported fields
}
EthereumVRFConsumerV2 represents VRFv2 consumer contract
func (*EthereumVRFConsumerV2) Address ¶ added in v1.0.54
func (v *EthereumVRFConsumerV2) Address() string
func (*EthereumVRFConsumerV2) CreateFundedSubscription ¶ added in v1.0.54
func (v *EthereumVRFConsumerV2) CreateFundedSubscription(funds *big.Int) error
CreateFundedSubscription create funded subscription for VRFv2 randomness
func (*EthereumVRFConsumerV2) CurrentSubscription ¶ added in v1.0.54
func (v *EthereumVRFConsumerV2) CurrentSubscription() (uint64, error)
CurrentSubscription get current VRFv2 subscription
func (*EthereumVRFConsumerV2) Fund ¶ added in v1.0.54
func (v *EthereumVRFConsumerV2) Fund(ethAmount *big.Float) error
func (*EthereumVRFConsumerV2) GasAvailable ¶ added in v1.1.4
func (v *EthereumVRFConsumerV2) GasAvailable() (*big.Int, error)
GasAvailable get available gas after randomness fulfilled
func (*EthereumVRFConsumerV2) GetAllRandomWords ¶ added in v1.1.6
GetAllRandomWords get all VRFv2 randomness output words
func (*EthereumVRFConsumerV2) RandomnessOutput ¶ added in v1.0.54
func (v *EthereumVRFConsumerV2) RandomnessOutput(ctx context.Context, arg0 *big.Int) (*big.Int, error)
RandomnessOutput get VRFv2 randomness output (word)
func (*EthereumVRFConsumerV2) RequestRandomness ¶ added in v1.0.54
func (v *EthereumVRFConsumerV2) RequestRandomness(hash [32]byte, subID uint64, confs uint16, gasLimit uint32, numWords uint32) error
RequestRandomness request VRFv2 random words
func (*EthereumVRFConsumerV2) TopUpSubscriptionFunds ¶ added in v1.1.6
func (v *EthereumVRFConsumerV2) TopUpSubscriptionFunds(funds *big.Int) error
TopUpSubscriptionFunds add funds to a VRFv2 subscription
type EthereumVRFCoordinator ¶
type EthereumVRFCoordinator struct {
// contains filtered or unexported fields
}
EthereumVRFCoordinator represents VRF coordinator contract
func (*EthereumVRFCoordinator) Address ¶
func (v *EthereumVRFCoordinator) Address() string
func (*EthereumVRFCoordinator) HashOfKey ¶
func (v *EthereumVRFCoordinator) HashOfKey(ctx context.Context, pubKey [2]*big.Int) ([32]byte, error)
HashOfKey get a hash of proving key to use it as a request ID part for VRF
func (*EthereumVRFCoordinator) RegisterProvingKey ¶
func (v *EthereumVRFCoordinator) RegisterProvingKey( fee *big.Int, oracleAddr string, publicProvingKey [2]*big.Int, jobID [32]byte, ) error
RegisterProvingKey register VRF proving key
type EthereumVRFCoordinatorV2 ¶ added in v1.0.54
type EthereumVRFCoordinatorV2 struct {
// contains filtered or unexported fields
}
EthereumVRFCoordinatorV2 represents VRFV2 coordinator contract
func (*EthereumVRFCoordinatorV2) Address ¶ added in v1.0.54
func (v *EthereumVRFCoordinatorV2) Address() string
func (*EthereumVRFCoordinatorV2) RegisterProvingKey ¶ added in v1.0.54
func (v *EthereumVRFCoordinatorV2) RegisterProvingKey( oracleAddr string, publicProvingKey [2]*big.Int, ) error
func (*EthereumVRFCoordinatorV2) SetConfig ¶ added in v1.0.54
func (v *EthereumVRFCoordinatorV2) SetConfig(minimumRequestConfirmations uint16, maxGasLimit uint32, stalenessSeconds uint32, gasAfterPaymentCalculation uint32, fallbackWeiPerUnitLink *big.Int, feeConfig ethereum.VRFCoordinatorV2FeeConfig) error
type FluxAggregator ¶
type FluxAggregator interface { Address() string Fund(ethAmount *big.Float) error LatestRoundID(ctx context.Context) (*big.Int, error) LatestRoundData(ctx context.Context) (RoundData, error) GetContractData(ctxt context.Context) (*FluxAggregatorData, error) UpdateAvailableFunds() error PaymentAmount(ctx context.Context) (*big.Int, error) RequestNewRound(ctx context.Context) error WithdrawPayment(ctx context.Context, from common.Address, to common.Address, amount *big.Int) error WithdrawablePayment(ctx context.Context, addr common.Address) (*big.Int, error) GetOracles(ctx context.Context) ([]string, error) SetOracles(opts FluxAggregatorSetOraclesOptions) error Description(ctxt context.Context) (string, error) SetRequesterPermissions(ctx context.Context, addr common.Address, authorized bool, roundsDelay uint32) error WatchSubmissionReceived(ctx context.Context, eventChan chan<- *SubmissionEvent) error }
type FluxAggregatorData ¶
type FluxAggregatorData struct { AllocatedFunds *big.Int // The amount of payment yet to be withdrawn by oracles AvailableFunds *big.Int // The amount of future funding available to oracles LatestRoundData RoundData // Data about the latest round Oracles []common.Address // Addresses of oracles on the contract }
type FluxAggregatorOptions ¶
type FluxAggregatorOptions struct { PaymentAmount *big.Int // The amount of LINK paid to each oracle per submission, in wei (units of 10⁻¹⁸ LINK) Timeout uint32 // The number of seconds after the previous round that are allowed to lapse before allowing an oracle to skip an unfinished round Validator common.Address // An optional contract address for validating external validation of answers MinSubValue *big.Int // An immutable check for a lower bound of what submission values are accepted from an oracle MaxSubValue *big.Int // An immutable check for an upper bound of what submission values are accepted from an oracle Decimals uint8 // The number of decimals to offset the answer by Description string // A short description of what is being reported }
func DefaultFluxAggregatorOptions ¶
func DefaultFluxAggregatorOptions() FluxAggregatorOptions
DefaultFluxAggregatorOptions produces some basic defaults for a flux aggregator contract
type FluxAggregatorRoundConfirmer ¶
type FluxAggregatorRoundConfirmer struct {
// contains filtered or unexported fields
}
FluxAggregatorRoundConfirmer is a header subscription that awaits for a certain flux round to be completed
func NewFluxAggregatorRoundConfirmer ¶
func NewFluxAggregatorRoundConfirmer( contract FluxAggregator, roundID *big.Int, timeout time.Duration, ) *FluxAggregatorRoundConfirmer
NewFluxAggregatorRoundConfirmer provides a new instance of a FluxAggregatorRoundConfirmer
func (*FluxAggregatorRoundConfirmer) ReceiveBlock ¶
func (f *FluxAggregatorRoundConfirmer) ReceiveBlock(block client.NodeBlock) error
ReceiveBlock will query the latest FluxAggregator round and check to see whether the round has confirmed
func (*FluxAggregatorRoundConfirmer) Wait ¶
func (f *FluxAggregatorRoundConfirmer) Wait() error
Wait is a blocking function that will wait until the round has confirmed, and timeout if the deadline has passed
type FluxAggregatorSetOraclesOptions ¶
type FluxAggregatorSetOraclesOptions struct { AddList []common.Address // oracle addresses to add RemoveList []common.Address // oracle addresses to remove AdminList []common.Address // oracle addresses to become admin MinSubmissions uint32 // min amount of submissions in round MaxSubmissions uint32 // max amount of submissions in round RestartDelayRounds uint32 // rounds to wait after oracles has changed }
type JobByInstance ¶
JobByInstance helper struct to match job + instance ID
type KeeperConsumer ¶
type KeeperConsumerPerformance ¶ added in v1.0.48
type KeeperConsumerPerformance interface { Address() string Fund(ethAmount *big.Float) error CheckEligible(ctx context.Context) (bool, error) GetUpkeepCount(ctx context.Context) (*big.Int, error) }
KeeperConsumerPerformance is a keeper consumer contract that is more complicated than the typical consumer, it's intended to only be used for performance tests.
type KeeperConsumerPerformanceRoundConfirmer ¶ added in v1.0.48
type KeeperConsumerPerformanceRoundConfirmer struct {
// contains filtered or unexported fields
}
KeeperConsumerPerformanceRoundConfirmer is a header subscription that awaits for a round of upkeeps
func NewKeeperConsumerPerformanceRoundConfirmer ¶ added in v1.0.48
func NewKeeperConsumerPerformanceRoundConfirmer( contract KeeperConsumerPerformance, expectedBlockCadence int64, blockRange int64, metricsReporter *testreporters.KeeperBlockTimeTestReporter, ) *KeeperConsumerPerformanceRoundConfirmer
NewKeeperConsumerPerformanceRoundConfirmer provides a new instance of a KeeperConsumerPerformanceRoundConfirmer Used to track and log performance test results for keepers
func (*KeeperConsumerPerformanceRoundConfirmer) ReceiveBlock ¶ added in v1.0.48
func (o *KeeperConsumerPerformanceRoundConfirmer) ReceiveBlock(receivedBlock client.NodeBlock) error
ReceiveBlock will query the latest Keeper round and check to see whether the round has confirmed
func (*KeeperConsumerPerformanceRoundConfirmer) Wait ¶ added in v1.0.48
func (o *KeeperConsumerPerformanceRoundConfirmer) Wait() error
Wait is a blocking function that will wait until the round has confirmed, and timeout if the deadline has passed
type KeeperConsumerRoundConfirmer ¶ added in v0.0.5
type KeeperConsumerRoundConfirmer struct {
// contains filtered or unexported fields
}
KeeperConsumerRoundConfirmer is a header subscription that awaits for a round of upkeeps
func NewKeeperConsumerRoundConfirmer ¶ added in v0.0.5
func NewKeeperConsumerRoundConfirmer( contract KeeperConsumer, counterValue int, timeout time.Duration, ) *KeeperConsumerRoundConfirmer
NewKeeperConsumerRoundConfirmer provides a new instance of a KeeperConsumerRoundConfirmer
func (*KeeperConsumerRoundConfirmer) ReceiveBlock ¶ added in v0.0.5
func (o *KeeperConsumerRoundConfirmer) ReceiveBlock(_ client.NodeBlock) error
ReceiveBlock will query the latest Keeper round and check to see whether the round has confirmed
func (*KeeperConsumerRoundConfirmer) Wait ¶ added in v0.0.5
func (o *KeeperConsumerRoundConfirmer) Wait() error
Wait is a blocking function that will wait until the round has confirmed, and timeout if the deadline has passed
type KeeperInfo ¶
KeeperInfo keeper status and balance info
type KeeperRegistry ¶
type KeeperRegistry interface { Address() string Fund(ethAmount *big.Float) error SetRegistrar(registrarAddr string) error AddUpkeepFunds(id *big.Int, amount *big.Int) error GetUpkeepInfo(ctx context.Context, id *big.Int) (*UpkeepInfo, error) GetKeeperInfo(ctx context.Context, keeperAddr string) (*KeeperInfo, error) SetKeepers(keepers []string, payees []string) error GetKeeperList(ctx context.Context) ([]string, error) RegisterUpkeep(target string, gasLimit uint32, admin string, checkData []byte) error }
type KeeperRegistryOpts ¶
type KeeperRegistryOpts struct { LinkAddr string ETHFeedAddr string GasFeedAddr string PaymentPremiumPPB uint32 FlatFeeMicroLINK uint32 BlockCountPerTurn *big.Int CheckGasLimit uint32 StalenessSeconds *big.Int GasCeilingMultiplier uint16 FallbackGasPrice *big.Int FallbackLinkPrice *big.Int }
KeeperRegistryOpts opts to deploy keeper registry
type KeeperRegistrySettings ¶ added in v1.0.54
type KeeperRegistrySettings struct { PaymentPremiumPPB uint32 // payment premium rate oracles receive on top of being reimbursed for gas, measured in parts per billion BlockCountPerTurn *big.Int // number of blocks each oracle has during their turn to perform upkeep before it will be the next keeper's turn to submit CheckGasLimit uint32 // gas limit when checking for upkeep StalenessSeconds *big.Int // number of seconds that is allowed for feed data to be stale before switching to the fallback pricing GasCeilingMultiplier uint16 // multiplier to apply to the fast gas feed price when calculating the payment ceiling for keepers FallbackGasPrice *big.Int // gas price used if the gas price feed is stale FallbackLinkPrice *big.Int // LINK price used if the LINK price feed is stale }
KeeperRegistrySettings represents the fine tuning settings for each upkeep contract
type MessageExecutor ¶ added in v1.1.15
type MessageExecutor interface { Address() string SetConfig([]ocrConfigHelper2.OracleIdentityExtra) error }
type MockETHLINKFeed ¶
type MockGasFeed ¶
type MockGasFeed interface {
Address() string
}
type NativeTokenPool ¶ added in v1.1.15
type OffChainAggregatorConfig ¶
type OffChainAggregatorConfig struct { DeltaProgress time.Duration // The duration in which a leader must achieve progress or be replaced DeltaResend time.Duration // The interval at which nodes resend NEWEPOCH messages DeltaRound time.Duration // The duration after which a new round is started DeltaGrace time.Duration // The duration of the grace period during which delayed oracles can still submit observations DeltaC time.Duration // Limits how often updates are transmitted to the contract as long as the median isn’t changing by more then AlphaPPB AlphaPPB uint64 // Allows larger changes of the median to be reported immediately, bypassing DeltaC DeltaStage time.Duration // Used to stagger stages of the transmission protocol. Multiple Ethereum blocks must be mineable in this period RMax uint8 // The maximum number of rounds in an epoch S []int // Transmission Schedule F int // The allowed number of "bad" oracles N int // The number of oracles OracleIdentities []ocrConfigHelper.OracleIdentityExtra }
func DefaultOffChainAggregatorConfig ¶
func DefaultOffChainAggregatorConfig(numberNodes int) OffChainAggregatorConfig
DefaultOffChainAggregatorConfig returns some base defaults for configuring an OCR contract
type OffChainAggregatorV2Config ¶ added in v0.0.36
type OffChainAggregatorV2Config struct { DeltaProgress time.Duration DeltaResend time.Duration DeltaRound time.Duration DeltaGrace time.Duration DeltaStage time.Duration RMax uint8 S []int Oracles []ocrConfigHelper2.OracleIdentityExtra ReportingPluginConfig []byte MaxDurationQuery time.Duration MaxDurationObservation time.Duration MaxDurationReport time.Duration MaxDurationShouldAcceptFinalizedReport time.Duration MaxDurationShouldTransmitAcceptedReport time.Duration F int OnchainConfig []byte }
type OffRamp ¶ added in v1.1.15
type OffRamp interface { Address() string SetRouter(addr string) error WatchEvents() SetConfig([]ocrConfigHelper2.OracleIdentityExtra) error }
type OffRampRouter ¶ added in v1.1.17
type OffRampRouter interface {
Address() string
}
type OffchainAggregator ¶
type OffchainAggregator interface { Address() string Fund(nativeAmount *big.Float) error GetContractData(ctxt context.Context) (*OffchainAggregatorData, error) SetConfig(chainlinkNodes []client.Chainlink, ocrConfig OffChainAggregatorConfig) error SetPayees([]string, []string) error RequestNewRound() error GetLatestAnswer(ctxt context.Context) (*big.Int, error) GetLatestRound(ctxt context.Context) (*RoundData, error) }
type OffchainAggregatorData ¶
type OffchainAggregatorData struct {
LatestRoundData RoundData // Data about the latest round
}
type OffchainAggregatorRoundConfirmer ¶
type OffchainAggregatorRoundConfirmer struct {
// contains filtered or unexported fields
}
OffchainAggregatorRoundConfirmer is a header subscription that awaits for a certain OCR round to be completed
func NewOffchainAggregatorRoundConfirmer ¶
func NewOffchainAggregatorRoundConfirmer( contract OffchainAggregator, roundID *big.Int, timeout time.Duration, optionalTestReport *testreporters.OCRSoakTestReport, ) *OffchainAggregatorRoundConfirmer
NewOffchainAggregatorRoundConfirmer provides a new instance of a OffchainAggregatorRoundConfirmer
func (*OffchainAggregatorRoundConfirmer) ReceiveBlock ¶
func (o *OffchainAggregatorRoundConfirmer) ReceiveBlock(_ client.NodeBlock) error
ReceiveBlock will query the latest OffchainAggregator round and check to see whether the round has confirmed
func (*OffchainAggregatorRoundConfirmer) Wait ¶
func (o *OffchainAggregatorRoundConfirmer) Wait() error
Wait is a blocking function that will wait until the round has confirmed, and timeout if the deadline has passed
type OffchainOptions ¶
type OffchainOptions struct { MaximumGasPrice uint32 // The highest gas price for which transmitter will be compensated ReasonableGasPrice uint32 // The transmitter will receive reward for gas prices under this value MicroLinkPerEth uint32 // The reimbursement per ETH of gas cost, in 1e-6LINK units LinkGweiPerObservation uint32 // The reward to the oracle for contributing an observation to a successfully transmitted report, in 1e-9LINK units LinkGweiPerTransmission uint32 // The reward to the transmitter of a successful report, in 1e-9LINK units MinimumAnswer *big.Int // The lowest answer the median of a report is allowed to be MaximumAnswer *big.Int // The highest answer the median of a report is allowed to be BillingAccessController common.Address // The access controller for billing admin functions RequesterAccessController common.Address // The access controller for requesting new rounds Decimals uint8 // Answers are stored in fixed-point format, with this many digits of precision Description string // A short description of what is being reported }
func DefaultOffChainAggregatorOptions ¶
func DefaultOffChainAggregatorOptions() OffchainOptions
DefaultOffChainAggregatorOptions returns some base defaults for deploying an OCR contract
type OnRampRouter ¶ added in v1.1.17
type PerfEvent ¶ added in v0.0.7
type PerfEvent struct { Contract DeviationFlaggingValidator Round *big.Int RequestID [32]byte BlockTimestamp *big.Int }
PerfEvent is used to get some metrics for contracts, it contrains roundID for Keeper/OCR/Flux tests and request id for VRF/Runlog
type ReadAccessController ¶
type ReadAccessController interface { Address() string AddAccess(addr string) error DisableAccessCheck() error }
ReadAccessController is read/write access controller, just named by interface
type ReceiverDapp ¶ added in v1.1.15
type ReceiverDapp interface {
Address() string
}
type RunlogRoundConfirmer ¶ added in v0.0.7
type RunlogRoundConfirmer struct {
// contains filtered or unexported fields
}
RunlogRoundConfirmer is a header subscription that awaits for a certain Runlog round to be completed
func NewRunlogRoundConfirmer ¶ added in v0.0.7
func NewRunlogRoundConfirmer( contract APIConsumer, roundID *big.Int, timeout time.Duration, ) *RunlogRoundConfirmer
NewRunlogRoundConfirmer provides a new instance of a RunlogRoundConfirmer
func (*RunlogRoundConfirmer) ReceiveBlock ¶ added in v0.0.7
func (o *RunlogRoundConfirmer) ReceiveBlock(_ client.NodeBlock) error
ReceiveBlock will query the latest Runlog round and check to see whether the round has confirmed
func (*RunlogRoundConfirmer) Wait ¶ added in v0.0.7
func (o *RunlogRoundConfirmer) Wait() error
Wait is a blocking function that will wait until the round has confirmed, and timeout if the deadline has passed
type SenderDapp ¶ added in v1.1.15
type SimpleMessageReceiver ¶ added in v1.1.15
type SimpleMessageReceiver interface {
Address() string
}
type SubmissionEvent ¶
type UpkeepInfo ¶
type UpkeepInfo struct { Target string ExecuteGas uint32 CheckData []byte Balance *big.Int LastKeeper string Admin string MaxValidBlocknumber uint64 }
UpkeepInfo keeper target info
type UpkeepRegistrar ¶
type UpkeepRegistrar interface { Address() string SetRegistrarConfig( autoRegister bool, windowSizeBlocks uint32, allowedPerWindow uint16, registryAddr string, minLinkJuels *big.Int, ) error EncodeRegisterRequest( name string, email []byte, upkeepAddr string, gasLimit uint32, adminAddr string, checkData []byte, amount *big.Int, source uint8, ) ([]byte, error) Fund(ethAmount *big.Float) error }
type VRFConsumer ¶
type VRFConsumer interface { Address() string RequestRandomness(hash [32]byte, fee *big.Int) error CurrentRoundID(ctx context.Context) (*big.Int, error) RandomnessOutput(ctx context.Context) (*big.Int, error) WatchPerfEvents(ctx context.Context, eventChan chan<- *PerfEvent) error Fund(ethAmount *big.Float) error }
type VRFConsumerRoundConfirmer ¶ added in v0.0.5
type VRFConsumerRoundConfirmer struct {
// contains filtered or unexported fields
}
VRFConsumerRoundConfirmer is a header subscription that awaits for a certain VRF round to be completed
func NewVRFConsumerRoundConfirmer ¶ added in v0.0.5
func NewVRFConsumerRoundConfirmer( contract VRFConsumer, roundID *big.Int, timeout time.Duration, ) *VRFConsumerRoundConfirmer
NewVRFConsumerRoundConfirmer provides a new instance of a NewVRFConsumerRoundConfirmer
func (*VRFConsumerRoundConfirmer) ReceiveBlock ¶ added in v0.0.5
func (f *VRFConsumerRoundConfirmer) ReceiveBlock(block client.NodeBlock) error
ReceiveBlock will query the latest VRFConsumer round and check to see whether the round has confirmed
func (*VRFConsumerRoundConfirmer) Wait ¶ added in v0.0.5
func (f *VRFConsumerRoundConfirmer) Wait() error
Wait is a blocking function that will wait until the round has confirmed, and timeout if the deadline has passed
type VRFConsumerV2 ¶ added in v1.0.54
type VRFConsumerV2 interface { Address() string CurrentSubscription() (uint64, error) CreateFundedSubscription(funds *big.Int) error TopUpSubscriptionFunds(funds *big.Int) error RequestRandomness(hash [32]byte, subID uint64, confs uint16, gasLimit uint32, numWords uint32) error RandomnessOutput(ctx context.Context, arg0 *big.Int) (*big.Int, error) GetAllRandomWords(ctx context.Context, num int) ([]*big.Int, error) GasAvailable() (*big.Int, error) Fund(ethAmount *big.Float) error }
type VRFCoordinator ¶
type VRFCoordinatorV2 ¶ added in v1.0.54
type VRFCoordinatorV2 interface { SetConfig( minimumRequestConfirmations uint16, maxGasLimit uint32, stalenessSeconds uint32, gasAfterPaymentCalculation uint32, fallbackWeiPerUnitLink *big.Int, feeConfig ethereum.VRFCoordinatorV2FeeConfig, ) error RegisterProvingKey( oracleAddr string, publicProvingKey [2]*big.Int, ) error HashOfKey(ctx context.Context, pubKey [2]*big.Int) ([32]byte, error) Address() string }