Uploads a certificate.

Limits

You can call this operation up to 10 times per second per account. If the number of the calls per second exceeds the limit, throttling is triggered. As a result, your business may be affected. We recommend that you take note of the limit when you call this operation.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes CreateUserCertificate

The operation that you want to perform. Set the value to CreateUserCertificate.

Name String Yes auto-test-AXX

The name of the certificate. The name can contain up to 128 characters in length. The name can contain all types of characters, such as letters, digits, and underscores (_).

Note The name must be unique within an Alibaba Cloud account.
Cert String Yes ---BEGIN CERTIFICATE----- MIIF...... -----END CERTIFICATE-----

The CA certificate in the PEM format.

Key String Yes ---BEGIN RSA PRIVATE KEY----- MII.... -----END RSA PRIVATE KEY-----

The private key in the PEM format.

SourceIp String No 1.2.XX.XX

The source IP address of the request.

Lang String No zh

The language of the content within the request and response. Valid values:

  • zh: Chinese
  • en: English

Default value: zh.

Response parameters

Parameter Type Example Description
CertId Long 132

The ID of the certificate.

RequestId String 15BE9F82-71D1-4A83-9002-381C0BE2A889

The ID of the request.

Examples

Sample requests

http(s)://[Endpoint]/?Action=CreateUserCertificate
&Name=auto-test-AXX
&Cert=---BEGIN CERTIFICATE----- MIIF...... -----END CERTIFICATE-----
&Key=---BEGIN RSA PRIVATE KEY----- MII.... -----END RSA PRIVATE KEY-----
&SourceIp=1.2.XX.XX
&Lang=zh
&Common request parameters

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<CreateUserCertificateResponse>
    <CertId>321</CertId>
    <RequestId>15BE9F82-71D1-4A83-9002-381C0BE2A889</RequestId>
</CreateUserCertificateResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "CertId" : 321,
  "RequestId" : "15BE9F82-71D1-4A83-9002-381C0BE2A889"
}

Error codes

For a list of error codes, visit the API Error Center.