One SDK. Every provider. Woven together.
Stripe, Paystack, and Flutterwave behind one typed client — with subscriptions, metered usage, a database layer, and a CLI built in, not bolted on.
import { createPayweave } from "payweave"const payweave = createPayweave({ paystack: { secretKey: process.env.PAYSTACK_SECRET_KEY! },})// One unified call — always minor units; the adapter converts.const checkout = await payweave.checkout.create({ amount: { value: 500_000, currency: "NGN" }, customer: { email: "ada@example.com" }, reference: "order_8123", redirectUrl: "https://app.example.com/pay/callback",})console.log(checkout.checkoutUrl)Wiring up payments usually means doing it three times.
- Hand-rolling fetch calls against each provider's own REST docs, one provider at a time.
- Copy-pasting webhook verification snippets — and frequently getting signature validation wrong.
- Writing your own subscription/plan bookkeeping and database schema by hand.
- Doing it all again the moment you add a second provider, a database, or usage-based billing.
The SDK fundamentals, done once, done right
Full endpoint coverage per provider, fully typed, with first-class webhook verification and a normalized layer when you want portability.
One client, every provider
Configure one or more of Stripe, Paystack, and Flutterwave under createPayweave and get a single, fully-typed client — no hand-rolled fetch calls.
Compile-time provider narrowing
Only configured providers appear on the client. Autocomplete never shows a namespace you didn't set up.
Webhooks, done correctly
One endpoint verifies every configured provider — raw bytes, constant-time comparison, fail-closed — then returns a typed, normalized event.
A capability-gated unified layer
Checkout, verify, refunds, transfers and banks, normalized across providers — gated by a capability matrix, so an unsupported call fails before it's sent, not after.
Errors that name the culprit
Typed subclasses tell you whether a failure is yours (validation/auth), the customer's (declined), or transient (network/5xx).
Money that can't drift
Always integer minor units in the unified layer; the adapters convert kobo, naira, and cents so you never fat-finger a decimal.
A billing platform, not just an API client
Persist state, define pricing, meter usage, and manage it all from a CLI — without reaching for a separate billing service.
Ship your first verified payment in under 10 minutes
Install once, configure a provider, and go from a checkout URL to a verified payment to a handled webhook.