Retrieves a protection policy.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
bdrc:GetProtectionPolicy |
get |
*All Resource
|
None | None |
Request syntax
GET /api/v1/protection-policies/{ProtectionPolicyId} HTTP/1.1
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| ProtectionPolicyId |
string |
Yes |
The protection policy ID. |
p-123***7890 |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
The response parameters. |
||
| Data |
object |
The data returned. |
|
| ProtectionPolicyRegionId |
string |
The region ID of the protection policy. |
cn-hangzhou |
| ProtectionPolicyId |
string |
The protection policy ID. |
p-123***7890 |
| ProtectionPolicyName |
string |
The protection policy name. |
MyProtectionPolicy |
| BoundResourceCategoryIds |
array |
The list of associated resource category IDs. |
|
|
string |
The resource category ID. |
rc-123***7890 |
|
| SubProtectionPolicies |
array<object> |
The list of configured sub-protection policies. |
|
|
object |
The list of enabled sub-protection policies. |
||
| SubProtectionPolicyType |
string |
The sub-protection policy type. |
ECS_AUTO_SNAPSHOT_POLICY |
| Config |
string |
The sub-protection policy configuration. |
{\"kafka.message.max.bytes\": \"10485760\", \"kafka.log.retention.hours\": \"48\", \"enable.acl\": \"true\"} |
| LatestApplyTime |
integer |
The time when the policy was last applied. |
1742167218 |
| LatestTaskId |
string |
The ID of the latest application task. |
t-123***7890 |
| RequestId |
string |
The unique ID of the request. |
AE43C4CB-8074-5EBD-9806-8CA6D12800B1 |
Examples
Success response
JSON format
{
"Data": {
"ProtectionPolicyRegionId": "cn-hangzhou",
"ProtectionPolicyId": "p-123***7890",
"ProtectionPolicyName": "MyProtectionPolicy",
"BoundResourceCategoryIds": [
"rc-123***7890"
],
"SubProtectionPolicies": [
{
"SubProtectionPolicyType": "ECS_AUTO_SNAPSHOT_POLICY",
"Config": "{\\\"kafka.message.max.bytes\\\": \\\"10485760\\\", \\\"kafka.log.retention.hours\\\": \\\"48\\\", \\\"enable.acl\\\": \\\"true\\\"}"
}
],
"LatestApplyTime": 1742167218,
"LatestTaskId": "t-123***7890"
},
"RequestId": "AE43C4CB-8074-5EBD-9806-8CA6D12800B1"
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.