run this command in your project root folder
composer require "motwreen/whmcpanel":"@dev"
or add the following to your composer.json
{
"require": {
"motwreen/whmcpanel":"@dev"
}
}
add the following line to your providers array in config/app.php
file
Motwreen\WHMCPanel\WHMCPanelServiceProvider::class,
and this to aliases
'WHMCPanel' => Motwreen\WHMCPanel\WHMCPanelFacade::class,
<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use WHMCPanel;
class TestController extends Controller
{
public function index()
{
WHMCPanel::listaccts(); \\list all accounts data in server
}
}
<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use WHMCPanel;
class TestController extends Controller
{
public function index()
{
WHMCPanel::suspendacct(['user'=>'User Name','reason'=>'Reason String']); \\ Suspend Account using it's username
}
}
1-listaccts
2-listpkgs
3-accountsummary
4-createacct
5-suspendacct
6-unsuspendacct
1- make code ready for rest API methods
2- Validate For Required Parameters
3- dedicate package config into seprate files
I will provide more examples and will develope this package feel free to use,test and develop it .