Claude Code Code Mode

  • Desktop app
  • All plans

What it does

Code Mode is an experimental Claude Code mode: instead of calling its tools one at a time, Claude writes a piece of JavaScript that calls them. AgentsRoom can start a Claude agent in Code Mode without editing any settings.json by hand. The switch is passed for that agent's launches only: your Claude settings are never changed.

Where to find it

Open the agent's Edit agent window > Advanced options > Code Mode (experimental), under CLI options. When you create an agent, the same switch is in the Add agent window > Advanced > Launch, under CLI options. Shown for Claude Code agents only.

How to use it

  1. Turn on Code Mode (experimental) and save (or create the agent).
  2. Restart the agent (the switch applies at the next launch). A new agent starts in Code Mode right away.
  3. The first time, Claude Code shows its own screen explaining Code Mode. "No, start without it" is selected by default: choose "Yes, turn on Code Mode" yourself. AgentsRoom never answers this screen for you.

Turn the switch off and restart the agent to go back to normal tool calls.

Settings

  • claudeCodeMode (agent, Edit agent > Advanced options > Code Mode (experimental), or Add agent > Advanced > Launch): starts this Claude agent in Code Mode. Off by default. Applies at the next launch, including a resume.

Agent tools (MCP)

  • agents_save: claudeCodeMode: true | false on a saved agent.
  • settings_set with scope: "agent", key claudeCodeMode.

Providers

Claude Code only. Codex has its own code mode (exec), which needs no switch.

Mobile

The switch is not on the phone. An agent started from the phone still runs in Code Mode when it is turned on for that agent.

Limits

  • Experimental in Claude Code: it may change or be removed in any release.
  • Not applied to a restricted run, or when the agent's CLI options already pass --settings (yours stays alone, because Claude Code keeps only one).
  • An unattended launch (ticket, trigger) waits on Claude Code's first opt-in screen until someone answers it.
  • Claude Code turns off Remote Control, Claude in Chrome and computer use in a Code Mode session. A Code Mode conversation resumes only with Code Mode on.
  • Per agent only (not per account, project or folder). Saved agent templates keep the switch; team steps never carry it (nobody would answer the opt-in screen during a run).
  • In the conversation, a REPL card (the script Claude wrote) comes before the cards of the tools that script called.

Common questions

Can AgentsRoom turn on Claude Code's Code Mode without editing settings.json?

Yes, per agent: Edit agent > Advanced options > Code Mode (experimental), then restart the agent, or Add agent > Advanced > Launch when you create it. Nothing is written into your Claude settings.

Do tool cards and tool statistics still work in Code Mode?

Yes. Claude Code still writes each tool the script calls, with its real name and input, so every call keeps its card, its MCP App view and its line in the session details. AgentsRoom does not count these calls as extra turns, and the context gauge keeps its value while the script runs.

Does AgentsRoom accept Code Mode's opt-in question for me?

No. Claude Code asks once in the agent's terminal, and you answer it.