> ## 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 Arize organizations programmatically. List, create, retrieve, and update organizations using the Python SDK.

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

Manage organizations programmatically. List, create, retrieve, and update organizations in your Arize account.

## Key Capabilities

* List organizations you have access to
* Retrieve organization details by name or ID
* Create new organizations
* Update an organization's name or description
* Delete an organization
* Add or remove users (organization memberships)

## List Organizations

List all organizations you have access to, with optional name filtering.

```python theme={null}
resp = client.organizations.list(
    name="my-org",  # optional substring filter
    limit=50,
)

for org in resp.organizations:
    print(org.id, org.name)
```

For details on pagination, field introspection, and data conversion (to dict/JSON/DataFrame), see [Response Objects](/api-clients/python/version-8/overview#response-objects).

## Create an Organization

Organization names must be unique within the account.

```python theme={null}
org = client.organizations.create(
    name="my-organization",
    description="Optional description",  # optional
)

print(org.id, org.name)
```

## Get an Organization

Retrieve a specific organization by name or ID.

```python theme={null}
org = client.organizations.get(organization="your-org-name-or-id")

print(org.id, org.name)
```

## Update an Organization

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

```python theme={null}
org = client.organizations.update(
    organization="your-org-name-or-id",
    name="updated-org-name",            # optional
    description="Updated description",  # optional
)

print(org.id, org.name)
```

## Delete an Organization

<Warning>
  This operation is irreversible. It deletes the organization and all
  resources that belong to it, including all spaces and their contents
  (projects, experiments, evaluators, models, monitors, dashboards,
  datasets, annotation configs, annotation queues, custom metrics) as
  well as organization-level resources (integrations, cost
  configurations, SAML identity providers, and API keys).
</Warning>

```python theme={null}
client.organizations.delete(organization="your-org-name-or-id")

print("Organization deleted successfully")
```

## Add a User to an Organization

<Note>
  The `add_user` method is currently in **ALPHA**. The API may change without notice.
</Note>

Add a user to an organization, or update their role if they're already a member (upsert). Requires organization admin.

Role constraints:

* Users with an `annotator` account role can only be assigned the `annotator` organization role.
* Users with a non-annotator account role cannot be assigned the `annotator` organization role.

```python theme={null}
from arize.organizations.types import PredefinedOrgRole

membership = client.organizations.add_user(
    organization="your-org-name-or-id",
    user_id="your-user-id",
    role=PredefinedOrgRole(name="member"),  # "admin", "member", "read-only", or "annotator"
)

print(membership.id, membership.user_id, membership.role)
```

## Remove a User from an Organization

<Note>
  The `remove_user` method is currently in **ALPHA**. The API may change without notice.
</Note>

Remove a user from an organization. This cascades to all of the organization's child spaces. Requires organization admin.

```python theme={null}
client.organizations.remove_user(
    organization="your-org-name-or-id",
    user_id="your-user-id",
)

print("User removed from organization")
```
