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

# MCP Setup

> Configure your AI coding assistant to use Whilst

## 1. Generate an API Key

<Steps>
  <Step title="Open Settings">
    In the Whilst web app, go to **Settings → API Keys**.
  </Step>

  <Step title="Create a new key">
    Click **Generate API Key**, give it a name (e.g. "Cursor IDE"), and select the permissions you need.
  </Step>

  <Step title="Copy the key">
    Copy the key immediately — it won't be shown again. It looks like: `whl_live_abc123...`
  </Step>
</Steps>

## 2. Configure Your IDE

<Tabs>
  <Tab title="Cursor">
    Add to your Cursor MCP config (`~/.cursor/mcp.json`):

    ```json theme={null}
    {
      "mcpServers": {
        "whilst": {
          "command": "npx",
          "args": ["@whilst/mcp-server"],
          "env": {
            "WHILST_API_KEY": "whl_live_your_key_here"
          }
        }
      }
    }
    ```
  </Tab>

  <Tab title="Claude Desktop">
    Add to `~/Library/Application Support/Claude/claude_desktop_config.json`:

    ```json theme={null}
    {
      "mcpServers": {
        "whilst": {
          "command": "npx",
          "args": ["@whilst/mcp-server"],
          "env": {
            "WHILST_API_KEY": "whl_live_your_key_here"
          }
        }
      }
    }
    ```
  </Tab>

  <Tab title="VS Code">
    Add to your VS Code settings (`.vscode/settings.json`):

    ```json theme={null}
    {
      "mcp.servers": {
        "whilst": {
          "command": "npx",
          "args": ["@whilst/mcp-server"],
          "env": {
            "WHILST_API_KEY": "whl_live_your_key_here"
          }
        }
      }
    }
    ```
  </Tab>
</Tabs>

## 3. Verify

After configuring, ask your AI assistant:

```
Search my Whilst docs for deployment guides
```

It should return matching documents from your workspace.

## Rate Limits

API keys are limited to **100 requests per minute**. All operations are logged for audit purposes.
