Build Auth + Payments + Usage-Credit Layer for FastAPI/React SaaS (Stripe, Clerk, Postgres)
Only freelancers located in the U.S. may apply.U.S. located freelancers only
What this is: I'm the founder of a working AI SaaS platform (FastAPI/uvicorn backend, React/Vite frontend, deployed on AWS). The product pipeline is built and live! I need an experienced engineer to build the authentication, payments, and usage-entitlement layer that gates the product behind login and paid usage. You'll work against a runnable stub repository (real routes + data shapes, proprietary internals removed) - so you can build and test the full layer without ever touching the core IP, and afterwards - I will merge your work into the production app! Scope: • Auth (Clerk): signup/login, session lifecycle, backend session/JWT verification, inject a validated `user_id` into protected endpoints. • Payments (Stripe): Checkout for purchasing usage credits, plus a webhook that credits the user's ledger on successful payment. The webhook MUST be signature-verified, idempotent (Stripe retries-credit exactly once), and reconcilable (handle webhook-failed-but-payment-succeeded). • Entitlement ledger (the core): a credit balance per user with atomic check-and-decrement (two concurrent requests must never double-spend) on PostgreSQL. A `check_entitlement(user_id, ...)`gate that expensive endpoints call before doing paid work. • Server-side route gating: enforce entitlement on every paid endpoint (not just hidden in the UI); clean 401/402/403 responses. • Frontend integration (React): login/signup UI, buy-credits/checkout flow, balance display,graceful "out of credits" states, wired to the above. • Tests for the money-critical paths (webhook idempotency, atomic decrement, gating-bypass attempts). Stack you'll work with: Python 3.11, FastAPI, Pydantic, uvicorn (Linux). React + Vite, Tailwind. PostgreSQL. Clerk. Stripe. Who I'm looking for: Someone who has shipped this exact kind of system to production before. In your proposal, briefly tell me: 1. How you ensure Stripe webhook idempotency and handle reconciliation when a webhook fails but payment succeeded. 2. How you'd implement the atomic credit check-and-decrement so concurrent requests couldn't double-spend. 3. A relevant production system you've built (Stripe + auth + usage metering ideally). *I'd much rather a short, specific proposal - than a long generic one!* Working with me: I'm an engaged founder who genuinely enjoys building, and I want this to be a good experience for both of us! I'm responsive, communicate clearly, and I respect your expertise - because you're the specialist here,and I'm hiring you because you know this much better than I do! I'm not a micromanager and I'm not nitpicky - I just want the end results to be solid! I review in milestones, asking questions because I like understanding the work (not because I'm second-guessing you), and I make decisions quickly so you're never stuck waiting on me! The scope is already well-defined (detailed spec + a runnable stub repo on engagement), so you're not pricing around a vague, shifting target - it's a clean, bounded build. I care about getting the money-handling pieces right, and I'm betting you do too - if that resonates, I think we'll work well together! IP / engagement: A mutual NDA + IP-assignment (work-for-hire) before repo access. You build against stubs; you won't receive the proprietary pipeline. Work is milestone-based, fixed-bid preferred. To apply: Answer the three questions above + share 1-2 relevant examples, and ballpark your timeline and milestone structure (suggested: auth → payments+webhook → ledger+gating → frontend → tests/docs)!
$4,000.00
Fixed-price- ExpertExperience Level
- Remote Job
- Ongoing projectProject Type
Skills and Expertise
Activity on this job
- Proposals:50+
- Last viewed by client:last week
- Hires:1
- Interviewing:2
- Invites sent:0
- Unanswered invites:0
About the client
- USAIrving1:38 PM
- $4K total spent1 hire, 0 active
- Tech & ITSmall company (2-9 people)
Explore similar jobs on Upwork
How it works
Create your free profileHighlight your skills and experience, show your portfolio, and set your ideal pay rate.
Work the way you wantApply for jobs, create easy-to-by projects, or access exclusive opportunities that come to you.
Get paid securelyFrom contract to payment, we help you work safely and get paid securely.
About Upwork
- 4.9/5(Average rating of clients by professionals)
- G2 2021#1 freelance platform
- 49,000+Signed contract every week
- $2.3BFreelancers earned on Upwork in 2020
Find the best freelance jobs
Growing your career is as easy as creating a free profile and finding work like this that fits your skills.
Trusted by