Documentation
¶
Overview ¶
Package http contains utilities for making HTTP requests.
Index ¶
Constants ¶
View Source
const ( HeaderAccept = "Accept" HeaderUserAgent = "User-Agent" HeaderAuthorization = "Authorization" HeaderContentEncoding = "Content-Encoding" HeaderContentType = "Content-Type" HeaderAcceptEncoding = "Accept-Encoding" )
View Source
const ( ContentTypeGzip = "gzip" ContentTypeProtobuf = "application/x-protobuf" ContentTypeJSON = "application/json" ContentTypeValueBin = "application/octet-stream" ContentTypeValueTxt = "text/plain" ContentTypeValueYAML = "text/yaml" ContentTypeValueCSV = "text/csv" )
View Source
const ( QueryParamClusterName = "cluster_name" QueryParamAccountID = "cloud_account_id" QueryParamRegion = "region" )
Variables ¶
View Source
var ( ErrStatusBadRequest = errors.New("badrequest error") ErrStatusPaymentRequired = errors.New("paymentrequired error") ErrStatusForbidden = errors.New("forbidden error") ErrStatusNotFound = errors.New("not found error") ErrStatusMethodNotAllowed = errors.New("method not allowed error") ErrStatusNotAcceptable = errors.New("not acceptable error") ErrStatusProxyAuthRequired = errors.New("proxy authrequired error") ErrStatusRequestTimeout = errors.New("request timeout error") ErrStatusConflict = errors.New("conflict error") ErrStatusGone = errors.New("gone error") ErrStatusLengthRequired = errors.New("length required error") ErrStatusPreconditionFailed = errors.New("precondition failed error") ErrStatusRequestEntityTooLarge = errors.New("requestentity too large error") ErrStatusRequestURITooLong = errors.New("request uri too long error") ErrStatusUnsupportedMediaType = errors.New("unsupported media type error") ErrStatusRequestedRangeNotSatisfiable = errors.New("requested range not satisfiable error") ErrStatusExpectationFailed = errors.New("expectation failed error") ErrStatusTeapot = errors.New("teapot error") ErrStatusMisdirectedRequest = errors.New("misdirected request error") ErrStatusUnprocessableEntity = errors.New("unprocessable entity error") ErrStatusLocked = errors.New("locked error") ErrStatusFailedDependency = errors.New("failed dependency error") ErrStatusTooEarly = errors.New("too early error") ErrStatusUpgradeRequired = errors.New("upgrade required error") ErrStatusPreconditionRequired = errors.New("precondition required error") ErrStatusTooManyRequests = errors.New("too many requests error") ErrStatusRequestHeaderFieldsTooLarge = errors.New("request header fields too large error") ErrStatusInternalServerError = errors.New("internal server error") ErrStatusNotImplemented = errors.New("not implemented error") ErrStatusBadGateway = errors.New("bad gateway error") ErrStatusGatewayTimeout = errors.New("gateway timeout error") ErrStatusHTTPVersionNotSupported = errors.New("http version not supported error") ErrStatusVariantAlsoNegotiates = errors.New("variant also negotiates error") ErrStatusInsufficientStorage = errors.New("insufficient storage error") ErrStatusLoopDetected = errors.New("loop detected error") ErrStatusNotExtended = errors.New("not extended error") ErrStatusNetworkAuthenticationRequired = errors.New("network authentication required error") )
Functions ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.