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.
Authorization Information
Each account has all the permissions required to call all APIs, but IAM users must be assigned the required permissions.
- If you are using role/policy-based authorization, see Permissions Policies and Supported Actions for details on the required permissions.
- If you are using identity policy-based authorization, the following identity policy-based permissions are required.
Action
Access Level
Resource Type (*: required)
Condition Key
Alias
Dependencies
live:domain:getCertificates
Read
-
-
-
-
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 |
Streaming domain name. |
|
offset |
No |
Integer |
Offset where the query starts. |
|
limit |
No |
Integer |
Number of records displayed on each page. Value range: 1 to 100. |
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 |
Number of query results. |
|
certificates_info |
Array of CertInfoResp objects |
Certificate information list. |
|
Parameter |
Type |
Description |
|---|---|---|
|
play_domain |
String |
Streaming domain name. |
|
project_id |
String |
Tenant ID. |
|
tenant_name |
String |
Tenant name. |
|
start_time |
String |
Time when the certificate becomes effective. The value is a UTC time in the format of YYYY-MM-DDTHH:mm:ssZ. |
|
expire_time |
String |
Time when the certificate expires. The value is a UTC time in the format of YYYY-MM-DDTHH:mm:ssZ. |
|
cert_type |
Integer |
Certificate type. 1: SM-series cryptographic certificates; 0: standard international certificate (default) |
|
gm_cert_type |
Integer |
SM-series cryptographic certificate type. 1: signature certificate; 2: encryption certificate |
|
source |
String |
Certificate source. user: self-owned certificate; scm: Huawei Cloud certificate manager |
|
cert_name |
String |
Name of the certificate from SCM. The value is empty for a self-owned certificate. |
|
cert_id |
String |
ID of the certificate from SCM. The value is empty for a self-owned certificate. |
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.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot