npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

afrikpay-node-sdk

v1.0.5

Published

Afrikpay library for api payments

Readme

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

npm install npm@latest -g

Installation

npm install afrikpay-node-sdk

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 an uncomment the code to test the others apis.

import {Ecommerce} from 'afrikpay-node-sdk';

let 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/'
);

ecommerce.collect(
    'mtn_mobilemoney_cm',
    '677777777',
    350).then(function (response) {
        console.log(response.data);
    }).catch(function (error) {
        console.log(error);
    });

ecommerce.collect(
//     'orange_money_cm',
//     '699999999',
//     400,
//     '0000',
//     'wdl125').then(function (response) {
//         console.log(response.data);
//     }).catch(function (error) {
//         console.log(error);
//     });


// ecommerce.deposit()
//     .then(function (response) {
//             console.log(response.data);
//         }).catch(function (error) {
//             console.log(error);
//         });

// ecommerce.payout(
//     'mtn_mobilemoney_cm',
//     '677777777',
//     350).then(function (response) {
//         console.log(response.data);
//     }).catch(function (error) {
//         console.log(error);
//     });

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.

import {Bill} from 'afrikpay-node-sdk';

let 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/'
);

bill.payBill(
    'camwater',
    '111111111111111',
    2500,
    'cash',
    '321koi'
).then(function (response) {
    console.log(response.data);
}).catch(function (error) {
    console.log(error);
});

bill.payBill(
//     'canal',
//     '11111111111111',
//     13500,
//     'cash',
//     '321bgh'
// ).then(function (response) {
//     console.log(response.data);
// }).catch(function (error) {
//     console.log(error);
// });

// bill.getBillAmount(
//     'camwater',
//     '111111111111111'
// ).then(function (response) {
//     console.log(response.data);
// }).catch(function (error) {
//     console.log(error);
// });

// bill.getBillStatus(
//     '321bgh'
// ).then(function (response) {
//     console.log(response.data);
// }).catch(function (error) {
//     console.log(error);
// });

Airtime api 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.

import {Airtime} from 'afrikpay-node-sdk';

let 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.makeAirtime(
    'mtn',
    '677777777',
    1000,
    'cash',
    'zerty145'
).then(function (response) {
    console.log(response.data);
}).catch(function (error) {
    console.log(error);
});

airtime.airtimeStatus(
//     'zerty145'
// ).then(function (response) {
//     console.log(response.data);
// }).catch(function (error) {
//     console.log(error);
// });

Account api 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.

import {Account} from 'afrikpay-node-sdk';

let 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/'
);

account.balance()
    .then(function (response) {
        console.log(response.data);
    })
    .catch(function (error) {
        console.log(error);
    });

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

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

Contact

Project Link: https://github.com/Georges-Ngandeu/AfrikpayNodeSdk

Acknowledgements