云服务器内容精选

  • 请求示例 HTTP的示例 POST /v1/accountservice/cert-manager/crls/action/batch-immediate-sync HTTP/1.1 Host: 192.168.1.125:18002 Content-Type: application/json Accept: application/json Accept-Language: en-US X-AC CES S-TOKEN: x-yyyyyy { "{ \n \"ids\":[ \"db27dbc7-a962-4e8a-b23d-bc5e9e3a6881\" ]\n }" }
  • 响应示例 返回状态码为200:设置认证源信息返回体, 同步操作为异步操作,结果需要通过查询list来获取同步结果 { "errcode": "0", "errmsg": " ", "successList": [ "db27dbc7-a962-4e8a-b23d-bc5e9e3a6881" ], "failList": [] } 返回状态码为207:设置认证源信息返回体, 同步操作为异步操作,结果需要通过查询list来获取同步结果,部分证书同步成功 { "errcode": "0", "errmsg": " ", "successList": [ "db27dbc7-a962-4e8a-b23d-bc5e9e3a6881" ], "failList": [ { "errcode": "0x00c8005a", "errmsg": "No rights.", "id": "db27dbc7-a962-4e8a-b23d-bc5e9e3a6333" } ] } 返回状态码为400:出现错误返回结果 HTTP/1.1 400 Bad Request Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive
  • 响应参数 返回状态码为200:操作成功 表3 CommonErrDto对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 errCode string 0~16个字符。 - 错误码。 "0x00000003" errMsg string 0~256个字符。 - 错误信息。 "No Rights" 返回状态码为400:校验异常 CommonErrDto对象的参数列表,详细请参见表3。
  • 响应示例 返回状态码为200:操作成功 HTTPS 200 OK Date: Thu,13 Sep 2023 10:00:00 GMT Server: example-server Content-Type: application/json { "errCode":"0", "errMsg":"" } 返回状态码为400:校验异常 HTTPS 400 Bad Requests Date: Thu,13 Sep 2023 10:00:00 GMT Server: example-server Content-Type: application/json { "errCode": "0x00c80035", "errMsg": "Invalid parameter deviceList." }
  • 请求示例 HTTP的示例 POST /controller/campus/v2/certification/tasks HTTP/1.1 Host: 192.168.1.125:18002 Content-Type: application/json Accept: application/json Accept-Language: en-US X-ACCESS-TOKEN: x-yyyyyy { "deviceList" : ["936815c9-f7b3-48ab-bd1a-475cb8b1f092"], "certId" : "ThirdPartyPortalServer_31fb59ef-5b64-43b2-9491-81c90dc818ff" }
  • 响应示例 返回状态码为200:查询成功,响应体参考QueryDeviceCertificateResponseDto。 HTTP/1.1 200 OK Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive { "errcode" : "0", "errmsg" : "", "data" : { "deviceId" : "00000000-0000-0000-0000-000000000000", "deviceEsn" : "esn", "certificationStatus" : "0", "issuer" : "Huawei Equipment CA", "issuerDatetime" : 1557187200000, "expirationDatetime" : 1558656000000, "failureReason" : "在线更新设备证书失败" } } 返回状态码为400:校验异常,无响应体。 HTTP/1.1 400 Bad Request Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive 返回状态码为500:内部错误,无响应体。 HTTP/1.1 500 Internal Server Error Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive
  • 响应参数 返回状态码为200:查询成功,响应体参考QueryDeviceCertificateResponseDto。 表2 QueryDeviceCertificateResponseDto对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 errcode string 1~64个字符。 - 错误码。 "0" errmsg string 1~64个字符。 - 错误信息。 "" data REFERENCE 详细请参见表3。 - - 表3 DeviceCertificateDto对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 deviceId string 1~64个字符。 - 设备ID。 "00000000-0000-0000-0000-000000000000" deviceEsn string 1~64个字符。 - 设备ESN。 "esn" certificationStatus string 1~64个字符。 - 证书状态(0:初始化,1:申请中,2:申请成功,3:申请失败,4:等待中)。 "0" issuer string - - 证书授权者("Huawei Equipment CA","Huawei Switch & Enterprise Communications Product Line CA","Other 3rd Issuer CA")。 "Huawei Equipment CA" issuerDatetime int64 - - 发行时间(UTC)。 1557187200000 expirationDatetime int64 - - 到期时间(UTC)。 1558656000000 failureReason string 0~256个字符。 - 失败原因。 "在线更新设备证书失败" 返回状态码为400:校验异常,无响应体。 详细信息请参见实际响应消息体。 返回状态码为500:内部错误,无响应体。 详细信息请参见实际响应消息体。
  • 请求示例 HTTP的示例 GET /controller/campus/v1/oamservice/certification/device/certificate?deviceId=fbb684c8-0d37-496f-bafa-4b06d5151e2e HTTP/1.1 Host: 192.168.1.125:18002 Content-Type: application/json Accept: application/json Accept-Language: en-US X-ACCESS-TOKEN: x-yyyyyy
  • 响应参数 返回状态码为200:操作成功 表3 QueryImportTaskOutput对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 errCode string 0~64个字符。 - 错误码。 "0" errMsg string 0~256个字符。 - 错误信息。 "No Rights" totalRecords int32 [0-200000] - 任务总数 10 data ARRAY_REFERENCE 0-100个列表项,详细请参见表4。 证书导入任务信息 - 表4 DeviceCertImportTaskDetail对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 deviceId string 36个字符。 - 设备ID "936815c9-f7b3-48ab-bd1a-475cb8b1f092" deviceName string 0~64个字符。 - 设备名称 "Device_AP" esn string 0~64个字符。 - 设备ESN "2102353GSG10LA002185" certFileName string 0~64个字符。 - 证书文件名称 "ca.pem" deviceModel string 0~64个字符。 - 设备型号 "AP4050DN" dueDate string 0~36个字符。 - 过期时间(示例为UTC时间,格式YYYY-MM-DD HH:MM:SS) "2035-04-17 14:47:30" status int32 [-1-2] - 证书更新任务状态(-1:失败,0:成功,1:初始化,2:执行中) 0 failureCause string 0~256个字符。 - 失败原因 "No Rights" 返回状态码为400:查询异常 CommonErrDto对象的参数列表,详细请参见表3。
  • 响应示例 返回状态码为200:操作成功 HTTP/1.1 200 OK Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive { "errCode" : "0", "errMsg" : "No Rights", "totalRecords" : 10, "data" : [ { "deviceId" : "936815c9-f7b3-48ab-bd1a-475cb8b1f092", "deviceName" : "Device_AP", "esn" : "2102353GSG10LA002185", "certFileName" : "ca.pem", "deviceModel" : "AP4050DN", "dueDate" : "2035-04-17 14:47:30", "status" : 0, "failureCause" : "No Rights" } ] } 返回状态码为400:查询异常 HTTP/1.1 400 Bad Request Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive { "errCode" : "0x00000003", "errMsg" : "No Rights" }
  • 请求示例 HTTP的示例 POST /controller/campus/v2/certification/tasks/action/status-query HTTP/1.1 Host: 192.168.1.125:18002 Content-Type: application/json Accept: application/json Accept-Language: en-US X-ACCESS-TOKEN: x-yyyyyy { "pageIndex" : 1, "pageSize" : 10, "siteId" : "595ffa80-3f6a-42b2-a79f-3e54dd8d121a", "keyword" : "DeviceName", "importTaskStatus" : [-1,0,1,2], "dueTimeBegin" : 1697457554059, "dueTimeEnd" : 1697457554059, "sortField" : "esn" }
  • 请求示例 HTTP的示例 POST /controller/campus/v1/oamservice/certification/device/certificate/batch-query HTTP/1.1 Host: 192.168.1.125:18002 Content-Type: application/json Accept: application/json Accept-Language: en-US X-ACCESS-TOKEN: x-yyyyyy { "deviceIds" : [ "57f879c7-7f6a-4d3a-88af-bf2585cb61e0" ] }
  • 响应示例 返回状态码为200:查询成功,响应体参考BatchQueryDeviceCertificateResponseDto。 HTTP/1.1 200 OK Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive { "errcode" : "0", "errmsg" : "", "data" : [ { "deviceId" : "00000000-0000-0000-0000-000000000000", "deviceEsn" : "esn", "certificationStatus" : "0", "issuer" : "Huawei Equipment CA", "issuerDatetime" : 1557187200000, "expirationDatetime" : 1558656000000, "failureReason" : "在线更新设备证书失败" } ] } 返回状态码为400:校验异常,无响应体。 HTTP/1.1 400 Bad Request Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive 返回状态码为500:内部错误,无响应体。 HTTP/1.1 500 Internal Server Error Date: Sun,16 Feb 2025 10:00:00 GMT Server: example-server Content-Type: application/json;charset=UTF-8 Content-Length: 250 Connection: keep-alive
  • 响应参数 返回状态码为200:查询成功,响应体参考BatchQueryDeviceCertificateResponseDto。 表3 BatchQueryDeviceCertificateResponseDto对象的参数列表 参数名称 类型 参数值域 默认值 参数说明 参数示例 errcode string 1~64个字符。 - 错误码。 "0" errmsg string 0~64个字符。 - 错误信息。 "" data ARRAY_REFERENCE 0-100个列表项,详细请参见表3。 结果返回列表 - 返回状态码为400:校验异常,无响应体。 详细信息请参见实际响应消息体。 返回状态码为500:内部错误,无响应体。 详细信息请参见实际响应消息体。
  • 请求示例 HTTP的示例 GET /v1/accountservice/cert-manager/crls?pageIndex=1&pageSize=20&keyWord=com HTTP/1.1 Host: 192.168.1.125:18002 Content-Type: application/json Accept: application/json Accept-Language: en-US X-ACCESS-TOKEN: x-yyyyyy