client

package
v2.0.0-prerelease3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 9, 2024 License: GPL-3.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ApiClient

type ApiClient struct {
	Auction  *AuctionRequester
	Faucet   *FaucetRequester
	Minipool *MinipoolRequester
	Network  *NetworkRequester
	Node     *NodeRequester
	ODao     *ODaoRequester
	PDao     *PDaoRequester
	Queue    *QueueRequester
	Security *SecurityRequester
	Service  *ServiceRequester
	Tx       *TxRequester
	Wallet   *WalletRequester
	// contains filtered or unexported fields
}

Binder for the Smart Node daemon API server

func NewApiClient

func NewApiClient(baseRoute string, socketPath string, logger *slog.Logger) *ApiClient

Creates a new API client instance

type AuctionRequester

type AuctionRequester struct {
	// contains filtered or unexported fields
}

func NewAuctionRequester

func NewAuctionRequester(context *client.RequesterContext) *AuctionRequester

func (*AuctionRequester) BidOnLot

func (r *AuctionRequester) BidOnLot(lotIndex uint64, amountWei *big.Int) (*types.ApiResponse[api.AuctionBidOnLotData], error)

Bid on a lot

func (*AuctionRequester) ClaimFromLots

Claim RPL from lots

func (*AuctionRequester) CreateLot

Create a new lot

func (*AuctionRequester) GetContext

func (r *AuctionRequester) GetContext() *client.RequesterContext

func (*AuctionRequester) GetName

func (r *AuctionRequester) GetName() string

func (*AuctionRequester) GetRoute

func (r *AuctionRequester) GetRoute() string

func (*AuctionRequester) Lots

Get RPL lots for auction

func (*AuctionRequester) RecoverUnclaimedRplFromLots

func (r *AuctionRequester) RecoverUnclaimedRplFromLots(indices []uint64) (*types.ApiResponse[types.DataBatch[api.AuctionRecoverRplFromLotData]], error)

Recover unclaimed RPL from lots (returning it to the auction contract)

func (*AuctionRequester) Status

Get RPL auction status

type FaucetRequester

type FaucetRequester struct {
	// contains filtered or unexported fields
}

func NewFaucetRequester

func NewFaucetRequester(context *client.RequesterContext) *FaucetRequester

func (*FaucetRequester) GetContext

func (r *FaucetRequester) GetContext() *client.RequesterContext

func (*FaucetRequester) GetName

func (r *FaucetRequester) GetName() string

func (*FaucetRequester) GetRoute

func (r *FaucetRequester) GetRoute() string

func (*FaucetRequester) Status

Get faucet status

func (*FaucetRequester) WithdrawRpl

Withdraw RPL from the faucet

type MinipoolRequester

type MinipoolRequester struct {
	// contains filtered or unexported fields
}

func NewMinipoolRequester

func NewMinipoolRequester(context *client.RequesterContext) *MinipoolRequester

func (*MinipoolRequester) BeginReduceBond

func (r *MinipoolRequester) BeginReduceBond(addresses []common.Address, newBondAmount *big.Int) (*types.ApiResponse[types.BatchTxInfoData], error)

Begin reduce bond on minipools

func (*MinipoolRequester) CanChangeWithdrawalCredentials

func (r *MinipoolRequester) CanChangeWithdrawalCredentials(address common.Address, mnemonic string) (*types.ApiResponse[api.MinipoolCanChangeWithdrawalCredentialsData], error)

Verify that migrating a solo validator's withdrawal creds to a minipool address is possible

func (*MinipoolRequester) ChangeWithdrawalCredentials

func (r *MinipoolRequester) ChangeWithdrawalCredentials(address common.Address, mnemonic string) (*types.ApiResponse[types.SuccessData], error)

Migrate a solo validator's withdrawal creds to a minipool address

func (*MinipoolRequester) Close

Close minipools

func (*MinipoolRequester) Dissolve

Dissolve minipools

func (*MinipoolRequester) Distribute

func (r *MinipoolRequester) Distribute(addresses []common.Address) (*types.ApiResponse[types.BatchTxInfoData], error)

Distribute minipool balances

func (*MinipoolRequester) Exit

Exit minipools

func (*MinipoolRequester) GetBeginReduceBondDetails

func (r *MinipoolRequester) GetBeginReduceBondDetails() (*types.ApiResponse[api.MinipoolBeginReduceBondDetailsData], error)

Get begin reduce bond details

func (*MinipoolRequester) GetCloseDetails

Get close details

func (*MinipoolRequester) GetContext

func (r *MinipoolRequester) GetContext() *client.RequesterContext

func (*MinipoolRequester) GetDelegateDetails

Get delegate details

func (*MinipoolRequester) GetDissolveDetails

Get dissolve details

func (*MinipoolRequester) GetDistributeDetails

Get distribute minipool balances details

func (*MinipoolRequester) GetExitDetails

Get exit details

func (*MinipoolRequester) GetName

func (r *MinipoolRequester) GetName() string

func (*MinipoolRequester) GetPromoteDetails

Get promote details

func (*MinipoolRequester) GetReduceBondDetails

Get reduce bond details

func (*MinipoolRequester) GetRefundDetails

Get refund details

func (*MinipoolRequester) GetRescueDissolvedDetails

func (r *MinipoolRequester) GetRescueDissolvedDetails() (*types.ApiResponse[api.MinipoolRescueDissolvedDetailsData], error)

Get rescue dissolved details

func (*MinipoolRequester) GetRoute

func (r *MinipoolRequester) GetRoute() string

func (*MinipoolRequester) GetStakeDetails

Get stake details

func (*MinipoolRequester) GetVanityArtifacts

func (r *MinipoolRequester) GetVanityArtifacts(nodeAddressStr string) (*types.ApiResponse[api.MinipoolVanityArtifactsData], error)

Get the artifacts necessary for vanity address searching

func (*MinipoolRequester) ImportKey

func (r *MinipoolRequester) ImportKey(address common.Address, mnemonic string) (*types.ApiResponse[types.SuccessData], error)

Import a validator private key for a vacant minipool

func (*MinipoolRequester) Promote

Promote minipools

func (*MinipoolRequester) ReduceBond

func (r *MinipoolRequester) ReduceBond(addresses []common.Address) (*types.ApiResponse[types.BatchTxInfoData], error)

Reduce bond on minipools

func (*MinipoolRequester) Refund

Refund ETH from minipools

func (*MinipoolRequester) RescueDissolved

func (r *MinipoolRequester) RescueDissolved(addresses []common.Address, depositAmounts []*big.Int) (*types.ApiResponse[types.BatchTxInfoData], error)

Rescue dissolved minipools

func (*MinipoolRequester) RollbackDelegates

func (r *MinipoolRequester) RollbackDelegates(addresses []common.Address) (*types.ApiResponse[types.BatchTxInfoData], error)

Rollback minipool delegates

func (*MinipoolRequester) SetUseLatestDelegates

func (r *MinipoolRequester) SetUseLatestDelegates(addresses []common.Address, setting bool) (*types.ApiResponse[types.BatchTxInfoData], error)

Set the use-latest-delegate setting for minipools

func (*MinipoolRequester) Stake

Stake minipools

func (*MinipoolRequester) Status

Get minipool status

func (*MinipoolRequester) UpgradeDelegates

func (r *MinipoolRequester) UpgradeDelegates(addresses []common.Address) (*types.ApiResponse[types.BatchTxInfoData], error)

Upgrade minipool delegates

type NetworkRequester

type NetworkRequester struct {
	// contains filtered or unexported fields
}

func NewNetworkRequester

func NewNetworkRequester(context *client.RequesterContext) *NetworkRequester

func (*NetworkRequester) DownloadRewardsFile

func (r *NetworkRequester) DownloadRewardsFile(interval uint64) (*types.ApiResponse[types.SuccessData], error)

Download a rewards info file from IPFS or Github for the given interval

func (*NetworkRequester) GenerateRewardsTree

func (r *NetworkRequester) GenerateRewardsTree(index uint64) (*types.ApiResponse[types.SuccessData], error)

Set a request marker for the watchtower to generate the rewards tree for the given interval

func (*NetworkRequester) GetActiveDaoProposals

func (r *NetworkRequester) GetActiveDaoProposals() (*types.ApiResponse[api.NetworkDaoProposalsData], error)

Get information about active Protocol DAO proposals on Snapshot

func (*NetworkRequester) GetContext

func (r *NetworkRequester) GetContext() *client.RequesterContext

func (*NetworkRequester) GetDepositContractInfo

func (r *NetworkRequester) GetDepositContractInfo() (*types.ApiResponse[api.NetworkDepositContractInfoData], error)

Get the deposit contract info for Rocket Pool and the Beacon Client

func (*NetworkRequester) GetLatestDelegate

Get the address of the latest minipool delegate contract

func (*NetworkRequester) GetName

func (r *NetworkRequester) GetName() string

func (*NetworkRequester) GetRoute

func (r *NetworkRequester) GetRoute() string

func (*NetworkRequester) NodeFee

Get network node fee

func (*NetworkRequester) RewardsFileInfo

func (r *NetworkRequester) RewardsFileInfo(index uint64) (*types.ApiResponse[api.NetworkRewardsFileData], error)

Get information about whether or not a rewards file can be regenerated, and whether or not one already exists

func (*NetworkRequester) RplPrice

Get network RPL price

func (*NetworkRequester) Stats

Get network stats

func (*NetworkRequester) TimezoneMap

Get the timezone map

type NodeRequester

type NodeRequester struct {
	// contains filtered or unexported fields
}

func NewNodeRequester

func NewNodeRequester(context *client.RequesterContext) *NodeRequester

func (*NodeRequester) Balance

Get the node's ETH balance

func (*NodeRequester) Burn

func (r *NodeRequester) Burn(amount *big.Int) (*types.ApiResponse[api.NodeBurnData], error)

Burn rETH owned by the node for ETH

func (*NodeRequester) CheckCollateral

func (r *NodeRequester) CheckCollateral() (*types.ApiResponse[api.NodeCheckCollateralData], error)

Get the node's collateral info, including pending bond reductions

func (*NodeRequester) ClaimAndStake

func (r *NodeRequester) ClaimAndStake(indices []*big.Int, stakeAmount *big.Int) (*types.ApiResponse[types.TxInfoData], error)

Claim rewards for the given reward intervals

func (*NodeRequester) ClearSnapshotDelegate

func (r *NodeRequester) ClearSnapshotDelegate() (*types.ApiResponse[types.TxInfoData], error)

Clear the node's voting snapshot delegate

func (*NodeRequester) ConfirmPrimaryWithdrawalAddress

func (r *NodeRequester) ConfirmPrimaryWithdrawalAddress() (*types.ApiResponse[api.NodeConfirmPrimaryWithdrawalAddressData], error)

Confirm the node's withdrawal address

func (*NodeRequester) ConfirmRplWithdrawalAddress

func (r *NodeRequester) ConfirmRplWithdrawalAddress() (*types.ApiResponse[api.NodeConfirmRplWithdrawalAddressData], error)

Confirm the node's RPL address

func (*NodeRequester) CreateVacantMinipool

func (r *NodeRequester) CreateVacantMinipool(amount *big.Int, minFee float64, salt *big.Int, pubkey beacon.ValidatorPubkey) (*types.ApiResponse[api.NodeCreateVacantMinipoolData], error)

Create a vacant minipool, which can be used to migrate a solo staker

func (*NodeRequester) Deposit

func (r *NodeRequester) Deposit(amount *big.Int, minFee float64, salt *big.Int) (*types.ApiResponse[api.NodeDepositData], error)

Make a node deposit

func (*NodeRequester) Distribute

Distribute ETH from the node's fee distributor

func (*NodeRequester) GetContext

func (r *NodeRequester) GetContext() *client.RequesterContext

func (*NodeRequester) GetName

func (r *NodeRequester) GetName() string

func (*NodeRequester) GetRewardsInfo

Get info about your eligible rewards periods, including balances and Merkle proofs

func (*NodeRequester) GetRoute

func (r *NodeRequester) GetRoute() string

func (*NodeRequester) InitializeFeeDistributor

func (r *NodeRequester) InitializeFeeDistributor() (*types.ApiResponse[api.NodeInitializeFeeDistributorData], error)

Initialize the fee distributor contract

func (*NodeRequester) Register

func (r *NodeRequester) Register(timezoneLocation string) (*types.ApiResponse[api.NodeRegisterData], error)

Register the node

func (*NodeRequester) ResolveEns

func (r *NodeRequester) ResolveEns(address common.Address, name string) (*types.ApiResponse[api.NodeResolveEnsData], error)

Resolves an ENS name or reserve resolves an address

func (*NodeRequester) Rewards

Get node rewards status

func (*NodeRequester) Send

func (r *NodeRequester) Send(amount *big.Int, token string, recipient common.Address) (*types.ApiResponse[api.NodeSendData], error)

Send tokens from the node to an address

func (*NodeRequester) SetPrimaryWithdrawalAddress

func (r *NodeRequester) SetPrimaryWithdrawalAddress(withdrawalAddress common.Address, confirm bool) (*types.ApiResponse[api.NodeSetPrimaryWithdrawalAddressData], error)

Set the node's primary withdrawal address

func (*NodeRequester) SetRplLockingAllowed

func (r *NodeRequester) SetRplLockingAllowed(allowed bool) (*types.ApiResponse[api.NodeSetRplLockingAllowedData], error)

Sets whether or not the node is allowed to lock RPL for Protocol DAO proposal or challenge bonds

func (*NodeRequester) SetRplWithdrawalAddress

func (r *NodeRequester) SetRplWithdrawalAddress(withdrawalAddress common.Address, confirm bool) (*types.ApiResponse[api.NodeSetRplWithdrawalAddressData], error)

Set the node's RPL withdrawal address

func (*NodeRequester) SetSmoothingPoolRegistrationState

func (r *NodeRequester) SetSmoothingPoolRegistrationState(optIn bool) (*types.ApiResponse[api.NodeSetSmoothingPoolRegistrationStatusData], error)

Sets the node's Smoothing Pool opt-in status

func (*NodeRequester) SetSnapshotDelegate

func (r *NodeRequester) SetSnapshotDelegate(delegate common.Address) (*types.ApiResponse[types.TxInfoData], error)

Set a voting snapshot delegate for the node

func (*NodeRequester) SetStakeRplForAllowed

func (r *NodeRequester) SetStakeRplForAllowed(caller common.Address, allowed bool) (*types.ApiResponse[api.NodeSetStakeRplForAllowedData], error)

Sets the allow state of another address staking on behalf of the node

func (*NodeRequester) SetTimezone

func (r *NodeRequester) SetTimezone(timezoneLocation string) (*types.ApiResponse[types.TxInfoData], error)

Set the node's timezone location

func (*NodeRequester) StakeRpl

func (r *NodeRequester) StakeRpl(amount *big.Int) (*types.ApiResponse[api.NodeStakeRplData], error)

Stake RPL against the node

func (*NodeRequester) Status

Get node status

func (*NodeRequester) SwapRpl

func (r *NodeRequester) SwapRpl(amount *big.Int) (*types.ApiResponse[api.NodeSwapRplData], error)

Swap node's old RPL tokens for new RPL tokens

func (*NodeRequester) WithdrawEth

func (r *NodeRequester) WithdrawEth(amount *big.Int) (*types.ApiResponse[api.NodeWithdrawEthData], error)

Withdraw ETH staked on behalf of the node

func (*NodeRequester) WithdrawRpl

func (r *NodeRequester) WithdrawRpl(amount *big.Int) (*types.ApiResponse[api.NodeWithdrawRplData], error)

Withdraw RPL staked against the node

type ODaoRequester

type ODaoRequester struct {
	// contains filtered or unexported fields
}

func NewODaoRequester

func NewODaoRequester(context *client.RequesterContext) *ODaoRequester

func (*ODaoRequester) CancelProposal

Cancel a proposal made by the node

func (*ODaoRequester) ExecuteProposals

Execute a proposal

func (*ODaoRequester) GetContext

func (r *ODaoRequester) GetContext() *client.RequesterContext

func (*ODaoRequester) GetName

func (r *ODaoRequester) GetName() string

func (*ODaoRequester) GetRoute

func (r *ODaoRequester) GetRoute() string

func (*ODaoRequester) Join

Join the oracle DAO (requires an executed invite proposal)

func (*ODaoRequester) Leave

func (r *ODaoRequester) Leave(bondRefundAddress common.Address) (*types.ApiResponse[api.OracleDaoLeaveData], error)

Leave the oracle DAO (requires an executed leave proposal)

func (*ODaoRequester) Members

Get oracle DAO members

func (*ODaoRequester) Proposals

Get oracle DAO proposals

func (*ODaoRequester) ProposeInvite

func (r *ODaoRequester) ProposeInvite(memberAddress common.Address, memberId string, memberUrl string) (*types.ApiResponse[api.OracleDaoProposeInviteData], error)

Propose inviting a new member

func (*ODaoRequester) ProposeKick

func (r *ODaoRequester) ProposeKick(memberAddress common.Address, fineAmount *big.Int) (*types.ApiResponse[api.OracleDaoProposeKickData], error)

Propose kicking a member

func (*ODaoRequester) ProposeLeave

Propose leaving the oracle DAO

func (*ODaoRequester) ProposeSetting

func (r *ODaoRequester) ProposeSetting(contractName rocketpool.ContractName, settingName oracle.SettingName, value string) (*types.ApiResponse[api.OracleDaoProposeSettingData], error)

Propose an Oracle DAO setting update

func (*ODaoRequester) Settings

Get oracle DAO settings

func (*ODaoRequester) Status

Get oracle DAO status

func (*ODaoRequester) Vote

Vote on a proposal

type PDaoRequester

type PDaoRequester struct {
	// contains filtered or unexported fields
}

func NewPDaoRequester

func NewPDaoRequester(context *client.RequesterContext) *PDaoRequester

func (*PDaoRequester) ClaimBonds

Claim / unlock bonds from a proposal

func (*PDaoRequester) DefeatProposal

func (r *PDaoRequester) DefeatProposal(proposalID uint64, index uint64) (*types.ApiResponse[api.ProtocolDaoDefeatProposalData], error)

Defeat a proposal if it still has an challenge after voting has started

func (*PDaoRequester) ExecuteProposals

Execute one or more proposals

func (*PDaoRequester) FinalizeProposal

func (r *PDaoRequester) FinalizeProposal(proposalID uint64) (*types.ApiResponse[api.ProtocolDaoFinalizeProposalData], error)

Finalize a proposal if it's been vetoed by burning the proposer's bond

func (*PDaoRequester) GetClaimableBonds

Get the list of proposals with claimable / rewardable bonds, and the relevant indices for each one

func (*PDaoRequester) GetContext

func (r *PDaoRequester) GetContext() *client.RequesterContext

func (*PDaoRequester) GetCurrentVotingDelegate

func (r *PDaoRequester) GetCurrentVotingDelegate() (*types.ApiResponse[api.ProtocolDaoCurrentVotingDelegateData], error)

Get the address that's assigned as the delegate for voting on Protocol DAO proposals

func (*PDaoRequester) GetName

func (r *PDaoRequester) GetName() string

func (*PDaoRequester) GetRoute

func (r *PDaoRequester) GetRoute() string

func (*PDaoRequester) InitializeVoting

Initialize voting so the node can vote on Protocol DAO proposals

func (*PDaoRequester) InviteToSecurityCouncil

Propose inviting someone to the security council

func (*PDaoRequester) KickFromSecurityCouncil

Propose kicking someone from the security council

func (*PDaoRequester) KickMultiFromSecurityCouncil

Propose kicking multiple members from the security council

func (*PDaoRequester) OneTimeSpend

func (r *PDaoRequester) OneTimeSpend(invoiceID string, recipient common.Address, amount *big.Int) (*types.ApiResponse[api.ProtocolDaoGeneralProposeData], error)

Propose a one-time spend of the Protocol DAO's treasury

func (*PDaoRequester) OverrideVoteOnProposal

func (r *PDaoRequester) OverrideVoteOnProposal(proposalID uint64, voteDirection rptypes.VoteDirection) (*types.ApiResponse[api.ProtocolDaoVoteOnProposalData], error)

Override a delegate's vote on a proposal

func (*PDaoRequester) Proposals

Get the Protocol DAO proposals

func (*PDaoRequester) ProposeRewardsPercentages

func (r *PDaoRequester) ProposeRewardsPercentages(node *big.Int, odao *big.Int, pdao *big.Int) (*types.ApiResponse[api.ProtocolDaoGeneralProposeData], error)

Propose new RPL rewards percentages for node operators, the oDAO, and the pDAO at each rewards period

func (*PDaoRequester) ProposeSetting

Propose updating one of the Protocol DAO settings

func (*PDaoRequester) RecurringSpend

func (r *PDaoRequester) RecurringSpend(contractName string, recipient common.Address, amountPerPeriod *big.Int, periodLength time.Duration, startTime time.Time, numberOfPeriods uint64) (*types.ApiResponse[api.ProtocolDaoGeneralProposeData], error)

Propose a recurring spend of the Protocol DAO's treasury

func (*PDaoRequester) RecurringSpendUpdate

func (r *PDaoRequester) RecurringSpendUpdate(contractName string, recipient common.Address, amountPerPeriod *big.Int, periodLength time.Duration, numberOfPeriods uint64) (*types.ApiResponse[api.ProtocolDaoGeneralProposeData], error)

Propose updating an existing recurring spend of the Protocol DAO's treasury

func (*PDaoRequester) ReplaceMemberOfSecurityCouncil

func (r *PDaoRequester) ReplaceMemberOfSecurityCouncil(existingAddress common.Address, newID string, newAddress common.Address) (*types.ApiResponse[api.ProtocolDaoProposeReplaceMemberOfSecurityCouncilData], error)

Propose replacing someone on the security council with a new member to invite

func (*PDaoRequester) RewardsPercentages

Get the amount of minted RPL (and percentages) provided to node operators, the oDAO, and the pDAO at each rewards period

func (*PDaoRequester) SetVotingDelegate

func (r *PDaoRequester) SetVotingDelegate(delegate common.Address) (*types.ApiResponse[types.TxInfoData], error)

Set the delegate for voting on Protocol DAO proposals

func (*PDaoRequester) Settings

Get the Protocol DAO settings

func (*PDaoRequester) VoteOnProposal

func (r *PDaoRequester) VoteOnProposal(proposalID uint64, voteDirection rptypes.VoteDirection) (*types.ApiResponse[api.ProtocolDaoVoteOnProposalData], error)

Vote on a proposal

type QueueRequester

type QueueRequester struct {
	// contains filtered or unexported fields
}

func NewQueueRequester

func NewQueueRequester(context *client.RequesterContext) *QueueRequester

func (*QueueRequester) GetContext

func (r *QueueRequester) GetContext() *client.RequesterContext

func (*QueueRequester) GetName

func (r *QueueRequester) GetName() string

func (*QueueRequester) GetRoute

func (r *QueueRequester) GetRoute() string

func (*QueueRequester) Process

Process the queue

func (*QueueRequester) Status

Get queue status

type SecurityRequester

type SecurityRequester struct {
	// contains filtered or unexported fields
}

func NewSecurityRequester

func NewSecurityRequester(context *client.RequesterContext) *SecurityRequester

func (*SecurityRequester) CancelProposal

Cancel a proposal made by the node

func (*SecurityRequester) ExecuteProposals

Execute a proposal

func (*SecurityRequester) GetContext

func (r *SecurityRequester) GetContext() *client.RequesterContext

func (*SecurityRequester) GetName

func (r *SecurityRequester) GetName() string

func (*SecurityRequester) GetRoute

func (r *SecurityRequester) GetRoute() string

func (*SecurityRequester) Join

Join the security council after being invited

func (*SecurityRequester) Leave

Leave the security council after the proposal to leave has passed

func (*SecurityRequester) Members

Get info about the security council members

func (*SecurityRequester) Proposals

Get info about the security council proposals

func (*SecurityRequester) ProposeLeave

func (r *SecurityRequester) ProposeLeave() (*types.ApiResponse[types.TxInfoData], error)

Request leaving the security council

func (*SecurityRequester) ProposeSetting

func (r *SecurityRequester) ProposeSetting(contractName rocketpool.ContractName, settingName protocol.SettingName, value string) (*types.ApiResponse[api.SecurityProposeSettingData], error)

Propose a Protocol DAO (security council) setting update

func (*SecurityRequester) Status

Get info about the security council

func (*SecurityRequester) VoteOnProposal

func (r *SecurityRequester) VoteOnProposal(id uint64, support bool) (*types.ApiResponse[api.SecurityVoteOnProposalData], error)

Vote on a proposal

type ServiceRequester

type ServiceRequester struct {
	// contains filtered or unexported fields
}

func NewServiceRequester

func NewServiceRequester(context *client.RequesterContext) *ServiceRequester

func (*ServiceRequester) ClientStatus

Gets the status of the configured Execution and Beacon clients

func (*ServiceRequester) GetContext

func (r *ServiceRequester) GetContext() *client.RequesterContext

func (*ServiceRequester) GetName

func (r *ServiceRequester) GetName() string

func (*ServiceRequester) GetRoute

func (r *ServiceRequester) GetRoute() string

func (*ServiceRequester) RestartVc

Restarts the Validator client

func (*ServiceRequester) TerminateDataFolder

Deletes the data folder including the wallet file, password file, and all validator keys. Don't use this unless you have a very good reason to do it (such as switching from a Testnet to Mainnet).

func (*ServiceRequester) Version

Gets the version of the daemon

type TxRequester

type TxRequester struct {
	// contains filtered or unexported fields
}

func NewTxRequester

func NewTxRequester(context *client.RequesterContext) *TxRequester

func (*TxRequester) GetContext

func (r *TxRequester) GetContext() *client.RequesterContext

func (*TxRequester) GetName

func (r *TxRequester) GetName() string

func (*TxRequester) GetRoute

func (r *TxRequester) GetRoute() string

func (*TxRequester) SignTx

func (r *TxRequester) SignTx(txSubmission *eth.TransactionSubmission, nonce *big.Int, maxFee *big.Int, maxPriorityFee *big.Int) (*types.ApiResponse[api.TxSignTxData], error)

Use the node private key to sign a transaction without submitting it

func (*TxRequester) SignTxBatch

func (r *TxRequester) SignTxBatch(txSubmissions []*eth.TransactionSubmission, firstNonce *big.Int, maxFee *big.Int, maxPriorityFee *big.Int) (*types.ApiResponse[api.TxBatchSignTxData], error)

Use the node private key to sign a batch of transactions without submitting them

func (*TxRequester) SubmitTx

func (r *TxRequester) SubmitTx(txSubmission *eth.TransactionSubmission, nonce *big.Int, maxFee *big.Int, maxPriorityFee *big.Int) (*types.ApiResponse[api.TxData], error)

Submit a transaction

func (*TxRequester) SubmitTxBatch

func (r *TxRequester) SubmitTxBatch(txSubmissions []*eth.TransactionSubmission, firstNonce *big.Int, maxFee *big.Int, maxPriorityFee *big.Int) (*types.ApiResponse[api.BatchTxData], error)

Submit a batch of transactions

func (*TxRequester) WaitForTransaction

func (r *TxRequester) WaitForTransaction(txHash common.Hash) (*types.ApiResponse[types.SuccessData], error)

Wait for a transaction

type WalletRequester

type WalletRequester struct {
	// contains filtered or unexported fields
}

func NewWalletRequester

func NewWalletRequester(context *client.RequesterContext) *WalletRequester

func (*WalletRequester) DeletePassword

func (r *WalletRequester) DeletePassword() (*types.ApiResponse[types.SuccessData], error)

Delete the wallet keystore's password from disk

func (*WalletRequester) Export

Export wallet

func (*WalletRequester) ExportEthKey

Export the wallet in encrypted ETH key format

func (*WalletRequester) GetContext

func (r *WalletRequester) GetContext() *client.RequesterContext

func (*WalletRequester) GetName

func (r *WalletRequester) GetName() string

func (*WalletRequester) GetRoute

func (r *WalletRequester) GetRoute() string

func (*WalletRequester) Initialize

func (r *WalletRequester) Initialize(derivationPath *string, index *uint64, saveWallet bool, password string, savePassword bool) (*types.ApiResponse[api.WalletInitializeData], error)

Initialize the wallet with a new key

func (*WalletRequester) Masquerade

func (r *WalletRequester) Masquerade(address common.Address) (*types.ApiResponse[types.SuccessData], error)

Set the node address to an arbitrary address

func (*WalletRequester) Rebuild

Rebuild the validator keys associated with the wallet

func (*WalletRequester) Recover

func (r *WalletRequester) Recover(derivationPath *string, mnemonic string, skipValidatorKeyRecovery *bool, index *uint64, password string, save bool) (*types.ApiResponse[api.WalletRecoverData], error)

Recover wallet

func (*WalletRequester) RestoreAddress

func (r *WalletRequester) RestoreAddress() (*types.ApiResponse[types.SuccessData], error)

Set the node address back to the wallet address

func (*WalletRequester) SearchAndRecover

func (r *WalletRequester) SearchAndRecover(mnemonic string, address common.Address, skipValidatorKeyRecovery *bool, password string, save bool) (*types.ApiResponse[api.WalletSearchAndRecoverData], error)

Search and recover wallet

func (*WalletRequester) SendMessage

func (r *WalletRequester) SendMessage(message []byte, address common.Address) (*types.ApiResponse[types.TxInfoData], error)

Sends a zero-value message with a payload

func (*WalletRequester) SetEnsName

Set an ENS reverse record to a name

func (*WalletRequester) SetPassword

func (r *WalletRequester) SetPassword(password string, save bool) (*types.ApiResponse[types.SuccessData], error)

Sets the wallet keystore's password

func (*WalletRequester) SignMessage

func (r *WalletRequester) SignMessage(message []byte) (*types.ApiResponse[api.WalletSignMessageData], error)

Use the node private key to sign an arbitrary message

func (*WalletRequester) SignTx

func (r *WalletRequester) SignTx(message []byte) (*types.ApiResponse[api.WalletSignTxData], error)

Use the node private key to sign a transaction

func (*WalletRequester) Status

Get wallet status

func (*WalletRequester) TestRecover

func (r *WalletRequester) TestRecover(derivationPath *string, mnemonic string, skipValidatorKeyRecovery *bool, index *uint64) (*types.ApiResponse[api.WalletRecoverData], error)

Recover wallet in test-mode so none of the artifacts are saved

func (*WalletRequester) TestSearchAndRecover

func (r *WalletRequester) TestSearchAndRecover(mnemonic string, address common.Address, skipValidatorKeyRecovery *bool) (*types.ApiResponse[api.WalletSearchAndRecoverData], error)

Search for and recover the wallet in test-mode so none of the artifacts are saved

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL