{"version":"2.1.285","anchor":"headless-ui-host-requests-toast-status-copy-prompt-fill","canonical_anchor":"headless-ui-host-requests-toast-status-copy-prompt-fill","heading":"Headless SDK sessions send plugin UI events and requests to the host app","tier":"notice","area":"SDK","url":"https:\/\/changelogs.core-directive.com\/v\/2.1.285\/e\/headless-ui-host-requests-toast-status-copy-prompt-fill","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.285","markdown":"### Headless SDK sessions send plugin UI events and requests to the host app\n\nHeadless stream-json sessions now send ui_* messages (toasts, status, panes, prompt fill and more) so a host app can show plugin interface pieces\n\n**Unclear.** It is not clear which host apps answer these requests, or which plugin features send them.\n\n**What**\n\nA headless session is Claude Code running without its own screen, driven by another program (the host) through the SDK with `stream-json` output. Plugin interface actions there used to do nothing but log \"no notification bar in a headless session\". Now they are passed to the host:\n\n- System messages with subtypes `ui_toast`, `ui_status`, `ui_invalidate`, `ui_log`, `ui_panes`, `ui_scroll` and `ui_focus`. The last five are sent only when a check passes. Before, only `commands_changed` was sent.\n\n- Requests the host answers: `ui_copy`, `ui_prompt_read`, `ui_prompt_fill` and `ui_prompt_suggest`, sent on non-remote connections. If an answer is shaped like an error and is not from the expected client, it is ignored and the request keeps waiting.\n\n- An allowlist of message subtypes now includes these `ui_*` subtypes and `session_title_changed`.\n\n- New hooks for connecting and resolving plugin MCP servers.\n\nIn the same area, reconnect and retry delays now go through one shared helper with random variation of 0.25 either way, and errors when waking a worker map to reasons such as `wake_unsupported_host`.\n\n**Why**\n\nA host app can now show plugin notifications, status and panes, and let plugins read or fill in the prompt box. This only has an effect if the host answers these messages.\n\n- Area: SDK\n- Tier: You'll notice\n- Useful: 3\/5\n- Signal: 3\/5"}