The problem

Small online shops lose money on PayPal disputes and refund requests. They answer late, have no proof, or refund when they did not need to. A big company has a team for this. A small shop has one person and a deadline.

What PayDesk does

PayDesk is an AI helper for people who sell with PayPal. The AI does the investigating. The seller makes the final decision.

Everything in this demo runs on the PayPal Sandbox with test money.

  • Refunds. A buyer writes "I was charged twice". The AI finds the payment, checks PayPal, sees the duplicate, and suggests refunding that one payment. The seller clicks Approve and PayPal sends the refund.
  • Disputes. When a buyer opens a dispute on PayPal, PayDesk picks it up and opens a case. It collects proof (delivery and download records) and suggests what to do: accept, offer part of the money back, or contest. The seller clicks Approve and the answer goes to PayPal.
  • Ask PayPal. A chat where the seller asks about disputes and sales, like "Which disputes need my attention first?".

How we built it

  • PayPal: Smart Buttons for checkout, the PayPal Server SDK for orders and refunds, the Disputes API, webhooks, and PayPal's Agent Toolkit for the chat.
  • AI: LangGraph agents on Groq. Each agent gathers facts from PayPal, decides, passes a rules check, and drafts a reply.
  • App: React, Node.js, Express, MongoDB and TypeScript, with 85 automated tests.
  • We built the PayPal payment and refund code with APIMatic's Context Plugin for PayPal and the PayPal Server SDK that APIMatic makes. It was a big help: its guides gave us the right setup, error handling and tests from the start, and caught a bug in our retry settings.

Built to be safe

  • Rules written in code check every AI suggestion: the refund window, never more than what is left, and proof before contesting a dispute.
  • Proof files are made from store records, not written by the AI.
  • A double click can never refund twice.
  • Nothing moves until a person approves.

What we learned

How PayPal disputes work, how to verify webhooks, how much a good SDK and good guides like APIMatic's help a developer, and how to keep a person in charge when AI works near money.

Built With

Share this project:

Updates

Submission history