Inspiration

Inspiration Payment disputes are one of the most painful and expensive parts of online commerce. A customer claims an item never arrived or arrived damaged, and what follows is a slow, manual process full of emails, policy lookups, incomplete evidence, and delayed refunds. Merchants lose time and money; buyers lose trust. At the same time, PayPal has built powerful payment rails, and AI agents are becoming capable of real actions — not just recommendations. We saw an opportunity to combine the two: use multi-agent AI to investigate, reason, and resolve disputes, then execute the actual financial outcome through PayPal. That intersection of agentic commerce and real money movement is what inspired ResolveAI. What it does ResolveAI is an AI-powered autonomous payment dispute resolution platform built on PayPal. A buyer submits a complaint with a PayPal transaction reference. Four specialized agents then collaborate: The Buyer Agent understands the complaint and extracts key details. The Merchant Agent retrieves order, shipment, and policy evidence. The Resolution Agent compares evidence, retrieves relevant policies via RAG, and generates an explainable recommendation with confidence scores. The Payment Agent executes a real full or partial refund through the PayPal Sandbox — only after merchant authorization. The result is a complete loop: complaint → evidence-based investigation → AI recommendation → human approval → actual PayPal refund, all with full audit trails. ResolveAI doesn’t just suggest what should happen; it settles the payment. How we built it. We designed ResolveAI as a production-oriented system rather than a prototype. Frontend: Next.js + TypeScript + Tailwind CSS with a polished buyer complaint interface and a merchant dashboard powered by AG Grid Community. Backend: FastAPI (Python) handling authentication, case management, and all PayPal interactions. Agent orchestration: LangGraph for the multi-agent workflow (Buyer, Merchant, Resolution, and Payment agents) with state management, conditional routing, and human-in-the-loop approval. Knowledge: PostgreSQL + pgvector for RAG over merchant refund, return, and shipping policies. Payments: Official PayPal Sandbox integration (OAuth, Orders, Captures, Refunds, Webhooks) with modular design so real Disputes API support can be added when available. AI: Configurable LLM layer (Gemini or OpenAI) so the system stays provider-independent. Infrastructure: Designed for Vercel (frontend) + Render (backend + PostgreSQL). We prioritized real PayPal money movement and clear separation between simulated complaint flows and actual Sandbox transactions.Challenges we ran intoThe biggest challenge was working within the realities of PayPal Sandbox capabilities — particularly around buyer-side dispute creation and the DISPUTE_CREATE permission, which is not always enabled by default. We had to carefully distinguish real PayPal operations (payments and refunds) from simulated complaint workflows so we never claimed something was a live PayPal dispute when it wasn’t.Other challenges included: Designing a multi-agent system that stays grounded in evidence and never invents facts. Keeping financial operations strictly server-side and human-authorized. Building a clean capability matrix so every feature maps to an actual PayPal API, toolkit, or documented capability. Balancing a rich agent architecture against the tight hackathon deadline while still delivering a working end-to-end demo. Accomplishments that we're proud of A complete multi-agent resolution loop that investigates, reasons, recommends, and executes. Real PayPal Sandbox payment + refund integration (not just mocked responses). Evidence-based decisions powered by RAG over merchant policies, with source references. Strong security and governance: human approval gates, audit trails, idempotency, and no client-side credentials. A clear, modern interface for both buyers and merchants that makes the agent work visible and trustworthy. Architecture that treats PayPal as core infrastructure rather than an optional payment gateway. What we learnedWe learned that agentic systems become truly powerful when they can take real actions — but only when those actions are carefully constrained, auditable, and human-authorized. Working deeply with PayPal’s APIs, Agent Toolkit concepts, and webhook patterns taught us how payment platforms expect integrations to be built.We also learned the importance of capability verification early: never assume an API or permission is available until it is tested. Finally, we saw how much clearer multi-agent systems become when each agent has a narrow, well-defined responsibility and the overall workflow is explicit.What's next for ResolveAI Full integration with the official PayPal Disputes API once sandbox permissions are confirmed or expanded. Support for more complex resolution types (partial refunds, replacements, store credit, chargebacks). Merchant policy onboarding and continuous learning from resolved cases. Expansion into agent-to-agent commerce scenarios (for example, two agents negotiating and settling a payment). Production-ready deployment with stronger monitoring, rate limiting, and multi-merchant support. Exploration of PayPal’s AI Toolkit and MCP server for even tighter native agent tooling.

Built With

Share this project:

Updates

Submission history