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

# Troubleshooting

> Resolve common LinkModel CLI installation, authentication, schema, timeout, and download issues.

## Command Not Found

Confirm the package is installed globally:

```bash theme={null}
npm install -g linkmodel-cli
lkm --version
```

If `lkm` is still unavailable, check that your global npm bin directory is on `PATH`.

## Missing API Key

Run:

```bash theme={null}
lkm auth status
```

Then configure credentials with either:

```bash theme={null}
lkm setup
```

or:

```bash theme={null}
export LINKMODEL_API_KEY="<your-api-key>"
```

Authentication is resolved in this order:

```text theme={null}
--api-key > LINKMODEL_API_KEY > ~/.linkmodel/config.json
```

## Unknown Option

Model-specific flags come from bundled schemas. Inspect the selected model before using provider-specific options:

```bash theme={null}
lkm models show <model>
```

If the hosted docs show a newer model or parameter, update the CLI:

```bash theme={null}
npm install -g linkmodel-cli@latest
```

## Timeout or Interrupted Task

Server-side tasks continue running after local timeout or `Ctrl-C`. Resume with:

```bash theme={null}
lkm image status <task_id> --wait
lkm video status <task_id> --wait
```

## Download Issues

Use `--no-download` when you only need artifact URLs:

```bash theme={null}
lkm image status <task_id> --wait --no-download
lkm video status <task_id> --wait --no-download
```
