A3A Protocol

A3A Protocol: secure daily AI-to-AI communication & payments under Web3 for Fiducia Agents

A3A Protocol

Created At

ETHOnline 2025

Project Description

We're building the A3A Protocol, a system designed to act as the trust and settlement layer for an ecosystem of Fiducia Agents.

The goal is to create a secure and decentralized network where autonomous AI agents can communicate, negotiate services, and exchange value. Fiducia agents are divided into several roles, basically one for consumers and the rest for merchants. Think of it as a foundational protocol for the emerging agent-to-agent (A2A) economy but under Web3, allowing your personal AI assistant to securely order a pizza or book a table directly with a restaurant's AI agent and pay with your decentralized wallet. The name A3A stands for Agent-Web3-Agent.

The protocol uses smart contracts to ensure that payments are only released when services are verifiably completed, removing the need for traditional intermediaries and centralized platforms. It also empowers everyone to provide service or goods.

User Flow

User Intent: A user types a command like "Order a large pepperoni pizza" into the chatbot UI.

API to Agent: The frontend sends this message to our FastAPI backend. The backend then forwards this natural language request to our @asi AI Consumer Agent.

Agent Interaction: The Consumer Agent communicates with available Merchant Agents to find a match, negotiate the order details, and confirm the final price. All interagent communications abide the A3A protocol designed by us on ASI Agentverse.

Transaction Generation: Once the order is finalized, the backend agent constructs the raw transaction data required to execute the createOrder function on our OrderContract. This includes the function signature, parameters (like order ID and price), and the target contract address.

Frontend Confirmation: The backend returns this raw transaction object to the frontend. The frontend then uses wagmi to present allowance approval and transaction to the user in MetaMask for final confirmation and payment. This ensures the user always has the final say and signs the transaction with their private key.

How it's Made

Our project, A3A Protocol, is an exploration into the future of commerce, blending autonomous @ASI AI agents with the trust and immutability of the blockchain. We built a decentralized platform where users can interact with AI-powered consumer and merchant agents to execute real-world transactions, like ordering food, in a completely transparent and secure manner. Stable payment is made available by integrating @pyusd, and we support real time status track with @blockscout.

Core Tech Stack

Frontend: We chose Vite as our framework for its speed and developer experience. Blockchain interaction is powered by wagmi and viem, which provide hooks for wallet state management (useAccount), balance queries (useBalance), and transaction signing (useSignMessage, useSendTransaction). For a seamless wallet connection experience, we integrated ConnectKit, which offers a polished and user-friendly modal. Our dashboard, including order and transaction status tracking, is powered by @blockscout. All application state, particularly user authentication tokens (JWTs), is managed globally with Zustand.

Backend: Our backend is a lightweight yet powerful Python server using the FastAPI framework. Its role is not to hold funds or user data but to act as a secure orchestrator. It manages a Sign-In with Ethereum (SIWE)-like authentication flow, issuing JWTs upon successful message signing. Most importantly, it serves as the bridge between user requests, smart contracts and our AI agents, receiving commands from the frontend, dispatching tasks to agent and then handling the tool calling.

Smart Contracts: The on-chain logic is built with Solidity. We developed an OrderContract that serves as the central escrow and logic handler for all transactions, alongside standard ERC20 token contracts for A3A token. We also integrated ERC721 for the A3A Merchant NFT, which provides each merchant their merchant ID that is utilized for merchants to handle their merchant agent stores. Our entire testing workflow was powered by Foundry and Sepolia. We used Anvil for a fast, local testnet node, Forge for compiling and scripting deployments, and cast for direct chain interaction and debugging. Order contract: 0xa39aE8c1B35314FfafA9fF294637754F281F0875 A3AToken: 0x307Fea2981Ed87F37E96b96Fad40e8052942d99F MerchantNft: 0x1e08cFBd659436F8Fc72C91A9302B6C6F444c0A2

Technologies Integration

ASI (Artificial Superintelligence Alliance): This is the brain of our operation. Both our Consumer and Merchant agents are built on the ASI framework, as well as the protocol. This allowed us to move beyond simple chatbots and create intelligent, autonomous entities that can understand complex requests, manage inventory, process orders, and construct valid blockchain transactions. We also utilized METTA storage via the hyperon library to store merchant data and index it for the merchant agent to provide the best context to the customer agent. This is what enables the "AI-agent-driven" aspect of our platform to help users finalize their orders.

PYUSD: For payments to be stable and predictable, we integrated PYUSD as the primary medium of exchange. By using a trusted stablecoin, we remove the price volatility associated with native tokens like ETH, making the platform viable for real-world commerce between consumers and merchants.

Blockscout: Trust through transparency is a core tenet of web3. We leverage Blockscout as our on-chain analytics and visualization tool. After an order is successfully paid for, our dashboard provides a direct link to the transaction on our dedicated Blockscout instance. This allows user to verify their order details, payment amount, and status directly on the blockchain, creating an immutable and trustworthy record of every transaction.

Lighthouse: We utilized lighthouse to store order descriptions that are then pulled to the front end when viewing all the merchant and customer orders via the smart contract. The smart contract stores the CIDs of all these orders for transparency and data reliability.

background image mobile

Join the mailing list

Get the latest news and updates

A3A Protocol | ETHGlobal