Shopify Integration Indonesia Payment Gateway Full Flow
# Shopify Integration with Indonesia Payment Gateway Full Process Guide
I. Preliminary preparations
1. Understanding the characteristics of the Indonesian payments market
- Bank transfers (Direct Debit) dominate (about 40%)
- E-wallet popularity (OVO, GoPay, DANA, etc.)
- COD (cash on delivery) still accounts for a certain percentage
- Low credit card penetration (~5%)
2. Selection of a suitable Indonesian payment gateway
- Xendit: Supports multiple local payment methods
- Midtrans: providing one-stop solutions
- Doku: A Veteran Local Payment Service Provider
- Veritrans (formerly Midtrans)
3. Register for a merchant account
Completed on selected payment gateway platforms.
1) KYC Verification
2) API Key Acquisition
3) Webhook Configuration
Second, Shopify background configuration steps
A. Shopify Payments Settings (if applicable)
“`
1. Shopify Back Office > Settings > Payments
2. Select your gateway provider in the "Add payment methods" section.
3. (Third-party applications or custom integrations are required if no direct options are available)
“`
B. API Integration Methodology (using Xendit as an example)
1. Installation of the necessary plug-ins
"`bash
# Shopify App Store Search and install.
- Xendit Payment Gateway for Shopify or similar plugins
“`
2. Manual API integration steps
"`javascript
// Add script references to theme.liquid (Xendit example)
{% endif %}
“`
B. Webhook Security Authentication Best Practices
"`javascript
// Node.js Example - Xendit webhook authentication middleware
const crypto = require('crypto');
function verifyXenditWebhook(req, res, next) {
const callbackToken = process.env.XENDIT_CALLBACK_TOKEN;
// Step1: Get signature header and timestamp header
const xCallbackSignature = req.headers['x-callback-signature'];
}
“`
VI. Key indicators for performance optimisation
The 5 core metrics that must be monitored:
| Indicators | Compliance Thresholds | Recommended Measurement Tools |
|———————–|————-|————————-|
| API Response Time | ≤800ms | NewRelic/Datadog |
| Checkout Page Load Speed | ≤2s | Google PageSpeed Insights|
| Webhook Latency | ≤3s | AWS CloudWatch Metrics |
| Mobile Success Rate