
# tdx completion

Generate shell completion.

**Runs locally**

Generate a completion script from this command schema. JSON returns the script in data.script.

```bash
tdx completion <shell> [flags]
```

**Arguments**

| Argument | Type | Description |
|---|---|---|
| `shell` | one of `bash`, `zsh`, `fish` | Required. Completion shell. |

**Output fields** (inside `data`)

| Field | Type | Description |
|---|---|---|
| `script` | string | Shell completion script. |

Every command also takes the [global flags](/cli/reference#global-flags) and reads the [environment variables](/cli/reference#environment-variables) that the command reference lists once.
