PHPackages                             yubarajshrestha/nchl - 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. yubarajshrestha/nchl

ActiveLibrary[Payment Processing](/categories/payments)

yubarajshrestha/nchl
====================

Connect IPS payment gateway for laravel.

v1.0(6y ago)81137[5 PRs](https://github.com/yubarajshrestha/nchl/pulls)MITPHP

Since Jan 12Pushed 2y ago1 watchersCompare

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

READMEChangelogDependencies (11)Versions (7)Used By (0)

NCHL
----

[](#nchl)

Connect IPS payment gateway package.

[![Latest Stable Version](https://camo.githubusercontent.com/71c1aa5ebb5fe0fdb0dfd3e8c6141464dee0b28acee9e509a4befd6eca8f7f02/68747470733a2f2f706f7365722e707567782e6f72672f7975626172616a73687265737468612f6e63686c2f762f737461626c65)](https://packagist.org/packages/yubarajshrestha/nchl)[![Total Downloads](https://camo.githubusercontent.com/4bf51646f1eccbe84db773d9dacd820d8fe9f3b245c2c6298312b1fe858a30bc/68747470733a2f2f706f7365722e707567782e6f72672f7975626172616a73687265737468612f6e63686c2f646f776e6c6f616473)](https://packagist.org/packages/yubarajshrestha/nchl)

[![License](https://camo.githubusercontent.com/d29288144439ba7d04fdd95a4f79847b90bc7abfacc17f586e2b6b6900bea0b1/68747470733a2f2f706f7365722e707567782e6f72672f7975626172616a73687265737468612f6e63686c2f6c6963656e7365)](https://packagist.org/packages/yubarajshrestha/nchl)[![Build](https://camo.githubusercontent.com/94b9d5ecf0a38aeacc4a09049de012a6ad9eeaa7fcc596910d482819af85cd5f/68747470733a2f2f7472617669732d63692e636f6d2f7975626172616a73687265737468612f6e63686c2e7376673f6272616e63683d6d6173746572)](https://camo.githubusercontent.com/94b9d5ecf0a38aeacc4a09049de012a6ad9eeaa7fcc596910d482819af85cd5f/68747470733a2f2f7472617669732d63692e636f6d2f7975626172616a73687265737468612f6e63686c2e7376673f6272616e63683d6d6173746572)[![StyleCI](https://camo.githubusercontent.com/ede18cc2667886cbbd53085bf19923821e2a95b58472f0ab50b2fb140807f50d/68747470733a2f2f6769746875622e7374796c6563692e696f2f7265706f732f3233303736383633362f736869656c643f6272616e63683d6d6173746572)](https://github.styleci.io/repos/230768636)[![All Contributors](https://camo.githubusercontent.com/db0a672758a6b3f2641e6c6099e3fadfd608167acfae3b31425eb3917b0dc47f/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f616c6c5f636f6e7472696275746f72732d322d6f72616e67652e7376673f7374796c653d666c61742d737175617265)](#contributors-)

### Installation

[](#installation)

Require this package with composer.

```
composer require yubarajshrestha/nchl
```

Laravel 5.5 uses Package Auto-Discovery, so doesn't require you to manually add the ServiceProvider.

### Laravel 5.5+:

[](#laravel-55)

If you don't use auto-discovery, add the ServiceProvider to the providers array in config/app.php

```
YubarajShrestha\NCHL\NchlServiceProvider::class,
```

If you want to use the facade to log messages, add this to your facades in app.php:

```
'NCHL' => YubarajShrestha\NCHL\Facades\NchlFacade::class,
```

### Copy the package config to your local config with the publish command:

[](#copy-the-package-config-to-your-local-config-with-the-publish-command)

```
php artisan vendor:publish --provider="YubarajShrestha\NCHL\NchlServiceProvider"
```

### Copy the environment variables and setup as per required in .env:

[](#copy-the-environment-variables-and-setup-as-per-required-in-env)

```
NCHL_MERCHANT_ID=
NCHL_APP_ID=
NCHL_APP_NAME=
NCHL_APP_PASSWORD=
NCHL_GATEWAY=
NCHL_VALIDATION_URL=
NCHL_TRANSACTION_DETAIL_URL=
```

### Basic Usage

[](#basic-usage)

A `NCHL` is Service Class and can be instanciated like this:

```
// In Controller
$nchl = NCHL::__init([
    "txn_id" => '3',
    "txn_date" => '1-10-2020',
    "txn_amount" => '500',
    "reference_id" => 'REF-001',
    "remarks" => 'RMKS-001',
    "particulars" => 'PART-001',
]);
```

And then in view you will create a form to start payment, which redirects you to `Connect IPS`.

```
// In View

    MERCHANT ID

    APP ID

    APP NAME

    TXN ID

    TXN DATE

    TXN CRNCY

    TXN AMT

    REFERENCE ID

    REMARKS

    PARTICULARS

    TOKEN

```

After success or failure payment it will redirect you to the redirect url that you've provided to `Connect IPS`.

### Validating Payment and retrieving Payment Details

[](#validating-payment-and-retrieving-payment-details)

Re-instantiate the NCHL serivce class same like before.

```
// In Controller
$nchl = NCHL::__init([
    "txn_id" => '3',
    "txn_date" => '1-10-2020',
    "txn_amount" => '500',
    "reference_id" => 'REF-001',
    "remarks" => 'RMKS-001',
    "particulars" => 'PART-001',
]);

/** Validating Payment **/
$response = $nchl->paymentValidate();

/** Retrieving payment details **/
$response = $nchl->paymentDetails();
```

Well that's it. Enjoy

### Contributors

[](#contributors)

  [![](https://avatars0.githubusercontent.com/u/7955362?s=460&v=4)
**Yubaraj Shrestha**](https://yubarajshrestha.com.np) ### License

[](#license)

###  Health Score

31

—

LowBetter than 68% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity18

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity61

Established project with proven stability

 Bus Factor1

Top contributor holds 96.5% 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

Unknown

Total

1

Last Release

2313d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/4140257658433cc8eb3a1a36a13fdf25ae15b9716c682f1c69a5a3bfb13f0a4b?d=identicon)[meyubaraj](/maintainers/meyubaraj)

---

Top Contributors

[![yubarajshrestha](https://avatars.githubusercontent.com/u/7955362?v=4)](https://github.com/yubarajshrestha "yubarajshrestha (111 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (4 commits)")

---

Tags

connect-ipsgateway-apilaravelnchl

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/yubarajshrestha-nchl/health.svg)

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

###  Alternatives

[chargebee/chargebee-php

ChargeBee API client implementation for PHP

768.0M9](/packages/chargebee-chargebee-php)[imdhemy/google-play-billing

Google Play Billing

491.3M5](/packages/imdhemy-google-play-billing)[bitpay/sdk

Complete version of the PHP library for the new cryptographically secure BitPay API

42337.5k4](/packages/bitpay-sdk)[buckaroo/sdk

Buckaroo payment SDK

12189.1k9](/packages/buckaroo-sdk)[contica/facturador-electronico-cr

Un facturador de código libre para integrar facturación electrónica en Costa Rica a un proyecto PHP

2128.8k](/packages/contica-facturador-electronico-cr)[karson/mpesa-php-sdk

172.2k](/packages/karson-mpesa-php-sdk)

PHPackages © 2026

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