Enabling or Disabling a Security Policy
Function
This API is used to enable or disable security policies in batches.
Calling Method
For details, see Calling APIs.
URI
PUT /v1/{project_id}/security-policies
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
project_id |
Yes |
String |
Unique project ID. |
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
operation |
Yes |
String |
Operation type, which can be enable or disable. |
Request Parameters
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
ids |
No |
Array of longs |
Policy ID list. |
Response Parameters
Status code: 200
Operation succeeded.
Status code: 201
Resource being created.
None
Example Requests
PUT /v1/{project_id}/security-policies
{
"ids" : [ 0 ]
}
Example Responses
None
Status Codes
|
Status Code |
Description |
|---|---|
|
200 |
Operation succeeded. |
|
201 |
Resource being created. |
|
401 |
Unauthorized. The user is not logged in or the token is invalid. |
|
403 |
Unauthorized to access the resource. |
|
404 |
The specified project does not exist. |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot