Backend for Mystica readings and Pro access compatibility.
ANTHROPIC_API_KEY: Anthropic API key.PRO_SECRET: Enables both the old production header path and Overhaul native-billing entitlements.The old production app sends PRO_SECRET in x-mystica-pro. The Overhaul never
receives or sends the secret; it sends the purchase token restored by its native
Google Play Billing plugin, and the configured server accepts that entitlement.
Daily free allowances are enforced locally by the app: 2 reads/day plus one additional read for every five streak days, capped at 8/day. The backend also applies a fallback safeguard of 10 successful free readings per SGT day per IP, plus a 10 requests/minute/IP abuse limit for all users.
The fallback counter is held in the free Render process memory. A service restart, spin-down, deployment, or IP-address change resets or bypasses that counter, so it is a deterrent rather than persistent account-level enforcement.
npm install
npm start
GET /: health check.POST /reading: accepts existing entitlement formats, applies the free-user fallback and short-term abuse limits, then proxies the reading request to Anthropic.