Export (0) Print
Expand All
Expand Minimize

HttpRequestHeader Enumeration

Note: This enumeration is new in the .NET Framework version 2.0.

The HTTP headers that may be specified in a client request.

Namespace: System.Net
Assembly: System (in system.dll)

public enum class HttpRequestHeader
public enum HttpRequestHeader
public enum HttpRequestHeader

 Member nameDescription
AcceptThe Accept header, which specifies the MIME types that are acceptable for the response. 
AcceptCharsetThe Accept-Charset header, which specifies the character sets that are acceptable for the response. 
AcceptEncodingThe Accept-Encoding header, which specifies the content encodings that are acceptable for the response. 
AcceptLanguageThe Accept-Langauge header, which specifies that natural languages that are preferred for the response. 
AllowThe Allow header, which specifies the set of HTTP methods supported. 
AuthorizationThe Authorization header, which specifies the credentials that the client presents in order to authenticate itself to the server. 
CacheControlThe Cache-Control header, which specifies directives that must be obeyed by all cache control mechanisms along the request/response chain. 
ConnectionThe Connection header, which specifies options that are desired for a particular connection. 
ContentEncodingThe Content-Encoding header, which specifies the encodings that have been applied to the accompanying body data. 
ContentLanguageThe Content-Langauge header, which specifies the natural language(s) of the accompanying body data. 
ContentLengthThe Content-Length header, which specifies the length, in bytes, of the accompanying body data. 
ContentLocationThe Content-Location header, which specifies a URI from which the accompanying body may be obtained. 
ContentMd5The Content-MD5 header, which specifies the MD5 digest of the accompanying body data, for the purpose of providing an end-to-end message integrity check. 
ContentRangeThe Content-Range header, which specifies where in the full body the accompanying partial body data should be applied. 
ContentTypeThe Content-Type header, which specifies the MIME type of the accompanying body data. 
CookieThe Cookie header, which specifies cookie data presented to the server. 
DateThe Date header, which specifies the date and time at which the request originated. 
ExpectThe Expect header, which specifies particular server behaviors that are required by the client. 
ExpiresThe Expires header, which specifies the date and time after which the accompanying body data should be considered stale. 
FromThe From header, which specifies an Internet E-mail address for the human user who controls the requesting user agent. 
HostThe Host header, which specifies the host name and port number of the resource being requested. 
IfMatchThe If-Match header, which specifies that the requested operation should be performed only if the client's cached copy of the indicated resource is current. 
IfModifiedSinceThe If-Modified-Since header, which specifies that the requested operation should be performed only if the requested resource has been modified since the indicated data and time. 
IfNoneMatchThe If-None-Match header, which specifies that the requested operation should be performed only if none of client's cached copies of the indicated resources are current. 
IfRangeThe If-Range header, which specifies that only the specified range of the requested resource should be sent, if the client's cached copy is current. 
IfUnmodifiedSinceThe If-Unmodified-Since header, which specifies that the requested operation should be performed only if the requested resource has not been modified since the indicated date and time. 
KeepAliveThe Keep-Alive header, which specifies a parameter used into order to maintain a persistent connection. 
LastModifiedThe Last-Modified header, which specifies the date and time at which the accompanying body data was last modified. 
MaxForwardsThe Max-Forwards header, which specifies an integer indicating the remaining number of times that this request may be forwarded. 
PragmaThe Pragma header, which specifies implementation-specific directives that might apply to any agent along the request/response chain. 
ProxyAuthorizationThe Proxy-Authorization header, which specifies the credentials that the client presents in order to authenticate itself to a proxy. 
RangeThe Range header, which specifies the the sub-range(s) of the response that the client requests be returned in lieu of the entire response. 
RefererThe Referer header, which specifies the URI of the resource from which the request URI was obtained. 
TeThe TE header, which specifies the transfer encodings that are acceptable for the response. 
TrailerThe Trailer header, which specifies the header fields present in the trailer of a message encoded with chunked transfer-coding. 
TransferEncodingThe Transfer-Encoding header, which specifies what (if any) type of transformation that has been applied to the message body. 
TranslateThe Translate header, a Microsoft extension to the HTTP specification used in conjunction with WebDAV functionality. 
UpgradeThe Upgrade header, which specifies additional communications protocols that the client supports. 
UserAgentThe User-Agent header, which specifies information about the client agent. 
ViaThe Via header, which specifies intermediate protocols to be used by gateway and proxy agents. 
WarningThe Warning header, which specifies additional information about that status or transformation of a message that might not be reflected in the message. 

The appropriate contents of various headers are described in detail in the HTTP/1.1 specification, available at rfc2616.

Windows 98, Windows 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see System Requirements.

.NET Framework

Supported in: 2.0

Community Additions

ADD
Show:
© 2014 Microsoft