Versions in this module Expand all Collapse all v1 v1.0.3 Dec 5, 2019 Changes in this version + func NewExportHandler(l *Logger) http.Handler + func NewResetHandler(l *Logger) http.Handler + type Cache struct + type Content struct + Encoding string + MimeType string + Size int64 + Text []byte + type Cookie struct + Domain string + Expires time.Time + Expires8601 string + HTTPOnly bool + Name string + Path string + Secure bool + Value string + type Creator struct + Name string + Version string + type Entry struct + Cache *Cache + ID string + Request *Request + Response *Response + StartedDateTime time.Time + Time int64 + Timings *Timings + type HAR struct + Log *Log + type Header struct + Name string + Value string + type Log struct + Creator *Creator + Entries []*Entry + Version string + type Logger struct + func NewLogger() *Logger + func (l *Logger) Export() *HAR + func (l *Logger) ExportAndReset() *HAR + func (l *Logger) ModifyRequest(req *http.Request) error + func (l *Logger) ModifyResponse(res *http.Response) error + func (l *Logger) RecordRequest(id string, req *http.Request) error + func (l *Logger) RecordResponse(id string, res *http.Response) error + func (l *Logger) Reset() + func (l *Logger) SetOption(opts ...Option) + type Option func(l *Logger) + func BodyLogging(enabled bool) Option + func BodyLoggingForContentTypes(cts ...string) Option + func PostDataLogging(enabled bool) Option + func PostDataLoggingForContentTypes(cts ...string) Option + func SkipBodyLoggingForContentTypes(cts ...string) Option + func SkipPostDataLoggingForContentTypes(cts ...string) Option + type Param struct + ContentType string + Filename string + Name string + Value string + type PostData struct + MimeType string + Params []Param + Text string + func (p *PostData) MarshalJSON() ([]byte, error) + func (p *PostData) UnmarshalJSON(data []byte) error + type QueryString struct + Name string + Value string + type Request struct + BodySize int64 + Cookies []Cookie + HTTPVersion string + Headers []Header + HeadersSize int64 + Method string + PostData *PostData + QueryString []QueryString + URL string + func NewRequest(req *http.Request, withBody bool) (*Request, error) + type Response struct + BodySize int64 + Content *Content + Cookies []Cookie + HTTPVersion string + Headers []Header + HeadersSize int64 + RedirectURL string + Status int + StatusText string + func NewResponse(res *http.Response, withBody bool) (*Response, error) + type Timings struct + Receive int64 + Send int64 + Wait int64 Incompatible versions in this module v2.1.0+incompatible Sep 28, 2018