Skip to main content
Back to ATP
Agent Treasury Protocol

The Complete Architecture Guide

Everything you need to build an autonomous agent that manages its own money — earns yield on idle capital, enforces its own budget, and lets the owner extract surplus safely. Based on real research across 50+ production deployments, with complete code.

What's included

  • 8 chapters, ~40 pages of technical content
  • Solidity vault contract (production-ready, Base-deployed)
  • TypeScript SDK with full type definitions
  • x402 payment integration examples
  • Extraction controller with sigmoid guardrails
  • Compliance module with audit log pattern
  • Architecture diagrams for every component
  • Decision frameworks (when to use each pattern)
  • Lifetime access + all future updates

Table of contents

01
Why agents fail financially
The gap between wallet primitives and operational finance. Why raw wallets aren't enough.
02
Treasury vault design
Smart contract architecture for policy-governed capital pools. Sub-accounts, spending limits, approved recipients.
03
Yield automation on Base
Sweeping idle USDC to Compound V3, Aave V3, Morpho. CrypWalk integration pattern. Risk tolerance configuration.
04
x402 payment management
Per-category budgets for LLM calls, compute, data. Auto-approve thresholds. Settlement tracking and receipts.
05
Owner extraction with guardrails
The sigmoid extraction function. Cooldown periods, surplus calculation, lagged extraction. Tax logging.
06
Compliance and audit
KYC/AML counterparty registry. Jurisdiction awareness. Immutable audit trail. CSV export for accountants.
07
Cognitive-economic feedback loops
Connecting agent performance to capital allocation. Phase theft, TMS, goal-space coupling.
08
Full implementation walkthrough
End-to-end code: vault deployment, SDK setup, yield sweep, extraction controller, dashboard basics.
$199
One-time. Lifetime access. Delivered to your inbox.
Secure checkout via Stripe. Guide delivered to your inbox within 24 hours.