Test a probe
A key with write:metrics or write:config may call it. Validates source_config with the same rules as a metric write, then runs the probe once: on the given agent (on its network, with its env-var secrets), or, with no agent_id, from Observer’s cloud for a public HTTP check. Waits up to wait_seconds (default 20) for the agent; if it has not answered by then the response is 202 with a job_id whose result GET /metrics/test/ returns. Nothing is stored: no metric, no sample, no status change. The result carries only the value, its unit, the status the given thresholds would produce, a reason code and the duration; never response bodies, rows or headers.
Value units by source_type:
- prometheus: Value: scalar result of the PromQL query, as returned by the query; Observer does not rescale it.
- http: Value: ms: response time in milliseconds. With json_path set: the number extracted from the JSON response at json_path (booleans read as 1/0); unit as in the response.
- tcp: Value: ms: TCP connect time in milliseconds.
- dns: Value: ms: DNS resolve time in milliseconds.
- icmp: Value by interpretation: interpretation=latency (default) → ms: average round-trip time in milliseconds; interpretation=packet_loss → %: percentage of pings lost, 0 to 100; interpretation=reachability → 1 when any ping returned, 0 when none did.
- tls_cert: Value: days: days until the certificate expires.
- grpc: Value by interpretation: interpretation=health_state (default) → 1 when the health check reports SERVING, 0 when NOT_SERVING; interpretation=latency → ms: health check round-trip time in milliseconds.
- websocket: Value by interpretation: interpretation=handshake_latency (default) → ms: handshake time in milliseconds; interpretation=round_trip_latency → ms: message round-trip time in milliseconds; interpretation=connection_success → 1 when the socket opened, 0 when it did not.
- mtls_http: Value: ms: response time in milliseconds (deprecated alias of http). With json_path set: the number extracted from the JSON response at json_path (booleans read as 1/0); unit as in the response.
- database: Value: scalar returned by the read-only query (one row, one column), as returned by the query; Observer does not rescale it.
- cloudwatch: Value: latest CloudWatch datapoint for the chosen statistic, in the metric’s CloudWatch unit.
- loki: Value: scalar result of the LogQL aggregation, as returned by the query; Observer does not rescale it.
- elasticsearch: Value: value of the named aggregation, as returned by the query; Observer does not rescale it.
- host: Value by metric: metric=cpu (default) → %: CPU utilisation percentage, 0 to 100; metric=memory → %: used memory percentage, 0 to 100; metric=filesystem → %: used disk space percentage of the mountpoint, 0 to 100; metric=network → B/s: network throughput in bytes per second (received + sent); metric=load → 1-minute load average divided by the CPU count.
- datadog: Value: scalar result of the Datadog metrics query over the window, as returned by the query; Observer does not rescale it.
- gcp_monitoring: Value: scalar result of the PromQL query against Cloud Monitoring, as returned by the query; Observer does not rescale it.
- azure_monitor: Value: latest Azure Monitor data point for the chosen aggregation, in the metric’s Azure unit.
Authorizations
Body
Response
the probe ran

