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

# Agent skills and MCP

> Give your coding agent access to decisions, evaluations and model workflows.

Configure your API URL and key, then connect an MCP client to the hosted endpoint when MCP is enabled:

```bash theme={null}
export D1_API_URL='https://console.sqwish.ai'
export D1_API_KEY='your-api-key'
```

<CodeGroup>
  ```bash Codex theme={null}
  codex mcp add decisionone --url "$D1_API_URL/mcp" \
    --bearer-token-env-var D1_API_KEY
  ```

  ```bash Claude Code theme={null}
  claude mcp add --transport http decisionone "$D1_API_URL/mcp" \
    --header "Authorization: Bearer $D1_API_KEY"
  ```
</CodeGroup>

Ask the agent to list the DecisionOne models. It should use `list_models` and report their current availability. A 401 means the API key is missing, invalid or revoked; signing into the browser does not authenticate the MCP connection.

<Note>
  HTTP MCP is available only on deployments installed with the MCP extra. These tools use your account and can create paid jobs or change production model versions. Review the requested operation using your MCP client's approval controls.
</Note>

## Local stdio option

For users with access to a workbench clone, install its MCP extra and run the included command:

```bash theme={null}
uv sync --extra mcp
D1_API_URL=https://console.sqwish.ai uv run decisionone mcp
```

Configure your MCP client to launch this command from the repository directory and inherit `D1_API_KEY`. The process speaks MCP over stdio; use it through the client rather than typing into it. No separately published MCP package is required.

## Add the workflow skill

The repository contains `skills/decisionone/SKILL.md`. Copy its `decisionone` directory into `.agents/skills/` for Codex, or `.claude/skills/` for Claude Code; Cursor can use the supported skill directory for your setup. This is a repository-distributed skill, not a registry installation command.

Agents that read documentation can also start with [the service's llms.txt](https://console.sqwish.ai/llms.txt) and OpenAPI. The skill explains how to write decisions, build datasets, inspect evaluations and promote or roll back a model.

## Give the agent a concrete task

For example: “Inspect my labelled support dataset, tune the `team` decision, and show me the verdict and changed wording before I apply it.” A completed tuning job is not necessarily an improvement. Use `result.tuned` only when `result.verdict` is `improved`.

For a fine-tune, ask the agent to inspect the held-out gate and candidate version. A successful training job does not by itself move the production pointer. [Versions and promotion](/guides/model-versions) explains that boundary.

## Claude Code tool-call hook

`POST /v1/hooks/claude-code` is a separate integration for `PreToolUse` payloads. It returns `hookSpecificOutput` with `allow`, `ask` or `deny`. Default `mode=guard` never grants permission; `mode=auto` can allow. If scoring fails after the authenticated request reaches the hook, the hook asks the person. Other hook events return an empty object.

This classifier is one input to tool permissions. Keep your application's deterministic permission checks and scope restrictions. The [tool-risk recipe](/examples/tool-risk) explains the decision policy; the **Integrations** API reference describes the HTTP payload.
