http

package
v0.0.0-...-d1533f9 Latest Latest
Warning

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

Go to latest
Published: Jul 28, 2025 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type SecureClient

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

SecureClient provides a secure HTTP client with proper timeouts

func DefaultClient

func DefaultClient() *SecureClient

DefaultClient returns a default secure HTTP client with 30 second timeout

func NewSecureClient

func NewSecureClient(timeout time.Duration) *SecureClient

NewSecureClient creates a new secure HTTP client

func (*SecureClient) Close

func (c *SecureClient) Close() error

Close closes the client and cleans up resources

func (*SecureClient) Get

func (c *SecureClient) Get(ctx context.Context, url string) (*http.Response, error)

Get performs a GET request with context

func (*SecureClient) Post

func (c *SecureClient) Post(ctx context.Context, url, contentType string, body interface{}) (*http.Response, error)

Post performs a POST request with context

Jump to

Keyboard shortcuts

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