Inspiration
Online shopping has become incredibly convenient, but getting the best deal still requires too much effort.
Consumers spend time comparing prices, researching products, evaluating alternatives, and searching for discounts. Even after all that work, they rarely get the opportunity to negotiate.
That made me wonder:
What if shopping wasn't just about finding the best price, but having an AI agent actively negotiate it for you?
I wanted to explore a future where AI doesn't simply recommend products. It takes action on behalf of the user.
That's how Agent D was born: an intelligent shopping agent designed to analyze, negotiate, and help users secure better deals, with PayPal powering the checkout experience.
What it does
Agent D is an AI-powered shopping assistant that transforms the traditional buying journey into an intelligent, agent-driven experience.
Instead of manually comparing offers and negotiating prices, users can delegate those tasks to Agent D.
The experience follows four main steps:
Analyze: The user provides a product or shopping request. Agent D analyzes the offer and explains its value, potential savings, and negotiation opportunities.
Negotiate: Agent D interacts with AI-powered seller agents, exchanging offers and counteroffers within a simulated marketplace. Each seller follows specific business constraints, creating a more realistic negotiation environment.
Decide: The agent evaluates the negotiation results and helps identify the most attractive deal. Users can review the outcome and choose how to proceed.
Checkout: Agent D connects the shopping journey to PayPal Sandbox, demonstrating how an AI-driven negotiation can lead directly to a payment.
The project also explores autonomous purchasing, where an AI agent can move from finding a suitable deal to initiating checkout, with user authentication and authorization.
The goal is simple: less searching, less negotiating, and smarter shopping.
How we built it
I developed Agent D as a full-stack web application, combining modern web technologies, generative AI, and PayPal's developer ecosystem.
The architecture brings together several components:
AI-powered product analysis: Google Gemini helps generate contextual explanations and insights about shopping offers.
Agent-based negotiation: Seller agents operate under configurable business rules, while AI-generated responses make negotiations more dynamic and conversational.
Negotiation fallback: A server-driven response mode provides a more predictable experience when AI services are unavailable or API limits are reached.
PayPal integration: PayPal Sandbox enables an end-to-end demonstration of the checkout process using test transactions.
User experience: An interactive interface visualizes the agent's analysis, negotiation progress, offers, and checkout journey.
I focused on creating more than a technical proof of concept. I wanted the product to feel like an accessible, consumer-ready shopping assistant.
The experience combines AI reasoning, controlled agent behavior, clear user interactions, and payment integration into one connected workflow.
Challenges we ran into
One of the biggest challenges was making AI negotiation feel meaningful rather than simply generating random discounts.
A credible negotiation requires constraints. Sellers should have pricing boundaries, business incentives, and reasons to accept or reject offers.
I addressed this by designing a controlled seller-agent environment that combines predefined negotiation rules with dynamic responses.
Another major challenge was reliability.
AI APIs can introduce latency, unpredictable outputs, and rate limits. During a live demonstration, these limitations can interrupt the experience.
To mitigate this, I explored a hybrid approach that supports AI-driven negotiation alongside deterministic server responses.
Integrating PayPal was another important milestone. Connecting conversational AI decisions to a real payment workflow required thinking carefully about state management, user authorization, and the transition from negotiation to checkout.
Finally, building everything independently under hackathon time constraints meant constantly balancing technical ambition, product quality, and delivery.
Accomplishments that we're proud of
My biggest accomplishment is turning an ambitious concept into a working end-to-end prototype.
I'm particularly proud of:
Building it independently: Taking Agent D from initial concept to functional prototype as a solo developer.
Going beyond chatbots: Exploring an AI agent that can actively negotiate rather than simply provide recommendations.
Integrating PayPal Sandbox: Demonstrating the journey from shopping request to negotiation and test checkout.
Creating constrained seller agents: Introducing business rules to make simulated negotiations more credible.
Designing for real users: Focusing on a polished, understandable experience rather than exposing users to complex technical processes.
Handling uncertainty: Developing fallback mechanisms to make the application more resilient to AI service limitations.
Most importantly, Agent D demonstrates how AI agents and payments can work together within a single commerce experience.
What we learned
This project completely changed how I think about building AI-powered applications.
I learned that building an AI agent is not just about connecting a language model to an interface.
The real challenge is designing a system that can make useful decisions, interact with other agents, respect constraints, recover from failures, and ultimately produce a meaningful result.
I also gained valuable experience integrating PayPal into an AI-driven workflow and understanding how payment authorization fits into autonomous commerce.
Another important lesson was that reliability matters as much as intelligence. A predictable fallback can sometimes be more valuable than a sophisticated AI response that fails at the wrong moment.
Above all, I learned how much can be accomplished by combining clear product thinking, rapid iteration, and a strong focus on the end-user experience.
What's next for AgentD
Agent D is an early exploration of a much bigger opportunity: agentic commerce.
My vision is to evolve it from a controlled prototype into a shopping agent capable of operating within real commerce ecosystems.
Future directions include:
Real merchant integrations: Connecting to participating retailers and merchant APIs to negotiate genuine offers.
Multi-agent negotiation: Allowing Agent D to negotiate with several sellers simultaneously and compare results.
Personalized shopping intelligence: Learning from user preferences, budgets, and previous decisions.
More autonomous workflows: Enabling secure, user-authorized purchasing when predefined conditions are met.
Deeper PayPal integration: Exploring how PayPal's payment capabilities can support trustworthy agent-driven transactions.
Smarter deal evaluation: Considering shipping, delivery times, seller reputation, and overall value, not just price.
The ultimate vision is a future where shopping agents do the hard work for consumers while keeping them in control.
Agent D — It always gets you the best deal.
Built With
- agentic-commerce
- generative-ai
- groq
- multi-agent
- nextjs
- typescript