Unified Pay Core
A unified payment processing library that simplifies integration with multiple payment gateways through a single, consistent API.
🚀 Features
- Multi-gateway support: Stripe, PayPal, and more
- Unified API: Single interface for all payment gateways
- TypeScript support: Full type safety and IntelliSense
- Webhook handling: Built-in webhook processing with signature verification
- Environment-based configuration: Secure credential management
- Test mode support: Easy testing with sandbox environments
- Consistent response format: Standardized responses across all gateways
Why Choose Unified Pay Core?
Instead of implementing separate SDKs for each payment provider, Unified Pay Core provides:
- Consistency: Unified API across all supported gateways
- Reliability: Built-in retry logic and comprehensive error handling
- Security: Webhook signature verification and secure practices
- Flexibility: Switch gateways easily or use multiple simultaneously
- Developer Experience: Clear TypeScript definitions and structured documentation
- Simplified Integration: Single interface for payment processing, refunds, and webhooks
🔗 Supported Gateways
Gateway | Status | Test Mode | Webhooks | Refunds | Verification |
---|---|---|---|---|---|
Stripe | ✅ Active | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |
PayPal | ✅ Active | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |
Razorpay | ✅ Active | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |
Square | 🚧 Coming Soon | - | - | - | - |
📦 Installation
npm install unified-pay-core
🔒 Security Best Practices
- Environment Variables: Store credentials in environment variables
- Webhook Verification: Always verify webhook signatures
- HTTPS: Use HTTPS in production for all endpoints
- Raw Body Parsing: Use raw body parsing for webhook endpoints
- Error Handling: Implement comprehensive error handling