headers

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Feb 21, 2024 License: AGPL-3.0 Imports: 0 Imported by: 0

Documentation

Overview

Package headers defines common HTTP headers.

Index

Constants

View Source
const (
	Accept           = "Accept"            // RFC 2616
	Authorization    = "Authorization"     // RFC 2616
	ETag             = "ETag"              // RFC 2616
	ContentType      = "Content-Type"      // RFC 2616
	ContentLength    = "Content-Length"    // RFC 2616
	ContentEncoding  = "Content-Encoding"  // RFC 2616 and 7231
	TransferEncoding = "Transfer-Encoding" // RFC 2616
)

Commonly used HTTP headers.

View Source
const (
	Forwarded     = "Forwarded"       // RFC 7239
	XForwardedFor = "X-Forwarded-For" // Non-standard
	XFrameOptions = "X-Frame-Options" // Non-standard
)

Commonly used HTTP headers for forwarding originating IP addresses of clients connecting through an reverse proxy or load balancer.

View Source
const (
	ContentTypeAny       = "*/*"
	ContentTypeAppAny    = "application/*" // any application type, like json, octet-stream, ...
	ContentTypeBinary    = "application/octet-stream"
	ContentTypeJSON      = "application/json"
	ContentTypeJSONLines = "application/x-ndjson"
	ContentTypeText      = "text/plain"
	ContentTypeHTML      = "text/html"
)

Commonly used HTTP content type values.

View Source
const (
	ContentEncodingGZIP = "gzip"
)

Commonly used HTTP content encoding values.

Variables

This section is empty.

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

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