Specify the ID of an existing rule you want to delete and the rule gets deleted. Ensure that the rules you want to delete are disabled. If a rule is enabled, you cannot delete the rule.
Parameter |
Mandatory/Optional | Data Type |
Description |
---|---|---|---|
ruleIds |
Mandatory | Array[String] |
Specify the ID of an rule to be deleted and the rule gets deleted. You can provide multiple Ids separated by comma. Example: { "ids": [ "string" ] } |
API request
curl -k -X POST-u <username>:<password>
'https://<QualysURL>/cloudview-api/rest/v1/rules/delete'
Request POST Data
{
"ids": [
"1a841990-5dff-11ea-a923-6b29e6c4cbec",
"efbf4080-52dd-11ea-a008-cbe911ab6a51"
]
}
Response
No Content
Response Code: 200
Response returns status code 200 with rule detail for rules that cannot be deleted. If rules are in enabled state, you need to disable them before deleting
Response
{
"efbf4080-52dd-11ea-a008-cbe911ab6a51": "Cannot delete enable rule."
}