Menu

Explorer & Settings

Tempo Explorer Submit Project
Back to all projects

arc-pulse

by ecommercemah2023-gif · Updated 6 months ago

"AI-Powered Autonomous Payment Agent reviving HTTP 402. Built with Gemini, Circle, and Arc."

In the AI payments ecosystem

arc-pulse is an early-stage TypeScript project in the AI payments / x402 ecosystem. It currently has 0 GitHub stars and 0 forks.

README.md View on GitHub →

Arc-Pulse 🚀

Autonomous AI-Powered Payment Agent for Agentic Commerce

Built for Arc Powered by Circle AI by Gemini

Hackathon Submission for Agentic Commerce on Arc


🎯 What is Arc-Pulse?

Arc-Pulse is an autonomous API broker agent that detects premium API payment requirements (HTTP 402) and autonomously processes USDC payments on Arc L1 to unlock data access.

The Flow

1️⃣ Agent requests premium API data
     ↓
2️⃣ API returns HTTP 402 Payment Required
     ↓
3️⃣ Gemini AI analyzes payment request
     ↓
4️⃣ Agent autonomously pays USDC via Circle Wallet
     ↓
5️⃣ Transaction confirmed on Arc blockchain
     ↓
6️⃣ Agent retries request with payment proof
     ↓
7️⃣ Premium data unlocked! ✅

🛠️ Tech Stack

Layer Technology
Blockchain Arc L1 (Arbitrum Sepolia)
Payments Circle Developer-Controlled Wallets, USDC
AI Agent Gemini API with Function Calling
Backend Express, tRPC, TypeScript
Frontend React 19, TailwindCSS
Database PostgreSQL, Drizzle ORM
Testing Vitest, Playwright

🚀 Quick Start

Prerequisites

Installation

# Clone the repo
git clone https://github.com/your-username/arc-pulse.git
cd arc-pulse

# Install dependencies
pnpm install

# Setup environment
cp .env.example .env
# Edit .env with your API keys

# Setup database
pnpm db:push

# Start development server
pnpm dev

Open Dashboard

Navigate to http://localhost:5173/dashboard to see the agent in action!


📁 Project Structure

arc-pulse/
├── client/              # React frontend
│   └── src/
│       ├── pages/       # Dashboard, Home
│       └── components/  # UI components
├── server/              # Express backend
│   ├── _core/           # tRPC, LLM, auth
│   └── modules/         # Core business logic
│       ├── paymentService.ts    # Payment orchestration
│       ├── circleWallet.ts      # Circle SDK integration
│       ├── geminiAgent.ts       # AI decision engine
│       ├── arcBlockchain.ts     # Transaction verification
│       └── walletFactory.ts     # Wallet fallback pattern
├── drizzle/             # Database schema
└── tests/               # Test suites

🔐 Environment Variables

See .env.example for all required configuration.

Required for Demo:

  • CIRCLE_API_KEY - Circle Developer API key
  • CIRCLE_ENTITY_SECRET - 32-byte hex entity secret
  • CIRCLE_WALLET_SET_ID - Your wallet set ID
  • GOOGLE_GEMINI_KEY or BUILT_IN_FORGE_API_KEY - AI API key

🧪 Testing

# Run unit tests
pnpm test

# Run e2e tests
pnpm test:e2e

📊 Features

  • Autonomous Payment Detection - Detects HTTP 402 responses
  • AI-Powered Decisions - Gemini evaluates payment worthiness
  • Real USDC Transfers - Circle Wallets on Arc testnet
  • Blockchain Verification - Confirms transactions on-chain
  • Budget Controls - Daily spending limits
  • Mock Mode - Development without real credentials
  • Transaction Dashboard - Visual payment history

🎥 Demo

The dashboard at /dashboard demonstrates the complete flow:

  1. Initialize Circle Wallet
  2. Trigger premium data request (0.05 USDC)
  3. Watch AI agent make autonomous payment decision
  4. See transaction confirmed on Arc
  5. Premium data unlocked!

📜 License

MIT


🤝 Team

Built with ❤️ for the Agentic Commerce on Arc Hackathon


Powered by Arc, Circle, and Gemini

📝 Circle Product Feedback

What we loved:

  • The Console UI is incredibly clean and made it easy to visualize wallet states during debugging.
  • REST API documentation was clear, especially the POST /transfers endpoint which we used for the main payment flow.

Challenges we faced:

  • We initially struggled with the Entity Secret Set creation; the error messages were generic (e.g., "Invalid Request"), making it hard to debug without digging into forums.
  • It would be helpful to have a "Simulation Mode" in the SDK that doesn't require waiting for blockchain confirmation during local testing.
All TypeScript projects →