Aller au contenu
Tous les fournisseurs

KadevPay

paiement·🇨🇮·Sandbox disponible

KadevPay est une passerelle de paiement ivoirienne qui prend en charge le mobile money (Orange Money, MTN MoMo) et les paiements par carte via un SDK JavaScript côté client.

À utiliser avec des agents IA

Après avoir installé le plugin ou ajouté le serveur MCP, donnez cette consigne à votre agent :

« Initialise une session de paiement KadevPay et redirige le client pour qu’il finalise un paiement mobile money ou par carte. »
Installer le plugin →

Capacités

CapacitéTypeStatutiMéthodeExemple
create_checkout_sessionSDKDisponible
verify_paymentsynchroneDisponibleGET
webhook_payment_successwebhookDisponiblePOST

Gotchas

Les gotchas sont affichés tels qu’ils figurent dans les specs, dans leur langue d’origine.

create_checkout_session

  • ⚠Use the PUBLIC key (kdvp_*) in KadevPay.checkout(), not the secret key — the secret key is only for server-side verify_payment calls.
  • ⚠amount is a number in XOF (FCFA), not a string — e.g. 5000 for 5000 FCFA.
  • ⚠Save the transaction reference returned via the onSuccess callback — you need it to call verify_payment before fulfilling the order.
  • ⚠For method: 'card', KadevPay processes payments via Paystack internally — no additional Paystack integration is needed.
  • ⚠Always call verify_payment server-side after checkout — the onSuccess callback can be spoofed.

verify_payment

  • ⚠Use the SECRET key (kdvs_*), not the public key — using the wrong key returns 401.
  • ⚠reference is passed as a path parameter: GET /api/v1/transactions/verify/{reference}, not in the request body.
  • ⚠Check both conditions before fulfilling: top-level status === 'success' AND data.status === 'paid'. Checking only data.status is not sufficient — an invalid reference can return a non-success top-level status.
  • ⚠The reference comes from the browser (onSuccess callback or callback_url redirect), so validate it server-side before putting it in the path: a visitor can send "../…" and make this call, with your secret key, reach another endpoint. The docs give no format (only the example KDV-1775413916000), so the example rejects an empty value, ".", "..", and any /, \, ?, #, %, space or control character.
  • ⚠mode: 'test' appears in sandbox responses — check this field to distinguish test vs live transactions.

webhook_payment_success

  • ⚠Verify the signature: compute HMAC-SHA512(JSON.stringify(req.body), KADEVPAY_WEBHOOK_SECRET) and compare with the x-kadevpay-signature header — hash the re-serialized parsed body, not the raw request string. Use SHA-512, not SHA-256.
  • ⚠Only act on event === 'payment.success' — other event types may be added by KadevPay in the future.
  • ⚠net_amount is the actual revenue after KadevPay's 3% fee — use it for accounting, not amount.
  • ⚠Always call verify_payment server-side after receiving the webhook — never fulfill based on the webhook payload alone.
  • ⚠Return HTTP 200 immediately; process the event asynchronously. The webhook URL must be HTTPS and configured in the KadevPay dashboard.

Détails

Catégorie
paiement
Sandbox
Oui

Contributeurs de la spec