Versions in this module Expand all Collapse all v0 v0.9.0 Mar 1, 2024 v0.8.0 Dec 11, 2023 Changes in this version + func DecodeScaleUnmarshal(body []byte, target any) error v0.7.0 Nov 23, 2022 Changes in this version + var ErrResponseError = errors.New("response error received") + var ErrResponseVersion = errors.New("unexpected response version received") + func Decode(body []byte, target interface{}) error + func EpochLength(ctx context.Context, rpcPort string) (epochLength uint64, err error) + func GetBlock(ctx context.Context, rpcPort string, hash common.Hash) (block *types.Block, err error) + func GetBlockHash(ctx context.Context, rpcPort, num string) (hash common.Hash, err error) + func GetChainHead(ctx context.Context, rpcPort string) (header *types.Header, err error) + func GetFinalizedHead(ctx context.Context, rpcPort string) (hash common.Hash, err error) + func GetFinalizedHeadByRound(ctx context.Context, rpcPort string, round uint64) (hash common.Hash, err error) + func GetHealth(ctx context.Context, address string) (health modules.SystemHealthResponse, err error) + func GetPeers(ctx context.Context, rpcPort string) (peers []common.PeerInfo, err error) + func NewEndpoint(port string) string + func PauseBABE(ctx context.Context, rpcPort string) error + func Post(ctx context.Context, endpoint, method, params string) (data []byte, err error) + func SlotDuration(ctx context.Context, rpcPort string) (slotDuration time.Duration, err error) + type Error struct + Data map[string]interface{} + ErrorCode int + Message string + type ServerResponse struct + Error *Error + ID *json.RawMessage + Method string + Params json.RawMessage + Result json.RawMessage + Subscription *json.RawMessage + Version string