Architecture
MetaMask Agent Wallet exposes wallet operations through the mm CLI, backed by the
@metamask/agentic-sdk package.
CLI and session
- Install
@metamask/agentic-clito get themmbinary. - Session data is stored at
~/.metamask/session.jsonwith restricted file permissions. - Run
mm resetto clear local session state.
Wallet modes
| Mode | Keys | Signing model |
|---|---|---|
| server-wallet | Cubist TEE-backed custody | Async jobs with optional MFA approval |
| BYOK | User-supplied mnemonic (optionally encrypted) | Local signing; immediate results |
Server-wallet async model
When you submit a signing or transaction request in server-wallet mode:
- The CLI submits the request to the wallet service.
- The service may simulate the transaction, run Transaction Shield, and evaluate policies.
- If policy requires human approval, the job enters an
AWAITING_MFAstate until you approve via MetaMask Mobile or email. - The CLI returns a
pollingIdunless you pass--wait.
Track pending work:
mm wallet requests list
mm wallet requests watch --polling-id <POLLING_ID>
REPL vs headless
- REPL — Run
mmwith no arguments on a TTY for an interactive shell. - Headless — Pass flags explicitly or use
--format jsonfor machine-readable output in scripts and agents.