Documentation ¶
Index ¶
- Constants
- type BeaconService
- func (b *BeaconService) Configure(cfg config.BeaconConfig) error
- func (b *BeaconService) ConnectedChainId() *big.Int
- func (b *BeaconService) FinalizedValidatorEffectiveBalance(blsKeys []phase0.BLSPubKey) (res map[phase0.BLSPubKey]uint64, err error)
- func (b *BeaconService) Status() (res *SyncStatusData, err error)
- func (b *BeaconService) SubscribeToHeadEvents(ctx context.Context, headEvent chan<- HeadEventData) error
- type GetSyncStatusResponse
- type GetValidatorsResponse
- type HeadEventData
- type SyncStatusData
- type Validator
- type ValidatorData
Constants ¶
View Source
const ( SpecPath = "/eth/v1/config/spec" SyncPath = "/eth/v1/node/syncing" FinalizedValidatorsPath = "/eth/v1/beacon/states/finalized/validators" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BeaconService ¶
type BeaconService struct {
// contains filtered or unexported fields
}
func NewBeaconService ¶
func NewBeaconService() *BeaconService
func (*BeaconService) Configure ¶
func (b *BeaconService) Configure(cfg config.BeaconConfig) error
func (*BeaconService) ConnectedChainId ¶
func (b *BeaconService) ConnectedChainId() *big.Int
func (*BeaconService) FinalizedValidatorEffectiveBalance ¶
func (*BeaconService) Status ¶
func (b *BeaconService) Status() (res *SyncStatusData, err error)
func (*BeaconService) SubscribeToHeadEvents ¶
func (b *BeaconService) SubscribeToHeadEvents(ctx context.Context, headEvent chan<- HeadEventData) error
type GetSyncStatusResponse ¶
type GetSyncStatusResponse struct {
Data *SyncStatusData `json:"data"`
}
type GetValidatorsResponse ¶
type GetValidatorsResponse struct {
Data []*ValidatorData `json:"data"`
}
type HeadEventData ¶
type SyncStatusData ¶
type Validator ¶
type Validator struct { Pubkey phase0.BLSPubKey `json:"pubkey"` WithdrawalCredentials string `json:"withdrawal_credentials"` EffectiveBalance uint64 `json:"effective_balance,string"` Slashed bool `json:"slashed"` ActivationEligibilityEpoch uint64 `json:"activation_eligibility_epoch,string"` ActivationEpoch uint64 `json:"activation_epoch,string"` ExitEpoch uint64 `json:"exit_epoch,string"` WithdrawableEpoch uint64 `json:"withdrawable_epoch,string"` }
Click to show internal directories.
Click to hide internal directories.