---
title: "Choose which roles may use AI connectors"
description: "Workspace owner only. Changes allowed_roles (a subset of owner, admin, manager, agent).\nAI Connectors are available automatically for existing and new workspaces. Confirmed changes\nand usage limits remain platform-controlled. A missing settings row uses default permissions.\n"
---

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

Path: Channel Automation API › AI Connectors

`PUT /api/workspaces/{workspaceId}/ai-connectors/access`

Workspace owner only. Changes allowed_roles (a subset of owner, admin, manager, agent).
AI Connectors are available automatically for existing and new workspaces. Confirmed changes
and usage limits remain platform-controlled. A missing settings row uses default permissions.

## Authentication

- `BearerAuth`, http, header `Authorization`, format `JWT`

## Path parameters

- `workspaceId` (`put/api/workspaces/workspaceId/ai-connectors/access.path.workspaceId`; string, required)

## Request body

_Required._

- `allowed_roles` (`put/api/workspaces/workspaceId/ai-connectors/access.allowed_roles`; array<string>, optional)
  - one of `"owner"`, `"admin"`, `"manager"`, `"agent"`

## Example request

```json
{
  "allowed_roles": [
    "owner"
  ]
}
```

## Code samples

### cURL

```bash
curl --request PUT \
  --url 'https://api.channelautomation.com/api/workspaces/<workspaceId>/ai-connectors/access' \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "allowed_roles": [
    "owner"
  ]
}
'
```

### TypeScript

```typescript
const url = 'https://api.channelautomation.com/api/workspaces/<workspaceId>/ai-connectors/access';
const options = {
  method: 'PUT',
  headers: {'Content-Type': 'application/json', Authorization: 'Bearer <token>'},
  body: JSON.stringify({allowed_roles: ['owner']})
};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "https://api.channelautomation.com/api/workspaces/<workspaceId>/ai-connectors/access"

payload = { "allowed_roles": ["owner"] }
headers = {
    "Content-Type": "application/json",
    "Authorization": "Bearer <token>"
}

response = requests.put(url, json=payload, headers=headers)

print(response.text)
```

## Responses

### 200

Same shape as GET

### 400

Invalid value, platform-controlled field sent, or nothing to change

### 403

Not the workspace owner

### 503

AI_CONNECTORS_NOT_SET_UP


Source: https://developer.channelautomations.com/api/put-api-workspaces-workspace-id-ai-connectors-access/index.md
