DescribeApplication - 查询应用信息

调用DescribeApplication查询应用的基本属性、资源和容器状态列表。

调试

您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。

授权信息

下表是API对应的授权信息,可以在RAM权限策略语句的Action元素中使用,用来给RAM用户或RAM角色授予调用此API的权限。具体说明如下:

  • 操作:是指具体的权限点。
  • 访问级别:是指每个操作的访问级别,取值为写入(Write)、读取(Read)或列出(List)。
  • 资源类型:是指操作中支持授权的资源类型。具体说明如下:
    • 对于必选的资源类型,用背景高亮的方式表示。
    • 对于不支持资源级授权的操作,用全部资源表示。
  • 条件关键字:是指云产品自身定义的条件关键字。
  • 关联操作:是指成功执行操作所需要的其他权限。操作者必须同时具备关联操作的权限,操作才能成功。
操作访问级别资源类型条件关键字关联操作
ens:DescribeApplicationget
*全部资源
*

请求参数

名称类型必填描述示例值
AppIdstring

应用 ID,可通过调用 ListApplications 接口获取。

a2bac6f4-75dc-455e-8389-2dc8e47526d3
AppVersionsstring

应用的业务服务版本号。支持多选,以","分割;输入 All,输出所有版本数据。默认只输出稳定版版本号的关联数据。

v1,v2
Levelstring

应用边缘资源的区域统计级别。枚举类型,取值范围:

  • National:全国
  • Big:大区
  • Middle:省级
  • Small:城市
  • RegionId:边缘节点

默认 National。

National
OutDetailStatParamsstring

是否输出统计资源实例/容器 Pod 等维度的信息。Json 的字符串格式。默认输出所有信息。

{\"appInfo\":true,\"detailStat\": true, \"appVersionStat\": true, \"districtStat\":true ,\"instanceStat\": true, \"podCountStat\": true}
ResourceSelectorstring

资源筛选条件。

[{\"regionCode\": \"cn-wuxi-telecom_unicom_cmcc-3\", \"ispCode\": \"telecom\", \"count\": 2 },{ \"regionCode\": \"cn-shanghai-cmcc\", \"count\": 4 }]

返回参数

名称类型描述示例值
object
Applicationstring

返回的应用信息数据。

{ "AppMetaData":{ "AppId":"b0b27670-87d5-4c40-9ea8-adeeec2986ce", "AppName":"asp-yz", "ClusterName":"poc", "AppStableVersion":"0825", "AppType":"Scheduler", "Description":"日常测试CPU环境", "CreateTime":"2020-08-25 16:36:16" }, "AppStatus":{ "Phase":"RUNNING", "StatusDescrip":"{\"status\":\"UPDATE_SUCCESS\",\"step\":\"DONE\",\"descrip\":\"delVersion success\",\"start_time\":\"2021-08-18 14:46:45\"}", "UpdateTime":"2021-08-18 14:46:45" }, "ResourceAttribute":{ "ResourceType":"Ens", "ResourceAgent":"Linux", "InstanceSpec":"ens.sn1.large", "SystemDiskSize":40, "DataDiskSize":0, "BandwithOut":10, "SchedulingStrategy":"Disperse", "AreaLevel":"RegionId", "IpType":"PublicIP" }, "WorkloadAttribute":[ { "Name":"andorid", "PodCount":7, "ServiceConfig":{ "PortsBindConfig":{ "NetServiceContainer":"aspserver-android", "Ports":[ { "Protocol":"TCP", "BindType":"PassThrough", "StartNodePorts":"5000-5000", "ContainerPorts":"5000-5000" }, { "Protocol":"UDP", "BindType":"PassThrough", "StartNodePorts":"4001-4010", "ContainerPorts":"4001-4010" } ] }, "ServiceContainerName":"android" } }, { "Name":"aic-manager", "PodCount":1, "ServiceConfig":null } ], "DetailStat":{ "Level":"Small", "InstanceTotalCount":1, "InstanceRunningCount":0, "PodCountStat":[ { "Name":"andorid", "RunningCount":7, "ProducedCount":7, "Devices":null }, { "Name":"aic-manager", "RunningCount":1, "ProducedCount":1, "Devices":null } ], "AppVersionStat":[ { "AppVersion":"08102", "Descrip":"白屏化测试2", "CreateTime":"2021-08-10 11:20:04", "InstanceTotalCount":1, "InstanceRunningCount":0, "PodCountStat":[ { "Name":"andorid", "RunningCount":7, "ProducedCount":7, "Devices":null }, { "Name":"aic-manager", "RunningCount":1, "ProducedCount":1, "Devices":null } ], "DistrictStat":[ { "AreaCode":"310100", "AreaName":"华东,,", "RegionCode":"310100", "RegionName":"", "IspCode":"telecom", "RegionIds":[ "cn-shanghai-telecom-2" ], "InstanceTotalCount":1, "InstanceRunningCount":0, "PodCountStat":[ { "Name":"andorid", "RunningCount":7, "ProducedCount":7, "Devices":null }, { "Name":"aic-manager", "RunningCount":1, "ProducedCount":1, "Devices":null } ], "InstanceStat":[ { "InstanceId":"i-xxxxxxx", "PublicIps":[ { "PublicIp":"101.227.7.12", "Isp":"telecom" } ], "InternalIps":[ { "Ip":"10.0.1.4" } ], "RegionId":"cn-shanghai-telecom-2", "NcName":"", "InstanceStatus":"", "CreateTime":"2020-09-12 22:33:08", "PodCountStat":[ { "Name":"andorid", "RunningCount":7, "ProducedCount":7, "Devices":[ { "Name":"asp-yz-andorid-08102-zjzmcyaw-0", "Status":"Running", "Ports":null }, { "Name":"asp-yz-andorid-08102-zjzmcyaw-1", "Status":"Running", "Ports":null }, { "Name":"asp-yz-andorid-08102-zjzmcyaw-2", "Status":"Running", "Ports":null }, { "Name":"asp-yz-andorid-08102-zjzmcyaw-3", "Status":"Running", "Ports":null }, { "Name":"asp-yz-andorid-08102-zjzmcyaw-4", "Status":"Running", "Ports":null }, { "Name":"asp-yz-andorid-08102-zjzmcyaw-5", "Status":"Running", "Ports":null }, { "Name":"asp-yz-andorid-08102-zjzmcyaw-6", "Status":"Running", "Ports":null } ] }, { "Name":"aic-manager", "RunningCount":1, "ProducedCount":1, "Devices":[ { "Name":"asp-yz-aic-manager-08102-zjzmcyaw-0", "Status":"Running", "Ports":null } ] } ], "AppVersionDescrip":"" } ] } ] } ] } }
RequestIdstring

请求 ID。

473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E

示例

正常返回示例

JSON格式

{
  "Application": "{\n    \"AppMetaData\":{\n        \"AppId\":\"b0b27670-87d5-4c40-9ea8-adeeec2986ce\",\n        \"AppName\":\"asp-yz\",\n        \"ClusterName\":\"poc\",\n        \"AppStableVersion\":\"0825\",\n        \"AppType\":\"Scheduler\",\n        \"Description\":\"日常测试CPU环境\",\n        \"CreateTime\":\"2020-08-25 16:36:16\"\n    },\n    \"AppStatus\":{\n        \"Phase\":\"RUNNING\",\n        \"StatusDescrip\":\"{\\\"status\\\":\\\"UPDATE_SUCCESS\\\",\\\"step\\\":\\\"DONE\\\",\\\"descrip\\\":\\\"delVersion success\\\",\\\"start_time\\\":\\\"2021-08-18 14:46:45\\\"}\",\n        \"UpdateTime\":\"2021-08-18 14:46:45\"\n    },\n    \"ResourceAttribute\":{\n        \"ResourceType\":\"Ens\",\n        \"ResourceAgent\":\"Linux\",\n        \"InstanceSpec\":\"ens.sn1.large\",\n        \"SystemDiskSize\":40,\n        \"DataDiskSize\":0,\n        \"BandwithOut\":10,\n        \"SchedulingStrategy\":\"Disperse\",\n        \"AreaLevel\":\"RegionId\",\n        \"IpType\":\"PublicIP\"\n    },\n    \"WorkloadAttribute\":[\n        {\n            \"Name\":\"andorid\",\n            \"PodCount\":7,\n            \"ServiceConfig\":{\n                \"PortsBindConfig\":{\n                    \"NetServiceContainer\":\"aspserver-android\",\n                    \"Ports\":[\n                        {\n                            \"Protocol\":\"TCP\",\n                            \"BindType\":\"PassThrough\",\n                            \"StartNodePorts\":\"5000-5000\",\n                            \"ContainerPorts\":\"5000-5000\"\n                        },\n                        {\n                            \"Protocol\":\"UDP\",\n                            \"BindType\":\"PassThrough\",\n                            \"StartNodePorts\":\"4001-4010\",\n                            \"ContainerPorts\":\"4001-4010\"\n                        }\n                    ]\n                },\n                \"ServiceContainerName\":\"android\"\n            }\n        },\n        {\n            \"Name\":\"aic-manager\",\n            \"PodCount\":1,\n            \"ServiceConfig\":null\n        }\n    ],\n    \"DetailStat\":{\n        \"Level\":\"Small\",\n        \"InstanceTotalCount\":1,\n        \"InstanceRunningCount\":0,\n        \"PodCountStat\":[\n            {\n                \"Name\":\"andorid\",\n                \"RunningCount\":7,\n                \"ProducedCount\":7,\n                \"Devices\":null\n            },\n            {\n                \"Name\":\"aic-manager\",\n                \"RunningCount\":1,\n                \"ProducedCount\":1,\n                \"Devices\":null\n            }\n        ],\n        \"AppVersionStat\":[\n            {\n                \"AppVersion\":\"08102\",\n                \"Descrip\":\"白屏化测试2\",\n                \"CreateTime\":\"2021-08-10 11:20:04\",\n                \"InstanceTotalCount\":1,\n                \"InstanceRunningCount\":0,\n                \"PodCountStat\":[\n                    {\n                        \"Name\":\"andorid\",\n                        \"RunningCount\":7,\n                        \"ProducedCount\":7,\n                        \"Devices\":null\n                    },\n                    {\n                        \"Name\":\"aic-manager\",\n                        \"RunningCount\":1,\n                        \"ProducedCount\":1,\n                        \"Devices\":null\n                    }\n                ],\n                \"DistrictStat\":[\n                    {\n                        \"AreaCode\":\"310100\",\n                        \"AreaName\":\"华东,,\",\n                        \"RegionCode\":\"310100\",\n                        \"RegionName\":\"\",\n                        \"IspCode\":\"telecom\",\n                        \"RegionIds\":[\n                            \"cn-shanghai-telecom-2\"\n                        ],\n                        \"InstanceTotalCount\":1,\n                        \"InstanceRunningCount\":0,\n                        \"PodCountStat\":[\n                            {\n                                \"Name\":\"andorid\",\n                                \"RunningCount\":7,\n                                \"ProducedCount\":7,\n                                \"Devices\":null\n                            },\n                            {\n                                \"Name\":\"aic-manager\",\n                                \"RunningCount\":1,\n                                \"ProducedCount\":1,\n                                \"Devices\":null\n                            }\n                        ],\n                        \"InstanceStat\":[\n                            {\n                                \"InstanceId\":\"i-xxxxxxx\",\n                                \"PublicIps\":[\n                                    {\n                                        \"PublicIp\":\"101.227.7.12\",\n                                        \"Isp\":\"telecom\"\n                                    }\n                                ],\n                                \"InternalIps\":[\n                                    {\n                                        \"Ip\":\"10.0.1.4\"\n                                    }\n                                ],\n                                \"RegionId\":\"cn-shanghai-telecom-2\",\n                                \"NcName\":\"\",\n                                \"InstanceStatus\":\"\",\n                                \"CreateTime\":\"2020-09-12 22:33:08\",\n                                \"PodCountStat\":[\n                                    {\n                                        \"Name\":\"andorid\",\n                                        \"RunningCount\":7,\n                                        \"ProducedCount\":7,\n                                        \"Devices\":[\n                                            {\n                                                \"Name\":\"asp-yz-andorid-08102-zjzmcyaw-0\",\n                                                \"Status\":\"Running\",\n                                                \"Ports\":null\n                                            },\n                                            {\n                                                \"Name\":\"asp-yz-andorid-08102-zjzmcyaw-1\",\n                                                \"Status\":\"Running\",\n                                                \"Ports\":null\n                                            },\n                                            {\n                                                \"Name\":\"asp-yz-andorid-08102-zjzmcyaw-2\",\n                                                \"Status\":\"Running\",\n                                                \"Ports\":null\n                                            },\n                                            {\n                                                \"Name\":\"asp-yz-andorid-08102-zjzmcyaw-3\",\n                                                \"Status\":\"Running\",\n                                                \"Ports\":null\n                                            },\n                                            {\n                                                \"Name\":\"asp-yz-andorid-08102-zjzmcyaw-4\",\n                                                \"Status\":\"Running\",\n                                                \"Ports\":null\n                                            },\n                                            {\n                                                \"Name\":\"asp-yz-andorid-08102-zjzmcyaw-5\",\n                                                \"Status\":\"Running\",\n                                                \"Ports\":null\n                                            },\n                                            {\n                                                \"Name\":\"asp-yz-andorid-08102-zjzmcyaw-6\",\n                                                \"Status\":\"Running\",\n                                                \"Ports\":null\n                                            }\n                                        ]\n                                    },\n                                    {\n                                        \"Name\":\"aic-manager\",\n                                        \"RunningCount\":1,\n                                        \"ProducedCount\":1,\n                                        \"Devices\":[\n                                            {\n                                                \"Name\":\"asp-yz-aic-manager-08102-zjzmcyaw-0\",\n                                                \"Status\":\"Running\",\n                                                \"Ports\":null\n                                            }\n                                        ]\n                                    }\n                                ],\n                                \"AppVersionDescrip\":\"\"\n                            }\n                        ]\n                    }\n                ]\n            }\n        ]\n    }\n}",
  "RequestId": "473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E"
}

错误码

HTTP status code错误码错误信息描述
400MissingParameterThe input parameter that is mandatory for processing this request is not supplied.-
400NoPermissionPermission denied.没有足够的权限,请联系云账号管理员授予您相应权限。
400InvalidParameter.%sThe specified field %s invalid. Please check it again.-
400InvalidParameterThe errorMessage is %s. Please check it again.-
400ens.interface.errorAn error occurred while calling the API.-
400CallInterfaceCall Interface Happen Error.接口调用出错。

访问错误中心查看更多错误码。

变更历史

变更时间变更内容概要操作
2024-05-11OpenAPI 错误码发生变更、OpenAPI 入参发生变更查看变更详情
2023-12-21OpenAPI 描述信息更新、OpenAPI 错误码发生变更查看变更详情