FAQ / Troubleshooting
Collected from the README and frequent questions in the community group, and updated over time. For more pitfalls, see Common Pitfalls.
This page is grouped by topic:
The bot doesn't reply
Match your symptom first — each one has a different cause:
A. No messages at all
Check in order (PersonalAgent comes configured; normally you don't need to touch this):
- Event subscription: Open Platform → Events & Callbacks — subscribe to
im.message.receive_v1andcard.action.trigger, choose "Long connection (WebSocket)", and make sure the daemon is running. - Bot capability: Open Platform → App Features → Bot is enabled.
- Release: the app must have a published version ("visible only to me" is approved automatically). After changing permissions or events you must publish again for them to take effect.
- Long connection taken: make sure no other program is using the same app's long connection.
- Once all of that checks out, run
botmux restartfrom a clean shell.
To have an agent investigate, see "General troubleshooting approach" in Common Pitfalls: use
botmux logsto find the launch command and reproduce it locally, then check the real error in the web terminal.
B. Others can't use it
botmux has two permission layers:
- Talk permission: who can talk to it.
- Operate permission: who can run management commands such as
/cd,/restart,/close, and tap card buttons.
By default only people in allowedUsers can talk to it. Anyone else who @-mentions it is blocked, and the owner gets a grant request card. Adding the bot to a group does not grant anyone access.
Full rules: Permissions & Access.
C. Terminal has output but nothing reached Lark
Output printed in the terminal is not the same as a message sent to Lark. First check how this bot delivers replies:
- Default (send) mode (default for every CLI except Doubao): the model must run
botmux sendfor the group to see anything.- Every send needs one of
--mention-back,--mention, or--no-mention; otherwise it errors and sends nothing. - If it only uses
echo/print, or forgetsbotmux send, nothing goes out. - Pass multi-line content with a heredoc; don't write
"line one\nline two".
- Every send needs one of
- Auto-forward final reply (
replyDelivery: "transcript", opt-in; default for Doubao): botmux takes the turn's last answer from the CLI's session record and posts it. If nothing arrives, the session record usually wasn't read — the chat shows a notice that botmux couldn't read the turn; open the Web terminal for the result. You can also switch back to model-sent replies with/botconfig set replyDelivery send.
Two more cases where the model doesn't need to send by itself:
codex-app(the Codex App protocol): botmux forwards the final reply automatically. Don't callbotmux sendfor normal replies or they'll be posted twice; use it only for mid-turn progress, attachments, or @-mentioning another bot.- Zero prompt injection mode (
promptInjection: "none"): botmux picks the final answer from the CLI's transcript and posts it to Lark. See bots.json.
Permissions and mentions
How are permissions divided? Who can operate the bot?
Quotas, expiry, and request cards are covered in Permissions & Access.
How do I let a whole group use it?
Send @bot /grant (same as /grant all) in the group:
- The group is added to
allowedChatGroups, and everyone in it can talk right away — no message limit, no expiry. - New members get access automatically; people who leave lose it.
- In a topic group it applies to the whole group, covering every topic.
- Revoke with
@bot /revoke.
The group manage dialog in Dashboard Group Management also has a Whole-chat grant button. It grants talk only; operate permission stays with allowedUsers.
How do I give someone a few trial messages?
Send @bot /grant @someone. The bot replies with a grant card that defaults to 3 messages / 1 hour per person.
- To set the count directly:
@bot /grant @someone 20. - Duration options are 1 hour, 8 hours, 1 day, 7 days, and permanent; leave the quota empty for unlimited.
What's the difference between on-call and /grant?
Both grant talk only, and neither has a quota. The difference is the working directory:
/oncall bind <dir>binds the group to a directory, so new topics skip repo selection and start right away. Good for duty Q&A./grantonly opens up talking and binds no directory. Good when group members ask questions in topics whose repo is already chosen.
Why must I mention the bot in groups?
The default policy is always: in regular groups the bot replies only when explicitly @-mentioned, so bots don't talk over each other in groups with several bots or people. Send /mention-mode in the group to change it:
- Changing it requires operate permission and works in regular groups only.
- A "1 person + 1 bot" group needs no @ by default; you can turn that exception off with
soloGroupMentionBypass. - A few more exceptions exist (message listeners, no-@ commands, and so on). See Mention Policy for the full list.
How do multiple bots work together?
It works out of the box — add the bots to the same group:
- Just you and one bot: talk to it directly, no @ needed.
- A group with several bots or people: @ the bot you want to hand the work to.
- Bot-to-bot relays (say, one writes and another reviews): the bots @ each other; you only hand the work to the first one.
Can I stop people from adding the bot to groups?
Not from botmux. "Who can add the bot to a group" is controlled by the Lark platform (app availability, who can add bots to groups). What you can do on the bot side:
- Don't auto-start when added: turn off Auto-start when added to a new chat (
autoStartOnGroupJoin) under Dashboard Bot Config → Proactive Start. Even when it's on, the group must contain at least one person fromallowedUsers. - Stay restricted: being added is not a grant. People without access are blocked when they @ it, and the owner gets a request card.
- Don't pull the owner into new groups: by default, when the bot is added to a new group it also adds the owner (
autoInviteOwnerOnGroupAdd). If an alert or on-call platform creates groups in bulk and the owner shouldn't be disturbed, turn off Add the owner to chats the bot joins under Bot Config → Proactive Start, send/botconfig set autoInviteOwnerOnGroupAdd off, or editbots.json.
Can a bot added to a new group read earlier chat history?
Yes. Tell it "look at the chat history", or quote a specific message. The Lark app needs its full permission set (including reading group messages).
A regular group is too noisy — can I switch it to a topic group?
Yes, but the group owner or a group admin has to do it: Group Settings → Group Management → Message format → "Topic messages". The bot can't change group settings for you.
Sessions
Does restarting the daemon lose context?
Not with the default tmux backend. The CLI keeps running inside tmux, and after botmux restart the next message reattaches to the same process.
- Without tmux installed, botmux does not quietly fall back to pty; it shows a card asking you to install tmux first.
- pty is used only when you explicitly set
BACKEND_TYPE=pty(orbackendType: "pty"for one bot). pty sessions don't survive a daemon restart and have to be relaunched.
What happens to work in progress when the CLI restarts mid-way?
When the CLI exits unexpectedly (a crash, the tmux server going away, and so on), botmux relaunches it with the previous context and reads the transcript the old process left behind to see whether work was cut off:
- the previous turn hadn't finished, such as a review half-way through;
- background tasks died with the old process, such as Claude Code background commands, Monitors, or background agents.
If so, the resumed CLI first gets a short note (it was just restarted, which background tasks were interrupted, check and continue), and one notice appears in the topic. Nothing is posted when nothing was interrupted.
- The same check runs on a cold resume after a suspend or a daemon restart; the note is placed in front of the next message to the CLI. CLIs that take the first message as a launch argument, such as Pi, only get the topic notice.
- Only the transcript is read, never the screen. This covers Claude Code, plus CLIs with structured transcripts such as Pi and Codex (for those, only whether the turn finished).
Messages not yet handed to the CLI aren't lost:
- A first message passed as a launch argument, where the CLI exited before starting on it, is typed in again after the restart.
- Messages still queued when the daemon restarts are delivered by the session's next worker.
- Messages older than 24 hours aren't re-delivered; the topic says they weren't delivered instead. The same happens when another restart interrupts re-delivery and delivery can't be confirmed.
- A message the CLI had already received and started on is not typed in again; the note above reminds it to continue. It is re-sent only when the restart has to open a new session without the old context.
Does a session use memory forever if I don't close it?
No. Each bot has two automatic limits. A reclaimed session is "suspended": the CLI process exits and frees memory, but the topic stays, and the next message restores the context from disk (usually within a few seconds).
- A session that is producing an answer is never interrupted.
- A session whose main turn has ended while background tasks keep running (the card shows "⏳ Main turn ended · background tasks running") isn't suspended either — suspending would kill those tasks, and they can't be brought back.
- Adopted external terminals and sessions that can't be resumed are exempt.
To clean up by hand:
More commands: CLI Commands.
Can I follow up or interrupt a running session?
By default it doesn't interrupt. New messages queue up and are entered in order after the current turn ends.
To stop and change course right away:
- Tap ⏹ Stop on the card, or send
/stopin the topic. It interrupts only the current turn; the session and its context stay. - When the card shows the terminal screenshot, you can also tap the
Escor^Ckeys; in the web terminal you can press keys directly.
Then send your new request.
Wrong working directory or repository?
workingDirsearches for git repos downward from that directory (up to 3 levels), never upward. Point it at a folder with many repos (such as~/projects) to list them all; point it at one repo to list only that repo (and its worktrees).- Switch directories temporarily:
/cd <path>. - Skip the repo picker and go straight into one repo: set
defaultWorkingDir(see side effects in Common Pitfalls). - Don't set
workingDirto~— there are too many folders to scan. /reponumbers can change; use/repo <project-name>to pick a repo.
Session does not start
Symptom: the session never starts, or the first message errors with zsh: parse error near '\n'.
Usually your login shell ($SHELL, often bash) has a "switch to another shell" line in its startup file. The classic one is in ~/.bashrc:
botmux starts the session inside tmux with <$SHELL> -i -c '…start the CLI'. -i loads that startup file, exec zsh replaces the shell, and the command that starts the CLI never runs — so the first message lands in an empty shell. botmux detects this and posts a diagnostic card instead of typing the message into the empty shell.
Pick one fix:
-
Set
launchShell(recommended): start this bot directly with the target shell, skipping the startup file that switches shells.- In Lark, send
/botconfig set launchShell zsh; - or fill it in under Dashboard Bot Config → Launch shell;
- or add
"launchShell": "zsh"tobots.json.
PATH, nvm, and the like must live in the chosen shell's own startup file (such as
.zshrc; for fish,~/.config/fish/config.fish). - In Lark, send
-
Fix the startup file: only switch when you open a terminal by hand:
[ -z "$BASH_EXECUTION_STRING" ] && [ -t 1 ] && exec zsh(put PATH, nvm, etc. before this line).
Then run botmux restart and send another message. This only affects backends that start through a shell (tmux / zellij / zmx / hc); the pty backend starts the CLI directly and isn't affected.
The Workbench or terminal won't load on my phone?
If it works on your computer but on your phone the Workbench is blank or the terminal never shows up, open <your Dashboard address>/workbench-doctor in the phone's browser.
- This self-check page needs no sign-in. It checks the service version, sign-in state (cookies), the terminal link and the live connections on its own.
- When it finishes, send a screenshot to the bot or a maintainer. It shows whether the cause is the network, the sign-in state or a stale cache.
- The page never shows any token or secret, so the screenshot is safe to share.
For what each check means, see Agent Workbench · Phone won't load it? Use the self-check page.
Install and environment
How do I upgrade?
The safest way is to re-run the install command, no matter how you installed originally (npm / pnpm global installs included):
- It replaces
~/.botmux/bin/botmuxin place. The download is test-run on your machine first; if it can't run, the installer errors out and keeps your current version. - You can run it again safely: it won't add PATH twice, and it doesn't need Node.
- Afterwards, open a new terminal and run
botmux restart. The installer puts~/.botmux/binat the front of PATH, and only a new terminal is guaranteed to pick up the new version. - The
botmuxcommand inside sessions always matches the daemon version; no separate upgrade needed.
On v3.18.0 or later you can also use the built-in command:
Install a specific version with curl (same for rollback or pinning; the tag needs the v):
⚠️
BOTMUX_VERSIONmust come right before theshon the right of the pipe. If you writeBOTMUX_VERSION=… curl … | sh, only curl sees the variable,shdoesn't, and you silently get the latest version.
Why can releases older than v3.18.0 only upgrade via curl?
From v3.18.0 the npm package switched from "Node + source" to platform binaries, and node-pty left the dependencies. Old releases' botmux upgrade handed the job to npm: crossing this version, npm deletes node-pty from the old directory, but the old daemon still loads it on restart, fails with ERR_MODULE_NOT_FOUND, and none of the bots come back (the output may already say "restarting to apply the update"). curl drops in the new binary without relying on the old directory, so it's the one safe way across this version. If you're not sure how you installed, just use curl.
How do I fix Please run /login · API Error: 403?
First work out which side wants a login:
- Lark authorization rejected (calling Lark APIs as the user failed): send
/loginin the topic, open the authorization link, then copy the address the browser lands on (http://127.0.0.1:9768/callback?...— it's normal that the page doesn't load) back into the topic. - The model gateway returns 403: unrelated to Lark; usually an environment variable or gateway token problem. A common cause is bash users putting variables in
.bash_profile, whichbash -idoesn't read (see Common Pitfalls).
claude keeps asking for /login on macOS
claude stores its login token in two places, and the two drifting apart is the main reason for Please run /login on macOS:
As long as the keychain item exists, claude reads only the keychain, never the file. So "/login over SSH succeeded (it only wrote the file), but the GUI and the bot still use the old keychain token". On top of that, claude rotates the token on refresh, so whichever side refreshes first invalidates the other, and everyone gets logged out.
Stick to the file as the only source:
- Don't use claude code in the GUI; it writes the token to the keychain.
- Always update the token by running
/loginover SSH. - If an old keychain item already exists, delete it.
botmux history returns 400, or the Lark gateway returns 411?
- 400: usually the Lark app is missing a permission (such as
im:message.group_msg). Enable the full permission list. - 411: older versions sent GET requests with an empty body, which the Lark gateway rejects. Upgrade to a newer version.
Does it support Lark (international, larksuite.com)?
Yes. Both Feishu (feishu.cn) and Lark (larksuite.com) work:
- When you scan to create an app, China vs. international is detected automatically; when you paste the AppID / Secret by hand, you choose once.
- Each bot connects to the domain of its own edition. One machine can run Feishu and Lark bots side by side, with separate login credentials.
Can I launch the CLI through ccr, a custom gateway, or a wrapper?
Yes. Write a wrapper script that passes its arguments ("$@") straight through, then set cliPathOverride to that script's path when editing the bot in botmux setup.
Chinese characters or emoji show up as boxes in screenshots?
Fonts are missing. On Debian / Ubuntu the daemon tries to install fonts-noto-cjk and fonts-noto-color-emoji automatically (needs root or passwordless sudo). On other Linux distributions, install Noto CJK and Noto Color Emoji by hand, then restart the daemon.
A bot with cliId: "gemini" no longer starts?
Gemini CLI has been retired and the gemini adapter removed. That bot refuses to start with a hint to switch to Antigravity; other bots keep running. To migrate:
- Install
agyand sign in with a Google account (or setmodelProvider: "gemini"in~/.gemini/antigravity-cli/settings.jsonand provideGEMINI_API_KEY). - Change
cliIdto"antigravity"(inbots.jsonor withbotmux setup). - Run
botmux restart.
The old cliPathOverride / wrapperCli (such as ttadk gemini), Gemini model names, and GEMINI_CLI_HOME don't carry over. See CLI Adapters.
Messages sent while CoCo is busy get lost?
Upgrade to CoCo 0.120.32 or later. Messages sent while it's busy go into CoCo's own queue, which relies on that version's behavior.
Does it work on Windows?
Native Windows isn't supported: the daemon only runs on Unix-like systems, and there's no Windows build (neither curl nor npm can install one). Install inside WSL2 and follow the Linux steps there.
