Call the OpenHttps operation to enable HTTPS.

Note
  • To ensure data security, we recommend that you enable HTTPS.
  • Except for the 8.5 version, 7.16 version, , make sure that you have purchased a coordinator node before enabling HTTPS.

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 headers

This operation uses only common request headers. For more information, see Common request headers.

Request syntax

POST /openapi/instances/{InstanceId}/actions/open-https HTTP/1.1

Request parameters

Parameter Type Position Required Example Description
InstanceId String Path Yes es-cn-n6w1o1x0w001c****

The ID of the instance.

clientToken String Query No 5A2CFF0E-5718-45B5-9D4D-70B3FF****

The client token that is used to ensure the idempotence of the request. You can use the client to generate the token, but you must make sure that the token is unique among different requests. The token can contain only ASCII characters and cannot exceed 64 characters in length.

Response parameters

Parameter Type Example Description
Result Boolean true

Output

  • true: HTTPS is enabled.
  • false: The HTTPS protocol fails to be enabled.
RequestId String F99407AB-2FA9-489E-A259-40CF6DCC****

The request ID.

Examples

Sample requests

POST /openapi/instances/es-cn-n6w1o1x0w001c****/actions/open-https HTTP/1.1
Common request header

Sample success responses

JSON format

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

{
  "Result" : true,
  "RequestId" : "5A5D8E74-565C-43DC-B031-29289FA9****"
}

Error codes

HttpCode Error code Error message Description
400 InstanceActivating Instance is activating. The instance is currently in effect.
400 InstanceNotFound The instanceId provided does not exist. The error message returned because the instance cannot be found. Check the instance status.

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