Payment go-live checklist
Before production
-
PAYMENTS_ENV=production,PAYMENTS_ALLOW_SIMULATION=false,POS_MPESA_SIMULATE=false -
SAAS_WEBHOOK_REQUIRE_SIGNATURE=truewith strongSAAS_WEBHOOK_SECRET_MPESA/KCB -
WEBHOOK_BASE_URL=https://biasharaerp.com - Redis queue workers running (
supervisor) - Per-tenant POS payment settings: Daraja consumer key/secret, shortcode, passkey
- Register Safaricom callback URLs per tenant slug:
https://biasharaerp.com/webhooks/{slug}/mpesa/stk-callbackhttps://biasharaerp.com/webhooks/{slug}/mpesa/c2b/confirmation- Or copy from Settings → Integrations → POS payment settings (Daraja section)
- KCB Buni STK callback:
https://biasharaerp.com/webhooks/{slug}/kcb/stk-callback
Daraja staging (on staging.biasharaerp.com)
-
PAYMENTS_FORCE_SANDBOX=true, sandbox credentials in tenant settings -
WEBHOOK_BASE_URL=https://staging.biasharaerp.com - Test STK push from POS checkout; verify
webhook_logs+payment_intents→paid - Test duplicate callback (same idempotency key) returns 200 without double sale
KCB staging
- Buni sandbox credentials in POS settings
- STK initiate + callback updates intent
Monitoring
- Alert on
webhook_logs.processing_status = failed - Daily review
payment_intentsstuck inpending
Tenant isolation
- Webhook URL includes correct
{slug} -
ProcessWebhookJobruns withCurrentOrganizationset (seeTenantQueueContext)