Developer Center

Fixed Functions and Return

The function names which are mandatory in the module class are: create, terminate, suspend, unsuspend

All of these 4 functions run similarly, they can run both manually and automatically, each of which must return a success or error response.

Response Usage

All other functions except "create" function must return response in boolean data type.

If the function fails, the error message you specify must be a message that can be understood by user.

You should assign the error message to $this->error variable in the class.

"create" Response Example

The return value from the function must be an array. Received value is saved to users_products.options field in the database of service.


public function create($order_options=[]){

* $order_options --> users_products.options
* Here are the codes to be sent to the API...

$api_result = "OK|101";
/* Error Result:
* $api_result = "Failed to create server, something went wrong.";

if(substr($api_result,0,2) == 'OK')
return [
'ip' => '',
'assigned_ips' => ['',''],
'login' => [
'username' => 'root',
'password' => 'test123',
'config' => [$this->entity_id_name => substr($api_result,3)],
$this->error = $api_result;
return false;
Parameters Single Sign-On

Do you have any questions?

Feel free to contact us
Contact Us
Copyright © 2022. All Rights Reserved.
Join Our Discord Channel