Repository navigation
Add a session/delete host route so a session can be removed, not only archived
#9806
danieledwards2030-hue
started this conversation in
Ideas
Replies: 1 comment
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Ask. Expose a first-class way to remove a persisted session. Concretely: a
session/delete {request:{sessionId}}Remote route on the host wire answering{deleted:true}β withsession/not-foundfor an unknown id β mirroring the existingworkspace/archiveSessionenvelope ({request:{sessionId}}β{archivedSessionIds:[β¦]}) so clientscan treat the family uniformly. A non-interactive way to reach it (a CLI subcommand, or the
documented ACP path) would be welcome but is secondary to the route itself.
Why (1) β test hygiene. Suites that drive the host against a real harness home, or that fail to
isolate the home, accumulate sessions and workspaces that the user cannot remove afterwards. In one
project a single acceptance run left 31 workspaces and 52 ungrouped chats in a developer's real home,
and there is no supported way to clean that up. A delete route makes such pollution recoverable,
which is what turns an isolation bug from a permanent mess into a survivable one.
Why (2) β user session management. A user who creates a session by mistake, or whose sidebar has
filled with experiments, has today only archive: the session keeps its store directory and is still
returned by
session/list. There is no "delete this chat" action anywhere in the product.Current gap.
session/deleteon the host wire. Zero records in the recorded route corpus, and zero typedbindings in the client library that consumes those routes. (By contrast
workspace/deleteispresent and live, answering
{deleted:true}andworkspace/not-found.)dsh plugin(pnpm argument forwarding) only.There is no
sessions,workspace,delete,pruneorgccommand.session_deletebut nothing implements it. The bundled ACP schema declares themethod name:
dist/v2/schema/index.js:14βsession_delete: "session/delete",(the v1 mirror isdist/schema/index.js:16). The ACP app package implementsnewSession(lib/index.js:1168),resumeSession(:1208),listSessions(:1256),closeSession(:1296) andprompt(
:1309) β but no implementation handles it: apart from that schema declaration, neither the ACP SDK'simplementation code nor the ACP app package contains the string
session/deleteorsession_delete(grep count 0 across their 13 and 8 files respectively). So
session/deleteis a protocol name withno server side.
workspace/deleteis not a substitute. It removes the workspace record only: the workspace'ssessions are orphaned into the ungrouped "Chats" bucket and stay on disk. Deleting a workspace is
therefore not a way to remove sessions β it visibly relocates them.
Archiving-only limitation.
workspace/archiveSessionwritesarchivedSessionIdson theworkspace store. The session keeps its store directory;
session/liststill returns it and does notmark it as archived (the list item is byte-identical before and after archiving). The hide is
entirely a client-side filter: the
workspace/followbaseline carries{items, archivedSessionIds, pinnedSessionIds}, so a client can hide archived sessions β but anyclient that does not consume those lists shows them anyway. A route that actually removes the session
would make cleanup independent of every client honouring the archive list.
Compatibility note.
workspace/archiveSession,workspace/unarchiveSession,workspace/pinSessionandworkspace/unpinSessionare session-level in this version;workspace/pinandworkspace/archivedo not exist (both answer 404). Asession/deleteshouldmirror the
{request:{sessionId}}envelope.All reactions