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

# DeepSeek Harness

> Add Opper as a custom provider in DeepSeek's open-source agent harness

[DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness) (`dsh`) is DeepSeek's open-source agent harness, released under MIT and built so that everything is a plugin — the model adapter, the tool registry, the sandbox, and the agent loop itself. It runs as a local web UI or headless from the terminal, and accepts any OpenAI-compatible endpoint as a custom provider.

## Setup

### Web UI

```bash theme={null}
npx @deepseek-ai/dsh web
```

Open the UI (served at `http://127.0.0.1:3080` by default), go to **Settings → Models → Add a custom provider**, and fill in:

| Field            | Value                                     |
| ---------------- | ----------------------------------------- |
| **Provider ID**  | `opper` (lowercase; permanent once saved) |
| **Base URL**     | `https://api.opper.ai/v3/compat`          |
| **API protocol** | OpenAI (chat completions)                 |
| **API key**      | Your Opper API key                        |

Under **Model catalog**, click **Fetch available models** — `dsh` queries Opper's OpenAI-compatible `GET /models` endpoint and lists the full catalog. Select the models you want, save, then pick one in the model picker to make it the default for new sessions.

### Config file, and headless mode

The Models page writes to `$DSH_HOME/settings.yaml` (default `~/.dsh`). To configure the same thing by hand — for example for one-shot headless jobs:

```yaml theme={null}
# $DSH_HOME/settings.yaml
agent-default-model:
  provider: opper
  model: anthropic/claude-sonnet-4-6
llm-pi-ai:
  providers:
    opper:
      apiKeyEnv: OPPER_API_KEY
      api: openai-completions
      baseURL: https://api.opper.ai/v3/compat
      models:
        - id: anthropic/claude-sonnet-4-6
        - id: tensorx/deepseek/deepseek-v4-flash
```

```bash theme={null}
export OPPER_API_KEY=your-opper-api-key
npx @deepseek-ai/dsh --profile headless "Summarize this repository"
```

<Note>
  Models entered by hand are treated as text-only; for a vision model, add `input: [text, image]` to its entry. The API key itself never lands in `settings.yaml` — the UI stores it in `$DSH_HOME/.credentials.yaml`, and `apiKeyEnv` reads it from the environment instead.
</Note>

## Troubleshooting

<AccordionGroup>
  <Accordion title="Fetch available models returns nothing">
    Check the base URL has no trailing path — `dsh` appends `/models` itself. It should be exactly `https://api.opper.ai/v3/compat`.
  </Accordion>

  <Accordion title="A vision model won't accept images">
    Hand-written model entries default to text-only. Add `input: [text, image]` under that model's entry in `settings.yaml`.
  </Accordion>

  <Accordion title="Provider ID is wrong">
    The provider ID is permanent once saved. Delete the provider and re-add it with the correct ID.
  </Accordion>
</AccordionGroup>

## Related

<CardGroup cols={2}>
  <Card title="Model catalog" icon="list" href="/capabilities/models">
    Browse the catalog for model IDs and capabilities.
  </Card>

  <Card title="All integrations" icon="plug" href="/integrations/overview">
    Every app that runs on Opper.
  </Card>
</CardGroup>
