Deletes a server certificate.
Note You cannot delete server certificates that are in use.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | DeleteServerCertificate |
The operation that you want to perform. Set the value to DeleteServerCertificate. |
ServerCertificateId | String | Yes | 123157xxxxxxx_166f8204689_1714763408_7099******* |
The ID of the server certificate. |
RegionId | String | Yes | cn-hangzhou |
The region where the Server Load Balancer (SLB) instance is created. You can call the DescribeRegions operation to query region IDs. |
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
RequestId | String | CEF72CEB-54B6-4AE8-B225-F876FF7BA984 |
The ID of the request. |
Examples
Sample request
http(s)://[Endpoint]/? Action=DeleteServerCertificate
&ServerCertificateId=123157xxxxxxx_166f8204689_1714763408_7099*******
&<Common request parameters>
Sample success responses
XML
format
<DeleteServerCertificateResponse>
<RequestId>CEF72CEB-54B6-4AE8-B225-F876FF7BA984</RequestId></DeleteServerCertificateResponse>
JSON
format
{
"RequestId":" CEF72CEB-54B6-4AE8-B225-F876FF7BA984"
}
Error codes
HttpCode | Error code | Error message | Description |
---|---|---|---|
400 | CertificateAndPrivateKeyIsRefered | The specified certificate is bound to listeners. You cannot delete it. | The error message returned because the server certificate cannot be deleted when the certificate is associated with a listener. |
For a list of error codes, visit the API Error Center.