Organizations#
- class OrganizationsClient(*, sdk_config: SDKConfiguration, generated_client: ApiClient)[source]#
Bases:
objectClient for managing Arize organizations.
This class is primarily intended for internal use within the SDK. Users are highly encouraged to access resource-specific functionality via
arize.ArizeClient.The organizations client is a thin wrapper around the generated REST API client, using the shared generated API client owned by
arize.config.SDKConfiguration.- Parameters:
sdk_config (SDKConfiguration) – Resolved SDK configuration.
generated_client (ApiClient) – Shared generated API client instance.
- list(*, name: str | None = None, limit: int = 50, cursor: str | None = None) OrganizationsList200Response[source]#
List organizations the user has access to.
This endpoint supports cursor-based pagination. When provided,
namefilters results to organizations whose name contains the given substring (case-insensitive).- Parameters:
- Returns:
A paginated organization list response from the Arize REST API.
- Raises:
ApiException – If the API request fails.
- Return type:
- get(*, organization: str) Organization[source]#
Get an organization by ID or name.
- Parameters:
organization (str) – Organization ID or name to retrieve.
- Returns:
The organization object.
- Raises:
ApiException – If the API request fails (for example, organization not found).
- Return type:
- create(*, name: str, description: str | None = None) Organization[source]#
Create a new organization.
Organization names must be unique within the account.
- Parameters:
- Returns:
The created organization object.
- Raises:
ApiException – If the API request fails.
- Return type:
- delete(*, organization: str) None[source]#
Delete an organization by ID or name.
This operation is irreversible. It permanently 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, etc.) as well as organization-level resources (integrations, cost configurations, SAML identity providers, and API keys).
- Parameters:
organization (str) – Organization ID or name to delete.
- Returns:
This method returns None on success (204 No Content response).
- Raises:
ApiException – If the API request fails (for example, organization not found or insufficient permissions).
- Return type:
None
- update(*, organization: str, name: str | None = None, description: str | None = None) Organization[source]#
Update an organization’s metadata by ID or name.
- Parameters:
- Returns:
The updated organization object.
- Raises:
ValueError – If neither
namenordescriptionis provided.ApiException – If the API request fails (for example, organization not found or insufficient permissions).
- Return type:
Response Types#
- class Organization(*, id: Annotated[str, Strict(strict=True)], name: Annotated[str, Strict(strict=True)], description: Annotated[str, Strict(strict=True)], created_at: datetime)[source]#
Bases:
BaseModelAn organization is a top-level container within an account for grouping spaces and managing access control. Organizations enable team separation with role-based access control at the organization level.
Create a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- Parameters:
- id: StrictStr#
- name: StrictStr#
- description: StrictStr#
- created_at: datetime#
- model_config: ClassVar[ConfigDict] = {'populate_by_name': True, 'protected_namespaces': (), 'validate_assignment': True, 'validate_by_alias': True, 'validate_by_name': True}#
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- classmethod from_json(json_str: str) Self | None[source]#
Create an instance of Organization from a JSON string
- to_dict() Dict[str, Any][source]#
Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic’s self.model_dump(by_alias=True):
None is only added to the output dict for nullable fields that were set at model initialization. Other fields with value None are ignored.
- class OrganizationsList200Response(*, organizations: List[Organization], pagination: PaginationMetadata)[source]#
Bases:
BaseModelCreate a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
self is explicitly positional-only to allow self as a field name.
- Parameters:
organizations (List[Organization])
pagination (PaginationMetadata)
- organizations: List[Organization]#
- pagination: PaginationMetadata#
- model_config: ClassVar[ConfigDict] = {'populate_by_name': True, 'protected_namespaces': (), 'validate_assignment': True, 'validate_by_alias': True, 'validate_by_name': True}#
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- classmethod from_json(json_str: str) Self | None[source]#
Create an instance of OrganizationsList200Response from a JSON string
- to_dict() Dict[str, Any][source]#
Return the dictionary representation of the model using alias.
This has the following differences from calling pydantic’s self.model_dump(by_alias=True):
None is only added to the output dict for nullable fields that were set at model initialization. Other fields with value None are ignored.
- classmethod from_dict(obj: Dict[str, Any] | None) Self | None[source]#
Create an instance of OrganizationsList200Response from a dict
- to_df(by_alias: bool = False, exclude_none: str | bool = True, json_normalize: bool = False, convert_dtypes: bool = True, expand_field: str = 'additional_properties', expand_prefix: str = '') pd.DataFrame#
Convert a list of objects to a
pandas.DataFrame.- Behavior:
If an item is a Pydantic v2 model, use .model_dump(by_alias=…).
If an item is a mapping (dict-like), use it as-is.
Otherwise, raise a ValueError (unsupported row type).
- Parameters:
self (object) – The object instance containing the field to convert.
by_alias (bool) – Use field aliases when dumping Pydantic models.
exclude_none (str | bool) – Control None/NaN column dropping. - False: keep Nones as-is - “all”: drop columns where all values are None/NaN - “any”: drop columns where any value is None/NaN - True: alias for “all”
json_normalize (bool) – If True, flatten nested dicts via pandas.json_normalize.
convert_dtypes (bool) – If True, call DataFrame.convert_dtypes() at the end.
expand_field (str) – If set, look for this field in each row and
columns. (expand its keys into top-level)
expand_prefix (str) – If set, prefix expanded column names with this string.
- Returns:
The converted DataFrame.
- Return type: