@compozy/client 0.4.8 → 0.5.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.
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  // This file is auto-generated by @hey-api/openapi-ts
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
- exports.Compozy = exports.worktrees = exports.vault = exports.toolsets = exports.tools = exports.workspaces = exports.support = exports.skills = exports.tasks = exports.roles = exports.resources = exports.profiles = exports.sessions = exports.openai = exports.onboarding = exports.observe = exports.notifications = exports.providers = exports.settings = exports.marketplace = exports.loops = exports.logs = exports.hooks = exports.gateway = exports.filesystem = exports.extensions = exports.diagnostics = exports.cmdPalette = exports.automation = exports.appTokens = exports.agents = exports.agent = void 0;
4
+ exports.Compozy = exports.worktrees = exports.vault = exports.toolsets = exports.tools = exports.workspaces = exports.support = exports.skills = exports.tasks = exports.roles = exports.resources = exports.profiles = exports.sessions = exports.openai = exports.onboarding = exports.observe = exports.notifications = exports.providers = exports.settings = exports.marketplace = exports.loops = exports.logs = exports.hooks = exports.gateway = exports.filesystem = exports.extensions = exports.diagnostics = exports.cmdPalette = exports.automation = exports.appTokens = exports.agent = exports.agents = void 0;
5
5
  const client_gen_js_1 = require("./client.gen.js");
6
6
  const index_js_1 = require("./client/index.js");
7
7
  class HeyApiClient {
@@ -24,44 +24,106 @@ class HeyApiRegistry {
24
24
  this.instances.set(key ?? this.defaultKey, value);
25
25
  }
26
26
  }
27
- class agent extends HeyApiClient {
27
+ class agents extends HeyApiClient {
28
28
  /**
29
- * Return the bounded calling-agent situation context
29
+ * List agent instances
30
30
  */
31
- getAgentContext(options) {
32
- return (options.client ?? this.client).get({
31
+ listAgentInstances(options) {
32
+ return (options?.client ?? this.client).get({
33
33
  responseStyle: "data",
34
- url: "/api/agent/context",
34
+ url: "/api/agent-instances",
35
35
  ...options,
36
36
  });
37
37
  }
38
38
  /**
39
- * Read resolved coordinator config for the calling agent workspace
39
+ * Create an always-on agent instance
40
40
  */
41
- getAgentCoordinatorConfig(options) {
41
+ createAgentInstance(options) {
42
+ return (options.client ?? this.client).post({
43
+ responseStyle: "data",
44
+ url: "/api/agent-instances",
45
+ ...options,
46
+ headers: {
47
+ "Content-Type": "application/json",
48
+ ...options.headers,
49
+ },
50
+ });
51
+ }
52
+ /**
53
+ * Adopt a root session as an instance
54
+ */
55
+ adoptAgentInstance(options) {
56
+ return (options.client ?? this.client).post({
57
+ responseStyle: "data",
58
+ url: "/api/agent-instances/adopt",
59
+ ...options,
60
+ headers: {
61
+ "Content-Type": "application/json",
62
+ ...options.headers,
63
+ },
64
+ });
65
+ }
66
+ /**
67
+ * Archive an agent instance
68
+ */
69
+ archiveAgentInstance(options) {
70
+ return (options.client ?? this.client).delete({
71
+ responseStyle: "data",
72
+ url: "/api/agent-instances/{id}",
73
+ ...options,
74
+ });
75
+ }
76
+ /**
77
+ * Get an agent instance
78
+ */
79
+ getAgentInstance(options) {
42
80
  return (options.client ?? this.client).get({
43
81
  responseStyle: "data",
44
- url: "/api/agent/coordinator/config",
82
+ url: "/api/agent-instances/{id}",
45
83
  ...options,
46
84
  });
47
85
  }
48
86
  /**
49
- * Resolve the calling agent session
87
+ * Update instance checks
50
88
  */
51
- getAgentMe(options) {
89
+ updateAgentInstance(options) {
90
+ return (options.client ?? this.client).patch({
91
+ responseStyle: "data",
92
+ url: "/api/agent-instances/{id}",
93
+ ...options,
94
+ headers: {
95
+ "Content-Type": "application/json",
96
+ ...options.headers,
97
+ },
98
+ });
99
+ }
100
+ /**
101
+ * Read the operator's instance away digest
102
+ */
103
+ getAgentInstanceAway(options) {
52
104
  return (options.client ?? this.client).get({
53
105
  responseStyle: "data",
54
- url: "/api/agent/me",
106
+ url: "/api/agent-instances/{id}/away",
55
107
  ...options,
56
108
  });
57
109
  }
58
110
  /**
59
- * Notify live operator clients from the calling agent
111
+ * Mark the instance seen by the local operator
60
112
  */
61
- notifyOperator(options) {
113
+ markAgentInstanceSeen(options) {
62
114
  return (options.client ?? this.client).post({
63
115
  responseStyle: "data",
64
- url: "/api/agent/notify",
116
+ url: "/api/agent-instances/{id}/away",
117
+ ...options,
118
+ });
119
+ }
120
+ /**
121
+ * Check an agent instance
122
+ */
123
+ checkAgentInstance(options) {
124
+ return (options.client ?? this.client).post({
125
+ responseStyle: "data",
126
+ url: "/api/agent-instances/{id}/check",
65
127
  ...options,
66
128
  headers: {
67
129
  "Content-Type": "application/json",
@@ -70,22 +132,92 @@ class agent extends HeyApiClient {
70
132
  });
71
133
  }
72
134
  /**
73
- * Inspect the resolved Soul read model for the calling agent
135
+ * List instance wake events
74
136
  */
75
- getAgentSoul(options) {
137
+ listAgentInstanceCheckIns(options) {
76
138
  return (options.client ?? this.client).get({
77
139
  responseStyle: "data",
78
- url: "/api/agent/soul",
140
+ url: "/api/agent-instances/{id}/check-ins",
79
141
  ...options,
80
142
  });
81
143
  }
82
144
  /**
83
- * Validate a proposed Soul body or the calling agent's current Soul
145
+ * Ensure the main session exists
84
146
  */
85
- validateAgentSoul(options) {
147
+ ensureAgentInstanceMain(options) {
86
148
  return (options.client ?? this.client).post({
87
149
  responseStyle: "data",
88
- url: "/api/agent/soul/validate",
150
+ url: "/api/agent-instances/{id}/ensure-main",
151
+ ...options,
152
+ });
153
+ }
154
+ /**
155
+ * Read an instance check occurrence
156
+ */
157
+ getAgentInstanceOccurrence(options) {
158
+ return (options.client ?? this.client).get({
159
+ responseStyle: "data",
160
+ url: "/api/agent-instances/{id}/occurrences/{occurrence}",
161
+ ...options,
162
+ });
163
+ }
164
+ /**
165
+ * Pause an agent instance
166
+ */
167
+ pauseAgentInstance(options) {
168
+ return (options.client ?? this.client).post({
169
+ responseStyle: "data",
170
+ url: "/api/agent-instances/{id}/pause",
171
+ ...options,
172
+ });
173
+ }
174
+ /**
175
+ * List durable instance reports
176
+ */
177
+ listAgentInstanceReports(options) {
178
+ return (options.client ?? this.client).get({
179
+ responseStyle: "data",
180
+ url: "/api/agent-instances/{id}/reports",
181
+ ...options,
182
+ });
183
+ }
184
+ /**
185
+ * Resume an agent instance
186
+ */
187
+ resumeAgentInstance(options) {
188
+ return (options.client ?? this.client).post({
189
+ responseStyle: "data",
190
+ url: "/api/agent-instances/{id}/resume",
191
+ ...options,
192
+ });
193
+ }
194
+ /**
195
+ * List agent skill reviews (experimental)
196
+ */
197
+ listAgentSkillReviews(options) {
198
+ return (options?.client ?? this.client).get({
199
+ responseStyle: "data",
200
+ url: "/api/agent-skill-reviews",
201
+ ...options,
202
+ });
203
+ }
204
+ /**
205
+ * Read exact proposed skill contents (experimental)
206
+ */
207
+ getAgentSkillReview(options) {
208
+ return (options.client ?? this.client).get({
209
+ responseStyle: "data",
210
+ url: "/api/agent-skill-reviews/{id}",
211
+ ...options,
212
+ });
213
+ }
214
+ /**
215
+ * Decide a skill review as the operator (experimental)
216
+ */
217
+ approveAgentSkillReview(options) {
218
+ return (options.client ?? this.client).post({
219
+ responseStyle: "data",
220
+ url: "/api/agent-skill-reviews/{id}/approve",
89
221
  ...options,
90
222
  headers: {
91
223
  "Content-Type": "application/json",
@@ -94,12 +226,12 @@ class agent extends HeyApiClient {
94
226
  });
95
227
  }
96
228
  /**
97
- * Spawn a narrowed child session for the calling agent
229
+ * Decide a skill review as the operator (experimental)
98
230
  */
99
- spawnAgentSession(options) {
231
+ rejectAgentSkillReview(options) {
100
232
  return (options.client ?? this.client).post({
101
233
  responseStyle: "data",
102
- url: "/api/agent/spawn",
234
+ url: "/api/agent-skill-reviews/{id}/reject",
103
235
  ...options,
104
236
  headers: {
105
237
  "Content-Type": "application/json",
@@ -108,12 +240,22 @@ class agent extends HeyApiClient {
108
240
  });
109
241
  }
110
242
  /**
111
- * Atomically claim the next matching task run for the calling agent
243
+ * List all readable agent definitions, optionally resolved for a workspace
112
244
  */
113
- claimNextAgentTask(options) {
245
+ listAgents(options) {
246
+ return (options?.client ?? this.client).get({
247
+ responseStyle: "data",
248
+ url: "/api/agents",
249
+ ...options,
250
+ });
251
+ }
252
+ /**
253
+ * Create a global or workspace-local AGENT.md definition
254
+ */
255
+ createAgent(options) {
114
256
  return (options.client ?? this.client).post({
115
257
  responseStyle: "data",
116
- url: "/api/agent/tasks/claim-next",
258
+ url: "/api/agents",
117
259
  ...options,
118
260
  headers: {
119
261
  "Content-Type": "application/json",
@@ -122,12 +264,32 @@ class agent extends HeyApiClient {
122
264
  });
123
265
  }
124
266
  /**
125
- * Complete a claimed task run for the calling agent
267
+ * List a filtered agent fleet with exact session metrics
126
268
  */
127
- completeAgentTaskRun(options) {
269
+ listAgentsAggregate(options) {
270
+ return (options?.client ?? this.client).get({
271
+ responseStyle: "data",
272
+ url: "/api/agents/aggregate",
273
+ ...options,
274
+ });
275
+ }
276
+ /**
277
+ * List a filtered agent fleet with exact session metrics
278
+ */
279
+ listAgentCatalog(options) {
280
+ return (options?.client ?? this.client).get({
281
+ responseStyle: "data",
282
+ url: "/api/agents/catalog",
283
+ ...options,
284
+ });
285
+ }
286
+ /**
287
+ * Draft agent instructions without saving a definition
288
+ */
289
+ draftAgentInstructions(options) {
128
290
  return (options.client ?? this.client).post({
129
291
  responseStyle: "data",
130
- url: "/api/agent/tasks/{run_id}/complete",
292
+ url: "/api/agents/draft-instructions",
131
293
  ...options,
132
294
  headers: {
133
295
  "Content-Type": "application/json",
@@ -136,12 +298,56 @@ class agent extends HeyApiClient {
136
298
  });
137
299
  }
138
300
  /**
139
- * Fail a claimed task run for the calling agent
301
+ * Durably delete one effective authored agent definition
140
302
  */
141
- failAgentTaskRun(options) {
303
+ deleteAgent(options) {
304
+ return (options.client ?? this.client).delete({
305
+ responseStyle: "data",
306
+ url: "/api/agents/{name}",
307
+ ...options,
308
+ });
309
+ }
310
+ /**
311
+ * Get one agent definition by name, optionally resolved for a workspace
312
+ */
313
+ getAgent(options) {
314
+ return (options.client ?? this.client).get({
315
+ responseStyle: "data",
316
+ url: "/api/agents/{name}",
317
+ ...options,
318
+ });
319
+ }
320
+ /**
321
+ * Replace one effective AGENT.md definition with digest CAS
322
+ */
323
+ updateAgent(options) {
324
+ return (options.client ?? this.client).put({
325
+ responseStyle: "data",
326
+ url: "/api/agents/{name}",
327
+ ...options,
328
+ headers: {
329
+ "Content-Type": "application/json",
330
+ ...options.headers,
331
+ },
332
+ });
333
+ }
334
+ /**
335
+ * Read agent activity across authorized workspaces
336
+ */
337
+ getAgentActivity(options) {
338
+ return (options.client ?? this.client).get({
339
+ responseStyle: "data",
340
+ url: "/api/agents/{name}/activity",
341
+ ...options,
342
+ });
343
+ }
344
+ /**
345
+ * Duplicate one effective authored agent definition server-side
346
+ */
347
+ duplicateAgent(options) {
142
348
  return (options.client ?? this.client).post({
143
349
  responseStyle: "data",
144
- url: "/api/agent/tasks/{run_id}/fail",
350
+ url: "/api/agents/{name}/duplicate",
145
351
  ...options,
146
352
  headers: {
147
353
  "Content-Type": "application/json",
@@ -150,12 +356,60 @@ class agent extends HeyApiClient {
150
356
  });
151
357
  }
152
358
  /**
153
- * Extend a claimed task-run lease for the calling agent
359
+ * Delete HEARTBEAT.md through managed authoring
154
360
  */
155
- heartbeatAgentTaskRun(options) {
361
+ deleteAgentHeartbeat(options) {
362
+ return (options.client ?? this.client).delete({
363
+ responseStyle: "data",
364
+ url: "/api/agents/{name}/heartbeat",
365
+ ...options,
366
+ headers: {
367
+ "Content-Type": "application/json",
368
+ ...options.headers,
369
+ },
370
+ });
371
+ }
372
+ /**
373
+ * Inspect the resolved Heartbeat policy for an agent definition
374
+ */
375
+ getAgentHeartbeat(options) {
376
+ return (options.client ?? this.client).get({
377
+ responseStyle: "data",
378
+ url: "/api/agents/{name}/heartbeat",
379
+ ...options,
380
+ });
381
+ }
382
+ /**
383
+ * Create or replace HEARTBEAT.md through managed authoring
384
+ */
385
+ putAgentHeartbeat(options) {
386
+ return (options.client ?? this.client).put({
387
+ responseStyle: "data",
388
+ url: "/api/agents/{name}/heartbeat",
389
+ ...options,
390
+ headers: {
391
+ "Content-Type": "application/json",
392
+ ...options.headers,
393
+ },
394
+ });
395
+ }
396
+ /**
397
+ * List managed HEARTBEAT.md authoring revisions
398
+ */
399
+ listAgentHeartbeatHistory(options) {
400
+ return (options.client ?? this.client).get({
401
+ responseStyle: "data",
402
+ url: "/api/agents/{name}/heartbeat/history",
403
+ ...options,
404
+ });
405
+ }
406
+ /**
407
+ * Rollback HEARTBEAT.md through managed authoring
408
+ */
409
+ rollbackAgentHeartbeat(options) {
156
410
  return (options.client ?? this.client).post({
157
411
  responseStyle: "data",
158
- url: "/api/agent/tasks/{run_id}/heartbeat",
412
+ url: "/api/agents/{name}/heartbeat/rollback",
159
413
  ...options,
160
414
  headers: {
161
415
  "Content-Type": "application/json",
@@ -164,12 +418,22 @@ class agent extends HeyApiClient {
164
418
  });
165
419
  }
166
420
  /**
167
- * Release a claimed task run for the calling agent
421
+ * Revoke a source script approval (operator only)
168
422
  */
169
- releaseAgentTaskRun(options) {
423
+ revokeAgentHeartbeatScript(options) {
424
+ return (options.client ?? this.client).delete({
425
+ responseStyle: "data",
426
+ url: "/api/agents/{name}/heartbeat/scripts/{script}/approve",
427
+ ...options,
428
+ });
429
+ }
430
+ /**
431
+ * Approve exact source script bytes (operator only)
432
+ */
433
+ approveAgentHeartbeatScript(options) {
170
434
  return (options.client ?? this.client).post({
171
435
  responseStyle: "data",
172
- url: "/api/agent/tasks/{run_id}/release",
436
+ url: "/api/agents/{name}/heartbeat/scripts/{script}/approve",
173
437
  ...options,
174
438
  headers: {
175
439
  "Content-Type": "application/json",
@@ -178,12 +442,32 @@ class agent extends HeyApiClient {
178
442
  });
179
443
  }
180
444
  /**
181
- * Start a claimed task run under the calling agent's lease
445
+ * List check-in source kinds, scripts and effective limits
182
446
  */
183
- startAgentTaskRun(options) {
447
+ getAgentHeartbeatSources(options) {
448
+ return (options.client ?? this.client).get({
449
+ responseStyle: "data",
450
+ url: "/api/agents/{name}/heartbeat/sources",
451
+ ...options,
452
+ });
453
+ }
454
+ /**
455
+ * Read Heartbeat policy status, wake state, and optional session health
456
+ */
457
+ getAgentHeartbeatStatus(options) {
458
+ return (options.client ?? this.client).get({
459
+ responseStyle: "data",
460
+ url: "/api/agents/{name}/heartbeat/status",
461
+ ...options,
462
+ });
463
+ }
464
+ /**
465
+ * Validate a proposed HEARTBEAT.md body
466
+ */
467
+ validateAgentHeartbeat(options) {
184
468
  return (options.client ?? this.client).post({
185
469
  responseStyle: "data",
186
- url: "/api/agent/tasks/{run_id}/start",
470
+ url: "/api/agents/{name}/heartbeat/validate",
187
471
  ...options,
188
472
  headers: {
189
473
  "Content-Type": "application/json",
@@ -191,26 +475,89 @@ class agent extends HeyApiClient {
191
475
  },
192
476
  });
193
477
  }
194
- }
195
- exports.agent = agent;
196
- class agents extends HeyApiClient {
197
478
  /**
198
- * List all readable agent definitions, optionally resolved for a workspace
479
+ * Request one advisory Heartbeat wake for an eligible session
199
480
  */
200
- listAgents(options) {
201
- return (options?.client ?? this.client).get({
481
+ wakeAgentHeartbeat(options) {
482
+ return (options.client ?? this.client).post({
202
483
  responseStyle: "data",
203
- url: "/api/agents",
484
+ url: "/api/agents/{name}/heartbeat/wake",
485
+ ...options,
486
+ headers: {
487
+ "Content-Type": "application/json",
488
+ ...options.headers,
489
+ },
490
+ });
491
+ }
492
+ /**
493
+ * Inspect agent memory (experimental)
494
+ *
495
+ * @stability experimental
496
+ */
497
+ getAgentMemory(options) {
498
+ return (options.client ?? this.client).get({
499
+ responseStyle: "data",
500
+ url: "/api/agents/{name}/memory",
204
501
  ...options,
205
502
  });
206
503
  }
207
504
  /**
208
- * Create a global or workspace-local AGENT.md definition
505
+ * Replace memory with a digest check (experimental)
506
+ *
507
+ * @stability experimental
209
508
  */
210
- createAgent(options) {
509
+ putAgentMemory(options) {
510
+ return (options.client ?? this.client).put({
511
+ responseStyle: "data",
512
+ url: "/api/agents/{name}/memory",
513
+ ...options,
514
+ headers: {
515
+ "Content-Type": "application/json",
516
+ ...options.headers,
517
+ },
518
+ });
519
+ }
520
+ /**
521
+ * Remove matching memory entries (experimental)
522
+ *
523
+ * @stability experimental
524
+ */
525
+ removeAgentMemory(options) {
526
+ return (options.client ?? this.client).delete({
527
+ responseStyle: "data",
528
+ url: "/api/agents/{name}/memory/entries",
529
+ ...options,
530
+ headers: {
531
+ "Content-Type": "application/json",
532
+ ...options.headers,
533
+ },
534
+ });
535
+ }
536
+ /**
537
+ * Replace matching memory text (experimental)
538
+ *
539
+ * @stability experimental
540
+ */
541
+ replaceAgentMemory(options) {
542
+ return (options.client ?? this.client).patch({
543
+ responseStyle: "data",
544
+ url: "/api/agents/{name}/memory/entries",
545
+ ...options,
546
+ headers: {
547
+ "Content-Type": "application/json",
548
+ ...options.headers,
549
+ },
550
+ });
551
+ }
552
+ /**
553
+ * Add a dated memory entry (experimental)
554
+ *
555
+ * @stability experimental
556
+ */
557
+ addAgentMemory(options) {
211
558
  return (options.client ?? this.client).post({
212
559
  responseStyle: "data",
213
- url: "/api/agents",
560
+ url: "/api/agents/{name}/memory/entries",
214
561
  ...options,
215
562
  headers: {
216
563
  "Content-Type": "application/json",
@@ -219,52 +566,96 @@ class agents extends HeyApiClient {
219
566
  });
220
567
  }
221
568
  /**
222
- * List a filtered agent fleet with exact session metrics
569
+ * List the last fifty memory revisions (experimental)
570
+ *
571
+ * @stability experimental
223
572
  */
224
- listAgentsAggregate(options) {
225
- return (options?.client ?? this.client).get({
573
+ listAgentMemoryHistory(options) {
574
+ return (options.client ?? this.client).get({
226
575
  responseStyle: "data",
227
- url: "/api/agents/aggregate",
576
+ url: "/api/agents/{name}/memory/history",
228
577
  ...options,
229
578
  });
230
579
  }
231
580
  /**
232
- * List a filtered agent fleet with exact session metrics
581
+ * Restore a memory revision (experimental)
582
+ *
583
+ * @stability experimental
233
584
  */
234
- listAgentCatalog(options) {
235
- return (options?.client ?? this.client).get({
585
+ rollbackAgentMemory(options) {
586
+ return (options.client ?? this.client).post({
236
587
  responseStyle: "data",
237
- url: "/api/agents/catalog",
588
+ url: "/api/agents/{name}/memory/rollback",
238
589
  ...options,
590
+ headers: {
591
+ "Content-Type": "application/json",
592
+ ...options.headers,
593
+ },
239
594
  });
240
595
  }
241
596
  /**
242
- * Durably delete one effective authored agent definition
597
+ * Search agent notes and accessible sessions (experimental)
598
+ *
599
+ * @stability experimental
243
600
  */
244
- deleteAgent(options) {
601
+ searchAgentMemory(options) {
602
+ return (options.client ?? this.client).post({
603
+ responseStyle: "data",
604
+ url: "/api/agents/{name}/memory/search",
605
+ ...options,
606
+ headers: {
607
+ "Content-Type": "application/json",
608
+ ...options.headers,
609
+ },
610
+ });
611
+ }
612
+ /**
613
+ * Validate proposed memory content (experimental)
614
+ *
615
+ * @stability experimental
616
+ */
617
+ validateAgentMemory(options) {
618
+ return (options.client ?? this.client).post({
619
+ responseStyle: "data",
620
+ url: "/api/agents/{name}/memory/validate",
621
+ ...options,
622
+ headers: {
623
+ "Content-Type": "application/json",
624
+ ...options.headers,
625
+ },
626
+ });
627
+ }
628
+ /**
629
+ * Delete SOUL.md through managed authoring
630
+ */
631
+ deleteAgentSoul(options) {
245
632
  return (options.client ?? this.client).delete({
246
633
  responseStyle: "data",
247
- url: "/api/agents/{name}",
634
+ url: "/api/agents/{name}/soul",
248
635
  ...options,
636
+ headers: {
637
+ "Content-Type": "application/json",
638
+ ...options.headers,
639
+ },
249
640
  });
250
641
  }
251
642
  /**
252
- * Get one agent definition by name, optionally resolved for a workspace
643
+ * Inspect the resolved Soul read model for an agent definition
253
644
  */
254
- getAgent(options) {
645
+ getAgentDefinitionSoul(options) {
255
646
  return (options.client ?? this.client).get({
256
647
  responseStyle: "data",
257
- url: "/api/agents/{name}",
648
+ url: "/api/agents/{name}/soul",
258
649
  ...options,
259
650
  });
260
651
  }
261
652
  /**
262
- * Replace one effective AGENT.md definition with digest CAS
653
+ * Create or replace SOUL.md through managed authoring
263
654
  */
264
- updateAgent(options) {
655
+ putAgentSoul(options) {
265
656
  return (options.client ?? this.client).put({
266
657
  responseStyle: "data",
267
- url: "/api/agents/{name}",
658
+ url: "/api/agents/{name}/soul",
268
659
  ...options,
269
660
  headers: {
270
661
  "Content-Type": "application/json",
@@ -273,12 +664,22 @@ class agents extends HeyApiClient {
273
664
  });
274
665
  }
275
666
  /**
276
- * Duplicate one effective authored agent definition server-side
667
+ * List managed SOUL.md authoring revisions
277
668
  */
278
- duplicateAgent(options) {
669
+ listAgentSoulHistory(options) {
670
+ return (options.client ?? this.client).get({
671
+ responseStyle: "data",
672
+ url: "/api/agents/{name}/soul/history",
673
+ ...options,
674
+ });
675
+ }
676
+ /**
677
+ * Rollback SOUL.md through managed authoring
678
+ */
679
+ rollbackAgentSoul(options) {
279
680
  return (options.client ?? this.client).post({
280
681
  responseStyle: "data",
281
- url: "/api/agents/{name}/duplicate",
682
+ url: "/api/agents/{name}/soul/rollback",
282
683
  ...options,
283
684
  headers: {
284
685
  "Content-Type": "application/json",
@@ -287,12 +688,12 @@ class agents extends HeyApiClient {
287
688
  });
288
689
  }
289
690
  /**
290
- * Delete HEARTBEAT.md through managed authoring
691
+ * Validate a proposed Soul body for an agent definition
291
692
  */
292
- deleteAgentHeartbeat(options) {
293
- return (options.client ?? this.client).delete({
693
+ validateAgentDefinitionSoul(options) {
694
+ return (options.client ?? this.client).post({
294
695
  responseStyle: "data",
295
- url: "/api/agents/{name}/heartbeat",
696
+ url: "/api/agents/{name}/soul/validate",
296
697
  ...options,
297
698
  headers: {
298
699
  "Content-Type": "application/json",
@@ -300,47 +701,46 @@ class agents extends HeyApiClient {
300
701
  },
301
702
  });
302
703
  }
704
+ }
705
+ exports.agents = agents;
706
+ class agent extends HeyApiClient {
303
707
  /**
304
- * Inspect the resolved Heartbeat policy for an agent definition
708
+ * Return the bounded calling-agent situation context
305
709
  */
306
- getAgentHeartbeat(options) {
710
+ getAgentContext(options) {
307
711
  return (options.client ?? this.client).get({
308
712
  responseStyle: "data",
309
- url: "/api/agents/{name}/heartbeat",
713
+ url: "/api/agent/context",
310
714
  ...options,
311
715
  });
312
716
  }
313
717
  /**
314
- * Create or replace HEARTBEAT.md through managed authoring
718
+ * Read resolved coordinator config for the calling agent workspace
315
719
  */
316
- putAgentHeartbeat(options) {
317
- return (options.client ?? this.client).put({
720
+ getAgentCoordinatorConfig(options) {
721
+ return (options.client ?? this.client).get({
318
722
  responseStyle: "data",
319
- url: "/api/agents/{name}/heartbeat",
723
+ url: "/api/agent/coordinator/config",
320
724
  ...options,
321
- headers: {
322
- "Content-Type": "application/json",
323
- ...options.headers,
324
- },
325
725
  });
326
726
  }
327
727
  /**
328
- * List managed HEARTBEAT.md authoring revisions
728
+ * Resolve the calling agent session
329
729
  */
330
- listAgentHeartbeatHistory(options) {
730
+ getAgentMe(options) {
331
731
  return (options.client ?? this.client).get({
332
732
  responseStyle: "data",
333
- url: "/api/agents/{name}/heartbeat/history",
733
+ url: "/api/agent/me",
334
734
  ...options,
335
735
  });
336
736
  }
337
737
  /**
338
- * Rollback HEARTBEAT.md through managed authoring
738
+ * Notify live operator clients from the calling agent
339
739
  */
340
- rollbackAgentHeartbeat(options) {
740
+ notifyOperator(options) {
341
741
  return (options.client ?? this.client).post({
342
742
  responseStyle: "data",
343
- url: "/api/agents/{name}/heartbeat/rollback",
743
+ url: "/api/agent/notify",
344
744
  ...options,
345
745
  headers: {
346
746
  "Content-Type": "application/json",
@@ -349,22 +749,22 @@ class agents extends HeyApiClient {
349
749
  });
350
750
  }
351
751
  /**
352
- * Read Heartbeat policy status, wake state, and optional session health
752
+ * Inspect the resolved Soul read model for the calling agent
353
753
  */
354
- getAgentHeartbeatStatus(options) {
754
+ getAgentSoul(options) {
355
755
  return (options.client ?? this.client).get({
356
756
  responseStyle: "data",
357
- url: "/api/agents/{name}/heartbeat/status",
757
+ url: "/api/agent/soul",
358
758
  ...options,
359
759
  });
360
760
  }
361
761
  /**
362
- * Validate a proposed HEARTBEAT.md body
762
+ * Validate a proposed Soul body or the calling agent's current Soul
363
763
  */
364
- validateAgentHeartbeat(options) {
764
+ validateAgentSoul(options) {
365
765
  return (options.client ?? this.client).post({
366
766
  responseStyle: "data",
367
- url: "/api/agents/{name}/heartbeat/validate",
767
+ url: "/api/agent/soul/validate",
368
768
  ...options,
369
769
  headers: {
370
770
  "Content-Type": "application/json",
@@ -373,12 +773,12 @@ class agents extends HeyApiClient {
373
773
  });
374
774
  }
375
775
  /**
376
- * Request one advisory Heartbeat wake for an eligible session
776
+ * Spawn a narrowed child session for the calling agent
377
777
  */
378
- wakeAgentHeartbeat(options) {
778
+ spawnAgentSession(options) {
379
779
  return (options.client ?? this.client).post({
380
780
  responseStyle: "data",
381
- url: "/api/agents/{name}/heartbeat/wake",
781
+ url: "/api/agent/spawn",
382
782
  ...options,
383
783
  headers: {
384
784
  "Content-Type": "application/json",
@@ -387,12 +787,12 @@ class agents extends HeyApiClient {
387
787
  });
388
788
  }
389
789
  /**
390
- * Delete SOUL.md through managed authoring
790
+ * Atomically claim the next matching task run for the calling agent
391
791
  */
392
- deleteAgentSoul(options) {
393
- return (options.client ?? this.client).delete({
792
+ claimNextAgentTask(options) {
793
+ return (options.client ?? this.client).post({
394
794
  responseStyle: "data",
395
- url: "/api/agents/{name}/soul",
795
+ url: "/api/agent/tasks/claim-next",
396
796
  ...options,
397
797
  headers: {
398
798
  "Content-Type": "application/json",
@@ -401,22 +801,26 @@ class agents extends HeyApiClient {
401
801
  });
402
802
  }
403
803
  /**
404
- * Inspect the resolved Soul read model for an agent definition
804
+ * Complete a claimed task run for the calling agent
405
805
  */
406
- getAgentDefinitionSoul(options) {
407
- return (options.client ?? this.client).get({
806
+ completeAgentTaskRun(options) {
807
+ return (options.client ?? this.client).post({
408
808
  responseStyle: "data",
409
- url: "/api/agents/{name}/soul",
809
+ url: "/api/agent/tasks/{run_id}/complete",
410
810
  ...options,
811
+ headers: {
812
+ "Content-Type": "application/json",
813
+ ...options.headers,
814
+ },
411
815
  });
412
816
  }
413
817
  /**
414
- * Create or replace SOUL.md through managed authoring
818
+ * Fail a claimed task run for the calling agent
415
819
  */
416
- putAgentSoul(options) {
417
- return (options.client ?? this.client).put({
820
+ failAgentTaskRun(options) {
821
+ return (options.client ?? this.client).post({
418
822
  responseStyle: "data",
419
- url: "/api/agents/{name}/soul",
823
+ url: "/api/agent/tasks/{run_id}/fail",
420
824
  ...options,
421
825
  headers: {
422
826
  "Content-Type": "application/json",
@@ -425,22 +829,26 @@ class agents extends HeyApiClient {
425
829
  });
426
830
  }
427
831
  /**
428
- * List managed SOUL.md authoring revisions
832
+ * Extend a claimed task-run lease for the calling agent
429
833
  */
430
- listAgentSoulHistory(options) {
431
- return (options.client ?? this.client).get({
834
+ heartbeatAgentTaskRun(options) {
835
+ return (options.client ?? this.client).post({
432
836
  responseStyle: "data",
433
- url: "/api/agents/{name}/soul/history",
837
+ url: "/api/agent/tasks/{run_id}/heartbeat",
434
838
  ...options,
839
+ headers: {
840
+ "Content-Type": "application/json",
841
+ ...options.headers,
842
+ },
435
843
  });
436
844
  }
437
845
  /**
438
- * Rollback SOUL.md through managed authoring
846
+ * Release a claimed task run for the calling agent
439
847
  */
440
- rollbackAgentSoul(options) {
848
+ releaseAgentTaskRun(options) {
441
849
  return (options.client ?? this.client).post({
442
850
  responseStyle: "data",
443
- url: "/api/agents/{name}/soul/rollback",
851
+ url: "/api/agent/tasks/{run_id}/release",
444
852
  ...options,
445
853
  headers: {
446
854
  "Content-Type": "application/json",
@@ -449,12 +857,12 @@ class agents extends HeyApiClient {
449
857
  });
450
858
  }
451
859
  /**
452
- * Validate a proposed Soul body for an agent definition
860
+ * Start a claimed task run under the calling agent's lease
453
861
  */
454
- validateAgentDefinitionSoul(options) {
862
+ startAgentTaskRun(options) {
455
863
  return (options.client ?? this.client).post({
456
864
  responseStyle: "data",
457
- url: "/api/agents/{name}/soul/validate",
865
+ url: "/api/agent/tasks/{run_id}/start",
458
866
  ...options,
459
867
  headers: {
460
868
  "Content-Type": "application/json",
@@ -463,7 +871,7 @@ class agents extends HeyApiClient {
463
871
  });
464
872
  }
465
873
  }
466
- exports.agents = agents;
874
+ exports.agent = agent;
467
875
  class appTokens extends HeyApiClient {
468
876
  /**
469
877
  * List app tokens without their bearer secrets
@@ -910,6 +1318,18 @@ class cmdPalette extends HeyApiClient {
910
1318
  }
911
1319
  exports.cmdPalette = cmdPalette;
912
1320
  class diagnostics extends HeyApiClient {
1321
+ /**
1322
+ * Capture a runtime profile over the local socket
1323
+ *
1324
+ * @stability experimental
1325
+ */
1326
+ captureDaemonProfile(options) {
1327
+ return (options.client ?? this.client).get({
1328
+ responseStyle: "data",
1329
+ url: "/api/daemon/profile/{kind}",
1330
+ ...options,
1331
+ });
1332
+ }
913
1333
  /**
914
1334
  * Run runtime diagnostics
915
1335
  */
@@ -2819,6 +3239,26 @@ class observe extends HeyApiClient {
2819
3239
  ...options,
2820
3240
  });
2821
3241
  }
3242
+ /**
3243
+ * List the newest permission decisions with their initiators
3244
+ */
3245
+ listPermissionEntries(options) {
3246
+ return (options?.client ?? this.client).get({
3247
+ responseStyle: "data",
3248
+ url: "/api/permissions",
3249
+ ...options,
3250
+ });
3251
+ }
3252
+ /**
3253
+ * Read daily permission totals by agent and decision
3254
+ */
3255
+ getPermissionRollup(options) {
3256
+ return (options?.client ?? this.client).get({
3257
+ responseStyle: "data",
3258
+ url: "/api/permissions/rollup",
3259
+ ...options,
3260
+ });
3261
+ }
2822
3262
  }
2823
3263
  exports.observe = observe;
2824
3264
  class onboarding extends HeyApiClient {
@@ -3303,6 +3743,16 @@ class sessions extends HeyApiClient {
3303
3743
  ...options,
3304
3744
  });
3305
3745
  }
3746
+ /**
3747
+ * List a session's child sessions, recursively
3748
+ */
3749
+ listSessionDescendants(options) {
3750
+ return (options.client ?? this.client).get({
3751
+ responseStyle: "data",
3752
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/descendants",
3753
+ ...options,
3754
+ });
3755
+ }
3306
3756
  /**
3307
3757
  * List persisted session events
3308
3758
  */
@@ -3391,6 +3841,78 @@ class sessions extends HeyApiClient {
3391
3841
  },
3392
3842
  });
3393
3843
  }
3844
+ /**
3845
+ * Search this project for link candidates
3846
+ */
3847
+ searchSessionWorkCandidates(options) {
3848
+ return (options.client ?? this.client).get({
3849
+ responseStyle: "data",
3850
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/link-candidates",
3851
+ ...options,
3852
+ });
3853
+ }
3854
+ /**
3855
+ * Unlink session work
3856
+ */
3857
+ removeSessionWorkLink(options) {
3858
+ return (options.client ?? this.client).delete({
3859
+ responseStyle: "data",
3860
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/links",
3861
+ ...options,
3862
+ headers: {
3863
+ "Content-Type": "application/json",
3864
+ ...options.headers,
3865
+ },
3866
+ });
3867
+ }
3868
+ /**
3869
+ * List session linked work
3870
+ */
3871
+ listSessionLinkedWork(options) {
3872
+ return (options.client ?? this.client).get({
3873
+ responseStyle: "data",
3874
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/links",
3875
+ ...options,
3876
+ });
3877
+ }
3878
+ /**
3879
+ * Link work to a session
3880
+ */
3881
+ addSessionWorkLink(options) {
3882
+ return (options.client ?? this.client).post({
3883
+ responseStyle: "data",
3884
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/links",
3885
+ ...options,
3886
+ headers: {
3887
+ "Content-Type": "application/json",
3888
+ ...options.headers,
3889
+ },
3890
+ });
3891
+ }
3892
+ /**
3893
+ * Ask the forge again about one linked item
3894
+ */
3895
+ refreshSessionWorkLink(options) {
3896
+ return (options.client ?? this.client).post({
3897
+ responseStyle: "data",
3898
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/links/refresh",
3899
+ ...options,
3900
+ headers: {
3901
+ "Content-Type": "application/json",
3902
+ ...options.headers,
3903
+ },
3904
+ });
3905
+ }
3906
+ /**
3907
+ * Mark a session's Needs you as seen until its next occurrence; a session waiting on an answer, a sign-in, or a stop is refused
3908
+ */
3909
+ markSessionSeen(options) {
3910
+ return (options.client ?? this.client).post({
3911
+ responseStyle: "data",
3912
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/mark-seen",
3913
+ ...options,
3914
+ });
3915
+ }
3394
3916
  /**
3395
3917
  * List a session's monitors
3396
3918
  */
@@ -3425,6 +3947,20 @@ class sessions extends HeyApiClient {
3425
3947
  },
3426
3948
  });
3427
3949
  }
3950
+ /**
3951
+ * Copy a stopped user session into another profile and archive the original
3952
+ */
3953
+ moveSessionToProfile(options) {
3954
+ return (options.client ?? this.client).post({
3955
+ responseStyle: "data",
3956
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/move-to-profile",
3957
+ ...options,
3958
+ headers: {
3959
+ "Content-Type": "application/json",
3960
+ ...options.headers,
3961
+ },
3962
+ });
3963
+ }
3428
3964
  /**
3429
3965
  * Make an adopted child session top-level, or take over a stopped spawned worker
3430
3966
  */
@@ -3449,6 +3985,16 @@ class sessions extends HeyApiClient {
3449
3985
  },
3450
3986
  });
3451
3987
  }
3988
+ /**
3989
+ * List pending session interactions
3990
+ */
3991
+ listSessionPendingInteractions(options) {
3992
+ return (options.client ?? this.client).get({
3993
+ responseStyle: "data",
3994
+ url: "/api/workspaces/{workspace_id}/sessions/{session_id}/pending-interactions",
3995
+ ...options,
3996
+ });
3997
+ }
3452
3998
  /**
3453
3999
  * Update operator session presence
3454
4000
  */
@@ -5856,14 +6402,14 @@ class Compozy extends HeyApiClient {
5856
6402
  super(args);
5857
6403
  Compozy.__registry.set(this, args?.key);
5858
6404
  }
5859
- _agent;
5860
- get agent() {
5861
- return (this._agent ??= new agent({ client: this.client }));
5862
- }
5863
6405
  _agents;
5864
6406
  get agents() {
5865
6407
  return (this._agents ??= new agents({ client: this.client }));
5866
6408
  }
6409
+ _agent;
6410
+ get agent() {
6411
+ return (this._agent ??= new agent({ client: this.client }));
6412
+ }
5867
6413
  _appTokens;
5868
6414
  get appTokens() {
5869
6415
  return (this._appTokens ??= new appTokens({ client: this.client }));