Querying a Group
Function
This API is used to query groups, and query groups under applications, sub-applications, and components to manage resources in a unified manner. If there is no component under the application, no component information is displayed.
Authorization Information
Each account has all the permissions required to call all APIs, but IAM users must be assigned the required permissions.
- If you are using role/policy-based authorization, see Permissions Policies and Supported Actions for details on the required permissions.
- If you are using identity policy-based authorization, the following identity policy-based permissions are required.
Action
Access Level
Resource Type (*: required)
Condition Key
Alias
Dependencies
coc:application:listGroups
List
application *
-
-
-
URI
GET /v1/groups
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
id_list |
No |
Array of strings |
Definition: Group ID list consisting of group IDs. Constraints: N/A Value range: N/A Default value: N/A |
|
component_id |
No |
String |
Definition: Component ID. Constraints: N/A Value range: ID of the component selected during group creation. The value contains 24 characters. Default value: N/A |
|
application_id |
No |
String |
Definition: Application ID. Constraints: N/A Value range: ID of the application for the component corresponding to the group. There is a clear hierarchy between them. Default value: N/A |
|
name_like |
No |
String |
Definition: Group name. Fuzzy match is supported. Constraints: N/A Value range: The value is a string. It contains 1 to 50 characters. Default value: N/A |
|
code |
No |
String |
Definition: Group code. Constraints: N/A Value range: The value is a string. It contains 3 to 50 characters. Default value: N/A |
|
marker |
No |
String |
Definition: It is used for pagination query. Constraints: N/A Value range: ID of the last record in the previous query. Default value: N/A |
|
limit |
Yes |
Integer |
Definition: Number of items displayed on each page when the pagination query is performed. Constraints: N/A Value range: It is user-defined. The value ranges from 1 to 500. Default value: N/A |
Request Parameters
None
Response Parameters
Status code: 200
|
Parameter |
Type |
Description |
|---|---|---|
|
data |
Array of data objects |
Definition: Group ID. Value range: N/A |
|
Parameter |
Type |
Description |
|---|---|---|
|
id |
String |
Definition: UUID allocated by COC-CMDB. Value range: N/A |
|
name |
String |
Definition: Group name. Value range: The value can contain 3 to 50 characters, including letters, digits, hyphens (-), underscores (_), and Chinese characters. |
|
vendor |
String |
Definition: Vendor. Value range: |
|
code |
String |
Definition: Group code. Value range: N/A |
|
domain_id |
String |
Definition: Tenant ID. Value range: N/A |
|
region_id |
String |
Definition: Region ID. Value range: N/A |
|
component_id |
String |
Definition: Component ID. Value range: N/A |
|
application_id |
String |
Definition: Application ID. Value range: N/A |
|
ep_id |
String |
Definition: Enterprise project ID. Value range: Select a project ID that is available inEnterprise Management. |
|
sync_mode |
String |
Definition: Resource synchronization method. Value range: |
|
rule_tags |
String |
Definition: Tag that is associated with resources. Value range: N/A |
|
relation_configurations |
Array of GroupRelationConfiguration objects |
Definition: Group configuration information. Value range: N/A |
|
Parameter |
Type |
Description |
|---|---|---|
|
type |
String |
Definition: Configuration type. Configure the application, component, and environment of the APM service corresponding to the group. APM service performance information can be obtained during fault diagnosis. Constraints: N/A Value range: Default value: N/A |
|
parameters |
Map<String,String> |
Definition: Configuration parameters. Constraints: N/A Value range: APM configuration parameter app_id->business_id->env_id. The value contains multiple fields. The maximum length is for reference only. Default value: N/A |
Example Requests
This API is used to query the component information of an application or sub-application.
GET https://{Endpoint}/v1/groups
Example Responses
Status code: 200
The group information is queried.
{
"data" : [ {
"id" : "64898bf60224b9730ccb577f",
"name" : "testgroup",
"vendor" : "RMS",
"code" : "testgroup",
"domain_id" : "dc2d76541f754d68a4c8d150262d92c2",
"region_id" : "string",
"component_id" : "64898bf60224b9730ccb577f",
"application_id" : "64898bf60224b9730ccb577f",
"ep_id" : "0",
"sync_mode" : "MANUAL",
"rule_tags" : null,
"relation_configurations" : [ { } ]
} ]
}
Status Codes
|
Status Code |
Description |
|---|---|
|
200 |
The group information is queried. |
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