TheDocumentation Index
Fetch the complete documentation index at: https://developers.ligdicash.com/llms.txt
Use this file to discover all available pages before exploring further.
confirm endpoint lets you verify the status of an invoice from the token obtained at creation. Call it from your backend — after the redirect to return_url, or from your callback handler before fulfilling the order.
Headers
The API key of your LigdiCash project.
Your API TOKEN prefixed with
Bearer . Example: Bearer eyJ0eXAiOiJKV1Qi...Must be
application/json.Parameters
The token returned by the
create endpoint when the invoice was created.Request example
Response fields
"00" if the API call succeeded, "01" on a technical error. This field indicates the success of the confirm request, not the payment outcome — use status for that.Payment status. See the table below.
May be empty in the
confirm response.Complementary message or error sub-code in the form
Echec (CodeXX). Consult wiki for the description. Empty if no error.Free-form description of the transaction. Can be empty.
Numeric identifier of the operator used for the payment. Example:
"14" for Moov CI. Empty if the status is pending.Operator name. Example:
"MOOV CI". Empty if the status is pending.Phone number of the payer in the format
226XXXXXXXXX. May be null if the payment is still pending.Transaction amount in XOF.
Same as
montant. Both fields are always present and hold the same value.Date and time of the transaction in the format
YYYY-MM-DD HH:MM:SS+TZ. Example: "2026-04-15 11:19:28+00".Concatenation of
valueof_customdata values whose key (keyof_customdata) contains "id", separated by ;. Matches the value of your transaction_id if you follow the recommended pattern.Operator reference. Can be empty.
Unique request identifier on the LigdiCash side. Useful for support.
Your metadata as sent at creation, enriched by LigdiCash (which adds entries like
logfile). Each entry contains:Customer information entered during payment.
URL to the documentation of error codes for this endpoint. Consult when
response_code is "01".status values
status | Meaning | Recommended action |
|---|---|---|
completed | Payment confirmed | Fulfill the order |
pending | Awaiting operator confirmation | Wait, recheck, or wait for the callback |
notcompleted | Payment did not go through (cancelled or failed) | Offer to retry |
Response example
Reading custom_data in the response
custom_data returns an array of your metadata enriched by LigdiCash (which adds entries like logfile). To retrieve your transaction_id:
JavaScript
When to call confirm
1. After the redirect to return_url
From your frontend, trigger a call to your backend, which calls confirm with the stored token. Never call confirm directly from the browser — your API keys would be exposed.
2. In your callback handler
Before fulfilling an order following a callback, always re-verify the status with confirm. A forged payload could be sent by anyone who knows your endpoint URL.
Polling pattern
If the callback is unavailable or slow to arrive, pollconfirm at regular intervals:
JavaScript
Polling is a safety net, not the primary strategy. Always prefer the callback. See Polling vs callback for trade-offs.
Related pages
- Redirect the customer — getting the creation token
- Callback — security — why always re-verify
- Parsing custom_data — reading metadata safely
- Polling vs callback — choosing the right strategy
- Response codes and statuses — full reference
