Enable¶
POST /api/v1/self_built_checker/enable
Overview¶
Enable self-built inspections.
Before Calling and Usage Steps¶
Set status to 0 for matching self-built inspections that have not been deleted; this does not immediately execute associated functions, create new schedules, or guarantee that tasks in external business integrations have been paused/started. Verify the actual execution status on the integration side.
Only UUIDs from this module's list in the current workspace can be used. If refKey is provided, it is used together with UUIDs for filtering; it is not an independent batch targeting method. Returns true, with no per-item hit/change count; an empty array or no match can also succeed, and status/associations must be read back to verify. For errors/timeouts, check the current configuration state first; asynchronous dispatch failures after deletion/submission may have already been persisted.
Request Headers¶
| Parameter | Type | Required | Description |
|---|---|---|---|
| DF-API-KEY | string | Y | OpenAPI authentication credential for the workspace. Example: <DF-API-KEY>How to obtain or fill in: Obtain an OpenAPI Key with this operation permission from API Key Management in the target workspace. |
Body Request Parameters¶
| Parameter | Type | Required | Description |
|---|---|---|---|
| ruleUUIDs[*] | string | A non-empty string is recommended; it is not a function ID or other rule identifier. Example: rul_self_exampleHow to obtain or fill in: A single verified self-built inspection UUID. |
|
| ruleUUIDs | array | Declared optional but an array must actually be provided; if omitted, in_(None) may return 500, and refKey cannot replace the array. A non-empty array is recommended; do not mix rules of other types or UUIDs from other workspaces. Allows null: False Example: ["rul_self_example"]How to obtain or fill in: Check each self-built inspection UUID in the current workspace from this module's list. |
|
| refKey | string | Optional additional filter condition that matches together with each UUID; it is not a substitute for UUID, and you cannot operate on a collection by passing only refKey. Allows null: False Example: custom-healthcheck-productionHow to obtain or fill in: Fill in when you need to additionally verify the same business association key. |
Request Example¶
curl --request POST 'https://openapi.guance.com/api/v1/self_built_checker/enable' \
-H 'DF-API-KEY: <DF-API-KEY>' \
-H 'Content-Type: application/json' \
--data-raw '{"ruleUUIDs":["rul_self_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; this does not mean every input UUID matched or was actually changed. |
{
"code": 200,
"content": true,
"errorCode": "",
"message": "",
"success": true,
"traceId": "TRACE-EXAMPLE"
}
Error Response¶
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 | A 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 | Fix the JSON according to content.reason, line, and column. |
| 500 | ft.InternalServerError | Target not selected, invalid field shape or length, database or post-submission asynchronous task dispatch failure, etc. | Internal error | First read back the current rule to confirm whether it has been saved; retry after using an explicit ruleUUID in the current workspace, and provide traceId. |