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

# Anthropic

<div className="page-title-row">
  <img src="https://mintcdn.com/klef/xJ0kXbcegZOD2G3h/images/connectors/anthropic.svg?fit=max&auto=format&n=xJ0kXbcegZOD2G3h&q=85&s=e010c089e90427fa16bb70a8907af935" alt="" noZoom width="148" height="148" data-path="images/connectors/anthropic.svg" />

  <h1>Anthropic</h1>
</div>

## Connection

### Setup

An organization admin creates an
[Admin API key](https://docs.anthropic.com/en/api/administration-api) in the Claude Console.

### Settings

| Setting       | Required | Description                                                                                               |
| ------------- | -------- | --------------------------------------------------------------------------------------------------------- |
| Admin API key | Yes      | Admin API key (sk-ant-admin...) created by an organization admin in the Claude Console. Stored encrypted. |

### Permissions

Minimum permissions the connection requires.

| Capability      | Required | Granted by (any one)                  |
| --------------- | -------- | ------------------------------------- |
| Manage members  | Yes      | `Admin API key`, `Organization admin` |
| Read workspaces | Yes      | `Admin API key`, `Organization admin` |

## anthropic.user

### Fields

| Field          | Type   | Required | Description                                                                                                                                                                                |
| -------------- | ------ | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `email`        | string | Yes      | Email address the invite goes to and the member signs in with. Klef does not change it.                                                                                                    |
| `role`         | enum   |          | Organization role. Defaults to user. Admins are managed in the Claude Console. Values: `user` (User), `claude_code_user` (Claude Code user), `developer` (Developer), `billing` (Billing). |
| `workspaces`   | grant  |          | Workspaces the member belongs to, joined as a workspace user. Applied once the member has accepted their invite. One row grants one workspace.                                             |
| `workspaces[]` | string |          | Workspace ID.                                                                                                                                                                              |
| `active`       | bool   |          | Whether the person belongs to the organization. Switching it off removes a member, or withdraws an invite not yet accepted.                                                                |

### Default Account Matching Rules

When Klef [adopts](/docs/adoption) an account that already exists in Anthropic, it works out whose it is by trying these in order. A connection can override them.

| Account field | Worker field            |
| ------------- | ----------------------- |
| `email`       | `worker.business_email` |

## Examples

### Anthropic members

A Claude Console organization invite for every engineer, removed when they go, or withdrawn if never accepted.

```hcl theme={null}
stage active {
  target anthropic.user {
    email  = worker.business_email
    role   = "user"
    active = true
  }
}
```
