PHPackages                             unityarray/payscel - 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. unityarray/payscel

ActiveLibrary[Payment Processing](/categories/payments)

unityarray/payscel
==================

payscel's payment sdk for stk payment initiation and query

v1(2y ago)02303MITPHPPHP &gt;=7.3

Since Mar 21Pushed 2y ago1 watchersCompare

[ Source](https://github.com/code-jambo/payscel-php)[ Packagist](https://packagist.org/packages/unityarray/payscel)[ RSS](/packages/unityarray-payscel/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (1)DependenciesVersions (2)Used By (0)

Payscel PHP Library
===================

[](#payscel-php-library)

This library provides a simple interface for interacting with the Payscel payment gateway in your PHP applications.

Installation Using Composer:

```
composer require unityarray/payscel

```

Usage
-----

[](#usage)

Instantiate the Payscel class:

```
require_once 'vendor/autoload.php';

use UnityArray\Payscel\Payscel;

$apiKey = 'YOUR_API_KEY';
$linkId = 'YOUR_LINK_ID';
$payscel = new Payscel($apiKey, $linkId);
```

Initiate a payment:

```
$msisdn = '254712345678'; // Phone number without the leading '+'
$amount = 10; // Amount in kes
$callback = 'https://your-website.com/callback'; // Your callback URL

$response = $payscel->initiate($msisdn, $amount, $callback);

// Handle the response (usually a JSON object containing checkout details)

// {
//   +"MerchantRequestID": "db57-40e1-af85-2424fab5a2e697902622"
//   +"CheckoutRequestID": "ws_CO_21032024215003724757869730"
//   +"ResponseCode": "0"
//   +"ResponseDescription": "Success. Request accepted for processing"
//   +"CustomerMessage": "Success. Request accepted for processing"
// }

// example

echo $response->ResponseDescription; // Success. Request accepted for processing
```

Query the status of a payment:

```
$checkoutId = 'CHECKOUT_ID_FROM_INITIATE_RESPONSE';

$response = $payscel->query($checkoutId);

// Handle the response (usually a JSON object containing payment status)

// {
//   +"ResponseCode": "0"
//   +"ResponseDescription": "The service request has been accepted successsfully"
//   +"MerchantRequestID": "847c-4573-85db-96a68dacad1992169467"
//   +"CheckoutRequestID": "ws_CO_21032024213641597757869730"
//   +"ResultCode": "1037"
//   +"ResultDesc": "DS timeout user cannot be reached"
// }

// example

echo $response->ResultDesc; // DS timeout user cannot be reached
```

### Methods

[](#methods)

- initiate($msisdn, $amount, $callback): Initiates a payment.
- query($checkoutId): Queries the status of a payment.

### Examples

[](#examples)

Please see the examples directory for more detailed usage examples.

### Contributing

[](#contributing)

We welcome contributions! Please see the CONTRIBUTING.md file for more information.

### License

[](#license)

This library is licensed under the MIT License. See the LICENSE file for more information.

###  Health Score

21

—

LowBetter than 18% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity13

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity36

Early-stage or recently created project

 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

Unknown

Total

1

Last Release

788d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/37f695608c85d2586d9d10f986c154490e6ca2aea0f884b6bc5a6c1faa1ed415?d=identicon)[code-jambo](/maintainers/code-jambo)

---

Top Contributors

[![kemboimax](https://avatars.githubusercontent.com/u/125876925?v=4)](https://github.com/kemboimax "kemboimax (14 commits)")

### Embed Badge

![Health badge](/badges/unityarray-payscel/health.svg)

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

###  Alternatives

[omnipay/paypal

PayPal gateway for Omnipay payment processing library

3156.8M53](/packages/omnipay-paypal)[eduardokum/laravel-boleto

Biblioteca com boletos para o laravel

626351.9k2](/packages/eduardokum-laravel-boleto)[tbbc/money-bundle

This is a Symfony bundle that integrates moneyphp/money library (Fowler pattern): https://github.com/moneyphp/money.

1961.9M](/packages/tbbc-money-bundle)[2checkout/2checkout-php

2Checkout PHP Library

83740.3k2](/packages/2checkout-2checkout-php)[smhg/sepa-qr-data

Generate QR code data for SEPA payments

61717.2k5](/packages/smhg-sepa-qr-data)[omnipay/dummy

Dummy driver for the Omnipay payment processing library

271.2M33](/packages/omnipay-dummy)

PHPackages © 2026

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