调用DescribeApplication查询应用的基本属性、资源和容器状态列表。
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。
授权信息
下表是API对应的授权信息,可以在RAM权限策略语句的Action
元素中使用,用来给RAM用户或RAM角色授予调用此API的权限。具体说明如下:
- 操作:是指具体的权限点。
- 访问级别:是指每个操作的访问级别,取值为写入(Write)、读取(Read)或列出(List)。
- 资源类型:是指操作中支持授权的资源类型。具体说明如下:
- 对于必选的资源类型,用背景高亮的方式表示。
- 对于不支持资源级授权的操作,用
全部资源
表示。
- 条件关键字:是指云产品自身定义的条件关键字。
- 关联操作:是指成功执行操作所需要的其他权限。操作者必须同时具备关联操作的权限,操作才能成功。
操作 | 访问级别 | 资源类型 | 条件关键字 | 关联操作 |
---|---|---|---|---|
ens:DescribeApplication | get | *全部资源 * |
| 无 |
请求参数
名称 | 类型 | 必填 | 描述 | 示例值 |
---|---|---|---|---|
AppId | string | 是 | 应用 ID,可通过调用 ListApplications 接口获取。 | a2bac6f4-75dc-455e-8389-2dc8e47526d3 |
AppVersions | string | 否 | 应用的业务服务版本号。支持多选,以","分割;输入 All,输出所有版本数据。默认只输出稳定版版本号的关联数据。 | v1,v2 |
Level | string | 否 | 应用边缘资源的区域统计级别。枚举类型,取值范围:
默认 National。 | National |
OutDetailStatParams | string | 否 | 是否输出统计资源实例/容器 Pod 等维度的信息。Json 的字符串格式。默认输出所有信息。 | {\"appInfo\":true,\"detailStat\": true, \"appVersionStat\": true, \"districtStat\":true ,\"instanceStat\": true, \"podCountStat\": true} |
ResourceSelector | string | 否 | 资源筛选条件。 | [{\"regionCode\": \"cn-wuxi-telecom_unicom_cmcc-3\", \"ispCode\": \"telecom\", \"count\": 2 },{ \"regionCode\": \"cn-shanghai-cmcc\", \"count\": 4 }] |
返回参数
示例
正常返回示例
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 | 错误码 | 错误信息 | 描述 |
---|---|---|---|
400 | MissingParameter | The input parameter that is mandatory for processing this request is not supplied. | - |
400 | NoPermission | Permission denied. | 没有足够的权限,请联系云账号管理员授予您相应权限。 |
400 | InvalidParameter.%s | The specified field %s invalid. Please check it again. | - |
400 | InvalidParameter | The errorMessage is %s. Please check it again. | - |
400 | ens.interface.error | An error occurred while calling the API. | - |
400 | CallInterface | Call Interface Happen Error. | 接口调用出错。 |
访问错误中心查看更多错误码。
变更历史
变更时间 | 变更内容概要 | 操作 |
---|---|---|
2024-05-11 | OpenAPI 错误码发生变更、OpenAPI 入参发生变更 | 查看变更详情 |
2023-12-21 | OpenAPI 描述信息更新、OpenAPI 错误码发生变更 | 查看变更详情 |