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

# User Extensions

> Link and unlink users to extensions

Manages the many-to-many relationship between users and extensions. All endpoints require level 0 permission and a Bearer token.

***

## List all links

```
GET /api/v1/user-extensions
```

```json theme={null}
{
  "success": true,
  "message": "2 link(s) found",
  "data": [
    {
      "uuid": "770e8400-e29b-41d4-a716-446655440002",
      "user_uuid": "550e8400-e29b-41d4-a716-446655440000",
      "extension_uuid": "660e8400-e29b-41d4-a716-446655440001",
      "username": "admin",
      "first_name": "Admin",
      "last_name": "User",
      "extension": "100",
      "ext_name": "Reception",
      "type": "chan_sip",
      "created_at": "2026-06-28T12:00:00.000Z"
    }
  ],
  "metadata": {}
}
```

***

## Get links by user

```
GET /api/v1/user-extensions/by-user/{userUuid}
```

```json theme={null}
{
  "success": true,
  "message": "2 extension(s) linked to user",
  "data": [
    {
      "uuid": "770e8400-e29b-41d4-a716-446655440002",
      "user_uuid": "550e8400-e29b-41d4-a716-446655440000",
      "extension_uuid": "660e8400-e29b-41d4-a716-446655440001",
      "extension": "100",
      "ext_name": "Reception",
      "type": "chan_sip",
      "created_at": "2026-06-28T12:00:00.000Z"
    }
  ],
  "metadata": {}
}
```

***

## Get links by extension

```
GET /api/v1/user-extensions/by-extension/{extUuid}
```

```json theme={null}
{
  "success": true,
  "message": "1 user(s) linked to extension",
  "data": [
    {
      "uuid": "770e8400-e29b-41d4-a716-446655440002",
      "user_uuid": "550e8400-e29b-41d4-a716-446655440000",
      "extension_uuid": "660e8400-e29b-41d4-a716-446655440001",
      "username": "admin",
      "first_name": "Admin",
      "last_name": "User",
      "created_at": "2026-06-28T12:00:00.000Z"
    }
  ],
  "metadata": {}
}
```

***

## Create link

```
POST /api/v1/user-extensions
```

| Field           | Type   | Required |
| --------------- | ------ | -------- |
| user\_uuid      | string | yes      |
| extension\_uuid | string | yes      |

```json theme={null}
{
  "user_uuid": "550e8400-e29b-41d4-a716-446655440000",
  "extension_uuid": "660e8400-e29b-41d4-a716-446655440001"
}
```

```json theme={null}
{
  "success": true,
  "message": "User linked to extension",
  "data": {
    "uuid": "770e8400-e29b-41d4-a716-446655440002",
    "user_uuid": "550e8400-e29b-41d4-a716-446655440000",
    "extension_uuid": "660e8400-e29b-41d4-a716-446655440001",
    "username": "admin",
    "first_name": "Admin",
    "last_name": "User",
    "extension": "100",
    "ext_name": "Reception",
    "type": "chan_sip",
    "created_at": "2026-06-28T12:00:00.000Z"
  },
  "metadata": {}
}
```

***

## Delete link

```
DELETE /api/v1/user-extensions/{uuid}
```

```json theme={null}
{
  "success": true,
  "message": "Link deleted",
  "data": null,
  "metadata": {}
}
```
