PHPackages                             zoodpay/laravel-package - 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. [Payment Processing](/categories/payments)
4. /
5. zoodpay/laravel-package

ActivePackage[Payment Processing](/categories/payments)

zoodpay/laravel-package
=======================

Laravel Package for processing payments through ZoodPay BNPL.

1.0.1(3y ago)114MITPHP

Since Jun 17Pushed 3y ago3 watchersCompare

[ Source](https://github.com/orientswiss/zoodpay-laravel-package)[ Packagist](https://packagist.org/packages/zoodpay/laravel-package)[ RSS](/packages/zoodpay-laravel-package/feed)WikiDiscussions master Synced 1mo ago

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

ZoodPay Laravel Package
=======================

[](#zoodpay-laravel-package)

[![Software License](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](LICENSE.md)[![Total Downloads](https://camo.githubusercontent.com/3704285480b70f0b20c288f4e60fb4bd7458ee1a8fdcc9b2c2b299ca7d99b8fc/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f7a6f6f647061792f6c61726176656c2d7061636b616765)](https://packagist.org/packages/zoodpay/laravel-package)

Install
-------

[](#install)

`composer require zoodpay/laravel-package`

Usage
-----

[](#usage)

Check that ZoodpayServiceProvider is added in the config/app.php, or Manually add it.

```
 'providers' => [

        /*
         * Laravel Framework Service Providers...
         */
     ...
 ZoodPay\ZoodpayServiceProvider::class,
]
```

Add zoodpay credentials to the config/services.php config file as below.

```
return [

    ...
 'zoodpay' => [
        'merchant_key' => "",
        'merchant_secret' => "",
        'merchant_salt' => "",
        'merchant_api_url' => "",
        'merchant_api_ver' => "",
        'market_code' => "",
        'currency' =>"",
        'success_url' => "",
        'error_url' => "" ,
        'pending_url' => ""
    ]
```

Available functions:

```
//Return the ZoodPay Config settings
$this->app->zoodpay->getAPISettings()

//Fetch the merchant configuration.
$this->app->zoodpay->getZoodPayLimit()

//To verify if ZoodPay need to be shown in Checkout Page
$this->app->zoodpay->availableZoodPayService($amount)

//Fetch the credit balance of a customer.
$this->app->zoodpay->getCreditBalance($phone_number)

//Return ZoodPay Signature for Transaction Signature Verification
$this->app->zoodpay->getResponseSignature($amount, $merchant_reference_no, $transaction_id)

//Return ZoodPay Refund Signature for Refund Signature Verification
$this->app->zoodpay->getRefundResponseSignature($merchant_refund_reference, $refund_amount, $status, $refund_id)

/*
 * Create Transaction Using ZoodPay, it will return ZoodPay API response.
 * Initiate the Models and set Values
 * $billing = new Model\BillingShippingInfo();
 * $customer = new Model\CustomerInfo();
 * $items[] = new Model\ItemsInfo();
 * $order = new Model\OrderInfo();
 * $shippingService = new Model\ShippingServiceInfo();
 * $shipping = $billing;
 *
*/
$this->app->zoodpay->createTransaction($billing, $customer, $items, $order, $shipping, $shippingService)

/*
 * Set Delivery Date for the Paid Transaction,  it will return ZoodPay API response.
 * Init the Model and set Values
 * Model\DeliveryDate();
 *
 * */
$this->app->zoodpay->setDeliveryDate($deliveryModel);

/*
 * Create Refund for the Paid Transaction,  it will return ZoodPay API response.
 * Init the Model and set Values
 * Model\CreateRefund()
 *
 * */
$this->app->zoodpay->createRefund($refundModel);

/*
 * Get Refund Status by Refund id,  it will return ZoodPay API response.
 * Init the Model and set Values
 * Model\CreateRefund()
 *
 * */
$this->app->zoodpay->getRefundStatusById($refund_id);

```

Process: ZoodPay Flow [![ZoodPay Flow](./doc-assets/flow.jpg)](./doc-assets/flow.jpg)

```
/* 1)
 * To check if ZoodPay need to be Shown in Checkout Page, call this function
 * and based on the available response show the corresponding service
*/
$this->app->zoodpay->availableZoodPayService($amount)

/* 2)
 * User Select ZoodPay Service and Click Pay, Prepare the request and Create Transaction
 * and function will return ZoodPay API response.
 * Initiate the Models and set Values
 * $billing = new Model\BillingShippingInfo();
 * $customer = new Model\CustomerInfo();
 * $items[] = new Model\ItemsInfo();
 * $order = new Model\OrderInfo();
 * $shippingService = new Model\ShippingServiceInfo();
 * $shipping = $billing;
 *
 * API Response :
 *
 * Transaction created: {"session_token":"YYYYYYYYYYYYYYYYYYYY","transaction_id":"407879856581528","expiry_time":"2021-12-22T16:58:49Z","payment_url":"https://b2c.zoodpay.com/index.php?XXXXXXXXXXXXXXXXXXXXXXXXXXXX","signature":"96496a0ae20cf58d936d195fd1d0b19526201313f7af97aae3e99610e314294dc3d66c9d3881d06994af273b25bb115bf5eef5b21806f24b5bd61b37f2387be7"}
 *

 *
*/
$this->app->zoodpay->createTransaction($billing, $customer, $items, $order, $shipping, $shippingService);

/*
 * 3)
 * Verify the Signature by  Calling below function and if the signature match,
 * do necessary changes and save transaction_id as reference and redirect user to ZoodPay UI .
 *
 * */
 $this->app->zoodpay->getResponseSignature($amount, $merchant_reference_no, $transaction_id)

/*
 * 4)
 * User will be redirected to the Callback Http/Controller/Callback.php,
 * change your Order Status Accordingly in each Action.
 */

 /*
  * 5)
 * Set Delivery Date for the Paid Transaction,  it will return ZoodPay API response.
 * Init the Model and set Values
 * Model\DeliveryDate();
 *
 * */
$this->app->zoodpay->setDeliveryDate($deliveryModel);

 /*
  * 6)
 * Create Refund for the Paid Transaction,  it will return ZoodPay API response.
 * Init the Model and set Values
 * Model\CreateRefund()
 *
 * */
$this->app->zoodpay->createRefund($refundModel);
```

Testing
-------

[](#testing)

Run the tests with: load the phpunit.xml and change

```
$ /usr/bin/php /path to laravel/vendor/phpunit/phpunit/phpunit --configuration /path to laravel/packages/zoodpay-laravel/phpunit.xml
```

Changelog
---------

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently.

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

Credits
-------

[](#credits)

- [ZoodPay](https://github.com/orientswiss)

Security
--------

[](#security)

If you discover any security-related issues, please email  instead of using the issue tracker.

License
-------

[](#license)

The MIT License (MIT). Please see [License File](/LICENSE.md) for more information.

###  Health Score

22

—

LowBetter than 22% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community5

Small or concentrated contributor base

Maturity47

Maturing project, gaining track record

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

Unknown

Total

1

Last Release

1424d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/d03ea31c551752ab2b697a8a4057d862665b0306a9bd968f8f50f303c6b05cd3?d=identicon)[accounts-orientswiss](/maintainers/accounts-orientswiss)

---

Tags

laravelpaymentgatewaypayment gatewaybuy now pay laterbnplzoodpayZoodMall

### Embed Badge

![Health badge](/badges/zoodpay-laravel-package/health.svg)

```
[![Health](https://phpackages.com/badges/zoodpay-laravel-package/health.svg)](https://phpackages.com/packages/zoodpay-laravel-package)
```

###  Alternatives

[sebdesign/laravel-viva-payments

A Laravel package for integrating the Viva Payments gateway

4845.9k](/packages/sebdesign-laravel-viva-payments)

PHPackages © 2026

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