Detach subagents without archiving them (#1612)
* Add detach action for subagents * Translate detached subagent connection error * Address subagent detach review feedback * Fix subagent integration test import * Focus detached subagents as tabs
This commit is contained in:
@@ -2098,6 +2098,19 @@ export class DaemonClient {
|
||||
return { archivedAt: result.archivedAt };
|
||||
}
|
||||
|
||||
async detachAgent(agentId: string): Promise<void> {
|
||||
const payload = await this.sendNamespacedCorrelatedSessionRequest<"agent.detach.response">({
|
||||
message: {
|
||||
type: "agent.detach.request",
|
||||
agentId,
|
||||
},
|
||||
timeout: 10000,
|
||||
});
|
||||
if (!payload.accepted) {
|
||||
throw new Error(payload.error ?? "detachAgent rejected");
|
||||
}
|
||||
}
|
||||
|
||||
async updateAgent(
|
||||
agentId: string,
|
||||
updates: { name?: string; labels?: Record<string, string> },
|
||||
|
||||
Reference in New Issue
Block a user