Feature: Expose session rename/color as programmable API
Resolved 💬 3 comments Opened Mar 26, 2026 by GrantUdstrand Closed Mar 30, 2026
Use Case
When running multiple Claude Code sessions as a pool of dedicated experts (e.g., one session per ticket, one per domain), it would be valuable for sessions to auto-name and color themselves based on the work they're assigned. Today, /rename and /color are interactive-only CLI commands — there's no way for hooks, skills, or tools to invoke them programmatically.
Proposed Solution
Expose session metadata (name, color) through one or more of:
- A writable metadata file (e.g.,
~/.claude/sessions/{id}/meta.json) that the TUI watches for changes - CLI flags (
claude --session-name "botboy" --session-color yellow) - A tool or built-in function that Claude itself can call (e.g., a
RenameSessiontool) - Hook support — allow hooks to emit special directives that the TUI interprets (e.g.,
echo "::set-session-name::botboy")
Any of these would enable automation patterns like:
- A
/ticketskill that renames the session to the ticket ID when work begins - An agent pool manager that color-codes sessions by domain (red = infra, blue = frontend, etc.)
- Automatic session naming based on the git branch being worked on
Current Workaround
The user must manually type /rename and /color after each task assignment. This breaks the flow when orchestrating multiple concurrent sessions.
Environment
- Claude Code CLI
- Multiple concurrent sessions via Zellij/tmux
- Skills and hooks configured for ticket workflow automation
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗