Working example apps using the Sanwo payment SDK across multiple frameworks.
| Example | Framework | SDK |
|---|---|---|
| vanilla-js | Vite + Vanilla JS | @sanwohq/web |
| react | Vite + React + TypeScript | @sanwohq/react |
| nextjs | Next.js 14 (App Router) | @sanwohq/web |
| vue | Vite + Vue 3 + TypeScript | @sanwohq/vue |
| angular | Angular 18 | @sanwohq/web |
| svelte | Vite + Svelte 4 | @sanwohq/svelte |
| react-native | React Native CLI | @sanwohq/react-native |
| flutter | Flutter + Dart | sanwo_flutter |
| android | Android + Kotlin | com.github.Sanwohq.android |
| ios | SwiftUI (iOS 15+) | Sanwo (SPM) |
| laravel | Laravel (Blade) | sanwohq/laravel |
| dotnet | ASP.NET (Razor Pages) | Sanwo |
| embed | No-code / Any HTML page | @sanwohq/embed |
Each example is a standalone project. To run one:
cd <example-name>
npm install
npm run devReplace the placeholder public key (pk_test_xxx...) with your actual Paystack test key from the Paystack Dashboard.
All examples follow the same core pattern:
import { createSanwo } from "@sanwohq/web";
import { paystackProvider } from "@sanwohq/paystack";
const sanwo = createSanwo({
provider: paystackProvider,
publicKey: "pk_test_your_key_here",
});
const result = await sanwo({
amount: 500000, // 5000 NGN in kobo
currency: "NGN",
customer: { email: "user@example.com" },
});All examples demonstrate these 5 providers: Paystack, Flutterwave, Razorpay, Monnify, Interswitch.
- Web examples: Node.js 22+
- React Native: React Native CLI, Xcode/Android Studio
- Flutter: Flutter SDK 3.10+
- Android: Android Studio, JDK 17
- iOS: Xcode 15+, iOS 15+
- Laravel: PHP 8.1+, Composer
- .NET: .NET 8.0 or 9.0 SDK