How to Send Custom Telemetry to DigitalOcean Insightsprivate

Last verified 23 Nov 2026

DigitalOcean Insights provides metrics, logs, traces, dashboards, and alerts to help you monitor, analyze, and troubleshoot supported DigitalOcean resources.

Warning

DigitalOcean Insights is not a HIPAA-eligible service and is strictly excluded from DigitalOcean’s Business Associate Agreement (BAA). Customers are contractually prohibited from transmitting, storing, or processing Protected Health Information (PHI) within Insights via logs, traces, custom metrics, or log forwarding, even if originating from resources under an active BAA. For teams covered by a BAA, Insights blocks log and trace ingestion but does not block metrics, which remain permissible only to the extent they contain zero PHI.

For more information, see Insights Data Protection.

Note

Platform-level operational metrics do not contain personal data. Logs and traces may contain personally identifiable information (PII), credentials, or other sensitive data emitted by your applications.

Operational security follows DigitalOcean’s Shared Responsibility Model. DigitalOcean secures the underlying infrastructure; customers maintain exclusive responsibility for telemetry contents emitted by their workloads and access control configurations.

Ingested logs and traces do not undergo automatic scrubbing, masking, or redaction. Customers are solely responsible for removing or masking Personally Identifiable Information (PII), credentials, or sensitive data on the client side prior to ingestion.

For more information, see Insights Data Protection.

DigitalOcean Insights custom telemetry lets you send your own application metrics, traces, and logs to Insights using the OpenTelemetry Protocol (OTLP). Custom telemetry appears alongside platform metrics from your DigitalOcean resources, so you can correlate application behavior with infrastructure health in one place.

For recommendations on what to send and how to instrument your services so that metrics, logs, and traces correlate, see Instrument Custom Telemetry.

To use custom telemetry, you need:

  • Access to the custom telemetry private preview.
  • An application instrumented with an OpenTelemetry SDK that can export over OTLP/HTTP.
  • A supported DigitalOcean resource that runs the application, such as an App Platform app, Droplet, Managed Database, or DigitalOcean Kubernetes (DOKS) cluster.

Create an API Token for Custom Telemetry

Insights authenticates custom telemetry using a DigitalOcean API token. Create a personal access token with the insights:custom_ingest scope.

Store the token in an environment variable, such as DO_API_TOKEN, rather than in your application code.

Configure the OpenTelemetry Exporter

Each Insights region has its own OTLP endpoint, https://otlp-insights-<region>.digitalocean.com, where <region> is the slug of the region your application runs in, such as nyc3. Signals are sent to the /v1/metrics, /v1/traces, and /v1/logs paths on that endpoint. Most OpenTelemetry SDKs append these paths automatically when you set the base endpoint.

To configure the exporter, set the following environment variables in your application’s environment, replacing <region> with your region slug:

export OTEL_EXPORTER_OTLP_ENDPOINT="https://otlp-insights-<region>.digitalocean.com"
export OTEL_EXPORTER_OTLP_HEADERS="Authorization=Bearer $DO_API_TOKEN"
export OTEL_EXPORTER_OTLP_PROTOCOL="http/protobuf"
export OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE="delta"

Custom metrics must meet the following requirements:

  • Send delta metrics. Insights rejects cumulative metric values. Set OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE to delta, as shown in the configuration above.
  • Use dotted metric names. Separate name segments with periods, such as app.payment.declined. Insights rejects names that use underscores as separators, such as app_payment_declined.
  • Do not use the do. prefix. Metric names that start with do. are reserved for platform metrics.

The endpoint region must match the resource.region.slug attribute on your telemetry. Insights rejects data sent to an endpoint in a different region. For a list of regions, see Insights Availability.

Set Resource Attributes

Every metric, trace, and log you send must include resource attributes that identify the service, the DigitalOcean resource it runs on, the owning team, and the region. Insights uses these attributes to link your telemetry to the resource, group it with platform metrics, and enable filtering in the DigitalOcean Control Panel.

The following resource attributes are required:

  • service.name: The name of your application or microservice, such as payment-service. This is the primary identifier in the Control Panel. For metrics, also add service.name as a metric label. In the Metrics tab, resource attributes alone do not make metrics filterable.
  • resource.urn: The Uniform Resource Name (URN) of the DigitalOcean resource that owns the telemetry, in the format do:<resource-type>:<resource-id>. For examples, see Resource URN Format.
  • resource.type: The category of DigitalOcean resource: app, droplet, dbaas, or kubernetes. Insights uses this value to group your data with platform metrics.
  • tenant.urn: The team that owns the resource, in the format do:team:<team-id>. Insights uses this value for access control and billing attribution.
  • resource.region.slug: The slug of the DigitalOcean region where your application runs, such as nyc3, sfo3, or ams3. The value must match a supported Insights region and the region of the endpoint you send to.

You can also include the following optional resource attributes:

  • service.version: The deployed version of your service, such as 1.4.2.
  • service.namespace: A logical grouping for services, such as an environment or team name.
  • deployment.environment: The deployment environment: prod, staging, or dev.

Resource URN Format

The resource.urn attribute uses the format do:<resource-type>:<resource-id>:

  • App Platform: do:app:<app-id>, for web services, APIs, and workers.
  • Droplets: do:droplet:<droplet-id>.
  • Managed Databases: do:dbaas:<database-cluster-id>, for database clusters such as PostgreSQL and MySQL.
  • DigitalOcean Kubernetes: do:kubernetes:<cluster-id>, for DOKS workloads.

Example Resource Attributes

The following example sets resource attributes for a payment service running on App Platform, using the standard OTEL_RESOURCE_ATTRIBUTES environment variable:

export OTEL_RESOURCE_ATTRIBUTES="service.name=payment-service,service.version=1.4.2,resource.urn=do:app:<your-app-id>,resource.type=app,tenant.urn=do:team:<your-team-id>,resource.region.slug=nyc3,deployment.environment=prod"

To correlate metrics, logs, and traces, propagate trace context between services, emit logs inside active spans, and include service.name as a metric label. These practices help you filter telemetry by service and link related signals. For more information, see Instrument Custom Telemetry.

Enable Telemetry Signals for the Resource

Enable the metrics, logs, or traces signals for the resource that owns your telemetry, identified by its URN. You can update signals using the DigitalOcean CLI or API. For full details, see Enable or Disable Telemetry Collection Using Automation.

To enable signals using the DigitalOcean CLI, use the doctl insights resource update command with the resource’s URN and the --metrics, --logs, or --traces flag set to true.

How to Update Resource Signal Enablement Using the DigitalOcean CLI
  1. Install doctl, the official DigitalOcean CLI.

  2. Create a personal access token and save it for use with doctl.

  3. Use the token to grant doctl access to your DigitalOcean account.

    doctl auth init
  4. Finally, run doctl insights resource update. Basic usage looks like this, but you can read the usage docs for more details:

    doctl insights resource update <resource-urn> [flags]

    The following example enables metrics and logs while disabling traces:

    doctl insights resource update do:droplet:12345 --region nyc3 --metrics=true --logs=true --traces=false

To enable signals using the DigitalOcean API, send the resource’s URN to the Update Resource Signal Enablement endpoint with metrics, logs, or traces set to true.

How to Update Resource Signal Enablement Using the DigitalOcean API

Create a personal access token and save it for use with the API.

cURL

Send a PUT request to https://api.digitalocean.com/v2/insights/resources/{resource_urn}/signals.

Using cURL:

curl -X PUT \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer $DIGITALOCEAN_TOKEN" \
  -d '{"region":"nyc3","metrics":true,"logs":true}' \
  "https://api.digitalocean.com/v2/insights/resources/do:droplet:12345/signals"

After enabling the signals and sending telemetry, select the region where your telemetry was sent in the Control Panel to view your custom telemetry alongside platform telemetry in the following tabs:

  • Metrics: In the Metrics tab, search for your custom metric names and filter by service.name. For more information, see How to Explore and Query Metrics.
  • Traces: In the Traces tab, filter by status, service, or attribute, and expand a trace to investigate its spans. For more information, see How to View Traces.
  • Logs: In the Logs tab, search and filter by log attributes, such as an order ID, and open related traces when available. For more information, see How to View Logs.

If your telemetry doesn’t appear, verify that the required resource attributes are included in each signal, that resource.urn identifies a resource with the corresponding signal enabled, and that the endpoint region matches resource.region.slug.

We can't find any results for your search.

Try using different keywords or simplifying your search terms.