-
-
Job settled: all 4 checklist items passed, so PayPal released the full $40.00 to the freelancer and returned $0.00 to the client.
-
Gemini checks the work against the agreed checklist and gives a pass or fail with a reason for every item.
-
PayPal proof: the $40 authorization hold was captured with final capture true. Order, authorization and capture IDs are shown.
-
TrustLance home: describe the job in plain English and Gemini turns it into a checklist. PayPal and Gemini status shown live.
-
The freelancer's submitted work, which Gemini reviewed against the checklist before PayPal released the money.
Inspiration
Freelancing runs on trust, and that trust breaks in both directions: clients fear paying for work they never get, and freelancers fear delivering and never being paid. The goal was to see whether AI plus PayPal could take the guesswork out of the middle and make both sides safe by default.
The problem
Freelancers and clients often don't trust each other. Clients worry about paying for work that isn't delivered, and freelancers worry about delivering work and never getting paid. Traditional escrow often adds fees and relies on manual dispute handling, which is heavy for small freelance jobs.
What TrustLance does
TrustLance is an AI-powered escrow for freelancers. It builds trust by agreeing on the rules before any work starts, holding the money safely, and then settling automatically from verifiable proof.
- The client describes the job in plain English and sets a price.
- Gemini turns the description into a checklist of 3 to 6 specific, verifiable items. The client can edit it, and the freelancer accepts it, so both sides agree on the rules up front.
- The client funds the job through PayPal. The full amount is placed on hold with a PayPal authorization, and nothing is paid out yet. The freelancer sees "Payment secured" and can start work with confidence.
- The freelancer submits the work as pasted text or a public URL.
- Gemini reviews the submission against each checklist item and gives a pass or fail with a one-sentence reason.
- The server (not the AI) calculates the payout: price x (items passed / total items). PayPal captures exactly that amount for the freelancer and releases the remainder back to the client.
Example: a $40 job with 4 checklist items. The work meets 2 of 4, so $20 is paid to the freelancer and $20 returns to the client. Both sides see exactly why.
How we use PayPal
- Orders v2 with intent AUTHORIZE to reserve the client's funds without charging them.
- Authorize and partial capture (final_capture) to release only the earned amount, so the unearned remainder goes back to the client.
- Void when nothing was earned.
- All of it runs in the PayPal sandbox.
How we use AI
Gemini does two jobs: it converts a plain-English brief into a verifiable checklist, and it reviews submitted work against that checklist with reasons. The AI never moves money. It only produces a structured result, which the server validates, and the server calculates the payout and calls PayPal. This keeps the money logic predictable and safe.
How we built it
Node.js and Express backend, a responsive web front end, PayPal sandbox REST APIs, and the Gemini API with JSON output and validation. The Gemini calls retry and fall back to backup models when Google returns busy errors. Each job can only be funded and captured once, and a failed AI review never charges or captures anything. It is deployed on Render and was built during the hackathon with an AI coding assistant (Google Antigravity).
Challenges we ran into
- Getting partial capture and release working correctly with PayPal authorizations.
- Making AI output reliable enough to drive a payment, which is why the AI only scores and the server handles the money.
- Handling Gemini's temporary overload errors without breaking the demo.
Accomplishments that we're proud of
- A complete, working escrow flow end to end on a live link: AI checklist, PayPal hold, AI review, and an exact payout, all tested with real sandbox payments.
- Proving PayPal's authorize and partial capture works the way an escrow needs, with the unearned remainder going back to the client.
- Keeping the AI away from the money: it only scores the work, and the server validates the result and calculates the payout.
- Building and deploying all of it within the hackathon window.
What we learned
- How PayPal authorizations differ from instant payments, and how partial capture with final_capture releases the unearned remainder.
- To keep AI away from money logic: the AI only scores, and the server calculates and pays.
- How to build with an AI coding assistant and still test every step by hand, especially the payment flow.
Limitations (being honest)
- Sandbox only, with no real money.
- A PayPal authorization expires after a limited time (about 29 days), so this is a demonstration of escrow, not a full legal escrow service.
- The AI can only judge what it can read, like text, code, and web page content. It cannot fully test things like whether a form submits correctly.
- Jobs are stored in a file on a free server, so they can reset after a redeploy.
- A human review or dispute step would be needed in a production version.
What's next for TrustLance
Milestone payments, a human dispute flow, support for more types of deliverables, and PayPal webhooks for a full audit trail.
Try it
Live demo: https://trustlance-n5ti.onrender.com (the free server may take up to a minute to wake up). Test with the sandbox buyer account listed in the testing instructions and the README.
Built With
- css
- express.js
- gemini
- html
- javascript
- node.js
- paypal
- paypal-sandbox
- render