Créer un nouveau paiement (collect)
| Header | Description |
|---|---|
X-Idempotency-Key | Clé unique pour éviter les doublons (ex: ID de commande) |
| Champ | Type | Description |
|---|---|---|
type | string | direct ou checkout |
amount | number | Montant du paiement |
externalReference | string | Votre référence unique (ID commande) |
| Champ | Type | Description |
|---|---|---|
provider | string | Code du provider (wave, orange_money, etc.) |
country | string | Code ISO du pays (SN, CI, ML, etc.) |
customerPhone | string | Numéro du client (format E.164) |
| Champ | Type | Description |
|---|---|---|
currency | string | Devise (défaut: XOF) |
customerName | string | Nom du client |
customerEmail | string | Email du client |
description | string | Description du paiement |
callbackUrl | string | URL webhook pour notifications |
returnUrl | string | Redirection après succès |
cancelUrl | string | Redirection après annulation |
metadata | object | Données personnalisées (JSON) |
| Champ | Type | Description |
|---|---|---|
transactionId | string | ID unique de la transaction |
status | string | Statut initial (pending) |
redirectUrl | string | URL de paiement (rediriger le client) |
expiresAt | string | Date d’expiration |
deepLinks | object | Liens deep pour apps mobiles |
| Code | Message | Solution |
|---|---|---|
400 | Montant invalide | Vérifiez les limites du provider |
400 | Provider non disponible | Utilisez /payments/providers |
401 | Non authentifié | Vérifiez vos clés API |