client

package
v0.0.0-...-b39ed8c Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2021 License: AGPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CupClient

type CupClient struct {
	Service
}

func New

func New(cfg *TransportConfig) *CupClient

New creates a new high load cup2021 HTTP client, using a customizable transport config.

type Service

type Service interface {
	Cash(id string, target *[]uint) error

	Dig(params *models.Dig, target *[]string) error

	ExploreArea(params *models.Area, target *models.Report) error

	GetBalance(target *models.Balance) error

	HealthCheck() error

	IssueLicense(coins []uint64, target *models.License) error

	ListLicenses(target *[]models.License) error
}

Service is the interface for client methods

type TransportConfig

type TransportConfig struct {
	BaseUrl string
}

TransportConfig contains the transport related info, found in the meta section of the spec file.

func (*TransportConfig) WithHost

func (cfg *TransportConfig) WithHost(host string) *TransportConfig

WithHost overrides the default host, provided by the meta section of the spec file.

Jump to

Keyboard shortcuts

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