Mirai CLI

A Claude Code-class terminal agent for Mirai v1: tools by default, streaming replies, permissions, parallel reads, and MCP — install @satuapps/mirai-cli@0.2.0.

Install

Install globally (Node 20+, package 0.2.0+):

npm install -g @satuapps/mirai-cli

Or run once without installing:

npx @satuapps/mirai-cli

Optional — build from a local checkout of this repo: cd cli && bash install.sh

Quick start

Save your API key (create one in chat settings after you sign in on the site). Then run mirai doctor to verify:

mirai login

One-shot agent turn — tools run in the working directory:

mirai ask "Explain how auth works in this repo"

Start the agent in cwd (slash: /help, /model, /compact, /doctor, /tools, /mcp, …):

mirai chat

Built-in tools

The agent can call these tools during a turn. Write and shell actions ask for permission unless you pass --auto.

MCP

Add Model Context Protocol servers in ~/.config/mirai/mcp.json or .mirai/mcp.json. Tools appear as mcp_<server>_<tool>. Manage them with mirai mcp list|add|remove.

Example config:

{
  "mcpServers": {
    "filesystem": {
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-filesystem", "/tmp"]
    }
  }
}

Model

Default model is mirai-v1-code. Override with --model, MIRAI_BASE_URL / config for the API origin, or mirai models to list what your key can reach.

mirai --model mirai-v1-code ask "…"

Need the HTTP chat completions contract instead? Read the API docs.