Documentation
¶
Overview ¶
Package constants provides common constants used throughout the application.
Index ¶
Constants ¶
View Source
const ( HeaderContentType = "Content-Type" HeaderAuthorization = "Authorization" HeaderAccept = "Accept" HeaderAcceptEncoding = "Accept-Encoding" HeaderCacheControl = "Cache-Control" HeaderContentLength = "Content-Length" HeaderContentEncoding = "Content-Encoding" HeaderCookie = "Cookie" HeaderSetCookie = "Set-Cookie" HeaderUserAgent = "User-Agent" HeaderHost = "Host" HeaderConnection = "Connection" HeaderLocation = "Location" )
HTTP Header names (canonical form)
View Source
const ( MIMEApplicationJSON = "application/json" MIMEApplicationXML = "application/xml" MIMEApplicationFormURLEncoded = "application/x-www-form-urlencoded" MIMEMultipartFormData = "multipart/form-data" MIMETextPlain = "text/plain" MIMETextHTML = "text/html" MIMETextXML = "text/xml" MIMEOctetStream = "application/octet-stream" )
MIME types
View Source
const ( AuthSchemeBearer = "Bearer" AuthSchemeBasic = "Basic" AuthSchemeDigest = "Digest" )
Authentication schemes
View Source
const ( MethodGET = "GET" MethodPOST = "POST" MethodPUT = "PUT" MethodDELETE = "DELETE" MethodPATCH = "PATCH" MethodHEAD = "HEAD" MethodOPTIONS = "OPTIONS" )
HTTP Methods
View Source
const ( ExtHTTP = ".http" ExtREST = ".rest" ExtJSON = ".json" ExtEnv = ".env" )
File extensions
View Source
const ( DefaultUserAgent = "restclient-cli" DefaultTimeout = 0 // No timeout )
Default values
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.