Delete Accelerated Domain Name

Last updated: 2018-08-13 10:11:07

API Description

This API (DeleteDsaHost) is used to delete DSA service for the specified accelerated domain names.
Domain name for API request: dsa.api.qcloud.com

1) You can only delete DSA service for one domain name at a time with this API;
2) This API only applies to the deactivated domain names;
3) A maximum of 100 calls to this API are allowed per minute. If the limit is exceeded, an error is returned.

Input Parameters

The following request parameter list only provides API request parameters. Common request parameters are required when the API is called. For more information, please see Common Request Parameters page. The Action field for this API is DeleteDsaHost.

Parameter Name Required Type Description
hostId Yes Unsigned The ID of the domain name after it is connected to DSA. You can obtain the ID through the API Query Domain Name List

Output Parameters

Parameter Name Type Description
code Int Common error code; 0: Successful; other values: Failed. For more information, please see Common Error Codes on the Error Codes page.
message String Module error message description depending on API
codeDesc String Error message or error code at business side.

Example

1. Configuration example

Delete the DSA service for the domain name dsa.qcloud.com:

host:dsa.qcloud.com
hostId:1234

2. GET request

For a GET request, all the parameters are required to be appended to the URL:

https://dsa.api.qcloud.com/v2/index.php?
Action=DeleteDsaHost   
&SecretId=XXXXXXXXXXXXXXXXXXXXXXXXX   
&Timestamp=1462440051   
&Nonce=123456789   
&Signature=XXXXXXXXXXXXXXXXXXXXXXXXXX  
&hostId=1234

3. POST request

For a POST request, the parameters are input in HTTP Request-body. The request address is:

https://dsa.api.qcloud.com/v2/index.php

Formats such as form-data and x-www-form-urlencoded are supported for the parameters. The array of parameters is as follows:

array (
  'Action' => 'DeleteDsaHost',
  'SecretId' => 'SecretId',
  'Timestamp' => 1462782282,
  'Nonce' => 123456789,
  'Signature' => 'Signature',
  'hostId' => 1234
)

4 Example of returned result

Deleted successfully

{
    "code": 0,
    "message": "",
    "codeDesc": "Success",
}

Deletion failed

{
    "code": 4000,
    "message": "(2005) The requested domain name has been deactivated.",
    "codeDesc": "InvalidParameter"
}