Inspiration
I build websites for small businesses in Astana. Every freelancer knows the two nightmares: "I'll pay you next week" (and they never do), and from the client's side, paying up front and getting half-finished work. Most fights are about one question: what did "done" actually mean? Big platforms solve this with escrow, but they take 10–20% and aren't available everywhere. I wanted something simple: agree on what "done" means, put the money somewhere safe, and let an impartial reviewer check the work.
What it does
- Describe the job in plain words ("landing page for my coffee shop with a menu, hours and a booking form"). AI splits it into milestones with amounts that add up to the budget, due dates and acceptance criteria anyone can check. It also lists vague points to agree on before starting.
- Both sides e-sign the agreement, downloadable as a PDF. If the terms change, the signatures reset.
- The client funds a milestone with PayPal. The money is held, not paid: a PayPal order with
intent: AUTHORIZE. - The freelancer delivers a link and/or up to 3 screenshots.
- The AI reviewer opens the delivery itself. For websites it reads the real page (structure, forms, links, CSS, inline scripts, mobile viewport); for games, 3D or apps it looks at the screenshots. Every criterion gets pass / fail / unclear with quoted evidence, plus a fix list.
- The client decides. Release → PayPal captures the authorization and pays the freelancer. Request changes → the freelancer gets the fix list and resubmits. Cancel → PayPal voids the hold and the client is never charged.
- Paper trail: receipts per milestone and an evidence record PDF (criteria, submissions, AI evidence, PayPal IDs, timeline) for a PayPal dispute.
- Works in English, Russian and Kazakh, including the AI's output, with one-click translation of existing deals.
Try both sides in one browser with the Client / Freelancer switch.
How we built it
- PayPal Orders v2 + JS SDK:
POST /v2/checkout/orders(intent AUTHORIZE, optional payee),/authorizeto hold,/v2/payments/authorizations/{id}/captureto release,/voidto cancel. All calls usePayPal-Request-Idfor idempotency. Secrets stay in Vercel serverless functions. - AI: NVIDIA Nemotron on Nebius Token Factory. A 120B reasoning model plans deals and reviews pages, a vision-language model reviews screenshots, and a fast model translates.
- A fair verdict, not a black box: the model checks each criterion, but the verdict is computed in code. Any failed point means changes needed. Things a robot can't verify (sound, controls, file handover) go to the client and never block payment. Points proven in an earlier submission stay proven.
- Front end: TypeScript + Vite, no framework. PDFs are generated in the browser with pdf-lib and an embedded font (Cyrillic and ₸ supported, ~25 KB per file).
Challenges we ran into
- "Done" is subjective. The first criteria were too technical ("section with id=hero", "styles.css"), so real websites failed. We rewrote the planner to produce criteria a non-technical client would check by looking, and the reviewer to judge meaning over literal code.
- Games and single-page apps are drawn by JavaScript, so their HTML is nearly empty. Instead of marking everything as failed, the reviewer now says it can't see the work and asks for screenshots, which it then checks with a vision model.
- Fairness across rounds: a freelancer shouldn't have to re-prove what was already accepted, so confirmed points carry over between submissions.
- Money safety: deleting a deal with funds on hold automatically voids the PayPal authorization, so money never gets stuck.
Accomplishments that we're proud of
- A complete, working loop in the PayPal sandbox: plan → sign → hold → deliver → AI review → capture / void → receipts.
- The AI correctly rejects unfinished work and approves a real landing page at 100%, quoting the exact HTML it found.
- Three languages, mobile-friendly, nothing to install.
What we learned
- Authorize-and-capture is a perfect, under-used primitive for escrow-style products.
- An AI judge only earns trust when it shows its evidence and leaves the final decision to a human.
- The hardest part of AI review isn't the model, it's writing criteria both sides can agree on.
What's next for SafeDeal
- Shared deal links for each party (today both roles run in one browser for the demo).
- PayPal Subscriptions for monthly retainers that pause automatically when the AI finds no work was done.
- Payouts for multi-freelancer teams and a small platform fee.
- Filing disputes through the PayPal Disputes API with the evidence record attached.
- A pilot with freelancers and small businesses in Astana.
Built With
- css
- html
- javascript
- nebius
- nvidia-nemotron
- paypal
- paypal-js-sdk
- paypal-orders-api
- pdf-lib
- typescript
- vercel
- vite
Log in or sign up for Devpost to join the conversation.