Child pages
  • WHM API 1 Functions - ipv6_disable_account
Skip to end of metadata
Go to start of metadata

Description

This function removes the IPv6 address from an account.

Notes:

  • When you disable IPv6 on an account, the system unbinds that IPv6 address from your server and the account loses the address. If you enable IPv6 on that account again, the system assigns it a different IPv6 address.
  • For all of cPanel & WHM's features to function properly on IPv6, the cpsrvd daemon must listen on IPv6 addresses. To enable this functionality, select On for the Listen on IPv6 Addresses setting in the System section of WHM's Tweak Settings interface (WHM >> Home >> Server Configuration >> Tweak Settings).

Examples 


 JSON API
https://hostname.example.com:2087/cpsess##########/json-api/ipv6_disable_account?api.version=1&user=username
 XML API
https://hostname.example.com:2087/cpsess##########/xml-api/ipv6_disable_account?api.version=1&user=username
 Command Line
whmapi1 ipv6_disable_account user=username


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

 Output (JSON)
{
    "metadata": {
        "version": 1,
        "reason": "OK",
        "result": 1,
        "command": "ipv6_disable_account"
    }
}
 Output (XML)
<result>
   <metadata>
      <version>1</version>
      <reason>OK</reason>
      <result>1</result>
      <command>ipv6_disable_account</command>
   </metadata>
</result>


Note:

Use WHM's API Shell interface (WHM >> Home >> Development >> API Shell) to directly test WHM API calls.

   

Parameters

ParameterTypeDescriptionPossible valuesExample
user
string

Required

The user's username.

A valid cPanel account name, or a comma-separated list of account names.username

 

Returns

ReturnTypeDescriptionPossible valuesExample
fail_cntintegerThe number of accounts for which the function failed to remove the IPv6 address.A valid integer.
0
failureshash

A hash of the function's failures.

This hash includes the used return.
 

used

string

The reason for the function's failures.

The function returns this value in the failures hash.

A valid string.
null