finalclient

package
v0.0.0-...-99b279f Latest Latest
Warning

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

Go to latest
Published: Aug 22, 2021 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TimeoutError    = "timeout"
	UnexpectedError = "unexpected"
	ClientError     = "client"
	UnknownError    = "unknown"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type ApiResp

type ApiResp struct {
	Error string `json:"error"`
	Data  Result `json:"data"`
}

type Data

type Data struct {
	RequestId string `form:"requestId" json:"requestId" binding:"required"`
}

type FinalClient

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

func NewFinalClient

func NewFinalClient(
	serverConfig *config.ServerConfig, metricsClient *metrics.Client,
) *FinalClient

func (*FinalClient) RequestWithStrategy

func (client *FinalClient) RequestWithStrategy(data Data) (Result, error)

type RequestError

type RequestError struct {
	ErrorType string
	Err       error
}

func NewRequestError

func NewRequestError(errorType string) *RequestError

func (*RequestError) AttachError

func (r *RequestError) AttachError(e error)

func (*RequestError) Error

func (r *RequestError) Error() string

type Result

type Result struct {
	Hashed string `json:"hashed"`
}

Jump to

Keyboard shortcuts

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