OpenTelemetry payload reference
To set up the webhook that sends this payload, see Export with OpenTelemetry.
The OpenTelemetry webhook sends each result to your platform as an OpenTelemetry trace over OTLP/HTTP. A result for one Monitor produces one Monitor span and six timing spans. A result for a Workflow is described in Workflow spans. The OpenTelemetry (Conformance Events) webhook sends log records instead, described in Conformance Events.
The example below is the OTLP JSON form of the Monitor span for one result. The names and types are the ones the exporter sends. The values are illustrative, and the certificate is shortened.
{
"resourceSpans": [
{
"resource": {
"attributes": [
{ "key": "service.name", "value": { "stringValue": "APImetrics" } }
]
},
"scopeSpans": [
{
"scope": {
"name": "Example API status"
},
"spans": [
{
"traceId": "8a4439de8699e4a4a5f868d81a000640",
"spanId": "dfbc5e6391b72526",
"name": "Example API status",
"kind": 1,
"startTimeUnixNano": "1793525400000000000",
"endTimeUnixNano": "1793525400134000000",
"attributes": [
{ "key": "http.route", "value": { "stringValue": "https://api.example.com/v1/status" } },
{ "key": "http.request.method", "value": { "stringValue": "GET" } },
{ "key": "url.full", "value": { "stringValue": "https://api.example.com/v1/status" } },
{ "key": "http.response.status_code", "value": { "intValue": "200" } },
{ "key": "apimetrics_org_id", "value": { "stringValue": "EXAMPLE_ORG_ID" } },
{ "key": "apimetrics_project_id", "value": { "stringValue": "EXAMPLE_PROJECT_ID" } },
{ "key": "apimetrics_project_name", "value": { "stringValue": "Example Project" } },
{ "key": "apimetrics_call_id", "value": { "stringValue": "EXAMPLE_MONITOR_ID" } },
{ "key": "apimetrics_call_name", "value": { "stringValue": "Example API status" } },
{ "key": "apimetrics_result_id", "value": { "stringValue": "EXAMPLE_RESULT_ID" } },
{ "key": "apimetrics_agent_id", "value": { "stringValue": "apimetrics_azurenorwayeast" } },
{ "key": "apimetrics_cloud", "value": { "stringValue": "Azure" } },
{ "key": "client.address", "value": { "stringValue": "203.0.113.10" } },
{ "key": "apimetrics_city", "value": { "stringValue": "Oslo" } },
{ "key": "apimetrics_region", "value": { "stringValue": "Oslo" } },
{ "key": "apimetrics_country", "value": { "stringValue": "Norway" } },
{ "key": "apimetrics_continent", "value": { "stringValue": "Europe" } },
{ "key": "apimetrics_latitude", "value": { "doubleValue": 59.9139 } },
{ "key": "apimetrics_longitude", "value": { "doubleValue": 10.7522 } },
{ "key": "tls.protocol.name", "value": { "stringValue": "TLS" } },
{ "key": "tls.protocol.version", "value": { "stringValue": "1.3" } },
{ "key": "tls.cipher", "value": { "stringValue": "TLS_AES_128_GCM_SHA256" } },
{ "key": "tls.next_protocol", "value": { "stringValue": "h2" } },
{
"key": "tls.server.certificate_chain",
"value": {
"arrayValue": {
"values": [
{
"stringValue": "-----BEGIN CERTIFICATE-----\nMIIB...\n-----END CERTIFICATE-----"
}
]
}
}
},
{ "key": "tls.server.issuer", "value": { "stringValue": "CN=Example CA R1,O=Example CA" } },
{ "key": "tls.server.subject", "value": { "stringValue": "CN=api.example.com" } },
{ "key": "tls.server.not_before", "value": { "stringValue": "2026-09-01T00:00:00+00:00" } },
{ "key": "tls.server.not_after", "value": { "stringValue": "2026-11-30T00:00:00+00:00" } },
{ "key": "tls.server.hash.md5", "value": { "stringValue": "2F127B4B8170CFA17349669CC5A5D9B5" } },
{ "key": "tls.server.hash.sha1", "value": { "stringValue": "A5499D20CD1D03665FE38DFABAE0BEDBEB1F7025" } },
{ "key": "tls.server.hash.sha256", "value": { "stringValue": "DE802211979E5AF048501B36DB6D8FDDF2F86E33CF671B770F67094C05A1F587" } }
]
}
]
}
]
}
]
}
Your platform may display these fields differently, for example by flattening attributes into key = value pairs. The attribute names are always the ones listed below.
Resource and scope
| Field | Value |
|---|---|
resource.attributes["service.name"] | APImetrics. This is the only resource attribute. |
scope.name | The name of the Monitor. For a Workflow span, the name of the Workflow. |
Span fields
| Field | Type | Description |
|---|---|---|
name | String | The name of the Monitor for the Monitor span. For a timing span, one of the names in Timing spans. |
kind | Integer | Always 1 (internal). |
traceId | String | A unique identifier of the trace to which this span belongs. If the request the Monitor sent includes a W3C traceparent header, the Monitor span reuses that trace ID, so it lines up with the trace in the target's own telemetry. Otherwise APIContext generates one. |
spanId | String | A unique identifier representing the span. The Monitor span reuses the span ID from the traceparent header when there is one. |
parentSpanId | String | Optional. A unique identifier representing the parent span of the current span. Timing spans set it to the Monitor span. The Monitor span does not set it. |
startTimeUnixNano, endTimeUnixNano | String | The start and end of the span, in nanoseconds since the Unix epoch. For the Monitor span these are the start and end of the result. |
Monitor span attributes
Every attribute below is set on the Monitor span, and the six timing spans carry the same attributes. The names are exactly as the exporter sends them. Earlier versions of this page showed a custom. prefix on the apimetrics_ names. The exporter does not add one.
| Attribute | Type | Example | Present | Description |
|---|---|---|---|---|
http.route | String | https://api.example.com/v1/status | Always | The Monitor URL from the configuration |
http.request.method | String | GET | Always | The HTTP method |
url.full | String | https://api.example.com/v1/status | Always | The full URL called by the platform |
http.response.status_code | Integer | 200 | Always | The response HTTP code |
apimetrics_org_id | String | EXAMPLE_ORG_ID | Always | The ID of the Organization that owns the Project |
apimetrics_project_id | String | EXAMPLE_PROJECT_ID | Always | The ID of the Project that owns the Monitor |
apimetrics_project_name | String | Example Project | Always | The name of the Project |
apimetrics_call_id | String | EXAMPLE_MONITOR_ID | Always | The ID of the Monitor |
apimetrics_call_name | String | Example API status | Always | The name of the Monitor |
apimetrics_result_id | String | EXAMPLE_RESULT_ID | Always | The ID of this Result |
apimetrics_agent_id | String | apimetrics_azurenorwayeast | When the node is found | The ID of the node (test location) that made the call |
apimetrics_cloud | String | Azure | When the node has a value | The cloud from which the call was made |
client.address | String | 203.0.113.10 | When the node has a value | The source IP from which the call was made |
apimetrics_city | String | Oslo | When the node has a value | The city from which the call was made |
apimetrics_region | String | Oslo | When the node has a value | The region from which the call was made |
apimetrics_country | String | Norway | When the node has a value | The country from which the call was made |
apimetrics_continent | String | Europe | When the node has a value | The continent from which the call was made |
apimetrics_latitude | Double | 59.9139 | When the node has a value | The latitude from which the call was made |
apimetrics_longitude | Double | 10.7522 | When the node has a value | The longitude from which the call was made |
tls.protocol.name | String | TLS | HTTPS, when TLS details are available | The name of the TLS protocol through which the call was made |
tls.protocol.version | String | 1.3 | HTTPS, when TLS details are available | The version of the TLS protocol through which the call was made |
tls.cipher | String | TLS_AES_128_GCM_SHA256 | HTTPS, when TLS details are available | The cipher of the TLS protocol through which the call was made |
tls.next_protocol | String | h2 | HTTPS, when the server negotiated one | The next protocol of the TLS protocol through which the call was made |
tls.server.certificate_chain | Array of strings | One PEM certificate per entry | HTTPS, when the full chain is available | The chain of the TLS certificate of the endpoint called |
tls.server.issuer | String | CN=Example CA R1,O=Example CA | HTTPS, when the certificate is available | The issuer of the TLS certificate of the endpoint called |
tls.server.subject | String | CN=api.example.com | HTTPS, when the certificate is available | The subject of the TLS certificate of the endpoint called |
tls.server.not_before | String | 2026-09-01T00:00:00+00:00 | HTTPS, when the certificate is available | The first valid date of the TLS certificate of the endpoint called, in ISO 8601 format |
tls.server.not_after | String | 2026-11-30T00:00:00+00:00 | HTTPS, when the certificate is available | The last valid date of the TLS certificate of the endpoint called, in ISO 8601 format |
tls.server.hash.md5 | String | 2F127B4B8170CFA17349669CC5A5D9B5 | HTTPS, when the certificate is available | The MD5 hash of the TLS certificate of the endpoint called, in uppercase hexadecimal |
tls.server.hash.sha1 | String | A5499D20CD1D03665FE38DFABAE0BEDBEB1F7025 | HTTPS, when the certificate is available | The SHA1 hash of the TLS certificate of the endpoint called, in uppercase hexadecimal |
tls.server.hash.sha256 | String | DE802211979E5AF048501B36DB6D8FDDF2F86E33CF671B770F67094C05A1F587 | HTTPS, when the certificate is available | The SHA256 hash of the TLS certificate of the endpoint called, in uppercase hexadecimal |
tls.client.issuer | String | Not in the example | Only if the Monitor is configured to use mTLS | The client certificate issuer of the endpoint called |
tls.client.subject | String | Not in the example | Only if the Monitor is configured to use mTLS | The client certificate subject of the endpoint called |
tls.client.not_before | String | Not in the example | Only if the Monitor is configured to use mTLS | The first valid date of the client certificate of the endpoint called, in ISO 8601 format |
tls.client.not_after | String | Not in the example | Only if the Monitor is configured to use mTLS | The last valid date of the client certificate of the endpoint called, in ISO 8601 format |
A result with no timing data is not exported.
Timing spans
Each result is split up into the following spans for timing information. Each is a child of the Monitor span, so it has the same trace ID and sets parentSpanId to the Monitor span's spanId. Each span starts when the one before it ends, and the first starts when the result starts.
| Span | Description |
|---|---|
dns | Time taken for DNS lookup |
connect | Time taken for network connection |
tls_handshake | Time taken for network handshake |
upload | Time taken to upload the request |
processing | Time taken for the server to process the request (time to first byte) |
download | Time taken for the download to complete (time to last byte) |
For more information on the OpenTelemetry data model, see the OpenTelemetry specification.
Workflow spans
For a Workflow, nothing is exported as each Monitor finishes. When the last Monitor in the Workflow finishes, the webhook exports one Workflow span and, for each API Monitor result in the Workflow, the Monitor span and timing spans described above. The Workflow span is a separate span in the same export. Monitor spans do not name it as their parent span.
The Workflow span is named for the Workflow, starts when the Workflow result starts, and ends when it ends. It has these attributes:
| Attribute | Type | Description |
|---|---|---|
apimetrics_org_id | String | The ID of the Organization that owns the Project |
apimetrics_project_id | String | The ID of the Project that owns the Monitor |
apimetrics_project_name | String | The name of the Project |
apimetrics_workflow_id | String | The ID of the Workflow |
apimetrics_workflow_name | String | The name of the Workflow |
apimetrics_workflow_result_id | String | The ID of this Workflow result |
Conformance Events
The OpenTelemetry (Conformance Events) webhook sends each conformance check result as an OTLP log record over OTLP/HTTP, not as a span. It posts to the URL exactly as you enter it, with the HTTP headers you set. Which results are sent follows the webhook's Pass and Fail switches.
| Field | Value |
|---|---|
scope.name | conformance |
severityText | WARN for a failed check, INFO for a passed check |
severityNumber | 13 (WARN) for a failed check, 9 (INFO) for a passed check |
body | <category> conformance check <result>ed, for example data conformance check failed |
Log record attributes
The attributes are the fields of the conformance result. Like the apimetrics_ names above, they have no prefix. Every record has these attributes:
| Attribute | Type | Description |
|---|---|---|
project_id | String | The ID of the Project |
timestamp | String | The time of the result |
category | String | The check category: data, objective, specification, schema, security, coverage, threshold, or network |
result | String | pass or fail |
The other attributes depend on the category. Attributes in the last column are present only on a failed check.
| Category | Attributes on every result | Added on a failed check |
|---|---|---|
data | check_name, call_id, result_id | error, rule_id, and when set, parent_rule_id, rule_json_path, rule_value, rule_regex, rule_substring_of, rule_count, source_url, json_pointer, value |
objective | call_id, http_method, url, metric, comparator, value, period, measured | None |
specification | oas_id | rule_id, severity, and when set, count, description |
schema | oas_id, result_id, http_method, url | keyword, schema_path, instance_paths (array of strings), variance, expected, message |
security | Failed checks only: specification, result_id, http_method, url, check_category, check_id, description | Not applicable |
coverage | check_name, metric, coverage, goal, total_calls, missing_calls, total_endpoints, missing_endpoints (numbers) | missing_call_ids (array of strings), and when set, description |
threshold | call_id, http_method, url, metric, delta, period, measured | None |
network | check_name, affected_endpoints (number) | description, domain |
Attributes are strings unless the table says otherwise.