Claude is stuck on a question. Answer it from Discord.
Description and use
The bridge lets users answer Claude Code prompts via Discord, automatically typing the reply into a tmux session, removing the need to be at the keyboard.
Problem
Claude Code stops after a few minutes and waits for a user reply that must be typed into a terminal, but the user is not at the keyboard.
Outcome
The bridge allows a user to answer Claude Code prompts from a phone via Discord, automatically typing the reply into the running tmux session, eliminating the need to be at the keyboard.
Workflow
- Run Claude Code inside a tmux session named for the project.
- Configure a Notification hook that triggers when the agent is blocked.
- Set up a Discord bot that DMs the user with the question card.
- User replies with option codes (e.g., 1:1 2:1 3:1).
- The bridge script receives the reply, loads it into a tmux paste buffer, sends Escape to close any selector, waits for the footer to disappear, then pastes the reply and presses Enter.
- The agent receives the input and continues execution.
Evidence
Get a Discord DM when your coding agent (Claude Code, Codex, etc.) is blocked waiting on you, reply from your phone, and have that reply typed straight back into the session -- no need to be at your keyboard.
The bridge treats the terminal as the API.
A reply never goes in while that widget is up. The bridge sends Escape, checks that the selector footer is gone, and only then pastes.
- Record date: 2026-10-18T00:56:11.145Z