httpclient

package
v0.1.7 Latest Latest
Warning

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

Go to latest
Published: Oct 6, 2025 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LoggingHTTPClient

type LoggingHTTPClient struct {
	// contains filtered or unexported fields
}

LoggingHTTPClient wraps an HTTP client to add trace logging

func NewLoggingHTTPClient

func NewLoggingHTTPClient(logger *slog.Logger) *LoggingHTTPClient

NewLoggingHTTPClient creates a new logging HTTP client

func NewLoggingHTTPClientWithClient

func NewLoggingHTTPClientWithClient(client *http.Client, logger *slog.Logger) *LoggingHTTPClient

NewLoggingHTTPClientWithClient wraps an existing HTTP client

func (*LoggingHTTPClient) Do

func (c *LoggingHTTPClient) Do(req *http.Request) (*http.Response, error)

Do implements the HTTPClient interface with logging

Jump to

Keyboard shortcuts

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