Observer
Observer Agent

Connect to Grafana Cloud

Use a Grafana Cloud Prometheus endpoint as the agent's metric source.

Grafana Cloud's hosted Prometheus is a valid source for Observer agents. The connection uses basic auth with credentials issued by Grafana for read access.

Steps

  1. In Grafana Cloud, open the stack details for the Prometheus instance you want the agent to read. Note:

    • URL: the remote-read URL (e.g. https://prometheus-prod-01-eu-west-0.grafana.net/api/prom).
    • Username: the numeric user id (e.g. 123456).
    • Password: a Grafana Cloud access policy token with metrics:read scope.
  2. Set the agent's environment:

    PROMETHEUS_SERVER_URL=https://prometheus-prod-01-eu-west-0.grafana.net/api/prom
    PROMETHEUS_BASIC_AUTH_ENABLED=true
    PROMETHEUS_USERNAME=123456
    PROMETHEUS_PASSWORD=glc_eyJ...   # access policy token
  3. Restart the agent. Heartbeats and probe queries now hit Grafana Cloud.

Verification

Define a Prometheus metric in the console (any working PromQL query against the data Grafana Cloud holds). Within one push interval the metric reports a value. Failures resolve to no_data with a reason:

  • Unauthorized when the access policy token is missing or lacking the required scope.
  • BadQuery when the PromQL string is invalid against the data.
  • PromUpstream for Grafana-side 5xx responses.
Was this page helpful?