validator

package
v0.0.0-...-bb812c9 Latest Latest
Warning

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

Go to latest
Published: Dec 16, 2023 License: Apache-2.0, GPL-3.0, MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	*client.Client
}

Client provides a collection of helper methods for calling the Keymanager API endpoints.

func NewClient

func NewClient(host string, opts ...client.ClientOpt) (*Client, error)

NewClient returns a new Client that includes functions for REST calls to keymanager APIs.

func (*Client) GetFeeRecipientAddress

func (c *Client) GetFeeRecipientAddress(ctx context.Context, pubkey string) (*apimiddleware.GetFeeRecipientByPubkeyResponseJson, error)

GetFeeRecipientAddress takes a public key and calls the keymanager API to return its fee recipient.

func (*Client) GetFeeRecipientAddresses

func (c *Client) GetFeeRecipientAddresses(ctx context.Context, validators []string) ([]string, error)

GetFeeRecipientAddresses takes a list of validators in hex format and returns an equal length list of fee recipients in hex format.

func (*Client) GetLocalValidatorKeys

func (c *Client) GetLocalValidatorKeys(ctx context.Context) (*apimiddleware.ListKeystoresResponseJson, error)

GetLocalValidatorKeys calls the keymanager APIs for local validator keys

func (*Client) GetRemoteValidatorKeys

func (c *Client) GetRemoteValidatorKeys(ctx context.Context) (*apimiddleware.ListRemoteKeysResponseJson, error)

GetRemoteValidatorKeys calls the keymanager APIs for web3signer validator keys

func (*Client) GetValidatorPubKeys

func (c *Client) GetValidatorPubKeys(ctx context.Context) ([]string, error)

GetValidatorPubKeys gets the current list of web3signer or the local validator public keys in hex format.

Jump to

Keyboard shortcuts

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