- Created by Documentation, last modified on Oct 05, 2018
disable_authentication_provider
disable_failing_authentication_providers
enable_authentication_provider
get_available_authentication_providers
get_provider_client_configurations
get_provider_configuration_fields
get_provider_display_configurations
get_users_authn_linked_accounts
set_provider_client_configurations
set_provider_display_configurations
twofactorauth_generate_tfa_config
twofactorauth_get_user_configs
cpgreylist_is_server_netblock_trusted
cpgreylist_list_entries_for_common_mail_provider
cpgreylist_load_common_mail_providers_config
cpgreylist_save_common_mail_providers_config
cpgreylist_trust_entries_for_common_mail_provider
cpgreylist_untrust_entries_for_common_mail_provider
create_cpgreylist_trusted_host
delete_cpgreylist_trusted_host
Description
This function deletes a DNS zone.
Important:
- The WHM API 1 adddns function adds an XDNS entry for a domain in the following locations:
- The
/var/cpanel/users/USER
file, whereUSER
represents the domain's owner. - The
/etc/vdomainaliases/DOMAIN
directory, whereDOMAIN
represents the new zone's domain. - The
/etc/vfilters/DOMAIN
directory, whereDOMAIN
represents the new zone's domain.
- The
- This function does not automatically delete these entries. You must manually delete these entries, or you cannot use this domain as a value in other API functions.
- You cannot delete other DNS zones that reside on Write-only servers in a DNS cluster.
Important:
DNS
role, the system disables this function. For more information, read our How to Use Server Profiles documentation.Examples
https://hostname.example.com:2087/cpsess##########/json-api/killdns?api.version=1&domain=example.com
https://hostname.example.com:2087/cpsess##########/xml-api/killdns?api.version=1&domain=example.com
whmapi1 killdns domain=example.com
Notes:
- You must URI-encode values.
- For more information and additional output options, read our Guide to WHM API 1 documentation or run the
whmapi1 --help
command. If you run CloudLinux™, you must use the full path of the
whmapi1
command:/usr/local/cpanel/bin/whmapi1
{ "metadata": { "version": 1, "reason": "Zones Removed", "output": { "raw": "example.com => deleted from example. \n" }, "result": 1, "command": "killdns" } }
<result> <metadata> <version>1</version> <reason>Zones Removed</reason> <output> <raw>example.com => deleted from example.</raw> </output> <result>1</result> <command>killdns</command> </metadata> </result>
Note:
Parameters
Parameter | Type | Description | Possible values | Example |
---|---|---|---|---|
| string | Required The zone record's domain. | A valid domain name on the server. | example.com |
Returns
This function only returns metadata.
Function information
API Version:
Available in:
WHM 11+
Methods:
GET, POST
Required Parameters:
domain
Return Formats:
About WHM API 1
WHM API 1 performs functions and accesses data in WHM.
Notes:
- Some functions and parameters may require that you authenticate as the
root
user. - You must use the appropriate WHM ports (
2086
or2087
) to call WHM API functions.
Find a function
Related functions
-
Page:WHM API 1 Sections - DNS — DNS functions allow you to manage your server's DNS zones and records.
-
Page:WHM API 1 Functions - adddns — This function creates a DNS zone.
-
Page:WHM API 1 Functions - addzonerecord — This function adds a DNS zone record.
-
Page:WHM API 1 Functions - addzonerecord - Reverse DNS — This function uses PTR records to add reverse DNS functionality.
-
Page:WHM API 1 Functions - dumpzone — This function returns a domain's DNS zone configuration.