PHPackages                             emmanuelsiziba/pesepay - 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. emmanuelsiziba/pesepay

ActiveLibrary[Payment Processing](/categories/payments)

emmanuelsiziba/pesepay
======================

Pesepay online payment integration package for seamless payment processing.

2.1.1.0(1y ago)054MITPHPPHP ^7.4|^8.0

Since Oct 22Pushed 1y agoCompare

[ Source](https://github.com/SyzbaLinux/pesepay-php)[ Packagist](https://packagist.org/packages/emmanuelsiziba/pesepay)[ Docs](https://github.com/SyzbaLinux/pesepay-php)[ RSS](/packages/emmanuelsiziba-pesepay/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (3)Dependencies (1)Versions (4)Used By (0)

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

[](#installation)

You can install the package via composer:

```
composer require emmanuelsiziba/pesepay
```

### Getting Started

[](#getting-started)

Import the library into your project/application

```
require_once 'path/to/vendor/autoload.php';
use EmmanuelSiziba\Payments\Pesepay
```

Create an instance of the `Pesepay` class using your integration key and encryption key as supplied by Pesepay.

```
$pesepay = new Pesepay("INTEGRATION KEY", "ENCRYPTION KEY");
```

Set return and result urls

```
$pesepay->returnUrl = "http://example.com/gateway/return";
$pesepay->resultUrl = "http://example.com/gateway/return";
```

### Make seamless payment

[](#make-seamless-payment)

Create the payment

##### NB: Customer email or number should be provided

[](#nb-customer-email-or-number-should-be-provided)

```
$payment = $pesepay->createPayment('CURRECNCY_CODE', 'PAYMENT_METHOD_CODE', 'CUSTOMER_EMAIL(OPTIONAL)', 'CUSTOMER_PHONE_NUMBER(OPTIONAL)', 'CUSTOMER_NAME(OPTIONAL)');
```

Create an `object` of the required fields (if any)

```
$requiredFields = ['requiredFieldName'=>'requiredFieldValue'];
```

Send of the payment

```
$response = $pesepay->makeSeamlessPayment($payment, 'Online Transaction', $AMOUNT, $requiredFields, 'MERCHANT_REFERENCE(OPTIONAL)');

if ($response->success()) {
    # Save the reference number and/or poll url (used to check the status of a transaction)
    $referenceNumber = $response->referenceNumber();
    $pollUrl = $response->pollUrl();

} else {
    #Get Error Message
    $errorMessage = $response->message();
}
```

### Make redirect payment

[](#make-redirect-payment)

Create a transaction

```
$transaction = $pesepay->createTransaction($amount, 'CURRENCY_CODE', 'PAYMENT_REASON', 'MERCHANT_REFERENCE(OPTIONAL)');
```

Initiate the transaction

```
$response = $pesepay->initiateTransaction($transaction);

if ($response->success()) {
    # Save the reference number and/or poll url (used to check the status of a transaction)
    $referenceNumber = $response->referenceNumber();
    $pollUrl = $response->pollUrl();
    # Get the redirect url and redirect user to complete transaction
    $redirectUrl = $response->redirectUrl();

} else {
    # Get error message
    $errorMessage = $response->message();
}
```

### Check Payment Status

[](#check-payment-status)

#### Method 1: Using referenceNumber

[](#method-1-using-referencenumber)

```
$response = $pesepay->checkPayment($referenceNumber);

if ($response->success()) {

    if ($response->paid()) {
        # Payment was successfull
    }

} else {
    # Get error message
    $errorMessage = $response->message();
}
```

#### Method 2: Using poll url

[](#method-2-using-poll-url)

```
$response = $pesepay->pollTransaction($pollUrl);

if ($response->success()) {

    if ($response->paid()) {
        # Payment was successfull
    }

} else {
    # Get error message
    $errorMessage = $response->message();
}
```

###  Health Score

32

—

LowBetter than 72% of packages

Maintenance42

Moderate activity, may be stable

Popularity9

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity57

Maturing project, gaining track record

 Bus Factor2

2 contributors hold 50%+ of commits

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

2

Last Release

464d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/11e3e40a83b7f1c61e34835b2cb96e59e27c4a78a928a8965e5295c81785d47d?d=identicon)[SyzbaLinux](/maintainers/SyzbaLinux)

---

Top Contributors

[![sean-codevirtus](https://avatars.githubusercontent.com/u/92912881?v=4)](https://github.com/sean-codevirtus "sean-codevirtus (9 commits)")[![SyzbaLinux](https://avatars.githubusercontent.com/u/20104015?v=4)](https://github.com/SyzbaLinux "SyzbaLinux (8 commits)")[![Loydtafireyi](https://avatars.githubusercontent.com/u/46261990?v=4)](https://github.com/Loydtafireyi "Loydtafireyi (1 commits)")[![simbachizhande](https://avatars.githubusercontent.com/u/93269083?v=4)](https://github.com/simbachizhande "simbachizhande (1 commits)")

---

Tags

paymentintegrationpesepayemmanuel siziba

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/emmanuelsiziba-pesepay/health.svg)

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

PHPackages © 2026

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