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

# Organizations

> Manage organizations with the AX CLI

<Note>
  The `ax organizations` commands are currently in **BETA**. The API may change without notice. A one-time warning is emitted on first use.
</Note>

The `ax organizations` commands let you create, retrieve, and manage organizations on the Arize platform.

## `ax organizations list`

List organizations the authenticated user has access to.

```bash theme={null}
ax organizations list [--name <filter>] [--limit <n>] [--cursor <cursor>]
```

| Option     | Description                                                     |
| ---------- | --------------------------------------------------------------- |
| `--name`   | Filter organizations by name (case-insensitive substring match) |
| `--limit`  | Maximum number of results to return (default: 50)               |
| `--cursor` | Pagination cursor for the next page                             |

**Examples:**

```bash theme={null}
ax organizations list
ax organizations list --name "acme" --output orgs.json
```

## `ax organizations get`

Get an organization by name or ID.

```bash theme={null}
ax organizations get <name-or-id>
```

**Examples:**

```bash theme={null}
ax organizations get org_abc123
ax organizations get "Acme Corp"
```

## `ax organizations create`

Create a new organization. Organization names must be unique within the account.

```bash theme={null}
ax organizations create --name <name> [--description <text>]
```

| Option          | Description                                                    |
| --------------- | -------------------------------------------------------------- |
| `--name`        | Organization name (must be unique, max 255 characters)         |
| `--description` | Optional description of the organization (max 1000 characters) |

**Example:**

```bash theme={null}
ax organizations create --name "Acme Corp" --description "Main organization"
```

## `ax organizations update`

Update an organization's metadata. At least one of `--name` or `--description` must be provided.

```bash theme={null}
ax organizations update <name-or-id> [--name <name>] [--description <text>]
```

| Option          | Description                                                           |
| --------------- | --------------------------------------------------------------------- |
| `--name`        | New organization name (max 255 characters)                            |
| `--description` | New description (max 1000 characters). Pass an empty string to clear. |

**Examples:**

```bash theme={null}
ax organizations update org_abc123 --name "Acme Corp v2"
ax organizations update org_abc123 --description "Updated description"
```

## `ax organizations add-user`

Add a user to an organization, or update their role if they are already a member (upsert semantics).

```bash theme={null}
ax organizations add-user <name-or-id> --user-id <id> --role <role>
```

| Option         | Description                                                                  |
| -------------- | ---------------------------------------------------------------------------- |
| `--user-id`    | Global ID of the user to add                                                 |
| `--role`, `-r` | Predefined organization role: `admin`, `member`, `read-only`, or `annotator` |

**Example:**

```bash theme={null}
ax organizations add-user org_abc123 --user-id usr_xyz789 --role member
```

## `ax organizations remove-user`

Remove a user from an organization. Also removes the user from all child spaces (membership cascade).

```bash theme={null}
ax organizations remove-user <name-or-id> --user-id <id> [--force]
```

| Option          | Description                     |
| --------------- | ------------------------------- |
| `--user-id`     | Global ID of the user to remove |
| `--force`, `-f` | Skip the confirmation prompt    |

**Examples:**

```bash theme={null}
ax organizations remove-user org_abc123 --user-id usr_xyz789
ax organizations remove-user org_abc123 --user-id usr_xyz789 --force
```
