Skip to content
Agent Allowance · Arc Mainnet · USDC Streams · ERC-8004
AgentBadge AgentBadge
vests
Arc Arc mainnet

Agent Allowance

Onchain USDC budget vaults for AI agents. The owner funds a vault once — funds vest linearly Sablier-style — and the agent can only claim what already vested, only to allowlisted payees, within a per-transaction cap. Live on Arc mainnet.

3
verified claims on mainnet
5042
Arc mainnet chain ID
Sablier
linear USDC vesting
46/46
Foundry tests green

Architecture

One funded vault, one enforced policy. Every write below is a real transaction on Arc mainnet (chainId 5042).

⚡ AgentBadge Owner human / multisig / ops controls policy 1. create agentId VaultFactory deploys + registry 0x5D1a…acA4 2. deploy BudgetVault USDC · rate = amt / 30d 0x2860…Ff52 5. pay USDC Payee (Vendor) allowlisted address 0x9a66…95A5 3. approve + deposit USDC → vesting starts AI Agent 0xcdd2…699d ERC-8004 id 2 4. claim amt,payee Guards payee allowlist per-tx cap vested−claimed·!paused onchain only checks ERC-8004 agentId = 2 Owner controls pause · cancel → unvested ↩ Three-role UI vite + wagmi · owner/agent/vendor explorer.arc.io every write auditable

Arc mainnet (5042) — the claim leg is a real verified transaction: 0x5a29b4…09b5 ↗

⚡ AgentBadge components in this flow ▾

Everything inside the dashed border is the Agent Allowance system we built and deployed on Arc mainnet:

  • VaultFactory — thin registry; createVault(owner, agent, agentId, registry, operator) deploys a fresh BudgetVault and indexes it in vaults[] / vaultOf[agent]
  • BudgetVault — holds USDC, releases it linearly over the vesting duration (Sablier Lockup semantics); enforces every guard at claim time
  • Guards — payee allowlist, per-transaction cap, vested−claimed balance, pause flag — all checked onchain, nothing trusted off-chain
  • Three-role UI — Vite + wagmi frontend: Owner (create/fund/policy), Agent (claim), Vendor (payment scan) — the exact views shown in the demo video
  • Owner, Agent, Payee, ERC-8004 and the explorer are external actors/services
📋 Step-by-step vault lifecycle ▾
  1. Create — the owner calls createVault on the factory with the agent address, its ERC-8004 agentId and optional operator
  2. Configure — the owner allowlists payees and sets perTxCap; the agent cannot route funds anywhere else
  3. Fund — approve + deposit(amount) sets the linear vesting rate (amount / duration) — Sablier-style streaming
  4. Claim — the agent calls claim(amount, payee); the contract checks allowlist, cap, vested−claimed and the pause flag, then transfers vested USDC straight to the payee
  5. Verify — every deposit, payee change, cap change and claim lands on explorer.arc.io; vendors confirm incoming payments by scanning their own address
  6. Exit — owner can pause instantly, or cancel: the vault returns every unvested unit and closes the stream
❓ FAQ — questions & answers ▾

What problem does it solve?

x402-style agent payments exist, but a funded key is an unlimited budget. Agent Allowance turns the budget into code: an owner funds a vault once, and the agent can only spend what vested, to whom the owner approved, within the per-transaction cap — enforced by the contract, not by trusting the agent.

How does the agent get its spending rate?

Depositing USDC starts linear vesting — the rate is amount / duration (Sablier Lockup semantics). Vested balances tick up continuously; the agent claims at any point and only up to vested − claimed.

Where is the proof it works on mainnet?

The full lifecycle ran on Arc mainnet (chainId 5042): approve, deposit 3 USDC, addPayee, setPerTxCap and three separate claims to the vendor — see the tx table below, each row links to explorer.arc.io. Latest claim 0x5a29b4…09b5 at block 27082200.

Can the owner claw money back?

Yes — pause() freezes new claims instantly, and cancel() returns all unvested USDC to the owner. What already vested stays claimable by the agent — Sablier semantics again.

Does the agent hold any funds?

No. The agent calls claim(amount, payee) and the vault transfers directly to the approved payee address — the agent's key never custodies USDC.

How does ERC-8004 fit in?

The vault stores the agent's ERC-8004 agentId (2 in the demo vault) for off-chain correlation — identity cards, service listings, x402 payment metadata — without gating claims on identity lookups.

Was the contract reviewed?

46/46 Foundry tests green plus an external adversarial review (Arc Studio audit): 3 Critical and 3 High findings found and fixed before mainnet deploy.

How it works

1

Create + fund

Owner calls createVault(agent, agentId) on the factory, then approve + deposit USDC — depositing starts linear vesting (Sablier-style rate = amount / duration).

2

Set policy

Owner allowlists payees and sets a per-transaction cap. From this point the contract — not trust — decides what the agent may spend.

3

Agent claims

Agent calls claim(amount, payee). Guards check allowlist, cap, vested−claimed and the pause flag; vested USDC goes straight to the payee.

4

Verify + control

Vendor scans its address to prove incoming payments; every write is on explorer.arc.io. Owner can top up, pause, or cancel — cancel returns all unvested funds.

Mainnet proof

The full vault lifecycle ran live on Arc mainnet on 2026-10-20/21 — every row links to explorer.arc.io.

Lifecycle stepTransaction
approve 3 USDC 0xfb313a0582…e0b1aa ↗
deposit 3 USDC → vesting starts 0xaf0b2dd109…9d5a56 ↗
addPayee (vendor) 0x92a234f6c6…073787 ↗
setPerTxCap 1 USDC 0xc927d0ac15…194a54 ↗
claim → vendor (+55 units) 0xab12863288…d9013d ↗
claim → vendor (+30, via UI) 0x99a6418d86…7d0c6e ↗
claim → vendor (+30, block 27082200) 0x5a29b45d13…8509b5 ↗
Network Arc mainnet · chainId 5042
Vault (demo, agentId 2) 0x2860258C…D4Ff52 ↗
Factory 0x5D1a014e…cdacA4 ↗
USDC token 0x36000000…000000 ↗
Agent 0xcdd23d10…58699d ↗
Vendor / payee 0x9a664574…8e95A5 ↗
Vendor balance delta 99,020 → 99,135 units · +115 over 3 claims

The three-role demo UI (Owner / Agent / Vendor) reproduced this flow end to end — the +30 claim above was submitted from the Agent view itself. Slide-videos with EN/RU voiceover ship in the submission repo.

Onchain guardrails

A funded key is not a budget — the policy lives in the contract.

Payee allowlist

claim() only pays addresses the owner added via addPayee — the agent cannot route to itself or arbitrary destinations.

Per-transaction cap

perTxCap bounds each single claim; a compromised agent key can never drain more than one capped payment.

Vested − claimed

Claims are bounded by linearly accrued balance — unvested funds are unreachable, even with a valid signature.

Pause / cancel

Owner pauses new claims instantly, or cancels: unvested USDC returns to the owner, the stream closes.

Stack

Arc mainnet 5042
deployment + verification chain
BudgetVault
solidity, sablier-style linear vesting
Foundry 46/46
tests + adversarial review fixes
ERC-8004 agentId
agent identity reference in vault
vite + wagmi + viem
three-role demo frontend
explorer.arc.io
auditability of every write
USDC 0x3600…0000
arc native usdc asset
Arc Studio
prototyping + review environment
edge-tts + ffmpeg
EN/RU slide-video pipeline

Budgets enforced in code — not in trust

Fund a vault, set the policy, and let the agent spend only what vested — verify every claim on explorer.arc.io.

Support: support@agentbadge.xyz