Skip to main content

Documentation Index

Fetch the complete documentation index at: https://developers.ligdicash.com/llms.txt

Use this file to discover all available pages before exploring further.

Identity

FieldValue
OperatorLigdiCash Wallet
operator_id-
operator_nameLIGDICASH [OPERATOR_NAME]
Number formatcountry code + local number (no + or spaces)
Validation modeSMS OTP
The LigdiCash Wallet uses two endpoints distinct from the other operators (/v02). The flow is different: a first call triggers the OTP being sent, a second call submits the transaction with the OTP.

Validation mode: SMS OTP

The customer receives an OTP code on their LigdiCash app or by SMS after your first request. They share this code with you. You then submit a second request with the OTP to finalize the transaction.
1

Collect the customer's number

Your form collects the phone number associated with the customer’s LigdiCash account.
2

Send the OTP — first request

Call GET /pay/v02/debitotp/{phone_number}/{amount}. LigdiCash sends an OTP to the customer.
3

Display the OTP field

After confirmation that the OTP was sent ("error": false), display an input field for the OTP. Tell the customer to check their LigdiCash app or SMS messages.
4

Submit with the OTP — second request

Call POST /pay/v02/debitwallet/withotp with the number in customer and the OTP in otp.
5

Wait for the callback

Show a waiting indicator. Confirmation arrives via your callback_url.

Step 1 — Send the OTP

GET https://app.ligdicash.com/pay/v02/debitotp/{phone_number}/{amount}
The phone_number and amount parameters are path parameters, not a JSON body.

Headers

Apikey
string
required
The API key of your LigdiCash project.
Authorization
string
required
Your API TOKEN prefixed with Bearer .
Accept
string
required
Must be application/json.

Path parameters

phone_number
string
required
Customer’s phone number in the format country code + local number, without + or spaces.
amount
integer
required
Amount in XOF (integer, no decimals).

Example

curl -X GET "https://app.ligdicash.com/pay/v02/debitotp/22670000000/5000" \
  -H "Apikey: {API_KEY}" \
  -H "Authorization: Bearer {API_TOKEN}" \
  -H "Accept: application/json"

Response

Success
{
  "error": false,
  "message": "OTP sent. Please check your phone."
}
Check that error is false before displaying the OTP field. If error is true, show an error message and do not offer OTP input.

Step 2 — Validate with the OTP

POST https://app.ligdicash.com/pay/v02/debitwallet/withotp

Headers

Apikey
string
required
The API key of your LigdiCash project.
Authorization
string
required
Your API TOKEN prefixed with Bearer .
Accept
string
required
Must be application/json.
Content-Type
string
required
Must be application/json.

Body

Same structure as the /pay/v01/straight/checkout-invoice/create endpoint, with customer filled and otp containing the code received by the customer.

Example

curl -X POST https://app.ligdicash.com/pay/v02/debitwallet/withotp \
  -H "Apikey: {API_KEY}" \
  -H "Authorization: Bearer {API_TOKEN}" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{
    "commande": {
      "invoice": {
        "items": [
          {
            "name": "Pro Subscription",
            "description": "Premium access for 1 month",
            "quantity": 1,
            "unit_price": 5000,
            "total_price": 5000
          }
        ],
        "total_amount": 5000,
        "devise": "XOF",
        "description": "Pro Subscription — January 2025",
        "customer": "22670000000",
        "customer_firstname": "Amadou",
        "customer_lastname": "Diallo",
        "customer_email": "amadou@example.com",
        "external_id": "",
        "otp": "123456"
      },
      "store": {
        "name": "MyApp",
        "website_url": "https://myapp.com"
      },
      "actions": {
        "cancel_url": "",
        "return_url": "",
        "callback_url": "https://myapp.com/api/callback/ligdicash"
      },
      "custom_data": {
        "transaction_id": "ORD-2025-00042"
      }
    }
  }'

Expected response

{
  "response_code": "00",
  "token": "eyJ0eXAiOiJKV1Qi...",
  "response_text": "Votre requête est en cours de traitement",
  "wiki": "https://client.ligdicash.com/wiki/createInvoice"
}
Store the token returned by /debitwallet/withotp. This is the one you will use to call confirm when the callback is received.

Limits

ParameterValue
Minimum amount10 XOF
Maximum amount2,000,000 XOF
Daily limit