Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type HTTPFetcher ¶
type HTTPFetcher struct {
// contains filtered or unexported fields
}
HTTPFetcher implements the discovery.Fetcher interface using standard HTTP.
func NewHTTPFetcher ¶
func NewHTTPFetcher() *HTTPFetcher
NewHTTPFetcher creates a new fetcher with a default 5-second timeout.
func (*HTTPFetcher) FetchWithAuth ¶
func (f *HTTPFetcher) FetchWithAuth(ctx context.Context, url string, authHeader string) ([]byte, error)
FetchWithAuth retrieves the content from the given URL with an optional Authorization header.
func (*HTTPFetcher) SetHeader ¶
func (f *HTTPFetcher) SetHeader(key, value string)
SetHeader sets a default header for all fetch requests.
Click to show internal directories.
Click to hide internal directories.