Skip to main content

Data Destinations Grafana Cloud Integration

Prerequisites

  • Have an active Grafana Cloud account.

Pulling your Grafana Cloud API Key or Access Policy / Token

Grafana Cloud migrated from API Keys to Access Policies. It depends on your Grafana Cloud version the information that you need to share with us.

Only Grafana administrators can create or delete API Keys and Access Policies. See Grafana Cloud roles and permissions for more information.

Access Policy/Token

Image showing Grafana cloud access policy tab
  1. Log into your Grafana Cloud account to access the Cloud Portal.
  2. Select the organization that you want to add an Access Policy Token to, by selecting from the dropdown in top left.
  3. Click Access Policies from the SECURITY section on the left.
  4. Click Create Access Policy.
Image showing Grafana cloud access policy tab
  1. In Display Name and Name, enter a name for your Access Policy.
  2. In Realms, choose the organization in which you want the metrics.
  3. In Scopes, select write for Metrics, Logs and Traces. (this only gives permission to send metric, log and trace data to Grafana Cloud).
  4. In Add Scope, choose api-keys-metrics-publisher.
  5. Click Create when finished.
Image showing Grafana cloud token tab
  1. Click Add token to generate it associated with the access policy.
  2. In Token Name, enter a name for the token.
  3. In Expiration Date, select No expiry.

API Key

Image showing Grafana cloud api key tab
  1. Log into your Grafana Cloud account to access the Cloud Portal.
  2. Select the organization that you want to add an API key to, by selecting from the dropdown in top left.
  3. Click API Keys from the SECURITY section on the left.
  4. Click +Add API Key.
  5. In API Key Name, enter a name for your API key.
  6. In Role, select MetricsPublisher (is only given permission to send metric, log, and trace data to Grafana Cloud).
  7. Click Create API Key.
  8. A token is created and displayed. Copy the token and store it in a safe place, because it will not be displayed again.
  9. Share the token with an Embrace onboarding specialist.
  10. Click Close when finished.

Pulling your Instance ID and Zone

  1. Log into your Grafana Cloud account to access the Cloud Portal.
  2. Select the organization you want the instance ID and zone, by selecting from the dropdown in the top left.
  3. Click Details from the Grafana stack and copy the instance ID and zone.
  4. Share the instance ID and zone with an Embrace onboarding specialist.
Image showing Grafana Cloud fields needed

Selecting the Correct Data Source for Embrace Metrics

tip

If you are using the Embrace Metrics API, ensure that you configure Grafana to treat the Embrace Metrics API as a data source, rather than setting up your own Prometheus instance. You can reference this guide.

Embrace provides two main options for viwing metrics within Grafana: using the Embrace Metrics API (pull method) or setting up a Data Destination (push method).

For Data Distination ensure that you are selecting the correct prometheus datasource. Ex:

Image showing Grafana Cloud datasource Image showing the Prometheus data source selection

Embrace Metrics API vs. Data Destination

  • Embrace Metrics API: Alternatively, you can configure Grafana to pull metrics from Embrace using PromQL queries via the Embrace Metrics API. However, this method requires Grafana to be set up with the Embrace API as a data source and is typically only used if you have specific requirements for on-demand metrics retrieval.

  • Data Destination: Embrace can push metrics directly to your Grafana Cloud instance as a data destination. This setup leverages Grafana Cloud's managed Prometheus services, enabling seamless integration without the need for an additional Prometheus instance. This method is ideal for most users who prefer a simple, automated approach to access Embrace metrics within Grafana Cloud.