Devlopeer yi

Ab API bu sa ekip di bëgg ci dëgg-dëgg

REST bu ñu mëna xalaat, caabi idempotency, webhook yu ñu sinye ak ab sandbox bu ame yoon yu ñu simule, ngir nga mëna integre lépp balaa benn frang di yëngu.

Ubbi kont
Defaru ngir devlopeer yi

Sa jot xaalis bu njëkk ak benn laaj rekk

REST bu set, JSON bu ñu mëna xalaat ak request id ci tontu bu nekk. Sandbox bi mel na ni production bi: benn API, benn nekkin, benn webhook.

  • Caabi sandbox ak production, ku nekk ak sa app
  • Webhook yu ñu sinye ak HMAC, ak aar ci replay
  • Caabi idempotency ci woote bu nekk bu yëngal xaalis
  • Njumte yu ñu tënk yu lay wax lu mu war a defaraat
  • Wone OpenAPI, mbooloo Postman ak llms.txt, ñépp génn nañu
  • Session fey yu ñu teg ak callback yu tallal ngir jokkukaay CRM, ERP ak bitik
POST /v1/collections
curl https://api.capayglobal.com/v1/collections \
  -H "Authorization: Bearer sk_test_..." \
  -H "Idempotency-Key: 9f1c-collect-01" \
  -H "Content-Type: application/json" \
  -d '{
    "amount": "2500",
    "currency": "XAF",
    "country": "CM",
    "method": "mobile_money",
    "msisdn": "2376XXXXXXXX",
    "merchant_reference": "order-1042"
  }'
201 Created
{
  "status": "success",
  "data": {
    "id": "col_9xKQ2mD41Vb8",
    "object": "collection",
    "status": "pending",
    "amount": "2500",
    "currency": "XAF",
    "country": "CM",
    "method": "mobile_money",
    "merchant_reference": "order-1042",
    "fees": {
      "platform_fee": "50",
      "provider_fee": "0",
      "total_fee": "50",
      "bearer": "merchant"
    },
    "net_amount": null,
    "livemode": false,
    "created_at": "2026-08-30T12:04:11Z"
  },
  "request_id": "req_b0f3d2c1"
}

Sa ndajale bu njëkk

Benn ñaan dafay sos xalaat u fey, delloo id u ñaan te, ci xaalisu telefon, yónnee ñaan bi ci telefonu feykat bi. Sandbox dafay doxe ni produksioŋ ci dëgg.

Jël sa caabi nattSos benn kont te caabi sandbox yi dinañu feeñ ci sa xët u defarkat ci saa si. Caabi produksioŋ dañuy ubbeeku ginnaaw dëggal u liggéey bi.
POST /v1/collections
curl -X POST https://api.capayglobal.com/v1/collections \
  -H "Authorization: Bearer sk_test_XXXXXXXXXXXX" \
  -H "Idempotency-Key: col-order-10482-a1b2c3" \
  -H "Content-Type: application/json" \
  -d '{
    "amount": "5000",
    "currency": "XAF",
    "country": "CM",
    "method": "mobile_money",
    "msisdn": "+237650000001",
    "merchant_reference": "order-10482"
  }'
Tontu
{
  "status": "success",
  "data": {
    "id": "col_7Qm3k1Xa9Zr4",
    "object": "collection",
    "status": "pending",
    "amount": "5000",
    "currency": "XAF",
    "auth_model": "STK_PROMPT",
    "livemode": false
  },
  "request_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
}
201 Created
Xaalis yi ay bindu desimaal lañu ci digu API bi te ay xeet yu ndaw ci teere bi, kon dara du réer. Woote bu ne bu di toxal xaalis dafay jël benn caabi idempotency te tontu bu ne dafa yóbbu id u ñaan bi nga mën a wax ndimbal.

SDK u serwëer

Ay muur yu sew yu am xeet ci kaw benn API REST bu bokk, ak idempotency ak seetlu xaatim ci biir.

TypeScript and NodeDinañu ko génne ci gaaw@capay/sdk
Import
import { Capay } from '@capay/sdk';

Nekkatul ci npm ba tey. Rëddu import bi ci kaw mooy bu mujj bi, kon sa integrasioŋ du soppiku bu ñu ko génnee.

Jàng jukki bi
PythonDinañu ko génne ci gaawcapay
Import
from capay import Capay

Nekkatul ci PyPI ba tey. Rëddu import bi ci kaw mooy bu mujj bi, kon sa integrasioŋ du soppiku bu ñu ko génnee.

Jàng jukki bi
PHPDinañu ko génne ci gaawcapay/capay-php
Import
use Capay\CapayClient;

Nekkatul ci Packagist ba tey. Rëddu import bi ci kaw mooy bu mujj bi, kon sa integrasioŋ du soppiku bu ñu ko génnee.

Jàng jukki bi

Seetlu webhook bu ne

Xaatim yi dañu leen di xayma ci yaram bu tuub bi te mengale ci jamono ju sax, te benn màndarga u jamono bu ëpp 300 saa dañu koy bàyyi. Bul wóolu benn webhook bu nga seetlu wul.

X-Capay-Signature
# T is the t= value from X-Capay-Signature; delivery.json is the raw body as received.
T=1767225600
SECRET=whsec_XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

{ printf '%s.' "$T"; cat delivery.json; } \
  | openssl dgst -sha256 -hmac "$SECRET" -r | cut -d' ' -f1
# Compare the printed hex with each v1= value in the header (either may match
# during a secret rotation), and reject the delivery if |now - T| > 300 s.
Bopp u xaatim
X-Capay-Signature: t=1767225600,v1=6f8b4c2d9e0a1b3c5d7e9f0a2b4c6d8e0f1a3b5c7d9e1f0a2b4c6d8e0f1a3b5c
X-Capay-Event-Id: evt_2n4Kq8Zr41Xa
X-Capay-Event-Type: collection.completed
Yónnee ak jéem bu bees

Yónnee bu antuwul dañu koy jéemaat ci tabax bu sax: 1m, 5m, 30m, 2h, 6h, 12h, 24h, 24h. Benn endpoint bu antuwul 8 yoon topp ci topp dañu koy fey te wax la ko, kon endpoint bu dee du lekk ay xew ci kumpa.

Ñaari kumpa u xaatim mën nañu doxal ci benn jamono, kon mën nga leen soppi te réerul benn xew. Bàyyi lu ne lu génn palanteeru 300 saa te denc id u xew bi ngir bu delloo bi am jafe jafe.

Yeneen jumtukaay yi

Wone yu masin mën a jàng, mbooloo mu nga mën a dugal, ak jumtukaay yu leen di jàng.

llms.txtDokimaan bépp bu ñu tas ngir dimbalikat u kodd, ngir sa AI tontu ci sunu API ci sunu bind.Wone OpenAPIKontaraa bu mat, bu jóge ci API bi. Dugal ko ngir tabax kliyaan ci làkk bu ne.Mbooloo PostmanEndpoint bu ne ak yaram u misaal ak soppeeku u barab, jekk ngir doxal ci sandbox.
Bindu ndigalDafay ñëwSos fey yu natt, topp xew yi te delloo webhook ci sa masin.@capay/cli
Serwëer MCPDafay ñëwJox sa dimbalikat u kodd ndigal u jàng sa sandbox ngir mu tontu ak sa dëggu dénkaane.@capay/mcp
Skript u feyDafay ñëwUbbi xët u fey bi ci palanteer ci sa xët bi, du yóbbu ci beneen barab.https://pay.capayglobal.com/capay.js

Tàmbalil jot payement ci Afrig gépp tey

Ubbil ab kont bu amul njëg, defaral ci sandbox bi te tàmbali ci production bu ñu verifiyee.

Ubbi kont

Wax nu say koridoor ak say volim ci waxtu wu la neex.