You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
TUI doesn't render messages from prompt_async endpoint #8564
Messages sent via POST /session/:id/prompt_async are processed by the LLM but don't appear in the TUI. The AI responds, but users see nothing.
Steps to Reproduce
Start opencode (which connects to a running server on port 4096)
Note the session ID
From another process, call POST localhost:4096/session/{id}/prompt_async with a message
LLM processes and responds (confirmed via API response)
TUI remains blank - no prompt, no response shown
Expected
Messages injected via prompt_async should render in TUI like user-typed messages.
Why This Matters
Any external tool or automation that uses the API to send prompts works correctly at the LLM level, but users watching the TUI can't see what's happening. The conversation is invisible.
Use Case
We run multiple opencode instances (agents) against a single server, each in different project directories. A daemon monitors a shared message queue and delivers messages between agents using prompt_async.
The agents collaborate - they receive messages, process them, and respond. It all works at the API level. But when we watch an agent's TUI, we see nothing. The agent handled 4 messages autonomously, but only 2 user-typed exchanges were visible.
It'd be preferred to have LLM activity be more visible to the TUI session rather than completely invisible API calls happening in the background.
Possible Fixes
Render prompt_async in TUI - treat it like user input
New endpoint with explicit TUI rendering
TUI subscribes to all session messages - render regardless of source
Activity
github-actions commentedon Jan 15, 2026
This issue might be a duplicate of existing issues. Please check:
Feel free to ignore if none of these address your specific case.
thdxr commentedon Mar 25, 2026
To stay organized issues are automatically closed after 90 days of no activity. If the issue is still relevant please open a new one.
opencode: TUI-inject mode — make interactive sessions injectable