调用DescribeClusterLogs查询指定集群日志。
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。
请求语法
GET /clusters/ClusterId/logs HTTP/1.1
Content-Type:application/json
请求参数
参数名称 | 类型 | 是否必选 | 示例 | 说明 |
---|---|---|---|---|
ClusterId | String | 是 | c106f377e16f34eb1808d6b9362c9**** |
集群ID。 |
响应体语法
HTTP/1.1 200 OK
Content-Type:application/json
[ {
"ID" : Long,
"cluster_id" : "String",
"cluster_log" : "String",
"created" : "String",
"updated" : "String"
} ]
响应参数
参数名称 | 类型 | 示例 | 说明 |
---|---|---|---|
Array |
日志列表。 |
||
ID | Long | 590749245 |
日志ID。 |
cluster_id | String | c23421cfa74454bc8b37163fd19af*** |
集群ID。 |
cluster_log | String | start to update cluster status to CREATE_COMPLETE |
日志内容。 |
created | String | 2020-09-11T10:11:51+08:00 |
日志产生时间。 |
updated | String | 2020-09-11T10:11:51+08:00 |
日志更新时间。 |
查询集群日志示例
请求示例
GET /clusters/c106f377e16f34eb1808d6b9362c9****/logs HTTP/1.1
Host:cs.aliyuncs.com
Content-Type:application/json
正常返回示例
XML
格式
HTTP/1.1 200 OK
Content-Type:application/xml
<DescribeClusterLogsResponse>
<ID>590749245</ID>
<cluster_id>c23421cfa74454bc8b37163fd19af***</cluster_id>
<cluster_log>start to update cluster status to CREATE_COMPLETE</cluster_log>
<created>2020-09-11T10:11:51+08:00</created>
<updated>2020-09-11T10:11:51+08:00</updated>
</DescribeClusterLogsResponse>
JSON
格式
HTTP/1.1 200 OK
Content-Type:application/json
[ {
"ID" : 590749245,
"cluster_id" : "c23421cfa74454bc8b37163fd19af***",
"cluster_log" : "start to update cluster status to CREATE_COMPLETE",
"created" : "2020-09-11T10:11:51+08:00",
"updated" : "2020-09-11T10:11:51+08:00"
} ]
错误码
访问错误中心查看更多错误码。