PayCentral › ›
5
6
< 2s
99.9%
Uptime SLA
x-text: $store.lang==='fr'?'Votre clé API':'Your API key'
X-Api-Key: sk_sandbox_xxxxxxxxxxxxxxxxxxxx
cURL
curl -X POST https://api-paycentral.gabondunumerique.com/api/v1/payment/initiate \ -H "X-Api-Key: sk_sandbox_xxxx" \ -H "Content-Type: application/json" \ -d '{ "amount": 5000, "currency": "XAF", "phone": "237691234567", "description": "Commande #123", "merchant_reference": "ORDER-123", "callback_url": "https://votresite.com/webhooks/paycentral" }'
JSON
{ "success": true, "message": "Paiement initié avec succès", "data": { "transaction_id": "txn_01HXYZ...", "status": "pending", "provider": "mtn", "amount": 5000, "currency": "XAF" } }
| Sandbox | sk_sandbox_ |
|
| Live | sk_live_ |
| Code | ||
|---|---|---|
| 200 | ||
| 400 | Bad Request | |
| 401 | Unauthorized | |
| 403 | Forbidden | |
| 404 | Not Found | |
| 422 | Unprocessable | |
| 500 | Server Error |
JSON
{ "success": false, "message": "Clé API invalide ou expirée.", "errors": null }