更新时间:2023-11-29 GMT+08:00
分享

查询节点证书

功能介绍

查询边缘节点上的应用证书和设备证书。

调试

您可以在API Explorer中调试该接口,支持自动认证鉴权。API Explorer可以自动生成SDK代码示例,并提供SDK代码示例调试功能。

URI

GET /v2/{project_id}/edgemgr/nodes/{node_id}/certs

表1 路径参数

参数

是否必选

参数类型

描述

project_id

String

项目ID

node_id

String

节点ID

表2 Query参数

参数

是否必选

参数类型

描述

limit

Integer

查询返回记录的数量限制

offset

Integer

偏移量,表示查询该偏移量后面的记录

请求参数

表3 请求Header参数

参数

是否必选

参数类型

描述

Content-Type

String

消息体的类型(格式),默认取值为“application/json”

X-Auth-Token

String

用户Token。 通过调用IAM服务获取用户Token接口获取(响应消息头中X-Subject-Token的值)。

ief-instance-id

String

铂金版实例ID,专业版实例为空值

响应参数

状态码: 200

表4 响应Body参数

参数

参数类型

描述

count

Integer

节点上已关联的应用证书和设备证书的数目

node_certs

Array of NodeCert objects

节点上的证书列表

表5 NodeCert

参数

参数类型

描述

id

String

证书id

name

String

证书名称

description

String

证书的描述

created_at

String

证书的创建时间

node_id

String

节点id

type

String

证书类型,包含:

  • system:创建节点时会默认创建一套系统证书

  • application:应用证书

  • device:设备证书

serial_num

String

证书序列号

请求示例

响应示例

状态码: 200

查询成功

{
  "count" : 3,
  "node_certs" : [ {
    "description" : "test device cert",
    "created_at" : "2020-03-31T14:52:25.405025+08:00",
    "serial_num" : null,
    "node_id" : "f66bfc52-db62-4701-b93d-50843262cbfb",
    "type" : "device",
    "id" : "104344d9-3e76-4ddc-8a90-ac601d812251",
    "name" : "device-cert"
  }, {
    "description" : "",
    "created_at" : "2020-03-31T07:32:36.992162+08:00",
    "serial_num" : "",
    "node_id" : "f66bfc52-db62-4701-b93d-50843262cbfb",
    "type" : "system",
    "id" : "54c66dbf-d0e9-4c25-8843-146199e434ea",
    "name" : "sys-cert"
  }, {
    "description" : "test application cert",
    "created_at" : "2020-03-31T14:50:28.544569+08:00",
    "serial_num" : null,
    "node_id" : "f66bfc52-db62-4701-b93d-50843262cbfb",
    "type" : "application",
    "id" : "65e8cb68-5b5d-4777-984c-94d16b39753a",
    "name" : "app-cert"
  } ]
}

状态码

状态码

描述

200

查询成功

错误码

请参见错误码

分享:

    相关文档

    相关产品