dots.v2.insights.resources.byResource_urn().signals.put()

Generated on 5 Nov 2026 from DoTs version v1.23.0

Usage

client.v2.insights.resources.byResource_urn(resource_urn).signals.put(body: Resource_signals_update_request, requestConfiguration?: RequestConfiguration<object>): Promise<undefined | Resource_response>

Description

To enable or disable telemetry signals for a resource, send a PUT request to /v2/insights/resources/{resource_urn}/signals.

This endpoint uses merge semantics. Set metrics, logs, or traces to true or false to change that signal; omit a signal to leave it unchanged. At least one signal must be set.

region is only used when the resource has no existing enablement. On later updates, omit it or send the stored value; changing the region is rejected with a 400.

Requires both the insights:update and insights:create scopes.

Parameters

Path Parameters

resource_urn string required

Example: do:droplet:12345

The uniform resource name (URN) of the resource, for example do:droplet:12345.

Request Body

region string optional

Example: nyc3

The region slug for region-specific resources. Only used when the resource has no existing enablement. On later updates, omit it or send the stored value; changing the region is rejected.

metrics boolean optional

Example: true

Enable or disable the metrics signal. Omit to leave unchanged.

logs boolean optional

Example: true

Enable or disable the logs signal. Omit to leave unchanged.

traces boolean optional

Example: false

Enable or disable the traces signal. Omit to leave unchanged.

Request Sample

Show Request Sample
import { FetchRequestAdapter } from "@microsoft/kiota-http-fetchlibrary";
import {
    createDigitalOceanClient,
    DigitalOceanApiKeyAuthenticationProvider,
} from "@digitalocean/dots";

const authProvider = new DigitalOceanApiKeyAuthenticationProvider(process.env.DIGITALOCEAN_TOKEN!);
const adapter = new FetchRequestAdapter(authProvider);
const client = createDigitalOceanClient(adapter);

const response = await client.v2.insights.resources
    .byResource_urn("do:droplet:12345").signals.put({
    region: "nyc3",
    metrics: true,
    logs: true,
});

Response Example

Show Response Example
{
  "resource": {
    "resource_urn": "do:droplet:12345",
    "product_type": "droplet",
    "region": "nyc3",
    "metrics": {
      "enabled": true,
      "effective_at": "2026-10-01T12:00:00Z"
    },
    "logs": {
      "enabled": true,
      "effective_at": "2026-10-01T12:00:00Z"
    },
    "traces": {
      "enabled": false,
      "effective_at": "2026-10-03T08:30:00Z"
    }
  }
}

More Information

See /v2/insights/resources/{resource_urn}/signals in the API reference for additional detail on responses, headers, parameters, and more.

We can't find any results for your search.

Try using different keywords or simplifying your search terms.