Update an environment
Это содержимое пока не доступно на вашем языке.
updateEnvironment changes an existing virtual environment, the same as saving the Edit Environment form under System Management → Environments. Only the root customer of the root environment can call it.
The method supports trusted mode with i_customer, the ID of the root customer.
Parameters
Section titled “Parameters”| Name | Type | Required | Description |
|---|---|---|---|
i_environment |
int | yes | ID of the environment |
any parameter of createEnvironment |
— | no | The new value. Parameters you leave out keep their current value |
Send None (nil) to clear a value: unlimited max_cps or max_sessions, no expiration_date, no installed_modules. assigned_ips set to None unassigns all IP addresses; the panel offers this only for a stopped environment other than the root one.
Returns
Section titled “Returns”| Name | Type | Description |
|---|---|---|
result |
string | OK |
Example
Section titled “Example”Raise the caps of environment 4 and extend it until the end of 2027:
call("updateEnvironment", { "i_environment": 4, "max_cps": 50, "max_sessions": 500, "expiration_date": "23:59:59.000 GMT Fri Dec 31 2027",}){"result": "OK"}Related
Section titled “Related”- Virtual environments: the Environments screen
- Get environment information: the current values
- Create an environment
- List IP addresses of the switch