proxygroup.create

Description

object proxygroup.create(object/array proxyGroups)

This method allows to create new proxy groups.

This method is only available to Super admin user type. Permissions to call the method can be revoked in user role settings. See User roles for more information.

Parameters

(object/array) Proxy groups to create.

The method accepts proxy groups with the standard proxy group properties.

Return values

(object) Returns an object containing the IDs of the created proxy groups under the proxy_groupids property. The order of the returned IDs matches the order of the passed proxy groups.

Examples

Create a proxy group

Create a proxy group with custom settings.

Request:

{
           "jsonrpc": "2.0",
           "method": "proxygroup.create",
           "params": {
               "name": "Proxy group",
               "failover_delay": "5m",
               "min_online": "10"
           },
           "id": 1
       }

Response:

{
           "jsonrpc": "2.0",
           "result": {
               "proxy_groupids": [
                   "5"
               ]
           },
           "id": 1
       }

Source

CProxyGroup::create() in ui/include/classes/api/services/CProxyGroup.php.