Payout

This documentation explains how to integrate Money Fusion's withdrawal API and how to manage webhooks related to withdrawal events.

Authentication

Authentication Illustration

Before making a withdrawal request, you must (go to the Settings section):

  1. Generate an API key from your Money Fusion dashboard.
  2. Add your server's IP address (the one sending the request) in the dashboard.
  3. Include this API key in the HTTP request headers:
moneyfusion-private-key: YOUR_API_KEY
Content-Type: application/json

Withdrawal Endpoint

POST https://pay.moneyfusion.net/api/v1/withdraw

Request Body (JSON)

{
  "countryCode": "ci",
  "phone": "05xxxxxxxxx",
  "amount": 200,
  "withdraw_mode": "mtn-ci",
  "webhook_url": "https://your-server.com/api/withdraw/callback"
}

Response if successful

{
  "tokenPay": "D0h6fjyjkCfi",
  "statut": true,
  "message": "Retrait soumis avec succès"
}

Response in case of error

{
  "statut": false,
  "message": "Tous les champs (countryCode, phone, amount, withdraw_mode) sont requis."
}

About tokenPay

The tokenPay field is a unique identifier generated when initiating a withdrawal.
It is used to track and verify the transaction. This token should be stored on your client or server as it will be used for:

  • Validating and identifying the transaction in webhook notifications.
  • Linking the initial request to its final status.

This token ensures traceability and security of the withdrawal process.


Required or Not Parameters (JSON body)

FieldTypeRequiredDescription
countryCodestringCountry code (e.g., ci for Côte d’Ivoire)
phonestringPhone number to withdraw to
amountnumberAmount to withdraw
withdraw_modestringWithdrawal method
webhook_urlstringNOURL to which Money Fusion will send the notification

Supported Withdrawal Methods (withdraw_mode)

Here are the supported values for withdraw_mode and countryCode:

CountrycountryCodewithdraw_mode
Côte d'Ivoireciorange-money-ci / mtn-ci / moov-ci / wave-ci
Senegalsnorange-money-senegal / free-money-senegal / wave-senegal / expresso-senegal
Burkina Fasobforange-money-burkina / moov-burkina-faso
Beninbjmtn-benin / moov-benin
Togotgt-money-togo / moov-togo
Malimlorange-money-mali
Congo Brazzavillecgorange-money-mali / mtn-cg
Camerouncmorange-money-cm / mtn-cm
Congo RDCcdairtel-money-cd
Gabongaairtel-money-ga / libertis-ga
Ghanaghairtel-money-gh / mtn-gh / vodafone-gh
Guinée Conakrygnorange-gn / mtn-gn
Guinée-Bissaugwmtn-gw
Kenyakem-pesa-ke
Mauritaniemrbankily-mr
Nigerneairtel-money-ne / mtn-ne / mauritel-ne
Ougandaugmtn-ug
Centrafriquecforange-cf
Rwandarwmtn-rw
Sierra Leoneslafricell-sl / orange-sl
Tanzanietzairtel-money-tz / m-pesa-tz / tigo-tz
Tchadtdairtel-money-td / moov-td
Gambiegmorange-gm
Éthiopieetsafaricom-et

Webhooks

Your server must listen for the following events on the webhook_url you provided:

- payout.session.completed
- payout.session.cancelled

Sample Webhook Payload

{
  "event": "payout.session.cancelled",
  "tokenPay": "D0h6fjyjkCfi",
  "montant": 205,
  "numeroRetrait": "07xxxxxxxxx",
  "moyen": "orange-money-ci",
  "webhook_url": "https://votre-serveur.com/api/withdraw/callback",
  "createdAt": "2025-07-17T17:35:23.468Z"
}

Possible Events

EventDescription
payout.session.completedThe withdrawal was successfully processed
payout.session.cancelledThe withdrawal failed or was canceled

Code Example (Node.js / Express)

// Webhook Endpoint
app.post("/api/withdraw/callback", (req, res) => {
  const { event, tokenPay, montant, numeroRetrait, moyen, createdAt } =
    req.body;

  if (event === "payout.session.completed") {
    // Mark the withdrawal as successful in your DB
  } else if (event === "payout.session.cancelled") {
    // Mark the withdrawal as failed in your DB
  }
});