Connect your AI client

AI Commander exposes one capability three ways — an MCP server, a plain REST API, and an installable Agent Skill. Any AI client (MCP or not) can run shell commands on your machines by session code. Below is every supported client and the exact config for each.

Are you an AI agent reading this? The complete, copy-paste onboarding is at aicommander.dev/llms-full.txt (concise index: /llms.txt). It has the exact command for each client and the tool reference — read it, then run the setup for your user's client.

Before you start

The relay your client connects to is https://aicommander.dev/mcp — it's already live, there is nothing to deploy or host, and no login is needed to connect — no-account access works for the code's first hour, then sign in or use an API key. You only need one thing, then pick your client below:

  1. An agent running on the machine you want to control, showing a session code like AIC-7K3P-WX9M-RTBN. Install it below.

You drive each machine by quoting its session code in chat. The code is the credential — anyone who knows a current code can run commands on that machine, for as long as the code stays valid, until the owner resets the code or blocks their account. The code is stable — it never auto-rotates, so the same code keeps working across reboots and restarts. You don't even need an account for the first hour after a code is created or refreshed — or sign in (free) and use it for as long as you like. See Security.

Optional — accounts. Sign in to save machines under friendly aliases and connect with a personal API key. The first time you connect, the machine auto-links to your account and is saved under an alias — then you can use the alias or the raw code interchangeably, at any time, including long after the first hour, indefinitely (until the owner resets the code or blocks your account). Everything also works without an account during the code's first hour. See Accounts.
Two transports. Clients connect either over remote HTTP (nothing to install locally — Claude Code, opencode, Codex, ChatGPT, and Claude Desktop connectors) or via a local stdio process using @aicommander/mcp (pi, Cursor / Windsurf / Antigravity, and Claude Desktop's config file).

Install the agent

Run the agent on the machine you want to control. Pick your platform — the download or install command updates below.

Download the desktop app — a menu-bar app that bundles the agent with a GUI (copy the code, refresh it, pause access). No terminal needed.

Download for macOS

Apple Silicon (M1–M4) · Intel (x64)

Download the desktop app — a tray app that bundles the agent with a GUI (copy the code, refresh it, pause access). No terminal needed.

Download for Windows

Windows x64

Run the one-line installer on the Linux box (server, VM, Raspberry Pi). It detects your CPU architecture and installs the agent as a systemd service that starts on boot.

$ curl -fsSL https://aicommander.dev/install | sudo bash

x86_64 & arm64 (systemd). Runs as root by default — the session code is the credential, so guard it.

Full details and the session-code lifetime: Agent Installation.

Pick your client

Three families, depending on what you drive AI Commander from:

CLI agents

Terminal coding agents. Pick yours — most connect to the remote relay over HTTP with a single command, no token (to add the connector):

Native remote-HTTP MCP — nothing to install, no token.

$ claude mcp add --transport http aicommander https://aicommander.dev/mcp

Verify with claude mcp list (look for aicommander: ✔ Connected), then mention a code in chat: "Run npm test on AIC-7K3P-WX9M-RTBN."

Recent Codex connects to remote HTTP MCP servers directly:

$ codex mcp add aicommander --url https://aicommander.dev/mcp

Pass --url before the URL — without it Codex treats the address as a command and fails with os error 2. Prefer a local stdio process? Add this to ~/.codex/config.toml instead:

[mcp_servers.aicommander]
command = "npx"
args = ["-y", "@aicommander/mcp"]
env = { AICOMMANDER_SERVER = "https://aicommander.dev" }

On Windows use command = "npx.cmd" for the stdio variant — plain npx resolves to npx.exe and the spawn fails with the same os error 2.

opencode connects to remote HTTP MCP servers directly:

$ opencode mcp add aicommander --url https://aicommander.dev/mcp

For the optional account features, attach your API key as an environment variable: add --env AICOMMANDER_TOKEN=<your-key> to the command. Then aliases work — see Accounts.

pi installs the @aicommander/mcp stdio bridge from npm:

$ pi install npm:@aicommander/mcp

The bridge defaults to the hosted relay (https://aicommander.dev), so no extra config is needed to drive a machine by raw code. For aliases, set AICOMMANDER_TOKEN=<your-key> in the bridge's environment — see Accounts.

Coding GUIs & IDEs

Editors and agentic IDEs — Cursor, Windsurf, Antigravity, Zed, and others — accept an MCP server as JSON and run it locally over the same stdio bridge. The config is identical everywhere; only the file location differs:

{
  "mcpServers": {
    "aicommander": {
      "command": "npx",
      "args": ["-y", "@aicommander/mcp"],
      "env": {
        "AICOMMANDER_SERVER": "https://aicommander.dev"
      }
    }
  }
}

On Windows use "command": "npx.cmd". Add "AICOMMANDER_TOKEN": "<your-key>" to env for alias-based access. Restart the editor; the remote_exec and session_status tools appear.

Chat apps — ChatGPT & Claude (MCP connectors)

The desktop / web chat apps connect to the relay as a custom connector — a remote HTTPS MCP endpoint. No token needed to add the connector; leave auth empty.

ChatGPT

Settings → Connectors → Advanced / Developer mode → Add custom connector:

Note. Custom MCP connectors require a ChatGPT plan that exposes developer mode / connectors, and the relay must be reachable from the public internet (it is).

Claude Desktop

Custom connector (recommended): Settings → Connectors → Add custom connector, URL https://aicommander.dev/mcp, auth none. Or use the stdio config file claude_desktop_config.json (macOS: ~/Library/Application Support/Claude/) with the same JSON as the IDE config above, then restart Claude Desktop.

Chat apps without MCP

No connector support, or you just don't want to set one up? Any capable chat model — the ChatGPT app, the Claude app, or similar — can drive a machine on its own as long as it can make HTTP requests (browsing / code-interpreter / a generic "fetch" tool). You don't paste any config; you just tell it where to go. The model reads the public API and figures out the calls.

Give it the relay, the machine's code, and the goal. For example:

# Paste this into ChatGPT / Claude (with web or tool access enabled)
Connect to my computer AIC-7K3P-WX9M-RTBN through aicommander.dev
and tell me its disk usage.

The REST API is documented at https://aicommander.dev/openapi.json
(POST https://aicommander.dev/api/v1/exec with JSON {"code","command"}).
No auth is needed for the first hour after a code is created or refreshed;
sign in (free) to use the code at any time after that.

That's enough for the model to discover and call the endpoint itself — it will POST to /api/v1/exec with the code and a command like df -h, read the JSON result, and answer. You can keep going in plain language ("now restart nginx", "tail the last 50 lines of the app log") and it reissues calls per turn.

Make it reliable. If the model is unsure, point it straight at the docs: aicommander.dev/llms-full.txt (full onboarding) and /openapi.json (machine-readable spec). With an account, give it an API key (Authorization: Bearer <key>) so it can reach machines by alias at any time — including long after the first hour — see Accounts.
Why this works. The same two operations behind MCP — run a command, check status — are plain HTTPS endpoints (next section). Anything that can call a URL can use AI Commander; MCP just makes it automatic.

Any MCP client (raw HTTP+SSE)

The relay speaks standard MCP over HTTP with SSE responses. Point any compliant client at:

# Endpoint — no auth header needed
POST https://aicommander.dev/mcp
Accept: text/event-stream

Tools exposed: remote_exec(code, command, cwd?, timeout_ms?) and session_status(code). Streaming command output arrives as SSE message events.

REST API & Agent Skill (no MCP needed)

If your client doesn't speak MCP — or you just want a single HTTP call — the same two operations are exposed as a plain REST API. Auth is identical to MCP: no token means anonymous (works for the first hour after a code is created or refreshed), and Authorization: Bearer <api-key> gives alias-based access at any time, including long after the first hour (kept active by a dashboard sign-in within the last 24h — see Accounts). There is no OAuth browser flow on this surface — REST clients just paste an API key.

# Is the machine online?
$ curl -s https://aicommander.dev/api/v1/status/AIC-7K3P-WX9M-RTBN

# Run a command (buffered JSON result)
$ curl -s -X POST https://aicommander.dev/api/v1/exec \
    -H 'Content-Type: application/json' \
    -d '{"code":"AIC-7K3P-WX9M-RTBN","command":"df -h"}'

The exec response is { "ok": true, "exitCode": 0, "stdout": "…", "stderr": "…", "truncated": false }. Add "cwd" and "timeout_ms" as needed, or send Accept: text/event-stream to stream the result instead of buffering. Machine-readable spec: /openapi.json.

Install the Agent Skill (Claude — instead of the MCP server)

Claude Code / Claude users who'd rather use a skill than add the MCP server can install the hosted Agent Skill (copy-paste usage + safety rules) into their own skills directory. It's served from the relay at a public URL — nothing to clone — so one command does it:

$ mkdir -p ~/.claude/skills/aicommander && \
    curl -fsSL https://aicommander.dev/skill/SKILL.md -o ~/.claude/skills/aicommander/SKILL.md

Claude auto-loads it on the next session — quote an AIC-… code and it drives the machine over the REST API, with no claude mcp add and no OAuth. View the skill: /skill/SKILL.md.

Accounts & API keys

Connecting needs no login — you can drive machines by their session code, and for the first hour after a code is created or refreshed you don't even need an account. An optional account lets you use the code at any time after that, indefinitely, and gives you alias-based access (though a first link made after the code's first hour starts blocked until the machine's operator approves it). Sign in (passkey or email magic link — no password) to:

With an API key set (Authorization: Bearer <key>, or AICOMMANDER_TOKEN=<key> for the @aicommander/mcp stdio bridge), remote_exec / session_status accept either a raw AIC-… code or one of your saved aliases. Without an account, everything on this page still works by raw code for the first hour after a code is created or refreshed.

Owner controls — who can reach your machine

The machine's owner stays in charge of access at all times:

Keys need a sign-in every 24h. For security, a personal API key only works over MCP/HTTP while you've signed in to the dashboard within the last 24 hours — signing in (or clicking Reactivate in the dashboard) re-arms the window. If it lapses, the key keeps its value but both MCP and HTTP reply with a friendly "please sign in to reactivate" notice instead of acting, so a leaked key is useless to anyone who can't also log in. This bounds the blast radius of a leaked key to 24 hours. Running unattended automation (CI/cron) where a daily login isn't practical? Turn the gate off per account under Key security in the dashboard (this trades that protection away). OAuth tokens are unaffected.
OAuth (passwordless). Some clients (Codex, ChatGPT, Claude Desktop) can sign in via OAuth instead of an API key: when prompted, enter your email and type the one-time code we send you, on the same page. The client then gets a token bound to your account, so aliases work. After your first code sign-in the page offers to save a passkey — next time you can authorize with Face ID / Touch ID / Windows Hello / a security key instead of waiting for a code. (Prefer a single API key for CLI / loopback clients — it's simpler.)