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

# Claude

> Claude Desktop, Claude Code and the Claude API.

## Claude Desktop

Open the configuration file (**Settings → Developer → Edit Config**):

* macOS: `~/Library/Application Support/Claude/claude_desktop_config.json`
* Windows: `%APPDATA%\Claude\claude_desktop_config.json`

```json theme={null}
{
  "mcpServers": {
    "doconda": {
      "command": "npx",
      "args": ["-y", "@doconda/mcp"],
      "env": { "DOCONDA_API_KEY": "ak_eu_…" }
    }
  }
}
```

Restart Claude and ask it, for example: *"Make me a lease agreement for €900 a month in Word, with blue headings"*.
Since it runs on your computer, it can also review or edit your own files: *"Review \~/Documents/contract.docx"*.

## Claude Code

```bash theme={null}
claude mcp add --transport stdio --env DOCONDA_API_KEY=ak_eu_… doconda -- npx -y @doconda/mcp
```

Or the remote server:

```bash theme={null}
claude mcp add --transport http doconda https://api.eu.doconda.com/mcp --header "Authorization: Bearer ak_eu_…"
```

Add `--scope user` to have it in all your projects.

## Claude API

The tools from `doconda.tools()` have the shape the Anthropic SDK's *tool runner* expects:

```ts theme={null}
import Anthropic from "@anthropic-ai/sdk"
import { betaTool } from "@anthropic-ai/sdk/helpers/beta/json-schema"
import { Doconda } from "@doconda/sdk"

const anthropic = new Anthropic()
const doconda = new Doconda()

const message = await anthropic.beta.messages.toolRunner({
  model: "claude-opus-5-5",
  max_tokens: 4096,
  messages: [{ role: "user", content: "Prepare a short report on remote work in Word" }],
  tools: doconda.tools().map((t) => betaTool({ ...t, run: async (input) => JSON.stringify(await t.run(input)) })),
})
```

<Accordion title="Without the tool runner (manual loop)">
  ```ts theme={null}
  const tools = doconda.tools()
  const messages: Anthropic.MessageParam[] = [{ role: "user", content: "Prepare a short report on remote work" }]

  while (true) {
    const msg = await anthropic.messages.create({
      model: "claude-opus-5-5",
      max_tokens: 4096,
      messages,
      tools: tools.map((t) => ({ name: t.name, description: t.description, input_schema: t.inputSchema })),
    })
    messages.push({ role: "assistant", content: msg.content })
    if (msg.stop_reason !== "tool_use") break
    const results = await Promise.all(
      msg.content
        .filter((b) => b.type === "tool_use")
        .map(async (b) => ({
          type: "tool_result" as const,
          tool_use_id: b.id,
          content: JSON.stringify(await tools.find((t) => t.name === b.name)!.run(b.input as Record<string, unknown>)),
        })),
    )
    messages.push({ role: "user", content: results })
  }
  ```
</Accordion>

With the API's MCP connector (in beta), Claude calls Doconda's remote server without you running anything:

```ts theme={null}
const res = await anthropic.beta.messages.create({
  model: "claude-opus-5-5",
  max_tokens: 4096,
  messages: [{ role: "user", content: "Write up the minutes of today's meeting" }],
  mcp_servers: [{ type: "url", url: "https://api.eu.doconda.com/mcp", name: "doconda", authorization_token: process.env.DOCONDA_API_KEY }],
  tools: [{ type: "mcp_toolset", mcp_server_name: "doconda" }],
  betas: ["mcp-client-2025-11-20"],
})
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.