20 October 2026
What if you could test almost every Razorpay payment failure without waiting for it to happen in production?
That question inspired me to build LocalPay — an open-source local emulator for Razorpay integrations.
When building payment systems, testing the happy path isn’t enough. What happens when a UPI payment times out, a bank goes down, a webhook arrives twice, or a refund takes longer than expected?
Developers need a reliable way to test these scenarios before shipping.
🚀 What LocalPay brings to the table:
- Simulate orders, payments, captures, and refunds locally.
- Test UPI timeouts, insufficient funds, and bank failures.
- Generate signed webhooks with retries, replay, and fault injection.
- Simulate duplicate, delayed, and out-of-order webhook deliveries.
- Fast-forward time to test refunds, subscriptions, expiries, and settlements.
- Run repeatable payment scenarios in CI/CD without production credentials.
- Inspect payment events and transaction flows through a local dashboard.
The goal: Make payment integration testing faster, more predictable, and easier for developers.
🛠️ Built with TypeScript, Node.js, Fastify, React, and a modular architecture, LocalPay also includes a CLI, Docker support, a GitHub Action, and example integrations for Express, Next.js, FastAPI, and Django.
🔓 Open source under the Apache 2.0 license.
GitHub: https://lnkd.in/dcJfsWUy
One important distinction: LocalPay is a testing emulator, not a real payment gateway. It never moves money and is not affiliated with or endorsed by Razorpay.
I’m building tools that help developers test the failure cases that matter—not just the scenarios where everything works.
Because reliable payment systems are built by testing what can go wrong.
Harshil Mathur , Shashank Kumar , Patrick Collison Vivek Agarwal
#OpenSource #FinTech #Razorpay #DeveloperTools #SoftwareEngineering #Payments Stripe Cashfree PayPal Postman GitHub Docker, Inc
GitHub - karthikrshet/localpay: Test your Razorpay integration offline. A free, open-source local emulator of the Razorpay API with a test checkout, signed webhooks, UPI and bank failure scenarios, fault injection, time travel and a dashboard. No keys, no ngrok, no internet. Not affiliated with Razorpay.
GitHub - karthikrshet/localpay: Test your Razorpay integration offline. A free, open-source local emulator of the Razorpay API with a test checkout, signed webhooks, UPI and bank failure scenarios, fault injection, time travel and a dashboard. No keys, no ngrok, no internet. Not affiliated with Razorpay.
github.com