Payments API
Process payment
Section titled “Process payment”Payments are processed through the checkout flow. The payment gateway is selected based on configuration.
Get payment
Section titled “Get payment”GET /api/v1/payments/:idAuthorization: Bearer <token>Refund payment
Section titled “Refund payment”POST /api/v1/payments/:id/refundAuthorization: Bearer <admin_token>{ "amount": 50.00, "reason": "Customer request"}Partial refunds supported.
Payment gateways
Section titled “Payment gateways”Stripe
Section titled “Stripe”- Secret key:
sk_test_...orsk_live_... - Publishable key:
pk_test_...orpk_live_... - Supports: cards, Apple Pay, Google Pay, 3D Secure
Airwallex
Section titled “Airwallex”- Client ID: from Airwallex dashboard
- API key: from Airwallex dashboard
- Supports: cards, WeChat Pay, Alipay, 3D Secure
Mock (testing)
Section titled “Mock (testing)”Always available for testing. Simulates successful payments.
Webhooks
Section titled “Webhooks”Payment status changes trigger webhooks:
payment.succeededpayment.failedrefund.succeeded
Register webhook endpoints via API or admin.