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

manishapay

v1.0.0

Published

Official Node.js SDK for ManishaPay — a multi-gateway payments API (PayNow, Stripe, Paystack, Flutterwave, PayPal, M-Pesa, PayFast and more)

Readme

manishapay (Node.js SDK)

Official Node.js client for ManishaPay — one API for many payment gateways (PayNow, Stripe, Paystack, Flutterwave, PayPal, M-Pesa, PayFast and more). Pick the gateway per call with a provider field; your code stays the same.

Install

npm install manishapay

Requires Node ≥ 18 (uses built-in fetch).

Usage

const ManishaPay = require('manishapay');

const mp = new ManishaPay(process.env.MANISHAPAY_API_KEY);

const r = await mp.pay({
  reference: 'order-1234',
  amount: '5.00',
  description: 'Pro plan — annual',
  email: '[email protected]',
});

// Redirect customer:
console.log(r.browser_url);

// Or poll for status:
const status = await mp.status('order-1234');
console.log(status.status_normalized); // 'paid' | 'pending' | 'failed' | 'disputed' | 'refunded'

Choosing a gateway (provider)

provider is optional and defaults to 'paynow'. Set it to route the same call through any live gateway — the request and response shape don't change:

const r = await mp.pay({
  provider: 'stripe',        // paynow (default) | stripe | paystack | flutterwave | paypal | mpesa | payfast
  reference: 'order-1234',
  amount: '5.00',
  currency: 'USD',
  email: '[email protected]',
});

Express checkout (mobile money)

const r = await mp.pay({
  reference: 'order-1234',
  amount: '5.00',
  method: 'ecocash',         // ecocash | onemoney | innbucks | omari | zimswitch | vmc
  phone: '0772123456',       // any format — auto-normalised to 263…
});

Hosted checkout (method routing)

A payment link is a no-code hosted checkout at /pay/<slug>. It offers the customer a set of methods (EcoCash, Card, …) and routes each to whichever gateway you've connected that serves it. The simplest path is to just share the hosted page. To build your own checkout UI, fetch the method chooser and start the payment — both endpoints are public (no API key required):

// 1. Fetch the checkout + the methods the customer can pay with right now
const checkout = await mp.getCheckout('ab12cd34ef56');
// checkout.methods → [{ method, label, needsPhone, kind, provider, mode }, …]

// 2. The customer picks a method; start the payment (phone needed when needsPhone)
const r = await mp.payCheckout('ab12cd34ef56', {
  method: 'ecocash',
  phone: '0771234567',
});

if (r.browser_url) window.location = r.browser_url;   // redirect rails
// else: a phone push (EcoCash / M-Pesa STK) is already on the customer's device

Links are created from the dashboard (Payment Links), or via POST /v1/links with your dashboard session — set enabled_methods to choose which methods a link offers. Prefer a fully custom flow with no link? pay() already takes method.

Webhook verification

const express = require('express');
const ManishaPay = require('manishapay');

const app = express();
const WEBHOOK_SECRET = process.env.MANISHAPAY_WEBHOOK_SECRET;

app.post('/webhooks/manishapay',
  express.raw({ type: 'application/json' }),
  (req, res) => {
    const sig = req.header('X-ManishaPay-Signature');
    if (!ManishaPay.verifyWebhook(req.body, sig, WEBHOOK_SECRET)) {
      return res.status(401).send('bad signature');
    }
    const evt = JSON.parse(req.body.toString('utf8'));
    console.log('Payment update:', evt.data.reference, evt.data.status_normalized);
    res.send('ok');
  });

Test mode

When you create a mp_test_* API key and haven't yet added PayNow credentials, ManishaPay runs in fully simulated mode — no real PayNow call. The browser_url it returns points to manishapay.netlify.app/simulator/<tracker> where you can click Paid / Cancelled / Timeout buttons to fire signed webhooks to your endpoint.

Author

Built by Noby Tebulonobie.netlify.app · [email protected]

License

MIT © 2026 Noby Tebulo