AgentMandate

Onchain trust layer for AI agents trading on Uniswap. Bound the agent, not the keys.

Repo
AgentMandate banner

About

AgentMandate is the trust layer for AI agents trading on Uniswap. Instead of handing your private key to an agent (risky) or signing every tx yourself (defeats the point), you deposit funds into a smart contract that defines onchain rules: allowed tokens, max per swap, daily limits. The agent gets its own wallet but can ONLY call executeSwap within the mandate's bounds. Any violation reverts at the Solidity level. Built with Uniswap's Trading API on Base. Even if the agent is compromised, your funds are safe.

How it's made

The core is a Solidity contract on Base Sepolia that acts as a programmable proxy between an AI agent and the Uniswap Universal Router. The owner deposits funds and defines a mandate (allowed tokens, max per swap, daily USDC volume). The agent's wallet can only call executeSwap, which validates every parameter onchain before forwarding the call.

Frontend is Next.js 14 with wagmi v2, viem, and RainbowKit. The chat panel calls Claude Sonnet 4.5 with a swap_tokens tool. Claude parses intent, the backend fetches calldata from the Uniswap Trading API, the frontend submits through the mandate.

The hard part was Permit2. The Trading API returns calldata assuming a Permit2 setup that breaks for contract callers. We pre approve Permit2 in the constructor, then call Permit2.approve(token, router, amount, deadline) inside executeSwap right before forwarding.

From the public ETHGlobal showcase page. Votes, swipes and the judge score are hackfeed's own.

AI judge

Not judged yet. A free model reads this page, compares it with similar projects and this event's winners, then scores it and says what would make it win.

Still being built?

DormantLast push 215 days ago

Swipe stats

0upvotes
0skips
0saves

Discussion 0

No comments yet. Ask the team something, or say what you'd use it for.

Posting as a guest. Plain text, 1,000 characters max.

Already built nearby

Closest projects by meaning and shared words. Similar isn't the same as copied: read them.

Agent-Verify

Trust layer for AI agents: ENS identity, on-chain execution proof, and decentralized storage.

AgentOS

The OS layer for onchain AI agents: ENS identity, Uniswap trading, and KeeperHub execution.

SAKA - DeFi AI Agent

Your own AI DeFi agent on Uniswap that thinks on 0G and proves every move it makes.

ETHGlobal MumbaiPrize winnerJudge 6.5 Shipping#ai-agents#ai

Trust Swap

Reputation-graded Uniswap settlement: AI agents execute via TrustSwapRouter, gated on ENS trust