Obtaining Details About a Single Rule
Function
Obtaining Details About a Single Rule
URI
GET /v2/{domain_id}/rules/{rule_id}/detail
Parameter | Mandatory | Type | Description |
|---|---|---|---|
domain_id | Yes | String | Indicates the tenant ID. |
rule_id | Yes | String | Rule ID |
Request Parameters
Parameter | Mandatory | Type | Description |
|---|---|---|---|
X-Auth-Token | Yes | String | User token. Can be obtained by calling the IAM API for obtaining the user token (the value of X-Subject-Token in the response header). |
Response Parameters
Status code: 200
Parameter | Type | Description |
|---|---|---|
id | String | Rule ID. |
type | String | Rule type |
name | String | Rule Name |
version | String | Rule version. |
layout_content | String | Layout Content |
plugin_id | String | Plug-in ID |
plugin_name | String | Plug-in |
plugin_version | String | Add-on version. |
creator | String | Created By |
create_time | String | Created |
updater | String | User who updated the data |
update_time | String | Updated |
content | Array of RuleContent objects | Rule Attribute List |
Parameter | Type | Description |
|---|---|---|
group_name | String | Group |
can_modify_when_inherit | Boolean | Can the Threshold of an Inherited Subpolicy Be Modified? |
properties | Array of RuleProperty objects | Rule Attribute List |
Parameter | Type | Description |
|---|---|---|
key | String | Attribute Key |
type | String | Type |
name | String | Display name |
operator | String | Comparison Operators |
value | String | Property value. |
value_type | String | Data Type |
Status code: 400
Parameter | Type | Description |
|---|---|---|
error_code | String | Error Codes |
error_msg | String | Description |
Status code: 401
Parameter | Type | Description |
|---|---|---|
error_code | String | Error Codes |
error_msg | String | Description |
Status code: 403
Parameter | Type | Description |
|---|---|---|
error_code | String | Error Codes |
error_msg | String | Description |
Status code: 404
Parameter | Type | Description |
|---|---|---|
error_code | String | Error Codes |
error_msg | String | Description |
Example Requests
GET https://{endpoint}/v2/ce8df55870164338a72d7e828a966a2a/rules/865b4c2d616b46ab890fff056a6f7e05/detail Example Responses
Status code: 200
Request succeeded.
{
"id" : "865b4c2d616b46ab890fff056a6f7e05",
"type" : "Build",
"name" : "New Rule-20231020103003",
"version" : "e2db2a63b3064252874b1b5a8571e2be",
"plugin_id" : "official_devcloud_cloudBuild",
"plugin_name" : "official_devcloud_cloudBuild",
"plugin_version" : "0.0.15",
"content" : [ {
"group_name" : "MavenUnitTest",
"can_modify_when_inherit" : true,
"properties" : [ {
"key" : "build.PassRatio",
"type" : "judge",
"name" : "PassRatio",
"value_type" : "float",
"value" : "0.1",
"operator" : "="
}, {
"key" : "build.TotalCases",
"type" : "judge",
"name" : "TotalCases",
"value_type" : "float",
"value" : "0.1",
"operator" : "="
}, {
"key" : "build.CoverageRatio",
"type" : "judge",
"name" : "CoverageRatio",
"value_type" : "float",
"value" : "0.1",
"operator" : "="
} ]
} ],
"creator" : "847a5317086c41798469d0868535943a",
"create_time" : "2023-10-20T10:30:20",
"updater" : "847a5317086c41798469d0868535943a",
"update_time" : "2023-10-20T10:30:20"
} Status Codes
Status Code | Description |
|---|---|
200 | Request succeeded. |
400 | Failed request |
401 | Authentication failed. |
403 | No permission. |
404 | The resource 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.

