PHPackages                             nanatty32/laravelhubtelmerchantaccountcedibet - 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. nanatty32/laravelhubtelmerchantaccountcedibet

ActiveLibrary[API Development](/categories/api)

nanatty32/laravelhubtelmerchantaccountcedibet
=============================================

Laravel Hubtel Merchant Account integration (Pure Laravel CediBet)

v1.0.2(5y ago)020[1 PRs](https://github.com/nanatty32/laravelhubtelmerchantaccountcedibet/pulls)MITPHP

Since Sep 16Pushed 5y ago1 watchersCompare

[ Source](https://github.com/nanatty32/laravelhubtelmerchantaccountcedibet)[ Packagist](https://packagist.org/packages/nanatty32/laravelhubtelmerchantaccountcedibet)[ RSS](/packages/nanatty32-laravelhubtelmerchantaccountcedibet/feed)WikiDiscussions master Synced yesterday

READMEChangelog (2)Dependencies (1)Versions (5)Used By (0)

Hubtel Merchant Account integration (Pure Laravel CediBet)
==========================================================

[](#hubtel-merchant-account-integration-pure-laravel-cedibet)

[![ico-version](https://camo.githubusercontent.com/efa0b91c6ab7dc8557cd9659099728831b87a406c8bd056ba19691c1a2486d24/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f72656c656173652f6e616e6174747933322f6c61726176656c68756274656c6d65726368616e746163636f756e74636564696265742e7376673f7374796c653d666c61742d737175617265)](https://camo.githubusercontent.com/efa0b91c6ab7dc8557cd9659099728831b87a406c8bd056ba19691c1a2486d24/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f72656c656173652f6e616e6174747933322f6c61726176656c68756274656c6d65726368616e746163636f756e74636564696265742e7376673f7374796c653d666c61742d737175617265)

Based on

About
-----

[](#about)

The `laravel-hubtel-merchant-account-cedibet` package allows you to accept and process payments using [Hubtel Merchant Account API](https://developers.hubtel.com/documentations/merchant-account-api) directly in your Laravel application.

Features
--------

[](#features)

- Receive mobile money
- Send mobile money
- Check status of transaction
- Online checkout

Installation
------------

[](#installation)

Require the `nanatty32/laravelhubtelmerchantaccountcedibet` package in your `composer.json` and update your dependencies:

```
$ composer require nanatty32/laravelhubtelmerchantaccountcedibet
```

If you're using Laravel 5.5, this is all there is to do.

Should you still be on older versions of Laravel, the final steps for you are to add the service provider of the package and alias the package. To do this open your `config/app.php` file.

Add the HubtelMerchantAccount\\ServiceProvider to your `providers` array:

```
Nanatty32\HubtelMerchantAccount\ServiceProvider::class,
```

And add a new line to the `aliases` array:

```
'aliases' => [
      ...
      'HubtelMerchantAccount' => Nanatty32\HubtelMerchantAccount\HubtelMerchantAccountFacade::class,
      ...
 ]
```

Using Online Checkout feature
-----------------------------

[](#using-online-checkout-feature)

Let's say you are using this feature from a controller method, you can do it like so:

```
namespace App\Http\Controllers;

use Nanatty32\HubtelMerchantAccount\OnlineCheckout\Item;
use HubtelMerchantAccount;
use App\Stake;
use Illuminate\Http\Request;

class CheckoutController extends Controller
{

  ...

  public function payOnline(Request $request)
    {
        $stake = Stake::where('session_id', $request->session()->getId())->latest()->first();

        if (!$stake) {
            abort(404, 'Invalid stake!');
        }

        // Initiate online checkout
        $ocRequest = new \Nanatty32\HubtelMerchantAccount\OnlineCheckout\Request();
        $ocRequest->invoice->description = "Invoice description";
        $ocRequest->invoice->total_amount = $stake->total;
        $ocRequest->business->name = "CediBet";
        $ocRequest->business->logo_url = asset('/img/logo.png');// Can be changed by developers
        $ocRequest->business->phone = "0243XXXXXX";
        $ocRequest->business->postal_address = "P. O. Box ******";
        $ocRequest->business->tagline = "Best online Betting Company In Ghana";
        $ocRequest->business->website_url = env('APP_URL');
        $ocRequest->actions->cancel_url = url('/checkout/done');
        $ocRequest->actions->return_url = url('/checkout/done');

        foreach ($stake->items as $item) {

            $invoiceItem = new Item();
            $invoiceItem->name = $item->product_name;
            $invoiceItem->description = "";
            $invoiceItem->quantity = $item->quantity;
            $invoiceItem->unit_price = $item->price;
            $invoiceItem->total_price = $item->price * $item->quantity;

            $ocRequest->invoice->addItem($invoiceItem);
        }

        HubtelMerchantAccount::onlineCheckout($ocRequest);
    }
```

Receive Mobile Money
--------------------

[](#receive-mobile-money)

Here is how you request mobile money payment from the controller method:

```
namespace App\Http\Controllers;

use HubtelMerchantAccount;
use Nanatty32\HubtelMerchantAccount\MobileMoney\Receive\Request as ReceiveMobileMoneyRequest;

class CheckoutController extends Controller
{

  ...

  public function payOnline(Request $request)
    {
        $request = new ReceiveMobileMoneyRequest();
        $request->Amount = $this->transaction->amount;
        $request->Channel = $this->transaction->channel;
        $request->CustomerMsisdn = $this->transaction->mobile_wallet_number;
        $request->CustomerName = "N/A";
        $request->Description = "Bet Amount";
        $request->PrimaryCallbackURL = "https://my-application.com/handle" . $this->transaction->id;
        $request->SecondaryCallbackURL = "https://my-application.com/handle/" . $this->transaction->id;
        $response = HubtelMerchantAccount::receiveMobileMoney($request);
    }
```

Configuration
-------------

[](#configuration)

The defaults are set in `config/hubtelmerchantaccount.php`. Copy this file to your own config directory to modify the values. You can publish the config using this command:

```
$ php artisan vendor:publish --provider="Nanatty32\HubtelMerchantAccount\ServiceProvider"
```

```
return [

    /**
     * Merchant account number
     */
    "account_number" => env('HUBTEL_MERCHANT_ACCOUNT_NUMBER'),

    /**
     * Login credentials for hubtel api
     *
     */
    "api_key" => [
        "client_id" => env('HUBTEL_MERCHANT_ACCOUNT_CLIENT_ID'),
        "client_secret" => env('HUBTEL_MERCHANT_ACCOUNT_CLIENT_SECRET')
    ],

    /**
     * business details
     */
    "business" => [
        "name" => env('APP_NAME')
    ]
];
```

License
-------

[](#license)

Released under the MIT License, see [LICENSE](LICENSE).

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity57

Maturing project, gaining track record

 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

3

Last Release

2064d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/61622082?v=4)[Nanatty32](/maintainers/Nanatty32)[@nanatty32](https://github.com/nanatty32)

---

Top Contributors

[![nanatty32](https://avatars.githubusercontent.com/u/61622082?v=4)](https://github.com/nanatty32 "nanatty32 (49 commits)")

---

Tags

apilaravelpaymentgatewaymerchantaccounthubtelcedibet

### Embed Badge

![Health badge](/badges/nanatty32-laravelhubtelmerchantaccountcedibet/health.svg)

```
[![Health](https://phpackages.com/badges/nanatty32-laravelhubtelmerchantaccountcedibet/health.svg)](https://phpackages.com/packages/nanatty32-laravelhubtelmerchantaccountcedibet)
```

###  Alternatives

[mollie/laravel-mollie

Mollie API client wrapper for Laravel &amp; Mollie Connect provider for Laravel Socialite

3624.1M28](/packages/mollie-laravel-mollie)[checkout/checkout-sdk-php

Checkout.com SDK for PHP

553.3M7](/packages/checkout-checkout-sdk-php)[shipu/php-aamarpay-payment

PHP client for Aamarpay Payment Gateway API

3214.6k](/packages/shipu-php-aamarpay-payment)

PHPackages © 2026

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