Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

 

Description

Excerpt

This function sets a reseller's bandwidth and disk quotas.

Panel
bgColor#F2F2F2
borderStylenone

Examples 


Panel
bgColor#FFFFFF
borderStylenone
Expand
titleJSON API
Code Block
languagexml
https://hostname.example.com:2087/cpsess##########/json-api/setresellerlimits?api.version=1&user=username&enable_account_limit=0
Expand
titleXML API
Code Block
languagexml
https://hostname.example.com:2087/cpsess##########/xml-api/setresellerlimits?api.version=1&user=username&enable_account_limit=0
Expand
titleCommand Line
Code Block
languagebash
whmapi1 setresellerlimits user=username enable_account_limit=0

Include Page
_WHMAPI1CLINote
_WHMAPI1CLINote

Expand
titleOutput (JSON)
Code Block
languagetext
linenumberstrue
{
  "metadata": {
    "version": 1,
    "reason": "OK",
    "result": 1,
    "command": "setresellerlimits"
  }
}
Expand
titleOutput (XML)
Code Block
languagetext
linenumberstrue
<result>
    <metadata>
        <version>1</version>
        <reason>OK</reason>
        <result>1</result>
        <command>setresellerlimits</command>
    </metadata>
</result>

Include Page
LIB:_WHMAPIShellNote
LIB:_WHMAPIShellNote

   

Parameters

ParameterTypeDescriptionPossible valuesExample
userstring

Required

The reseller's username.

A valid username on the server.username
enable_account_limitBoolean

Whether to limit the reseller's total number of accounts.

Note
titleNote:

Use this parameter with the account_limit parameter. 

This parameter defaults to 0.

  • 1 — Limit.
  • 0 — Do not limit.
1
account_limitinteger

The reseller's maximum total number of accounts.

Warning
titleImportant:

The system only enforces this maximum if you set the enable_account_limit value to 1.

A positive integer that represents the maximum number of accounts that the reseller may access.

10

enable_resource_limits

Boolean

Whether to limit the reseller's resources.

Note
titleNote:

Use this parameter with the bandwidthlimit, diskspace_limit, enable_overselling, enable_overselling_bandwidth, enable_overselling_diskspace, enable_package_limits, and enable_package_limit_numbers parameters. 

This parameter defaults to 0.

  • 1 — Limit resources.
  • 0 — Do not limit resources.
1
bandwidth_limitinteger

The reseller's total bandwidth limit.

Warning
titleImportant:

The system only enforces this limit if you set the enable_resource_limits value to 1.

  • A positive integer that represents the reseller's bandwidth limit, in Megabytes (MB).
  • 0 — The reseller has unlimited bandwidth.
0
enable_oversellingBoolean

Whether the reseller can oversell accounts.

Warning
titleImportant:

The system only enforces this limit if you set the enable_resource_limits value to 1.

  • 1 — The reseller can oversell accounts.
  • 0 — The reseller cannot oversell accounts.
0
enable_overselling_bandwidthBoolean

Whether the reseller can oversell bandwidth.

Warning
titleImportant:

The system only enforces this limit if you set the enable_resource_limits value to 1.

  • 1 — The reseller can oversell bandwidth.
  • 0 — The reseller cannot oversell bandwidth.
0
enable_overselling_diskspaceBoolean

Whether the reseller can oversell disk space.

Warning
titleImportant:

The system only enforces this limit if you set the enable_resource_limits value to 1.

  • 1 — The reseller can oversell disk space.
  • 0 — The reseller cannot oversell disk space.
0
diskspace_limitinteger

The reseller's total disk space usage limit.

Warning
titleImportant:

The system only enforces this limit if you set the enable_resource_limits value to 1.

  • A positive integer that represents the reseller's disk space limit, in Megabytes (MB).
  • 0 — The reseller has unlimited disk space.
0
enable_package_limitsBoolean

Whether to apply package limits to the reseller.

  • 1 — Enable package limits.
  • 0 — Disable package limits.
0
enable_package_limit_numbersBooleanWhether to apply package limit numbers to the reseller.
  • 1 — Enable package limit numbers.
  • 0 — Disable package limit numbers.
0


Returns

This function only returns metadata.