agentwallet-sdk 5.0.0 → 5.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +221 -0
- package/dist/abi.d.ts +397 -0
- package/dist/abi.d.ts.map +1 -0
- package/dist/abi.js +255 -0
- package/dist/abi.js.map +1 -0
- package/dist/ap2/index.d.ts +185 -0
- package/dist/ap2/index.d.ts.map +1 -0
- package/dist/ap2/index.js +255 -0
- package/dist/ap2/index.js.map +1 -0
- package/dist/bridge/abis.d.ts +64 -0
- package/dist/bridge/abis.d.ts.map +1 -0
- package/dist/bridge/abis.js +129 -0
- package/dist/bridge/abis.js.map +1 -0
- package/dist/bridge/client.d.ts +35 -0
- package/dist/bridge/client.d.ts.map +1 -0
- package/dist/bridge/client.js +245 -0
- package/dist/bridge/client.js.map +1 -0
- package/dist/bridge/index.d.ts +4 -0
- package/dist/bridge/index.d.ts.map +1 -0
- package/dist/bridge/index.js +3 -0
- package/dist/bridge/index.js.map +1 -0
- package/dist/bridge/types.d.ts +68 -0
- package/dist/bridge/types.d.ts.map +1 -0
- package/dist/bridge/types.js +93 -0
- package/dist/bridge/types.js.map +1 -0
- package/dist/bridge/unified.d.ts +101 -0
- package/dist/bridge/unified.d.ts.map +1 -0
- package/dist/bridge/unified.js +284 -0
- package/dist/bridge/unified.js.map +1 -0
- package/dist/chains.d.ts +62 -0
- package/dist/chains.d.ts.map +1 -0
- package/dist/chains.js +108 -0
- package/dist/chains.js.map +1 -0
- package/dist/escrow/MutualStakeEscrow.d.ts +75 -0
- package/dist/escrow/MutualStakeEscrow.d.ts.map +1 -0
- package/dist/escrow/MutualStakeEscrow.js +339 -0
- package/dist/escrow/MutualStakeEscrow.js.map +1 -0
- package/dist/escrow/types.d.ts +59 -0
- package/dist/escrow/types.d.ts.map +1 -0
- package/dist/escrow/types.js +11 -0
- package/dist/escrow/types.js.map +1 -0
- package/dist/escrow/verifiers.d.ts +26 -0
- package/dist/escrow/verifiers.d.ts.map +1 -0
- package/dist/escrow/verifiers.js +53 -0
- package/dist/escrow/verifiers.js.map +1 -0
- package/dist/fiat/index.d.ts +10 -0
- package/dist/fiat/index.d.ts.map +1 -0
- package/dist/fiat/index.js +9 -0
- package/dist/fiat/index.js.map +1 -0
- package/dist/fiat/onramp.d.ts +101 -0
- package/dist/fiat/onramp.d.ts.map +1 -0
- package/dist/fiat/onramp.js +155 -0
- package/dist/fiat/onramp.js.map +1 -0
- package/dist/fiat/providers/index.d.ts +16 -0
- package/dist/fiat/providers/index.d.ts.map +1 -0
- package/dist/fiat/providers/index.js +30 -0
- package/dist/fiat/providers/index.js.map +1 -0
- package/dist/fiat/providers/moonpay.d.ts +22 -0
- package/dist/fiat/providers/moonpay.d.ts.map +1 -0
- package/dist/fiat/providers/moonpay.js +107 -0
- package/dist/fiat/providers/moonpay.js.map +1 -0
- package/dist/fiat/providers/stripe.d.ts +26 -0
- package/dist/fiat/providers/stripe.d.ts.map +1 -0
- package/dist/fiat/providers/stripe.js +135 -0
- package/dist/fiat/providers/stripe.js.map +1 -0
- package/dist/fiat/providers/transak.d.ts +26 -0
- package/dist/fiat/providers/transak.d.ts.map +1 -0
- package/dist/fiat/providers/transak.js +119 -0
- package/dist/fiat/providers/transak.js.map +1 -0
- package/dist/fiat/types.d.ts +106 -0
- package/dist/fiat/types.d.ts.map +1 -0
- package/dist/fiat/types.js +13 -0
- package/dist/fiat/types.js.map +1 -0
- package/dist/flash/executor.d.ts +119 -0
- package/dist/flash/executor.d.ts.map +1 -0
- package/dist/flash/executor.js +195 -0
- package/dist/flash/executor.js.map +1 -0
- package/dist/flash/index.d.ts +28 -0
- package/dist/flash/index.d.ts.map +1 -0
- package/dist/flash/index.js +29 -0
- package/dist/flash/index.js.map +1 -0
- package/dist/flash/scanner.d.ts +133 -0
- package/dist/flash/scanner.d.ts.map +1 -0
- package/dist/flash/scanner.js +212 -0
- package/dist/flash/scanner.js.map +1 -0
- package/dist/flash/types.d.ts +136 -0
- package/dist/flash/types.d.ts.map +1 -0
- package/dist/flash/types.js +23 -0
- package/dist/flash/types.js.map +1 -0
- package/dist/gas/index.d.ts +4 -0
- package/dist/gas/index.d.ts.map +1 -0
- package/dist/gas/index.js +3 -0
- package/dist/gas/index.js.map +1 -0
- package/dist/gas/sponsor.d.ts +70 -0
- package/dist/gas/sponsor.d.ts.map +1 -0
- package/dist/gas/sponsor.js +193 -0
- package/dist/gas/sponsor.js.map +1 -0
- package/dist/gas/types.d.ts +76 -0
- package/dist/gas/types.d.ts.map +1 -0
- package/dist/gas/types.js +21 -0
- package/dist/gas/types.js.map +1 -0
- package/dist/identity/agent-identity.d.ts +276 -0
- package/dist/identity/agent-identity.d.ts.map +1 -0
- package/dist/identity/agent-identity.js +300 -0
- package/dist/identity/agent-identity.js.map +1 -0
- package/dist/identity/erc6551.d.ts +441 -0
- package/dist/identity/erc6551.d.ts.map +1 -0
- package/dist/identity/erc6551.js +517 -0
- package/dist/identity/erc6551.js.map +1 -0
- package/dist/identity/erc8004.d.ts +305 -0
- package/dist/identity/erc8004.d.ts.map +1 -0
- package/dist/identity/erc8004.js +413 -0
- package/dist/identity/erc8004.js.map +1 -0
- package/dist/identity/index.d.ts +7 -0
- package/dist/identity/index.d.ts.map +1 -0
- package/dist/identity/index.js +4 -0
- package/dist/identity/index.js.map +1 -0
- package/dist/identity/reputation.d.ts +318 -0
- package/dist/identity/reputation.d.ts.map +1 -0
- package/dist/identity/reputation.js +272 -0
- package/dist/identity/reputation.js.map +1 -0
- package/dist/identity/validation.d.ts +284 -0
- package/dist/identity/validation.d.ts.map +1 -0
- package/dist/identity/validation.js +226 -0
- package/dist/identity/validation.js.map +1 -0
- package/dist/index.d.ts +38803 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +376 -0
- package/dist/index.js.map +1 -0
- package/dist/mev/index.d.ts +4 -0
- package/dist/mev/index.d.ts.map +1 -0
- package/dist/mev/index.js +8 -0
- package/dist/mev/index.js.map +1 -0
- package/dist/mev/protection.d.ts +54 -0
- package/dist/mev/protection.d.ts.map +1 -0
- package/dist/mev/protection.js +185 -0
- package/dist/mev/protection.js.map +1 -0
- package/dist/mev/risk.d.ts +19 -0
- package/dist/mev/risk.d.ts.map +1 -0
- package/dist/mev/risk.js +95 -0
- package/dist/mev/risk.js.map +1 -0
- package/dist/mev/types.d.ts +49 -0
- package/dist/mev/types.d.ts.map +1 -0
- package/dist/mev/types.js +2 -0
- package/dist/mev/types.js.map +1 -0
- package/dist/plugins/elizaos.d.ts +52 -0
- package/dist/plugins/elizaos.d.ts.map +1 -0
- package/dist/plugins/elizaos.js +89 -0
- package/dist/plugins/elizaos.js.map +1 -0
- package/dist/policy/SpendingPolicy.d.ts +106 -0
- package/dist/policy/SpendingPolicy.d.ts.map +1 -0
- package/dist/policy/SpendingPolicy.js +155 -0
- package/dist/policy/SpendingPolicy.js.map +1 -0
- package/dist/policy/SpendingPolicy.test.d.ts +2 -0
- package/dist/policy/SpendingPolicy.test.d.ts.map +1 -0
- package/dist/policy/SpendingPolicy.test.js +143 -0
- package/dist/policy/SpendingPolicy.test.js.map +1 -0
- package/dist/settlement/index.d.ts +4 -0
- package/dist/settlement/index.d.ts.map +1 -0
- package/dist/settlement/index.js +3 -0
- package/dist/settlement/index.js.map +1 -0
- package/dist/settlement/types.d.ts +66 -0
- package/dist/settlement/types.d.ts.map +1 -0
- package/dist/settlement/types.js +37 -0
- package/dist/settlement/types.js.map +1 -0
- package/dist/settlement/verifier.d.ts +75 -0
- package/dist/settlement/verifier.d.ts.map +1 -0
- package/dist/settlement/verifier.js +354 -0
- package/dist/settlement/verifier.js.map +1 -0
- package/dist/solana/bridge.d.ts +144 -0
- package/dist/solana/bridge.d.ts.map +1 -0
- package/dist/solana/bridge.js +352 -0
- package/dist/solana/bridge.js.map +1 -0
- package/dist/solana/index.d.ts +8 -0
- package/dist/solana/index.d.ts.map +1 -0
- package/dist/solana/index.js +6 -0
- package/dist/solana/index.js.map +1 -0
- package/dist/solana/swap.d.ts +85 -0
- package/dist/solana/swap.d.ts.map +1 -0
- package/dist/solana/swap.js +173 -0
- package/dist/solana/swap.js.map +1 -0
- package/dist/solana/types.d.ts +126 -0
- package/dist/solana/types.d.ts.map +1 -0
- package/dist/solana/types.js +10 -0
- package/dist/solana/types.js.map +1 -0
- package/dist/solana/wallet.d.ts +83 -0
- package/dist/solana/wallet.d.ts.map +1 -0
- package/dist/solana/wallet.js +164 -0
- package/dist/solana/wallet.js.map +1 -0
- package/dist/solana/x402.d.ts +69 -0
- package/dist/solana/x402.d.ts.map +1 -0
- package/dist/solana/x402.js +154 -0
- package/dist/solana/x402.js.map +1 -0
- package/dist/solver/adapter.d.ts +47 -0
- package/dist/solver/adapter.d.ts.map +1 -0
- package/dist/solver/adapter.js +146 -0
- package/dist/solver/adapter.js.map +1 -0
- package/dist/solver/analyzer.d.ts +48 -0
- package/dist/solver/analyzer.d.ts.map +1 -0
- package/dist/solver/analyzer.js +171 -0
- package/dist/solver/analyzer.js.map +1 -0
- package/dist/solver/builder.d.ts +31 -0
- package/dist/solver/builder.d.ts.map +1 -0
- package/dist/solver/builder.js +60 -0
- package/dist/solver/builder.js.map +1 -0
- package/dist/solver/index.d.ts +22 -0
- package/dist/solver/index.d.ts.map +1 -0
- package/dist/solver/index.js +25 -0
- package/dist/solver/index.js.map +1 -0
- package/dist/solver/types.d.ts +115 -0
- package/dist/solver/types.d.ts.map +1 -0
- package/dist/solver/types.js +10 -0
- package/dist/solver/types.js.map +1 -0
- package/dist/spend-guard/index.d.ts +125 -0
- package/dist/spend-guard/index.d.ts.map +1 -0
- package/dist/spend-guard/index.js +150 -0
- package/dist/spend-guard/index.js.map +1 -0
- package/dist/swap/SwapModule.d.ts +34 -0
- package/dist/swap/SwapModule.d.ts.map +1 -0
- package/dist/swap/SwapModule.js +144 -0
- package/dist/swap/SwapModule.js.map +1 -0
- package/dist/swap/abi.d.ts +51 -0
- package/dist/swap/abi.d.ts.map +1 -0
- package/dist/swap/abi.js +118 -0
- package/dist/swap/abi.js.map +1 -0
- package/dist/swap/index.d.ts +5 -0
- package/dist/swap/index.d.ts.map +1 -0
- package/dist/swap/index.js +4 -0
- package/dist/swap/index.js.map +1 -0
- package/dist/swap/router/cache.d.ts +13 -0
- package/dist/swap/router/cache.d.ts.map +1 -0
- package/dist/swap/router/cache.js +30 -0
- package/dist/swap/router/cache.js.map +1 -0
- package/dist/swap/router/flashbots.d.ts +10 -0
- package/dist/swap/router/flashbots.d.ts.map +1 -0
- package/dist/swap/router/flashbots.js +43 -0
- package/dist/swap/router/flashbots.js.map +1 -0
- package/dist/swap/router/health.d.ts +17 -0
- package/dist/swap/router/health.d.ts.map +1 -0
- package/dist/swap/router/health.js +38 -0
- package/dist/swap/router/health.js.map +1 -0
- package/dist/swap/router/index.d.ts +10 -0
- package/dist/swap/router/index.d.ts.map +1 -0
- package/dist/swap/router/index.js +10 -0
- package/dist/swap/router/index.js.map +1 -0
- package/dist/swap/router/providers/cowswap.d.ts +11 -0
- package/dist/swap/router/providers/cowswap.d.ts.map +1 -0
- package/dist/swap/router/providers/cowswap.js +79 -0
- package/dist/swap/router/providers/cowswap.js.map +1 -0
- package/dist/swap/router/providers/index.d.ts +20 -0
- package/dist/swap/router/providers/index.d.ts.map +1 -0
- package/dist/swap/router/providers/index.js +32 -0
- package/dist/swap/router/providers/index.js.map +1 -0
- package/dist/swap/router/providers/jupiter.d.ts +12 -0
- package/dist/swap/router/providers/jupiter.d.ts.map +1 -0
- package/dist/swap/router/providers/jupiter.js +73 -0
- package/dist/swap/router/providers/jupiter.js.map +1 -0
- package/dist/swap/router/providers/lifi.d.ts +11 -0
- package/dist/swap/router/providers/lifi.d.ts.map +1 -0
- package/dist/swap/router/providers/lifi.js +123 -0
- package/dist/swap/router/providers/lifi.js.map +1 -0
- package/dist/swap/router/providers/oneinch.d.ts +13 -0
- package/dist/swap/router/providers/oneinch.d.ts.map +1 -0
- package/dist/swap/router/providers/oneinch.js +71 -0
- package/dist/swap/router/providers/oneinch.js.map +1 -0
- package/dist/swap/router/providers/paraswap.d.ts +11 -0
- package/dist/swap/router/providers/paraswap.d.ts.map +1 -0
- package/dist/swap/router/providers/paraswap.js +73 -0
- package/dist/swap/router/providers/paraswap.js.map +1 -0
- package/dist/swap/router/providers/uniswap.d.ts +31 -0
- package/dist/swap/router/providers/uniswap.d.ts.map +1 -0
- package/dist/swap/router/providers/uniswap.js +237 -0
- package/dist/swap/router/providers/uniswap.js.map +1 -0
- package/dist/swap/router/providers/zerox.d.ts +13 -0
- package/dist/swap/router/providers/zerox.d.ts.map +1 -0
- package/dist/swap/router/providers/zerox.js +94 -0
- package/dist/swap/router/providers/zerox.js.map +1 -0
- package/dist/swap/router/router.d.ts +86 -0
- package/dist/swap/router/router.d.ts.map +1 -0
- package/dist/swap/router/router.js +224 -0
- package/dist/swap/router/router.js.map +1 -0
- package/dist/swap/router/rsi/engine.d.ts +60 -0
- package/dist/swap/router/rsi/engine.d.ts.map +1 -0
- package/dist/swap/router/rsi/engine.js +483 -0
- package/dist/swap/router/rsi/engine.js.map +1 -0
- package/dist/swap/router/rsi/index.d.ts +3 -0
- package/dist/swap/router/rsi/index.d.ts.map +1 -0
- package/dist/swap/router/rsi/index.js +3 -0
- package/dist/swap/router/rsi/index.js.map +1 -0
- package/dist/swap/router/rsi/types.d.ts +106 -0
- package/dist/swap/router/rsi/types.d.ts.map +1 -0
- package/dist/swap/router/rsi/types.js +3 -0
- package/dist/swap/router/rsi/types.js.map +1 -0
- package/dist/swap/router/types.d.ts +120 -0
- package/dist/swap/router/types.d.ts.map +1 -0
- package/dist/swap/router/types.js +16 -0
- package/dist/swap/router/types.js.map +1 -0
- package/dist/swap/types.d.ts +51 -0
- package/dist/swap/types.d.ts.map +1 -0
- package/dist/swap/types.js +17 -0
- package/dist/swap/types.js.map +1 -0
- package/dist/tax/engine.d.ts +131 -0
- package/dist/tax/engine.d.ts.map +1 -0
- package/dist/tax/engine.js +307 -0
- package/dist/tax/engine.js.map +1 -0
- package/dist/tax/index.d.ts +9 -0
- package/dist/tax/index.d.ts.map +1 -0
- package/dist/tax/index.js +12 -0
- package/dist/tax/index.js.map +1 -0
- package/dist/tax/lots.d.ts +60 -0
- package/dist/tax/lots.d.ts.map +1 -0
- package/dist/tax/lots.js +129 -0
- package/dist/tax/lots.js.map +1 -0
- package/dist/tax/types.d.ts +113 -0
- package/dist/tax/types.d.ts.map +1 -0
- package/dist/tax/types.js +18 -0
- package/dist/tax/types.js.map +1 -0
- package/dist/types.d.ts +110 -0
- package/dist/types.d.ts.map +1 -0
- package/dist/types.js +9 -0
- package/dist/types.js.map +1 -0
- package/dist/x402/__tests__/budget.test.d.ts +2 -0
- package/dist/x402/__tests__/budget.test.d.ts.map +1 -0
- package/dist/x402/__tests__/budget.test.js +114 -0
- package/dist/x402/__tests__/budget.test.js.map +1 -0
- package/dist/x402/__tests__/client.test.d.ts +2 -0
- package/dist/x402/__tests__/client.test.d.ts.map +1 -0
- package/dist/x402/__tests__/client.test.js +107 -0
- package/dist/x402/__tests__/client.test.js.map +1 -0
- package/dist/x402/budget.d.ts +52 -0
- package/dist/x402/budget.d.ts.map +1 -0
- package/dist/x402/budget.js +113 -0
- package/dist/x402/budget.js.map +1 -0
- package/dist/x402/chains/abstract/index.d.ts +135 -0
- package/dist/x402/chains/abstract/index.d.ts.map +1 -0
- package/dist/x402/chains/abstract/index.js +190 -0
- package/dist/x402/chains/abstract/index.js.map +1 -0
- package/dist/x402/client.d.ts +60 -0
- package/dist/x402/client.d.ts.map +1 -0
- package/dist/x402/client.js +205 -0
- package/dist/x402/client.js.map +1 -0
- package/dist/x402/index.d.ts +8 -0
- package/dist/x402/index.d.ts.map +1 -0
- package/dist/x402/index.js +8 -0
- package/dist/x402/index.js.map +1 -0
- package/dist/x402/middleware.d.ts +37 -0
- package/dist/x402/middleware.d.ts.map +1 -0
- package/dist/x402/middleware.js +65 -0
- package/dist/x402/middleware.js.map +1 -0
- package/dist/x402/types.d.ts +91 -0
- package/dist/x402/types.d.ts.map +1 -0
- package/dist/x402/types.js +9 -0
- package/dist/x402/types.js.map +1 -0
- package/dist/yield/index.d.ts +26 -0
- package/dist/yield/index.d.ts.map +1 -0
- package/dist/yield/index.js +29 -0
- package/dist/yield/index.js.map +1 -0
- package/dist/yield/rates.d.ts +114 -0
- package/dist/yield/rates.d.ts.map +1 -0
- package/dist/yield/rates.js +351 -0
- package/dist/yield/rates.js.map +1 -0
- package/dist/yield/types.d.ts +134 -0
- package/dist/yield/types.d.ts.map +1 -0
- package/dist/yield/types.js +24 -0
- package/dist/yield/types.js.map +1 -0
- package/dist/yield/vault.d.ts +112 -0
- package/dist/yield/vault.d.ts.map +1 -0
- package/dist/yield/vault.js +264 -0
- package/dist/yield/vault.js.map +1 -0
- package/package.json +46 -7
- package/index.js +0 -2
package/README.md
ADDED
|
@@ -0,0 +1,221 @@
|
|
|
1
|
+
# AgentWallet SDK
|
|
2
|
+
|
|
3
|
+
Non-custodial AI agent wallet with ERC-8004 on-chain identity, ERC-6551 token-bound accounts, x402 payments, mutual stake escrow, and programmable spending guardrails.
|
|
4
|
+
|
|
5
|
+
Agent Wallet gives AI agents autonomous spending power with hard on-chain limits. No more choosing between "agent can drain everything" and "every transaction needs manual approval."
|
|
6
|
+
|
|
7
|
+
> **ERC-8004 Ready:** Maps directly to [ERC-8004 (Trustless Agents)](https://eips.ethereum.org/EIPS/eip-8004) — your agent's ERC-6551 wallet NFT doubles as its on-chain identity handle, with built-in Identity Registry, Reputation Registry, and Validation Registry clients.
|
|
8
|
+
|
|
9
|
+
```
|
|
10
|
+
Agent wants to spend $15 → ✅ Auto-approved (under $25 limit)
|
|
11
|
+
Agent wants to spend $500 → ⏳ Queued for your approval
|
|
12
|
+
Agent spent $490 today → 🛑 Next tx queued ($500/day limit hit)
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Why Agent Wallet?
|
|
16
|
+
|
|
17
|
+
| Approach | Problem |
|
|
18
|
+
|----------|---------|
|
|
19
|
+
| Raw EOA wallet | Agent can drain everything. One prompt injection = rugged. |
|
|
20
|
+
| Multisig (Safe) | Every tx needs human sigs. Kills agent autonomy. |
|
|
21
|
+
| Custodial API (Stripe) | Centralized, KYC friction, not crypto-native. |
|
|
22
|
+
| **Agent Wallet** | **Agents spend freely within limits. Everything else queues for approval.** |
|
|
23
|
+
|
|
24
|
+
Built on **ERC-6551** (token-bound accounts). Your agent's wallet is tied to an NFT — portable, auditable, fully on-chain.
|
|
25
|
+
|
|
26
|
+
## Quick Start
|
|
27
|
+
|
|
28
|
+
```bash
|
|
29
|
+
npm install agentwallet-sdk viem
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
### Create a Wallet
|
|
33
|
+
|
|
34
|
+
```typescript
|
|
35
|
+
import { createWallet, setSpendPolicy, agentExecute, NATIVE_TOKEN } from 'agentwallet-sdk';
|
|
36
|
+
import { createWalletClient, http } from 'viem';
|
|
37
|
+
import { privateKeyToAccount } from 'viem/accounts';
|
|
38
|
+
import { base } from 'viem/chains';
|
|
39
|
+
|
|
40
|
+
const account = privateKeyToAccount('0x...');
|
|
41
|
+
const walletClient = createWalletClient({ account, chain: base, transport: http() });
|
|
42
|
+
|
|
43
|
+
const wallet = createWallet({
|
|
44
|
+
accountAddress: '0xYourAgentWallet',
|
|
45
|
+
chain: 'base',
|
|
46
|
+
walletClient,
|
|
47
|
+
});
|
|
48
|
+
|
|
49
|
+
// Set a $25/tx, $500/day spend policy for ETH
|
|
50
|
+
await setSpendPolicy(wallet, {
|
|
51
|
+
token: NATIVE_TOKEN,
|
|
52
|
+
perTxLimit: 25000000000000000n, // 0.025 ETH
|
|
53
|
+
periodLimit: 500000000000000000n, // 0.5 ETH
|
|
54
|
+
periodLength: 86400,
|
|
55
|
+
});
|
|
56
|
+
|
|
57
|
+
// Agent executes — auto-approved if within limits, queued if over
|
|
58
|
+
const result = await agentExecute(wallet, {
|
|
59
|
+
to: '0xRecipient',
|
|
60
|
+
value: 10000000000000000n, // 0.01 ETH
|
|
61
|
+
});
|
|
62
|
+
console.log(result.executed ? 'Sent!' : 'Queued for approval');
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
## ERC-8004 On-Chain Identity
|
|
66
|
+
|
|
67
|
+
Register your agent on the ERC-8004 Identity Registry — a portable, censorship-resistant on-chain identity using ERC-721.
|
|
68
|
+
|
|
69
|
+
```typescript
|
|
70
|
+
import { ERC8004Client } from 'agentwallet-sdk';
|
|
71
|
+
|
|
72
|
+
const identity = new ERC8004Client({ chain: 'base' });
|
|
73
|
+
|
|
74
|
+
// Register agent
|
|
75
|
+
const { txHash, agentId } = await identity.registerAgent(walletClient, {
|
|
76
|
+
name: 'MyAgent',
|
|
77
|
+
description: 'Autonomous trading agent',
|
|
78
|
+
});
|
|
79
|
+
|
|
80
|
+
// Look up any agent
|
|
81
|
+
const agent = await identity.lookupAgentIdentity(agentId!);
|
|
82
|
+
console.log(agent.owner, agent.agentURI);
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
## ERC-8004 Reputation Registry
|
|
86
|
+
|
|
87
|
+
On-chain reputation signals — scored feedback from clients, aggregated summaries, revocable.
|
|
88
|
+
|
|
89
|
+
```typescript
|
|
90
|
+
import { ReputationClient } from 'agentwallet-sdk';
|
|
91
|
+
|
|
92
|
+
const reputation = new ReputationClient({ chain: 'base' });
|
|
93
|
+
|
|
94
|
+
// Leave feedback for an agent
|
|
95
|
+
await reputation.giveFeedback(walletClient, {
|
|
96
|
+
agentId: 42n,
|
|
97
|
+
score: 95n,
|
|
98
|
+
category: 1,
|
|
99
|
+
comment: 'Fast execution, accurate results',
|
|
100
|
+
taskRef: 'task-abc-123',
|
|
101
|
+
verifierRef: '',
|
|
102
|
+
clientRef: '',
|
|
103
|
+
contentHash: '0x0000000000000000000000000000000000000000000000000000000000000000',
|
|
104
|
+
});
|
|
105
|
+
|
|
106
|
+
// Read aggregated reputation
|
|
107
|
+
const rep = await reputation.getAgentReputation(42n);
|
|
108
|
+
console.log(`Score: ${rep.totalScore} from ${rep.count} reviews`);
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
## ERC-8004 Validation Registry
|
|
112
|
+
|
|
113
|
+
Request and receive on-chain validation from validator contracts (TEE attestations, capability proofs, compliance checks).
|
|
114
|
+
|
|
115
|
+
```typescript
|
|
116
|
+
import { ValidationClient } from 'agentwallet-sdk';
|
|
117
|
+
import { keccak256, toBytes } from 'viem';
|
|
118
|
+
|
|
119
|
+
const validation = new ValidationClient({
|
|
120
|
+
chain: 'base',
|
|
121
|
+
validationAddress: '0xYourValidationRegistry', // address required until official deployment
|
|
122
|
+
});
|
|
123
|
+
|
|
124
|
+
// Request validation from a validator
|
|
125
|
+
const requestHash = keccak256(toBytes('my-validation-request-v1'));
|
|
126
|
+
await validation.requestValidation(walletClient, {
|
|
127
|
+
validator: '0xValidatorContract',
|
|
128
|
+
agentId: 42n,
|
|
129
|
+
requestURI: 'https://example.com/validation-spec.json',
|
|
130
|
+
requestHash,
|
|
131
|
+
});
|
|
132
|
+
|
|
133
|
+
// Check validation status
|
|
134
|
+
const status = await validation.getValidationStatus(requestHash);
|
|
135
|
+
console.log(status.responded ? `Result: ${status.response}` : 'Pending');
|
|
136
|
+
|
|
137
|
+
// Get summary for an agent
|
|
138
|
+
const summary = await validation.getSummary(42n);
|
|
139
|
+
console.log(`${summary.passCount} passed, ${summary.failCount} failed`);
|
|
140
|
+
```
|
|
141
|
+
|
|
142
|
+
## Mutual Stake Escrow
|
|
143
|
+
|
|
144
|
+
Reciprocal collateral for agent-to-agent task settlement. Both parties stake, both lose if the task fails.
|
|
145
|
+
|
|
146
|
+
```typescript
|
|
147
|
+
import { MutualStakeEscrow } from 'agentwallet-sdk';
|
|
148
|
+
|
|
149
|
+
const escrow = new MutualStakeEscrow({
|
|
150
|
+
chain: 'base',
|
|
151
|
+
walletClient,
|
|
152
|
+
});
|
|
153
|
+
|
|
154
|
+
// Create escrow — both agent and client stake
|
|
155
|
+
const { escrowId, txHash } = await escrow.create({
|
|
156
|
+
counterparty: '0xOtherAgent',
|
|
157
|
+
token: '0xUSDC',
|
|
158
|
+
stakeAmount: 100000000n, // 100 USDC
|
|
159
|
+
taskHash: '0x...',
|
|
160
|
+
deadline: BigInt(Math.floor(Date.now() / 1000) + 86400),
|
|
161
|
+
});
|
|
162
|
+
|
|
163
|
+
// Counterparty funds their side
|
|
164
|
+
await escrow.fund(escrowId);
|
|
165
|
+
|
|
166
|
+
// After task completion, fulfill
|
|
167
|
+
await escrow.fulfill(escrowId, proofHash);
|
|
168
|
+
|
|
169
|
+
// Verify and release stakes
|
|
170
|
+
await escrow.verify(escrowId);
|
|
171
|
+
```
|
|
172
|
+
|
|
173
|
+
## Feature Tiers
|
|
174
|
+
|
|
175
|
+
### Base (Free)
|
|
176
|
+
|
|
177
|
+
| Feature | Description |
|
|
178
|
+
|---------|-------------|
|
|
179
|
+
| Agent Identity | ERC-8004 Identity Registry — on-chain ERC-721 agent IDs |
|
|
180
|
+
| Agent Reputation | ERC-8004 Reputation Registry — scored feedback and summaries |
|
|
181
|
+
| Agent Validation | ERC-8004 Validation Registry — validator request/response |
|
|
182
|
+
| ERC-6551 TBA | NFT-bound wallets with autonomous spending |
|
|
183
|
+
| Mutual Stake Escrow | Reciprocal collateral task settlement |
|
|
184
|
+
| Optimistic Escrow | Time-locked optimistic verification |
|
|
185
|
+
| x402 Payments | HTTP 402 auto-pay for agent-to-service payments |
|
|
186
|
+
| CCTP Bridge | Circle CCTP V2 across 17 chains + Solana |
|
|
187
|
+
| Spend Policies | Per-token, per-period on-chain spending limits |
|
|
188
|
+
| Swap | Uniswap V3 on Base/Arbitrum/Optimism |
|
|
189
|
+
| Fiat Onramp | Opt-in fiat-to-crypto |
|
|
190
|
+
| AP2 Protocol | Agent-to-Agent task delegation and payment |
|
|
191
|
+
| Settlement | On-chain settlement finalization |
|
|
192
|
+
| Gas Sponsorship | ERC-4337 paymaster-based gas sponsorship |
|
|
193
|
+
| Solana Support | Cross-chain Solana bridging via CCTP |
|
|
194
|
+
|
|
195
|
+
### Premium
|
|
196
|
+
|
|
197
|
+
| Feature | Description |
|
|
198
|
+
|---------|-------------|
|
|
199
|
+
| CowSwap Solver | Batch auction solutions, earn COW tokens |
|
|
200
|
+
| Flash Executor | Atomic flash loan execution |
|
|
201
|
+
| MEV Protection | Private mempool via Flashbots/MEV Blocker |
|
|
202
|
+
| Yield Staking | Aave V3, Compound V3, Morpho Blue strategies |
|
|
203
|
+
| Tax Reporting | Cost basis and gain/loss reporting |
|
|
204
|
+
|
|
205
|
+
Premium access: [github.com/up2itnow/AgentNexus2](https://github.com/up2itnow/AgentNexus2)
|
|
206
|
+
|
|
207
|
+
## Supported Chains
|
|
208
|
+
|
|
209
|
+
Mainnet: Ethereum, Base, Arbitrum, Polygon, Optimism, Avalanche, BSC, Celo, Gnosis, Linea, Mantle, Scroll, and more.
|
|
210
|
+
|
|
211
|
+
Testnet: Base Sepolia, Arbitrum Sepolia, and corresponding testnets.
|
|
212
|
+
|
|
213
|
+
## Links
|
|
214
|
+
|
|
215
|
+
- [ERC-8004 Spec](https://eips.ethereum.org/EIPS/eip-8004)
|
|
216
|
+
- [GitHub](https://github.com/agentnexus/agent-wallet-sdk)
|
|
217
|
+
- [npm](https://www.npmjs.com/package/agentwallet-sdk)
|
|
218
|
+
|
|
219
|
+
## License
|
|
220
|
+
|
|
221
|
+
MIT
|
package/dist/abi.d.ts
ADDED
|
@@ -0,0 +1,397 @@
|
|
|
1
|
+
export declare const AgentAccountV2Abi: readonly [{
|
|
2
|
+
readonly name: "setSpendPolicy";
|
|
3
|
+
readonly type: "function";
|
|
4
|
+
readonly stateMutability: "nonpayable";
|
|
5
|
+
readonly inputs: readonly [{
|
|
6
|
+
readonly name: "token";
|
|
7
|
+
readonly type: "address";
|
|
8
|
+
}, {
|
|
9
|
+
readonly name: "perTxLimit";
|
|
10
|
+
readonly type: "uint256";
|
|
11
|
+
}, {
|
|
12
|
+
readonly name: "periodLimit";
|
|
13
|
+
readonly type: "uint256";
|
|
14
|
+
}, {
|
|
15
|
+
readonly name: "periodLength";
|
|
16
|
+
readonly type: "uint256";
|
|
17
|
+
}];
|
|
18
|
+
readonly outputs: readonly [];
|
|
19
|
+
}, {
|
|
20
|
+
readonly name: "setOperator";
|
|
21
|
+
readonly type: "function";
|
|
22
|
+
readonly stateMutability: "nonpayable";
|
|
23
|
+
readonly inputs: readonly [{
|
|
24
|
+
readonly name: "operator";
|
|
25
|
+
readonly type: "address";
|
|
26
|
+
}, {
|
|
27
|
+
readonly name: "authorized";
|
|
28
|
+
readonly type: "bool";
|
|
29
|
+
}];
|
|
30
|
+
readonly outputs: readonly [];
|
|
31
|
+
}, {
|
|
32
|
+
readonly name: "execute";
|
|
33
|
+
readonly type: "function";
|
|
34
|
+
readonly stateMutability: "payable";
|
|
35
|
+
readonly inputs: readonly [{
|
|
36
|
+
readonly name: "to";
|
|
37
|
+
readonly type: "address";
|
|
38
|
+
}, {
|
|
39
|
+
readonly name: "value";
|
|
40
|
+
readonly type: "uint256";
|
|
41
|
+
}, {
|
|
42
|
+
readonly name: "data";
|
|
43
|
+
readonly type: "bytes";
|
|
44
|
+
}];
|
|
45
|
+
readonly outputs: readonly [{
|
|
46
|
+
readonly name: "";
|
|
47
|
+
readonly type: "bytes";
|
|
48
|
+
}];
|
|
49
|
+
}, {
|
|
50
|
+
readonly name: "approvePending";
|
|
51
|
+
readonly type: "function";
|
|
52
|
+
readonly stateMutability: "nonpayable";
|
|
53
|
+
readonly inputs: readonly [{
|
|
54
|
+
readonly name: "txId";
|
|
55
|
+
readonly type: "uint256";
|
|
56
|
+
}];
|
|
57
|
+
readonly outputs: readonly [];
|
|
58
|
+
}, {
|
|
59
|
+
readonly name: "cancelPending";
|
|
60
|
+
readonly type: "function";
|
|
61
|
+
readonly stateMutability: "nonpayable";
|
|
62
|
+
readonly inputs: readonly [{
|
|
63
|
+
readonly name: "txId";
|
|
64
|
+
readonly type: "uint256";
|
|
65
|
+
}];
|
|
66
|
+
readonly outputs: readonly [];
|
|
67
|
+
}, {
|
|
68
|
+
readonly name: "agentExecute";
|
|
69
|
+
readonly type: "function";
|
|
70
|
+
readonly stateMutability: "payable";
|
|
71
|
+
readonly inputs: readonly [{
|
|
72
|
+
readonly name: "to";
|
|
73
|
+
readonly type: "address";
|
|
74
|
+
}, {
|
|
75
|
+
readonly name: "value";
|
|
76
|
+
readonly type: "uint256";
|
|
77
|
+
}, {
|
|
78
|
+
readonly name: "data";
|
|
79
|
+
readonly type: "bytes";
|
|
80
|
+
}];
|
|
81
|
+
readonly outputs: readonly [{
|
|
82
|
+
readonly name: "";
|
|
83
|
+
readonly type: "bytes";
|
|
84
|
+
}];
|
|
85
|
+
}, {
|
|
86
|
+
readonly name: "agentTransferToken";
|
|
87
|
+
readonly type: "function";
|
|
88
|
+
readonly stateMutability: "nonpayable";
|
|
89
|
+
readonly inputs: readonly [{
|
|
90
|
+
readonly name: "token";
|
|
91
|
+
readonly type: "address";
|
|
92
|
+
}, {
|
|
93
|
+
readonly name: "to";
|
|
94
|
+
readonly type: "address";
|
|
95
|
+
}, {
|
|
96
|
+
readonly name: "amount";
|
|
97
|
+
readonly type: "uint256";
|
|
98
|
+
}];
|
|
99
|
+
readonly outputs: readonly [];
|
|
100
|
+
}, {
|
|
101
|
+
readonly name: "remainingBudget";
|
|
102
|
+
readonly type: "function";
|
|
103
|
+
readonly stateMutability: "view";
|
|
104
|
+
readonly inputs: readonly [{
|
|
105
|
+
readonly name: "token";
|
|
106
|
+
readonly type: "address";
|
|
107
|
+
}];
|
|
108
|
+
readonly outputs: readonly [{
|
|
109
|
+
readonly name: "perTx";
|
|
110
|
+
readonly type: "uint256";
|
|
111
|
+
}, {
|
|
112
|
+
readonly name: "inPeriod";
|
|
113
|
+
readonly type: "uint256";
|
|
114
|
+
}];
|
|
115
|
+
}, {
|
|
116
|
+
readonly name: "getPending";
|
|
117
|
+
readonly type: "function";
|
|
118
|
+
readonly stateMutability: "view";
|
|
119
|
+
readonly inputs: readonly [{
|
|
120
|
+
readonly name: "txId";
|
|
121
|
+
readonly type: "uint256";
|
|
122
|
+
}];
|
|
123
|
+
readonly outputs: readonly [{
|
|
124
|
+
readonly name: "to";
|
|
125
|
+
readonly type: "address";
|
|
126
|
+
}, {
|
|
127
|
+
readonly name: "value";
|
|
128
|
+
readonly type: "uint256";
|
|
129
|
+
}, {
|
|
130
|
+
readonly name: "token";
|
|
131
|
+
readonly type: "address";
|
|
132
|
+
}, {
|
|
133
|
+
readonly name: "amount";
|
|
134
|
+
readonly type: "uint256";
|
|
135
|
+
}, {
|
|
136
|
+
readonly name: "createdAt";
|
|
137
|
+
readonly type: "uint256";
|
|
138
|
+
}, {
|
|
139
|
+
readonly name: "executed";
|
|
140
|
+
readonly type: "bool";
|
|
141
|
+
}, {
|
|
142
|
+
readonly name: "cancelled";
|
|
143
|
+
readonly type: "bool";
|
|
144
|
+
}];
|
|
145
|
+
}, {
|
|
146
|
+
readonly name: "spendPolicies";
|
|
147
|
+
readonly type: "function";
|
|
148
|
+
readonly stateMutability: "view";
|
|
149
|
+
readonly inputs: readonly [{
|
|
150
|
+
readonly name: "token";
|
|
151
|
+
readonly type: "address";
|
|
152
|
+
}];
|
|
153
|
+
readonly outputs: readonly [{
|
|
154
|
+
readonly name: "perTxLimit";
|
|
155
|
+
readonly type: "uint256";
|
|
156
|
+
}, {
|
|
157
|
+
readonly name: "periodLimit";
|
|
158
|
+
readonly type: "uint256";
|
|
159
|
+
}, {
|
|
160
|
+
readonly name: "periodLength";
|
|
161
|
+
readonly type: "uint256";
|
|
162
|
+
}, {
|
|
163
|
+
readonly name: "periodSpent";
|
|
164
|
+
readonly type: "uint256";
|
|
165
|
+
}, {
|
|
166
|
+
readonly name: "periodStart";
|
|
167
|
+
readonly type: "uint256";
|
|
168
|
+
}];
|
|
169
|
+
}, {
|
|
170
|
+
readonly name: "operators";
|
|
171
|
+
readonly type: "function";
|
|
172
|
+
readonly stateMutability: "view";
|
|
173
|
+
readonly inputs: readonly [{
|
|
174
|
+
readonly name: "operator";
|
|
175
|
+
readonly type: "address";
|
|
176
|
+
}];
|
|
177
|
+
readonly outputs: readonly [{
|
|
178
|
+
readonly name: "";
|
|
179
|
+
readonly type: "bool";
|
|
180
|
+
}];
|
|
181
|
+
}, {
|
|
182
|
+
readonly name: "pendingNonce";
|
|
183
|
+
readonly type: "function";
|
|
184
|
+
readonly stateMutability: "view";
|
|
185
|
+
readonly inputs: readonly [];
|
|
186
|
+
readonly outputs: readonly [{
|
|
187
|
+
readonly name: "";
|
|
188
|
+
readonly type: "uint256";
|
|
189
|
+
}];
|
|
190
|
+
}, {
|
|
191
|
+
readonly name: "nonce";
|
|
192
|
+
readonly type: "function";
|
|
193
|
+
readonly stateMutability: "view";
|
|
194
|
+
readonly inputs: readonly [];
|
|
195
|
+
readonly outputs: readonly [{
|
|
196
|
+
readonly name: "";
|
|
197
|
+
readonly type: "uint256";
|
|
198
|
+
}];
|
|
199
|
+
}, {
|
|
200
|
+
readonly name: "tokenContract";
|
|
201
|
+
readonly type: "function";
|
|
202
|
+
readonly stateMutability: "view";
|
|
203
|
+
readonly inputs: readonly [];
|
|
204
|
+
readonly outputs: readonly [{
|
|
205
|
+
readonly name: "";
|
|
206
|
+
readonly type: "address";
|
|
207
|
+
}];
|
|
208
|
+
}, {
|
|
209
|
+
readonly name: "tokenId";
|
|
210
|
+
readonly type: "function";
|
|
211
|
+
readonly stateMutability: "view";
|
|
212
|
+
readonly inputs: readonly [];
|
|
213
|
+
readonly outputs: readonly [{
|
|
214
|
+
readonly name: "";
|
|
215
|
+
readonly type: "uint256";
|
|
216
|
+
}];
|
|
217
|
+
}, {
|
|
218
|
+
readonly name: "operatorEpoch";
|
|
219
|
+
readonly type: "function";
|
|
220
|
+
readonly stateMutability: "view";
|
|
221
|
+
readonly inputs: readonly [];
|
|
222
|
+
readonly outputs: readonly [{
|
|
223
|
+
readonly name: "";
|
|
224
|
+
readonly type: "uint256";
|
|
225
|
+
}];
|
|
226
|
+
}, {
|
|
227
|
+
readonly name: "isOperatorActive";
|
|
228
|
+
readonly type: "function";
|
|
229
|
+
readonly stateMutability: "view";
|
|
230
|
+
readonly inputs: readonly [{
|
|
231
|
+
readonly name: "operator";
|
|
232
|
+
readonly type: "address";
|
|
233
|
+
}];
|
|
234
|
+
readonly outputs: readonly [{
|
|
235
|
+
readonly name: "";
|
|
236
|
+
readonly type: "bool";
|
|
237
|
+
}];
|
|
238
|
+
}, {
|
|
239
|
+
readonly name: "TransactionExecuted";
|
|
240
|
+
readonly type: "event";
|
|
241
|
+
readonly inputs: readonly [{
|
|
242
|
+
readonly name: "target";
|
|
243
|
+
readonly type: "address";
|
|
244
|
+
readonly indexed: true;
|
|
245
|
+
}, {
|
|
246
|
+
readonly name: "value";
|
|
247
|
+
readonly type: "uint256";
|
|
248
|
+
readonly indexed: false;
|
|
249
|
+
}, {
|
|
250
|
+
readonly name: "data";
|
|
251
|
+
readonly type: "bytes";
|
|
252
|
+
readonly indexed: false;
|
|
253
|
+
}, {
|
|
254
|
+
readonly name: "executor";
|
|
255
|
+
readonly type: "address";
|
|
256
|
+
readonly indexed: true;
|
|
257
|
+
}];
|
|
258
|
+
}, {
|
|
259
|
+
readonly name: "SpendPolicyUpdated";
|
|
260
|
+
readonly type: "event";
|
|
261
|
+
readonly inputs: readonly [{
|
|
262
|
+
readonly name: "token";
|
|
263
|
+
readonly type: "address";
|
|
264
|
+
readonly indexed: true;
|
|
265
|
+
}, {
|
|
266
|
+
readonly name: "perTxLimit";
|
|
267
|
+
readonly type: "uint256";
|
|
268
|
+
readonly indexed: false;
|
|
269
|
+
}, {
|
|
270
|
+
readonly name: "periodLimit";
|
|
271
|
+
readonly type: "uint256";
|
|
272
|
+
readonly indexed: false;
|
|
273
|
+
}, {
|
|
274
|
+
readonly name: "periodLength";
|
|
275
|
+
readonly type: "uint256";
|
|
276
|
+
readonly indexed: false;
|
|
277
|
+
}];
|
|
278
|
+
}, {
|
|
279
|
+
readonly name: "OperatorUpdated";
|
|
280
|
+
readonly type: "event";
|
|
281
|
+
readonly inputs: readonly [{
|
|
282
|
+
readonly name: "operator";
|
|
283
|
+
readonly type: "address";
|
|
284
|
+
readonly indexed: true;
|
|
285
|
+
}, {
|
|
286
|
+
readonly name: "authorized";
|
|
287
|
+
readonly type: "bool";
|
|
288
|
+
readonly indexed: false;
|
|
289
|
+
}];
|
|
290
|
+
}, {
|
|
291
|
+
readonly name: "TransactionQueued";
|
|
292
|
+
readonly type: "event";
|
|
293
|
+
readonly inputs: readonly [{
|
|
294
|
+
readonly name: "txId";
|
|
295
|
+
readonly type: "uint256";
|
|
296
|
+
readonly indexed: true;
|
|
297
|
+
}, {
|
|
298
|
+
readonly name: "to";
|
|
299
|
+
readonly type: "address";
|
|
300
|
+
readonly indexed: true;
|
|
301
|
+
}, {
|
|
302
|
+
readonly name: "value";
|
|
303
|
+
readonly type: "uint256";
|
|
304
|
+
readonly indexed: false;
|
|
305
|
+
}, {
|
|
306
|
+
readonly name: "token";
|
|
307
|
+
readonly type: "address";
|
|
308
|
+
readonly indexed: false;
|
|
309
|
+
}, {
|
|
310
|
+
readonly name: "amount";
|
|
311
|
+
readonly type: "uint256";
|
|
312
|
+
readonly indexed: false;
|
|
313
|
+
}];
|
|
314
|
+
}, {
|
|
315
|
+
readonly name: "TransactionApproved";
|
|
316
|
+
readonly type: "event";
|
|
317
|
+
readonly inputs: readonly [{
|
|
318
|
+
readonly name: "txId";
|
|
319
|
+
readonly type: "uint256";
|
|
320
|
+
readonly indexed: true;
|
|
321
|
+
}];
|
|
322
|
+
}, {
|
|
323
|
+
readonly name: "TransactionCancelled";
|
|
324
|
+
readonly type: "event";
|
|
325
|
+
readonly inputs: readonly [{
|
|
326
|
+
readonly name: "txId";
|
|
327
|
+
readonly type: "uint256";
|
|
328
|
+
readonly indexed: true;
|
|
329
|
+
}];
|
|
330
|
+
}];
|
|
331
|
+
export declare const AgentAccountFactoryV2Abi: readonly [{
|
|
332
|
+
readonly name: "createAccount";
|
|
333
|
+
readonly type: "function";
|
|
334
|
+
readonly stateMutability: "nonpayable";
|
|
335
|
+
readonly inputs: readonly [{
|
|
336
|
+
readonly name: "tokenContract";
|
|
337
|
+
readonly type: "address";
|
|
338
|
+
}, {
|
|
339
|
+
readonly name: "tokenId";
|
|
340
|
+
readonly type: "uint256";
|
|
341
|
+
}];
|
|
342
|
+
readonly outputs: readonly [{
|
|
343
|
+
readonly name: "wallet";
|
|
344
|
+
readonly type: "address";
|
|
345
|
+
}];
|
|
346
|
+
}, {
|
|
347
|
+
readonly name: "getAddress";
|
|
348
|
+
readonly type: "function";
|
|
349
|
+
readonly stateMutability: "view";
|
|
350
|
+
readonly inputs: readonly [{
|
|
351
|
+
readonly name: "tokenContract";
|
|
352
|
+
readonly type: "address";
|
|
353
|
+
}, {
|
|
354
|
+
readonly name: "tokenId";
|
|
355
|
+
readonly type: "uint256";
|
|
356
|
+
}];
|
|
357
|
+
readonly outputs: readonly [{
|
|
358
|
+
readonly name: "";
|
|
359
|
+
readonly type: "address";
|
|
360
|
+
}];
|
|
361
|
+
}, {
|
|
362
|
+
readonly name: "wallets";
|
|
363
|
+
readonly type: "function";
|
|
364
|
+
readonly stateMutability: "view";
|
|
365
|
+
readonly inputs: readonly [{
|
|
366
|
+
readonly name: "tokenContract";
|
|
367
|
+
readonly type: "address";
|
|
368
|
+
}, {
|
|
369
|
+
readonly name: "tokenId";
|
|
370
|
+
readonly type: "uint256";
|
|
371
|
+
}];
|
|
372
|
+
readonly outputs: readonly [{
|
|
373
|
+
readonly name: "";
|
|
374
|
+
readonly type: "address";
|
|
375
|
+
}];
|
|
376
|
+
}, {
|
|
377
|
+
readonly name: "WalletCreated";
|
|
378
|
+
readonly type: "event";
|
|
379
|
+
readonly inputs: readonly [{
|
|
380
|
+
readonly name: "wallet";
|
|
381
|
+
readonly type: "address";
|
|
382
|
+
readonly indexed: true;
|
|
383
|
+
}, {
|
|
384
|
+
readonly name: "tokenContract";
|
|
385
|
+
readonly type: "address";
|
|
386
|
+
readonly indexed: true;
|
|
387
|
+
}, {
|
|
388
|
+
readonly name: "tokenId";
|
|
389
|
+
readonly type: "uint256";
|
|
390
|
+
readonly indexed: true;
|
|
391
|
+
}, {
|
|
392
|
+
readonly name: "deployer";
|
|
393
|
+
readonly type: "address";
|
|
394
|
+
readonly indexed: false;
|
|
395
|
+
}];
|
|
396
|
+
}];
|
|
397
|
+
//# sourceMappingURL=abi.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"abi.d.ts","sourceRoot":"","sources":["../src/abi.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAsNpB,CAAC;AAEX,eAAO,MAAM,wBAAwB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAyC3B,CAAC"}
|