More
Migrating from v2
From the multi-tenant service and lokipay-sdk to v3.
LokiPay v3 replaces the multi-tenant cloud service (dashboard.getlokipay.com), the Expo mobile app and the lokipay-sdk npm package. Each business now gets its own deployment, so there are no merchant sign-ups, plans or public/secret key pairs.
What changed#
| v2 | v3 |
|---|---|
| Shared cloud, merchant accounts, billing plans | One self-hosted deployment per business, set up by us |
pk_live_ / sk_live_ keys | One server-side API key (lp_live_…) from Settings → API keys |
lokipay.createOrder(...) | POST /v1/intents |
waitForPayment() / polling status | Webhook payment.verified (or GET /v1/intents/:id) |
<LokiPayCheckout /> | Redirect to checkoutUrl (hosted checkout) |
claimTransactionId() | POST /v1/intents/:id/claim |
LokiPay.verifyWebhookSignature() | The 10-line verifier in verify signatures — same algorithm |
| References LP-82910 | 8-character references with LP anywhere, e.g. 4KLP7QMX |
| Expo app with merchant login | Flutter LokiPay Relay, paired by QR |
| — | Payment links, hosted pages, review queue, parsers, OTA app updates |
The SDK is retired#
lokipay-sdk is deprecated and no longer needed: payment creation is a single authenticated HTTP call, checkout is hosted, and webhook verification is a few lines in any language. Remove the package and use the snippets in these docs.
Migration steps#
- We deploy LokiPay v3 on your server and domain.
- Install LokiPay Relay on your MoMo phone and pair it.
- Generate an API key and set your webhook URL; deploy your backend changes (create intents, verify the new webhook payload).
- Switch your checkout to the new flow; keep the old one until open v2 orders are settled.
Webhook payload differences
v3 sends { id, type, created, data } with type one of payment.verified, payment.review, payment.expired, payment.rejected. Your order ID is data.reference; the amount received is data.receivedAmountPesewas.
