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

# Aion Chat

> Standalone terminal chat for A2A-compatible agents.

<img src="https://mintcdn.com/terminalresearch/onVinGXaRwnoau8e/assets/why-use-aion/tools/aion-cli.png?fit=max&auto=format&n=onVinGXaRwnoau8e&q=85&s=db47b1f4634ebbff1cc39c8e4bb95928" alt="Aion Chat terminal interface" width="2142" height="1020" data-path="assets/why-use-aion/tools/aion-cli.png" />

Aion Chat is a terminal interface for chatting with A2A-compatible agents. It can run through the
Python SDK CLI inside an Aion project, or as a standalone Node package installed from npm.

## Composer Controls

| Control       | Behavior                                         |
| ------------- | ------------------------------------------------ |
| `Enter`       | Send the message or select the active menu item. |
| `Shift+Enter` | Insert a newline.                                |
| `@`           | Open the agent picker.                           |
| `/`           | Open the slash command picker.                   |
| `Esc`         | Dismiss the active menu or clear the draft.      |
| `Ctrl+C`      | Clear the draft or exit when the draft is empty. |

## Python SDK CLI

Use the Python SDK CLI when you are working inside a Python SDK project or want to launch chat from
`poetry run aion chat`. Install it from the [Python SDK installation guide](/sdk/python/installation).

Start interactive chat:

```bash theme={null}
poetry run aion chat
```

By default, `aion chat` connects to `http://localhost:8000`. That default is useful when you are
running a local Aion proxy or agent server with the Python SDK.

### Options

| Option                  | Default                 | Description                                                         |
| ----------------------- | ----------------------- | ------------------------------------------------------------------- |
| `--url`, `--host`, `-u` | `http://localhost:8000` | Agent or proxy URL to connect to.                                   |
| `--agent-id`            | none                    | Agent identifier for proxy-aware routing with an explicit endpoint. |
| `--token`               | none                    | Bearer token for authenticated explicit endpoints.                  |
| `--header`              | none                    | Custom HTTP header in `key=value` format. Repeatable.               |
| `--push-notifications`  | disabled                | Include local push notification configuration.                      |
| `--push-receiver`       | `http://localhost:5000` | Push notification receiver URL.                                     |
| `--help`                | n/a                     | Show help text.                                                     |

`aion chat run` also supports headless one-shot messages:

| Option               | Default        | Description                                                     |
| -------------------- | -------------- | --------------------------------------------------------------- |
| `--agent`            | none           | Discovered agent handle, display id, identity id, or agent key. |
| `--request-mode`     | `send-message` | `send-message` or `streaming-message`.                          |
| `--response-mode`    | `message`      | `message` for rendered output or `a2a` for raw protocol JSON.   |
| positional `message` | none           | Message text. Use `-` to read stdin.                            |

### Examples

Connect to the default local endpoint:

```bash theme={null}
poetry run aion chat
```

Target a different endpoint:

```bash theme={null}
poetry run aion chat --url http://localhost:8000
```

Target a specific agent through a proxy:

```bash theme={null}
poetry run aion chat --url http://localhost:8000 --agent-id support
```

Send a headless message to a discovered agent:

```bash theme={null}
poetry run aion chat run --agent @david "Hello"
```

Write raw A2A protocol output for a headless message:

```bash theme={null}
poetry run aion chat run --agent @david --response-mode a2a "Hello"
```

See [Command Line Interface](/sdk/python/running/cli) for the broader Python SDK CLI.

## Standalone npm Package

Use the standalone npm package when you want the terminal chat client without installing the Python
SDK.

Install the standalone chat tool globally:

```bash theme={null}
npm install -g @terminal-research/aion
```

Run the primary executable:

```bash theme={null}
aio
```

By default, `aio` connects to `http://localhost:8000`. The package also installs an `aion-chat`
alias:

```bash theme={null}
aion-chat
```

### Options

| Option                  | Default                 | Description                                                         |
| ----------------------- | ----------------------- | ------------------------------------------------------------------- |
| `--url`, `--host`, `-u` | `http://localhost:8000` | Agent or proxy URL to connect to.                                   |
| `--agent-id`            | none                    | Agent identifier for proxy-aware routing with an explicit endpoint. |
| `--token`               | none                    | Bearer token for authenticated explicit endpoints.                  |
| `--header`              | none                    | Custom HTTP header in `key=value` format. Repeatable.               |
| `--push-notifications`  | disabled                | Include local push notification configuration.                      |
| `--push-receiver`       | `http://localhost:5000` | Push notification receiver URL.                                     |
| `--help`                | n/a                     | Show help text.                                                     |
| `--version`             | n/a                     | Print the package version.                                          |

`aio run` and `aion-chat run` also support headless one-shot messages:

| Option               | Default        | Description                                                     |
| -------------------- | -------------- | --------------------------------------------------------------- |
| `--agent`            | none           | Discovered agent handle, display id, identity id, or agent key. |
| `--request-mode`     | `send-message` | `send-message` or `streaming-message`.                          |
| `--response-mode`    | `message`      | `message` for rendered output or `a2a` for raw protocol JSON.   |
| positional `message` | none           | Message text. Use `-` to read stdin.                            |

### Examples

Connect to the default local endpoint:

```bash theme={null}
aio
```

Connect through a local proxy and select an agent:

```bash theme={null}
aio --url http://localhost:8000 --agent-id onboarding
```

Send an authenticated request:

```bash theme={null}
aio --url https://agent.example.com --token "$AION_TOKEN"
```

Add custom headers:

```bash theme={null}
aio --header "X-Client=aion-docs" --header "X-Trace=demo"
```

Enable push notifications:

```bash theme={null}
aio --push-notifications --push-receiver http://localhost:5000
```

Send a headless message to a discovered agent:

```bash theme={null}
aio run --agent @david "Hello"
```

Write raw A2A protocol output for a headless message:

```bash theme={null}
aio run --agent @david --response-mode a2a "Hello"
```
