Skip to content

Commit 7e958ac

Browse files
authored
updated native account abstraction docs (#1732)
* updated native account abstraction docs * updated native account abstraction docs * updated added cobalt * chore: regenerate docs/AGENTS.md, docs/llms-full.txt, docs/llms.txt (post-commit of fc56b08) * updated added cobalt * updated to mention vibenet
1 parent 85fe2a4 commit 7e958ac

6 files changed

Lines changed: 143 additions & 3 deletions

File tree

docs/AGENTS.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,7 @@ npx skills add base/base-skills
9595
|base-chain/specs/upgrades/azul:exec-engine,node-upgrade,overview,proofs
9696
|base-chain/specs/upgrades/beryl:b20-playground,b20,overview
9797
|base-chain/specs/upgrades/canyon:overview
98+
|base-chain/specs/upgrades/cobalt:eip-8130
9899
|base-chain/specs/upgrades/delta:overview,span-batches
99100
|base-chain/specs/upgrades/ecotone:derivation,l1-attributes,overview
100101
|base-chain/specs/upgrades/fjord:derivation,exec-engine,overview,predeploys

docs/base-chain/specs/upgrades/beryl/overview.mdx

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ description: "Overview of the Beryl hardfork, introducing the B20 native token s
88
- Introduce [B20](/base-chain/specs/upgrades/beryl/b20): Base's native token standard for stablecoin, real-world asset (RWA), and long-tail token issuers
99
- Reduce the single-proof withdrawal finalization period from 7 days to 5 days for increased capital efficiency
1010
- Reth V2: up to 50% disk reduction and a rewritten state root pipeline delivering +33% throughput
11+
- Upcoming in a later Beryl phase: [native account abstraction (EIP-8130)](/base-chain/specs/upgrades/beryl/eip-8130), currently previewing on the vibenet devnet
1112

1213
## Activation Timestamps
1314

@@ -40,6 +41,12 @@ B20 is Base's native token standard - ERC-20 compatible tokens implemented as Ru
4041
- [Mint & Burn](/base-chain/specs/upgrades/beryl/b20#mint)
4142
- [Variants](/base-chain/specs/upgrades/beryl/b20#variants)
4243

44+
## Native Account Abstraction (EIP-8130)
45+
46+
A later Beryl phase brings account abstraction into the protocol. Accounts configure authorized actors and signature validation onchain. Apps get portable smart accounts, scoped session keys, atomic batching, and native gas sponsorship without bundler or relay infrastructure. EIP-8130 is experimental and currently runs only on the vibenet devnet.
47+
48+
- [Native Account Abstraction (EIP-8130)](/base-chain/specs/upgrades/beryl/eip-8130)
49+
4350
## Withdrawals
4451

4552
The single-proof dispute game finalization window is reduced from 7 days to 5 days. The dual-proof fast path (TEE + ZK) introduced in Azul remains at 1 day.
Lines changed: 123 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,123 @@
1+
---
2+
title: "Native Account Abstraction"
3+
description: "Build with native account abstraction on Base. EIP-8130 smart accounts send ordinary transactions, with no bundlers or relays."
4+
---
5+
6+
[EIP-8130](https://eip.tools/eip/8130) builds account abstraction into the protocol. An account registers who can act for it, and how its signatures are checked, in an onchain system contract. The chain validates each transaction against that configuration, so smart accounts work without bundlers, relays, or a separate mempool.
7+
8+
<Warning>
9+
EIP-8130 is experimental and currently runs only on the [vibenet devnet](https://vibes.base.org/build).
10+
</Warning>
11+
12+
## Build with EIP-8130
13+
14+
EIP-8130 is live on vibenet (chain ID `84538453`, RPC `https://rpc.vibes.base.org`). Client support lives in an experimental viem fork:
15+
16+
```bash
17+
bun add "viem@github:chunter-cb/viem#feat/eip-8130"
18+
```
19+
20+
The example below performs the full flow:
21+
22+
1. Creates an account.
23+
2. Funds it from the faucet.
24+
3. Sends a batch of calls that succeed or revert together.
25+
4. Verifies that every phase succeeded.
26+
27+
```ts create-and-send.ts highlight={19,30-40,43-44}
28+
import { createPublicClient, http, parseEther } from "viem";
29+
import { privateKeyToAccount, generatePrivateKey } from "viem/accounts";
30+
import {
31+
newSmartAccount8130, sendCalls8130, estimateGas8130,
32+
encodeWalletCalls, waitForTransactionReceipt8130, allPhasesSucceeded,
33+
} from "viem/experimental/eip8130";
34+
35+
const RPC_URL = "https://rpc.vibes.base.org";
36+
const chain = {
37+
id: 84538453,
38+
name: "vibenet",
39+
nativeCurrency: { name: "Ether", symbol: "ETH", decimals: 18 },
40+
rpcUrls: { default: { http: [RPC_URL] } },
41+
};
42+
const client = createPublicClient({ chain, transport: http(RPC_URL) });
43+
44+
// The account address is deterministic and exists before any deployment
45+
const signer = privateKeyToAccount(generatePrivateKey());
46+
const account = newSmartAccount8130({ signer });
47+
48+
// Fund it from the vibenet faucet
49+
await fetch("https://vibes.base.org/api/vibenet/faucet/drip", {
50+
method: "POST",
51+
headers: { "content-type": "application/json" },
52+
body: JSON.stringify({ address: account.address }),
53+
});
54+
55+
// Estimate, then send a batch. Account creation rides along in the same transaction
56+
const calls = [{ to: "0x…recipient", value: parseEther("0.001") }];
57+
const gas = await estimateGas8130(client, {
58+
sender: account.address,
59+
accountChanges: [account.createChange],
60+
calls: encodeWalletCalls({ account: account.address, calls: [calls] }),
61+
});
62+
const hash = await sendCalls8130(client, {
63+
account,
64+
accountChanges: [account.createChange],
65+
calls,
66+
gas: (gas * 120n) / 100n,
67+
});
68+
69+
// An 8130 receipt reports per-phase results, so check all of them
70+
const receipt = await waitForTransactionReceipt8130(client, { hash });
71+
if (!allPhasesSucceeded(receipt)) throw new Error("a phase reverted");
72+
```
73+
74+
One transaction creates the account, executes the batch, and pays for gas.
75+
76+
## How it works
77+
78+
Everything in the example maps to one of five concepts. An 8130 transaction names a sender account, proves the sender is authorized to act for it, and carries a batch of calls.
79+
80+
### Account
81+
82+
Account addresses are deterministic: viem computes them locally with `CREATE2`. That is why `account.address` exists before any deployment and `account.createChange` rides along in the first transaction. Each account is a small proxy contract that forwards calls to a shared implementation. `DefaultAccount` is the minimal building block and backs externally owned accounts (EOAs) upgraded via EIP-7702. A variant built for high transaction rates locks outbound ETH during execution in exchange for higher mempool rate limits.
83+
84+
### Signer and Actor
85+
86+
A **signer** produces the transaction's authorization (`privateKeyToAccount` above). An **actor** is the onchain identity that authorization resolves to, recorded in the `AccountConfiguration` system contract. An account can authorize many actors and revoke each independently.
87+
88+
### Scope and Policy
89+
90+
Each actor carries **scope** flags (`SCOPE_NONCE`, `SCOPE_POLICY`) that limit what it may do. It can also bind to an onchain **policy**: per-token spend limits and restrictions on which contracts and functions it may call. This is the native session-key model: an app gets an actor with exactly the permissions it needs, revocable at any time.
91+
92+
### Authenticators
93+
94+
Signature validation is pluggable. Authenticator contracts implement `IAuthenticator.authenticate(hash, data)`. The reference set covers secp256k1 (standard Ethereum keys), P-256, and WebAuthn. Passkeys therefore validate at the protocol level, not through wrapper contracts.
95+
96+
### Payer
97+
98+
A transaction can name a **payer** that covers gas on the sender's behalf. Draft [ERC-8168](https://eip.tools/eip/8168) standardizes the payer service flow: how apps discover and request sponsorship.
99+
100+
## Why native account abstraction
101+
102+
Smart accounts on Ethereum today are bolted on from outside the protocol. [ERC-4337](https://eips.ethereum.org/EIPS/eip-4337) requires an alternate mempool, bundlers, and an EntryPoint contract; every app inherits that infrastructure and its costs. [EIP-7702](https://eips.ethereum.org/EIPS/eip-7702) delegates an EOA to contract code, but the account still validates against its single original key.
103+
104+
EIP-8130 moves the abstraction into the chain, so the features 4337 provides through external services come built into ordinary transactions:
105+
106+
| | ERC-4337 | EIP-7702 | EIP-8130 |
107+
|---|---|---|---|
108+
| Validation | EntryPoint contract via bundlers | One fixed key | Protocol, against onchain configuration |
109+
| Infrastructure | Bundlers + alternate mempool | None | None - standard transactions |
110+
| Session keys | Per-wallet plugin systems | Not native | Native actors with scoped policies |
111+
| Gas sponsorship | Paymaster contracts | Not native | Native payers ([ERC-8168](https://eip.tools/eip/8168)) |
112+
| Batching | Via account contract | Via delegated code | Native, atomic, per-transaction |
113+
114+
## Go deeper
115+
116+
<CardGroup cols={2}>
117+
<Card title="Reference contracts" href="https://github.com/base/eip-8130" icon="github">
118+
`AccountConfiguration`, account implementations, and authenticators, with Foundry tests.
119+
</Card>
120+
<Card title="Specifications" href="https://eip.tools/eip/8130" icon="file-lines">
121+
The EIP-8130 draft, and companion draft [ERC-8168](https://eip.tools/eip/8168) for payer services.
122+
</Card>
123+
</CardGroup>

docs/docs.json

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -265,6 +265,13 @@
265265
"pages": [
266266
"base-chain/specs/upgrades/beryl/overview",
267267
"base-chain/specs/upgrades/beryl/b20"
268+
269+
]
270+
},
271+
{
272+
"group": "Cobalt",
273+
"pages": [
274+
"base-chain/specs/upgrades/cobalt/eip-8130"
268275
]
269276
},
270277
{

docs/llms-full.txt

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -172,12 +172,12 @@ const client = createPublicClient({ chain: base, transport: http() })
172172
- [Network Fees](https://docs.base.org/base-chain/network-information/network-fees): Documentation about network fees on Base. This page covers details of the two-component cost system involving L2 execution fees and L1 security fees, and offers insights on fee variations and cost-saving strategies.
173173
- [Throughput and Limits](https://docs.base.org/base-chain/network-information/throughput-and-limits): Gas limits and throughput-related network parameters on Base.
174174
- [Transaction Finality](https://docs.base.org/base-chain/network-information/transaction-finality): Detailed information about transaction finality on Base.
175-
- [Transaction Ordering](https://docs.base.org/base-chain/network-information/transaction-ordering): This page outlines how Base transactions are ordered.
175+
- [Transaction Ordering](https://docs.base.org/base-chain/network-information/transaction-ordering): Transactions are ordered based priority fee and arrival time, which determines which Flashblock they are included in.
176176
- [Troubleshooting Transactions](https://docs.base.org/base-chain/network-information/troubleshooting-transactions): Guide to diagnosing and resolving transaction issues on Base.
177177
- [Node Providers](https://docs.base.org/base-chain/node-operators/node-providers): Documentation for Node Providers for the Base network. Including details on their services, supported networks, and pricing plans.
178178
- [Node Performance](https://docs.base.org/base-chain/node-operators/performance-tuning): Hardware specifications, storage requirements, client recommendations, and configuration settings for running a performant Base node.
179179
- [Run a Node](https://docs.base.org/base-chain/node-operators/run-a-base-node): A tutorial that teaches how to set up and run a Base Node.
180-
- [Node Snapshots](https://docs.base.org/base-chain/node-operators/snapshots): Download and restore Base node snapshots to significantly reduce initial sync time for both archive and pruned nodes.
180+
- [Node Snapshots](https://docs.base.org/base-chain/node-operators/snapshots): Download and restore Base node snapshots to significantly reduce initial sync time for nodes.
181181
- [Node Troubleshooting](https://docs.base.org/base-chain/node-operators/troubleshooting): Solutions to common issues when setting up and running a Base node, covering sync problems, networking, snapshots, and performance.
182182
- [Connecting to Base](https://docs.base.org/base-chain/quickstart/connecting-to-base): Network details and wallet setup for Base Mainnet, Base Testnet (Sepolia), and Base Vibenet.
183183
- [How to avoid getting your app flagged as malicious](https://docs.base.org/base-chain/security/avoid-malicious-flags): The Base bug bounty program and procedures for reporting vulnerabilities.
@@ -207,6 +207,7 @@ const client = createPublicClient({ chain: base, transport: http() })
207207
- [Node Upgrade Guide](https://docs.base.org/base-chain/specs/upgrades/azul/node-upgrade): Migrate your Base node to base-reth-node and base-consensus for Azul.
208208
- [Proof System](https://docs.base.org/base-chain/specs/upgrades/azul/proofs): Specification of the Azul multi-proof system, replacing the single output proposer with an AggregateVerifier contract for L2 checkpoint security.
209209
- [B20 Native Token Standard](https://docs.base.org/base-chain/specs/upgrades/beryl/b20): B20 is Base's native token standard - designed for stablecoin issuers, real-world asset (RWA) and equity issuers, and long-tail token creators.
210+
- [Native Account Abstraction](https://docs.base.org/base-chain/specs/upgrades/cobalt/eip-8130): Build with native account abstraction on Base. EIP-8130 smart accounts send ordinary transactions, with no bundlers or relays.
210211
- [Span-batches](https://docs.base.org/base-chain/specs/upgrades/delta/span-batches): Specification of span batches introduced in Delta, a new batch format that compresses sequences of L2 blocks for more efficient L1 data posting.
211212
- [Derivation](https://docs.base.org/base-chain/specs/upgrades/ecotone/derivation): Derivation changes in the Ecotone upgrade, extending the retrieval stage to support EIP-4844 blobs as an additional data availability source.
212213
- [Ecotone L1 Attributes](https://docs.base.org/base-chain/specs/upgrades/ecotone/l1-attributes): L1 attributes transaction changes in the Ecotone upgrade, updating calldata format to support the new blob-based fee calculation model.

docs/llms.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@
8989
- [Node Providers](https://docs.base.org/base-chain/node-operators/node-providers): Documentation for Node Providers for the Base network. Including details on their services, supported networks, and pricing plans.
9090
- [Node Performance](https://docs.base.org/base-chain/node-operators/performance-tuning): Hardware specifications, storage requirements, client recommendations, and configuration settings for running a performant Base node.
9191
- [Run a Node](https://docs.base.org/base-chain/node-operators/run-a-base-node): A tutorial that teaches how to set up and run a Base Node.
92-
- [Node Snapshots](https://docs.base.org/base-chain/node-operators/snapshots): Download and restore Base node snapshots to significantly reduce initial sync time for both archive and pruned nodes.
92+
- [Node Snapshots](https://docs.base.org/base-chain/node-operators/snapshots): Download and restore Base node snapshots to significantly reduce initial sync time for nodes.
9393
- [Node Troubleshooting](https://docs.base.org/base-chain/node-operators/troubleshooting): Solutions to common issues when setting up and running a Base node, covering sync problems, networking, snapshots, and performance.
9494
- [Connecting to Base](https://docs.base.org/base-chain/quickstart/connecting-to-base): Network details and wallet setup for Base Mainnet, Base Testnet (Sepolia), and Base Vibenet.
9595
- [How to avoid getting your app flagged as malicious](https://docs.base.org/base-chain/security/avoid-malicious-flags): The Base bug bounty program and procedures for reporting vulnerabilities.
@@ -119,6 +119,7 @@
119119
- [Node Upgrade Guide](https://docs.base.org/base-chain/specs/upgrades/azul/node-upgrade): Migrate your Base node to base-reth-node and base-consensus for Azul.
120120
- [Proof System](https://docs.base.org/base-chain/specs/upgrades/azul/proofs): Specification of the Azul multi-proof system, replacing the single output proposer with an AggregateVerifier contract for L2 checkpoint security.
121121
- [B20 Native Token Standard](https://docs.base.org/base-chain/specs/upgrades/beryl/b20): B20 is Base's native token standard - designed for stablecoin issuers, real-world asset (RWA) and equity issuers, and long-tail token creators.
122+
- [Native Account Abstraction](https://docs.base.org/base-chain/specs/upgrades/cobalt/eip-8130): Build with native account abstraction on Base. EIP-8130 smart accounts send ordinary transactions, with no bundlers or relays.
122123
- [Span-batches](https://docs.base.org/base-chain/specs/upgrades/delta/span-batches): Specification of span batches introduced in Delta, a new batch format that compresses sequences of L2 blocks for more efficient L1 data posting.
123124
- [Derivation](https://docs.base.org/base-chain/specs/upgrades/ecotone/derivation): Derivation changes in the Ecotone upgrade, extending the retrieval stage to support EIP-4844 blobs as an additional data availability source.
124125
- [Ecotone L1 Attributes](https://docs.base.org/base-chain/specs/upgrades/ecotone/l1-attributes): L1 attributes transaction changes in the Ecotone upgrade, updating calldata format to support the new blob-based fee calculation model.

0 commit comments

Comments
 (0)