Payments & infra

Cloudflare + Cashfree for India: DigiLocker KYC, penny drop, eNACH mandates, subscription webhooks on a database, FCM, and an ops dashboard.

Role
Solo builder
Type
Multi-worker India billing and KYC infrastructure
Stack
Cloudflare Workers · Database · KV · Cashfree · DigiLocker · eNACH / NPCI · FCM

Unique

Shared India billing spine: DigiLocker KYC → penny drop → eNACH, plus webhooks, FCM, and an ops dashboard.

Problem

Indian app subscriptions are not always “tap Buy, store handles it.” Some products need Aadhaar-backed KYC, a bank mandate, reliable renewals, a push when billing fails, and an ops view when support asks why a device is not Pro.

What it is

One shared payments spine for the apps:

  1. Billing worker — plans, subscribe, webhooks, status, revoke; shared database for subscription lifecycle
  2. Mandate worker — DigiLocker Aadhaar → penny drop → create subscription → eNACH on Cashfree / NPCI → success
  3. Notification worker — FCM for billing-related events
  4. Ops dashboard — stats and health over the same subscription database

Apps hit this when they need India-native collection instead of (or alongside) store IAP.

Approach

Split workers, shared database. KYC UX stays on DigiLocker so the app only starts the flow. Secrets in Wrangler. Same layer can serve multiple products.

Outcome

Markets and other apps can unlock Pro with a real Indian mandate path, and you can inspect subscriptions when something breaks.