Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Response ¶
type Response struct { UniqueIdentifier string // Unique ID for the request, generated internally URL string // URL the request was made to Method string // HTTP method used (e.g., GET, POST) RequestPayload any // Payload sent with the request Options *options.Option // Configuration options for the request RequestTime int64 // Timestamp of when the request was initiated ResponseTime int64 // Timestamp of when the response was received ProcessedTime int64 // Duration taken to process the request Status string // HTTP status message (e.g., "200 OK") StatusCode int // HTTP status code (e.g., 200, 404) Proto string // Protocol used (e.g., HTTP/1.1) Header http.Header // Headers included in the response ContentLength int64 // Length of the response content TransferEncoding []string // Transfer encoding details from the response CompressionType options.CompressionType // Type of compression applied to the response Uncompressed bool // Indicates if the response was uncompressed Cookies []*http.Cookie // Cookies received with the response AccessTime time.Duration // Time taken to complete the request Body options.WriteCloserBuffer // The response body as a buffer Error error // Any error encountered during the request TLS *tls.ConnectionState // Details about the TLS connection Redirected bool // Indicates if the request was redirected Location string // New location if the request was redirected }
Response represents the HTTP response along with additional metadata
func (*Response) Len ¶
Len returns the length of the response body If there is no body, it returns -1 to indicate there is an issue
func (*Response) PopulateResponse ¶
PopulateResponse populates the Response struct with data from an http.Response
Click to show internal directories.
Click to hide internal directories.