hackquest logo

Agent City

Give an AI agent a wallet without the risk. A private Venice gate decides whether to spend; an on-chain MetaMask cap decides how much. Agents pay agents via x402, settled on Base by 1Shot.

Videos

Project image 1
Project image 2
Project image 3
Project image 4

Tech Stack

React
Node
Web3
Metamask
Venice
1Shot
x402
ERC-7715

Description

Agent City — a spending firewall for AI agents.

Give an autonomous agent a wallet, and one bad prompt can drain it. Agent City puts two independent locks on every payment:

1. A private brain decides WHETHER.
A Venice AI gate, using zero-retention inference, judges each spend before any on-chain action. It fails closed: if the model cannot approve the spend, nothing moves.

2. An on-chain cap decides HOW MUCH.
Funding is a MetaMask ERC-7715 Advanced Permission from your own wallet, such as 5 USDC/day. This is a delegation enforced by the chain, not a setting in our code.

How it works

  1. You fund a Manager agent from MetaMask using ERC-7715.

  2. The Manager hires workers and re-delegates each one a narrower sub-budget using ERC-7710 agent-to-agent delegation.

  3. Each worker buys from a live x402 pay-per-call service.

  4. The price settles as an ERC-7710 redemption on Base through the 1Shot relayer, with gas paid in USDC and no ETH required.

  5. Venice composes the final deliverable using only the services the agents actually paid for.

  6. One click revokes the whole city.

The climax is negation: tell an agent to drain the treasury to an unrelated wallet, and the Venice gate refuses. There is no transaction and nothing settles. The money never moves because the model says no before the chain ever sees it.

Everything is real: a live ERC-7715 grant from MetaMask, on-chain ERC-7710 redemptions on Base, a testnet demo, a mainnet settlement with real USDC, a signature-verified 1Shot webhook using Ed25519/JWKS, and a passing test suite.

Stack: MetaMask Smart Accounts Kit · ERC-7715 · ERC-7710 · EIP-7702 · 1Shot API · Venice AI · x402 · Base · TypeScript

Progress During Hackathon

Built during the hackathon:

Delegation core
Wired MetaMask’s Delegation Framework end to end: ERC-7715 grants, ERC-7710 redelegation, EIP-7702 account upgrades, and settlement through the permissionless 1Shot relayer.

The City
Built a multi-agent orchestrator where a Manager hires workers, re-delegates capped sub-budgets, and each worker buys from a real x402 service market. Every settlement becomes an on-chain receipt in the City Ledger.

Venice spend-gate
Added a private, zero-retention model gate that reviews each spend and fails closed. Venice also writes per-worker reasoning and composes the final brief.

Agent reputation
Implemented credit and tier logic where reputation accrues from on-chain receipts and helps size each agent’s next budget.

UI
Built a “Blueprint Civic” frontend with a live delegation map, React Flow visualization, streaming ledger, grant / approve / revoke controls, and a one-click “bad spend” demo that shows the block.

1Shot webhook
Implemented an Ed25519/JWKS signature-verified status receiver, with polling fallback.

Proofs & tests
Completed a real MetaMask ERC-7715 grant end to end, on-chain ERC-7710 redemptions on Base Sepolia, a Base mainnet settlement with real USDC, and a passing TypeScript test suite.

Note: the project pivoted mid-hackathon from an earlier single-agent “treasurer” concept to this multi-agent firewall, which is visible in the git history.

Fundraising Status

Not fundraising.

Agent City is an open-source hackathon project. It has no capital raised, no token, and no users yet. Open to feedback, partnerships, and grants.

Team Leader
KKaran Bisht
Project Link
Deploy Ecosystem
BaseBase
Sector
AIInfraDeFi