> ## Documentation Index
> Fetch the complete documentation index at: https://docs.mirage.strukto.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# CLIs

> Install typed command-line programs beside your mounts and let agents act on services by name from Node.

Mounts make a service readable as files; CLIs make it actionable as a
program. A CLI is a typed program tree (`CLISpec`) installed on the
workspace by name, completely separate from any mount: it initializes
from its own config, consults no mount, and takes no operand path. The
shell dispatches a line to a CLI when its first word matches an
installed name.

```typescript theme={null}
import { EmailResource, HIMALAYA, Workspace } from '@struktoai/mirage-node'

const ws = new Workspace({ '/mail': new EmailResource(config) })
ws.registerCli('himalaya', HIMALAYA, config)

await ws.execute('himalaya envelope list --unseen --max 5')
```

In YAML the same install rides the `clis:` section:

```yaml theme={null}
mounts:
  /mail:
    resource: email
    config: { ... }
clis:
  himalaya:
    spec: himalaya
    config: { ... }
```

Every level of the tree answers `--help`, unknown verbs fail with git's
wording (exit 1), and missing required flags fail with argparse's
wording (exit 2). Two installs under different head words are two
accounts.

## Builtin CLIs

| Program                              | Acts on          | Vocabulary                                   |
| ------------------------------------ | ---------------- | -------------------------------------------- |
| [himalaya](/typescript/cli/himalaya) | IMAP/SMTP mail   | pimalaya/himalaya (`envelope`, `message`)    |
| [gws](/typescript/cli/gws)           | Google Workspace | official Google Workspace CLI                |
| [slack](/typescript/cli/slack)       | Slack            | OpenClaw Slack actions (`send-message`, …)   |
| [discord](/typescript/cli/discord)   | Discord          | OpenClaw Discord actions (`send`, `poll`, …) |
| [ntn](/typescript/cli/ntn)           | Notion           | official Notion CLI (`pages`, `datasources`) |
| [linear](/typescript/cli/linear)     | Linear           | noun/verb (`issue create`, `team list`)      |

Reading stays on the mount (`cat`, `grep`, `jq` over the virtual
files); acting goes through the CLI. The mounted tree's
`<name>__<id>` path segments supply the IDs the CLI flags take.
