MachineMachine
Machine Code

The machine-ide command

Start, follow, and script Machine Code agents from your terminal.

Machine Code comes with a command, machine-ide, that controls the same agents you see in the app. Use it to script agents, start them from other tools, or check on them from a terminal.

It's a different command from the Machine CLI (machine), which works with your Machine project in the cloud.

Install it

Open Settings › Integrations, find Command line, and click Install. It adds machine-ide to ~/.local/bin in your home folder. Make sure that folder is on your PATH.

Machine Code needs to be running, or its background service started with machine-ide daemon start.

Common commands

CommandWhat it does
machine-ide run "<task>"Create and start an agent with a task.
machine-ide lsList agents. Archived ones are left out.
machine-ide attach <id>Follow a running agent's output.
machine-ide logs <id>Show an agent's activity.
machine-ide send <id> "<message>"Send a message to an existing agent.
machine-ide wait <id>Wait until an agent is idle.
machine-ide inspect <id>Show details about an agent.
machine-ide stop <id>Interrupt an agent if it's running.
machine-ide archive <id>Archive an agent.
machine-ide statusCheck the background service.
machine-ide daemon startStart the background service.

An agent id can be shortened to its first few characters. The Copy id button in the Running view copies one.

Run machine-ide --help, or machine-ide <command> --help, for every command and option. There are also commands for schedules, terminals, workspace scripts, providers, and usage.

Most commands take --json for output that scripts can read.

On this page