class User
A class representing a W&B user with authentication and management capabilities.
This class provides methods to manage W&B users, including creating users, managing API keys, and accessing team memberships. It inherits from Attrs to handle user attributes.
method User.__init__
client: (wandb.apis.internal.Api) The client instance to useattrs: (dict) The user attributes
Some operations require admin privileges
property User.api_keys
List of API key names associated with the user. Returns: Names of API keys associated with the user. Empty list if user has no API keys or if API key data hasn’t been loaded. Returns:list[str]: The api_keys property value.
property User.teams
List of team names that the user is a member of. Returns: Names of teams the user belongs to. Empty list if user has no team memberships or if teams data hasn’t been loaded. Returns:list[str]: The teams property value.
property User.user_api
An instance of the api using credentials from the user. Returns:Api | None: The user_api property value.
classmethod User.create
api(Api): The api instance to useemail(str): The name of the teamadmin(bool): Whether this user should be a global instance admin
User object
method User.delete_api_key
api_key(str): The name of the API key to delete. This should be one of the names returned by theapi_keysproperty.
method User.generate_api_key
description(str, optional): A description for the new API key. This can be used to identify the purpose of the API key.