PHPackages                             afrikpay-tools/afrikpay-tools-php-sdk - 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. [API Development](/categories/api)
4. /
5. afrikpay-tools/afrikpay-tools-php-sdk

ActiveLibrary[API Development](/categories/api)

afrikpay-tools/afrikpay-tools-php-sdk
=====================================

Afrikpay Php Api Sdk

026[1 issues](https://github.com/Georges-Ngandeu/AfrikpayPhpSdk/issues)PHP

Since May 27Pushed 4y ago2 watchersCompare

[ Source](https://github.com/Georges-Ngandeu/AfrikpayPhpSdk)[ Packagist](https://packagist.org/packages/afrikpay-tools/afrikpay-tools-php-sdk)[ RSS](/packages/afrikpay-tools-afrikpay-tools-php-sdk/feed)WikiDiscussions master Synced 1w ago

READMEChangelogDependenciesVersions (1)Used By (0)

 [ ![Logo](afrikpay.png) ](https://github.com/Georges-Ngandeu/AfrikpayNodeSdk)

### Afrikpay Node Sdk

[](#afrikpay-node-sdk)

 Afrikpay api integration with nodejs
 [**Explore the docs »**](https://github.com/Georges-Ngandeu/AfrikpayNodeSdk)

 [View Demo](https://github.com/Georges-Ngandeu/AfrikpayNodeSdk) · [Report Bug](https://github.com/Georges-Ngandeu/AfrikpayNodeSdk) · [Request Feature](https://github.com/Georges-Ngandeu/AfrikpayNodeSdk)

 Table of Contents
-----------------

[](#table-of-contents)

1. [Getting started](#getting)
2. [Ecommerce integration](#usage)
3. [Bill integration](#usage)
4. [Airtime integration](#usage)
5. [Account integration](#usage)
6. [License](#license)
7. [Contact](#contact)
8. [Acknowledgements](#acknowledgements)

Getting Started
---------------

[](#getting-started)

This node library was created with the purpose of facilitating the integration of our payment api to our partners. It is an ongoing work. Suggestions to ameliorate the api are welcome.

### Prerequisites: `composer` must be install on your system

[](#prerequisites--composer-must-be-install-on-your-system)

### Installation

[](#installation)

```
composer require afrikpay-tools/afrikpay-tools-php-sdk:dev-master
```

Ecommerce integration
---------------------

[](#ecommerce-integration)

Let's suppose you want to integrate ecommerce payments on you system. Here are the two main steps to get the job done in the development environment. You can uncomment the code to test the others apis.

```
require __DIR__.'/vendor/autoload.php';

use App\Ecommerce;

//some example usage of the package

/*********************ecommerce api examples****************/

//collect example
 $ecommerce = new Ecommerce(
    'AFC6617',
    '661671d0bd7bef499e7d80879c27d95e',
    '7777',
    'http://34.86.5.170:8086/api/ecommerce/collect/',
    'http://34.86.5.170:8086/api/ecommerce/payout/',
    'http://34.86.5.170:8086/api/ecommerce/deposit/',
    'http://34.86.5.170:8086/api/ecommerce/changekey/',
    'http://34.86.5.170:8086/api/ecommerce/transaction/status/'
 );

$response = $ecommerce->collect(
  'mtn_mobilemoney_cm',
  '677777777',
  400);
$ecommerce->print_response($response);

// $response = $ecommerce->collect(
//     'orange_money_cm',
//     '699999999',
//     400,
//     '0000',
//     '123azerty');
// $ecommerce->print_response($response);

//payout example
// $response = $ecommerce->payout(
//     'mtn_mobilemoney_cm',
//     '677777777',
//     300);
// $ecommerce->print_response($response);

// $response = $ecommerce->payout(
//     'orange_money_cm',
//     '699999999',
//     500);
// $ecommerce->print_response($response);

//balance deposit example
// $response = $ecommerce->deposit();
// $ecommerce->print_response($response);

//transaction status example
// $response = $ecommerce->transactionStatus('123azerty');
// $ecommerce->print_response($response);

//ecommerce hash
// $hash = $ecommerce->hash('ecommerce_collect');
// print_r($hash);

```

Bill integration
----------------

[](#bill-integration)

If you want to integrate bill payments apis on you system, here are the two main steps to get the job done in the development environment. You an uncomment the code to test the others apis.

```
require __DIR__.'/vendor/autoload.php';

use App\Bill;

//bill example
$bill = new Bill(
  '3620724907638658',
  '3620724907638658',
  'e825e83873eafffff315fc3f22db2d59',
  'afrikpay',
  'http://34.86.5.170:8086/api/bill/v2/',
  'http://34.86.5.170:8086/api/bill/getamount/',
  'http://34.86.5.170:8086/api/bill/status/v2/'
);

$response = $bill->payBill(
  'camwater',
  '111111111111111',
  2000,
  'cash',
  '16589'
);
$bill->print_response($response);

// $response = $bill->payBill(
//     'canal',
//     '11111111111111',
//     13500,
//     'cash',
//     '165899'
// );
// $bill->print_response($response);

// $response = $bill->getBillAmount(
//     'canal',
//     '11111111111111'
// );
// $bill->print_response($response);

// $response = $bill->getBillStatus(
//     '165899'
// );
// $bill->print_response($response);

```

Airtime integration
-------------------

[](#airtime-integration)

If you want to integrate airtime apis on you system, here are the two main steps to get the job done in the development environment. You an uncomment the code to test the others apis.

```
require __DIR__.'/vendor/autoload.php';

use App\Airtime;

//airtime example
$airtime = new Airtime(
  '3620724907638658',
  '3620724907638658',
  'e825e83873eafffff315fc3f22db2d59',
  'afrikpay',
  'http://34.86.5.170:8086/api/airtime/v2/',
  'http://34.86.5.170:8086/api/airtime/status/v2/'
);

//airtime status
$response = $airtime->makeAirtime(
  'mtn',
  '677777777',
  1000,
  'cash',
  'xyz123'
);
$airtime->print_response($response);

// $response = $airtime->airtimeStatus(
//     'xyz123'
// );
// $airtime->print_response($response);

```

Account integration
-------------------

[](#account-integration)

If you want to integrate account apis on you system, here are the two main steps to get the job done in the development environment. You an uncomment the code to test the others apis.

```
require __DIR__.'/vendor/autoload.php';

use App\Account;

$account = new Account(
  '3620724907638658',
  '3620724907638658',
  'e825e83873eafffff315fc3f22db2d59',
  'http://34.86.5.170:8086/api/account/agent/balance/v2/',
  'http://34.86.5.170:8086/api/account/agent/balance/v2/',
  'http://34.86.5.170:8086/api/account/developer/changekey/'
);

$response = $account->balance();
$account->print_response($response);

```

How to switch to production ?
-----------------------------

[](#how-to-switch-to-production-)

You can explore the src folder to see the default production setup. Just use the appropriate apikey, store code, agentid for production. If you have any problem using the library please contact us, we will be happy to help you.

License
-------

[](#license)

Distributed under the MIT License. See `LICENSE` for more information.

Contact
-------

[](#contact)

Project Link:

Acknowledgements
----------------

[](#acknowledgements)

-
-
-

###  Health Score

17

—

LowBetter than 6% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity29

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.

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/25526045?v=4)[GeorgesNgandeu](/maintainers/GeorgesNgandeu)[@GeorgesNgandeu](https://github.com/GeorgesNgandeu)

---

Top Contributors

[![Georges-Ngandeu](https://avatars.githubusercontent.com/u/84016842?v=4)](https://github.com/Georges-Ngandeu "Georges-Ngandeu (14 commits)")

### Embed Badge

![Health badge](/badges/afrikpay-tools-afrikpay-tools-php-sdk/health.svg)

```
[![Health](https://phpackages.com/badges/afrikpay-tools-afrikpay-tools-php-sdk/health.svg)](https://phpackages.com/packages/afrikpay-tools-afrikpay-tools-php-sdk)
```

###  Alternatives

[stripe/stripe-php

Stripe PHP Library

4.0k143.3M480](/packages/stripe-stripe-php)[twilio/sdk

A PHP wrapper for Twilio's API

1.6k92.9M272](/packages/twilio-sdk)[knplabs/github-api

GitHub API v3 client

2.2k15.8M187](/packages/knplabs-github-api)[facebook/php-business-sdk

PHP SDK for Facebook Business

90121.9M34](/packages/facebook-php-business-sdk)[meilisearch/meilisearch-php

PHP wrapper for the Meilisearch API

73813.7M114](/packages/meilisearch-meilisearch-php)[google/gax

Google API Core for PHP

263103.1M454](/packages/google-gax)

PHPackages © 2026

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