Allow plugins to contribute to the status line via hook output

Resolved 💬 3 comments Opened Mar 1, 2026 by robtaylor Closed Apr 4, 2026

Summary

Plugins currently have no way to display persistent information in the status bar. The systemMessage field in hook output JSON injects text into the AI's context (useful!) but is invisible to the user. The statusLine setting in settings.json exists for user scripts, but plugins cannot contribute to it.

Use Case

I'm building context-daddy, a plugin that tracks cross-session goals. When a goal is active, I want to show a short status like:

🎯 Goal: Add auth (3/7) | ⏵⏵ accept edits

Currently the SessionStart hook can output systemMessage which goes into the AI's context - the AI can see the goal state, but the user can't see it in the status bar.

Proposed Solution

Allow hook output JSON to include a statusLine field that appends/sets text in the status bar:

{
  "systemMessage": "...",
  "statusLine": "🎯 Goal: Add auth (3/7)"
}

This could work from:

  • SessionStart hooks (set initial status)
  • PostToolUse hooks (update status after actions)
  • Stop hooks (update after responses)

Alternative: Plugin-level statusLine config

Allow plugin.json to declare a statusLine command, similar to the user-level statusLine setting in settings.json:

{
  "name": "my-plugin",
  "statusLine": "${CLAUDE_PLUGIN_ROOT}/scripts/status.sh"
}

Current Workarounds

  • systemMessage in hook output: AI sees it, user doesn't
  • stderr from SessionStart: flashes briefly during startup, not persistent
  • Suggest users manually configure statusLine in their settings: fragile, not portable

Environment

  • Claude Code: v2.1.50
  • OS: macOS (Darwin 24.6.0)
  • Plugin: context-daddy v0.14.2

View original on GitHub ↗

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