client

package
v0.0.0-...-c2f36be Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2024 License: BSD-3-Clause Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const UserAgent = "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/122.0.0.0 Safari/537.36"

Variables

This section is empty.

Functions

func Do

func Do(ctx context.Context, args *Args) (io.Reader, error)

Do executes the HTTP request with retry and redirection handling.

func SetProxy

func SetProxy(client *http.Client)

Types

type Args

type Args struct {
	Proxy    bool
	Method   string
	Endpoint *url.URL
	Headers  map[string]string
	Body     io.Reader
	// contains filtered or unexported fields
}

func (*Args) Cookies

func (x *Args) Cookies() []*http.Cookie

return the cookies of the response after the Args get passed to the 'Do' function.

Jump to

Keyboard shortcuts

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