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

# API Key Authentication

> Connect Claude Desktop using API key authentication for advanced configuration control

## Overview

API key authentication provides advanced users with full control over the Claude Desktop connection configuration. This method is suitable for team setups, organizations with specific API key management requirements, or users who prefer manual configuration.

### When to Use API Keys

* You need to use organization-level API keys
* You want fine-grained control over API permissions
* You're setting up Claude for multiple team members
* Your organization has specific API key management policies

## Prerequisites

Before configuring Claude Desktop with API keys:

1. **Claude Desktop** installed on your computer ([download from Anthropic](https://claude.ai/download))
2. **Sensolus API access token** from your organization
3. **mcp-proxy** installed on your system
4. Administrator access to modify configuration files on your system

### Installing mcp-proxy

The `mcp-proxy` tool is required to connect Claude Desktop to the Sensolus MCP server.

#### Option 1: With uv (recommended)

[uv](https://docs.astral.sh/uv/) is a fast Python package installer and resolver. Install it first:

**macOS/Linux:**

```bash theme={null}
curl -LsSf https://astral.sh/uv/install.sh | sh
```

**Windows:**

```powershell theme={null}
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
```

Then install mcp-proxy:

```bash theme={null}
uv tool install mcp-proxy
```

#### Option 2: With pip

If you already have Python installed:

```bash theme={null}
pip install mcp-proxy
```

#### Option 3: With pipx

If you have pipx installed:

```bash theme={null}
pipx install mcp-proxy
```

## Configuration Steps

**1. Locate the configuration file**

The Claude Desktop configuration file is located at:

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

You can also access the file location through Claude Desktop settings:

![Claude settings menu](https://mintlify.s3.us-west-1.amazonaws.com/sensolus/docs/sensolusai/images/claude_settings.png)

![Claude developer settings](https://mintlify.s3.us-west-1.amazonaws.com/sensolus/docs/sensolusai/images/claude_developer.png)

**2. Obtain your API access token**

Get your Sensolus API access token:

1. Log in to the Sensolus platform
2. Navigate to **Admin → Developers → API access**
3. Copy your existing API access token or create a new one

> [!WARNING]
>
> Keep your API access token secure. Never share it publicly or commit it to version control systems.

**3. Edit the configuration**

Open the `claude_desktop_config.json` file in a text editor. If the file doesn't exist, create it with the following structure:

```json theme={null}
{
  "mcpServers": {
    "sensolus-mcp-network": {
      "command": "mcp-proxy",
      "args": [
        "--transport",
        "streamablehttp",
        "https://mcp.agents.sensolus.com/mcp/"
      ],
      "env": {
        "API_ACCESS_TOKEN": "YOUR_API_ACCESS_TOKEN_HERE"
      }
    }
  }
}
```

If the file already exists and contains other MCP servers, add the Sensolus configuration to the existing `mcpServers` object:

```json theme={null}
{
  "mcpServers": {
    "existing-server": {
      // ... existing configuration
    },
    "sensolus-mcp-network": {
      "command": "mcp-proxy",
      "args": [
        "--transport",
        "streamablehttp",
        "https://mcp.agents.sensolus.com/mcp/"
      ],
      "env": {
        "API_ACCESS_TOKEN": "YOUR_API_ACCESS_TOKEN_HERE"
      }
    }
  }
}
```

**4. Add your API access token**

Replace `YOUR_API_ACCESS_TOKEN_HERE` with your actual Sensolus API access token from the previous step.

**5. Save and restart Claude Desktop**

1. Save the configuration file
2. Completely quit Claude Desktop (not just close the window)
   * **Windows**: Right-click the system tray icon and select "Quit"
   * **macOS**: Use Cmd+Q or select "Quit Claude" from the menu
   * **Linux**: Close all windows and terminate the process
3. Restart Claude Desktop

**6. Verify the connection**

Once Claude Desktop restarts, verify the MCP connector is active:

1. Start a new conversation in Claude Desktop
2. Look for the MCP indicator in the conversation interface
3. Test the connection by asking: "Can you connect to the Sensolus platform and list available organizations?"

## Troubleshooting

### Connector Not Appearing

If the Sensolus MCP connector doesn't appear in Claude Desktop:

1. Verify the JSON syntax in your configuration file (use a JSON validator)
2. Ensure Claude Desktop was completely restarted
3. Check that the API access token is valid and has appropriate permissions
4. Review Claude Desktop logs for error messages

### Authentication Errors

If you receive authentication errors:

1. Verify your API access token is correct and hasn't expired
2. Ensure your Sensolus account has API access enabled
3. Check that your organization has the necessary permissions
4. Confirm the API key has the required role-based permissions

### Connection Issues

If the connector fails to connect:

1. Verify your internet connection
2. Check if your firewall or proxy allows connections to `mcp.agents.sensolus.com`
3. Ensure you're using the latest version of Claude Desktop
4. Verify the `mcp-proxy` command is available in your system PATH

## API Key Management

### Security Best Practices

* Store API keys securely and never commit them to version control
* Use organization-level API keys for team setups
* Regularly rotate API keys according to your security policies
* Monitor API usage in the Sensolus platform
* Revoke unused or compromised API keys immediately

### Monitoring Usage

Track your API key usage through the Sensolus platform:

1. Navigate to **Admin → Developers → API access**
2. View current API call consumption
3. Check the 12-month usage graph
4. Monitor quota limits and remaining calls

## Next Steps

* Explore [Using Claude with Sensolus](https://doc.sensolus.com/docs/sensolusai/claudedesktop.md#using-the-mcp-connector)
* Review [MCP Connector capabilities](https://doc.sensolus.com/docs/sensolusai/mcpconnector.md)
* Learn about [API key permissions](https://doc.sensolus.com/docs/platform/administration/developers/api_access.md)
* Consider [creating a Claude team](https://doc.sensolus.com/docs/sensolusai/claudedesktop.md#creating-teams-for-project-knowledge) for collaborative use


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