LobPay: AI-agent marketplace using x402 for autonomous shopping, payments, and delivery. 🦞💸
LobPay is a decentralized commerce infrastructure designed specifically for the agentic economy, serving as a high-performance "Amazon for Agents" where autonomous entities can provision, trade, and settle transactions natively. Built on Next.js 15, the platform bridges the gap between traditional merchant services and DeFi by replacing fragile browser-based scraping with a structured API gateway and human-readable identities via ENS tracking. The project features a robust Revenue Liquidation Engine powered by the Uniswap Trade API and UniswapX, allowing merchants to rotate USDC earnings into assets like ETH or WBTC through gas-efficient EIP-712 permit signatures. Critically, the architecture utilizes 0G Storage as its primary data layer to maintain immutable, on-chain merchant product catalogs and transaction metadata, ensuring that the source of truth for AI consumers is permanent, tamper-proof, and lightning-fast.
LobPay is engineered as a native machine-to-machine commerce layer using Next.js 15 (App Router) and Wagmi/Viem for a seamless Web3 experience. At its core, the project replaces traditional, fragile browser-scraping methods with a structured API gateway, allowing AI agents to interact with merchant inventories with 100% reliability. We integrated ENS to provide human-readable identities for every merchant node, mapping complex hex addresses to business domains for better tracking and reputation. A major technical pivot was replacing IPFS with 0G Storage to maintain merchant product catalogs and metadata; this ensures data is not only decentralized and permanent but also provides the high-speed data availability required for real-time agentic workflows.
The DeFi backbone is powered by the Uniswap Trade API and UniswapX, enabling our "Revenue Liquidation Engine." We implemented EIP-712 permit signatures to allow merchants to authorize swaps via gasless signatures, significantly reducing overhead. One "hacky" but essential fix involved building a custom JSON Replacer Logic within our swap hooks to handle BigInt serialization; since standard JSON cannot stringify blockchain-native large integers, this interceptor ensures 100% numerical precision across our API calls without runtime crashes. The entire stack is tied together with a MariaDB backend and a custom Shimmer-Skeleton UI to maintain perceived performance while the 0G and ENS data fetches resolve.

