client

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Jul 15, 2025 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Headers

func Headers(url *urlpkg.URL, headers map[string]string) (map[string]string, error)

Types

type Client

type Client interface {
	Get(url string, params map[string]string, headers map[string]string) (*http.Response, error)
	Post(url string, body io.Reader, headers map[string]string) (*http.Response, error)
	Put(url string, body io.Reader, headers map[string]string) (*http.Response, error)
}

func NewClient

func NewClient(opts ...Option) (Client, error)

type Option

type Option func(*httpClient)

func WithTimeOut

func WithTimeOut(t time.Duration) Option

func WithTransport

func WithTransport(t *http.Transport) Option

Jump to

Keyboard shortcuts

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