Domain name for API request: teo.intl.tencentcloudapi.com.
This API is used to query the binding relationship list of a specified policy template.
A maximum of 20 requests can be initiated per second for this API.
The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.
| Parameter Name | Required | Type | Description |
|---|---|---|---|
| Action | Yes | String | Common Params. The value used for this API: DescribeSecurityTemplateBindings. |
| Version | Yes | String | Common Params. The value used for this API: 2022-09-01. |
| Region | No | String | Common Params. This parameter is not required. |
| ZoneId | Yes | String | Site ID to query. |
| TemplateId.N | Yes | Array of String | Template ID of the policy to query. |
| Parameter Name | Type | Description |
|---|---|---|
| SecurityTemplate | Array of SecurityTemplateBinding | List of binding relationships of the specified policy template. When a domain name in a site is included in the binding relationship of a specified policy template, the binding relationship list TemplateScope will include the ZoneId of the site and the domain name binding relationships under the site related to the policy template.Note: When no any domain name is being bound or has been bound to the specified policy template, the binding relationship is empty. That is, in the return structure, the length of the TemplateScope array is 0.In a binding relationship, the same domain name may appear repeatedly in the EntityStatus list and be marked with different Status. For example, a domain name being bound to another policy template is marked as both online and pending at the same time. |
| RequestId | String | The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. |
This method outputs all binding relationships of the policy template, including:
1) For an active binding relationship, the annotation "Status" is "online";
2) For a binding relationship that is binding in progress, the annotation "Status" is "pending".
Note: A domain name may appear multiple times in the binding relationship list and be marked with multiple statuses at the same time.
For example: To query the binding relationship of the policy template "Production Environment Policy" (SecurityTemplate ID: temp-fjsoelx) under the site example.com (zone ID: zone-fdsjjkfsda), see the following example.
Note: The output sample includes binding relationships that are being bound and failed to bind. The policy template has taken effect for both domains. Among them, abc.example.com is bound to the specified policy template, and the policy is active, so this binding relationship is shown as online. xyz.example.com is being rebound to another policy template, but the binding is not yet complete. The current policy template is still in effect, so it simultaneously appears in the lists of active and binding in progress relationships.
POST / HTTP/1.1
Host: teo.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeSecurityTemplateBindings
<Common request parameters>
{
"ZoneId": "zone-fdsjjkfsda",
"TemplateId": [
"temp-fjsoelx"
]
}
{
"Response": {
"SecurityTemplate": [
{
"TemplateId": "temp-fjsoelx",
"TemplateScope": [
{
"ZoneId": "zone-fdsjjkfsda",
"EntityStatus": [
{
"Entity": "abc.example.com",
"Status": "online",
"Message": ""
},
{
"Entity": "xyz.example.com",
"Status": "online",
"Message": ""
},
{
"Entity": "xyz.example.com",
"Status": "pending",
"Message": ""
}
]
}
]
}
],
"RequestId": "17d437bc-13a9-49bb-a6ac"
}
}
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.
The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.
| Error Code | Description |
|---|---|
| InternalError.ProxyServer | Unknown error occurs on the real server. |
| UnauthorizedOperation.CamUnauthorized | Unauthorized Cam operation. |
| UnauthorizedOperation.NoPermission | The sub-account does not have operation permissions. Add the required permissions and try again. |
| UnauthorizedOperation.Unknown | Unknown error occurs on the real server. |
フィードバック