@0gfoundation/0g-agentdna 0.0.0-stage → 0.2.1
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/GUIDE.md +975 -0
- package/LICENSE +21 -0
- package/MIGRATION.md +84 -0
- package/MIGRATION.zh.md +70 -0
- package/PROVIDERS.md +273 -0
- package/PROVIDERS.zh.md +234 -0
- package/README.md +334 -2
- package/dist/AgentClient.d.ts +312 -0
- package/dist/AgentClient.d.ts.map +1 -0
- package/dist/AgentClient.js +715 -0
- package/dist/AgentClient.js.map +1 -0
- package/dist/AgenticID.d.ts +823 -0
- package/dist/AgenticID.d.ts.map +1 -0
- package/dist/AgenticID.js +1188 -0
- package/dist/AgenticID.js.map +1 -0
- package/dist/AgenticIDClient.d.ts +68 -0
- package/dist/AgenticIDClient.d.ts.map +1 -0
- package/dist/AgenticIDClient.js +198 -0
- package/dist/AgenticIDClient.js.map +1 -0
- package/dist/AttestorClient.d.ts +465 -0
- package/dist/AttestorClient.d.ts.map +1 -0
- package/dist/AttestorClient.js +1030 -0
- package/dist/AttestorClient.js.map +1 -0
- package/dist/Providers.d.ts +72 -0
- package/dist/Providers.d.ts.map +1 -0
- package/dist/Providers.js +182 -0
- package/dist/Providers.js.map +1 -0
- package/dist/ReputationClient.d.ts +213 -0
- package/dist/ReputationClient.d.ts.map +1 -0
- package/dist/ReputationClient.js +708 -0
- package/dist/ReputationClient.js.map +1 -0
- package/dist/SandboxClient.d.ts +107 -0
- package/dist/SandboxClient.d.ts.map +1 -0
- package/dist/SandboxClient.js +200 -0
- package/dist/SandboxClient.js.map +1 -0
- package/dist/ServeProof.d.ts +161 -0
- package/dist/ServeProof.d.ts.map +1 -0
- package/dist/ServeProof.js +230 -0
- package/dist/ServeProof.js.map +1 -0
- package/dist/ServeSession.d.ts +180 -0
- package/dist/ServeSession.d.ts.map +1 -0
- package/dist/ServeSession.js +336 -0
- package/dist/ServeSession.js.map +1 -0
- package/dist/Settings.d.ts +179 -0
- package/dist/Settings.d.ts.map +1 -0
- package/dist/Settings.js +247 -0
- package/dist/Settings.js.map +1 -0
- package/dist/abi.d.ts +2216 -0
- package/dist/abi.d.ts.map +1 -0
- package/dist/abi.js +1248 -0
- package/dist/abi.js.map +1 -0
- package/dist/cli/commands/cells.d.ts +62 -0
- package/dist/cli/commands/cells.d.ts.map +1 -0
- package/dist/cli/commands/cells.js +113 -0
- package/dist/cli/commands/cells.js.map +1 -0
- package/dist/cli/commands/doctor.d.ts +15 -0
- package/dist/cli/commands/doctor.d.ts.map +1 -0
- package/dist/cli/commands/doctor.js +236 -0
- package/dist/cli/commands/doctor.js.map +1 -0
- package/dist/cli/commands/interactive.d.ts +115 -0
- package/dist/cli/commands/interactive.d.ts.map +1 -0
- package/dist/cli/commands/interactive.js +3052 -0
- package/dist/cli/commands/interactive.js.map +1 -0
- package/dist/cli/commands/list.d.ts +31 -0
- package/dist/cli/commands/list.d.ts.map +1 -0
- package/dist/cli/commands/list.js +91 -0
- package/dist/cli/commands/list.js.map +1 -0
- package/dist/cli/commands/providers.d.ts +3 -0
- package/dist/cli/commands/providers.d.ts.map +1 -0
- package/dist/cli/commands/providers.js +21 -0
- package/dist/cli/commands/providers.js.map +1 -0
- package/dist/cli/commands/settings.d.ts +22 -0
- package/dist/cli/commands/settings.d.ts.map +1 -0
- package/dist/cli/commands/settings.js +188 -0
- package/dist/cli/commands/settings.js.map +1 -0
- package/dist/cli/commands/status.d.ts +16 -0
- package/dist/cli/commands/status.d.ts.map +1 -0
- package/dist/cli/commands/status.js +148 -0
- package/dist/cli/commands/status.js.map +1 -0
- package/dist/cli/commands/update.d.ts +21 -0
- package/dist/cli/commands/update.d.ts.map +1 -0
- package/dist/cli/commands/update.js +95 -0
- package/dist/cli/commands/update.js.map +1 -0
- package/dist/cli/config.d.ts +73 -0
- package/dist/cli/config.d.ts.map +1 -0
- package/dist/cli/config.js +239 -0
- package/dist/cli/config.js.map +1 -0
- package/dist/cli/env.d.ts +36 -0
- package/dist/cli/env.d.ts.map +1 -0
- package/dist/cli/env.js +74 -0
- package/dist/cli/env.js.map +1 -0
- package/dist/cli/envelope.d.ts +33 -0
- package/dist/cli/envelope.d.ts.map +1 -0
- package/dist/cli/envelope.js +62 -0
- package/dist/cli/envelope.js.map +1 -0
- package/dist/cli/errors.d.ts +48 -0
- package/dist/cli/errors.d.ts.map +1 -0
- package/dist/cli/errors.js +81 -0
- package/dist/cli/errors.js.map +1 -0
- package/dist/cli/inference.d.ts +21 -0
- package/dist/cli/inference.d.ts.map +1 -0
- package/dist/cli/inference.js +60 -0
- package/dist/cli/inference.js.map +1 -0
- package/dist/cli/logo.d.ts +21 -0
- package/dist/cli/logo.d.ts.map +1 -0
- package/dist/cli/logo.js +131 -0
- package/dist/cli/logo.js.map +1 -0
- package/dist/cli/main.d.ts +14 -0
- package/dist/cli/main.d.ts.map +1 -0
- package/dist/cli/main.js +223 -0
- package/dist/cli/main.js.map +1 -0
- package/dist/cli/proofs.d.ts +67 -0
- package/dist/cli/proofs.d.ts.map +1 -0
- package/dist/cli/proofs.js +133 -0
- package/dist/cli/proofs.js.map +1 -0
- package/dist/cli/ref.d.ts +39 -0
- package/dist/cli/ref.d.ts.map +1 -0
- package/dist/cli/ref.js +48 -0
- package/dist/cli/ref.js.map +1 -0
- package/dist/cli/sdk.d.ts +24 -0
- package/dist/cli/sdk.d.ts.map +1 -0
- package/dist/cli/sdk.js +65 -0
- package/dist/cli/sdk.js.map +1 -0
- package/dist/cli/settings.d.ts +66 -0
- package/dist/cli/settings.d.ts.map +1 -0
- package/dist/cli/settings.js +137 -0
- package/dist/cli/settings.js.map +1 -0
- package/dist/cli/tokenize.d.ts +61 -0
- package/dist/cli/tokenize.d.ts.map +1 -0
- package/dist/cli/tokenize.js +157 -0
- package/dist/cli/tokenize.js.map +1 -0
- package/dist/cli/types.d.ts +25 -0
- package/dist/cli/types.d.ts.map +1 -0
- package/dist/cli/types.js +8 -0
- package/dist/cli/types.js.map +1 -0
- package/dist/constants.d.ts +107 -0
- package/dist/constants.d.ts.map +1 -0
- package/dist/constants.js +74 -0
- package/dist/constants.js.map +1 -0
- package/dist/context.d.ts +108 -0
- package/dist/context.d.ts.map +1 -0
- package/dist/context.js +64 -0
- package/dist/context.js.map +1 -0
- package/dist/index.d.ts +45 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +118 -0
- package/dist/index.js.map +1 -0
- package/dist/provider-catalog.json +23 -0
- package/dist/seal.d.ts +47 -0
- package/dist/seal.d.ts.map +1 -0
- package/dist/seal.js +145 -0
- package/dist/seal.js.map +1 -0
- package/dist/secretEnv.d.ts +119 -0
- package/dist/secretEnv.d.ts.map +1 -0
- package/dist/secretEnv.js +199 -0
- package/dist/secretEnv.js.map +1 -0
- package/dist/taskHash.d.ts +39 -0
- package/dist/taskHash.d.ts.map +1 -0
- package/dist/taskHash.js +119 -0
- package/dist/taskHash.js.map +1 -0
- package/dist/types.d.ts +336 -0
- package/dist/types.d.ts.map +1 -0
- package/dist/types.js +19 -0
- package/dist/types.js.map +1 -0
- package/package.json +75 -4
- package/scripts/sync-providers.cjs +8 -0
- package/src/AgentClient.ts +897 -0
- package/src/AgenticID.ts +1382 -0
- package/src/AgenticIDClient.ts +238 -0
- package/src/AttestorClient.ts +1306 -0
- package/src/Providers.ts +176 -0
- package/src/ReputationClient.ts +821 -0
- package/src/SandboxClient.ts +227 -0
- package/src/ServeProof.ts +290 -0
- package/src/ServeSession.ts +421 -0
- package/src/Settings.ts +296 -0
- package/src/abi.ts +1282 -0
- package/src/cli/commands/cells.ts +107 -0
- package/src/cli/commands/doctor.ts +235 -0
- package/src/cli/commands/interactive.ts +2738 -0
- package/src/cli/commands/list.ts +95 -0
- package/src/cli/commands/providers.ts +16 -0
- package/src/cli/commands/settings.ts +197 -0
- package/src/cli/commands/status.ts +170 -0
- package/src/cli/commands/update.ts +86 -0
- package/src/cli/config.ts +225 -0
- package/src/cli/env.ts +90 -0
- package/src/cli/envelope.ts +57 -0
- package/src/cli/errors.ts +114 -0
- package/src/cli/inference.ts +57 -0
- package/src/cli/logo.ts +125 -0
- package/src/cli/main.ts +235 -0
- package/src/cli/proofs.ts +160 -0
- package/src/cli/ref.ts +58 -0
- package/src/cli/sdk.ts +65 -0
- package/src/cli/settings.ts +153 -0
- package/src/cli/tokenize.ts +131 -0
- package/src/cli/types.ts +27 -0
- package/src/constants.ts +106 -0
- package/src/context.ts +161 -0
- package/src/index.ts +129 -0
- package/src/provider-catalog.json +23 -0
- package/src/seal.ts +163 -0
- package/src/secretEnv.ts +250 -0
- package/src/taskHash.ts +100 -0
- package/src/types.ts +357 -0
package/dist/abi.js
ADDED
|
@@ -0,0 +1,1248 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* @file abi.ts
|
|
4
|
+
* @description Contract ABIs for the 0G AgenticID protocol, manually authored from Solidity source.
|
|
5
|
+
*/
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.sandboxServingAbi = exports.tappRegistryAbi = exports.standardCloneAuthorizerAbi = exports.cloneGateAbi = exports.feedbackBatcherAbi = exports.verifiedFeedbackAbi = exports.canonicalReputationAbi = exports.agenticIDAbi = void 0;
|
|
8
|
+
/**
|
|
9
|
+
* ABI for the AgenticID contract.
|
|
10
|
+
* Inherits ERC-8004 and ERC-7857.
|
|
11
|
+
*/
|
|
12
|
+
exports.agenticIDAbi = [
|
|
13
|
+
// ── Registration ──
|
|
14
|
+
{
|
|
15
|
+
type: 'function',
|
|
16
|
+
name: 'register',
|
|
17
|
+
stateMutability: 'nonpayable',
|
|
18
|
+
inputs: [
|
|
19
|
+
{ name: 'agentURI', type: 'string' },
|
|
20
|
+
{ name: 'metadata', type: 'tuple[]', components: [
|
|
21
|
+
{ name: 'metadataKey', type: 'string' },
|
|
22
|
+
{ name: 'metadataValue', type: 'bytes' },
|
|
23
|
+
] },
|
|
24
|
+
{ name: 'intelligentDatas', type: 'tuple[]', components: [
|
|
25
|
+
{ name: 'dataDescription', type: 'string' },
|
|
26
|
+
{ name: 'dataHash', type: 'bytes32' },
|
|
27
|
+
] },
|
|
28
|
+
{ name: 'sealedKeys', type: 'bytes[]' },
|
|
29
|
+
],
|
|
30
|
+
outputs: [{ name: 'agentId', type: 'uint256' }],
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
type: 'function',
|
|
34
|
+
name: 'registerWithSeal',
|
|
35
|
+
stateMutability: 'nonpayable',
|
|
36
|
+
inputs: [
|
|
37
|
+
{ name: 'to', type: 'address' },
|
|
38
|
+
{ name: 'agentURI', type: 'string' },
|
|
39
|
+
{ name: 'metadata', type: 'tuple[]', components: [
|
|
40
|
+
{ name: 'metadataKey', type: 'string' },
|
|
41
|
+
{ name: 'metadataValue', type: 'bytes' },
|
|
42
|
+
] },
|
|
43
|
+
{ name: 'intelligentDatas', type: 'tuple[]', components: [
|
|
44
|
+
{ name: 'dataDescription', type: 'string' },
|
|
45
|
+
{ name: 'dataHash', type: 'bytes32' },
|
|
46
|
+
] },
|
|
47
|
+
{ name: 'sealedKeys', type: 'bytes[]' },
|
|
48
|
+
{ name: 'agentSeal_', type: 'address' },
|
|
49
|
+
{ name: 'sealId', type: 'bytes32' },
|
|
50
|
+
],
|
|
51
|
+
outputs: [{ name: 'agentId', type: 'uint256' }],
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
type: 'function',
|
|
55
|
+
name: 'tokenURI',
|
|
56
|
+
stateMutability: 'view',
|
|
57
|
+
inputs: [{ name: 'tokenId', type: 'uint256' }],
|
|
58
|
+
outputs: [{ name: '', type: 'string' }],
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
type: 'function',
|
|
62
|
+
name: 'getAgentSeal',
|
|
63
|
+
stateMutability: 'view',
|
|
64
|
+
inputs: [{ name: 'agentId', type: 'uint256' }],
|
|
65
|
+
outputs: [{ name: '', type: 'address' }],
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
type: 'function',
|
|
69
|
+
name: 'getSealId',
|
|
70
|
+
stateMutability: 'view',
|
|
71
|
+
inputs: [{ name: 'agentId', type: 'uint256' }],
|
|
72
|
+
outputs: [{ name: '', type: 'bytes32' }],
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
type: 'function',
|
|
76
|
+
name: 'getAgentIdBySealId',
|
|
77
|
+
stateMutability: 'view',
|
|
78
|
+
inputs: [{ name: 'sealId', type: 'bytes32' }],
|
|
79
|
+
outputs: [{ name: '', type: 'uint256' }],
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
type: 'function',
|
|
83
|
+
name: 'isSealIdBound',
|
|
84
|
+
stateMutability: 'view',
|
|
85
|
+
inputs: [{ name: 'sealId', type: 'bytes32' }],
|
|
86
|
+
outputs: [{ name: '', type: 'bool' }],
|
|
87
|
+
},
|
|
88
|
+
// ── Trusted Attestors ──
|
|
89
|
+
{
|
|
90
|
+
type: 'function',
|
|
91
|
+
name: 'addTrustedAttestor',
|
|
92
|
+
stateMutability: 'nonpayable',
|
|
93
|
+
inputs: [{ name: 'attestor', type: 'address' }],
|
|
94
|
+
outputs: [],
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
type: 'function',
|
|
98
|
+
name: 'removeTrustedAttestor',
|
|
99
|
+
stateMutability: 'nonpayable',
|
|
100
|
+
inputs: [{ name: 'attestor', type: 'address' }],
|
|
101
|
+
outputs: [],
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
type: 'function',
|
|
105
|
+
name: 'isTrustedAttestor',
|
|
106
|
+
stateMutability: 'view',
|
|
107
|
+
inputs: [{ name: 'attestor', type: 'address' }],
|
|
108
|
+
outputs: [{ name: '', type: 'bool' }],
|
|
109
|
+
},
|
|
110
|
+
// ── Framework Hashes ──
|
|
111
|
+
{
|
|
112
|
+
type: 'function',
|
|
113
|
+
name: 'addValidFrameworkHash',
|
|
114
|
+
stateMutability: 'nonpayable',
|
|
115
|
+
inputs: [{ name: 'frameworkHash', type: 'bytes32' }],
|
|
116
|
+
outputs: [],
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
type: 'function',
|
|
120
|
+
name: 'removeValidFrameworkHash',
|
|
121
|
+
stateMutability: 'nonpayable',
|
|
122
|
+
inputs: [{ name: 'frameworkHash', type: 'bytes32' }],
|
|
123
|
+
outputs: [],
|
|
124
|
+
},
|
|
125
|
+
{
|
|
126
|
+
type: 'function',
|
|
127
|
+
name: 'isValidFrameworkHash',
|
|
128
|
+
stateMutability: 'view',
|
|
129
|
+
inputs: [{ name: 'frameworkHash', type: 'bytes32' }],
|
|
130
|
+
outputs: [{ name: '', type: 'bool' }],
|
|
131
|
+
},
|
|
132
|
+
// ── Transfer (seal-bound only) ──
|
|
133
|
+
{
|
|
134
|
+
type: 'function',
|
|
135
|
+
name: 'transferFrom',
|
|
136
|
+
stateMutability: 'nonpayable',
|
|
137
|
+
inputs: [
|
|
138
|
+
{ name: 'from', type: 'address' },
|
|
139
|
+
{ name: 'to', type: 'address' },
|
|
140
|
+
{ name: 'tokenId', type: 'uint256' },
|
|
141
|
+
],
|
|
142
|
+
outputs: [],
|
|
143
|
+
},
|
|
144
|
+
{
|
|
145
|
+
type: 'function',
|
|
146
|
+
name: 'safeTransferFrom',
|
|
147
|
+
stateMutability: 'nonpayable',
|
|
148
|
+
inputs: [
|
|
149
|
+
{ name: 'from', type: 'address' },
|
|
150
|
+
{ name: 'to', type: 'address' },
|
|
151
|
+
{ name: 'tokenId', type: 'uint256' },
|
|
152
|
+
{ name: 'data', type: 'bytes' },
|
|
153
|
+
],
|
|
154
|
+
outputs: [],
|
|
155
|
+
},
|
|
156
|
+
// ── Intelligent Transfer ──
|
|
157
|
+
{
|
|
158
|
+
type: 'function',
|
|
159
|
+
name: 'iTransferFrom',
|
|
160
|
+
stateMutability: 'nonpayable',
|
|
161
|
+
inputs: [
|
|
162
|
+
{ name: 'from', type: 'address' },
|
|
163
|
+
{ name: 'to', type: 'address' },
|
|
164
|
+
{ name: 'tokenId', type: 'uint256' },
|
|
165
|
+
{ name: 'proofs', type: 'tuple[]', components: [
|
|
166
|
+
{ name: 'accessProof', type: 'tuple', components: [
|
|
167
|
+
{ name: 'dataHash', type: 'bytes32' },
|
|
168
|
+
{ name: 'targetPubkey', type: 'bytes' },
|
|
169
|
+
{ name: 'nonce', type: 'bytes' },
|
|
170
|
+
{ name: 'deadline', type: 'uint256' },
|
|
171
|
+
{ name: 'proof', type: 'bytes' },
|
|
172
|
+
] },
|
|
173
|
+
{ name: 'ownershipProof', type: 'tuple', components: [
|
|
174
|
+
{ name: 'oracleType', type: 'uint8' },
|
|
175
|
+
{ name: 'dataHash', type: 'bytes32' },
|
|
176
|
+
{ name: 'sealedKey', type: 'bytes' },
|
|
177
|
+
{ name: 'targetPubkey', type: 'bytes' },
|
|
178
|
+
{ name: 'nonce', type: 'bytes' },
|
|
179
|
+
{ name: 'deadline', type: 'uint256' },
|
|
180
|
+
{ name: 'proof', type: 'bytes' },
|
|
181
|
+
] },
|
|
182
|
+
] },
|
|
183
|
+
],
|
|
184
|
+
outputs: [{ name: '', type: 'tuple[]', components: [
|
|
185
|
+
{ name: 'dataHash', type: 'bytes32' },
|
|
186
|
+
{ name: 'sealedKey', type: 'bytes' },
|
|
187
|
+
] }],
|
|
188
|
+
},
|
|
189
|
+
{
|
|
190
|
+
type: 'function',
|
|
191
|
+
name: 'iCloneFrom',
|
|
192
|
+
stateMutability: 'nonpayable',
|
|
193
|
+
inputs: [
|
|
194
|
+
{ name: 'from', type: 'address' },
|
|
195
|
+
{ name: 'to', type: 'address' },
|
|
196
|
+
{ name: 'tokenId', type: 'uint256' },
|
|
197
|
+
{ name: 'proofs', type: 'tuple[]', components: [
|
|
198
|
+
{ name: 'accessProof', type: 'tuple', components: [
|
|
199
|
+
{ name: 'dataHash', type: 'bytes32' },
|
|
200
|
+
{ name: 'targetPubkey', type: 'bytes' },
|
|
201
|
+
{ name: 'nonce', type: 'bytes' },
|
|
202
|
+
{ name: 'deadline', type: 'uint256' },
|
|
203
|
+
{ name: 'proof', type: 'bytes' },
|
|
204
|
+
] },
|
|
205
|
+
{ name: 'ownershipProof', type: 'tuple', components: [
|
|
206
|
+
{ name: 'oracleType', type: 'uint8' },
|
|
207
|
+
{ name: 'dataHash', type: 'bytes32' },
|
|
208
|
+
{ name: 'sealedKey', type: 'bytes' },
|
|
209
|
+
{ name: 'targetPubkey', type: 'bytes' },
|
|
210
|
+
{ name: 'nonce', type: 'bytes' },
|
|
211
|
+
{ name: 'deadline', type: 'uint256' },
|
|
212
|
+
{ name: 'proof', type: 'bytes' },
|
|
213
|
+
] },
|
|
214
|
+
] },
|
|
215
|
+
],
|
|
216
|
+
outputs: [{ name: 'newTokenId', type: 'uint256' }],
|
|
217
|
+
},
|
|
218
|
+
// ── Update Agent Data ──
|
|
219
|
+
{
|
|
220
|
+
type: 'function',
|
|
221
|
+
name: 'update',
|
|
222
|
+
stateMutability: 'nonpayable',
|
|
223
|
+
inputs: [
|
|
224
|
+
{ name: 'tokenId', type: 'uint256' },
|
|
225
|
+
{ name: 'newDatas', type: 'tuple[]', components: [
|
|
226
|
+
{ name: 'dataDescription', type: 'string' },
|
|
227
|
+
{ name: 'dataHash', type: 'bytes32' },
|
|
228
|
+
] },
|
|
229
|
+
{ name: 'sealedKeys', type: 'bytes[]' },
|
|
230
|
+
],
|
|
231
|
+
outputs: [],
|
|
232
|
+
},
|
|
233
|
+
{
|
|
234
|
+
type: 'function',
|
|
235
|
+
name: 'updateAt',
|
|
236
|
+
stateMutability: 'nonpayable',
|
|
237
|
+
inputs: [
|
|
238
|
+
{ name: 'tokenId', type: 'uint256' },
|
|
239
|
+
{ name: 'index', type: 'uint256' },
|
|
240
|
+
{ name: 'newData', type: 'tuple', components: [
|
|
241
|
+
{ name: 'dataDescription', type: 'string' },
|
|
242
|
+
{ name: 'dataHash', type: 'bytes32' },
|
|
243
|
+
] },
|
|
244
|
+
{ name: 'sealedKey', type: 'bytes' },
|
|
245
|
+
],
|
|
246
|
+
outputs: [],
|
|
247
|
+
},
|
|
248
|
+
// ── Read Agent Data ──
|
|
249
|
+
{
|
|
250
|
+
type: 'function',
|
|
251
|
+
name: 'intelligentDatasOf',
|
|
252
|
+
stateMutability: 'view',
|
|
253
|
+
inputs: [{ name: 'tokenId', type: 'uint256' }],
|
|
254
|
+
outputs: [{ name: '', type: 'tuple[]', components: [
|
|
255
|
+
{ name: 'dataDescription', type: 'string' },
|
|
256
|
+
{ name: 'dataHash', type: 'bytes32' },
|
|
257
|
+
] }],
|
|
258
|
+
},
|
|
259
|
+
{
|
|
260
|
+
type: 'function',
|
|
261
|
+
name: 'sealedKeysOf',
|
|
262
|
+
stateMutability: 'view',
|
|
263
|
+
inputs: [{ name: 'tokenId', type: 'uint256' }],
|
|
264
|
+
outputs: [{ name: '', type: 'bytes[]' }],
|
|
265
|
+
},
|
|
266
|
+
// ── Agent URI ──
|
|
267
|
+
{
|
|
268
|
+
type: 'function',
|
|
269
|
+
name: 'setAgentURI',
|
|
270
|
+
stateMutability: 'nonpayable',
|
|
271
|
+
inputs: [
|
|
272
|
+
{ name: 'agentId', type: 'uint256' },
|
|
273
|
+
{ name: 'newURI', type: 'string' },
|
|
274
|
+
],
|
|
275
|
+
outputs: [],
|
|
276
|
+
},
|
|
277
|
+
// ── Metadata ──
|
|
278
|
+
{
|
|
279
|
+
type: 'function',
|
|
280
|
+
name: 'getMetadata',
|
|
281
|
+
stateMutability: 'view',
|
|
282
|
+
inputs: [
|
|
283
|
+
{ name: 'agentId', type: 'uint256' },
|
|
284
|
+
{ name: 'metadataKey', type: 'string' },
|
|
285
|
+
],
|
|
286
|
+
outputs: [{ name: '', type: 'bytes' }],
|
|
287
|
+
},
|
|
288
|
+
{
|
|
289
|
+
type: 'function',
|
|
290
|
+
name: 'setMetadata',
|
|
291
|
+
stateMutability: 'nonpayable',
|
|
292
|
+
inputs: [
|
|
293
|
+
{ name: 'agentId', type: 'uint256' },
|
|
294
|
+
{ name: 'metadataKey', type: 'string' },
|
|
295
|
+
{ name: 'metadataValue', type: 'bytes' },
|
|
296
|
+
],
|
|
297
|
+
outputs: [],
|
|
298
|
+
},
|
|
299
|
+
// ── Agent Wallet ──
|
|
300
|
+
{
|
|
301
|
+
type: 'function',
|
|
302
|
+
name: 'setAgentWallet',
|
|
303
|
+
stateMutability: 'nonpayable',
|
|
304
|
+
inputs: [
|
|
305
|
+
{ name: 'agentId', type: 'uint256' },
|
|
306
|
+
{ name: 'newWallet', type: 'address' },
|
|
307
|
+
{ name: 'deadline', type: 'uint256' },
|
|
308
|
+
{ name: 'signature', type: 'bytes' },
|
|
309
|
+
],
|
|
310
|
+
outputs: [],
|
|
311
|
+
},
|
|
312
|
+
{
|
|
313
|
+
type: 'function',
|
|
314
|
+
name: 'getAgentWallet',
|
|
315
|
+
stateMutability: 'view',
|
|
316
|
+
inputs: [{ name: 'agentId', type: 'uint256' }],
|
|
317
|
+
outputs: [{ name: '', type: 'address' }],
|
|
318
|
+
},
|
|
319
|
+
{
|
|
320
|
+
type: 'function',
|
|
321
|
+
name: 'unsetAgentWallet',
|
|
322
|
+
stateMutability: 'nonpayable',
|
|
323
|
+
inputs: [{ name: 'agentId', type: 'uint256' }],
|
|
324
|
+
outputs: [],
|
|
325
|
+
},
|
|
326
|
+
// ── Authorization ──
|
|
327
|
+
{
|
|
328
|
+
type: 'function',
|
|
329
|
+
name: 'authorizeUsage',
|
|
330
|
+
stateMutability: 'nonpayable',
|
|
331
|
+
inputs: [
|
|
332
|
+
{ name: 'tokenId', type: 'uint256' },
|
|
333
|
+
{ name: 'user', type: 'address' },
|
|
334
|
+
],
|
|
335
|
+
outputs: [],
|
|
336
|
+
},
|
|
337
|
+
{
|
|
338
|
+
type: 'function',
|
|
339
|
+
name: 'batchAuthorizeUsage',
|
|
340
|
+
stateMutability: 'nonpayable',
|
|
341
|
+
inputs: [
|
|
342
|
+
{ name: 'tokenId', type: 'uint256' },
|
|
343
|
+
{ name: 'users', type: 'address[]' },
|
|
344
|
+
],
|
|
345
|
+
outputs: [],
|
|
346
|
+
},
|
|
347
|
+
{
|
|
348
|
+
type: 'function',
|
|
349
|
+
name: 'revokeAuthorization',
|
|
350
|
+
stateMutability: 'nonpayable',
|
|
351
|
+
inputs: [
|
|
352
|
+
{ name: 'tokenId', type: 'uint256' },
|
|
353
|
+
{ name: 'user', type: 'address' },
|
|
354
|
+
],
|
|
355
|
+
outputs: [],
|
|
356
|
+
},
|
|
357
|
+
{
|
|
358
|
+
type: 'function',
|
|
359
|
+
name: 'clearAuthorizedUsers',
|
|
360
|
+
stateMutability: 'nonpayable',
|
|
361
|
+
inputs: [{ name: 'tokenId', type: 'uint256' }],
|
|
362
|
+
outputs: [],
|
|
363
|
+
},
|
|
364
|
+
{
|
|
365
|
+
type: 'function',
|
|
366
|
+
name: 'authorizedUsersOf',
|
|
367
|
+
stateMutability: 'view',
|
|
368
|
+
inputs: [{ name: 'tokenId', type: 'uint256' }],
|
|
369
|
+
outputs: [{ name: '', type: 'address[]' }],
|
|
370
|
+
},
|
|
371
|
+
// ── Access Delegate ──
|
|
372
|
+
{
|
|
373
|
+
type: 'function',
|
|
374
|
+
name: 'setAccessDelegate',
|
|
375
|
+
stateMutability: 'nonpayable',
|
|
376
|
+
inputs: [{ name: 'delegate', type: 'address' }],
|
|
377
|
+
outputs: [],
|
|
378
|
+
},
|
|
379
|
+
{
|
|
380
|
+
type: 'function',
|
|
381
|
+
name: 'getAccessDelegate',
|
|
382
|
+
stateMutability: 'view',
|
|
383
|
+
inputs: [{ name: 'user', type: 'address' }],
|
|
384
|
+
outputs: [{ name: '', type: 'address' }],
|
|
385
|
+
},
|
|
386
|
+
// ── ERC-721 Standard ──
|
|
387
|
+
{
|
|
388
|
+
type: 'function',
|
|
389
|
+
name: 'ownerOf',
|
|
390
|
+
stateMutability: 'view',
|
|
391
|
+
inputs: [{ name: 'tokenId', type: 'uint256' }],
|
|
392
|
+
outputs: [{ name: '', type: 'address' }],
|
|
393
|
+
},
|
|
394
|
+
{
|
|
395
|
+
type: 'function',
|
|
396
|
+
name: 'getApproved',
|
|
397
|
+
stateMutability: 'view',
|
|
398
|
+
inputs: [{ name: 'tokenId', type: 'uint256' }],
|
|
399
|
+
outputs: [{ name: '', type: 'address' }],
|
|
400
|
+
},
|
|
401
|
+
{
|
|
402
|
+
type: 'function',
|
|
403
|
+
name: 'isApprovedForAll',
|
|
404
|
+
stateMutability: 'view',
|
|
405
|
+
inputs: [
|
|
406
|
+
{ name: 'owner', type: 'address' },
|
|
407
|
+
{ name: 'operator', type: 'address' },
|
|
408
|
+
],
|
|
409
|
+
outputs: [{ name: '', type: 'bool' }],
|
|
410
|
+
},
|
|
411
|
+
{
|
|
412
|
+
type: 'function',
|
|
413
|
+
name: 'balanceOf',
|
|
414
|
+
stateMutability: 'view',
|
|
415
|
+
inputs: [{ name: 'owner', type: 'address' }],
|
|
416
|
+
outputs: [{ name: '', type: 'uint256' }],
|
|
417
|
+
},
|
|
418
|
+
// ── Pause ──
|
|
419
|
+
{
|
|
420
|
+
type: 'function',
|
|
421
|
+
name: 'pause',
|
|
422
|
+
stateMutability: 'nonpayable',
|
|
423
|
+
inputs: [],
|
|
424
|
+
outputs: [],
|
|
425
|
+
},
|
|
426
|
+
{
|
|
427
|
+
type: 'function',
|
|
428
|
+
name: 'unpause',
|
|
429
|
+
stateMutability: 'nonpayable',
|
|
430
|
+
inputs: [],
|
|
431
|
+
outputs: [],
|
|
432
|
+
},
|
|
433
|
+
{
|
|
434
|
+
type: 'function',
|
|
435
|
+
name: 'pauser',
|
|
436
|
+
stateMutability: 'view',
|
|
437
|
+
inputs: [],
|
|
438
|
+
outputs: [{ name: '', type: 'address' }],
|
|
439
|
+
},
|
|
440
|
+
{
|
|
441
|
+
type: 'function',
|
|
442
|
+
name: 'setPauser',
|
|
443
|
+
stateMutability: 'nonpayable',
|
|
444
|
+
inputs: [{ name: 'newPauser', type: 'address' }],
|
|
445
|
+
outputs: [],
|
|
446
|
+
},
|
|
447
|
+
{
|
|
448
|
+
type: 'function',
|
|
449
|
+
name: 'setVerifier',
|
|
450
|
+
stateMutability: 'nonpayable',
|
|
451
|
+
inputs: [{ name: 'newVerifier', type: 'address' }],
|
|
452
|
+
outputs: [],
|
|
453
|
+
},
|
|
454
|
+
// ── Events ──
|
|
455
|
+
// Registration has no AgenticID-local event: watch the ERC-721 `Transfer`
|
|
456
|
+
// (from zero) below, plus `AgentSealSet`; the canonical identity registry
|
|
457
|
+
// emits its own `Registered`.
|
|
458
|
+
{
|
|
459
|
+
type: 'event',
|
|
460
|
+
name: 'AgentSealSet',
|
|
461
|
+
inputs: [
|
|
462
|
+
{ name: 'agentId', type: 'uint256', indexed: true },
|
|
463
|
+
{ name: 'agentSeal', type: 'address', indexed: true },
|
|
464
|
+
{ name: 'sealId', type: 'bytes32', indexed: true },
|
|
465
|
+
],
|
|
466
|
+
},
|
|
467
|
+
{
|
|
468
|
+
type: 'event',
|
|
469
|
+
name: 'Updated',
|
|
470
|
+
inputs: [
|
|
471
|
+
{ name: 'tokenId', type: 'uint256', indexed: true },
|
|
472
|
+
{ name: 'oldDatas', type: 'tuple[]', indexed: false, components: [
|
|
473
|
+
{ name: 'dataDescription', type: 'string' },
|
|
474
|
+
{ name: 'dataHash', type: 'bytes32' },
|
|
475
|
+
] },
|
|
476
|
+
{ name: 'newDatas', type: 'tuple[]', indexed: false, components: [
|
|
477
|
+
{ name: 'dataDescription', type: 'string' },
|
|
478
|
+
{ name: 'dataHash', type: 'bytes32' },
|
|
479
|
+
] },
|
|
480
|
+
{ name: 'sealedKeys', type: 'bytes[]', indexed: false },
|
|
481
|
+
],
|
|
482
|
+
},
|
|
483
|
+
{
|
|
484
|
+
type: 'event',
|
|
485
|
+
name: 'Transfer',
|
|
486
|
+
inputs: [
|
|
487
|
+
{ name: 'from', type: 'address', indexed: true },
|
|
488
|
+
{ name: 'to', type: 'address', indexed: true },
|
|
489
|
+
{ name: 'tokenId', type: 'uint256', indexed: true },
|
|
490
|
+
],
|
|
491
|
+
},
|
|
492
|
+
{
|
|
493
|
+
type: 'event',
|
|
494
|
+
name: 'Paused',
|
|
495
|
+
inputs: [{ name: 'account', type: 'address', indexed: false }],
|
|
496
|
+
},
|
|
497
|
+
{
|
|
498
|
+
type: 'event',
|
|
499
|
+
name: 'Unpaused',
|
|
500
|
+
inputs: [{ name: 'account', type: 'address', indexed: false }],
|
|
501
|
+
},
|
|
502
|
+
];
|
|
503
|
+
/**
|
|
504
|
+
* Official canonical ERC-8004 ReputationRegistry (the fixed 0x8004B… singleton;
|
|
505
|
+
* v2.0.0). Feedback STORAGE lives here — clients call `giveFeedback` directly,
|
|
506
|
+
* so attribution is native msg.sender and every 8004 reader sees it. It has no
|
|
507
|
+
* ServeProof parameter and no custom errors (plain require strings).
|
|
508
|
+
* TEE verification marks live in the separate VerifiedFeedbackRegistry
|
|
509
|
+
* (`verifiedFeedbackAbi` below).
|
|
510
|
+
*/
|
|
511
|
+
exports.canonicalReputationAbi = [
|
|
512
|
+
// ── Give Feedback (canonical 8-arg form, attribution = msg.sender) ──
|
|
513
|
+
{
|
|
514
|
+
type: 'function',
|
|
515
|
+
name: 'giveFeedback',
|
|
516
|
+
stateMutability: 'nonpayable',
|
|
517
|
+
inputs: [
|
|
518
|
+
{ name: 'agentId', type: 'uint256' },
|
|
519
|
+
{ name: 'value', type: 'int128' },
|
|
520
|
+
{ name: 'valueDecimals', type: 'uint8' },
|
|
521
|
+
{ name: 'tag1', type: 'string' },
|
|
522
|
+
{ name: 'tag2', type: 'string' },
|
|
523
|
+
{ name: 'endpoint', type: 'string' },
|
|
524
|
+
{ name: 'feedbackURI', type: 'string' },
|
|
525
|
+
{ name: 'feedbackHash', type: 'bytes32' },
|
|
526
|
+
],
|
|
527
|
+
outputs: [],
|
|
528
|
+
},
|
|
529
|
+
// ── Revoke Feedback ──
|
|
530
|
+
{
|
|
531
|
+
type: 'function',
|
|
532
|
+
name: 'revokeFeedback',
|
|
533
|
+
stateMutability: 'nonpayable',
|
|
534
|
+
inputs: [
|
|
535
|
+
{ name: 'agentId', type: 'uint256' },
|
|
536
|
+
{ name: 'feedbackIndex', type: 'uint64' },
|
|
537
|
+
],
|
|
538
|
+
outputs: [],
|
|
539
|
+
},
|
|
540
|
+
// ── Append Response ──
|
|
541
|
+
{
|
|
542
|
+
type: 'function',
|
|
543
|
+
name: 'appendResponse',
|
|
544
|
+
stateMutability: 'nonpayable',
|
|
545
|
+
inputs: [
|
|
546
|
+
{ name: 'agentId', type: 'uint256' },
|
|
547
|
+
{ name: 'clientAddress', type: 'address' },
|
|
548
|
+
{ name: 'feedbackIndex', type: 'uint64' },
|
|
549
|
+
{ name: 'responseURI', type: 'string' },
|
|
550
|
+
{ name: 'responseHash', type: 'bytes32' },
|
|
551
|
+
],
|
|
552
|
+
outputs: [],
|
|
553
|
+
},
|
|
554
|
+
// ── Read Feedback ──
|
|
555
|
+
{
|
|
556
|
+
type: 'function',
|
|
557
|
+
name: 'readFeedback',
|
|
558
|
+
stateMutability: 'view',
|
|
559
|
+
inputs: [
|
|
560
|
+
{ name: 'agentId', type: 'uint256' },
|
|
561
|
+
{ name: 'clientAddress', type: 'address' },
|
|
562
|
+
{ name: 'feedbackIndex', type: 'uint64' },
|
|
563
|
+
],
|
|
564
|
+
outputs: [
|
|
565
|
+
{ name: 'value', type: 'int128' },
|
|
566
|
+
{ name: 'valueDecimals', type: 'uint8' },
|
|
567
|
+
{ name: 'tag1', type: 'string' },
|
|
568
|
+
{ name: 'tag2', type: 'string' },
|
|
569
|
+
{ name: 'isRevoked', type: 'bool' },
|
|
570
|
+
],
|
|
571
|
+
},
|
|
572
|
+
// ── Read All Feedback ──
|
|
573
|
+
{
|
|
574
|
+
type: 'function',
|
|
575
|
+
name: 'readAllFeedback',
|
|
576
|
+
stateMutability: 'view',
|
|
577
|
+
inputs: [
|
|
578
|
+
{ name: 'agentId', type: 'uint256' },
|
|
579
|
+
{ name: 'clientAddresses', type: 'address[]' },
|
|
580
|
+
{ name: 'tag1', type: 'string' },
|
|
581
|
+
{ name: 'tag2', type: 'string' },
|
|
582
|
+
{ name: 'includeRevoked', type: 'bool' },
|
|
583
|
+
],
|
|
584
|
+
outputs: [
|
|
585
|
+
{ name: 'clients', type: 'address[]' },
|
|
586
|
+
{ name: 'feedbackIndexes', type: 'uint64[]' },
|
|
587
|
+
{ name: 'values', type: 'int128[]' },
|
|
588
|
+
{ name: 'valueDecimals', type: 'uint8[]' },
|
|
589
|
+
{ name: 'tag1s', type: 'string[]' },
|
|
590
|
+
{ name: 'tag2s', type: 'string[]' },
|
|
591
|
+
{ name: 'revokedStatuses', type: 'bool[]' },
|
|
592
|
+
],
|
|
593
|
+
},
|
|
594
|
+
// ── Get Summary ──
|
|
595
|
+
{
|
|
596
|
+
type: 'function',
|
|
597
|
+
name: 'getSummary',
|
|
598
|
+
stateMutability: 'view',
|
|
599
|
+
inputs: [
|
|
600
|
+
{ name: 'agentId', type: 'uint256' },
|
|
601
|
+
{ name: 'clientAddresses', type: 'address[]' },
|
|
602
|
+
{ name: 'tag1', type: 'string' },
|
|
603
|
+
{ name: 'tag2', type: 'string' },
|
|
604
|
+
],
|
|
605
|
+
outputs: [
|
|
606
|
+
{ name: 'count', type: 'uint64' },
|
|
607
|
+
{ name: 'summaryValue', type: 'int128' },
|
|
608
|
+
{ name: 'summaryValueDecimals', type: 'uint8' },
|
|
609
|
+
],
|
|
610
|
+
},
|
|
611
|
+
// ── Get Response Count ──
|
|
612
|
+
{
|
|
613
|
+
type: 'function',
|
|
614
|
+
name: 'getResponseCount',
|
|
615
|
+
stateMutability: 'view',
|
|
616
|
+
inputs: [
|
|
617
|
+
{ name: 'agentId', type: 'uint256' },
|
|
618
|
+
{ name: 'clientAddress', type: 'address' },
|
|
619
|
+
{ name: 'feedbackIndex', type: 'uint64' },
|
|
620
|
+
{ name: 'responders', type: 'address[]' },
|
|
621
|
+
],
|
|
622
|
+
outputs: [{ name: 'count', type: 'uint64' }],
|
|
623
|
+
},
|
|
624
|
+
// ── Get Clients ──
|
|
625
|
+
{
|
|
626
|
+
type: 'function',
|
|
627
|
+
name: 'getClients',
|
|
628
|
+
stateMutability: 'view',
|
|
629
|
+
inputs: [{ name: 'agentId', type: 'uint256' }],
|
|
630
|
+
outputs: [{ name: '', type: 'address[]' }],
|
|
631
|
+
},
|
|
632
|
+
// ── Get Last Index ──
|
|
633
|
+
{
|
|
634
|
+
type: 'function',
|
|
635
|
+
name: 'getLastIndex',
|
|
636
|
+
stateMutability: 'view',
|
|
637
|
+
inputs: [
|
|
638
|
+
{ name: 'agentId', type: 'uint256' },
|
|
639
|
+
{ name: 'clientAddress', type: 'address' },
|
|
640
|
+
],
|
|
641
|
+
outputs: [{ name: '', type: 'uint64' }],
|
|
642
|
+
},
|
|
643
|
+
// ── Environment sanity reads ──
|
|
644
|
+
{
|
|
645
|
+
type: 'function',
|
|
646
|
+
name: 'getIdentityRegistry',
|
|
647
|
+
stateMutability: 'view',
|
|
648
|
+
inputs: [],
|
|
649
|
+
outputs: [{ name: '', type: 'address' }],
|
|
650
|
+
},
|
|
651
|
+
{
|
|
652
|
+
type: 'function',
|
|
653
|
+
name: 'getVersion',
|
|
654
|
+
stateMutability: 'pure',
|
|
655
|
+
inputs: [],
|
|
656
|
+
outputs: [{ name: '', type: 'string' }],
|
|
657
|
+
},
|
|
658
|
+
// ── Events (canonical v2.0.0 shapes) ──
|
|
659
|
+
{
|
|
660
|
+
type: 'event',
|
|
661
|
+
name: 'NewFeedback',
|
|
662
|
+
inputs: [
|
|
663
|
+
{ name: 'agentId', type: 'uint256', indexed: true },
|
|
664
|
+
{ name: 'clientAddress', type: 'address', indexed: true },
|
|
665
|
+
{ name: 'feedbackIndex', type: 'uint64', indexed: false },
|
|
666
|
+
{ name: 'value', type: 'int128', indexed: false },
|
|
667
|
+
{ name: 'valueDecimals', type: 'uint8', indexed: false },
|
|
668
|
+
{ name: 'indexedTag1', type: 'string', indexed: true },
|
|
669
|
+
{ name: 'tag1', type: 'string', indexed: false },
|
|
670
|
+
{ name: 'tag2', type: 'string', indexed: false },
|
|
671
|
+
{ name: 'endpoint', type: 'string', indexed: false },
|
|
672
|
+
{ name: 'feedbackURI', type: 'string', indexed: false },
|
|
673
|
+
{ name: 'feedbackHash', type: 'bytes32', indexed: false },
|
|
674
|
+
],
|
|
675
|
+
},
|
|
676
|
+
{
|
|
677
|
+
type: 'event',
|
|
678
|
+
name: 'FeedbackRevoked',
|
|
679
|
+
inputs: [
|
|
680
|
+
{ name: 'agentId', type: 'uint256', indexed: true },
|
|
681
|
+
{ name: 'clientAddress', type: 'address', indexed: true },
|
|
682
|
+
{ name: 'feedbackIndex', type: 'uint64', indexed: true },
|
|
683
|
+
],
|
|
684
|
+
},
|
|
685
|
+
{
|
|
686
|
+
type: 'event',
|
|
687
|
+
name: 'ResponseAppended',
|
|
688
|
+
inputs: [
|
|
689
|
+
{ name: 'agentId', type: 'uint256', indexed: true },
|
|
690
|
+
{ name: 'clientAddress', type: 'address', indexed: true },
|
|
691
|
+
{ name: 'feedbackIndex', type: 'uint64', indexed: false },
|
|
692
|
+
{ name: 'responder', type: 'address', indexed: true },
|
|
693
|
+
{ name: 'responseURI', type: 'string', indexed: false },
|
|
694
|
+
{ name: 'responseHash', type: 'bytes32', indexed: false },
|
|
695
|
+
],
|
|
696
|
+
},
|
|
697
|
+
];
|
|
698
|
+
/**
|
|
699
|
+
* VerifiedFeedbackRegistry — the local TEE-verification layer over the
|
|
700
|
+
* canonical ERC-8004 ReputationRegistry. `attestFeedback` marks a canonical
|
|
701
|
+
* entry as backed by a ServeProof; the `getVerified*` reads expose the marks
|
|
702
|
+
* so readers can intersect them with canonical entries.
|
|
703
|
+
*/
|
|
704
|
+
exports.verifiedFeedbackAbi = [
|
|
705
|
+
// Custom errors — so viem decodes reverts instead of showing a 4-byte selector.
|
|
706
|
+
{ "type": "error", "name": "ECDSAInvalidSignature", "inputs": [] },
|
|
707
|
+
{ "type": "error", "name": "ECDSAInvalidSignatureLength", "inputs": [{ "name": "length", "type": "uint256" }] },
|
|
708
|
+
{ "type": "error", "name": "ECDSAInvalidSignatureS", "inputs": [{ "name": "s", "type": "bytes32" }] },
|
|
709
|
+
{ "type": "error", "name": "EnforcedPause", "inputs": [] },
|
|
710
|
+
{ "type": "error", "name": "ExpectedPause", "inputs": [] },
|
|
711
|
+
{ "type": "error", "name": "InvalidInitialization", "inputs": [] },
|
|
712
|
+
{ "type": "error", "name": "NonceAlreadyUsed", "inputs": [{ "name": "key", "type": "bytes32" }] },
|
|
713
|
+
{ "type": "error", "name": "NonceDeadlineTooFar", "inputs": [{ "name": "deadline", "type": "uint256" }, { "name": "maxDeadline", "type": "uint256" }] },
|
|
714
|
+
{ "type": "error", "name": "NonceExpired", "inputs": [{ "name": "deadline", "type": "uint256" }, { "name": "nowTimestamp", "type": "uint256" }] },
|
|
715
|
+
{ "type": "error", "name": "NonceMaxAgeDecrease", "inputs": [{ "name": "currentMaxAge", "type": "uint256" }, { "name": "newMaxAge", "type": "uint256" }] },
|
|
716
|
+
{ "type": "error", "name": "NonceMaxAgeOutOfRange", "inputs": [{ "name": "maxAge", "type": "uint256" }] },
|
|
717
|
+
{ "type": "error", "name": "NotInitializing", "inputs": [] },
|
|
718
|
+
{ "type": "error", "name": "OwnableInvalidOwner", "inputs": [{ "name": "owner", "type": "address" }] },
|
|
719
|
+
{ "type": "error", "name": "OwnableUnauthorizedAccount", "inputs": [{ "name": "account", "type": "address" }] },
|
|
720
|
+
{ "type": "error", "name": "VerifiedFeedbackAlreadyVerified", "inputs": [{ "name": "agentId", "type": "uint256" }, { "name": "clientAddress", "type": "address" }, { "name": "feedbackIndex", "type": "uint64" }] },
|
|
721
|
+
{ "type": "error", "name": "VerifiedFeedbackClientsRequired", "inputs": [] },
|
|
722
|
+
{ "type": "error", "name": "VerifiedFeedbackInvalidProofSignature", "inputs": [] },
|
|
723
|
+
{ "type": "error", "name": "VerifiedFeedbackNoAgentSeal", "inputs": [] },
|
|
724
|
+
{ "type": "error", "name": "VerifiedFeedbackNoSuchEntry", "inputs": [{ "name": "agentId", "type": "uint256" }, { "name": "clientAddress", "type": "address" }, { "name": "feedbackIndex", "type": "uint64" }, { "name": "lastIndex", "type": "uint64" }] },
|
|
725
|
+
{ "type": "error", "name": "VerifiedFeedbackNotPauser", "inputs": [] },
|
|
726
|
+
{ "type": "error", "name": "VerifiedFeedbackNotVerified", "inputs": [{ "name": "agentId", "type": "uint256" }, { "name": "clientAddress", "type": "address" }, { "name": "feedbackIndex", "type": "uint64" }] },
|
|
727
|
+
{ "type": "error", "name": "VerifiedFeedbackProofAgentMismatch", "inputs": [{ "name": "agentId", "type": "uint256" }, { "name": "proofAgentId", "type": "uint256" }] },
|
|
728
|
+
{ "type": "error", "name": "VerifiedFeedbackProofSubmitterMismatch", "inputs": [{ "name": "submitter", "type": "address" }, { "name": "sender", "type": "address" }] },
|
|
729
|
+
{ "type": "error", "name": "VerifiedFeedbackSelfFeedback", "inputs": [{ "name": "agentId", "type": "uint256" }, { "name": "submitter", "type": "address" }] },
|
|
730
|
+
{ "type": "error", "name": "VerifiedFeedbackSummaryOverflow", "inputs": [] },
|
|
731
|
+
{ "type": "error", "name": "VerifiedFeedbackTaskMismatch", "inputs": [{ "name": "expected", "type": "bytes32" }, { "name": "actual", "type": "bytes32" }] },
|
|
732
|
+
{ "type": "error", "name": "VerifiedFeedbackInvalidTaskReveal", "inputs": [] },
|
|
733
|
+
{ "type": "error", "name": "VerifiedFeedbackValueOutOfRange", "inputs": [{ "name": "value", "type": "int128" }, { "name": "valueDecimals", "type": "uint8" }] },
|
|
734
|
+
{ "type": "error", "name": "VerifiedFeedbackEndpointRequired", "inputs": [] },
|
|
735
|
+
{ "type": "error", "name": "VerifiedFeedbackInvalidProofTimestamp", "inputs": [] },
|
|
736
|
+
// ── Attest ──
|
|
737
|
+
{
|
|
738
|
+
type: 'function',
|
|
739
|
+
name: 'attestFeedback',
|
|
740
|
+
stateMutability: 'nonpayable',
|
|
741
|
+
inputs: [
|
|
742
|
+
{ name: 'agentId', type: 'uint256' },
|
|
743
|
+
{ name: 'feedbackIndex', type: 'uint64' },
|
|
744
|
+
{ name: 'proof', type: 'tuple', components: [
|
|
745
|
+
{ name: 'agentId', type: 'uint256' },
|
|
746
|
+
{ name: 'submitter', type: 'address' },
|
|
747
|
+
{ name: 'timestamp', type: 'uint256' },
|
|
748
|
+
{ name: 'deadline', type: 'uint256' },
|
|
749
|
+
{ name: 'taskHash', type: 'bytes32' },
|
|
750
|
+
{ name: 'dataHashes', type: 'bytes32[]' },
|
|
751
|
+
{ name: 'frameworkHash', type: 'bytes32' },
|
|
752
|
+
{ name: 'signature', type: 'bytes' },
|
|
753
|
+
] },
|
|
754
|
+
],
|
|
755
|
+
outputs: [],
|
|
756
|
+
},
|
|
757
|
+
{
|
|
758
|
+
type: 'function',
|
|
759
|
+
name: 'attestFeedbackWithTask',
|
|
760
|
+
stateMutability: 'nonpayable',
|
|
761
|
+
inputs: [
|
|
762
|
+
{ name: 'agentId', type: 'uint256' },
|
|
763
|
+
{ name: 'feedbackIndex', type: 'uint64' },
|
|
764
|
+
{ name: 'proof', type: 'tuple', components: [
|
|
765
|
+
{ name: 'agentId', type: 'uint256' },
|
|
766
|
+
{ name: 'submitter', type: 'address' },
|
|
767
|
+
{ name: 'timestamp', type: 'uint256' },
|
|
768
|
+
{ name: 'deadline', type: 'uint256' },
|
|
769
|
+
{ name: 'taskHash', type: 'bytes32' },
|
|
770
|
+
{ name: 'dataHashes', type: 'bytes32[]' },
|
|
771
|
+
{ name: 'frameworkHash', type: 'bytes32' },
|
|
772
|
+
{ name: 'signature', type: 'bytes' },
|
|
773
|
+
] },
|
|
774
|
+
{ name: 'task', type: 'tuple', components: [
|
|
775
|
+
{ name: 'method', type: 'string' },
|
|
776
|
+
{ name: 'uri', type: 'string' },
|
|
777
|
+
{ name: 'reqBodyHash', type: 'bytes32' },
|
|
778
|
+
{ name: 'respBodyHash', type: 'bytes32' },
|
|
779
|
+
{ name: 'statusCode', type: 'uint16' },
|
|
780
|
+
] },
|
|
781
|
+
],
|
|
782
|
+
outputs: [],
|
|
783
|
+
},
|
|
784
|
+
// ── Reads ──
|
|
785
|
+
{
|
|
786
|
+
type: 'function',
|
|
787
|
+
name: 'isVerified',
|
|
788
|
+
stateMutability: 'view',
|
|
789
|
+
inputs: [
|
|
790
|
+
{ name: 'agentId', type: 'uint256' },
|
|
791
|
+
{ name: 'clientAddress', type: 'address' },
|
|
792
|
+
{ name: 'feedbackIndex', type: 'uint64' },
|
|
793
|
+
],
|
|
794
|
+
outputs: [{ name: '', type: 'bool' }],
|
|
795
|
+
},
|
|
796
|
+
{
|
|
797
|
+
type: 'function',
|
|
798
|
+
name: 'getServeData',
|
|
799
|
+
stateMutability: 'view',
|
|
800
|
+
inputs: [
|
|
801
|
+
{ name: 'agentId', type: 'uint256' },
|
|
802
|
+
{ name: 'clientAddress', type: 'address' },
|
|
803
|
+
{ name: 'feedbackIndex', type: 'uint64' },
|
|
804
|
+
],
|
|
805
|
+
outputs: [
|
|
806
|
+
{ name: 'dataHashes', type: 'bytes32[]' },
|
|
807
|
+
{ name: 'frameworkHash', type: 'bytes32' },
|
|
808
|
+
],
|
|
809
|
+
},
|
|
810
|
+
{
|
|
811
|
+
type: 'function',
|
|
812
|
+
name: 'getVerifiedIndexes',
|
|
813
|
+
stateMutability: 'view',
|
|
814
|
+
inputs: [
|
|
815
|
+
{ name: 'agentId', type: 'uint256' },
|
|
816
|
+
{ name: 'clientAddress', type: 'address' },
|
|
817
|
+
],
|
|
818
|
+
outputs: [{ name: '', type: 'uint64[]' }],
|
|
819
|
+
},
|
|
820
|
+
{
|
|
821
|
+
type: 'function',
|
|
822
|
+
name: 'getVerifiedClients',
|
|
823
|
+
stateMutability: 'view',
|
|
824
|
+
inputs: [{ name: 'agentId', type: 'uint256' }],
|
|
825
|
+
outputs: [{ name: '', type: 'address[]' }],
|
|
826
|
+
},
|
|
827
|
+
{
|
|
828
|
+
type: 'function',
|
|
829
|
+
name: 'getVerifiedEndpoint',
|
|
830
|
+
stateMutability: 'view',
|
|
831
|
+
inputs: [
|
|
832
|
+
{ name: 'agentId', type: 'uint256' },
|
|
833
|
+
{ name: 'clientAddress', type: 'address' },
|
|
834
|
+
{ name: 'feedbackIndex', type: 'uint64' },
|
|
835
|
+
],
|
|
836
|
+
outputs: [{ name: '', type: 'string' }],
|
|
837
|
+
},
|
|
838
|
+
{
|
|
839
|
+
type: 'function',
|
|
840
|
+
name: 'getVerifiedSummaryForEndpoint',
|
|
841
|
+
stateMutability: 'view',
|
|
842
|
+
inputs: [
|
|
843
|
+
{ name: 'agentId', type: 'uint256' },
|
|
844
|
+
{ name: 'clientAddresses', type: 'address[]' },
|
|
845
|
+
{ name: 'uri', type: 'string' },
|
|
846
|
+
],
|
|
847
|
+
outputs: [
|
|
848
|
+
{ name: 'count', type: 'uint64' },
|
|
849
|
+
{ name: 'summaryValue', type: 'int128' },
|
|
850
|
+
{ name: 'summaryValueDecimals', type: 'uint8' },
|
|
851
|
+
],
|
|
852
|
+
},
|
|
853
|
+
{
|
|
854
|
+
type: 'function',
|
|
855
|
+
name: 'getVerifiedSummary',
|
|
856
|
+
stateMutability: 'view',
|
|
857
|
+
inputs: [
|
|
858
|
+
{ name: 'agentId', type: 'uint256' },
|
|
859
|
+
{ name: 'clientAddresses', type: 'address[]' },
|
|
860
|
+
{ name: 'tag1', type: 'string' },
|
|
861
|
+
{ name: 'tag2', type: 'string' },
|
|
862
|
+
],
|
|
863
|
+
outputs: [
|
|
864
|
+
{ name: 'count', type: 'uint64' },
|
|
865
|
+
{ name: 'summaryValue', type: 'int128' },
|
|
866
|
+
{ name: 'summaryValueDecimals', type: 'uint8' },
|
|
867
|
+
],
|
|
868
|
+
},
|
|
869
|
+
{
|
|
870
|
+
type: 'function',
|
|
871
|
+
name: 'getIdentityRegistry',
|
|
872
|
+
stateMutability: 'view',
|
|
873
|
+
inputs: [],
|
|
874
|
+
outputs: [{ name: '', type: 'address' }],
|
|
875
|
+
},
|
|
876
|
+
{
|
|
877
|
+
type: 'function',
|
|
878
|
+
name: 'getCanonicalReputation',
|
|
879
|
+
stateMutability: 'view',
|
|
880
|
+
inputs: [],
|
|
881
|
+
outputs: [{ name: '', type: 'address' }],
|
|
882
|
+
},
|
|
883
|
+
// NonceRegistry view: a ServeProof's nonce key is
|
|
884
|
+
// keccak256(abi.encode(keccak256("SERVEPROOF"), agentId, signature)).
|
|
885
|
+
{
|
|
886
|
+
type: 'function',
|
|
887
|
+
name: 'isNonceConsumed',
|
|
888
|
+
stateMutability: 'view',
|
|
889
|
+
inputs: [{ name: 'key', type: 'bytes32' }],
|
|
890
|
+
outputs: [{ name: '', type: 'bool' }],
|
|
891
|
+
},
|
|
892
|
+
// ── Events ──
|
|
893
|
+
{
|
|
894
|
+
type: 'event',
|
|
895
|
+
name: 'FeedbackVerified',
|
|
896
|
+
inputs: [
|
|
897
|
+
{ name: 'agentId', type: 'uint256', indexed: true },
|
|
898
|
+
{ name: 'clientAddress', type: 'address', indexed: true },
|
|
899
|
+
{ name: 'feedbackIndex', type: 'uint64', indexed: true },
|
|
900
|
+
{ name: 'dataHashes', type: 'bytes32[]', indexed: false },
|
|
901
|
+
{ name: 'frameworkHash', type: 'bytes32', indexed: false },
|
|
902
|
+
{ name: 'taskHash', type: 'bytes32', indexed: false },
|
|
903
|
+
{ name: 'uri', type: 'string', indexed: false },
|
|
904
|
+
],
|
|
905
|
+
},
|
|
906
|
+
];
|
|
907
|
+
/**
|
|
908
|
+
* FeedbackBatcher — EIP-7702 delegate target. A client EOA attaches this code
|
|
909
|
+
* to itself (type-4 authorization) and self-calls to execute the canonical
|
|
910
|
+
* giveFeedback + attestFeedback pair atomically, with msg.sender = the EOA
|
|
911
|
+
* for both inner calls.
|
|
912
|
+
*/
|
|
913
|
+
exports.feedbackBatcherAbi = [
|
|
914
|
+
{ "type": "error", "name": "BatcherNotSelf", "inputs": [] },
|
|
915
|
+
{
|
|
916
|
+
type: 'function',
|
|
917
|
+
name: 'giveFeedbackAndAttest',
|
|
918
|
+
stateMutability: 'nonpayable',
|
|
919
|
+
inputs: [
|
|
920
|
+
{ name: 'agentId', type: 'uint256' },
|
|
921
|
+
{ name: 'value', type: 'int128' },
|
|
922
|
+
{ name: 'valueDecimals', type: 'uint8' },
|
|
923
|
+
{ name: 'tag1', type: 'string' },
|
|
924
|
+
{ name: 'tag2', type: 'string' },
|
|
925
|
+
{ name: 'endpoint', type: 'string' },
|
|
926
|
+
{ name: 'feedbackURI', type: 'string' },
|
|
927
|
+
{ name: 'feedbackHash', type: 'bytes32' },
|
|
928
|
+
{ name: 'proof', type: 'tuple', components: [
|
|
929
|
+
{ name: 'agentId', type: 'uint256' },
|
|
930
|
+
{ name: 'submitter', type: 'address' },
|
|
931
|
+
{ name: 'timestamp', type: 'uint256' },
|
|
932
|
+
{ name: 'deadline', type: 'uint256' },
|
|
933
|
+
{ name: 'taskHash', type: 'bytes32' },
|
|
934
|
+
{ name: 'dataHashes', type: 'bytes32[]' },
|
|
935
|
+
{ name: 'frameworkHash', type: 'bytes32' },
|
|
936
|
+
{ name: 'signature', type: 'bytes' },
|
|
937
|
+
] },
|
|
938
|
+
{ name: 'task', type: 'tuple', components: [
|
|
939
|
+
{ name: 'method', type: 'string' },
|
|
940
|
+
{ name: 'uri', type: 'string' },
|
|
941
|
+
{ name: 'reqBodyHash', type: 'bytes32' },
|
|
942
|
+
{ name: 'respBodyHash', type: 'bytes32' },
|
|
943
|
+
{ name: 'statusCode', type: 'uint16' },
|
|
944
|
+
] },
|
|
945
|
+
],
|
|
946
|
+
outputs: [{ name: 'feedbackIndex', type: 'uint64' }],
|
|
947
|
+
},
|
|
948
|
+
{
|
|
949
|
+
type: 'function',
|
|
950
|
+
name: 'canonicalReputation',
|
|
951
|
+
stateMutability: 'view',
|
|
952
|
+
inputs: [],
|
|
953
|
+
outputs: [{ name: '', type: 'address' }],
|
|
954
|
+
},
|
|
955
|
+
{
|
|
956
|
+
type: 'function',
|
|
957
|
+
name: 'verifiedFeedback',
|
|
958
|
+
stateMutability: 'view',
|
|
959
|
+
inputs: [],
|
|
960
|
+
outputs: [{ name: '', type: 'address' }],
|
|
961
|
+
},
|
|
962
|
+
];
|
|
963
|
+
/**
|
|
964
|
+
* CloneGate — policy-mode cloning SATELLITE of AgenticID (the core contract
|
|
965
|
+
* sits at the EIP-170 bytecode ceiling; clone policy + lineage live here).
|
|
966
|
+
* The owner opts in with setCloneAuthorizer; the attestor mints through
|
|
967
|
+
* cloneFrom, which consults the policy atomically. cloneAuthorizerOf returns
|
|
968
|
+
* the EFFECTIVE authorizer: 0 when unset, cleared, or auto-invalidated by an
|
|
969
|
+
* ownership transfer since it was set.
|
|
970
|
+
*/
|
|
971
|
+
exports.cloneGateAbi = [
|
|
972
|
+
{ "type": "error", "name": "CloneGateNotTrustedAttestor", "inputs": [] },
|
|
973
|
+
{ "type": "error", "name": "CloneGateNotTokenOwner", "inputs": [{ "name": "caller", "type": "address" }, { "name": "tokenId", "type": "uint256" }, { "name": "owner", "type": "address" }] },
|
|
974
|
+
{ "type": "error", "name": "CloneGateDenied", "inputs": [{ "name": "sourceAgentId", "type": "uint256" }, { "name": "authorizer", "type": "address" }] },
|
|
975
|
+
{ "type": "error", "name": "CloneGateDataHashMismatch", "inputs": [{ "name": "index", "type": "uint256" }, { "name": "onChain", "type": "bytes32" }, { "name": "submitted", "type": "bytes32" }] },
|
|
976
|
+
{ "type": "error", "name": "CloneGateArityMismatch", "inputs": [{ "name": "expected", "type": "uint256" }, { "name": "got", "type": "uint256" }] },
|
|
977
|
+
{
|
|
978
|
+
type: 'function',
|
|
979
|
+
name: 'setCloneAuthorizer',
|
|
980
|
+
stateMutability: 'nonpayable',
|
|
981
|
+
inputs: [
|
|
982
|
+
{ name: 'tokenId', type: 'uint256' },
|
|
983
|
+
{ name: 'authorizer', type: 'address' },
|
|
984
|
+
],
|
|
985
|
+
outputs: [],
|
|
986
|
+
},
|
|
987
|
+
{
|
|
988
|
+
type: 'function',
|
|
989
|
+
name: 'cloneAuthorizerOf',
|
|
990
|
+
stateMutability: 'view',
|
|
991
|
+
inputs: [{ name: 'tokenId', type: 'uint256' }],
|
|
992
|
+
outputs: [{ name: '', type: 'address' }],
|
|
993
|
+
},
|
|
994
|
+
{
|
|
995
|
+
type: 'function',
|
|
996
|
+
name: 'cloneSourceOf',
|
|
997
|
+
stateMutability: 'view',
|
|
998
|
+
inputs: [{ name: 'agentId_', type: 'uint256' }],
|
|
999
|
+
outputs: [{ name: '', type: 'uint256' }],
|
|
1000
|
+
},
|
|
1001
|
+
{
|
|
1002
|
+
type: 'function',
|
|
1003
|
+
name: 'cloneFrom',
|
|
1004
|
+
stateMutability: 'nonpayable',
|
|
1005
|
+
inputs: [
|
|
1006
|
+
{ name: 'sourceAgentId', type: 'uint256' },
|
|
1007
|
+
{ name: 'to', type: 'address' },
|
|
1008
|
+
{ name: 'dataHashes', type: 'bytes32[]' },
|
|
1009
|
+
{ name: 'sealedKeys', type: 'bytes[]' },
|
|
1010
|
+
{ name: 'newAgentSeal', type: 'address' },
|
|
1011
|
+
{ name: 'newSealId', type: 'bytes32' },
|
|
1012
|
+
{ name: 'caller', type: 'address' },
|
|
1013
|
+
{ name: 'authData', type: 'bytes' },
|
|
1014
|
+
],
|
|
1015
|
+
outputs: [{ name: 'agentId_', type: 'uint256' }],
|
|
1016
|
+
},
|
|
1017
|
+
{
|
|
1018
|
+
type: 'event',
|
|
1019
|
+
name: 'CloneAuthorizerSet',
|
|
1020
|
+
inputs: [
|
|
1021
|
+
{ name: 'tokenId', type: 'uint256', indexed: true },
|
|
1022
|
+
{ name: 'authorizer', type: 'address', indexed: true },
|
|
1023
|
+
{ name: 'owner', type: 'address', indexed: false },
|
|
1024
|
+
],
|
|
1025
|
+
},
|
|
1026
|
+
{
|
|
1027
|
+
type: 'event',
|
|
1028
|
+
name: 'ClonedFrom',
|
|
1029
|
+
inputs: [
|
|
1030
|
+
{ name: 'sourceAgentId', type: 'uint256', indexed: true },
|
|
1031
|
+
{ name: 'newAgentId', type: 'uint256', indexed: true },
|
|
1032
|
+
{ name: 'to', type: 'address', indexed: true },
|
|
1033
|
+
{ name: 'caller', type: 'address', indexed: false },
|
|
1034
|
+
],
|
|
1035
|
+
},
|
|
1036
|
+
{
|
|
1037
|
+
type: 'function',
|
|
1038
|
+
name: 'agenticId',
|
|
1039
|
+
stateMutability: 'view',
|
|
1040
|
+
inputs: [],
|
|
1041
|
+
outputs: [{ name: '', type: 'address' }],
|
|
1042
|
+
},
|
|
1043
|
+
];
|
|
1044
|
+
/**
|
|
1045
|
+
* StandardCloneAuthorizer — the OFFICIAL stock clone policy: a per-buyer
|
|
1046
|
+
* permission switch keyed (sourceAgentId, buyer), grant/revoke gated on the
|
|
1047
|
+
* source's current owner. The SDK's grantClone/revokeClone/cloneGrantOf
|
|
1048
|
+
* helpers speak this ABI to whatever authorizer the token has configured —
|
|
1049
|
+
* they only work when that policy IS the standard one (a custom policy has
|
|
1050
|
+
* its own management surface).
|
|
1051
|
+
*/
|
|
1052
|
+
exports.standardCloneAuthorizerAbi = [
|
|
1053
|
+
{
|
|
1054
|
+
type: 'function',
|
|
1055
|
+
name: 'grant',
|
|
1056
|
+
stateMutability: 'nonpayable',
|
|
1057
|
+
inputs: [
|
|
1058
|
+
{ name: 'sourceAgentId', type: 'uint256' },
|
|
1059
|
+
{ name: 'buyer', type: 'address' },
|
|
1060
|
+
],
|
|
1061
|
+
outputs: [],
|
|
1062
|
+
},
|
|
1063
|
+
{
|
|
1064
|
+
type: 'function',
|
|
1065
|
+
name: 'revoke',
|
|
1066
|
+
stateMutability: 'nonpayable',
|
|
1067
|
+
inputs: [
|
|
1068
|
+
{ name: 'sourceAgentId', type: 'uint256' },
|
|
1069
|
+
{ name: 'buyer', type: 'address' },
|
|
1070
|
+
],
|
|
1071
|
+
outputs: [],
|
|
1072
|
+
},
|
|
1073
|
+
{
|
|
1074
|
+
type: 'function',
|
|
1075
|
+
name: 'grantOf',
|
|
1076
|
+
stateMutability: 'view',
|
|
1077
|
+
inputs: [
|
|
1078
|
+
{ name: 'sourceAgentId', type: 'uint256' },
|
|
1079
|
+
{ name: 'buyer', type: 'address' },
|
|
1080
|
+
],
|
|
1081
|
+
outputs: [
|
|
1082
|
+
{ name: 'grantor', type: 'address' },
|
|
1083
|
+
{ name: 'effective', type: 'bool' },
|
|
1084
|
+
],
|
|
1085
|
+
},
|
|
1086
|
+
{
|
|
1087
|
+
type: 'function',
|
|
1088
|
+
name: 'canClone',
|
|
1089
|
+
stateMutability: 'view',
|
|
1090
|
+
inputs: [
|
|
1091
|
+
{ name: 'sourceAgentId', type: 'uint256' },
|
|
1092
|
+
{ name: 'targetOwner', type: 'address' },
|
|
1093
|
+
{ name: 'caller', type: 'address' },
|
|
1094
|
+
{ name: 'data', type: 'bytes' },
|
|
1095
|
+
],
|
|
1096
|
+
outputs: [{ name: '', type: 'bool' }],
|
|
1097
|
+
},
|
|
1098
|
+
{
|
|
1099
|
+
type: 'error',
|
|
1100
|
+
name: 'StdCloneAuthNotSeller',
|
|
1101
|
+
inputs: [
|
|
1102
|
+
{ name: 'caller', type: 'address' },
|
|
1103
|
+
{ name: 'sourceAgentId', type: 'uint256' },
|
|
1104
|
+
{ name: 'seller', type: 'address' },
|
|
1105
|
+
],
|
|
1106
|
+
},
|
|
1107
|
+
{
|
|
1108
|
+
type: 'event',
|
|
1109
|
+
name: 'CloneGranted',
|
|
1110
|
+
inputs: [
|
|
1111
|
+
{ name: 'sourceAgentId', type: 'uint256', indexed: true },
|
|
1112
|
+
{ name: 'buyer', type: 'address', indexed: true },
|
|
1113
|
+
{ name: 'seller', type: 'address', indexed: false },
|
|
1114
|
+
],
|
|
1115
|
+
},
|
|
1116
|
+
{
|
|
1117
|
+
type: 'event',
|
|
1118
|
+
name: 'CloneRevoked',
|
|
1119
|
+
inputs: [
|
|
1120
|
+
{ name: 'sourceAgentId', type: 'uint256', indexed: true },
|
|
1121
|
+
{ name: 'buyer', type: 'address', indexed: true },
|
|
1122
|
+
{ name: 'seller', type: 'address', indexed: false },
|
|
1123
|
+
],
|
|
1124
|
+
},
|
|
1125
|
+
];
|
|
1126
|
+
/**
|
|
1127
|
+
* TappRegistry — trust-root acknowledgement. `ack` acknowledges the set of
|
|
1128
|
+
* TEE components (attestor, kms, sandbox) the deploy/sandbox flow depends on.
|
|
1129
|
+
*/
|
|
1130
|
+
exports.tappRegistryAbi = [
|
|
1131
|
+
{
|
|
1132
|
+
type: 'function',
|
|
1133
|
+
name: 'acknowledgeApps',
|
|
1134
|
+
stateMutability: 'nonpayable',
|
|
1135
|
+
inputs: [{ name: 'appIds', type: 'string[]' }],
|
|
1136
|
+
outputs: [],
|
|
1137
|
+
},
|
|
1138
|
+
{
|
|
1139
|
+
type: 'function',
|
|
1140
|
+
name: 'isAcknowledged',
|
|
1141
|
+
stateMutability: 'view',
|
|
1142
|
+
inputs: [
|
|
1143
|
+
{ name: 'user', type: 'address' },
|
|
1144
|
+
{ name: 'appId', type: 'string' },
|
|
1145
|
+
],
|
|
1146
|
+
outputs: [{ name: '', type: 'bool' }],
|
|
1147
|
+
},
|
|
1148
|
+
{
|
|
1149
|
+
type: 'function',
|
|
1150
|
+
name: 'getAckVersion',
|
|
1151
|
+
stateMutability: 'view',
|
|
1152
|
+
inputs: [{ name: 'appId', type: 'string' }],
|
|
1153
|
+
outputs: [{ name: '', type: 'uint256' }],
|
|
1154
|
+
},
|
|
1155
|
+
{
|
|
1156
|
+
type: 'function',
|
|
1157
|
+
name: 'getAppInfo',
|
|
1158
|
+
stateMutability: 'view',
|
|
1159
|
+
inputs: [{ name: 'appId', type: 'string' }],
|
|
1160
|
+
outputs: [{
|
|
1161
|
+
name: '', type: 'tuple', components: [
|
|
1162
|
+
{ name: 'composeHash', type: 'bytes' },
|
|
1163
|
+
{ name: 'volumesHash', type: 'bytes' },
|
|
1164
|
+
{ name: 'imageHashes', type: 'bytes[]' },
|
|
1165
|
+
{ name: 'owner', type: 'address' },
|
|
1166
|
+
{ name: 'registeredAt', type: 'uint256' },
|
|
1167
|
+
],
|
|
1168
|
+
}],
|
|
1169
|
+
},
|
|
1170
|
+
{
|
|
1171
|
+
type: 'function',
|
|
1172
|
+
name: 'getNodeList',
|
|
1173
|
+
stateMutability: 'view',
|
|
1174
|
+
inputs: [{ name: 'appId', type: 'string' }],
|
|
1175
|
+
outputs: [{ name: '', type: 'address[]' }],
|
|
1176
|
+
},
|
|
1177
|
+
];
|
|
1178
|
+
/**
|
|
1179
|
+
* SandboxServing — prepaid sandbox balance. `deposit` funds the caller's (or a
|
|
1180
|
+
* recipient's) balance held against a provider; `getBalance` reads it.
|
|
1181
|
+
*/
|
|
1182
|
+
exports.sandboxServingAbi = [
|
|
1183
|
+
{
|
|
1184
|
+
type: 'function',
|
|
1185
|
+
name: 'deposit',
|
|
1186
|
+
stateMutability: 'payable',
|
|
1187
|
+
inputs: [
|
|
1188
|
+
{ name: 'recipient', type: 'address' },
|
|
1189
|
+
{ name: 'provider', type: 'address' },
|
|
1190
|
+
],
|
|
1191
|
+
outputs: [],
|
|
1192
|
+
},
|
|
1193
|
+
{
|
|
1194
|
+
type: 'function',
|
|
1195
|
+
name: 'requestRefund',
|
|
1196
|
+
stateMutability: 'nonpayable',
|
|
1197
|
+
inputs: [
|
|
1198
|
+
{ name: 'provider', type: 'address' },
|
|
1199
|
+
{ name: 'amount', type: 'uint256' },
|
|
1200
|
+
],
|
|
1201
|
+
outputs: [],
|
|
1202
|
+
},
|
|
1203
|
+
{
|
|
1204
|
+
type: 'function',
|
|
1205
|
+
name: 'withdrawRefund',
|
|
1206
|
+
stateMutability: 'nonpayable',
|
|
1207
|
+
inputs: [{ name: 'provider', type: 'address' }],
|
|
1208
|
+
outputs: [],
|
|
1209
|
+
},
|
|
1210
|
+
{
|
|
1211
|
+
type: 'function',
|
|
1212
|
+
name: 'getBalance',
|
|
1213
|
+
stateMutability: 'view',
|
|
1214
|
+
inputs: [
|
|
1215
|
+
{ name: 'user', type: 'address' },
|
|
1216
|
+
{ name: 'provider', type: 'address' },
|
|
1217
|
+
],
|
|
1218
|
+
outputs: [
|
|
1219
|
+
{ name: 'balance', type: 'uint256' },
|
|
1220
|
+
{ name: 'pendingRefund', type: 'uint256' },
|
|
1221
|
+
{ name: 'refundUnlockAt', type: 'uint256' },
|
|
1222
|
+
],
|
|
1223
|
+
},
|
|
1224
|
+
{
|
|
1225
|
+
type: 'function',
|
|
1226
|
+
name: 'services',
|
|
1227
|
+
stateMutability: 'view',
|
|
1228
|
+
inputs: [{ name: 'provider', type: 'address' }],
|
|
1229
|
+
outputs: [
|
|
1230
|
+
{ name: 'url', type: 'string' },
|
|
1231
|
+
{ name: 'appId', type: 'string' },
|
|
1232
|
+
{ name: 'pricePerCPUPerMin', type: 'uint256' },
|
|
1233
|
+
{ name: 'pricePerMemGBPerMin', type: 'uint256' },
|
|
1234
|
+
{ name: 'createFee', type: 'uint256' },
|
|
1235
|
+
],
|
|
1236
|
+
},
|
|
1237
|
+
{
|
|
1238
|
+
type: 'function',
|
|
1239
|
+
name: 'isTEEAcknowledged',
|
|
1240
|
+
stateMutability: 'view',
|
|
1241
|
+
inputs: [
|
|
1242
|
+
{ name: 'user', type: 'address' },
|
|
1243
|
+
{ name: 'provider', type: 'address' },
|
|
1244
|
+
],
|
|
1245
|
+
outputs: [{ name: '', type: 'bool' }],
|
|
1246
|
+
},
|
|
1247
|
+
];
|
|
1248
|
+
//# sourceMappingURL=abi.js.map
|