@agenticprimitives/agent-account 0.1.0-alpha.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/LICENSE +21 -0
- package/README.md +122 -0
- package/dist/abis.d.ts +543 -0
- package/dist/abis.d.ts.map +1 -0
- package/dist/abis.js +261 -0
- package/dist/abis.js.map +1 -0
- package/dist/bundler-client.d.ts +62 -0
- package/dist/bundler-client.d.ts.map +1 -0
- package/dist/bundler-client.js +95 -0
- package/dist/bundler-client.js.map +1 -0
- package/dist/client.d.ts +224 -0
- package/dist/client.d.ts.map +1 -0
- package/dist/client.js +473 -0
- package/dist/client.js.map +1 -0
- package/dist/execute.d.ts +39 -0
- package/dist/execute.d.ts.map +1 -0
- package/dist/execute.js +72 -0
- package/dist/execute.js.map +1 -0
- package/dist/index.d.ts +11 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +17 -0
- package/dist/index.js.map +1 -0
- package/dist/quorum.d.ts +62 -0
- package/dist/quorum.d.ts.map +1 -0
- package/dist/quorum.js +103 -0
- package/dist/quorum.js.map +1 -0
- package/dist/types.d.ts +16 -0
- package/dist/types.d.ts.map +1 -0
- package/dist/types.js +2 -0
- package/dist/types.js.map +1 -0
- package/dist/webauthn-signature.d.ts +34 -0
- package/dist/webauthn-signature.d.ts.map +1 -0
- package/dist/webauthn-signature.js +51 -0
- package/dist/webauthn-signature.js.map +1 -0
- package/package.json +57 -0
- package/spec.md +6 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Agentic Trust Labs
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
# @agenticprimitives/agent-account
|
|
2
|
+
|
|
3
|
+
ERC-4337 Smart Agent substrate — **canonical identity owner**.
|
|
4
|
+
|
|
5
|
+
Every person, org, service, or treasury agent is anchored by its Smart Agent
|
|
6
|
+
address (`0x…` / CAIP-10 `eip155:<chainId>:<address>`). This package deploys
|
|
7
|
+
that account, derives its address, builds UserOps, and verifies ERC-1271
|
|
8
|
+
signatures. Names, profiles, and passkeys are **facets** handled by sibling
|
|
9
|
+
packages.
|
|
10
|
+
|
|
11
|
+
> **Layer:** Core — the canonical identity **anchor**.
|
|
12
|
+
> **Canonical key:** Smart Agent address (CAIP-10 `eip155:<chainId>:<address>`). Names / profiles / edges point AT it; they never *are* the identity.
|
|
13
|
+
|
|
14
|
+
## Use This When
|
|
15
|
+
|
|
16
|
+
- You need counterfactual or deployed Smart Agent addresses (CREATE2 factory).
|
|
17
|
+
- You need `createAccount`, `isDeployed`, `buildUserOp`, or ERC-1271 verify paths.
|
|
18
|
+
- You need bundler helpers (`BundlerClient`, packed UserOp gas fields).
|
|
19
|
+
- You need quorum / admin payload hashing for custody-gated account actions.
|
|
20
|
+
|
|
21
|
+
## Do Not Use This For
|
|
22
|
+
|
|
23
|
+
- Passkey ceremonies, SIWE, OAuth, or JWT sessions → `connect-auth`.
|
|
24
|
+
- `.agent` name registration or resolution → `agent-naming`.
|
|
25
|
+
- AgentCard profiles or endpoint verification → `agent-profile`.
|
|
26
|
+
- Custodian enrollment, credential recovery, or quorum scheduling → `account-custody`.
|
|
27
|
+
- Delegation tokens or session authority → `delegation`.
|
|
28
|
+
|
|
29
|
+
## Install
|
|
30
|
+
|
|
31
|
+
Workspace-internal; not yet published.
|
|
32
|
+
|
|
33
|
+
```bash
|
|
34
|
+
pnpm add @agenticprimitives/agent-account
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
## 60-Second Quickstart
|
|
38
|
+
|
|
39
|
+
```ts
|
|
40
|
+
import { AgentAccountClient } from '@agenticprimitives/agent-account';
|
|
41
|
+
import { deriveSaltFromEmail } from '@agenticprimitives/connect-auth';
|
|
42
|
+
import type { Signer } from '@agenticprimitives/connect-auth';
|
|
43
|
+
|
|
44
|
+
const account = new AgentAccountClient({
|
|
45
|
+
rpcUrl: process.env.RPC_URL!,
|
|
46
|
+
chainId: 84532,
|
|
47
|
+
entryPoint: process.env.ENTRYPOINT_ADDRESS as `0x${string}`,
|
|
48
|
+
factory: process.env.AGENT_FACTORY_ADDRESS as `0x${string}`,
|
|
49
|
+
});
|
|
50
|
+
|
|
51
|
+
// Salt from auth scope — NOT from a .agent name (ADR-0010).
|
|
52
|
+
const salt = deriveSaltFromEmail(user.email, 0);
|
|
53
|
+
const address = await account.getAddress(bootstrapSigner.address, salt);
|
|
54
|
+
|
|
55
|
+
if (!(await account.isDeployed(address))) {
|
|
56
|
+
await account.createAccount(
|
|
57
|
+
{ owner: bootstrapSigner.address, salt },
|
|
58
|
+
bootstrapSigner as Signer,
|
|
59
|
+
);
|
|
60
|
+
}
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
## Main Concepts
|
|
64
|
+
|
|
65
|
+
- **Smart Agent address**: the canonical identifier; stable across credential
|
|
66
|
+
rotation ([ADR-0011](../../docs/architecture/decisions/0011-credential-recovery-and-re-association.md)).
|
|
67
|
+
- **CREATE2 salt**: from auth methods + user scope only — never from `.agent`
|
|
68
|
+
names ([spec 220](../../specs/220-agent-identity-bootstrap.md)).
|
|
69
|
+
- **Signer**: pluggable interface from `connect-auth`; this package consumes it.
|
|
70
|
+
- **UserOperation**: ERC-4337 v0.8 UserOp build path via `buildUserOp`.
|
|
71
|
+
|
|
72
|
+
See [`docs/concepts.md`](docs/concepts.md).
|
|
73
|
+
|
|
74
|
+
## Common Recipes
|
|
75
|
+
|
|
76
|
+
```ts
|
|
77
|
+
import { buildExecuteCallData, type ContractCall } from '@agenticprimitives/agent-account';
|
|
78
|
+
|
|
79
|
+
const calls: ContractCall[] = [
|
|
80
|
+
{ to: target, value: 0n, data: calldata },
|
|
81
|
+
];
|
|
82
|
+
const executeData = buildExecuteCallData(calls);
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
```ts
|
|
86
|
+
import { encodeWebAuthnSignature, SIG_TYPE_WEBAUTHN } from '@agenticprimitives/agent-account';
|
|
87
|
+
// WebAuthn ceremony output is produced by connect-auth; on-chain wire format here.
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
## Runtime Support
|
|
91
|
+
|
|
92
|
+
Node and browser via `viem`. Requires RPC URL for chain reads and transaction
|
|
93
|
+
submission.
|
|
94
|
+
|
|
95
|
+
## Security Invariants
|
|
96
|
+
|
|
97
|
+
- Salt derives from stable keccak inputs; no raw user-supplied salt bytes.
|
|
98
|
+
- EntryPoint version is explicit in client config.
|
|
99
|
+
- Bootstrap signer is distinct from day-to-day custodian signers.
|
|
100
|
+
|
|
101
|
+
See [`docs/security.md`](docs/security.md) and [`AUDIT.md`](AUDIT.md).
|
|
102
|
+
|
|
103
|
+
## Documentation Map
|
|
104
|
+
|
|
105
|
+
- [`docs/concepts.md`](docs/concepts.md) — canonical identity vs facets.
|
|
106
|
+
- [`docs/api.md`](docs/api.md) — public API guide.
|
|
107
|
+
- [`docs/security.md`](docs/security.md) — invariants and trust boundaries.
|
|
108
|
+
- [`docs/troubleshooting.md`](docs/troubleshooting.md) — common errors.
|
|
109
|
+
- [`docs/migration.md`](docs/migration.md) — migration notes.
|
|
110
|
+
- [`CLAUDE.md`](CLAUDE.md) — agent routing.
|
|
111
|
+
- [`spec.md`](spec.md) — spec pointer.
|
|
112
|
+
|
|
113
|
+
## Validation
|
|
114
|
+
|
|
115
|
+
```bash
|
|
116
|
+
pnpm check:agent-account
|
|
117
|
+
pnpm check:forbidden-terms
|
|
118
|
+
```
|
|
119
|
+
|
|
120
|
+
## License
|
|
121
|
+
|
|
122
|
+
UNLICENSED.
|
package/dist/abis.d.ts
ADDED
|
@@ -0,0 +1,543 @@
|
|
|
1
|
+
export declare const agentAccountFactoryAbi: readonly [{
|
|
2
|
+
readonly type: "function";
|
|
3
|
+
readonly name: "createAgentAccount";
|
|
4
|
+
readonly stateMutability: "nonpayable";
|
|
5
|
+
readonly inputs: readonly [{
|
|
6
|
+
readonly name: "params";
|
|
7
|
+
readonly type: "tuple";
|
|
8
|
+
readonly components: readonly [{
|
|
9
|
+
readonly name: "mode";
|
|
10
|
+
readonly type: "uint8";
|
|
11
|
+
}, {
|
|
12
|
+
readonly name: "custodians";
|
|
13
|
+
readonly type: "address[]";
|
|
14
|
+
}, {
|
|
15
|
+
readonly name: "trustees";
|
|
16
|
+
readonly type: "address[]";
|
|
17
|
+
}, {
|
|
18
|
+
readonly name: "initialPasskeyCredentialIdDigest";
|
|
19
|
+
readonly type: "bytes32";
|
|
20
|
+
}, {
|
|
21
|
+
readonly name: "initialPasskeyX";
|
|
22
|
+
readonly type: "uint256";
|
|
23
|
+
}, {
|
|
24
|
+
readonly name: "initialPasskeyY";
|
|
25
|
+
readonly type: "uint256";
|
|
26
|
+
}];
|
|
27
|
+
}, {
|
|
28
|
+
readonly name: "timelockOverrides";
|
|
29
|
+
readonly type: "uint32[7]";
|
|
30
|
+
}, {
|
|
31
|
+
readonly name: "salt";
|
|
32
|
+
readonly type: "uint256";
|
|
33
|
+
}];
|
|
34
|
+
readonly outputs: readonly [{
|
|
35
|
+
readonly name: "account";
|
|
36
|
+
readonly type: "address";
|
|
37
|
+
}];
|
|
38
|
+
}, {
|
|
39
|
+
readonly type: "function";
|
|
40
|
+
readonly name: "getAddressForAgentAccount";
|
|
41
|
+
readonly stateMutability: "view";
|
|
42
|
+
readonly inputs: readonly [{
|
|
43
|
+
readonly name: "params";
|
|
44
|
+
readonly type: "tuple";
|
|
45
|
+
readonly components: readonly [{
|
|
46
|
+
readonly name: "mode";
|
|
47
|
+
readonly type: "uint8";
|
|
48
|
+
}, {
|
|
49
|
+
readonly name: "custodians";
|
|
50
|
+
readonly type: "address[]";
|
|
51
|
+
}, {
|
|
52
|
+
readonly name: "trustees";
|
|
53
|
+
readonly type: "address[]";
|
|
54
|
+
}, {
|
|
55
|
+
readonly name: "initialPasskeyCredentialIdDigest";
|
|
56
|
+
readonly type: "bytes32";
|
|
57
|
+
}, {
|
|
58
|
+
readonly name: "initialPasskeyX";
|
|
59
|
+
readonly type: "uint256";
|
|
60
|
+
}, {
|
|
61
|
+
readonly name: "initialPasskeyY";
|
|
62
|
+
readonly type: "uint256";
|
|
63
|
+
}];
|
|
64
|
+
}, {
|
|
65
|
+
readonly name: "salt";
|
|
66
|
+
readonly type: "uint256";
|
|
67
|
+
}];
|
|
68
|
+
readonly outputs: readonly [{
|
|
69
|
+
readonly name: "";
|
|
70
|
+
readonly type: "address";
|
|
71
|
+
}];
|
|
72
|
+
}, {
|
|
73
|
+
readonly type: "function";
|
|
74
|
+
readonly name: "accountImplementation";
|
|
75
|
+
readonly stateMutability: "view";
|
|
76
|
+
readonly inputs: readonly [];
|
|
77
|
+
readonly outputs: readonly [{
|
|
78
|
+
readonly name: "";
|
|
79
|
+
readonly type: "address";
|
|
80
|
+
}];
|
|
81
|
+
}, {
|
|
82
|
+
readonly type: "function";
|
|
83
|
+
readonly name: "bundlerSigner";
|
|
84
|
+
readonly stateMutability: "view";
|
|
85
|
+
readonly inputs: readonly [];
|
|
86
|
+
readonly outputs: readonly [{
|
|
87
|
+
readonly name: "";
|
|
88
|
+
readonly type: "address";
|
|
89
|
+
}];
|
|
90
|
+
}, {
|
|
91
|
+
readonly type: "function";
|
|
92
|
+
readonly name: "sessionIssuer";
|
|
93
|
+
readonly stateMutability: "view";
|
|
94
|
+
readonly inputs: readonly [];
|
|
95
|
+
readonly outputs: readonly [{
|
|
96
|
+
readonly name: "";
|
|
97
|
+
readonly type: "address";
|
|
98
|
+
}];
|
|
99
|
+
}, {
|
|
100
|
+
readonly type: "function";
|
|
101
|
+
readonly name: "delegationManager";
|
|
102
|
+
readonly stateMutability: "view";
|
|
103
|
+
readonly inputs: readonly [];
|
|
104
|
+
readonly outputs: readonly [{
|
|
105
|
+
readonly name: "";
|
|
106
|
+
readonly type: "address";
|
|
107
|
+
}];
|
|
108
|
+
}, {
|
|
109
|
+
readonly type: "function";
|
|
110
|
+
readonly name: "custodyPolicy";
|
|
111
|
+
readonly stateMutability: "view";
|
|
112
|
+
readonly inputs: readonly [];
|
|
113
|
+
readonly outputs: readonly [{
|
|
114
|
+
readonly name: "";
|
|
115
|
+
readonly type: "address";
|
|
116
|
+
}];
|
|
117
|
+
}, {
|
|
118
|
+
readonly type: "event";
|
|
119
|
+
readonly name: "AgentAccountCreated";
|
|
120
|
+
readonly inputs: readonly [{
|
|
121
|
+
readonly name: "account";
|
|
122
|
+
readonly type: "address";
|
|
123
|
+
readonly indexed: true;
|
|
124
|
+
}, {
|
|
125
|
+
readonly name: "mode";
|
|
126
|
+
readonly type: "uint8";
|
|
127
|
+
readonly indexed: false;
|
|
128
|
+
}, {
|
|
129
|
+
readonly name: "nExternalCustodians";
|
|
130
|
+
readonly type: "uint256";
|
|
131
|
+
readonly indexed: false;
|
|
132
|
+
}, {
|
|
133
|
+
readonly name: "withPasskey";
|
|
134
|
+
readonly type: "bool";
|
|
135
|
+
readonly indexed: false;
|
|
136
|
+
}, {
|
|
137
|
+
readonly name: "salt";
|
|
138
|
+
readonly type: "uint256";
|
|
139
|
+
readonly indexed: false;
|
|
140
|
+
}];
|
|
141
|
+
}];
|
|
142
|
+
export declare const agentAccountAbi: readonly [{
|
|
143
|
+
readonly type: "function";
|
|
144
|
+
readonly name: "isValidSignature";
|
|
145
|
+
readonly stateMutability: "view";
|
|
146
|
+
readonly inputs: readonly [{
|
|
147
|
+
readonly name: "hash";
|
|
148
|
+
readonly type: "bytes32";
|
|
149
|
+
}, {
|
|
150
|
+
readonly name: "signature";
|
|
151
|
+
readonly type: "bytes";
|
|
152
|
+
}];
|
|
153
|
+
readonly outputs: readonly [{
|
|
154
|
+
readonly name: "";
|
|
155
|
+
readonly type: "bytes4";
|
|
156
|
+
}];
|
|
157
|
+
}, {
|
|
158
|
+
readonly type: "function";
|
|
159
|
+
readonly name: "acceptSessionDelegation";
|
|
160
|
+
readonly stateMutability: "nonpayable";
|
|
161
|
+
readonly inputs: readonly [{
|
|
162
|
+
readonly name: "sessionDelegationHash";
|
|
163
|
+
readonly type: "bytes32";
|
|
164
|
+
}];
|
|
165
|
+
readonly outputs: readonly [];
|
|
166
|
+
}, {
|
|
167
|
+
readonly type: "function";
|
|
168
|
+
readonly name: "hasAcceptedSessionDelegation";
|
|
169
|
+
readonly stateMutability: "view";
|
|
170
|
+
readonly inputs: readonly [{
|
|
171
|
+
readonly name: "sessionDelegationHash";
|
|
172
|
+
readonly type: "bytes32";
|
|
173
|
+
}];
|
|
174
|
+
readonly outputs: readonly [{
|
|
175
|
+
readonly type: "bool";
|
|
176
|
+
}];
|
|
177
|
+
}, {
|
|
178
|
+
readonly type: "function";
|
|
179
|
+
readonly name: "isCustodian";
|
|
180
|
+
readonly stateMutability: "view";
|
|
181
|
+
readonly inputs: readonly [{
|
|
182
|
+
readonly name: "account";
|
|
183
|
+
readonly type: "address";
|
|
184
|
+
}];
|
|
185
|
+
readonly outputs: readonly [{
|
|
186
|
+
readonly type: "bool";
|
|
187
|
+
}];
|
|
188
|
+
}, {
|
|
189
|
+
readonly type: "function";
|
|
190
|
+
readonly name: "custodianCount";
|
|
191
|
+
readonly stateMutability: "view";
|
|
192
|
+
readonly inputs: readonly [];
|
|
193
|
+
readonly outputs: readonly [{
|
|
194
|
+
readonly type: "uint256";
|
|
195
|
+
}];
|
|
196
|
+
}, {
|
|
197
|
+
readonly type: "function";
|
|
198
|
+
readonly name: "factory";
|
|
199
|
+
readonly stateMutability: "view";
|
|
200
|
+
readonly inputs: readonly [];
|
|
201
|
+
readonly outputs: readonly [{
|
|
202
|
+
readonly type: "address";
|
|
203
|
+
}];
|
|
204
|
+
}, {
|
|
205
|
+
readonly type: "function";
|
|
206
|
+
readonly name: "delegationManager";
|
|
207
|
+
readonly stateMutability: "view";
|
|
208
|
+
readonly inputs: readonly [];
|
|
209
|
+
readonly outputs: readonly [{
|
|
210
|
+
readonly type: "address";
|
|
211
|
+
}];
|
|
212
|
+
}, {
|
|
213
|
+
readonly type: "function";
|
|
214
|
+
readonly name: "passkeyIdentity";
|
|
215
|
+
readonly stateMutability: "pure";
|
|
216
|
+
readonly inputs: readonly [{
|
|
217
|
+
readonly name: "x";
|
|
218
|
+
readonly type: "uint256";
|
|
219
|
+
}, {
|
|
220
|
+
readonly name: "y";
|
|
221
|
+
readonly type: "uint256";
|
|
222
|
+
}];
|
|
223
|
+
readonly outputs: readonly [{
|
|
224
|
+
readonly type: "address";
|
|
225
|
+
}];
|
|
226
|
+
}, {
|
|
227
|
+
readonly type: "function";
|
|
228
|
+
readonly name: "hasPasskey";
|
|
229
|
+
readonly stateMutability: "view";
|
|
230
|
+
readonly inputs: readonly [{
|
|
231
|
+
readonly name: "credentialIdDigest";
|
|
232
|
+
readonly type: "bytes32";
|
|
233
|
+
}];
|
|
234
|
+
readonly outputs: readonly [{
|
|
235
|
+
readonly type: "bool";
|
|
236
|
+
}];
|
|
237
|
+
}, {
|
|
238
|
+
readonly type: "function";
|
|
239
|
+
readonly name: "getPasskey";
|
|
240
|
+
readonly stateMutability: "view";
|
|
241
|
+
readonly inputs: readonly [{
|
|
242
|
+
readonly name: "credentialIdDigest";
|
|
243
|
+
readonly type: "bytes32";
|
|
244
|
+
}];
|
|
245
|
+
readonly outputs: readonly [{
|
|
246
|
+
readonly name: "x";
|
|
247
|
+
readonly type: "uint256";
|
|
248
|
+
}, {
|
|
249
|
+
readonly name: "y";
|
|
250
|
+
readonly type: "uint256";
|
|
251
|
+
}];
|
|
252
|
+
}, {
|
|
253
|
+
readonly type: "function";
|
|
254
|
+
readonly name: "passkeyCount";
|
|
255
|
+
readonly stateMutability: "view";
|
|
256
|
+
readonly inputs: readonly [];
|
|
257
|
+
readonly outputs: readonly [{
|
|
258
|
+
readonly type: "uint256";
|
|
259
|
+
}];
|
|
260
|
+
}, {
|
|
261
|
+
readonly type: "function";
|
|
262
|
+
readonly name: "addPasskey";
|
|
263
|
+
readonly stateMutability: "nonpayable";
|
|
264
|
+
readonly inputs: readonly [{
|
|
265
|
+
readonly name: "credentialIdDigest";
|
|
266
|
+
readonly type: "bytes32";
|
|
267
|
+
}, {
|
|
268
|
+
readonly name: "x";
|
|
269
|
+
readonly type: "uint256";
|
|
270
|
+
}, {
|
|
271
|
+
readonly name: "y";
|
|
272
|
+
readonly type: "uint256";
|
|
273
|
+
}];
|
|
274
|
+
readonly outputs: readonly [];
|
|
275
|
+
}, {
|
|
276
|
+
readonly type: "function";
|
|
277
|
+
readonly name: "removePasskey";
|
|
278
|
+
readonly stateMutability: "nonpayable";
|
|
279
|
+
readonly inputs: readonly [{
|
|
280
|
+
readonly name: "credentialIdDigest";
|
|
281
|
+
readonly type: "bytes32";
|
|
282
|
+
}];
|
|
283
|
+
readonly outputs: readonly [];
|
|
284
|
+
}, {
|
|
285
|
+
readonly type: "function";
|
|
286
|
+
readonly name: "addCustodian";
|
|
287
|
+
readonly stateMutability: "nonpayable";
|
|
288
|
+
readonly inputs: readonly [{
|
|
289
|
+
readonly name: "owner";
|
|
290
|
+
readonly type: "address";
|
|
291
|
+
}];
|
|
292
|
+
readonly outputs: readonly [];
|
|
293
|
+
}, {
|
|
294
|
+
readonly type: "function";
|
|
295
|
+
readonly name: "removeCustodian";
|
|
296
|
+
readonly stateMutability: "nonpayable";
|
|
297
|
+
readonly inputs: readonly [{
|
|
298
|
+
readonly name: "owner";
|
|
299
|
+
readonly type: "address";
|
|
300
|
+
}];
|
|
301
|
+
readonly outputs: readonly [];
|
|
302
|
+
}, {
|
|
303
|
+
readonly type: "function";
|
|
304
|
+
readonly name: "execute";
|
|
305
|
+
readonly stateMutability: "nonpayable";
|
|
306
|
+
readonly inputs: readonly [{
|
|
307
|
+
readonly name: "target";
|
|
308
|
+
readonly type: "address";
|
|
309
|
+
}, {
|
|
310
|
+
readonly name: "value";
|
|
311
|
+
readonly type: "uint256";
|
|
312
|
+
}, {
|
|
313
|
+
readonly name: "data";
|
|
314
|
+
readonly type: "bytes";
|
|
315
|
+
}];
|
|
316
|
+
readonly outputs: readonly [];
|
|
317
|
+
}, {
|
|
318
|
+
readonly type: "function";
|
|
319
|
+
readonly name: "supportsInterface";
|
|
320
|
+
readonly stateMutability: "pure";
|
|
321
|
+
readonly inputs: readonly [{
|
|
322
|
+
readonly name: "interfaceId";
|
|
323
|
+
readonly type: "bytes4";
|
|
324
|
+
}];
|
|
325
|
+
readonly outputs: readonly [{
|
|
326
|
+
readonly type: "bool";
|
|
327
|
+
}];
|
|
328
|
+
}, {
|
|
329
|
+
readonly type: "function";
|
|
330
|
+
readonly name: "isAgenticPrimitivesAgentAccount";
|
|
331
|
+
readonly stateMutability: "pure";
|
|
332
|
+
readonly inputs: readonly [];
|
|
333
|
+
readonly outputs: readonly [{
|
|
334
|
+
readonly type: "bool";
|
|
335
|
+
}];
|
|
336
|
+
}, {
|
|
337
|
+
readonly type: "event";
|
|
338
|
+
readonly name: "CustodianAdded";
|
|
339
|
+
readonly inputs: readonly [{
|
|
340
|
+
readonly name: "owner";
|
|
341
|
+
readonly type: "address";
|
|
342
|
+
readonly indexed: true;
|
|
343
|
+
}];
|
|
344
|
+
}, {
|
|
345
|
+
readonly type: "event";
|
|
346
|
+
readonly name: "CustodianRemoved";
|
|
347
|
+
readonly inputs: readonly [{
|
|
348
|
+
readonly name: "owner";
|
|
349
|
+
readonly type: "address";
|
|
350
|
+
readonly indexed: true;
|
|
351
|
+
}];
|
|
352
|
+
}, {
|
|
353
|
+
readonly type: "event";
|
|
354
|
+
readonly name: "PasskeyAdded";
|
|
355
|
+
readonly inputs: readonly [{
|
|
356
|
+
readonly name: "credentialIdDigest";
|
|
357
|
+
readonly type: "bytes32";
|
|
358
|
+
readonly indexed: true;
|
|
359
|
+
}, {
|
|
360
|
+
readonly name: "x";
|
|
361
|
+
readonly type: "uint256";
|
|
362
|
+
readonly indexed: false;
|
|
363
|
+
}, {
|
|
364
|
+
readonly name: "y";
|
|
365
|
+
readonly type: "uint256";
|
|
366
|
+
readonly indexed: false;
|
|
367
|
+
}];
|
|
368
|
+
}, {
|
|
369
|
+
readonly type: "event";
|
|
370
|
+
readonly name: "PasskeyRemoved";
|
|
371
|
+
readonly inputs: readonly [{
|
|
372
|
+
readonly name: "credentialIdDigest";
|
|
373
|
+
readonly type: "bytes32";
|
|
374
|
+
readonly indexed: true;
|
|
375
|
+
}];
|
|
376
|
+
}];
|
|
377
|
+
/**
|
|
378
|
+
* ApprovedHashRegistry (packages/contracts/src/ApprovedHashRegistry.sol).
|
|
379
|
+
* The v=1 path companion — passkey-only or hardware-wallet signers
|
|
380
|
+
* pre-approve a hash with one tx instead of producing an off-chain
|
|
381
|
+
* ECDSA sig. `QuorumEnforcer.beforeHook` (and the
|
|
382
|
+
* `_verifyQuorum(..., guardianMode=true)` path in AgentAccount) check
|
|
383
|
+
* `isApproved(signer, hash)` for v=1 slots in the packed blob.
|
|
384
|
+
*/
|
|
385
|
+
export declare const approvedHashRegistryAbi: readonly [{
|
|
386
|
+
readonly type: "function";
|
|
387
|
+
readonly name: "approveHash";
|
|
388
|
+
readonly stateMutability: "nonpayable";
|
|
389
|
+
readonly inputs: readonly [{
|
|
390
|
+
readonly name: "hash";
|
|
391
|
+
readonly type: "bytes32";
|
|
392
|
+
}];
|
|
393
|
+
readonly outputs: readonly [];
|
|
394
|
+
}, {
|
|
395
|
+
readonly type: "function";
|
|
396
|
+
readonly name: "revokeHash";
|
|
397
|
+
readonly stateMutability: "nonpayable";
|
|
398
|
+
readonly inputs: readonly [{
|
|
399
|
+
readonly name: "hash";
|
|
400
|
+
readonly type: "bytes32";
|
|
401
|
+
}];
|
|
402
|
+
readonly outputs: readonly [];
|
|
403
|
+
}, {
|
|
404
|
+
readonly type: "function";
|
|
405
|
+
readonly name: "isApproved";
|
|
406
|
+
readonly stateMutability: "view";
|
|
407
|
+
readonly inputs: readonly [{
|
|
408
|
+
readonly name: "signer";
|
|
409
|
+
readonly type: "address";
|
|
410
|
+
}, {
|
|
411
|
+
readonly name: "hash";
|
|
412
|
+
readonly type: "bytes32";
|
|
413
|
+
}];
|
|
414
|
+
readonly outputs: readonly [{
|
|
415
|
+
readonly type: "bool";
|
|
416
|
+
}];
|
|
417
|
+
}];
|
|
418
|
+
/** ERC-1271 magic value returned by isValidSignature on success. */
|
|
419
|
+
export declare const ERC1271_MAGIC_VALUE: "0x1626ba7e";
|
|
420
|
+
/**
|
|
421
|
+
* Minimal EntryPoint ABI for our bundler client + UserOp hashing.
|
|
422
|
+
* Source: account-abstraction/contracts/core/EntryPoint.sol (v0.9).
|
|
423
|
+
*/
|
|
424
|
+
export declare const entryPointAbi: readonly [{
|
|
425
|
+
readonly type: "function";
|
|
426
|
+
readonly name: "getUserOpHash";
|
|
427
|
+
readonly stateMutability: "view";
|
|
428
|
+
readonly inputs: readonly [{
|
|
429
|
+
readonly name: "userOp";
|
|
430
|
+
readonly type: "tuple";
|
|
431
|
+
readonly components: readonly [{
|
|
432
|
+
readonly name: "sender";
|
|
433
|
+
readonly type: "address";
|
|
434
|
+
}, {
|
|
435
|
+
readonly name: "nonce";
|
|
436
|
+
readonly type: "uint256";
|
|
437
|
+
}, {
|
|
438
|
+
readonly name: "initCode";
|
|
439
|
+
readonly type: "bytes";
|
|
440
|
+
}, {
|
|
441
|
+
readonly name: "callData";
|
|
442
|
+
readonly type: "bytes";
|
|
443
|
+
}, {
|
|
444
|
+
readonly name: "accountGasLimits";
|
|
445
|
+
readonly type: "bytes32";
|
|
446
|
+
}, {
|
|
447
|
+
readonly name: "preVerificationGas";
|
|
448
|
+
readonly type: "uint256";
|
|
449
|
+
}, {
|
|
450
|
+
readonly name: "gasFees";
|
|
451
|
+
readonly type: "bytes32";
|
|
452
|
+
}, {
|
|
453
|
+
readonly name: "paymasterAndData";
|
|
454
|
+
readonly type: "bytes";
|
|
455
|
+
}, {
|
|
456
|
+
readonly name: "signature";
|
|
457
|
+
readonly type: "bytes";
|
|
458
|
+
}];
|
|
459
|
+
}];
|
|
460
|
+
readonly outputs: readonly [{
|
|
461
|
+
readonly name: "";
|
|
462
|
+
readonly type: "bytes32";
|
|
463
|
+
}];
|
|
464
|
+
}, {
|
|
465
|
+
readonly type: "function";
|
|
466
|
+
readonly name: "handleOps";
|
|
467
|
+
readonly stateMutability: "nonpayable";
|
|
468
|
+
readonly inputs: readonly [{
|
|
469
|
+
readonly name: "ops";
|
|
470
|
+
readonly type: "tuple[]";
|
|
471
|
+
readonly components: readonly [{
|
|
472
|
+
readonly name: "sender";
|
|
473
|
+
readonly type: "address";
|
|
474
|
+
}, {
|
|
475
|
+
readonly name: "nonce";
|
|
476
|
+
readonly type: "uint256";
|
|
477
|
+
}, {
|
|
478
|
+
readonly name: "initCode";
|
|
479
|
+
readonly type: "bytes";
|
|
480
|
+
}, {
|
|
481
|
+
readonly name: "callData";
|
|
482
|
+
readonly type: "bytes";
|
|
483
|
+
}, {
|
|
484
|
+
readonly name: "accountGasLimits";
|
|
485
|
+
readonly type: "bytes32";
|
|
486
|
+
}, {
|
|
487
|
+
readonly name: "preVerificationGas";
|
|
488
|
+
readonly type: "uint256";
|
|
489
|
+
}, {
|
|
490
|
+
readonly name: "gasFees";
|
|
491
|
+
readonly type: "bytes32";
|
|
492
|
+
}, {
|
|
493
|
+
readonly name: "paymasterAndData";
|
|
494
|
+
readonly type: "bytes";
|
|
495
|
+
}, {
|
|
496
|
+
readonly name: "signature";
|
|
497
|
+
readonly type: "bytes";
|
|
498
|
+
}];
|
|
499
|
+
}, {
|
|
500
|
+
readonly name: "beneficiary";
|
|
501
|
+
readonly type: "address";
|
|
502
|
+
}];
|
|
503
|
+
readonly outputs: readonly [];
|
|
504
|
+
}, {
|
|
505
|
+
readonly type: "function";
|
|
506
|
+
readonly name: "getNonce";
|
|
507
|
+
readonly stateMutability: "view";
|
|
508
|
+
readonly inputs: readonly [{
|
|
509
|
+
readonly name: "sender";
|
|
510
|
+
readonly type: "address";
|
|
511
|
+
}, {
|
|
512
|
+
readonly name: "key";
|
|
513
|
+
readonly type: "uint192";
|
|
514
|
+
}];
|
|
515
|
+
readonly outputs: readonly [{
|
|
516
|
+
readonly name: "nonce";
|
|
517
|
+
readonly type: "uint256";
|
|
518
|
+
}];
|
|
519
|
+
}, {
|
|
520
|
+
readonly type: "error";
|
|
521
|
+
readonly name: "FailedOp";
|
|
522
|
+
readonly inputs: readonly [{
|
|
523
|
+
readonly name: "opIndex";
|
|
524
|
+
readonly type: "uint256";
|
|
525
|
+
}, {
|
|
526
|
+
readonly name: "reason";
|
|
527
|
+
readonly type: "string";
|
|
528
|
+
}];
|
|
529
|
+
}, {
|
|
530
|
+
readonly type: "error";
|
|
531
|
+
readonly name: "FailedOpWithRevert";
|
|
532
|
+
readonly inputs: readonly [{
|
|
533
|
+
readonly name: "opIndex";
|
|
534
|
+
readonly type: "uint256";
|
|
535
|
+
}, {
|
|
536
|
+
readonly name: "reason";
|
|
537
|
+
readonly type: "string";
|
|
538
|
+
}, {
|
|
539
|
+
readonly name: "inner";
|
|
540
|
+
readonly type: "bytes";
|
|
541
|
+
}];
|
|
542
|
+
}];
|
|
543
|
+
//# sourceMappingURL=abis.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"abis.d.ts","sourceRoot":"","sources":["../src/abis.ts"],"names":[],"mappings":"AAoBA,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAyEzB,CAAC;AAEX,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAgDlB,CAAC;AAKX;;;;;;;GAOG;AACH,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAyB1B,CAAC;AAEX,oEAAoE;AACpE,eAAO,MAAM,mBAAmB,EAAG,YAAqB,CAAC;AAEzD;;;GAGG;AACH,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA8EhB,CAAC"}
|