You can call the UploadCACertificate API to upload a CA certificate.

You can only upload one CA certificate each time. After a CA certificate is successfully uploaded, the certificate ID, name, and fingerprint are returned.

Debug

Click here to perform a debug operation in OpenAPI Explorer and automatically generate an SDK code example.

Request parameters

Name Type Required? Example value Description
Action String Yes UploadCACertificate

The action to perform. Valid value is UploadCACertificate.

RegionId String Yes cn-hangzhou

The region to which the CA certificate belongs.

You can query the region ID by calling the DescribeRegions API.

CACertificate String Yes test

The content of the CA certificate to be uploaded

CACertificateName String No mycacert01

The name of the CA certificate

ResourceGroupId String No rg-atstuj3rtoptyui

The ID of the enterprise resource group

Response parameters

Name Type Example value Description
CACertificateId String 139a00604ad-cn-east-hangzhou-01

The ID of the CA certificate

CACertificateName String mycacert01

The name of the CA certificate

Fingerprint String 02:DF:AB:ED

The fingerprint of the CA certificate

CommonName String .example.com

The domain name of the CA certificate

CreateTime String 2017-08-31T02:49:05Z

The time at which the CA certificate is uploaded

CreateTimeStamp Long 1504147745000

The timestamp indicating when the CA certificate is uploaded

ExpireTime String 2024-11-21T06:04:25Z

The time at which the CA certificate expires

ExpireTimeStamp Long 1732169065000

The timestamp indicating when the CA certificate expires.

RequestId String 365F4154-92F6-4AE4-92F8-7FF34B540710

The ID of the request

ResourceGroupId String rg-atstuj3rtoptyui

The ID of the enterprise resource group

Examples

Request example


https://slb.aliyuncs.com/
&Action=UploadCACertificate
&RegionId=cn-hangzhou
&CACertificate=test
&CACertificateName=mycacert01
&<CommonParameters>

Normal response examples

XML format

<UploadCACertificateResponse>
  <RequestId>365F4154-92F6-4AE4-92F8-7FF34B540710</RequestId>
  <ServerCertificateId>idkp-234-cn-test-02</ServerCertificateId>
  <ServerCertificateName>mycacert01</ServerCertificateName>
  <Fingerprint>02:DF:AB:ED</Fingerprint>
</UploadCACertificateResponse>

JSON format

{
	"ServerCertificateId":"idkp-234-cn-test-02",
	"RequestId":"365F4154-92F6-4AE4-92F8-7FF34B540710",
	"ServerCertificateName":"mycacert01",
	"Fingerprint":"02:DF:AB:ED"
}

Error response example

JSON format

{
	"Message":"The specified parameter is not valid.",
	"RequestId":"0669D684-69D8-408E-A4FA-B9011E0F4E66",
	"HostId":"slb-pop.aliyuncs.com",
	"Code":"InvalidParameter"
}

Error codes

Click here to view the error codes.