dots.v2.uptime.checks.post()

Generated on 13 Nov 2026 from DoTs version v1.24.0

Usage

client.v2.uptime.checks.post(body: ChecksPostRequestBody, requestConfiguration?: RequestConfiguration<object>): Promise<undefined | ChecksPostResponse>

Description

To create an Uptime check, send a POST request to /v2/uptime/checks specifying the attributes in the table below in the JSON body.

Parameters

name string required

Example: Landing page check

A human-friendly display name.

type string required

The type of health check to perform.

One of: ping, http, https

target string required

Example: https://www.landingpage.com

The endpoint to perform healthchecks on.

regions array of strings required

Example: ["us_east", "eu_west"]

An array containing the selected regions to perform healthchecks from.

enabled boolean required

Example: true

A boolean value indicating whether the check is enabled/disabled.

Default: true

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.uptime.checks.post({
    name: "Landing page check",
    type: "https",
    target: "https://www.landingpage.com",
    regions: [
        "us_east",
        "eu_west",
    ],
    enabled: true,
});

Response Example

Show Response Example
{
  "check": {
    "id": "5a4981aa-9653-4bd1-bef5-d6bff52042e4",
    "name": "Landing page check",
    "type": "https",
    "target": "https://www.landingpage.com",
    "regions": [
      "us_east",
      "eu_west"
    ],
    "enabled": true
  }
}

More Information

See /v2/uptime/checks 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.