Replaces an additional certificate for an HTTPS listener.

Description

The UpdateAdditionalCertificateWithListener operation is used to replace an additional certificate. You can call this operation when you want to replace an expired additional certificate with a new additional certificate without changing the associated domain name.

  • UpdateAdditionalCertificateWithListener is an asynchronous operation. After you send a request, the system returns a request ID, but the operation is still being performed in the system background. You can call the ListListenerCertificates operation to query the state of the additional certificate that is associated with an HTTP listener:
    • If the certificate that you want to replace is in the updating state, it indicates that the additional certificate is being replaced for the HTTP listener. In this case, you can perform only query operations.
    • If the replacement certificate is in the active state, it indicates that the replacement operation is complete and the replacement certificate is associated with the HTTP listener.
  • The UpdateAdditionalCertificateWithListener operation cannot be called repeatedly for the same Global Accelerator (GA) instance within a specific period of time.

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 UpdateAdditionalCertificateWithListener

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

RegionId String Yes cn-hangzhou

The ID of the region where the GA instance is deployed. Set the value to cn-hangzhou.

DryRun Boolean No false

Specifies whether to only precheck the request. Default value: false. Valid values:

  • true: prechecks the request without performing this operation. The system checks the required parameters, request syntax, and limits. If the request fails the precheck, an error message is returned. If the request passes the precheck, the DryRunOperation error code is returned.
  • false: sends the request. If the request passes the precheck, a 2xx HTTP status code is returned and the operation is performed.
ClientToken String No 123e4567-e89b-12d3-a456-426655440000

The client token that is used to ensure the idempotence of the request.

You can use the client to generate the value, but you must make sure that it is unique among different requests. The ClientToken value contain only ASCII characters.

Note If you do not set this parameter, the system sets ClientToken to the value of RequestId. The value of RequestId may be different for each API request.
AcceleratorId String Yes ga-bp1odcab8tmno0hdq****

The ID of the GA instance.

ListenerId String Yes lsr-bp1bpn0kn908w4nbw****

The ID of the listener. Only HTTPS listeners are supported.

Domain String Yes example.com

The domain name associated with the additional certificate that you want to replace.

CertificateId String Yes 6092**-cn-hangzhou

The ID of the replacement certificate.

Response parameters

Parameter Type Example Description
RequestId String 6FEA0CF3-D3B9-43E5-A304-D217037876A8

The ID of the region.

ListenerId String lsr-bp1bpn0kn908w4nbw****

The ID of the listener.

Examples

Sample requests

http(s)://[Endpoint]/?Action=UpdateAdditionalCertificateWithListener
&RegionId=cn-hangzhou
&DryRun=false
&ClientToken=123e4567-e89b-12d3-a456-426655440000
&AcceleratorId=ga-bp1odcab8tmno0hdq****
&ListenerId=lsr-bp1bpn0kn908w4nbw****
&Domain=example.com
&CertificateId=6092**-cn-hangzhou
&<Common request parameters>

Sample success responses

XML format

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

<UpdateAdditionalCertificateWithListenerResponse>
    <RequestId>6FEA0CF3-D3B9-43E5-A304-D217037876A8</RequestId>
    <ListenerId>lsr-bp1bpn0kn908w4nbw****</ListenerId>
</UpdateAdditionalCertificateWithListenerResponse>

JSON format

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

{
  "RequestId" : "6FEA0CF3-D3B9-43E5-A304-D217037876A8",
  "ListenerId" : "lsr-bp1bpn0kn908w4nbw****"
}

Error codes

HttpCode Error code Error message Description
400 NotExist.Accelerator The accelerated instance does not exist. The error message returned because the specified GA instance does not exist.
400 StateError.Accelerator The state of the accelerated instance is invalid. The error message returned because the specified GA instance is in an invalid state.
400 NotExist.Listener The listener does not exist. The error message returned because the specified listener does not exist.
400 NotActive.Listener The state of the listener is not active. The error message returned because the specified listener is unstable.

For a list of error codes, see Service error codes.