Searching for Components, Environments, and Agents in a Region
Function
This API is used to search for components, environments, and Agents in a region.
URI
POST /v1/apm2/openapi/apm-service/app-mgr/search
Request Parameters
Parameter | Mandatory | Type | Description |
---|---|---|---|
X-Auth-Token | Yes | String | User token obtained from IAM. |
x-business-id | Yes | Long | Application ID. |
Parameter | Mandatory | Type | Description |
---|---|---|---|
business_id | Yes | Long | Application ID. |
region | Yes | String | Region name. |
page | Yes | Integer | Page number. |
page_size | No | Integer | Number of records on each page. |
keyword | No | String | Keyword used for search. |
Response Parameters
Status code: 200
Parameter | Type | Description |
---|---|---|
env_name | String | Environment name. |
env_id | Long | Environment ID. |
app_name | String | Component name. |
app_id | Long | Component ID. |
online_count | Integer | Number of online Agents. |
disable_count | Integer | Number of Agents that are manually stopped. |
offline_count | Integer | Number of offline Agents. |
data_source | String | Data source. |
Example Requests
Search for the Agents whose region ID is and application ID is 6, with the page number set to 1 and page size set to 10.
/v1/apm2/openapi/apm-service/app-mgr/search{"business_id" : 6,"region" : "","keyword" : "","page" : 1,"page_size" : 10}
Example Responses
Status code: 200
OK: The request is successful.
{"app_info_list" : [ {"env_name" : "beta","env_id" : 1,"app_name" : "application_name","app_id" : 2,"online_count" : 2,"disable_count" : 1,"offline_count" : 1} ],"app_total_count" : 4,"app_info_map" : {"additionalProp1" : {"env_name" : "string","env_id" : 0,"app_name" : "string","app_id" : 0,"online_count" : 0,"disable_count" : 0,"offline_count" : 0},"additionalProp2" : {"env_name" : "string","env_id" : 0,"app_name" : "string","app_id" : 0,"online_count" : 0,"disable_count" : 0,"offline_count" : 0},"additionalProp3" : {"env_name" : "string","env_id" : 0,"app_name" : "string","app_id" : 0,"online_count" : 0,"disable_count" : 0,"offline_count" : 0}}}
Status Codes
Status Code | Description |
---|---|
200 | OK: The request is successful. |
400 | Bad Request: Semantic or parameter error. |
401 | Unauthorized: No permissions. |
403 | Forbidden: Access forbidden. |
404 | Not Found: The requested resource is not found. |
Error Codes
See Error Codes.
- Function
- URI
- Request Parameters
- Response Parameters
- Example Requests
- Example Responses
- Status Codes
- Error Codes