monitoring.checks.update

Change an uptime check; changing what it requests starts it over as pending

PATCH /monitoring/api/checks/{id}IAM monitoring:UpdateCheckChanges state

Request syntax

PATCH /monitoring/api/checks/{id}
{
  "name": "string",
  "type": "enum",
  "url": "string",
  "method": "enum",
  "expectedStatusMin": "number",
  "expectedStatusMax": "number",
  "keyword": "string",
  "keywordMode": "enum",
  "timeoutMs": "number",
  "intervalSeconds": "number",
  "followRedirects": "boolean",
  "verifyTls": "boolean",
  "failureThreshold": "number",
  "confirmations": "number",
  "alertOnRegional": "boolean",
  "notifyEmails": "array of string",
  "webhookUrl": "string"
}

Path parameters

  • idRequired

    string

    Constraints: uuid

Request body

  • nameOptional

    string

    Unique in the organization (409 when taken), up to 128 characters; unchanged when omitted

  • typeOptional

    enum

    http or keyword; unchanged when omitted. Switching to http without a keyword drops the keyword; changing it starts the check over as pending

    One of: http, keyword

  • urlOptional

    string

    http:// or https:// on a public address, any port except 25, 465 and 587; unchanged when omitted. changing it starts the check over as pending; 409 when the new host is already requested 6 times a minute

  • methodOptional

    enum

    GET or HEAD (a keyword check uses GET); unchanged when omitted, changing it starts the check over as pending

    One of: GET, HEAD

  • expectedStatusMinOptional

    number

    Lowest status that counts as up, 100–599; unchanged when omitted, changing it starts the check over as pending

    Constraints: integer

  • expectedStatusMaxOptional

    number

    Highest status that counts as up, 100–599, not below the minimum; unchanged when omitted, changing it starts the check over as pending

    Constraints: integer

  • keywordOptional

    string

    Keyword checks only: the text looked for, up to 200 characters; unchanged when omitted, changing it starts the check over as pending

    May be null.

  • keywordModeOptional

    enum

    contains or not_contains; unchanged when omitted, changing it starts the check over as pending

    One of: contains, not_contains

    May be null.

  • timeoutMsOptional

    number

    Milliseconds, 1000–30000; unchanged when omitted

    Constraints: integer

  • intervalSecondsOptional

    number

    60, 120, 300, 600, 900, 1800 or 3600; unchanged when omitted. 409 when it would take the host over 6 requests a minute

    Constraints: integer

  • followRedirectsOptional

    boolean

    Follow up to 5 redirects; unchanged when omitted, changing it starts the check over as pending

  • verifyTlsOptional

    boolean

    Fail on an invalid certificate; unchanged when omitted, changing it starts the check over as pending

  • failureThresholdOptional

    number

    Failed runs in a row before DOWN, 1–5; unchanged when omitted

    Constraints: integer

  • confirmationsOptional

    number

    Locations that must fail in one run, 1–3; unchanged when omitted

    Constraints: integer

  • alertOnRegionalOptional

    boolean

    Treat one failing location as failed; unchanged when omitted

  • notifyEmailsOptional

    array of string

    Up to 10 addresses mailed on DOWN and UP; replaces the list, unchanged when omitted

  • webhookUrlOptional

    string

    https URL on a public address, POSTed on DOWN and UP; null removes it, unchanged when omitted

    May be null.

Response

200 with the check as get describes it. The merged check is checked as a whole (400 when its fields disagree); 409 when the new name is taken or a new host or interval would pass 6 requests a minute to the host; 404 when the organization has no such check.

A JSON response is wrapped as { "success": true, "data": … }; the CLI prints the whole body with --json.

Errors

  • 400The request does not pass the schema above. The body is { "error": …, "issues": […] }, one issue per field.
  • 401No credentials, or an access key that is unknown, revoked or expired.
  • 403The caller's policies do not allow monitoring:UpdateCheck on this resource. The body names the action and the resource, and the refusal is recorded in the audit log.
  • 404The resource does not exist in your organization.

Examples

The required parameters only, with example values. Replace id and the other placeholders with your own.

dcloud monitoring checks update id

Generated from the API description, the same one the API checks requests against and the CLI is built from. MCP tool: dcloud_monitoring_checks_update.