PHPackages                             ayman-elmalah/whmcs - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. ayman-elmalah/whmcs

ActiveLibrary[API Development](/categories/api)

ayman-elmalah/whmcs
===================

A Laravel package for handling the use of whmcs api and writing clean and cool code

v1.0.5(6y ago)437MITPHP

Since May 23Pushed 6y ago1 watchersCompare

[ Source](https://github.com/ayman-elmalah/whmcs)[ Packagist](https://packagist.org/packages/ayman-elmalah/whmcs)[ RSS](/packages/ayman-elmalah-whmcs/feed)WikiDiscussions master Synced today

READMEChangelogDependenciesVersions (6)Used By (0)

Laravel Whmcs
=============

[](#laravel-whmcs)

laravel whmcs is a php package written by [Ayman Elmalah](https://github.com/ayman-elmalah) with laravel to handle using [whmcs](https://www.whmcs.com/) .

About whmcs
-----------

[](#about-whmcs)

- WHMCS is the leading web host billing automation platform powering tens of thousands of web hosting companies.
- Simplify and automate daily tasks and operations with the #1 choice in Web Hosting Automation

Installation Guide
==================

[](#installation-guide)

At laravel project install package using composer

```
composer require ayman-elmalah/whmcs

```

Then you can run command to publish you vendor config files

```
php artisan vendor:publish --provider=AymanElmalah\Whmcs\WhmcsServiceProvider

```

The package is compatible with laravel 5.5 or later so you don't need to set providers or aliases for the package, we're using laravel auto discovery

Get Your Credentials From Whmcs
-------------------------------

[](#get-your-credentials-from-whmcs)

- Go to your .env file and paste your credentials to be like this

```
WHMCS_URL='http://yourdomain.com/includes/api.php'
WHMCS_USERNAME='username'
WHMCS_PASSWORD='password'

```

You are now ready to use the package

### To send request, you can use CURL request or localApi when you are in whmcs local project

[](#to-send-request-you-can-use-curl-request-or-localapi-when-you-are-in-whmcs-local-project)

you can add route for post request to do an action

```
Route::post('whmcs/action', 'WhmcsController@action');

```

At the controller, you can use one of two methods, curl or localApi to execute action to your whmcs

```
use Whmcs;
// curl request
public function action() {
    $post_fields = ['userid' => $CLIENT_ID', 'responsetype' => 'json'];
    $action = 'GetInvoices';
    $whmcs = Whmcs::curl($action, $post_fields);

    return $whmcs;
}

// localApi request
public function action() {
    $post_fields = ['userid' => $CLIENT_ID', 'responsetype' => 'json'];
    $action = 'GetInvoices';
    $whmcs = Whmcs::localApi($action, $post_fields);

    return $whmcs;
}

```

This code will do direct action to whmcs

That's an example of using whmcs api to you can use all actions with our package, just edit action value and postfields and it's all in your hand

To know more about all api index that you can use, you can visit the link below and choose the action you want
--------------------------------------------------------------------------------------------------------------

[](#to-know-more-about-all-api-index-that-you-can-use-you-can-visit-the-link-below-and-choose-the-action-you-want)

[WHMCS api index](https://developers.whmcs.com/api/api-index/) =&gt; its the documentation for whmcs api, you can take the action and post fields and use it in our package

If you have any question, issue Or request, i'll be happy if hear any thing from you
====================================================================================

[](#if-you-have-any-question-issue-or-request-ill-be-happy-if-hear-any-thing-from-you)

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity11

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity63

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

5

Last Release

2545d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/f310d904881978bb6effb86e20d1afd6bd84a41b652cd4bd48ef004dfda25537?d=identicon)[ayman-elmalah](/maintainers/ayman-elmalah)

---

Top Contributors

[![ayman-elmalah](https://avatars.githubusercontent.com/u/22693197?v=4)](https://github.com/ayman-elmalah "ayman-elmalah (7 commits)")

---

Tags

laravelwhmcs

### Embed Badge

![Health badge](/badges/ayman-elmalah-whmcs/health.svg)

```
[![Health](https://phpackages.com/badges/ayman-elmalah-whmcs/health.svg)](https://phpackages.com/packages/ayman-elmalah-whmcs)
```

###  Alternatives

[stripe/stripe-php

Stripe PHP Library

4.0k143.3M480](/packages/stripe-stripe-php)[twilio/sdk

A PHP wrapper for Twilio's API

1.6k92.9M271](/packages/twilio-sdk)[knplabs/github-api

GitHub API v3 client

2.2k15.8M187](/packages/knplabs-github-api)[facebook/php-business-sdk

PHP SDK for Facebook Business

90121.9M34](/packages/facebook-php-business-sdk)[meilisearch/meilisearch-php

PHP wrapper for the Meilisearch API

73813.7M114](/packages/meilisearch-meilisearch-php)[google/gax

Google API Core for PHP

263103.1M454](/packages/google-gax)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
