Skip to main content

Organization invitation SDK reference

Organization invitation SDK reference

Customer-hosted cloud features

note

Some features are only available on customer-hosted clouds. Reach out to support@anyscale.com for info.

Organization invitation SDK

anyscale.organization_invitation.create

Creates organization invitations for the provided emails.

Returns a tuple of successful emails and error messages.

Arguments

  • emails (List[str]): The emails to send the organization invitations to.

Returns: Tuple[List[str], List[str]]

Examples

import anyscale

anyscale.organization_invitation.create(emails=["test1@anyscale.com","test2@anyscale.com"])

anyscale.organization_invitation.list

Lists organization invitations.

Returns a list of organization invitations.

Arguments

Returns: List[OrganizationInvitation]

Examples

import anyscale

anyscale.organization_invitation.list()

anyscale.organization_invitation.delete

Deletes an organization invitation.

Returns the email of the deleted organization invitation.

Arguments

  • email (str): The email of the organization invitation to delete.

Returns: str

Examples

import anyscale

anyscale.organization_invitation.delete(email="test@anyscale.com")

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

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

Examples

import anyscale
from anyscale.organization_invitation.models import OrganizationInvitation

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