apiutil

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Feb 29, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DefaultConfig = Config{
	Timeout: 10 * time.Second,
	Debug:   false,
}

Functions

func BuildSignature

func BuildSignature(req SignatureRequest) string

func Client

func Client() *resty.Client

func ClientWithConfig

func ClientWithConfig(config Config) *resty.Client

Types

type Config

type Config struct {
	Timeout time.Duration
	Debug   bool
	BaseURL string
	Headers map[string]string
}

type SignatureRequest

type SignatureRequest struct {
	ApiKey    string
	SecretKey string
	Timestamp int64
	Method    string
	Path      string
	Body      string
}

Jump to

Keyboard shortcuts

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