dots.v2.databases.metrics.credentials.put()

Generated on 5 Nov 2026 from DoTs version v1.23.0

Usage

client.v2.databases.metrics.credentials.put(body: Database_metrics_credentials, requestConfiguration?: RequestConfiguration<object>): Promise<void>

Description

To update the credentials for all database clusters’ metrics endpoints, send a PUT request to /v2/databases/metrics/credentials. A successful request will receive a 204 No Content status code with no body in response.

Parameters

credentials object optional
Show child properties
basicAuthUsername string optional

Example: username

basic authentication username for metrics HTTP endpoint

basicAuthPassword string optional

Example: password

basic authentication password for metrics HTTP endpoint

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);

await client.v2.databases.metrics.credentials.put({
    credentials: {
        basicAuthUsername: "new_username",
        basicAuthPassword: "new_password",
    },
});

More Information

See /v2/databases/metrics/credentials 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.