Delete Monitors¶
POST /api/v1/checker/delete
Overview¶
Batch delete monitors, schedules, and associated references.
Before Calling and Usage Steps¶
First verify all target UUIDs and their impact, and select them item by item from the monitor list in the current workspace. Synchronously delete associated primary/attached/cross-workspace schedules, then soft-delete the rules and clean up related EntityRef references in the current workspace; old events and raw monitoring data are not deleted with the rules. Continue only if there is at least one non-deleted match; an empty array or a complete miss returns ObjectNotExists. The current method does not restrict type; use only rule UUIDs from this module, and do not mistakenly delete other Rules. Unmatched UUIDs among some inputs do not produce per-item errors; reference cleanup is based on the complete input set, and you cannot conclude from a match in an ownerless configuration that the corresponding reference in this workspace was definitely unaffected. Associated references such as SLOs are subsequently refreshed asynchronously; page status may lag until the refresh completes.
Custom operation permissions are validated for each target individually, and the API Key endpoint permissions are still required. The scheduling service, database commit, reference cleanup, and asynchronous dispatch are not an atomic cross-service transaction. On exceptions, some state/schedule updates may already have been applied; read back the current configuration and schedule state before retrying, and do not accept the result based solely on HTTP 200.
Request Headers¶
| Parameter Name | Type | Required | Description |
|---|---|---|---|
| DF-API-KEY | string | Y | OpenAPI authentication credential for the workspace. Example: <DF-API-KEY>How to obtain or enter: Obtain an OpenAPI Key with this operation permission from API Key Management in the target workspace. |
Body Request Parameters¶
| Parameter Name | Type | Required | Description |
|---|---|---|---|
| ruleUUIDs[*] | string | This is not a grouping, history, SLO, or generated metric UUID. Example: rul_checker_exampleHow to obtain or enter: a single monitor UUID that can be operated in the current workspace. |
|
| ruleUUIDs | array | Y | Required array; non-empty is recommended. These shared methods do not additionally restrict the monitor category; do not mix in UUIDs of other Rule resources merely because they have the rul_ prefix.Allows null: False Example: ["rul_checker_example"]How to obtain or enter: Obtain the UUIDs in the current workspace item by item from the Monitor List according to the target type. |
Request Example¶
curl --request POST 'https://openapi.guance.com/api/v1/checker/delete' \
-H 'DF-API-KEY: <DF-API-KEY>' \
-H 'Content-Type: application/json' \
--data-raw '{"ruleUUIDs":["rul_checker_example"]}'
Response¶
HTTP 200, application/json. The example below shows the main fields that can be read directly.
| Field | Type | Description |
|---|---|---|
| content | boolean | true on success; not the per-item match count or the downstream execution acceptance result. |
{
"code": 200,
"content": true,
"errorCode": "",
"message": "",
"success": true,
"traceId": "TRACE-EXAMPLE"
}
Error Responses¶
For authentication, rate limiting, and common request errors, see Common Error Definitions.
| HTTP Status | errorCode | Trigger Condition | Message or Response Description | Handling |
|---|---|---|---|---|
| 406 | ft.ParameterValidationFailed | Request field is missing, or the field value violates the declared validation conditions | Parameter parsing failed | Check the parameter location, field name, type, and value. |
| 400 | ft.RequestJsonFormatError | Request JSON syntax is invalid | Request JSON format error | Correct the JSON based on content.reason, line, and column. |
| 400 | ft.JsonFormatError | The top level of the JSON body is not an object, such as an array/string | Some JSON file format error | Submit a JSON object as shown in the example; do not submit checkers or event arrays directly. |
| 403 | ft.ForbiddenCheckerOperation | No permission to operate the target standard monitor | You do not have permission to operate monitor [{}] | Use the owner or an operation subject allowed by the rule, and check the API Key permissions. |
| 403 | ft.ForbiddenSmartCheckerOperation | No permission to operate the target smart/AI monitoring | You do not have permission to operate Smart Monitoring [{}] | Check the rule's permissionSet and the operation identity. |
| 400 | ft.OuterFuncFailed | The scheduling batch start/stop/delete returned an explicit business failure | External function call failed | Check the schedule and rule status, then retry and provide traceId. |
| 500 | ft.InternalServerError | Uncaught exceptions such as scheduling connection errors/timeouts/invalid JSON, storage, reference, or post-commit asynchronous dispatch failures | Internal error | First read the current state of each object and schedule, confirm the completed steps, then retry as appropriate and provide traceId. |
| 404 | ft.ObjectNotExists | No non-deleted rule in the collection matches in this workspace, including [] | The specified object does not exist | Obtain valid UUIDs again from the current list; deleted objects cannot be restored again based on this response. |