Updates a scan rule.
Operation description
This API is available through a whitelist. Submit a ticket to request access.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
cr:UpdateScanRule |
update |
*ScanRule
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| InstanceId |
string |
Yes |
The instance ID. |
cri-4abntrj42twd**** |
| ScanRuleId |
string |
Yes |
The rule ID. |
crscnr-3qmkeiuggfpjkfrq |
| RuleName |
string |
Yes |
The rule name. |
scan-test |
| ScanScope |
string |
Yes |
The scan scope. Valid values:
|
REPO |
| TriggerType |
string |
Yes |
The trigger type. Valid values:
|
AUTO |
| Namespaces |
array |
No |
The collection of namespaces.
|
|
|
string |
No |
The namespace. |
prd |
|
| RepoNames |
array |
No |
The list of repositories.
|
|
|
string |
No |
The repository name. |
prod |
|
| RepoTagFilterPattern |
string |
Yes |
The tag filtering rule. |
prod-.* |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
The response struct. |
||
| RequestId |
string |
Request Id |
33EF1695-E2B7-5D57-B4E1-3D655FE1EBD8 |
| Code |
integer |
The return code. |
success |
| ScanRuleId |
string |
The rule ID. |
crscnr-3qmkeiuggfpjkfrq |
Examples
Success response
JSON format
{
"RequestId": "33EF1695-E2B7-5D57-B4E1-3D655FE1EBD8",
"Code": 0,
"ScanRuleId": "crscnr-3qmkeiuggfpjkfrq"
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.