API Reference
Complete reference documentation for the ZenPays API. Build powerful payment solutions with our comprehensive REST API.
Enterprise-Grade API
Built for developers, trusted by businesses of all sizes
Secure by Default
All API calls are secured with industry-standard encryption
High Performance
99.9% uptime with sub-100ms response times
RESTful Design
Clean, predictable REST API with JSON responses
Global Scale
CDN-powered API endpoints across multiple regions
API Explorer
Interactive documentation with live examples
/v1/payments
Create Payment
Create a new payment intent for processing
Example Request
curl -X POST https://api.zenpays.io/v1/payments \
-H "Authorization: Bearer sk_test_..." \
-H "Content-Type: application/json" \
-d '{
"amount": 50000,
"currency": "INR",
"payment_method": "upi",
"description": "Test payment",
"metadata": {
"order_id": "ORD-2023-001"
}
}'
/v1/payments/{id}
Retrieve Payment
Retrieve details of a specific payment
/v1/refunds
Create Refund
Process a refund for a successful payment
/v1/customers
Create Customer
Create a new customer profile
/v1/subscriptions
Create Subscription
Set up a recurring payment subscription
/v1/webhook_endpoints
Create Webhook
Register a new webhook endpoint
Quick Start Guide
Get API Keys
Sign up and get your test and live API keys from the dashboard
Install SDK
Choose your preferred language and install our official SDK
Make First Call
Create your first payment using our simple API
Go Live
Switch to live keys and start processing real payments
Authentication Example
// Initialize ZenPays
const zenpays = new ZenPays('sk_test_...');
// Create a payment
const payment = await zenpays.payments.create({
amount: 50000, // ₹500.00
currency: 'INR',
payment_method: 'upi',
description: 'Test payment'
});
console.log(payment.id);
// Output: pay_1234567890abcdef
Ready to Start Building?
Get your API keys and start integrating ZenPays into your application today.