requests

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Apr 28, 2019 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WithAllowRedirects

func WithAllowRedirects(allowRedirects bool) fakeArgs

func WithHeaders

func WithHeaders(headers map[string]string) fakeArgs

func WithJson

func WithJson(json map[string]interface{}) fakeArgs

func WithParams

func WithParams(params map[string]string) fakeArgs

func WithTimeout

func WithTimeout(timeout time.Duration) fakeArgs

func WithVerify

func WithVerify(verify bool) fakeArgs

Types

type Resp

type Resp struct {
	StatusCode int
	Body       []byte
	// contains filtered or unexported fields
}

func Delete

func Delete(url string, arg ...fakeArgs) (*Resp, error)

func Get

func Get(url string, arg ...fakeArgs) (*Resp, error)

func Options

func Options(url string, arg ...fakeArgs) (*Resp, error)

func Patch

func Patch(url string, arg ...fakeArgs) (*Resp, error)

func Post

func Post(url string, arg ...fakeArgs) (*Resp, error)

func Put

func Put(url string, arg ...fakeArgs) (*Resp, error)

func (*Resp) Header

func (cls *Resp) Header() map[string]string

func (*Resp) Json

func (cls *Resp) Json(arg ...interface{}) (val map[string]interface{}, err error)

func (*Resp) JsonAndValueIsString

func (cls *Resp) JsonAndValueIsString() (val map[string]string, err error)

func (*Resp) List

func (cls *Resp) List(arg ...interface{}) (val []interface{}, err error)

Jump to

Keyboard shortcuts

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