Integrate ZSI Payinto your application
Follow our step-by-step integration guide to start accepting secure online payments through ZSI Pay. Choose your preferred integration method and get your payment flow up and running.
Choose your approach
Start with the integration that fits your stack
ZSI Pay provides flexible integration options so you can connect payments with your application the way you prefer.
Quick start
Get your first payment running quickly
The basic ZSI Pay integration follows a simple server-to-server payment flow. Your backend creates the payment, your customer completes checkout, and ZSI Pay notifies your application about the payment result.
const response = await fetch(
"https://api-pay.zsi.ai/v1/payments", {
method: "POST",
headers: {
"x-zsi-api-key": process.env.ZSI_API_KEY,
"x-zsi-api-secret": process.env.ZSI_API_SECRET,
"Content-Type": "application/json",
},
body: JSON.stringify({
customer_email: "customer@example.com",
merchant_transaction_id: "ORDER-10001",
success_url: "https://merchant.com/payment/success",
cancel_url: "https://merchant.com/payment/cancel",
items: [{
name: "Premium Plan",
quantity: 1,
price: 15000
}],
metadata: {
order_type: "subscription",
customer_id: "CUS-78421",
source: "web"
}
}),
}
);Integration flow
From setup to production
Follow these steps to connect ZSI Pay with your application.
Get your API credentials
Create your ZSI Pay account and obtain the API key and API secret required to authenticate your integration.
Create a payment
Send the payment details to ZSI Pay and create a secure payment session for your customer.
Redirect your customer
Redirect the customer to the ZSI Pay checkout experience so they can securely complete the payment.
Handle payment events
Configure webhooks to receive real-time payment status updates and keep your order system synchronized.
Verify the payment
Verify the final payment status on your server before fulfilling the customer's order or service.
Go live
Test your complete integration in the appropriate environment and switch to production when everything is ready.
Keep your integration secure
Your API credentials and payment operations should be handled securely on your backend. Avoid exposing secret credentials in browser-side code and always verify payment status before completing an order.
Developer resources
Everything you need to integrate
Explore the documentation and tools available for building your ZSI Pay integration.
Ready to integrate ZSI Pay?
Start with our developer documentation or talk directly with our team about your payment integration requirements.
