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

POST/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"
    }
  }'
GET/v1/payments/{id}

Retrieve Payment

Retrieve details of a specific payment

POST/v1/refunds

Create Refund

Process a refund for a successful payment

POST/v1/customers

Create Customer

Create a new customer profile

POST/v1/subscriptions

Create Subscription

Set up a recurring payment subscription

POST/v1/webhook_endpoints

Create Webhook

Register a new webhook endpoint

Quick Start Guide

01

Get API Keys

Sign up and get your test and live API keys from the dashboard

02

Install SDK

Choose your preferred language and install our official SDK

03

Make First Call

Create your first payment using our simple API

04

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.

View Documentation