Versions in this module Expand all Collapse all v2 v2.0.2 May 19, 2022 Changes in this version + func Struct2Map(obj interface{}, tagName string) map[string]interface + func StructPtr2Map(obj interface{}, tagName string) map[string]interface + type Request struct + Cookies map[string]string + Headers map[string]string + Params url.Values + func New(options ...bool) *Request + func (req *Request) BaseReq(Method, urlStr string, options ...interface{}) (resp *Response, err error) + func (req *Request) Cookie() + func (req *Request) Delete(urlStr string, options ...interface{}) (resp *Response, err error) + func (req *Request) Do() (*Response, error) + func (req *Request) EnableCookie(enable bool) + func (req *Request) Get(urlStr string, options ...interface{}) (resp *Response, err error) + func (req *Request) Header() + func (req *Request) Patch(urlStr string, options ...interface{}) (resp *Response, err error) + func (req *Request) Post(urlStr string, options ...interface{}) (resp *Response, err error) + func (req *Request) Put(urlStr string, options ...interface{}) (resp *Response, err error) + func (req *Request) SetBasicAuth(username, password string) + func (req *Request) SetTimeout(n time.Duration) + type Response struct + func Delete(urlStr string, options ...interface{}) (resp *Response, err error) + func Get(urlStr string, options ...interface{}) (resp *Response, err error) + func Patch(urlStr string, options ...interface{}) (resp *Response, err error) + func Post(urlStr string, options ...interface{}) (resp *Response, err error) + func Put(urlStr string, options ...interface{}) (resp *Response, err error) + func (res *Response) Body() (body io.ReadCloser) + func (res *Response) Content() (content []byte) + func (res *Response) Cookie() []*http.Cookie + func (res *Response) Header() map[string][]string + func (res *Response) Json() Value + func (res *Response) RawJson(v interface{}) error + func (res *Response) SetRes(rawRes *http.Response) + func (res *Response) Status() int + func (res *Response) Text() (text string) + type Value struct + Data interface{} + Exists bool + func NewJson(data []byte) (Value, error) + func (v Value) Bool() bool + func (v Value) Float64() float64 + func (v Value) Get(path ...interface{}) Value + func (v Value) Int64() int64 + func (v Value) Map() map[string]interface{} + func (v Value) Size() int + func (v Value) String() string + func (v Value) StringArray(path ...interface{}) []string + func (v Value) Time(layout string, options ...string) time.Time