@agent-shield/sdk 0.3.1 → 0.4.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.
@@ -6,98 +6,98 @@ export declare function buildInitializeVault(program: Program<AgentShield>, owne
6
6
  docs: ["Initialize a new agent vault with policy configuration.", "Only the owner can call this. Creates vault PDA, policy PDA, and spend tracker PDA.", "`tracker_tier`: 0 = Standard (200 entries), 1 = Pro (500), 2 = Max (1000)."];
7
7
  discriminator: [48, 191, 163, 44, 71, 129, 63, 164];
8
8
  accounts: [{
9
- "name": "owner";
10
- "writable": true;
11
- "signer": true;
12
- }, {
13
- "name": "vault";
14
- "writable": true;
15
- "pda": {
16
- "seeds": [{
17
- "kind": "const";
18
- "value": [118, 97, 117, 108, 116];
9
+ name: "owner";
10
+ writable: true;
11
+ signer: true;
12
+ }, {
13
+ name: "vault";
14
+ writable: true;
15
+ pda: {
16
+ seeds: [{
17
+ kind: "const";
18
+ value: [118, 97, 117, 108, 116];
19
19
  }, {
20
- "kind": "account";
21
- "path": "owner";
20
+ kind: "account";
21
+ path: "owner";
22
22
  }, {
23
- "kind": "arg";
24
- "path": "vaultId";
23
+ kind: "arg";
24
+ path: "vaultId";
25
25
  }];
26
26
  };
27
27
  }, {
28
- "name": "policy";
29
- "writable": true;
30
- "pda": {
31
- "seeds": [{
32
- "kind": "const";
33
- "value": [112, 111, 108, 105, 99, 121];
28
+ name: "policy";
29
+ writable: true;
30
+ pda: {
31
+ seeds: [{
32
+ kind: "const";
33
+ value: [112, 111, 108, 105, 99, 121];
34
34
  }, {
35
- "kind": "account";
36
- "path": "vault";
35
+ kind: "account";
36
+ path: "vault";
37
37
  }];
38
38
  };
39
39
  }, {
40
- "name": "tracker";
41
- "writable": true;
42
- "pda": {
43
- "seeds": [{
44
- "kind": "const";
45
- "value": [116, 114, 97, 99, 107, 101, 114];
40
+ name: "tracker";
41
+ writable: true;
42
+ pda: {
43
+ seeds: [{
44
+ kind: "const";
45
+ value: [116, 114, 97, 99, 107, 101, 114];
46
46
  }, {
47
- "kind": "account";
48
- "path": "vault";
47
+ kind: "account";
48
+ path: "vault";
49
49
  }];
50
50
  };
51
51
  }, {
52
- "name": "feeDestination";
53
- "docs": ["The protocol treasury that receives fees"];
52
+ name: "feeDestination";
53
+ docs: ["The protocol treasury that receives fees"];
54
54
  }, {
55
- "name": "systemProgram";
56
- "address": "11111111111111111111111111111111";
55
+ name: "systemProgram";
56
+ address: "11111111111111111111111111111111";
57
57
  }];
58
58
  args: [{
59
- "name": "vaultId";
60
- "type": "u64";
59
+ name: "vaultId";
60
+ type: "u64";
61
61
  }, {
62
- "name": "dailySpendingCapUsd";
63
- "type": "u64";
62
+ name: "dailySpendingCapUsd";
63
+ type: "u64";
64
64
  }, {
65
- "name": "maxTransactionSizeUsd";
66
- "type": "u64";
65
+ name: "maxTransactionSizeUsd";
66
+ type: "u64";
67
67
  }, {
68
- "name": "allowedTokens";
69
- "type": {
70
- "vec": {
71
- "defined": {
72
- "name": "allowedToken";
68
+ name: "allowedTokens";
69
+ type: {
70
+ vec: {
71
+ defined: {
72
+ name: "allowedToken";
73
73
  };
74
74
  };
75
75
  };
76
76
  }, {
77
- "name": "allowedProtocols";
78
- "type": {
79
- "vec": "pubkey";
77
+ name: "allowedProtocols";
78
+ type: {
79
+ vec: "pubkey";
80
80
  };
81
81
  }, {
82
- "name": "maxLeverageBps";
83
- "type": "u16";
82
+ name: "maxLeverageBps";
83
+ type: "u16";
84
84
  }, {
85
- "name": "maxConcurrentPositions";
86
- "type": "u8";
85
+ name: "maxConcurrentPositions";
86
+ type: "u8";
87
87
  }, {
88
- "name": "developerFeeRate";
89
- "type": "u16";
88
+ name: "developerFeeRate";
89
+ type: "u16";
90
90
  }, {
91
- "name": "timelockDuration";
92
- "type": "u64";
91
+ name: "timelockDuration";
92
+ type: "u64";
93
93
  }, {
94
- "name": "allowedDestinations";
95
- "type": {
96
- "vec": "pubkey";
94
+ name: "allowedDestinations";
95
+ type: {
96
+ vec: "pubkey";
97
97
  };
98
98
  }, {
99
- "name": "trackerTier";
100
- "type": "u8";
99
+ name: "trackerTier";
100
+ type: "u8";
101
101
  }];
102
102
  } & {
103
103
  name: "initializeVault";
@@ -109,39 +109,39 @@ export declare function buildInitializeVault(program: Program<AgentShield>, owne
109
109
  name: "vault";
110
110
  writable: true;
111
111
  pda: {
112
- "seeds": [{
113
- "kind": "const";
114
- "value": [118, 97, 117, 108, 116];
112
+ seeds: [{
113
+ kind: "const";
114
+ value: [118, 97, 117, 108, 116];
115
115
  }, {
116
- "kind": "account";
117
- "path": "owner";
116
+ kind: "account";
117
+ path: "owner";
118
118
  }, {
119
- "kind": "arg";
120
- "path": "vaultId";
119
+ kind: "arg";
120
+ path: "vaultId";
121
121
  }];
122
122
  };
123
123
  } | {
124
124
  name: "policy";
125
125
  writable: true;
126
126
  pda: {
127
- "seeds": [{
128
- "kind": "const";
129
- "value": [112, 111, 108, 105, 99, 121];
127
+ seeds: [{
128
+ kind: "const";
129
+ value: [112, 111, 108, 105, 99, 121];
130
130
  }, {
131
- "kind": "account";
132
- "path": "vault";
131
+ kind: "account";
132
+ path: "vault";
133
133
  }];
134
134
  };
135
135
  } | {
136
136
  name: "tracker";
137
137
  writable: true;
138
138
  pda: {
139
- "seeds": [{
140
- "kind": "const";
141
- "value": [116, 114, 97, 99, 107, 101, 114];
139
+ seeds: [{
140
+ kind: "const";
141
+ value: [116, 114, 97, 99, 107, 101, 114];
142
142
  }, {
143
- "kind": "account";
144
- "path": "vault";
143
+ kind: "account";
144
+ path: "vault";
145
145
  }];
146
146
  };
147
147
  } | {
@@ -156,80 +156,80 @@ export declare function buildDepositFunds(program: Program<AgentShield>, owner:
156
156
  docs: ["Deposit SPL tokens into the vault's PDA-controlled token account.", "Only the owner can call this."];
157
157
  discriminator: [202, 39, 52, 211, 53, 20, 250, 88];
158
158
  accounts: [{
159
- "name": "owner";
160
- "writable": true;
161
- "signer": true;
162
- "relations": ["vault"];
163
- }, {
164
- "name": "vault";
165
- "pda": {
166
- "seeds": [{
167
- "kind": "const";
168
- "value": [118, 97, 117, 108, 116];
159
+ name: "owner";
160
+ writable: true;
161
+ signer: true;
162
+ relations: ["vault"];
163
+ }, {
164
+ name: "vault";
165
+ pda: {
166
+ seeds: [{
167
+ kind: "const";
168
+ value: [118, 97, 117, 108, 116];
169
169
  }, {
170
- "kind": "account";
171
- "path": "owner";
170
+ kind: "account";
171
+ path: "owner";
172
172
  }, {
173
- "kind": "account";
174
- "path": "vault.vault_id";
175
- "account": "agentVault";
173
+ kind: "account";
174
+ path: "vault.vault_id";
175
+ account: "agentVault";
176
176
  }];
177
177
  };
178
178
  }, {
179
- "name": "mint";
179
+ name: "mint";
180
180
  }, {
181
- "name": "ownerTokenAccount";
182
- "docs": ["Owner's token account to transfer from"];
183
- "writable": true;
184
- "pda": {
185
- "seeds": [{
186
- "kind": "account";
187
- "path": "owner";
181
+ name: "ownerTokenAccount";
182
+ docs: ["Owner's token account to transfer from"];
183
+ writable: true;
184
+ pda: {
185
+ seeds: [{
186
+ kind: "account";
187
+ path: "owner";
188
188
  }, {
189
- "kind": "const";
190
- "value": [6, 221, 246, 225, 215, 101, 161, 147, 217, 203, 225, 70, 206, 235, 121, 172, 28, 180, 133, 237, 95, 91, 55, 145, 58, 140, 245, 133, 126, 255, 0, 169];
189
+ kind: "const";
190
+ value: [6, 221, 246, 225, 215, 101, 161, 147, 217, 203, 225, 70, 206, 235, 121, 172, 28, 180, 133, 237, 95, 91, 55, 145, 58, 140, 245, 133, 126, 255, 0, 169];
191
191
  }, {
192
- "kind": "account";
193
- "path": "mint";
192
+ kind: "account";
193
+ path: "mint";
194
194
  }];
195
- "program": {
196
- "kind": "const";
197
- "value": [140, 151, 37, 143, 78, 36, 137, 241, 187, 61, 16, 41, 20, 142, 13, 131, 11, 90, 19, 153, 218, 255, 16, 132, 4, 142, 123, 216, 219, 233, 248, 89];
195
+ program: {
196
+ kind: "const";
197
+ value: [140, 151, 37, 143, 78, 36, 137, 241, 187, 61, 16, 41, 20, 142, 13, 131, 11, 90, 19, 153, 218, 255, 16, 132, 4, 142, 123, 216, 219, 233, 248, 89];
198
198
  };
199
199
  };
200
200
  }, {
201
- "name": "vaultTokenAccount";
202
- "docs": ["Vault's PDA-controlled token account"];
203
- "writable": true;
204
- "pda": {
205
- "seeds": [{
206
- "kind": "account";
207
- "path": "vault";
201
+ name: "vaultTokenAccount";
202
+ docs: ["Vault's PDA-controlled token account"];
203
+ writable: true;
204
+ pda: {
205
+ seeds: [{
206
+ kind: "account";
207
+ path: "vault";
208
208
  }, {
209
- "kind": "const";
210
- "value": [6, 221, 246, 225, 215, 101, 161, 147, 217, 203, 225, 70, 206, 235, 121, 172, 28, 180, 133, 237, 95, 91, 55, 145, 58, 140, 245, 133, 126, 255, 0, 169];
209
+ kind: "const";
210
+ value: [6, 221, 246, 225, 215, 101, 161, 147, 217, 203, 225, 70, 206, 235, 121, 172, 28, 180, 133, 237, 95, 91, 55, 145, 58, 140, 245, 133, 126, 255, 0, 169];
211
211
  }, {
212
- "kind": "account";
213
- "path": "mint";
212
+ kind: "account";
213
+ path: "mint";
214
214
  }];
215
- "program": {
216
- "kind": "const";
217
- "value": [140, 151, 37, 143, 78, 36, 137, 241, 187, 61, 16, 41, 20, 142, 13, 131, 11, 90, 19, 153, 218, 255, 16, 132, 4, 142, 123, 216, 219, 233, 248, 89];
215
+ program: {
216
+ kind: "const";
217
+ value: [140, 151, 37, 143, 78, 36, 137, 241, 187, 61, 16, 41, 20, 142, 13, 131, 11, 90, 19, 153, 218, 255, 16, 132, 4, 142, 123, 216, 219, 233, 248, 89];
218
218
  };
219
219
  };
220
220
  }, {
221
- "name": "tokenProgram";
222
- "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
221
+ name: "tokenProgram";
222
+ address: "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
223
223
  }, {
224
- "name": "associatedTokenProgram";
225
- "address": "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL";
224
+ name: "associatedTokenProgram";
225
+ address: "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL";
226
226
  }, {
227
- "name": "systemProgram";
228
- "address": "11111111111111111111111111111111";
227
+ name: "systemProgram";
228
+ address: "11111111111111111111111111111111";
229
229
  }];
230
230
  args: [{
231
- "name": "amount";
232
- "type": "u64";
231
+ name: "amount";
232
+ type: "u64";
233
233
  }];
234
234
  } & {
235
235
  name: "depositFunds";
@@ -241,16 +241,16 @@ export declare function buildDepositFunds(program: Program<AgentShield>, owner:
241
241
  } | {
242
242
  name: "vault";
243
243
  pda: {
244
- "seeds": [{
245
- "kind": "const";
246
- "value": [118, 97, 117, 108, 116];
244
+ seeds: [{
245
+ kind: "const";
246
+ value: [118, 97, 117, 108, 116];
247
247
  }, {
248
- "kind": "account";
249
- "path": "owner";
248
+ kind: "account";
249
+ path: "owner";
250
250
  }, {
251
- "kind": "account";
252
- "path": "vault.vault_id";
253
- "account": "agentVault";
251
+ kind: "account";
252
+ path: "vault.vault_id";
253
+ account: "agentVault";
254
254
  }];
255
255
  };
256
256
  } | {
@@ -260,19 +260,19 @@ export declare function buildDepositFunds(program: Program<AgentShield>, owner:
260
260
  docs: ["Owner's token account to transfer from"];
261
261
  writable: true;
262
262
  pda: {
263
- "seeds": [{
264
- "kind": "account";
265
- "path": "owner";
263
+ seeds: [{
264
+ kind: "account";
265
+ path: "owner";
266
266
  }, {
267
- "kind": "const";
268
- "value": [6, 221, 246, 225, 215, 101, 161, 147, 217, 203, 225, 70, 206, 235, 121, 172, 28, 180, 133, 237, 95, 91, 55, 145, 58, 140, 245, 133, 126, 255, 0, 169];
267
+ kind: "const";
268
+ value: [6, 221, 246, 225, 215, 101, 161, 147, 217, 203, 225, 70, 206, 235, 121, 172, 28, 180, 133, 237, 95, 91, 55, 145, 58, 140, 245, 133, 126, 255, 0, 169];
269
269
  }, {
270
- "kind": "account";
271
- "path": "mint";
270
+ kind: "account";
271
+ path: "mint";
272
272
  }];
273
- "program": {
274
- "kind": "const";
275
- "value": [140, 151, 37, 143, 78, 36, 137, 241, 187, 61, 16, 41, 20, 142, 13, 131, 11, 90, 19, 153, 218, 255, 16, 132, 4, 142, 123, 216, 219, 233, 248, 89];
273
+ program: {
274
+ kind: "const";
275
+ value: [140, 151, 37, 143, 78, 36, 137, 241, 187, 61, 16, 41, 20, 142, 13, 131, 11, 90, 19, 153, 218, 255, 16, 132, 4, 142, 123, 216, 219, 233, 248, 89];
276
276
  };
277
277
  };
278
278
  } | {
@@ -280,19 +280,19 @@ export declare function buildDepositFunds(program: Program<AgentShield>, owner:
280
280
  docs: ["Vault's PDA-controlled token account"];
281
281
  writable: true;
282
282
  pda: {
283
- "seeds": [{
284
- "kind": "account";
285
- "path": "vault";
283
+ seeds: [{
284
+ kind: "account";
285
+ path: "vault";
286
286
  }, {
287
- "kind": "const";
288
- "value": [6, 221, 246, 225, 215, 101, 161, 147, 217, 203, 225, 70, 206, 235, 121, 172, 28, 180, 133, 237, 95, 91, 55, 145, 58, 140, 245, 133, 126, 255, 0, 169];
287
+ kind: "const";
288
+ value: [6, 221, 246, 225, 215, 101, 161, 147, 217, 203, 225, 70, 206, 235, 121, 172, 28, 180, 133, 237, 95, 91, 55, 145, 58, 140, 245, 133, 126, 255, 0, 169];
289
289
  }, {
290
- "kind": "account";
291
- "path": "mint";
290
+ kind: "account";
291
+ path: "mint";
292
292
  }];
293
- "program": {
294
- "kind": "const";
295
- "value": [140, 151, 37, 143, 78, 36, 137, 241, 187, 61, 16, 41, 20, 142, 13, 131, 11, 90, 19, 153, 218, 255, 16, 132, 4, 142, 123, 216, 219, 233, 248, 89];
293
+ program: {
294
+ kind: "const";
295
+ value: [140, 151, 37, 143, 78, 36, 137, 241, 187, 61, 16, 41, 20, 142, 13, 131, 11, 90, 19, 153, 218, 255, 16, 132, 4, 142, 123, 216, 219, 233, 248, 89];
296
296
  };
297
297
  };
298
298
  } | {
@@ -310,29 +310,29 @@ export declare function buildRegisterAgent(program: Program<AgentShield>, owner:
310
310
  docs: ["Register an agent's signing key to this vault.", "Only the owner can call this. One agent per vault."];
311
311
  discriminator: [135, 157, 66, 195, 2, 113, 175, 30];
312
312
  accounts: [{
313
- "name": "owner";
314
- "signer": true;
315
- "relations": ["vault"];
316
- }, {
317
- "name": "vault";
318
- "writable": true;
319
- "pda": {
320
- "seeds": [{
321
- "kind": "const";
322
- "value": [118, 97, 117, 108, 116];
313
+ name: "owner";
314
+ signer: true;
315
+ relations: ["vault"];
316
+ }, {
317
+ name: "vault";
318
+ writable: true;
319
+ pda: {
320
+ seeds: [{
321
+ kind: "const";
322
+ value: [118, 97, 117, 108, 116];
323
323
  }, {
324
- "kind": "account";
325
- "path": "owner";
324
+ kind: "account";
325
+ path: "owner";
326
326
  }, {
327
- "kind": "account";
328
- "path": "vault.vault_id";
329
- "account": "agentVault";
327
+ kind: "account";
328
+ path: "vault.vault_id";
329
+ account: "agentVault";
330
330
  }];
331
331
  };
332
332
  }];
333
333
  args: [{
334
- "name": "agent";
335
- "type": "pubkey";
334
+ name: "agent";
335
+ type: "pubkey";
336
336
  }];
337
337
  } & {
338
338
  name: "registerAgent";
@@ -344,16 +344,16 @@ export declare function buildRegisterAgent(program: Program<AgentShield>, owner:
344
344
  name: "vault";
345
345
  writable: true;
346
346
  pda: {
347
- "seeds": [{
348
- "kind": "const";
349
- "value": [118, 97, 117, 108, 116];
347
+ seeds: [{
348
+ kind: "const";
349
+ value: [118, 97, 117, 108, 116];
350
350
  }, {
351
- "kind": "account";
352
- "path": "owner";
351
+ kind: "account";
352
+ path: "owner";
353
353
  }, {
354
- "kind": "account";
355
- "path": "vault.vault_id";
356
- "account": "agentVault";
354
+ kind: "account";
355
+ path: "vault.vault_id";
356
+ account: "agentVault";
357
357
  }];
358
358
  };
359
359
  }>;
@@ -362,108 +362,108 @@ export declare function buildUpdatePolicy(program: Program<AgentShield>, owner:
362
362
  docs: ["Update the policy configuration for a vault.", "Only the owner can call this. Cannot be called by the agent.", "Blocked when timelock_duration > 0 \u2014 use queue_policy_update instead."];
363
363
  discriminator: [212, 245, 246, 7, 163, 151, 18, 57];
364
364
  accounts: [{
365
- "name": "owner";
366
- "signer": true;
367
- "relations": ["vault"];
368
- }, {
369
- "name": "vault";
370
- "pda": {
371
- "seeds": [{
372
- "kind": "const";
373
- "value": [118, 97, 117, 108, 116];
365
+ name: "owner";
366
+ signer: true;
367
+ relations: ["vault"];
368
+ }, {
369
+ name: "vault";
370
+ pda: {
371
+ seeds: [{
372
+ kind: "const";
373
+ value: [118, 97, 117, 108, 116];
374
374
  }, {
375
- "kind": "account";
376
- "path": "owner";
375
+ kind: "account";
376
+ path: "owner";
377
377
  }, {
378
- "kind": "account";
379
- "path": "vault.vault_id";
380
- "account": "agentVault";
378
+ kind: "account";
379
+ path: "vault.vault_id";
380
+ account: "agentVault";
381
381
  }];
382
382
  };
383
- "relations": ["policy", "tracker"];
383
+ relations: ["policy", "tracker"];
384
384
  }, {
385
- "name": "policy";
386
- "writable": true;
387
- "pda": {
388
- "seeds": [{
389
- "kind": "const";
390
- "value": [112, 111, 108, 105, 99, 121];
385
+ name: "policy";
386
+ writable: true;
387
+ pda: {
388
+ seeds: [{
389
+ kind: "const";
390
+ value: [112, 111, 108, 105, 99, 121];
391
391
  }, {
392
- "kind": "account";
393
- "path": "vault";
392
+ kind: "account";
393
+ path: "vault";
394
394
  }];
395
395
  };
396
396
  }, {
397
- "name": "tracker";
398
- "writable": true;
399
- "pda": {
400
- "seeds": [{
401
- "kind": "const";
402
- "value": [116, 114, 97, 99, 107, 101, 114];
397
+ name: "tracker";
398
+ writable: true;
399
+ pda: {
400
+ seeds: [{
401
+ kind: "const";
402
+ value: [116, 114, 97, 99, 107, 101, 114];
403
403
  }, {
404
- "kind": "account";
405
- "path": "vault";
404
+ kind: "account";
405
+ path: "vault";
406
406
  }];
407
407
  };
408
408
  }];
409
409
  args: [{
410
- "name": "dailySpendingCapUsd";
411
- "type": {
412
- "option": "u64";
410
+ name: "dailySpendingCapUsd";
411
+ type: {
412
+ option: "u64";
413
413
  };
414
414
  }, {
415
- "name": "maxTransactionSizeUsd";
416
- "type": {
417
- "option": "u64";
415
+ name: "maxTransactionSizeUsd";
416
+ type: {
417
+ option: "u64";
418
418
  };
419
419
  }, {
420
- "name": "allowedTokens";
421
- "type": {
422
- "option": {
423
- "vec": {
424
- "defined": {
425
- "name": "allowedToken";
420
+ name: "allowedTokens";
421
+ type: {
422
+ option: {
423
+ vec: {
424
+ defined: {
425
+ name: "allowedToken";
426
426
  };
427
427
  };
428
428
  };
429
429
  };
430
430
  }, {
431
- "name": "allowedProtocols";
432
- "type": {
433
- "option": {
434
- "vec": "pubkey";
431
+ name: "allowedProtocols";
432
+ type: {
433
+ option: {
434
+ vec: "pubkey";
435
435
  };
436
436
  };
437
437
  }, {
438
- "name": "maxLeverageBps";
439
- "type": {
440
- "option": "u16";
438
+ name: "maxLeverageBps";
439
+ type: {
440
+ option: "u16";
441
441
  };
442
442
  }, {
443
- "name": "canOpenPositions";
444
- "type": {
445
- "option": "bool";
443
+ name: "canOpenPositions";
444
+ type: {
445
+ option: "bool";
446
446
  };
447
447
  }, {
448
- "name": "maxConcurrentPositions";
449
- "type": {
450
- "option": "u8";
448
+ name: "maxConcurrentPositions";
449
+ type: {
450
+ option: "u8";
451
451
  };
452
452
  }, {
453
- "name": "developerFeeRate";
454
- "type": {
455
- "option": "u16";
453
+ name: "developerFeeRate";
454
+ type: {
455
+ option: "u16";
456
456
  };
457
457
  }, {
458
- "name": "timelockDuration";
459
- "type": {
460
- "option": "u64";
458
+ name: "timelockDuration";
459
+ type: {
460
+ option: "u64";
461
461
  };
462
462
  }, {
463
- "name": "allowedDestinations";
464
- "type": {
465
- "option": {
466
- "vec": "pubkey";
463
+ name: "allowedDestinations";
464
+ type: {
465
+ option: {
466
+ vec: "pubkey";
467
467
  };
468
468
  };
469
469
  }];
@@ -476,16 +476,16 @@ export declare function buildUpdatePolicy(program: Program<AgentShield>, owner:
476
476
  } | {
477
477
  name: "vault";
478
478
  pda: {
479
- "seeds": [{
480
- "kind": "const";
481
- "value": [118, 97, 117, 108, 116];
479
+ seeds: [{
480
+ kind: "const";
481
+ value: [118, 97, 117, 108, 116];
482
482
  }, {
483
- "kind": "account";
484
- "path": "owner";
483
+ kind: "account";
484
+ path: "owner";
485
485
  }, {
486
- "kind": "account";
487
- "path": "vault.vault_id";
488
- "account": "agentVault";
486
+ kind: "account";
487
+ path: "vault.vault_id";
488
+ account: "agentVault";
489
489
  }];
490
490
  };
491
491
  relations: ["policy", "tracker"];
@@ -493,24 +493,24 @@ export declare function buildUpdatePolicy(program: Program<AgentShield>, owner:
493
493
  name: "policy";
494
494
  writable: true;
495
495
  pda: {
496
- "seeds": [{
497
- "kind": "const";
498
- "value": [112, 111, 108, 105, 99, 121];
496
+ seeds: [{
497
+ kind: "const";
498
+ value: [112, 111, 108, 105, 99, 121];
499
499
  }, {
500
- "kind": "account";
501
- "path": "vault";
500
+ kind: "account";
501
+ path: "vault";
502
502
  }];
503
503
  };
504
504
  } | {
505
505
  name: "tracker";
506
506
  writable: true;
507
507
  pda: {
508
- "seeds": [{
509
- "kind": "const";
510
- "value": [116, 114, 97, 99, 107, 101, 114];
508
+ seeds: [{
509
+ kind: "const";
510
+ value: [116, 114, 97, 99, 107, 101, 114];
511
511
  }, {
512
- "kind": "account";
513
- "path": "vault";
512
+ kind: "account";
513
+ path: "vault";
514
514
  }];
515
515
  };
516
516
  }>;
@@ -519,103 +519,103 @@ export declare function buildValidateAndAuthorize(program: Program<AgentShield>,
519
519
  docs: ["Core permission check. Called by the agent before a DeFi action.", "Validates the action against all policy constraints (USD caps, per-token caps).", "If approved, creates a SessionAuthority PDA, delegates tokens to agent,", "and updates spend tracking.", "If denied, reverts the entire transaction (including subsequent DeFi instructions)."];
520
520
  discriminator: [22, 183, 48, 222, 218, 11, 197, 152];
521
521
  accounts: [{
522
- "name": "agent";
523
- "writable": true;
524
- "signer": true;
525
- }, {
526
- "name": "vault";
527
- "writable": true;
528
- "pda": {
529
- "seeds": [{
530
- "kind": "const";
531
- "value": [118, 97, 117, 108, 116];
522
+ name: "agent";
523
+ writable: true;
524
+ signer: true;
525
+ }, {
526
+ name: "vault";
527
+ writable: true;
528
+ pda: {
529
+ seeds: [{
530
+ kind: "const";
531
+ value: [118, 97, 117, 108, 116];
532
532
  }, {
533
- "kind": "account";
534
- "path": "vault.owner";
535
- "account": "agentVault";
533
+ kind: "account";
534
+ path: "vault.owner";
535
+ account: "agentVault";
536
536
  }, {
537
- "kind": "account";
538
- "path": "vault.vault_id";
539
- "account": "agentVault";
537
+ kind: "account";
538
+ path: "vault.vault_id";
539
+ account: "agentVault";
540
540
  }];
541
541
  };
542
- "relations": ["policy", "tracker"];
542
+ relations: ["policy", "tracker"];
543
543
  }, {
544
- "name": "policy";
545
- "pda": {
546
- "seeds": [{
547
- "kind": "const";
548
- "value": [112, 111, 108, 105, 99, 121];
544
+ name: "policy";
545
+ pda: {
546
+ seeds: [{
547
+ kind: "const";
548
+ value: [112, 111, 108, 105, 99, 121];
549
549
  }, {
550
- "kind": "account";
551
- "path": "vault";
550
+ kind: "account";
551
+ path: "vault";
552
552
  }];
553
553
  };
554
554
  }, {
555
- "name": "tracker";
556
- "writable": true;
557
- "pda": {
558
- "seeds": [{
559
- "kind": "const";
560
- "value": [116, 114, 97, 99, 107, 101, 114];
555
+ name: "tracker";
556
+ writable: true;
557
+ pda: {
558
+ seeds: [{
559
+ kind: "const";
560
+ value: [116, 114, 97, 99, 107, 101, 114];
561
561
  }, {
562
- "kind": "account";
563
- "path": "vault";
562
+ kind: "account";
563
+ path: "vault";
564
564
  }];
565
565
  };
566
566
  }, {
567
- "name": "session";
568
- "docs": ["Ephemeral session PDA \u2014 `init` ensures no double-authorization.", "Seeds include token_mint for per-token concurrent sessions."];
569
- "writable": true;
570
- "pda": {
571
- "seeds": [{
572
- "kind": "const";
573
- "value": [115, 101, 115, 115, 105, 111, 110];
567
+ name: "session";
568
+ docs: ["Ephemeral session PDA \u2014 `init` ensures no double-authorization.", "Seeds include token_mint for per-token concurrent sessions."];
569
+ writable: true;
570
+ pda: {
571
+ seeds: [{
572
+ kind: "const";
573
+ value: [115, 101, 115, 115, 105, 111, 110];
574
574
  }, {
575
- "kind": "account";
576
- "path": "vault";
575
+ kind: "account";
576
+ path: "vault";
577
577
  }, {
578
- "kind": "account";
579
- "path": "agent";
578
+ kind: "account";
579
+ path: "agent";
580
580
  }, {
581
- "kind": "arg";
582
- "path": "tokenMint";
581
+ kind: "arg";
582
+ path: "tokenMint";
583
583
  }];
584
584
  };
585
585
  }, {
586
- "name": "vaultTokenAccount";
587
- "docs": ["Vault's PDA-owned token account for the spend token (delegation source)"];
588
- "writable": true;
586
+ name: "vaultTokenAccount";
587
+ docs: ["Vault's PDA-owned token account for the spend token (delegation source)"];
588
+ writable: true;
589
589
  }, {
590
- "name": "tokenMintAccount";
591
- "docs": ["The token mint being spent"];
590
+ name: "tokenMintAccount";
591
+ docs: ["The token mint being spent"];
592
592
  }, {
593
- "name": "tokenProgram";
594
- "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
593
+ name: "tokenProgram";
594
+ address: "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
595
595
  }, {
596
- "name": "systemProgram";
597
- "address": "11111111111111111111111111111111";
596
+ name: "systemProgram";
597
+ address: "11111111111111111111111111111111";
598
598
  }];
599
599
  args: [{
600
- "name": "actionType";
601
- "type": {
602
- "defined": {
603
- "name": "actionType";
600
+ name: "actionType";
601
+ type: {
602
+ defined: {
603
+ name: "actionType";
604
604
  };
605
605
  };
606
606
  }, {
607
- "name": "tokenMint";
608
- "type": "pubkey";
607
+ name: "tokenMint";
608
+ type: "pubkey";
609
609
  }, {
610
- "name": "amount";
611
- "type": "u64";
610
+ name: "amount";
611
+ type: "u64";
612
612
  }, {
613
- "name": "targetProtocol";
614
- "type": "pubkey";
613
+ name: "targetProtocol";
614
+ type: "pubkey";
615
615
  }, {
616
- "name": "leverageBps";
617
- "type": {
618
- "option": "u16";
616
+ name: "leverageBps";
617
+ type: {
618
+ option: "u16";
619
619
  };
620
620
  }];
621
621
  } & {
@@ -628,41 +628,41 @@ export declare function buildValidateAndAuthorize(program: Program<AgentShield>,
628
628
  name: "vault";
629
629
  writable: true;
630
630
  pda: {
631
- "seeds": [{
632
- "kind": "const";
633
- "value": [118, 97, 117, 108, 116];
631
+ seeds: [{
632
+ kind: "const";
633
+ value: [118, 97, 117, 108, 116];
634
634
  }, {
635
- "kind": "account";
636
- "path": "vault.owner";
637
- "account": "agentVault";
635
+ kind: "account";
636
+ path: "vault.owner";
637
+ account: "agentVault";
638
638
  }, {
639
- "kind": "account";
640
- "path": "vault.vault_id";
641
- "account": "agentVault";
639
+ kind: "account";
640
+ path: "vault.vault_id";
641
+ account: "agentVault";
642
642
  }];
643
643
  };
644
644
  relations: ["policy", "tracker"];
645
645
  } | {
646
646
  name: "policy";
647
647
  pda: {
648
- "seeds": [{
649
- "kind": "const";
650
- "value": [112, 111, 108, 105, 99, 121];
648
+ seeds: [{
649
+ kind: "const";
650
+ value: [112, 111, 108, 105, 99, 121];
651
651
  }, {
652
- "kind": "account";
653
- "path": "vault";
652
+ kind: "account";
653
+ path: "vault";
654
654
  }];
655
655
  };
656
656
  } | {
657
657
  name: "tracker";
658
658
  writable: true;
659
659
  pda: {
660
- "seeds": [{
661
- "kind": "const";
662
- "value": [116, 114, 97, 99, 107, 101, 114];
660
+ seeds: [{
661
+ kind: "const";
662
+ value: [116, 114, 97, 99, 107, 101, 114];
663
663
  }, {
664
- "kind": "account";
665
- "path": "vault";
664
+ kind: "account";
665
+ path: "vault";
666
666
  }];
667
667
  };
668
668
  } | {
@@ -670,18 +670,18 @@ export declare function buildValidateAndAuthorize(program: Program<AgentShield>,
670
670
  docs: ["Ephemeral session PDA \u2014 `init` ensures no double-authorization.", "Seeds include token_mint for per-token concurrent sessions."];
671
671
  writable: true;
672
672
  pda: {
673
- "seeds": [{
674
- "kind": "const";
675
- "value": [115, 101, 115, 115, 105, 111, 110];
673
+ seeds: [{
674
+ kind: "const";
675
+ value: [115, 101, 115, 115, 105, 111, 110];
676
676
  }, {
677
- "kind": "account";
678
- "path": "vault";
677
+ kind: "account";
678
+ path: "vault";
679
679
  }, {
680
- "kind": "account";
681
- "path": "agent";
680
+ kind: "account";
681
+ path: "agent";
682
682
  }, {
683
- "kind": "arg";
684
- "path": "tokenMint";
683
+ kind: "arg";
684
+ path: "tokenMint";
685
685
  }];
686
686
  };
687
687
  } | {
@@ -703,100 +703,100 @@ export declare function buildFinalizeSession(program: Program<AgentShield>, paye
703
703
  docs: ["Finalize a session after the DeFi action completes.", "Revokes token delegation, collects fees, closes the SessionAuthority PDA,", "and records the transaction in the audit log.", "Can be called by the agent or permissionlessly (for cleanup of expired sessions)."];
704
704
  discriminator: [34, 148, 144, 47, 37, 130, 206, 161];
705
705
  accounts: [{
706
- "name": "payer";
707
- "writable": true;
708
- "signer": true;
709
- }, {
710
- "name": "vault";
711
- "writable": true;
712
- "pda": {
713
- "seeds": [{
714
- "kind": "const";
715
- "value": [118, 97, 117, 108, 116];
706
+ name: "payer";
707
+ writable: true;
708
+ signer: true;
709
+ }, {
710
+ name: "vault";
711
+ writable: true;
712
+ pda: {
713
+ seeds: [{
714
+ kind: "const";
715
+ value: [118, 97, 117, 108, 116];
716
716
  }, {
717
- "kind": "account";
718
- "path": "vault.owner";
719
- "account": "agentVault";
717
+ kind: "account";
718
+ path: "vault.owner";
719
+ account: "agentVault";
720
720
  }, {
721
- "kind": "account";
722
- "path": "vault.vault_id";
723
- "account": "agentVault";
721
+ kind: "account";
722
+ path: "vault.vault_id";
723
+ account: "agentVault";
724
724
  }];
725
725
  };
726
- "relations": ["policy", "tracker", "session"];
726
+ relations: ["policy", "tracker", "session"];
727
727
  }, {
728
- "name": "policy";
729
- "pda": {
730
- "seeds": [{
731
- "kind": "const";
732
- "value": [112, 111, 108, 105, 99, 121];
728
+ name: "policy";
729
+ pda: {
730
+ seeds: [{
731
+ kind: "const";
732
+ value: [112, 111, 108, 105, 99, 121];
733
733
  }, {
734
- "kind": "account";
735
- "path": "vault";
734
+ kind: "account";
735
+ path: "vault";
736
736
  }];
737
737
  };
738
738
  }, {
739
- "name": "tracker";
740
- "writable": true;
741
- "pda": {
742
- "seeds": [{
743
- "kind": "const";
744
- "value": [116, 114, 97, 99, 107, 101, 114];
739
+ name: "tracker";
740
+ writable: true;
741
+ pda: {
742
+ seeds: [{
743
+ kind: "const";
744
+ value: [116, 114, 97, 99, 107, 101, 114];
745
745
  }, {
746
- "kind": "account";
747
- "path": "vault";
746
+ kind: "account";
747
+ path: "vault";
748
748
  }];
749
749
  };
750
750
  }, {
751
- "name": "session";
752
- "docs": ["Session rent is returned to the session's agent (who paid for it),", "not the arbitrary payer, to prevent rent theft.", "Seeds include token_mint for per-token concurrent sessions."];
753
- "writable": true;
754
- "pda": {
755
- "seeds": [{
756
- "kind": "const";
757
- "value": [115, 101, 115, 115, 105, 111, 110];
751
+ name: "session";
752
+ docs: ["Session rent is returned to the session's agent (who paid for it),", "not the arbitrary payer, to prevent rent theft.", "Seeds include token_mint for per-token concurrent sessions."];
753
+ writable: true;
754
+ pda: {
755
+ seeds: [{
756
+ kind: "const";
757
+ value: [115, 101, 115, 115, 105, 111, 110];
758
758
  }, {
759
- "kind": "account";
760
- "path": "vault";
759
+ kind: "account";
760
+ path: "vault";
761
761
  }, {
762
- "kind": "account";
763
- "path": "session.agent";
764
- "account": "sessionAuthority";
762
+ kind: "account";
763
+ path: "session.agent";
764
+ account: "sessionAuthority";
765
765
  }, {
766
- "kind": "account";
767
- "path": "session.authorized_token";
768
- "account": "sessionAuthority";
766
+ kind: "account";
767
+ path: "session.authorized_token";
768
+ account: "sessionAuthority";
769
769
  }];
770
770
  };
771
771
  }, {
772
- "name": "sessionRentRecipient";
773
- "docs": ["Validated in handler to equal session.agent."];
774
- "writable": true;
772
+ name: "sessionRentRecipient";
773
+ docs: ["Validated in handler to equal session.agent."];
774
+ writable: true;
775
775
  }, {
776
- "name": "vaultTokenAccount";
777
- "docs": ["Vault's PDA token account for the session's token (fee source + delegation revocation)"];
778
- "writable": true;
779
- "optional": true;
776
+ name: "vaultTokenAccount";
777
+ docs: ["Vault's PDA token account for the session's token (fee source + delegation revocation)"];
778
+ writable: true;
779
+ optional: true;
780
780
  }, {
781
- "name": "feeDestinationTokenAccount";
782
- "docs": ["Developer fee destination token account \u2014 must match vault.fee_destination"];
783
- "writable": true;
784
- "optional": true;
781
+ name: "feeDestinationTokenAccount";
782
+ docs: ["Developer fee destination token account \u2014 must match vault.fee_destination"];
783
+ writable: true;
784
+ optional: true;
785
785
  }, {
786
- "name": "protocolTreasuryTokenAccount";
787
- "docs": ["Protocol treasury token account \u2014 must be owned by PROTOCOL_TREASURY"];
788
- "writable": true;
789
- "optional": true;
786
+ name: "protocolTreasuryTokenAccount";
787
+ docs: ["Protocol treasury token account \u2014 must be owned by PROTOCOL_TREASURY"];
788
+ writable: true;
789
+ optional: true;
790
790
  }, {
791
- "name": "tokenProgram";
792
- "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
791
+ name: "tokenProgram";
792
+ address: "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
793
793
  }, {
794
- "name": "systemProgram";
795
- "address": "11111111111111111111111111111111";
794
+ name: "systemProgram";
795
+ address: "11111111111111111111111111111111";
796
796
  }];
797
797
  args: [{
798
- "name": "success";
799
- "type": "bool";
798
+ name: "success";
799
+ type: "bool";
800
800
  }];
801
801
  } & {
802
802
  name: "finalizeSession";
@@ -808,41 +808,41 @@ export declare function buildFinalizeSession(program: Program<AgentShield>, paye
808
808
  name: "vault";
809
809
  writable: true;
810
810
  pda: {
811
- "seeds": [{
812
- "kind": "const";
813
- "value": [118, 97, 117, 108, 116];
811
+ seeds: [{
812
+ kind: "const";
813
+ value: [118, 97, 117, 108, 116];
814
814
  }, {
815
- "kind": "account";
816
- "path": "vault.owner";
817
- "account": "agentVault";
815
+ kind: "account";
816
+ path: "vault.owner";
817
+ account: "agentVault";
818
818
  }, {
819
- "kind": "account";
820
- "path": "vault.vault_id";
821
- "account": "agentVault";
819
+ kind: "account";
820
+ path: "vault.vault_id";
821
+ account: "agentVault";
822
822
  }];
823
823
  };
824
824
  relations: ["policy", "tracker", "session"];
825
825
  } | {
826
826
  name: "policy";
827
827
  pda: {
828
- "seeds": [{
829
- "kind": "const";
830
- "value": [112, 111, 108, 105, 99, 121];
828
+ seeds: [{
829
+ kind: "const";
830
+ value: [112, 111, 108, 105, 99, 121];
831
831
  }, {
832
- "kind": "account";
833
- "path": "vault";
832
+ kind: "account";
833
+ path: "vault";
834
834
  }];
835
835
  };
836
836
  } | {
837
837
  name: "tracker";
838
838
  writable: true;
839
839
  pda: {
840
- "seeds": [{
841
- "kind": "const";
842
- "value": [116, 114, 97, 99, 107, 101, 114];
840
+ seeds: [{
841
+ kind: "const";
842
+ value: [116, 114, 97, 99, 107, 101, 114];
843
843
  }, {
844
- "kind": "account";
845
- "path": "vault";
844
+ kind: "account";
845
+ path: "vault";
846
846
  }];
847
847
  };
848
848
  } | {
@@ -850,20 +850,20 @@ export declare function buildFinalizeSession(program: Program<AgentShield>, paye
850
850
  docs: ["Session rent is returned to the session's agent (who paid for it),", "not the arbitrary payer, to prevent rent theft.", "Seeds include token_mint for per-token concurrent sessions."];
851
851
  writable: true;
852
852
  pda: {
853
- "seeds": [{
854
- "kind": "const";
855
- "value": [115, 101, 115, 115, 105, 111, 110];
853
+ seeds: [{
854
+ kind: "const";
855
+ value: [115, 101, 115, 115, 105, 111, 110];
856
856
  }, {
857
- "kind": "account";
858
- "path": "vault";
857
+ kind: "account";
858
+ path: "vault";
859
859
  }, {
860
- "kind": "account";
861
- "path": "session.agent";
862
- "account": "sessionAuthority";
860
+ kind: "account";
861
+ path: "session.agent";
862
+ account: "sessionAuthority";
863
863
  }, {
864
- "kind": "account";
865
- "path": "session.authorized_token";
866
- "account": "sessionAuthority";
864
+ kind: "account";
865
+ path: "session.authorized_token";
866
+ account: "sessionAuthority";
867
867
  }];
868
868
  };
869
869
  } | {
@@ -897,23 +897,23 @@ export declare function buildRevokeAgent(program: Program<AgentShield>, owner: P
897
897
  docs: ["Kill switch. Immediately freezes the vault, preventing all agent actions.", "Only the owner can call this. Funds can still be withdrawn by the owner."];
898
898
  discriminator: [227, 60, 209, 125, 240, 117, 163, 73];
899
899
  accounts: [{
900
- "name": "owner";
901
- "signer": true;
902
- "relations": ["vault"];
903
- }, {
904
- "name": "vault";
905
- "writable": true;
906
- "pda": {
907
- "seeds": [{
908
- "kind": "const";
909
- "value": [118, 97, 117, 108, 116];
900
+ name: "owner";
901
+ signer: true;
902
+ relations: ["vault"];
903
+ }, {
904
+ name: "vault";
905
+ writable: true;
906
+ pda: {
907
+ seeds: [{
908
+ kind: "const";
909
+ value: [118, 97, 117, 108, 116];
910
910
  }, {
911
- "kind": "account";
912
- "path": "owner";
911
+ kind: "account";
912
+ path: "owner";
913
913
  }, {
914
- "kind": "account";
915
- "path": "vault.vault_id";
916
- "account": "agentVault";
914
+ kind: "account";
915
+ path: "vault.vault_id";
916
+ account: "agentVault";
917
917
  }];
918
918
  };
919
919
  }];
@@ -928,16 +928,16 @@ export declare function buildRevokeAgent(program: Program<AgentShield>, owner: P
928
928
  name: "vault";
929
929
  writable: true;
930
930
  pda: {
931
- "seeds": [{
932
- "kind": "const";
933
- "value": [118, 97, 117, 108, 116];
931
+ seeds: [{
932
+ kind: "const";
933
+ value: [118, 97, 117, 108, 116];
934
934
  }, {
935
- "kind": "account";
936
- "path": "owner";
935
+ kind: "account";
936
+ path: "owner";
937
937
  }, {
938
- "kind": "account";
939
- "path": "vault.vault_id";
940
- "account": "agentVault";
938
+ kind: "account";
939
+ path: "vault.vault_id";
940
+ account: "agentVault";
941
941
  }];
942
942
  };
943
943
  }>;
@@ -946,30 +946,30 @@ export declare function buildReactivateVault(program: Program<AgentShield>, owne
946
946
  docs: ["Reactivate a frozen vault. Optionally rotate the agent key.", "Only the owner can call this."];
947
947
  discriminator: [245, 50, 143, 70, 114, 220, 25, 251];
948
948
  accounts: [{
949
- "name": "owner";
950
- "signer": true;
951
- "relations": ["vault"];
952
- }, {
953
- "name": "vault";
954
- "writable": true;
955
- "pda": {
956
- "seeds": [{
957
- "kind": "const";
958
- "value": [118, 97, 117, 108, 116];
949
+ name: "owner";
950
+ signer: true;
951
+ relations: ["vault"];
952
+ }, {
953
+ name: "vault";
954
+ writable: true;
955
+ pda: {
956
+ seeds: [{
957
+ kind: "const";
958
+ value: [118, 97, 117, 108, 116];
959
959
  }, {
960
- "kind": "account";
961
- "path": "owner";
960
+ kind: "account";
961
+ path: "owner";
962
962
  }, {
963
- "kind": "account";
964
- "path": "vault.vault_id";
965
- "account": "agentVault";
963
+ kind: "account";
964
+ path: "vault.vault_id";
965
+ account: "agentVault";
966
966
  }];
967
967
  };
968
968
  }];
969
969
  args: [{
970
- "name": "newAgent";
971
- "type": {
972
- "option": "pubkey";
970
+ name: "newAgent";
971
+ type: {
972
+ option: "pubkey";
973
973
  };
974
974
  }];
975
975
  } & {
@@ -982,16 +982,16 @@ export declare function buildReactivateVault(program: Program<AgentShield>, owne
982
982
  name: "vault";
983
983
  writable: true;
984
984
  pda: {
985
- "seeds": [{
986
- "kind": "const";
987
- "value": [118, 97, 117, 108, 116];
985
+ seeds: [{
986
+ kind: "const";
987
+ value: [118, 97, 117, 108, 116];
988
988
  }, {
989
- "kind": "account";
990
- "path": "owner";
989
+ kind: "account";
990
+ path: "owner";
991
991
  }, {
992
- "kind": "account";
993
- "path": "vault.vault_id";
994
- "account": "agentVault";
992
+ kind: "account";
993
+ path: "vault.vault_id";
994
+ account: "agentVault";
995
995
  }];
996
996
  };
997
997
  }>;
@@ -1000,74 +1000,74 @@ export declare function buildWithdrawFunds(program: Program<AgentShield>, owner:
1000
1000
  docs: ["Withdraw tokens from the vault back to the owner.", "Works in any vault status (Active or Frozen). Only the owner can call this."];
1001
1001
  discriminator: [241, 36, 29, 111, 208, 31, 104, 217];
1002
1002
  accounts: [{
1003
- "name": "owner";
1004
- "writable": true;
1005
- "signer": true;
1006
- "relations": ["vault"];
1007
- }, {
1008
- "name": "vault";
1009
- "pda": {
1010
- "seeds": [{
1011
- "kind": "const";
1012
- "value": [118, 97, 117, 108, 116];
1003
+ name: "owner";
1004
+ writable: true;
1005
+ signer: true;
1006
+ relations: ["vault"];
1007
+ }, {
1008
+ name: "vault";
1009
+ pda: {
1010
+ seeds: [{
1011
+ kind: "const";
1012
+ value: [118, 97, 117, 108, 116];
1013
1013
  }, {
1014
- "kind": "account";
1015
- "path": "owner";
1014
+ kind: "account";
1015
+ path: "owner";
1016
1016
  }, {
1017
- "kind": "account";
1018
- "path": "vault.vault_id";
1019
- "account": "agentVault";
1017
+ kind: "account";
1018
+ path: "vault.vault_id";
1019
+ account: "agentVault";
1020
1020
  }];
1021
1021
  };
1022
1022
  }, {
1023
- "name": "mint";
1023
+ name: "mint";
1024
1024
  }, {
1025
- "name": "vaultTokenAccount";
1026
- "docs": ["Vault's PDA-controlled token account"];
1027
- "writable": true;
1028
- "pda": {
1029
- "seeds": [{
1030
- "kind": "account";
1031
- "path": "vault";
1025
+ name: "vaultTokenAccount";
1026
+ docs: ["Vault's PDA-controlled token account"];
1027
+ writable: true;
1028
+ pda: {
1029
+ seeds: [{
1030
+ kind: "account";
1031
+ path: "vault";
1032
1032
  }, {
1033
- "kind": "const";
1034
- "value": [6, 221, 246, 225, 215, 101, 161, 147, 217, 203, 225, 70, 206, 235, 121, 172, 28, 180, 133, 237, 95, 91, 55, 145, 58, 140, 245, 133, 126, 255, 0, 169];
1033
+ kind: "const";
1034
+ value: [6, 221, 246, 225, 215, 101, 161, 147, 217, 203, 225, 70, 206, 235, 121, 172, 28, 180, 133, 237, 95, 91, 55, 145, 58, 140, 245, 133, 126, 255, 0, 169];
1035
1035
  }, {
1036
- "kind": "account";
1037
- "path": "mint";
1036
+ kind: "account";
1037
+ path: "mint";
1038
1038
  }];
1039
- "program": {
1040
- "kind": "const";
1041
- "value": [140, 151, 37, 143, 78, 36, 137, 241, 187, 61, 16, 41, 20, 142, 13, 131, 11, 90, 19, 153, 218, 255, 16, 132, 4, 142, 123, 216, 219, 233, 248, 89];
1039
+ program: {
1040
+ kind: "const";
1041
+ value: [140, 151, 37, 143, 78, 36, 137, 241, 187, 61, 16, 41, 20, 142, 13, 131, 11, 90, 19, 153, 218, 255, 16, 132, 4, 142, 123, 216, 219, 233, 248, 89];
1042
1042
  };
1043
1043
  };
1044
1044
  }, {
1045
- "name": "ownerTokenAccount";
1046
- "docs": ["Owner's token account to receive funds"];
1047
- "writable": true;
1048
- "pda": {
1049
- "seeds": [{
1050
- "kind": "account";
1051
- "path": "owner";
1045
+ name: "ownerTokenAccount";
1046
+ docs: ["Owner's token account to receive funds"];
1047
+ writable: true;
1048
+ pda: {
1049
+ seeds: [{
1050
+ kind: "account";
1051
+ path: "owner";
1052
1052
  }, {
1053
- "kind": "const";
1054
- "value": [6, 221, 246, 225, 215, 101, 161, 147, 217, 203, 225, 70, 206, 235, 121, 172, 28, 180, 133, 237, 95, 91, 55, 145, 58, 140, 245, 133, 126, 255, 0, 169];
1053
+ kind: "const";
1054
+ value: [6, 221, 246, 225, 215, 101, 161, 147, 217, 203, 225, 70, 206, 235, 121, 172, 28, 180, 133, 237, 95, 91, 55, 145, 58, 140, 245, 133, 126, 255, 0, 169];
1055
1055
  }, {
1056
- "kind": "account";
1057
- "path": "mint";
1056
+ kind: "account";
1057
+ path: "mint";
1058
1058
  }];
1059
- "program": {
1060
- "kind": "const";
1061
- "value": [140, 151, 37, 143, 78, 36, 137, 241, 187, 61, 16, 41, 20, 142, 13, 131, 11, 90, 19, 153, 218, 255, 16, 132, 4, 142, 123, 216, 219, 233, 248, 89];
1059
+ program: {
1060
+ kind: "const";
1061
+ value: [140, 151, 37, 143, 78, 36, 137, 241, 187, 61, 16, 41, 20, 142, 13, 131, 11, 90, 19, 153, 218, 255, 16, 132, 4, 142, 123, 216, 219, 233, 248, 89];
1062
1062
  };
1063
1063
  };
1064
1064
  }, {
1065
- "name": "tokenProgram";
1066
- "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
1065
+ name: "tokenProgram";
1066
+ address: "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
1067
1067
  }];
1068
1068
  args: [{
1069
- "name": "amount";
1070
- "type": "u64";
1069
+ name: "amount";
1070
+ type: "u64";
1071
1071
  }];
1072
1072
  } & {
1073
1073
  name: "withdrawFunds";
@@ -1079,16 +1079,16 @@ export declare function buildWithdrawFunds(program: Program<AgentShield>, owner:
1079
1079
  } | {
1080
1080
  name: "vault";
1081
1081
  pda: {
1082
- "seeds": [{
1083
- "kind": "const";
1084
- "value": [118, 97, 117, 108, 116];
1082
+ seeds: [{
1083
+ kind: "const";
1084
+ value: [118, 97, 117, 108, 116];
1085
1085
  }, {
1086
- "kind": "account";
1087
- "path": "owner";
1086
+ kind: "account";
1087
+ path: "owner";
1088
1088
  }, {
1089
- "kind": "account";
1090
- "path": "vault.vault_id";
1091
- "account": "agentVault";
1089
+ kind: "account";
1090
+ path: "vault.vault_id";
1091
+ account: "agentVault";
1092
1092
  }];
1093
1093
  };
1094
1094
  } | {
@@ -1098,19 +1098,19 @@ export declare function buildWithdrawFunds(program: Program<AgentShield>, owner:
1098
1098
  docs: ["Vault's PDA-controlled token account"];
1099
1099
  writable: true;
1100
1100
  pda: {
1101
- "seeds": [{
1102
- "kind": "account";
1103
- "path": "vault";
1101
+ seeds: [{
1102
+ kind: "account";
1103
+ path: "vault";
1104
1104
  }, {
1105
- "kind": "const";
1106
- "value": [6, 221, 246, 225, 215, 101, 161, 147, 217, 203, 225, 70, 206, 235, 121, 172, 28, 180, 133, 237, 95, 91, 55, 145, 58, 140, 245, 133, 126, 255, 0, 169];
1105
+ kind: "const";
1106
+ value: [6, 221, 246, 225, 215, 101, 161, 147, 217, 203, 225, 70, 206, 235, 121, 172, 28, 180, 133, 237, 95, 91, 55, 145, 58, 140, 245, 133, 126, 255, 0, 169];
1107
1107
  }, {
1108
- "kind": "account";
1109
- "path": "mint";
1108
+ kind: "account";
1109
+ path: "mint";
1110
1110
  }];
1111
- "program": {
1112
- "kind": "const";
1113
- "value": [140, 151, 37, 143, 78, 36, 137, 241, 187, 61, 16, 41, 20, 142, 13, 131, 11, 90, 19, 153, 218, 255, 16, 132, 4, 142, 123, 216, 219, 233, 248, 89];
1111
+ program: {
1112
+ kind: "const";
1113
+ value: [140, 151, 37, 143, 78, 36, 137, 241, 187, 61, 16, 41, 20, 142, 13, 131, 11, 90, 19, 153, 218, 255, 16, 132, 4, 142, 123, 216, 219, 233, 248, 89];
1114
1114
  };
1115
1115
  };
1116
1116
  } | {
@@ -1118,19 +1118,19 @@ export declare function buildWithdrawFunds(program: Program<AgentShield>, owner:
1118
1118
  docs: ["Owner's token account to receive funds"];
1119
1119
  writable: true;
1120
1120
  pda: {
1121
- "seeds": [{
1122
- "kind": "account";
1123
- "path": "owner";
1121
+ seeds: [{
1122
+ kind: "account";
1123
+ path: "owner";
1124
1124
  }, {
1125
- "kind": "const";
1126
- "value": [6, 221, 246, 225, 215, 101, 161, 147, 217, 203, 225, 70, 206, 235, 121, 172, 28, 180, 133, 237, 95, 91, 55, 145, 58, 140, 245, 133, 126, 255, 0, 169];
1125
+ kind: "const";
1126
+ value: [6, 221, 246, 225, 215, 101, 161, 147, 217, 203, 225, 70, 206, 235, 121, 172, 28, 180, 133, 237, 95, 91, 55, 145, 58, 140, 245, 133, 126, 255, 0, 169];
1127
1127
  }, {
1128
- "kind": "account";
1129
- "path": "mint";
1128
+ kind: "account";
1129
+ path: "mint";
1130
1130
  }];
1131
- "program": {
1132
- "kind": "const";
1133
- "value": [140, 151, 37, 143, 78, 36, 137, 241, 187, 61, 16, 41, 20, 142, 13, 131, 11, 90, 19, 153, 218, 255, 16, 132, 4, 142, 123, 216, 219, 233, 248, 89];
1131
+ program: {
1132
+ kind: "const";
1133
+ value: [140, 151, 37, 143, 78, 36, 137, 241, 187, 61, 16, 41, 20, 142, 13, 131, 11, 90, 19, 153, 218, 255, 16, 132, 4, 142, 123, 216, 219, 233, 248, 89];
1134
1134
  };
1135
1135
  };
1136
1136
  } | {
@@ -1142,54 +1142,54 @@ export declare function buildCloseVault(program: Program<AgentShield>, owner: Pu
1142
1142
  docs: ["Close the vault entirely. Withdraws all remaining funds and closes all PDAs.", "Reclaims rent. Vault must have no open positions. Only the owner can call this."];
1143
1143
  discriminator: [141, 103, 17, 126, 72, 75, 29, 29];
1144
1144
  accounts: [{
1145
- "name": "owner";
1146
- "writable": true;
1147
- "signer": true;
1148
- "relations": ["vault"];
1149
- }, {
1150
- "name": "vault";
1151
- "writable": true;
1152
- "pda": {
1153
- "seeds": [{
1154
- "kind": "const";
1155
- "value": [118, 97, 117, 108, 116];
1145
+ name: "owner";
1146
+ writable: true;
1147
+ signer: true;
1148
+ relations: ["vault"];
1149
+ }, {
1150
+ name: "vault";
1151
+ writable: true;
1152
+ pda: {
1153
+ seeds: [{
1154
+ kind: "const";
1155
+ value: [118, 97, 117, 108, 116];
1156
1156
  }, {
1157
- "kind": "account";
1158
- "path": "owner";
1157
+ kind: "account";
1158
+ path: "owner";
1159
1159
  }, {
1160
- "kind": "account";
1161
- "path": "vault.vault_id";
1162
- "account": "agentVault";
1160
+ kind: "account";
1161
+ path: "vault.vault_id";
1162
+ account: "agentVault";
1163
1163
  }];
1164
1164
  };
1165
- "relations": ["policy", "tracker"];
1165
+ relations: ["policy", "tracker"];
1166
1166
  }, {
1167
- "name": "policy";
1168
- "writable": true;
1169
- "pda": {
1170
- "seeds": [{
1171
- "kind": "const";
1172
- "value": [112, 111, 108, 105, 99, 121];
1167
+ name: "policy";
1168
+ writable: true;
1169
+ pda: {
1170
+ seeds: [{
1171
+ kind: "const";
1172
+ value: [112, 111, 108, 105, 99, 121];
1173
1173
  }, {
1174
- "kind": "account";
1175
- "path": "vault";
1174
+ kind: "account";
1175
+ path: "vault";
1176
1176
  }];
1177
1177
  };
1178
1178
  }, {
1179
- "name": "tracker";
1180
- "writable": true;
1181
- "pda": {
1182
- "seeds": [{
1183
- "kind": "const";
1184
- "value": [116, 114, 97, 99, 107, 101, 114];
1179
+ name: "tracker";
1180
+ writable: true;
1181
+ pda: {
1182
+ seeds: [{
1183
+ kind: "const";
1184
+ value: [116, 114, 97, 99, 107, 101, 114];
1185
1185
  }, {
1186
- "kind": "account";
1187
- "path": "vault";
1186
+ kind: "account";
1187
+ path: "vault";
1188
1188
  }];
1189
1189
  };
1190
1190
  }, {
1191
- "name": "systemProgram";
1192
- "address": "11111111111111111111111111111111";
1191
+ name: "systemProgram";
1192
+ address: "11111111111111111111111111111111";
1193
1193
  }];
1194
1194
  args: [];
1195
1195
  } & {
@@ -1203,16 +1203,16 @@ export declare function buildCloseVault(program: Program<AgentShield>, owner: Pu
1203
1203
  name: "vault";
1204
1204
  writable: true;
1205
1205
  pda: {
1206
- "seeds": [{
1207
- "kind": "const";
1208
- "value": [118, 97, 117, 108, 116];
1206
+ seeds: [{
1207
+ kind: "const";
1208
+ value: [118, 97, 117, 108, 116];
1209
1209
  }, {
1210
- "kind": "account";
1211
- "path": "owner";
1210
+ kind: "account";
1211
+ path: "owner";
1212
1212
  }, {
1213
- "kind": "account";
1214
- "path": "vault.vault_id";
1215
- "account": "agentVault";
1213
+ kind: "account";
1214
+ path: "vault.vault_id";
1215
+ account: "agentVault";
1216
1216
  }];
1217
1217
  };
1218
1218
  relations: ["policy", "tracker"];
@@ -1220,24 +1220,24 @@ export declare function buildCloseVault(program: Program<AgentShield>, owner: Pu
1220
1220
  name: "policy";
1221
1221
  writable: true;
1222
1222
  pda: {
1223
- "seeds": [{
1224
- "kind": "const";
1225
- "value": [112, 111, 108, 105, 99, 121];
1223
+ seeds: [{
1224
+ kind: "const";
1225
+ value: [112, 111, 108, 105, 99, 121];
1226
1226
  }, {
1227
- "kind": "account";
1228
- "path": "vault";
1227
+ kind: "account";
1228
+ path: "vault";
1229
1229
  }];
1230
1230
  };
1231
1231
  } | {
1232
1232
  name: "tracker";
1233
1233
  writable: true;
1234
1234
  pda: {
1235
- "seeds": [{
1236
- "kind": "const";
1237
- "value": [116, 114, 97, 99, 107, 101, 114];
1235
+ seeds: [{
1236
+ kind: "const";
1237
+ value: [116, 114, 97, 99, 107, 101, 114];
1238
1238
  }, {
1239
- "kind": "account";
1240
- "path": "vault";
1239
+ kind: "account";
1240
+ path: "vault";
1241
1241
  }];
1242
1242
  };
1243
1243
  } | {
@@ -1249,111 +1249,111 @@ export declare function buildQueuePolicyUpdate(program: Program<AgentShield>, ow
1249
1249
  docs: ["Queue a policy update when timelock is active.", "Creates a PendingPolicyUpdate PDA that becomes executable after", "the timelock period expires."];
1250
1250
  discriminator: [149, 18, 76, 197, 179, 193, 91, 77];
1251
1251
  accounts: [{
1252
- "name": "owner";
1253
- "writable": true;
1254
- "signer": true;
1255
- "relations": ["vault"];
1256
- }, {
1257
- "name": "vault";
1258
- "pda": {
1259
- "seeds": [{
1260
- "kind": "const";
1261
- "value": [118, 97, 117, 108, 116];
1252
+ name: "owner";
1253
+ writable: true;
1254
+ signer: true;
1255
+ relations: ["vault"];
1256
+ }, {
1257
+ name: "vault";
1258
+ pda: {
1259
+ seeds: [{
1260
+ kind: "const";
1261
+ value: [118, 97, 117, 108, 116];
1262
1262
  }, {
1263
- "kind": "account";
1264
- "path": "owner";
1263
+ kind: "account";
1264
+ path: "owner";
1265
1265
  }, {
1266
- "kind": "account";
1267
- "path": "vault.vault_id";
1268
- "account": "agentVault";
1266
+ kind: "account";
1267
+ path: "vault.vault_id";
1268
+ account: "agentVault";
1269
1269
  }];
1270
1270
  };
1271
- "relations": ["policy"];
1271
+ relations: ["policy"];
1272
1272
  }, {
1273
- "name": "policy";
1274
- "pda": {
1275
- "seeds": [{
1276
- "kind": "const";
1277
- "value": [112, 111, 108, 105, 99, 121];
1273
+ name: "policy";
1274
+ pda: {
1275
+ seeds: [{
1276
+ kind: "const";
1277
+ value: [112, 111, 108, 105, 99, 121];
1278
1278
  }, {
1279
- "kind": "account";
1280
- "path": "vault";
1279
+ kind: "account";
1280
+ path: "vault";
1281
1281
  }];
1282
1282
  };
1283
1283
  }, {
1284
- "name": "pendingPolicy";
1285
- "writable": true;
1286
- "pda": {
1287
- "seeds": [{
1288
- "kind": "const";
1289
- "value": [112, 101, 110, 100, 105, 110, 103, 95, 112, 111, 108, 105, 99, 121];
1284
+ name: "pendingPolicy";
1285
+ writable: true;
1286
+ pda: {
1287
+ seeds: [{
1288
+ kind: "const";
1289
+ value: [112, 101, 110, 100, 105, 110, 103, 95, 112, 111, 108, 105, 99, 121];
1290
1290
  }, {
1291
- "kind": "account";
1292
- "path": "vault";
1291
+ kind: "account";
1292
+ path: "vault";
1293
1293
  }];
1294
1294
  };
1295
1295
  }, {
1296
- "name": "systemProgram";
1297
- "address": "11111111111111111111111111111111";
1296
+ name: "systemProgram";
1297
+ address: "11111111111111111111111111111111";
1298
1298
  }];
1299
1299
  args: [{
1300
- "name": "dailySpendingCapUsd";
1301
- "type": {
1302
- "option": "u64";
1300
+ name: "dailySpendingCapUsd";
1301
+ type: {
1302
+ option: "u64";
1303
1303
  };
1304
1304
  }, {
1305
- "name": "maxTransactionAmountUsd";
1306
- "type": {
1307
- "option": "u64";
1305
+ name: "maxTransactionAmountUsd";
1306
+ type: {
1307
+ option: "u64";
1308
1308
  };
1309
1309
  }, {
1310
- "name": "allowedTokens";
1311
- "type": {
1312
- "option": {
1313
- "vec": {
1314
- "defined": {
1315
- "name": "allowedToken";
1310
+ name: "allowedTokens";
1311
+ type: {
1312
+ option: {
1313
+ vec: {
1314
+ defined: {
1315
+ name: "allowedToken";
1316
1316
  };
1317
1317
  };
1318
1318
  };
1319
1319
  };
1320
1320
  }, {
1321
- "name": "allowedProtocols";
1322
- "type": {
1323
- "option": {
1324
- "vec": "pubkey";
1321
+ name: "allowedProtocols";
1322
+ type: {
1323
+ option: {
1324
+ vec: "pubkey";
1325
1325
  };
1326
1326
  };
1327
1327
  }, {
1328
- "name": "maxLeverageBps";
1329
- "type": {
1330
- "option": "u16";
1328
+ name: "maxLeverageBps";
1329
+ type: {
1330
+ option: "u16";
1331
1331
  };
1332
1332
  }, {
1333
- "name": "canOpenPositions";
1334
- "type": {
1335
- "option": "bool";
1333
+ name: "canOpenPositions";
1334
+ type: {
1335
+ option: "bool";
1336
1336
  };
1337
1337
  }, {
1338
- "name": "maxConcurrentPositions";
1339
- "type": {
1340
- "option": "u8";
1338
+ name: "maxConcurrentPositions";
1339
+ type: {
1340
+ option: "u8";
1341
1341
  };
1342
1342
  }, {
1343
- "name": "developerFeeRate";
1344
- "type": {
1345
- "option": "u16";
1343
+ name: "developerFeeRate";
1344
+ type: {
1345
+ option: "u16";
1346
1346
  };
1347
1347
  }, {
1348
- "name": "timelockDuration";
1349
- "type": {
1350
- "option": "u64";
1348
+ name: "timelockDuration";
1349
+ type: {
1350
+ option: "u64";
1351
1351
  };
1352
1352
  }, {
1353
- "name": "allowedDestinations";
1354
- "type": {
1355
- "option": {
1356
- "vec": "pubkey";
1353
+ name: "allowedDestinations";
1354
+ type: {
1355
+ option: {
1356
+ vec: "pubkey";
1357
1357
  };
1358
1358
  };
1359
1359
  }];
@@ -1367,40 +1367,40 @@ export declare function buildQueuePolicyUpdate(program: Program<AgentShield>, ow
1367
1367
  } | {
1368
1368
  name: "vault";
1369
1369
  pda: {
1370
- "seeds": [{
1371
- "kind": "const";
1372
- "value": [118, 97, 117, 108, 116];
1370
+ seeds: [{
1371
+ kind: "const";
1372
+ value: [118, 97, 117, 108, 116];
1373
1373
  }, {
1374
- "kind": "account";
1375
- "path": "owner";
1374
+ kind: "account";
1375
+ path: "owner";
1376
1376
  }, {
1377
- "kind": "account";
1378
- "path": "vault.vault_id";
1379
- "account": "agentVault";
1377
+ kind: "account";
1378
+ path: "vault.vault_id";
1379
+ account: "agentVault";
1380
1380
  }];
1381
1381
  };
1382
1382
  relations: ["policy"];
1383
1383
  } | {
1384
1384
  name: "policy";
1385
1385
  pda: {
1386
- "seeds": [{
1387
- "kind": "const";
1388
- "value": [112, 111, 108, 105, 99, 121];
1386
+ seeds: [{
1387
+ kind: "const";
1388
+ value: [112, 111, 108, 105, 99, 121];
1389
1389
  }, {
1390
- "kind": "account";
1391
- "path": "vault";
1390
+ kind: "account";
1391
+ path: "vault";
1392
1392
  }];
1393
1393
  };
1394
1394
  } | {
1395
1395
  name: "pendingPolicy";
1396
1396
  writable: true;
1397
1397
  pda: {
1398
- "seeds": [{
1399
- "kind": "const";
1400
- "value": [112, 101, 110, 100, 105, 110, 103, 95, 112, 111, 108, 105, 99, 121];
1398
+ seeds: [{
1399
+ kind: "const";
1400
+ value: [112, 101, 110, 100, 105, 110, 103, 95, 112, 111, 108, 105, 99, 121];
1401
1401
  }, {
1402
- "kind": "account";
1403
- "path": "vault";
1402
+ kind: "account";
1403
+ path: "vault";
1404
1404
  }];
1405
1405
  };
1406
1406
  } | {
@@ -1412,60 +1412,60 @@ export declare function buildApplyPendingPolicy(program: Program<AgentShield>, o
1412
1412
  docs: ["Apply a queued policy update after the timelock period has expired.", "Closes the PendingPolicyUpdate PDA and returns rent to the owner."];
1413
1413
  discriminator: [114, 212, 19, 227, 89, 199, 74, 62];
1414
1414
  accounts: [{
1415
- "name": "owner";
1416
- "writable": true;
1417
- "signer": true;
1418
- "relations": ["vault"];
1419
- }, {
1420
- "name": "vault";
1421
- "pda": {
1422
- "seeds": [{
1423
- "kind": "const";
1424
- "value": [118, 97, 117, 108, 116];
1415
+ name: "owner";
1416
+ writable: true;
1417
+ signer: true;
1418
+ relations: ["vault"];
1419
+ }, {
1420
+ name: "vault";
1421
+ pda: {
1422
+ seeds: [{
1423
+ kind: "const";
1424
+ value: [118, 97, 117, 108, 116];
1425
1425
  }, {
1426
- "kind": "account";
1427
- "path": "owner";
1426
+ kind: "account";
1427
+ path: "owner";
1428
1428
  }, {
1429
- "kind": "account";
1430
- "path": "vault.vault_id";
1431
- "account": "agentVault";
1429
+ kind: "account";
1430
+ path: "vault.vault_id";
1431
+ account: "agentVault";
1432
1432
  }];
1433
1433
  };
1434
- "relations": ["policy", "tracker", "pendingPolicy"];
1434
+ relations: ["policy", "tracker", "pendingPolicy"];
1435
1435
  }, {
1436
- "name": "policy";
1437
- "writable": true;
1438
- "pda": {
1439
- "seeds": [{
1440
- "kind": "const";
1441
- "value": [112, 111, 108, 105, 99, 121];
1436
+ name: "policy";
1437
+ writable: true;
1438
+ pda: {
1439
+ seeds: [{
1440
+ kind: "const";
1441
+ value: [112, 111, 108, 105, 99, 121];
1442
1442
  }, {
1443
- "kind": "account";
1444
- "path": "vault";
1443
+ kind: "account";
1444
+ path: "vault";
1445
1445
  }];
1446
1446
  };
1447
1447
  }, {
1448
- "name": "tracker";
1449
- "writable": true;
1450
- "pda": {
1451
- "seeds": [{
1452
- "kind": "const";
1453
- "value": [116, 114, 97, 99, 107, 101, 114];
1448
+ name: "tracker";
1449
+ writable: true;
1450
+ pda: {
1451
+ seeds: [{
1452
+ kind: "const";
1453
+ value: [116, 114, 97, 99, 107, 101, 114];
1454
1454
  }, {
1455
- "kind": "account";
1456
- "path": "vault";
1455
+ kind: "account";
1456
+ path: "vault";
1457
1457
  }];
1458
1458
  };
1459
1459
  }, {
1460
- "name": "pendingPolicy";
1461
- "writable": true;
1462
- "pda": {
1463
- "seeds": [{
1464
- "kind": "const";
1465
- "value": [112, 101, 110, 100, 105, 110, 103, 95, 112, 111, 108, 105, 99, 121];
1460
+ name: "pendingPolicy";
1461
+ writable: true;
1462
+ pda: {
1463
+ seeds: [{
1464
+ kind: "const";
1465
+ value: [112, 101, 110, 100, 105, 110, 103, 95, 112, 111, 108, 105, 99, 121];
1466
1466
  }, {
1467
- "kind": "account";
1468
- "path": "vault";
1467
+ kind: "account";
1468
+ path: "vault";
1469
1469
  }];
1470
1470
  };
1471
1471
  }];
@@ -1480,16 +1480,16 @@ export declare function buildApplyPendingPolicy(program: Program<AgentShield>, o
1480
1480
  } | {
1481
1481
  name: "vault";
1482
1482
  pda: {
1483
- "seeds": [{
1484
- "kind": "const";
1485
- "value": [118, 97, 117, 108, 116];
1483
+ seeds: [{
1484
+ kind: "const";
1485
+ value: [118, 97, 117, 108, 116];
1486
1486
  }, {
1487
- "kind": "account";
1488
- "path": "owner";
1487
+ kind: "account";
1488
+ path: "owner";
1489
1489
  }, {
1490
- "kind": "account";
1491
- "path": "vault.vault_id";
1492
- "account": "agentVault";
1490
+ kind: "account";
1491
+ path: "vault.vault_id";
1492
+ account: "agentVault";
1493
1493
  }];
1494
1494
  };
1495
1495
  relations: ["policy", "tracker", "pendingPolicy"];
@@ -1497,36 +1497,36 @@ export declare function buildApplyPendingPolicy(program: Program<AgentShield>, o
1497
1497
  name: "policy";
1498
1498
  writable: true;
1499
1499
  pda: {
1500
- "seeds": [{
1501
- "kind": "const";
1502
- "value": [112, 111, 108, 105, 99, 121];
1500
+ seeds: [{
1501
+ kind: "const";
1502
+ value: [112, 111, 108, 105, 99, 121];
1503
1503
  }, {
1504
- "kind": "account";
1505
- "path": "vault";
1504
+ kind: "account";
1505
+ path: "vault";
1506
1506
  }];
1507
1507
  };
1508
1508
  } | {
1509
1509
  name: "tracker";
1510
1510
  writable: true;
1511
1511
  pda: {
1512
- "seeds": [{
1513
- "kind": "const";
1514
- "value": [116, 114, 97, 99, 107, 101, 114];
1512
+ seeds: [{
1513
+ kind: "const";
1514
+ value: [116, 114, 97, 99, 107, 101, 114];
1515
1515
  }, {
1516
- "kind": "account";
1517
- "path": "vault";
1516
+ kind: "account";
1517
+ path: "vault";
1518
1518
  }];
1519
1519
  };
1520
1520
  } | {
1521
1521
  name: "pendingPolicy";
1522
1522
  writable: true;
1523
1523
  pda: {
1524
- "seeds": [{
1525
- "kind": "const";
1526
- "value": [112, 101, 110, 100, 105, 110, 103, 95, 112, 111, 108, 105, 99, 121];
1524
+ seeds: [{
1525
+ kind: "const";
1526
+ value: [112, 101, 110, 100, 105, 110, 103, 95, 112, 111, 108, 105, 99, 121];
1527
1527
  }, {
1528
- "kind": "account";
1529
- "path": "vault";
1528
+ kind: "account";
1529
+ path: "vault";
1530
1530
  }];
1531
1531
  };
1532
1532
  }>;
@@ -1535,36 +1535,36 @@ export declare function buildCancelPendingPolicy(program: Program<AgentShield>,
1535
1535
  docs: ["Cancel a queued policy update. Closes the PendingPolicyUpdate PDA", "and returns rent to the owner."];
1536
1536
  discriminator: [153, 36, 104, 200, 50, 94, 207, 33];
1537
1537
  accounts: [{
1538
- "name": "owner";
1539
- "writable": true;
1540
- "signer": true;
1541
- "relations": ["vault"];
1542
- }, {
1543
- "name": "vault";
1544
- "pda": {
1545
- "seeds": [{
1546
- "kind": "const";
1547
- "value": [118, 97, 117, 108, 116];
1538
+ name: "owner";
1539
+ writable: true;
1540
+ signer: true;
1541
+ relations: ["vault"];
1542
+ }, {
1543
+ name: "vault";
1544
+ pda: {
1545
+ seeds: [{
1546
+ kind: "const";
1547
+ value: [118, 97, 117, 108, 116];
1548
1548
  }, {
1549
- "kind": "account";
1550
- "path": "owner";
1549
+ kind: "account";
1550
+ path: "owner";
1551
1551
  }, {
1552
- "kind": "account";
1553
- "path": "vault.vault_id";
1554
- "account": "agentVault";
1552
+ kind: "account";
1553
+ path: "vault.vault_id";
1554
+ account: "agentVault";
1555
1555
  }];
1556
1556
  };
1557
- "relations": ["pendingPolicy"];
1557
+ relations: ["pendingPolicy"];
1558
1558
  }, {
1559
- "name": "pendingPolicy";
1560
- "writable": true;
1561
- "pda": {
1562
- "seeds": [{
1563
- "kind": "const";
1564
- "value": [112, 101, 110, 100, 105, 110, 103, 95, 112, 111, 108, 105, 99, 121];
1559
+ name: "pendingPolicy";
1560
+ writable: true;
1561
+ pda: {
1562
+ seeds: [{
1563
+ kind: "const";
1564
+ value: [112, 101, 110, 100, 105, 110, 103, 95, 112, 111, 108, 105, 99, 121];
1565
1565
  }, {
1566
- "kind": "account";
1567
- "path": "vault";
1566
+ kind: "account";
1567
+ path: "vault";
1568
1568
  }];
1569
1569
  };
1570
1570
  }];
@@ -1579,16 +1579,16 @@ export declare function buildCancelPendingPolicy(program: Program<AgentShield>,
1579
1579
  } | {
1580
1580
  name: "vault";
1581
1581
  pda: {
1582
- "seeds": [{
1583
- "kind": "const";
1584
- "value": [118, 97, 117, 108, 116];
1582
+ seeds: [{
1583
+ kind: "const";
1584
+ value: [118, 97, 117, 108, 116];
1585
1585
  }, {
1586
- "kind": "account";
1587
- "path": "owner";
1586
+ kind: "account";
1587
+ path: "owner";
1588
1588
  }, {
1589
- "kind": "account";
1590
- "path": "vault.vault_id";
1591
- "account": "agentVault";
1589
+ kind: "account";
1590
+ path: "vault.vault_id";
1591
+ account: "agentVault";
1592
1592
  }];
1593
1593
  };
1594
1594
  relations: ["pendingPolicy"];
@@ -1596,12 +1596,12 @@ export declare function buildCancelPendingPolicy(program: Program<AgentShield>,
1596
1596
  name: "pendingPolicy";
1597
1597
  writable: true;
1598
1598
  pda: {
1599
- "seeds": [{
1600
- "kind": "const";
1601
- "value": [112, 101, 110, 100, 105, 110, 103, 95, 112, 111, 108, 105, 99, 121];
1599
+ seeds: [{
1600
+ kind: "const";
1601
+ value: [112, 101, 110, 100, 105, 110, 103, 95, 112, 111, 108, 105, 99, 121];
1602
1602
  }, {
1603
- "kind": "account";
1604
- "path": "vault";
1603
+ kind: "account";
1604
+ path: "vault";
1605
1605
  }];
1606
1606
  };
1607
1607
  }>;
@@ -1610,75 +1610,75 @@ export declare function buildAgentTransfer(program: Program<AgentShield>, agent:
1610
1610
  docs: ["Transfer tokens from the vault to an allowed destination.", "Only the agent can call this. Respects destination allowlist,", "spending caps, and per-token limits."];
1611
1611
  discriminator: [199, 111, 151, 49, 124, 13, 150, 44];
1612
1612
  accounts: [{
1613
- "name": "agent";
1614
- "writable": true;
1615
- "signer": true;
1616
- }, {
1617
- "name": "vault";
1618
- "writable": true;
1619
- "pda": {
1620
- "seeds": [{
1621
- "kind": "const";
1622
- "value": [118, 97, 117, 108, 116];
1613
+ name: "agent";
1614
+ writable: true;
1615
+ signer: true;
1616
+ }, {
1617
+ name: "vault";
1618
+ writable: true;
1619
+ pda: {
1620
+ seeds: [{
1621
+ kind: "const";
1622
+ value: [118, 97, 117, 108, 116];
1623
1623
  }, {
1624
- "kind": "account";
1625
- "path": "vault.owner";
1626
- "account": "agentVault";
1624
+ kind: "account";
1625
+ path: "vault.owner";
1626
+ account: "agentVault";
1627
1627
  }, {
1628
- "kind": "account";
1629
- "path": "vault.vault_id";
1630
- "account": "agentVault";
1628
+ kind: "account";
1629
+ path: "vault.vault_id";
1630
+ account: "agentVault";
1631
1631
  }];
1632
1632
  };
1633
- "relations": ["policy", "tracker"];
1633
+ relations: ["policy", "tracker"];
1634
1634
  }, {
1635
- "name": "policy";
1636
- "pda": {
1637
- "seeds": [{
1638
- "kind": "const";
1639
- "value": [112, 111, 108, 105, 99, 121];
1635
+ name: "policy";
1636
+ pda: {
1637
+ seeds: [{
1638
+ kind: "const";
1639
+ value: [112, 111, 108, 105, 99, 121];
1640
1640
  }, {
1641
- "kind": "account";
1642
- "path": "vault";
1641
+ kind: "account";
1642
+ path: "vault";
1643
1643
  }];
1644
1644
  };
1645
1645
  }, {
1646
- "name": "tracker";
1647
- "writable": true;
1648
- "pda": {
1649
- "seeds": [{
1650
- "kind": "const";
1651
- "value": [116, 114, 97, 99, 107, 101, 114];
1646
+ name: "tracker";
1647
+ writable: true;
1648
+ pda: {
1649
+ seeds: [{
1650
+ kind: "const";
1651
+ value: [116, 114, 97, 99, 107, 101, 114];
1652
1652
  }, {
1653
- "kind": "account";
1654
- "path": "vault";
1653
+ kind: "account";
1654
+ path: "vault";
1655
1655
  }];
1656
1656
  };
1657
1657
  }, {
1658
- "name": "vaultTokenAccount";
1659
- "docs": ["Vault's PDA-owned token account (source)"];
1660
- "writable": true;
1658
+ name: "vaultTokenAccount";
1659
+ docs: ["Vault's PDA-owned token account (source)"];
1660
+ writable: true;
1661
1661
  }, {
1662
- "name": "destinationTokenAccount";
1663
- "docs": ["Destination token account (must be in allowed destinations if configured)"];
1664
- "writable": true;
1662
+ name: "destinationTokenAccount";
1663
+ docs: ["Destination token account (must be in allowed destinations if configured)"];
1664
+ writable: true;
1665
1665
  }, {
1666
- "name": "feeDestinationTokenAccount";
1667
- "docs": ["Developer fee destination token account \u2014 must match vault.fee_destination"];
1668
- "writable": true;
1669
- "optional": true;
1666
+ name: "feeDestinationTokenAccount";
1667
+ docs: ["Developer fee destination token account \u2014 must match vault.fee_destination"];
1668
+ writable: true;
1669
+ optional: true;
1670
1670
  }, {
1671
- "name": "protocolTreasuryTokenAccount";
1672
- "docs": ["Protocol treasury token account"];
1673
- "writable": true;
1674
- "optional": true;
1671
+ name: "protocolTreasuryTokenAccount";
1672
+ docs: ["Protocol treasury token account"];
1673
+ writable: true;
1674
+ optional: true;
1675
1675
  }, {
1676
- "name": "tokenProgram";
1677
- "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
1676
+ name: "tokenProgram";
1677
+ address: "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA";
1678
1678
  }];
1679
1679
  args: [{
1680
- "name": "amount";
1681
- "type": "u64";
1680
+ name: "amount";
1681
+ type: "u64";
1682
1682
  }];
1683
1683
  } & {
1684
1684
  name: "agentTransfer";
@@ -1690,41 +1690,41 @@ export declare function buildAgentTransfer(program: Program<AgentShield>, agent:
1690
1690
  name: "vault";
1691
1691
  writable: true;
1692
1692
  pda: {
1693
- "seeds": [{
1694
- "kind": "const";
1695
- "value": [118, 97, 117, 108, 116];
1693
+ seeds: [{
1694
+ kind: "const";
1695
+ value: [118, 97, 117, 108, 116];
1696
1696
  }, {
1697
- "kind": "account";
1698
- "path": "vault.owner";
1699
- "account": "agentVault";
1697
+ kind: "account";
1698
+ path: "vault.owner";
1699
+ account: "agentVault";
1700
1700
  }, {
1701
- "kind": "account";
1702
- "path": "vault.vault_id";
1703
- "account": "agentVault";
1701
+ kind: "account";
1702
+ path: "vault.vault_id";
1703
+ account: "agentVault";
1704
1704
  }];
1705
1705
  };
1706
1706
  relations: ["policy", "tracker"];
1707
1707
  } | {
1708
1708
  name: "policy";
1709
1709
  pda: {
1710
- "seeds": [{
1711
- "kind": "const";
1712
- "value": [112, 111, 108, 105, 99, 121];
1710
+ seeds: [{
1711
+ kind: "const";
1712
+ value: [112, 111, 108, 105, 99, 121];
1713
1713
  }, {
1714
- "kind": "account";
1715
- "path": "vault";
1714
+ kind: "account";
1715
+ path: "vault";
1716
1716
  }];
1717
1717
  };
1718
1718
  } | {
1719
1719
  name: "tracker";
1720
1720
  writable: true;
1721
1721
  pda: {
1722
- "seeds": [{
1723
- "kind": "const";
1724
- "value": [116, 114, 97, 99, 107, 101, 114];
1722
+ seeds: [{
1723
+ kind: "const";
1724
+ value: [116, 114, 97, 99, 107, 101, 114];
1725
1725
  }, {
1726
- "kind": "account";
1727
- "path": "vault";
1726
+ kind: "account";
1727
+ path: "vault";
1728
1728
  }];
1729
1729
  };
1730
1730
  } | {