---
title: "Organization invitation CLI reference"
description: "Customer-hosted cloud features"
---

# Organization invitation CLI reference

#### Customer-hosted cloud features

:::note
Some features are only available on customer-hosted clouds. Reach out to [support@anyscale.com](mailto:support@anyscale.com) for info.
:::

## Organization invitation CLI

### `anyscale organization-invitation create`

**Usage**

`anyscale organization-invitation create [OPTIONS]`

Creates organization invitations for the provided emails.

**Options**

-   **`--emails`**: The emails to send the organization invitations to. Delimited by commas.

#### Examples

::::tabs

:::tab[CLI]
```bash
$ anyscale organization-invitation create --emails test1@anyscale.com,test2@anyscale.com
(anyscale +0.5s) Creating organization invitations...
(anyscale +1.7s) Organization invitations sent to: test1@anyscale.com, test2@anyscale.com
```
:::

::::

### `anyscale organization-invitation list`

**Usage**

`anyscale organization-invitation list [OPTIONS]`

Lists organization invitations.

**Options**

#### Examples

::::tabs

:::tab[CLI]
```bash
$ anyscale organization-invitation list
ID             Email              Created At           Expires At
-------------  -----------------  -------------------  -------------------
orginv_abcedf  test@anyscale.com  11/25/2024 10:24 PM  12/02/2024 10:24 PM
```
:::

::::

### `anyscale organization-invitation delete`

**Usage**

`anyscale organization-invitation delete [OPTIONS]`

Deletes an organization invitation.

**Options**

-   **`--email`**: The email of the organization invitation to delete.

#### Examples

::::tabs

:::tab[CLI]
```bash
$ anyscale organization-invitation delete --email test@anyscale.com
(anyscale +0.6s) Organization invitation for test@anyscale.com deleted.
```
:::

::::

## Organization invitation models

### `OrganizationInvitation`

Organization invitation model.

#### Fields

-   **`id` (str)**: ID of the organization invitation.
-   **`email` (str)**: Email of the organization invitation.
-   **`created_at` (datetime)**: Creation time of the organization invitation.
-   **`expires_at` (datetime)**: Expiration time of the organization invitation.

#### Python Methods

```python
def to_dict(self) -> Dict[str, Any]
    """Return a dictionary representation of the model."""
```

#### Examples

::::tabs

:::tab[Python]
```python
import anyscale
from anyscale.organization_invitation.models import OrganizationInvitation

organization_invitations: List[OrganizationInvitation] = anyscale.organization_invitation.list()
```
:::

::::

---

Previous: [Machine pool](/reference/cli/machine-pool.md) | Next: [Other](/reference/cli/other.md)