http_constant/constant/
header_key.rs

1/// Server
2pub static SERVER: &str = "Server";
3
4/// The HTTP header field name `Accept`.
5pub static ACCEPT: &str = "Accept";
6
7/// The HTTP header field name `Accept-Encoding`, used to specify acceptable content encodings.
8pub static ACCEPT_ENCODING: &str = "Accept-Encoding";
9
10/// The HTTP header field name `Accept-Language`, used to specify preferred languages for the response.
11pub static ACCEPT_LANGUAGE: &str = "Accept-Language";
12
13/// The HTTP header field name `Authorization`, used to specify authentication credentials.
14pub static AUTHORIZATION: &str = "Authorization";
15
16/// The HTTP header field name `Cache-Control`, used to specify caching directives.
17pub static CACHE_CONTROL: &str = "Cache-Control";
18
19/// The HTTP header field name `Connection`, used to specify control options for the current connection.
20pub static CONNECTION: &str = "Connection";
21
22/// The HTTP header field name `Cookie`, used to send cookies from the server to the client.
23pub static COOKIE: &str = "Cookie";
24
25/// The HTTP header field name `Date`, used to specify the date and time at which the message was sent.
26pub static DATE: &str = "Date";
27
28/// The HTTP header field name `ETag`, used to specify a unique identifier for a resource version.
29pub static ETAG: &str = "ETag";
30
31/// The HTTP header field name `Host`, used to specify the host and port number of the server.
32pub static HOST: &str = "Host";
33
34/// The HTTP header field name `Last-Modified`, used to specify the last modification date of the resource.
35pub static LAST_MODIFIED: &str = "Last-Modified";
36
37/// The HTTP header field name `Location`, used to specify the URL to redirect a client.
38pub static LOCATION: &str = "Location";
39
40/// The HTTP header field name `Referer`, used to specify the URL of the referring resource.
41pub static REFERER: &str = "Referer";
42
43/// The HTTP header field name `Set-Cookie`, used to send cookies from the server to the client.
44pub static SET_COOKIE: &str = "Set-Cookie";
45
46/// The HTTP header field name `Transfer-Encoding`, used to specify the form of encoding used to safely transfer the entity to the user.
47pub static TRANSFER_ENCODING: &str = "Transfer-Encoding";
48
49/// The HTTP header field name `Upgrade`, used to indicate the protocol the client wants to upgrade to.
50pub static UPGRADE: &str = "Upgrade";
51
52/// Sec-WebSocket-Accept
53pub static SEC_WEB_SOCKET_ACCEPT: &str = "Sec-WebSocket-Accept";
54
55/// Sec-WebSocket-Key
56pub static SEC_WEBSOCKET_KEY: &str = "Sec-WebSocket-Key";
57
58/// The HTTP header field name `Vary`, used to specify that the response may vary based on certain request headers.
59pub static VARY: &str = "Vary";
60
61/// The HTTP header field name `X-Frame-Options`, used to specify whether a browser should be allowed to render a page in a `<frame>`.
62pub static X_FRAME_OPTIONS: &str = "X-Frame-Options";
63
64/// The HTTP header field name `X-Content-Type-Options`, used to indicate that the browser should not sniff the MIME type of a response.
65pub static X_CONTENT_TYPE_OPTIONS: &str = "X-Content-Type-Options";
66
67/// The HTTP header field name `X-Powered-By`, used to indicate the technology used by the server.
68pub static X_POWERED_BY: &str = "X-Powered-By";
69
70/// The HTTP header field name `X-Requested-With`, used to identify the type of request, typically for AJAX requests.
71pub static X_REQUESTED_WITH: &str = "X-Requested-With";
72
73/// The value for the `Content-Length` header, used to specify the size of the request body in octets (8-bit bytes).
74pub static CONTENT_LENGTH: &str = "Content-Length";
75
76/// The HTTP header field name `Content-Encoding`, used to specify the encoding transformations applied to the response body.
77pub static CONTENT_ENCODING: &str = "Content-Encoding";
78
79/// The HTTP header field name Content-Type, used to specify the media type of the resource or the data being sent in an HTTP request or response.
80pub static CONTENT_TYPE: &str = "Content-Type";
81
82/// The HTTP header field "User-Agent".
83pub static USER_AGENT: &str = "User-Agent";
84
85/// The HTTP header field "Access-Control-Allow-Origin", used to specify which origins are allowed to access the resource.
86pub static ACCESS_CONTROL_ALLOW_ORIGIN: &str = "Access-Control-Allow-Origin";
87
88/// The HTTP header field "Access-Control-Allow-Methods", used to specify the HTTP methods that are allowed when accessing the resource.
89pub static ACCESS_CONTROL_ALLOW_METHODS: &str = "Access-Control-Allow-Methods";
90
91/// The HTTP header field "Access-Control-Allow-Headers", used to specify which HTTP headers can be used during the request.
92pub static ACCESS_CONTROL_ALLOW_HEADERS: &str = "Access-Control-Allow-Headers";