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

# ankra chat

> AI-powered chat for troubleshooting and assistance

## ankra chat

AI-powered chat for troubleshooting and assistance.

If a message is provided, sends a one-shot question.
If no message is provided, enters interactive chat mode.

Use --cluster to provide cluster context for better answers.

```bash theme={null}
ankra chat [message] [flags]
```

**Flags**

| Flag        | Default | Description                                                                                           |
| ----------- | ------- | ----------------------------------------------------------------------------------------------------- |
| `--cluster` |         | Cluster name for context                                                                              |
| `--mode`    |         | Safety mode: 'ask' (read-only + safe creations) or 'agent' (can act). Defaults to the server default. |

## ankra chat actions

Agent-mode chat halts before every write and proposes it as a pending
action. Confirm the action to run it, or reject it to discard it.

Pending actions expire, so confirm promptly. If the cluster changed since the
action was proposed, confirming answers a drift conflict; re-run with --force
to apply it against the changed state anyway.

## ankra chat actions confirm

Confirm a pending action proposed by agent-mode chat.

The platform re-checks the action against live cluster state before running
it. If the state drifted since the proposal, the command reports the drift and
exits without running anything; pass --force to run it anyway.

```bash theme={null}
ankra chat actions confirm <action_id> [flags]
```

**Examples**

```bash theme={null}
# Confirm the action id printed by the chat stream
  ankra chat actions confirm 6f1c2f9e-6d5a-4a1e-9f0b-6d4c2b8a1e77

  # Apply it even though the cluster drifted since it was proposed
  ankra chat actions confirm 6f1c2f9e-6d5a-4a1e-9f0b-6d4c2b8a1e77 --force \
    --force-reason "drift is an unrelated label change"
```

**Flags**

| Flag             | Default | Description                                                                   |
| ---------------- | ------- | ----------------------------------------------------------------------------- |
| `--force`        | `false` | Confirm even though cluster state drifted since the action was proposed       |
| `--force-reason` |         | Why the drift is acceptable (recorded in the audit trail, max 280 characters) |
| `-o`, `--output` |         | Output format: json or yaml (default: human-readable)                         |

## ankra chat actions list

List the actions awaiting confirmation in a conversation

```bash theme={null}
ankra chat actions list <conversation_id> [flags]
```

**Flags**

| Flag             | Default | Description                                           |
| ---------------- | ------- | ----------------------------------------------------- |
| `-o`, `--output` |         | Output format: json or yaml (default: human-readable) |

## ankra chat actions reject

Reject a pending AI action so it never runs

```bash theme={null}
ankra chat actions reject <action_id> [flags]
```

**Flags**

| Flag             | Default | Description                                           |
| ---------------- | ------- | ----------------------------------------------------- |
| `-o`, `--output` |         | Output format: json or yaml (default: human-readable) |
| `--reason`       |         | Why the action was rejected                           |

## ankra chat delete

Delete a chat conversation

```bash theme={null}
ankra chat delete <conversation_id> [flags]
```

**Flags**

| Flag    | Default | Description                  |
| ------- | ------- | ---------------------------- |
| `--yes` | `false` | Skip the confirmation prompt |

## ankra chat health

Get AI-analyzed cluster health

```bash theme={null}
ankra chat health [flags]
```

**Flags**

| Flag             | Default | Description                                                  |
| ---------------- | ------- | ------------------------------------------------------------ |
| `--ai`           | `true`  | Include AI analysis                                          |
| `--cluster`      |         | Target cluster name or ID (defaults to the selected cluster) |
| `-o`, `--output` |         | Output format: json or yaml (default: human-readable)        |

## ankra chat history

List chat conversation history

```bash theme={null}
ankra chat history [flags]
```

**Flags**

| Flag             | Default | Description                                           |
| ---------------- | ------- | ----------------------------------------------------- |
| `--cluster`      |         | Filter by cluster                                     |
| `--limit`        | `20`    | Maximum number of conversations to show               |
| `-o`, `--output` |         | Output format: json or yaml (default: human-readable) |

## ankra chat show

Show a specific chat conversation

```bash theme={null}
ankra chat show <conversation_id> [flags]
```

**Flags**

| Flag             | Default | Description                                           |
| ---------------- | ------- | ----------------------------------------------------- |
| `-o`, `--output` |         | Output format: json or yaml (default: human-readable) |
