request

package
v1.5.1 Latest Latest
Warning

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

Go to latest
Published: Sep 15, 2025 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrEmptyResponse is returned when the response body is empty
	ErrEmptyResponse = fmt.Errorf("empty response body")
	// ErrHTTPError is returned when the HTTP request fails
	ErrHTTPError = fmt.Errorf("HTTP request failed")
	// ErrUnexpectedStatusCode is returned when the HTTP status code is not 200
	ErrUnexpectedStatusCode = fmt.Errorf("unexpected status code")
	// ErrMaxRetriesExceeded is returned when the maximum number of retries is exceeded
	ErrMaxRetriesExceeded = fmt.Errorf("exceeded maximum retries while waiting for BGG to process request")
	// ErrUnmarshalError is returned when the XML response cannot be unmarshalled
	ErrUnmarshalError = fmt.Errorf("failed to unmarshal XML response")
	// ErrRegenerateError is returned when the XML response cannot be regenerated
	ErrRegenerateError = fmt.Errorf("failed to regenerate XML response")
	// ErrXMLParseError is returned when the XML response cannot be parsed
	ErrXMLParseError = fmt.Errorf("failed to parse XML response")
)

Functions

func FetchAndUnmarshal

func FetchAndUnmarshal(url string, v interface{}) error

Types

This section is empty.

Jump to

Keyboard shortcuts

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