Agent Terminal
Browser-based xterm.js terminal providing direct access to the agent's Claude Code TUI, with mode switching between Claude, Gemini, and Bash.
How It Works
Open the agent detail page and click the Terminal tab.
The terminal connects via WebSocket to the agent container's PTY.
The default mode is the Claude Code TUI (interactive AI assistant).
A mode toggle in the terminal header switches between Claude, Gemini, and Bash.
The terminal supports resize and adapts to the browser window dimensions.
Per-agent API key control: toggle between the platform API key and your own Claude subscription in the Terminal tab.
Terminal Modes
GEMINI_API_KEY credential on the agent.Mode switching restarts the PTY process inside the container without dropping the WebSocket connection.
SSH Access
| Method | Reference |
|---|---|
| API | POST /api/agents/{name}/ssh-access |
| MCP | get_agent_ssh_access(name) |
System Agent Terminal
trinity-system).How It Works Internally
Each agent container runs an SSH server and a PTY multiplexer. The browser terminal connects through the backend's WebSocket proxy — agents do not need to expose ports directly.