Expose session management as tools (rename, list, resume)
Resolved 💬 3 comments Opened Mar 13, 2026 by dsjolie Closed Mar 17, 2026
Summary
With 1M context, resuming named sessions is becoming a primary workflow — conversations are rich working sessions worth returning to by name. Currently /rename and /resume are interactive-only slash commands. Exposing session management as tools would let the agent manage sessions programmatically.
Proposed tools
- SessionRename — rename the current session (equivalent to
/rename <name>) - SessionList — list sessions with optional filters (project, branch, name pattern), returning structured data (name, last activity, message count, branch)
- SessionResume — resume a specific session by name or ID (may not be feasible mid-conversation, but listing alone would be valuable)
Use cases
- Agent auto-names sessions based on the dominant work topic
- Skills that map tasks/tickets to sessions ("resume work on the auth refactor")
- Session discovery without leaving the current conversation ("which session was I working on the memory architecture in?")
- Building session management workflows in hooks or skills
Current workaround
None — session metadata isn't accessible programmatically. The JSONL files in ~/.claude/projects/ are an internal format with no stability guarantee.
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗