Querying HTTPS Certificate Information
Function
This API is used to query HTTPS certificate information based on the project ID and domain name.
Calling Method
For details, see Calling APIs.
URI
GET /v2/{project_id}/certificates
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| project_id | Yes | String | Project ID. For details about how to obtain the project ID, see Obtaining a Project ID. |
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| play_domain | No | String | Definition Streaming domain name. Constraints N/A Range Length: 1 to 255 characters Default Value N/A |
| offset | No | Integer | Definition Offset where the query starts. Constraints N/A Value range: 0~2147483647 Default value: 0 |
| limit | No | Integer | Definition Number of records on each page. Constraints N/A Value range: 1~100 Default value: 10 |
Request Parameters
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| X-Auth-Token | Yes | String | User token. This parameter is mandatory when token authentication is used. The token can be obtained by calling the IAM API used to obtain a user token. The value of X-Subject-Token in the response header is the user token. |
| Authorization | No | String | Authentication information. This parameter is mandatory for AK/SK authentication. |
| X-Sdk-Date | No | String | Time when the request is sent. This parameter is mandatory for AK/SK authentication. |
| X-Project-Id | No | String | Project ID. This parameter is mandatory for AK/SK authentication. |
Response Parameters
Status code: 200
| Parameter | Type | Description |
|---|---|---|
| total | Number | Definition Total number of records. Value range: 0~128 |
| certificates_info | Array of CertInfoResp objects | Definition Certificate information. |
| Parameter | Type | Description |
|---|---|---|
| play_domain | String | Definition Streaming domain name. Range Length: 1 to 255 characters |
| project_id | String | Definition Tenant ID. Range Length: 1 to 64 characters |
| tenant_name | String | Definition Tenant name. Range Length: 1 to 128 characters |
| start_time | String | Definition Time when the certificate becomes effective. Range The value is a UTC time in the format of YYYY-MM-DDTHH:mm:ssZ. |
| expire_time | String | Definition Time when the certificate expires. Range The value is a UTC time in the format of YYYY-MM-DDTHH:mm:ssZ. |
| cert_type | Integer | Definition Certificate type. Range |
| gm_cert_type | Integer | Definition SM certificate type. Range |
| source | String | Definition Certificate source. Range |
| cert_name | String | Definition Name of the certificate from scm. The value is empty for a self-owned certificate. Range Length: 0 to 64 characters |
| cert_id | String | Definition ID of the certificate from scm. The value is empty for a self-owned certificate. Range Length: 0 to 64 characters |
Status code: 400
| Parameter | Type | Description |
|---|---|---|
| error_code | String | Error code. |
| error_msg | String | Error description. |
Example Requests
GET https://{endpoint}/v2/70b76xxxxxx34253880af501cdxxxxxx/certificates?play_domian=play.example.huawei.com Example Responses
Status code: 200
HTTPS certificate information queried.
{
"total" : 2,
"certificates_info" : [ {
"play_domain" : "play.example.huawei.com",
"project_id" : "70b76xxxxxx34253880af501cdxxxxxx",
"tenant_name" : "huaweiTest",
"start_time" : "2021-03-03T01:34:01Z",
"expire_time" : "2022-04-04T01:34:01Z"
}, {
"play_domain" : "play.example.hwcloud.com",
"project_id" : "70b76xxxxxx34253880af505cdxxxxxx",
"tenant_name" : "huaweiTest001",
"start_time" : "2021-02-03T01:34:01Z",
"expire_time" : "2022-05-04T01:34:01Z"
} ]
} Status code: 400
Invalid parameter.
{
"error_code" : "LIVE.100011001",
"error_msg" : "Request Illegal",
"request_id" : "xxxx-xxxx-xxxx-xxxx"
} Status Codes
| Status Code | Description |
|---|---|
| 200 | HTTPS certificate information queried. |
| 400 | Invalid parameter. |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.