v1
latestOpenAPI 3.0.32026-07-248257161.1 KBCheckout
Complete an initiated payment request
Use this endpoint to complete an initiated charge request. When a request to /charges endpoint is initiated without precising the payment method, the system create a charge objet and redirect payment page url. Hence the customer can select the payment method and complete the form if needed then confirm payment
patch/charges/{chargeId}
Path parameters
chargeIdstring uuid required
Unique identifier of the charge object.
Query parameters
payment_type'wave_money' | 'orange_money' | 'maxit' | 'mtn_money' | 'free_money' | 'moov' | 'mobicash' | 'togocell' | 'bictorys' | 'card'
The type parameter allows to select the checkout service provider. E.g mtn_money, orange_money, wave_money, move_money
Headers
Op-Tokenstring required
value of op_token returned in the CheckoutLinkObject
X-Amzn-Trace-Idstring
HTTP request identifier allow to trace individual request sent from client to service.
Request body
Example request
{
"amount": 10000,
"currency": "XOF",
"orderDetails": [
{
"id": "fbd2053b-638d-4133-957e-3caf63e6b79c",
"name": "pineapple",
"reference": "SKU56789002",
"price": 100,
"quantity": 2.5,
"discount": 20,
"taxRate": 5.5,
"totalPrice": 125
}
],
"paymentReference": "yourOrder_CF34509",
"deviceId": "SN-4562345",
"customerId": "fbd2053b-638d-4133-957e-3caf63e6b79c",
"customerObject": {
"id": "fbd2053b-638d-4133-957e-3caf63e6b79c",
"name": "John Dao",
"email": "john.dao@example.com",
"address": "23, avenue de la liberté",
"city": "Dakar",
"country": "SN",
"locale": "fr-FR",
"createdAt": "2022-06-20T17:17:11Z",
"updatedAt": "2022-06-20T17:17:11Z"
},
"country": "SN",
"cardObject": {
"holderName": "John Dao",
"number": "4444 1234 1234 1234",
"expMonth": 7,
"expYear": 2026,
"cvv": 123,
"browserInfo": {
"browserAcceptHeader": "application/json",
"browserJavaEnabled": true,
"browserLanguage": "en",
"browserTZ": "0",
"browserUserAgent": "enMozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/96.0.4664.93 Safari/537.36",
"browserColorDepth": "30",
"browserScreenHeight": "1055",
"browserScreenWidth": "1680",
"browserJavascriptEnabled": true,
"browserIP": "192.168.1.1",
"challengeWindowSize": "05"
}
},
"tokenizedCardObject": {
"cardId": "fbd2053b-638d-4133-957e-3caf63e6b79c",
"cvv": 123
},
"authorization": true,
"merchantReference": "33e1c83b-7cb0-437b-bc50-a7a58e5660ad",
"successRedirectUrl": "https://example.com?status=success",
"errorRedirectUrl": "https://example.com?status=fails"
}Response
The payment transaction is initiated. The body response content a payment link
Example response
{
"transactionId": "abd2053b-638d-4133-957e-3caf63e6b79c",
"redirectUrl": "https://example.com/home.html",
"merchantReference": "33e1c83b-7cb0-437b-bc50-a7a58e5660ad",
"type": "MobilePaymentObject",
"link": "https://pay.mobilemoney.com/checkouts/v1/confirm?x_ref=abd2053b-638d-4133-957e-3caf63e6b79c",
"qrCode": "iVBORw0KGgoAAAANSUhEUgAAAMgAAADIAQAAAACFI5MzAAABcElEQVR4Xu2WsXLEIAxE5YrP4E/B/CmfQYWyuxBPcjOXIg0qTuPzYD2KZYXgzN+FvSae+JC/yTDE5d684z2T30zkGCRDYhuAvSTKbfiNKOS23MSxgsKxXaGI94pBouRwRF8/30GIUykTBVtQwpkMQdQlJPt56Z+TZIVKjVzVIhgRCIxELvlc2h2cs0IQR3k76ozenTBy8Jih9hiEMpm2iimJj23VpwkEOu2073ujPF4HIFPVvlOv9FJXh9HR82S7iDuWpNBXRQTCzuhQakv1Gu/1nCYMGrkJDeYiQhCVl3tQORDMnEEIg1uvQbhZXdaOx9GjBC8eMKY9yFJXqN774DRx9m7RdYFBZdOEISoy20LtUukrBh6CrBhWpH1Nufd6ThNtwGug1OD7D9RMWs95kpFqu+aU7OzpKORWeZv6WIt4VMcgg6ai4BcdxQkdiXiH2rprjlk5CMHHL9U4+bbq4wRyKbPpmKmSHIW8iw/5H/kCX34lmUXkLmkAAAAASUVORK5CYII=",
"message": "you will receive a sms with instructions to accept payment."
}