Skip to content

List a component's effective metrics

GET
/components/{name}/metrics
curl --request GET \
--url https://example.com/api/v1/components/example/metrics

Every metric the component’s product declares, resolved to the series’ latest observed or calculated sample or the contract default until one arrives (is_sampled marks a live series), plus any metric sampled directly on the component (from_contract false). Gated by component:read; an out-of-scope component is a non-disclosing 404.

name
required

The component’s name, or a dotted address (e.g. boi.17c.415a.$comp.display-1)

string

The component’s name, or a dotted address (e.g. boi.17c.415a.$comp.display-1)

OK

Media type application/json
object
$schema

A URL to the JSON Schema for this object.

string format: uri
component
required
string
metrics
required
Array<object> | null
object
data_type
required

The numeric value type, from the metric catalog

string
default_value

The contract default; omitted when the contract sets none

from_contract
required

True when the owner’s classifier declares the metric; false for a series landing directly on the owner

boolean
is_sampled
required

True when the series holds an observed or calculated sample

boolean
label

The metric’s human label; omitted when unset

string
metric_type_id
required

The catalog metric’s uuid, the stable form of metric_type_name

string
metric_type_name
required

The catalog metric name

string
required
required

Whether the contract requires the metric; always false off-contract

boolean
sample_value

The series’ latest sample; omitted when none has arrived

value

The effective value: the latest sample, or the contract default until one arrives

Example
{
"$schema": "/api/v1/schemas/ComponentMetricsOutputBody.json"
}

Error

Media type application/problem+json
object
$schema

A URL to the JSON Schema for this object.

string format: uri
detail

A human-readable explanation specific to this occurrence of the problem.

string
errors

Optional list of individual error details

Array<object> | null
object
location

Where the error occurred, e.g. ‘body.items[3].tags’ or ‘path.thing-id’

string
message

Error message text

string
value

The value at the given location

instance

A URI reference that identifies the specific occurrence of the problem.

string format: uri
status

HTTP status code

integer format: int64
title

A short, human-readable summary of the problem type. This value should not change between occurrences of the error.

string
type

A URI reference to human-readable documentation for the error.

string format: uri
default: about:blank
Example
{
"$schema": "/api/v1/schemas/ErrorModel.json",
"detail": "Property foo is required but is missing.",
"instance": "https://example.com/error-log/abc123",
"status": 400,
"title": "Bad Request",
"type": "about:blank"
}