1. Go to this page and download the library: Download naif/php-cpanel-email library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
$cpanel->create('username','password')
Response:
[
"status" => "success"
"message" => "Email address has been added successfully"
]
$cpanel->delete('email_address')
Response:
[
"status" => "success"
"message" => "Email address has been deleted successfully"
]
$cpanel->changePassword('username','password')
Response:
[
"status" => "success"
"message" => "Password has been changed successfully"
]
$cpanel->changeQuota('username',500)//quota as a number or 0 to set it as unlimited
Response:
[
"status" => "success"
"message" => "Email disk quota has been changed successfully"
]
composer
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.