For developers

An API that tells
the truth

Payments in the real world time out, half-complete, and answer late. Lango's API is designed around that: a payment is unknown until we know, never failed while the network is deciding — because "failed" makes customers pay twice.

# 1. Create the charge (safe to retry — same key, same result)
curl https://api.lango.co.zw/v1/payments \
  -H "Authorization: Bearer sk_test_..." \
  -H "Idempotency-Key: order-4417" \
  -d amount=10000 -d currency=USD \
  -d method=ecocash -d reference=ORD-4417 \
  -d "customer[msisdn]=263771234567"

# 2. The customer approves on their phone.
# 3. Your webhook hears about it — signed, so you can trust it:
#    Lango-Signature: t=1727286000,v1=hmac-sha256(...)
#    event: payment.succeeded

Sandbox from minute one

Register and you have test keys immediately. Ten deterministic test numbers simulate success, declines, timeouts, late answers — every outcome you'll meet in production.

Idempotency everywhere

Every POST takes an Idempotency-Key. Retry a request after a network blip and you get the original result back, never a second charge.

Preview before you charge

POST /v1/preview quotes any amount with the same engine that charges — build fee displays and quotes that cannot drift from what actually happens.

Signed webhooks

HMAC-SHA256 with a timestamp, five-minute tolerance, retried on a published schedule for 24 hours. Verify with one function call in our SDKs.

Honest states

Twelve payment statuses that mean what they say. unknown exists because sometimes the network really doesn't know yet — and we chase it so you don't.

Errors written for humans

Every error says what happened and what to do next, with a request id you can quote to support. No blame, no jargon, no dead ends.

Test numbers

Break it before your customers do

In the sandbox, the customer number chooses the outcome. A few of the ten:

NumberScenarioFinal status
263771000001Customer approvescompleted
263771000002Customer declines the PIN promptfailed
263771000003Customer never answersexpired
263771000004Insufficient fundsfailed
263771000007Provider answers latecompleted, on the third query
263771000009Provider returns HTTP 500unknown, then completed

Full reference — all ten scenarios, webhooks, and the five-minute quickstart — ships with the docs site at docs.lango.co.zw.