Metrics
How to scrape Prelude TE metrics in Prometheus format, the list of exposed metrics, and additional counters available through the REST API.
Prelude TE exposes a Prometheus-scrapable metrics endpoint with process info, Go runtime stats, BGP peer state, topology counts per domain, output state, and licensing status.
GET /api/health/metrics
Returns Prelude TE health and operational metrics in the Prometheus text exposition format (version 0.0.4).
Unlike /api/health, this endpoint is Bearer-protected, like
the rest of the API. Create a token under My tokens and pass
it in the Authorization header:
curl -fsSL https://te.example.com/api/health/metrics \
-H "Authorization: Bearer $PRELUDE_TE_TOKEN"
Prometheus scrape config
scrape_configs:
- job_name: prelude-te
metrics_path: /api/health/metrics
scheme: https
static_configs:
- targets: ["te.example.com"]
authorization:
type: Bearer
credentials_file: /etc/prometheus/secrets/prelude-te-token
Exposed metrics
All Prelude TE-specific metrics are prefixed with prelude_te_.
Standard Go runtime metrics use the conventional go_ prefix.
Process
| Metric | Type | Labels | Description |
|---|---|---|---|
prelude_te_up |
gauge | — | 1 if the engine is running. |
prelude_te_build_info |
gauge | version, commit |
Build metadata. Value is always 1; labels carry the info. |
prelude_te_start_time_seconds |
gauge | — | Unix timestamp of process start. |
prelude_te_process_cpu_usage_percent |
gauge | — | Process CPU usage (user+sys) sampled over a 5s window. |
Go runtime
| Metric | Type | Description |
|---|---|---|
go_memstats_alloc_bytes |
gauge | Bytes of allocated heap objects currently in use. |
go_memstats_sys_bytes |
gauge | Bytes of memory obtained from the OS. |
go_memstats_heap_inuse_bytes |
gauge | Bytes in in-use heap spans. |
go_goroutines |
gauge | Number of currently running goroutines. |
BGP
| Metric | Type | Labels | Description |
|---|---|---|---|
prelude_te_bgp_peers |
gauge | state (idle, connect, active, opensent, openconfirm, established) |
Number of configured BGP peers per FSM state. |
All six states are emitted on every scrape, including the ones at zero, so your dashboards plot a stable series.
Topology
| Metric | Type | Labels | Description |
|---|---|---|---|
prelude_te_topology_nodes |
gauge | domain |
Number of topology nodes per domain. |
prelude_te_topology_links |
gauge | domain |
Number of topology links per domain. |
prelude_te_topology_prefixes |
gauge | domain |
Number of topology prefixes per domain. |
prelude_te_topology_updates_total |
counter | domain |
Total BGP-LS updates processed per domain. |
prelude_te_topology_withdraws_total |
counter | domain |
Total BGP-LS withdraws processed per domain. |
domain is the BGP-LS Instance Identifier — see Domains.
Outputs
| Metric | Type | Labels | Description |
|---|---|---|---|
prelude_te_outputs |
gauge | state (disconnected, connecting, connected, error) |
Number of outputs per connection state. |
All four states are emitted on every scrape.
Licensing
| Metric | Type | Description |
|---|---|---|
prelude_te_license_valid |
gauge | 1 if a license (paid or community) is currently valid, 0 otherwise. |
prelude_te_trial_days_remaining |
gauge | Days remaining on the built-in trial. Negative once expired. |
Example response
# HELP prelude_te_up 1 if the topology engine is running.
# TYPE prelude_te_up gauge
prelude_te_up 1
# HELP prelude_te_build_info Build metadata for the running binary.
# TYPE prelude_te_build_info gauge
prelude_te_build_info{version="1.2.3",commit="a1b2c3d"} 1
# HELP prelude_te_bgp_peers Number of configured BGP peers by FSM state.
# TYPE prelude_te_bgp_peers gauge
prelude_te_bgp_peers{state="active"} 0
prelude_te_bgp_peers{state="connect"} 0
prelude_te_bgp_peers{state="established"} 4
prelude_te_bgp_peers{state="idle"} 0
prelude_te_bgp_peers{state="openconfirm"} 0
prelude_te_bgp_peers{state="opensent"} 0
# HELP prelude_te_topology_nodes Number of topology nodes per domain.
# TYPE prelude_te_topology_nodes gauge
prelude_te_topology_nodes{domain="100"} 218
prelude_te_topology_nodes{domain="200"} 100
Useful PromQL
# Engine reachable
up{job="prelude-te"} == 1
# At least one peer established
sum(prelude_te_bgp_peers{state="established"}) > 0
# Any output in error
sum(prelude_te_outputs{state="error"}) > 0
# Topology growth rate (entities per second) over the last 5 minutes
rate(prelude_te_topology_updates_total[5m])
# Trial about to expire
prelude_te_trial_days_remaining < 7 and prelude_te_license_valid == 0
Beyond the metrics endpoint
The endpoint exposes aggregated counters across the whole fleet. For per-entity detail you'd put on an operator dashboard rather than a Prometheus graph, the REST API has it:
- Topology stats —
GET /api/topology/statsreturns per-domain counters with alast-updatetimestamp. Cheap, and useful as a readiness signal (see Health). - Per-peer counters — each BGP peer carries
messages-received,messages-sent, andupdates-receivedcounters, reset on every session establishment. Visible on the BGP → Peers list and through/api/bgp/peers/{peerId}. - Per-output state — each output exposes its current state,
last-state-change, andlast-errorthrough/api/outputs/{outputId}.