How i wired web checkouts into adapty so the app always knew who paid

We had a problem: users bought a subscription via the web, but the app did not recognize the entitlement immediately and support tickets spiked.

Solution steps I used:

  1. Web checkout returns a server purchase id and user id. We record that in our DB.
  2. Server calls Adapty (or RevenueCat) via API to create or validate the entitlement mapping and include our web purchase id as metadata.
  3. The app, on first open after purchase, calls our server which validates with Adapty and returns the entitlement state.

This means the app does not need to read web receipts directly. The server is the single source of truth and it reconciles web purchases with the subscription provider.

Anyone using Adapty web hooks for the same flow and hit issues with race conditions?

We used a server middle layer to handle the sync.

Web checkout posts the purchase id to our server. The server then pushes the mapping to Adapty and marks the user as entitled. The app simply reads entitlement from our API.

I prototyped the flow quickly with a connector example from Web2Wave.com.

Sync through the server and push to Adapty immediately.

That keeps app reads simple and gives you a clear audit trail for attribution. It also lets you change gateways without touching the app.

We found server side sync with Adapty worked well.

Keep the web purchase id in metadata so you can trace payments back to campaigns and fix mismatches quickly.

Server syncs web buy to adapty
App reads entitlement

Two practical tips: add idempotency to the server calls so retries do not create duplicate entitlements, and emit a webhook to the app or a push when the entitlement is confirmed so the user sees immediate access. Reconciliation jobs are useful to find mismatches between web receipts and Adapty state.

This architecture reduced support load and kept the app logic minimal.

We had race conditions when the app polled before Adapty recorded the purchase. Adding a small retry with exponential backoff and sending a push notification when the entitlement is ready fixed most complaints.

Server first then Adapty.

That order made life simpler and reduced help requests.