PHPackages                             perfectmak/paystack-php - 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. perfectmak/paystack-php

ActiveLibrary[Payment Processing](/categories/payments)

perfectmak/paystack-php
=======================

Paystack Library for PHP

141.5k↓55.6%5[1 issues](https://github.com/perfectmak/paystack-php/issues)PHP

Since Mar 19Pushed 10y ago2 watchersCompare

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

READMEChangelogDependenciesVersions (1)Used By (0)

Paystack PHP
============

[](#paystack-php)

[![Build Status](https://camo.githubusercontent.com/6b1190f3dc5a26d7a77c96a8a58278abae88ad46f474f41fbb3bcffabe8c607c/68747470733a2f2f7365637572652e7472617669732d63692e6f72672f706572666563746d616b2f706179737461636b2d7068702e706e673f6272616e63683d6d6173746572)](http://travis-ci.org/perfectmak/paystack-php)

Paystack PHP is a library for using the [Paystack](http://paystack.com) API from PHP.

While there are other PHP libraries for Paystack, this library is designed to make it less cumbersome to implement a payment flow on the Paystack payment platform.

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

[](#installation)

To install using composer

```
composer install perfectmak/paystack-php

```

Usage
-----

[](#usage)

First you initialize the library with your secret key

```
\Paystack\Paystack::init('__secret_key_here__');
```

### Transaction

[](#transaction)

#### Initialize a transaction

[](#initialize-a-transaction)

```
    $payment = \Paystack\Transaction::initialize([
        'email' => 'jame@gosling.com',
        'amount' => '3000'
    ]);
```

### Customer

[](#customer)

#### Create Customer

[](#create-customer)

```
    $customer = \Paystack\Customer::create([
        'email' => 'google@gosling.com',
        'first_name' => 'Perfect',
        'last_name' => 'Makanju',
        'phone' => 'xxxxxxx'
    ]);

    echo 'Customer\'s first name is: '.$customer->first_name;
```

Todo
----

[](#todo)

This library is far from complete and not yet stable. So I don't advice using it yet.

- Finish up all the resources
- Tests for each Resource
- Fix travis build script

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance19

Infrequent updates — may be unmaintained

Popularity30

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity41

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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/7a9d83bf0acc3413e94375692cf05b0269c810d782b87e06c9debde2e7f7e87b?d=identicon)[perfectmak](/maintainers/perfectmak)

---

Top Contributors

[![perfectmak](https://avatars.githubusercontent.com/u/3120013?v=4)](https://github.com/perfectmak "perfectmak (10 commits)")

### Embed Badge

![Health badge](/badges/perfectmak-paystack-php/health.svg)

```
[![Health](https://phpackages.com/badges/perfectmak-paystack-php/health.svg)](https://phpackages.com/packages/perfectmak-paystack-php)
```

###  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)
