AgentPay — AI-Powered PayPal Command Center.

Inspiration

It's not something that needs to be your job. While reading about the time freelancers and small businesses spend on their PayPal business, I realized how time-consuming it is to perform daily activities such as invoice generation, transaction verification, tracking expenses, processing subscriptions and solving disputes.

I wanted to create something that will make these operations easier. What if there was someone who could take care of your PayPal account, without you having to deal with several dashboards or do everything manually?

I had that thought, and I started to develop AgentPay — an AI-powered PayPal Command Center that allows you to convert natural language to financial actions.

What I Built

AgentPay is a financial assistant that merges AI with PayPal functions. Users can type questions and request actions in simple, natural language, rather than through several screens.

It has multiple important features such as:

Invoice Management: Generate and handle invoices from natural language. Transaction Tracking: See and view the latest PayPal transactions. (Product Catalog): Ask questions about the products available in the PayPal catalog.

  • Payment Operations: Communicate with PayPal payment and order processes.
  • Dispute Management: Access and manage dispute related information. Handle subscription operations. View transactions and invoices in interactive data grids, charts and AI-powered insights. Human-in-the-Loop Approvals: Approve sensitive financial actions before they are executed.

An important design consideration was to ensure that the user was not taken by surprise. AgentPay is not just blindly performing sensitive actions. It displays approve requests to the user for approval or rejection.

How I Built It

I created AgentPay from scratch, from the front end to the integration of the back end, to the AI agent workflow, and all of the application architecture.

My tech skillset comprises:

  • Backend: Prisma, TypeScript, and Python
  • Pro Library: twine:pro, ketchup:pro The PayPal Official Agent Toolkit (@paypal/agent-toolkit) is a toolkit that allows developers to integrate PayPal features and functions into their applications.
  • Data Visualization: AG Grid Community and Recharts:
  • Animations: Framer Motion
  • State Management: Zustand
  • Authenticating the Payment Gateway: PayPal REST API

The core of the application is the AI agent powered by Gemini and the official PayPal Agent Toolkit. Implemented a total of 47 tools on 8 different PayPal API domains, enabling the assistant to engage with various PayPal functionalities.

In addition, I added visualization of the tool calls in real time. Users will be able to see what operation an AI is executing, its parameters, and if it is running, complete, or failed.

For the dashboard, I utilized AG Grid to create interactive transaction and invoice data, sort, filter, paginate and export to CSV. The financial visualizations are powered by Recharts and the insights feature offers AI-generated summaries.

PayPal Sandbox is used for testing and demonstrating PayPal's workflows.

Challenges I Faced

The one thing that posed a significant hurdle was bringing a conversational case to the actual financial operations.

Creating the response is easy with an AI assistant, but performing the right PayPal operation involves choosing the appropriate tool, providing the right parameters and processing the result correctly.

I had to be careful with designing the agent workflow as it had to be able to convert the natural-language requests into the correct operations provided by PayPal's toolkit.

One of the difficulties was to implement human-in-the-loop approvals. I wanted users to see and be in control of sensitive actions and not let the AI do everything automatically.

I also took some time to make it understandable. Displaying status of the tools executed, creating user-friendly financial tables and tying the chat experience to the dashboard added a financial touch to the application, rather than just another chatbot.

What I Learned

Creating AgentPay enlightened me about the potential of AI agents to interact with APIs and carry out practical actions other than text generation.

I've had hands-on experience using the PayPal Agent Toolkit, tool calling, approval workflow, streaming AI responses, and integrating multiple financial capabilities of the API into a single application.

The most important thing I learned is that making the AI intelligent isn't the same as making a useful AI product. It is also about openness, reliability and control of its actions.

What's Next

AgentPay is a first step to a full-fledged AI-powered financial operating system.

Some of the enhancements I'd like to consider further will be better recurring payment workflows, automated payment reminders, more in-depth financial analytics and more advanced financial insights.

I want to make it as easy as talking to a person to manage the finances of everyday life, and keep the user in control.

Built With

Share this project:

Updates

Submission history