You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
| Attribute | Type | Description | Examples |[Requirement Level](https://opentelemetry.io/docs/specs/semconv/general/attribute-requirement-level/)|
5
5
|---|---|---|---|---|
6
-
|`custom_http.request.header.<key>`| string[]| HTTP request headers, `<key>` being the normalized HTTP Header name (lowercase, with - characters replaced by _), the value being the header values. |``http.request.header.content_type=["application/json"]``| Recommended |
|`general.some_general_attribute.<key>`| string | This is a general attribute. |``some_general_attribute.some_key="abc"``| Recommended |
9
-
|`referenced_http.request.referenced.header.<key>`| string[]| This is a referenced attribute. |``http.request.header.content_type=["application/json"]``| Recommended |
6
+
|`custom_http.request.header.<key>`| string[]| HTTP request headers, `<key>` being the normalized HTTP Header name (lowercase, with - characters replaced by _), the value being the header values. |``http.request.header.content_type=["application/json"]``|`Recommended`|
|`general.some_general_attribute.<key>`| string | This is a general attribute. |``some_general_attribute.some_key="abc"``|`Recommended`|
9
+
|`referenced_http.request.referenced.header.<key>`| string[]| This is a referenced attribute. |``http.request.header.content_type=["application/json"]``|`Recommended`|
| Attribute | Type | Description | Examples |[Requirement Level](https://opentelemetry.io/docs/specs/semconv/general/attribute-requirement-level/)|
6
6
|---|---|---|---|---|
7
-
|`http.flavor`| string |**Deprecated. Use attribute `flavor_new` instead.**<br>Kind of HTTP protocol used [1]|`1.0`| Recommended |
8
-
|`http.host`| string | The value of the [HTTP host header](https://tools.ietf.org/html/rfc7230#section-5.4). When the header is empty or not present, this attribute should be the same. |`www.example.org`| Recommended |
|`http.scheme`| string | The URI scheme identifying the used protocol. |`http`; `https`| Recommended |
11
-
|`http.status_code`| int |[HTTP response status code](https://tools.ietf.org/html/rfc7231#section-6). |`200`| Conditionally Required: if and only if one was received/sent |
|`http.target`| string | The full request target as passed in a HTTP request line or equivalent. |`/path/12314/?q=ddds#123`| Recommended |
14
-
|`http.url`| string | Full HTTP request URL in the form `scheme://host[:port]/path?query[#fragment]`. Usually the fragment is not transmitted over HTTP, but if it is known, it should be included nevertheless. |`https://www.foo.bar/search?q=OpenTelemetry#SemConv`| Recommended |
15
-
|`http.user_agent`| string | Value of the [HTTP User-Agent](https://tools.ietf.org/html/rfc7231#section-5.5.3) header sent by the client. |`CERN-LineMode/2.15 libwww/2.17b3`| Recommended |
7
+
|`http.flavor`| string |**Deprecated. Use attribute `flavor_new` instead.**<br>Kind of HTTP protocol used [1]|`1.0`|`Recommended`|
8
+
|`http.host`| string | The value of the [HTTP host header](https://tools.ietf.org/html/rfc7230#section-5.4). When the header is empty or not present, this attribute should be the same. |`www.example.org`|`Recommended`|
|`http.scheme`| string | The URI scheme identifying the used protocol. |`http`; `https`|`Recommended`|
11
+
|`http.status_code`| int |[HTTP response status code](https://tools.ietf.org/html/rfc7231#section-6). |`200`|`Conditionally Required` if and only if one was received/sent |
12
+
|`http.status_text`| string |**Deprecated: Use attribute `status_description` instead.**<br>[HTTP reason phrase](https://tools.ietf.org/html/rfc7230#section-3.1.2). |`OK`|`Recommended`|
13
+
|`http.target`| string | The full request target as passed in a HTTP request line or equivalent. |`/path/12314/?q=ddds#123`|`Recommended`|
14
+
|`http.url`| string | Full HTTP request URL in the form `scheme://host[:port]/path?query[#fragment]`. Usually the fragment is not transmitted over HTTP, but if it is known, it should be included nevertheless. |`https://www.foo.bar/search?q=OpenTelemetry#SemConv`|`Recommended`|
15
+
|`http.user_agent`| string | Value of the [HTTP User-Agent](https://tools.ietf.org/html/rfc7231#section-5.5.3) header sent by the client. |`CERN-LineMode/2.15 libwww/2.17b3`|`Recommended`|
16
16
17
17
**[1]:** If `net.transport` is not specified, it can be assumed to be `IP.TCP` except if `http.flavor` is `QUIC`, in which case `IP.UDP` is assumed.
18
18
19
-
`http.flavor` has the following list of well-known values. If one of them applies, then the respective value MUST be used, otherwise a custom value MAY be used.
19
+
`http.flavor` has the following list of well-known values. If one of them applies, then the respective value MUST be used; otherwise, a custom value MAY be used.
|`http.method`| HTTP request method. E.g. `"GET"`. | Required |
8
+
|`http.method`| HTTP request method. E.g. `"GET"`. |`Required`|
9
9
|`http.url`| Full HTTP request URL in the form `scheme://host[:port]/path?query[#fragment]`. Usually the fragment is not transmitted over HTTP, but if it is known, it should be included nevertheless. | Defined later. |
10
10
|`http.target`| The full request target as passed in a [HTTP request line][] or equivalent, e.g. `"/path/12314/?q=ddds#123"`. | Defined later. |
11
11
|`http.host`| The value of the [HTTP host header][]. When the header is empty or not present, this attribute should be the same. | Defined later. |
12
12
|`http.scheme`| The URI scheme identifying the used protocol: `"http"` or `"https"`| Defined later. |
13
-
|`http.status_code`|[HTTP response status code][]. E.g. `200` (integer) | Conditionally Required: if and only if one was received/sent. |
14
-
|`http.status_text`|[HTTP reason phrase][]. E.g. `"OK"`| Recommended |
13
+
|`http.status_code`|[HTTP response status code][]. E.g. `200` (integer) |`Conditionally Required` if and only if one was received/sent. |
14
+
|`http.status_text`|[HTTP reason phrase][]. E.g. `"OK"`|`Recommended`|
15
15
|`http.flavor`| Kind of HTTP protocol used: `"1.0"`, `"1.1"`, `"2"`, `"SPDY"` or `"QUIC"`. | No |
16
-
|`http.user_agent`| Value of the HTTP [User-Agent][] header sent by the client. | Recommended |
16
+
|`http.user_agent`| Value of the HTTP [User-Agent][] header sent by the client. |`Recommended`|
|`http.method`| HTTP request method. E.g. `"GET"`. | Required |
75
+
|`http.method`| HTTP request method. E.g. `"GET"`. |`Required`|
76
76
|`http.url`| Full HTTP request URL in the form `scheme://host[:port]/path?query[#fragment]`. Usually the fragment is not transmitted over HTTP, but if it is known, it should be included nevertheless. | Defined later. |
77
77
|`http.target`| The full request target as passed in a [HTTP request line][] or equivalent, e.g. `"/path/12314/?q=ddds#123"`. | Defined later. |
78
78
|`http.host`| The value of the [HTTP host header][]. When the header is empty or not present, this attribute should be the same. | Defined later. |
79
79
|`http.scheme`| The URI scheme identifying the used protocol: `"http"` or `"https"`| Defined later. |
80
-
|`http.status_code`|[HTTP response status code][]. E.g. `200` (integer) | Conditionally Required: if and only if one was received/sent. |
81
-
|`http.status_text`|[HTTP reason phrase][]. E.g. `"OK"`| Recommended |
80
+
|`http.status_code`|[HTTP response status code][]. E.g. `200` (integer) |`Conditionally Required` if and only if one was received/sent. |
81
+
|`http.status_text`|[HTTP reason phrase][]. E.g. `"OK"`|`Recommended`|
82
82
|`http.flavor`| Kind of HTTP protocol used: `"1.0"`, `"1.1"`, `"2"`, `"SPDY"` or `"QUIC"`. | Opt-In |
83
-
|`http.user_agent`| Value of the HTTP [User-Agent][] header sent by the client. | Recommended |
83
+
|`http.user_agent`| Value of the HTTP [User-Agent][] header sent by the client. |`Recommended`|
84
84
85
85
It is recommended to also use the general [network attributes][], especially `net.peer.ip`. If `net.transport` is not specified, it can be assumed to be `IP.TCP` except if `http.flavor` is `QUIC`, in which case `IP.UDP` is assumed.
86
86
@@ -183,11 +183,11 @@ If the route does not include the application root, it SHOULD be prepended to th
183
183
184
184
If the route cannot be determined, the `name` attribute MUST be set as defined in the general semantic conventions for HTTP.
185
185
186
-
| Attribute name | Notes and examples | Required? |
186
+
| Attribute name | Notes and examples |`Required`? |
|`http.server_name`| The primary server name of the matched virtual host. This should be obtained via configuration. If no such configuration can be obtained, this attribute MUST NOT be set ( `net.host.name` should be used instead). |[1]|
189
-
|`http.route`| The matched route (path template). (TODO: Define whether to prepend application root) E.g. `"/users/:userID?"`. | Recommended |
190
-
|`http.client_ip`| The IP address of the original client behind all proxies, if known (e.g. from [X-Forwarded-For][]). Note that this is not necessarily the same as `net.peer.ip`, which would identify the network-level peer, which may be a proxy. | Recommended |
189
+
|`http.route`| The matched route (path template). (TODO: Define whether to prepend application root) E.g. `"/users/:userID?"`. |`Recommended`|
190
+
|`http.client_ip`| The IP address of the original client behind all proxies, if known (e.g. from [X-Forwarded-For][]). Note that this is not necessarily the same as `net.peer.ip`, which would identify the network-level peer, which may be a proxy. |`Recommended`|
0 commit comments