relay

package
v0.0.192 Latest Latest
Warning

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

Go to latest
Published: Sep 2, 2024 License: GPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	GetBidsEndpoint = "get_bids"
)

Functions

This section is empty.

Types

type Client

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

func NewClient

func NewClient(namespace string, config Config, networkName string) (*Client, error)

NewClient creates a new relay client

func (*Client) GetBids

func (c *Client) GetBids(ctx context.Context, params url.Values) ([]*mevrelay.BidTrace, error)

func (*Client) Name

func (c *Client) Name() string

func (*Client) URL

func (c *Client) URL() string

type Config

type Config struct {
	URL  string `yaml:"url"`
	Name string `yaml:"name"`
}

func (*Config) Validate

func (c *Config) Validate() error

type Metrics

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

func GetMetrics

func GetMetrics(namespace string) *Metrics

func (*Metrics) IncAPIFailures

func (m *Metrics) IncAPIFailures(relay, endpoint, network string)

func (*Metrics) IncAPIRequests

func (m *Metrics) IncAPIRequests(relay, endpoint, network string)

func (*Metrics) IncBidsReceived

func (m *Metrics) IncBidsReceived(relay, network string, count int)

Jump to

Keyboard shortcuts

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