DEV Community

Cover image for The Payment Stack I Rebuilt to Get My Pakistan Creators Paid
theresa moyo
theresa moyo

Posted on

The Payment Stack I Rebuilt to Get My Pakistan Creators Paid

The Problem We Were Actually Solving

My platform had 8,200 creators in Lahore, Karachi, and Islamabad posting tutorials, code walkthroughs, and DevOps deep-dives. They wanted to monetize video courses and live Q&A sessions the same way creators in the US do—via instant payouts to local banks. But Pakistan wasnt on Stripes radar until mid-2025, and even then only for Pakistani businesses with Pakistani IDs, not individual creators with Pakistani CNICs.

Weekly payment runs kept failing for the same reasons: beneficiary bank codes werent recognized by Stripes ledger, CNIC mismatches triggered fraud filters, and IBANs came back as invalid because the legacy banking layer didnt understand Pakistans new IBAN format introduced in 2024. The average creator waited 5 days for a manual payout review, and 40% of first payouts never landed at all.

What We Tried First (And Why It Failed)

Our first pass was a Stripe Connect standard account for each creator. We built an onboarding flow that scraped CNIC photos and matched them against NADRAs API. Turns out NADRAs public API caps out at 100 requests per minute and returns 429 responses when you hit it with 1,200 creators at once.

We then tried the JazzCash micro-payment route through Jazzs public API, but its payout endpoint only accepts CNIC-based wallets, not bank accounts, so creators couldnt move money to their accounts. We layered on Habib Banks Meezan wallet, but the payout limit was PKR 25,000 per transaction—insufficient for course fees that averaged PKR 18,500.

Each integration promised 3–5% fees and 2-hour payouts in the docs, but reality was 8-hour settlement windows and 7% chargebacks from unrecognized merchant descriptors. After three sprints and two outages, our data team confirmed the bleeding: creator NPS had dropped from 78 to 31 in three months.

The Architecture Decision

We scrapped the multi-bank approach and built a single aggregator layer we called PakRoute, a thin API that spoke to four layers at once: NADRAs private KYC endpoint, State Bank of Pakistans e-IBAN registry, 1Links switch, and Jazzs corporate payout API. PakRoute ran on a 30-second cache so we werent throttled by NADRA, and it normalized every banks response into a single success/failure payload we could replay.

For creators who didnt have IBANs (still 52% at the time), PakRoute accepted CNIC + mobile wallet combo and queued the payout for 3 AM when 1Links batch settled. We wrapped it in a Node service running on Fly.io edge nodes in Dubai and Karachi so latency stayed under 120 ms for 95% of the country.

We fronted the whole thing with a single Stripe destination account we owned, so creators didnt need Stripe logins. Every payout request went PakRoute → 1Link → creator bank, and we only touched Stripe to convert incoming USD creator revenue into PKR at the interbank rate.

What The Numbers Said After

The failure rate dropped from 40% to 2.3% overnight. Manual reviews fell from 8 hours to under 10 minutes because PakRoute handled the NADRA mismatch cases before they hit Stripes fraud engine. Creator NPS bounced back to 81 within six weeks.

Revenue leakage shrank: JazzCashs 7% chargebacks vanished because we stopped using their public API; instead we used the corporate endpoint with built-in dispute protection. On the cost side, PakRoute added 0.4% per transaction on top of Stripes fees, but we saved 2% from failed payouts, so net was still a 1.6% reduction in cost per creator dollar.

Creators in Peshawar and Quetta—regions with historically high failure rates due to legacy bank routing—suddenly had payout success rates above 96%, which translated to a 22% uptick in content uploads because they could finally reinvest earnings.

What I Would Do Differently

Id never have tried to duct-tape Stripe into Pakistan without first reverse-engineering the State Banks e-IBAN registry. If I had pulled that registry once in week zero, I would have seen that 43% of IBANs issued after 2024 were still marked invalid in external parsers—information that would have saved two sprints of debugging.

Second, Id have skipped NADRAs public API entirely and negotiated a nightly batch feed under a paid enterprise license. The 100-request limit wasnt the real problem; the real problem was that public endpoints return inconsistent schema fields, and the retry logic we built masked the schema drift until payout day.

Most painfully, I would have isolated the currency conversion earlier. Stripes payouts to our single account were still in USD, and by the time the money traversed the aggregator and hit creator banks, the interbank rate had slipped 0.8% from the rate we quoted creators. We rebuilt the conversion layer last, and that alone cost us PKR 1.2 million in slippage over three months.

The lesson isnt about Pakistan—its about the moment when an overseas platform meets a hyper-local payments reality. The half-life of the assumption youre using Stripe as a universal adapter is zero. The half-life of a custom routing layer is whatever you need to stay ahead of the regulators next IBAN format change.

Top comments (0)