Setup guide

Everything PaidCheck needs, and exactly why. (The in-app forms generate a real secret and fill it in for you.)

1. Stripe restricted key

  1. Open Stripe Dashboard → Developers → API keys (use the same mode — Live or Test — your app charges in).
  2. Click “Create restricted key”. Choose “Providing this key to another website”, name it PaidCheck.
  3. Set these to Read: Customers, Subscriptions (under Billing), Charges, Events, Webhook Endpoints. Optional but recommended, also Read: Checkout Sessions, Invoices, Entitlements (one-time purchases, fewer double-charge false positives). Leave EVERYTHING else at None.
  4. Create the key, copy it (starts with rk_live_ or rk_test_) and paste it here. You can roll/delete it in Stripe at any time.
CustomersReadmatch a subscription to the customer's email, ID and metadata
Subscriptions (Billing)Readknow who is active, trialing, past_due, unpaid or canceled, and seat quantities
ChargesReaddetect duplicate charges, refunds and one-time payments
EventsReadfind events whose webhook delivery failed (pending_webhooks > 0)
Webhook EndpointsReaddetect disabled endpoints and endpoints missing key events
Checkout SessionsRead (optional)optional: one-time purchases (mode=payment) and telling separate checkouts apart
InvoicesRead (optional)optional: link charges to subscription periods (fewer double-charge false positives) and invoice emails
EntitlementsRead (optional)optional: count Stripe active entitlements as paid access
Everything elseNonePaidCheck never writes to Stripe.

The optional scopes are still read-only. Without them PaidCheck skips the checks that need them and tells you so in the report.

2a. Supabase (Lovable, Bolt) — paste into your AI builder

Then give PaidCheck your project URL + anon/publishable key + the secret. The anon key alone can't read anything: the function checks the secret and only returns email/plan/active.

2b. HTTPS endpoint (Next.js, Cursor, any stack)

…or as a Supabase Edge Function

2c. No code: upload a CSV

Export your users (Supabase table editor → Export to CSV, or any admin panel) with these columns. On the free report the CSV is processed in memory for that one request and never stored. For monitored apps it's stored encrypted; re-upload it when your users change.

email,plan,active,stripe_customer_id
ana@example.com,pro,true,cus_123
bo@example.com,,false,

2d. Or skip it: Stripe-only checks

With no access source, PaidCheck still checks failed and undelivered webhooks, disabled endpoints and endpoints missing key events, double charges and duplicate subscriptions. “Paid but no access” and “cancelled but still active” need one of the sources above.

Expected format

[{"email":"ana@example.com","plan":"pro","active":true,"stripe_customer_id":"cus_123"},
 {"email":"bo@example.com","plan":null,"active":false}]

email, plan, active are required (the original 3-field format keeps working). Optional: stripe_customer_id (best match), user_id (matched against Stripe customer metadata like user_id / supabase_user_id), and for per-seat team plans team_id + seats_used.

How users are matched

  1. Stripe customer ID (stripe_customer_id)
  2. Customer metadata user ID (user_id, userId, app_user_id, supabase_user_id, …) ↔ your user_id
  3. Email: trimmed and case-insensitive; optionally ignoring +tags and Gmail dots (labeled)
  4. Any email seen on the customer's charges or invoices

Every report shows which rule matched each user.