Feature request: Include sandbox status in status line JSON data

Resolved 💬 3 comments Opened Mar 4, 2026 by rocke2020 Closed Mar 7, 2026

Feature Request

Add sandbox status to the JSON payload passed to the status line script.

Current Behavior

The status line script receives JSON with fields like model.id, model.display_name, context_window.*, cost.*, vim.mode, session_id, etc. — but sandbox status is not included.

The only way to check sandbox status during a session is by running /sandbox, which is a manual action that interrupts workflow.

Proposed Behavior

Include a field like sandbox.enabled (boolean) in the status line JSON data, so users can display real-time sandbox status in their custom status line scripts.

Example addition to the JSON payload:

{
  "sandbox": {
    "enabled": true
  }
}

Motivation

  • Sandbox mode is a critical safety setting that affects every tool call in a session
  • It can be toggled at runtime via /sandbox, making it easy to lose track of the current state
  • Displaying it in the status line would give users constant visibility without interrupting their workflow
  • Similar runtime state like vim.mode and output_style.name is already exposed — sandbox status fits naturally alongside these

Example Usage

#!/bin/bash
input=$(cat)
MODEL=$(echo "$input" | jq -r '.model.display_name')
SANDBOX=$(echo "$input" | jq -r '.sandbox.enabled')
if [ "$SANDBOX" = "true" ]; then
  echo "[$MODEL] 🔒 Sandbox"
else
  echo "[$MODEL] ⚠️ No Sandbox"
fi

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗