Skip to content

Get Prometheus metrics

GET
/api/v1/metrics
curl --request GET \
--url https://app.hostrepute.com/api/v1/metrics \
--header 'Authorization: Bearer <token>'

Get your team’s current totals as Prometheus gauges, labelled with your team’s ID. The response is text/plain; version=0.0.4 in the Prometheus exposition format, not JSON. Scrape it with an Authorization: Bearer header. Read https://docs.hostrepute.com/developers/prometheus-metrics/ for what each metric means.

Business and Enterprise plans only. Needs the metrics:read ability.

Media typetext/plain
string

Example

# HELP hostrepute_hosts_total Total non-temporary hosts.
# TYPE hostrepute_hosts_total gauge
hostrepute_hosts_total{team="01JZ8Q6W3T2M7XKD4R5N9BVC1E"} 8
# HELP hostrepute_hosts_blocklisted Currently blocklisted non-temporary hosts.
# TYPE hostrepute_hosts_blocklisted gauge
hostrepute_hosts_blocklisted{team="01JZ8Q6W3T2M7XKD4R5N9BVC1E"} 2
# HELP hostrepute_certificate_monitors_total Certificate monitors.
# TYPE hostrepute_certificate_monitors_total gauge
hostrepute_certificate_monitors_total{team="01JZ8Q6W3T2M7XKD4R5N9BVC1E"} 3
# HELP hostrepute_certificate_monitors_unhealthy Certificate monitors currently not healthy.
# TYPE hostrepute_certificate_monitors_unhealthy gauge
hostrepute_certificate_monitors_unhealthy{team="01JZ8Q6W3T2M7XKD4R5N9BVC1E"} 2
# HELP hostrepute_credits_balance Current credit balance.
# TYPE hostrepute_credits_balance gauge
hostrepute_credits_balance{team="01JZ8Q6W3T2M7XKD4R5N9BVC1E"} 4250
# HELP hostrepute_alert_destinations_total Configured alert destinations.
# TYPE hostrepute_alert_destinations_total gauge
hostrepute_alert_destinations_total{team="01JZ8Q6W3T2M7XKD4R5N9BVC1E"} 3
# HELP hostrepute_snds_integrations_total SNDS integrations.
# TYPE hostrepute_snds_integrations_total gauge
hostrepute_snds_integrations_total{team="01JZ8Q6W3T2M7XKD4R5N9BVC1E"} 1
# HELP hostrepute_gmail_postmaster_integrations_total Google Postmaster integrations.
# TYPE hostrepute_gmail_postmaster_integrations_total gauge
hostrepute_gmail_postmaster_integrations_total{team="01JZ8Q6W3T2M7XKD4R5N9BVC1E"} 1
# HELP hostrepute_deliverability_checks_total Deliverability checks executed.
# TYPE hostrepute_deliverability_checks_total gauge
hostrepute_deliverability_checks_total{team="01JZ8Q6W3T2M7XKD4R5N9BVC1E"} 42
# HELP hostrepute_deliverability_failures_total Deliverability checks with failed overall status.
# TYPE hostrepute_deliverability_failures_total gauge
hostrepute_deliverability_failures_total{team="01JZ8Q6W3T2M7XKD4R5N9BVC1E"} 5

Your plan doesn’t include metrics, or the token lacks metrics:read

Media typeapplication/json
object
message
string

Example

{
"message": "This action is unauthorized."
}