Developer Guide
Accept card and mobile-money payments across Côte d'Ivoire, Guinea, and Mali — with a REST API and the typed @sayele/sdk client.
Keys & authentication
Create a secret key (sk_live_…) on the Developers page. Send it as a bearer token on every request:
Authorization: Bearer sk_live_…Keep secret keys server-side only. For browser payments, use payment links + hosted checkout (below), which never expose your key.
Core concepts
- Amounts are integer minor units. XOF and GNF are zero-decimal, so
amountMinoris the number of francs (2 500 XOF →2500). - Idempotency. Every write takes an
idempotencyKey; retrying with the same key returns the original result — never double-charges. - Statuses:
pending → processing → settled, or→ failed. - Instruments are tokenized — you send a PSP token or an MSISDN, never a raw card number.
Quickstart (SDK)
npm install @sayele/sdkimport { SayeleGate } from "@sayele/sdk";
const gate = new SayeleGate({
apiKey: process.env.SAYELE_KEY!, // sk_live_…
baseUrl: "https://api.gate.sayele.co",
checkoutBaseUrl: "https://pay.gate.sayele.co",
});
// No-code payment link:
const link = await gate.paymentLinks.create({
amountMinor: 2500, currency: "XOF", country: "CI", reference: "Order #1042",
});
console.log(link.checkoutUrl);Hosted checkout & payment links
Create a payment link, send the customer to link.checkoutUrl, and they pay in three taps — card or mobile money, operator auto-detected from their phone. You're notified when it settles.
REST endpoints
POST /v1/transactions— create a pay-in.GET /v1/transactions/:id·GET /v1/transactions— read.POST /v1/payouts— create a pay-out (disbursement).GET /v1/payouts/:id·GET /v1/payouts— read pay-outs.POST /v1/payment-links— create a link.GET /v1/checkout/:token·POST /v1/checkout/:token— public checkout.GET /v1/reporting/summary·GET /v1/settlements— dashboard data.
Pay-ins & pay-outs (for partner apps)
Charge a customer with pay-in (POST /v1/transactions) and send money to a recipient with pay-out (POST /v1/payouts). Both are idempotent (send a unique idempotencyKey), keep money in integer minor units, and are authorized with your secret API key — ideal for embedding in your own and your partners' mobile apps. A pay-out debits your available balance and can never exceed it.
curl -X POST https://api.gate.sayele.co/v1/payouts \
-H "authorization: Bearer sk_live_…" \
-H "content-type: application/json" \
-d '{
"idempotencyKey": "payout-8f3c1a",
"amountMinor": 50000,
"currency": "XOF",
"country": "CI",
"method": "mobile_money",
"operator": "wave",
"customerReference": "PAYOUT-1042",
"instrument": "+2250700000000"
}'Countries, currencies & operators
| Country | Currency | Mobile money |
|---|---|---|
| Côte d'Ivoire | XOF | Orange, MTN, Wave, Moov |
| Mali | XOF | Orange, Moov |
| Guinea | GNF | Orange, MTN |