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

# E-MODEL-001

> The key this install's models wiring reads is not set, so the agent cannot answer a turn.

# E-MODEL-001

<Warning>
  **what doctor prints** (warning)

  model credential: ANTHROPIC\_API\_KEY is not set, and it is the only key this
  install's `models` wiring reads — the wire is wired, but the agent cannot answer
  a single turn
</Warning>

Every wiring check can pass and the agent can still answer nothing: the one key
this install reads is not set.

`check model/credential` · `error_code E-MODEL-001` · `doctor exits 0` (warning only)

## What you're seeing

Doctor names exactly one variable, and it is the one **your** wiring consults —
never a list. It finds that variable from the answer `vendo init` recorded in
`.vendo/install.json` (`modelKey`), or, failing that, from the provider your
composition's own `models` line names:

* `models: { default: anthropic("claude-sonnet-4-6") }` → `ANTHROPIC_API_KEY`
* `models: { default: openai("gpt-5") }` → `OPENAI_API_KEY`
* no `models` line at all → `VENDO_API_KEY`, which is the only variable the
  runtime ladder reads on its own

Doctor looks for that variable in the environment plus `.env` and `.env.local`.

## Why

A provider key on its own is a **credential**, not a selection — since the
selection law, nothing picks a model off the environment. So setting a key the
composition does not name changes nothing, which is why this warning names one
variable instead of three.

This is a warning and never a failure: production keys legitimately live in a
deploy platform's secret store, which doctor cannot read.

## The fix

Set the variable doctor named. If that is a provider key, put it in `.env.local`
— it is already **selected in your composition** (`lib/vendo.ts`):

```ts theme={null}
import { anthropic } from "@ai-sdk/anthropic";

export const vendo = createVendo({
  models: { default: anthropic("claude-sonnet-4-6") }, // ANTHROPIC_API_KEY supplies the key
  // …
});
```

Or a Vendo Cloud key, which needs no `models` line — the gateway resolves the
family names server-side:

```bash theme={null}
vendo login
```

The minted `VENDO_API_KEY` lands in `.env.local`. Restart your dev server
afterwards so the app picks the key up.

## Related errors

<CardGroup cols={2}>
  <Card title="E-CLOUD-001" href="/production/troubleshooting/e-cloud-001">VENDO\_API\_KEY is set but not usable</Card>
  <Card title="E-TOOLS-003" href="/production/troubleshooting/e-tools-003">part of the tool catalog is ungraded</Card>
</CardGroup>
