air_sdk.endpoints.organizations#
Stub file for organizations / resource budgets endpoint type hints.
Attributes#
Classes#
Represents an organization and its resource budget in the Air platform. |
|
API client for Organization / ResourceBudget endpoints. |
Module Contents#
- class air_sdk.endpoints.organizations.Organization[source]#
Bases:
air_sdk.air_model.AirModelRepresents an organization and its resource budget in the Air platform.
This model combines organization metadata with resource budget information.
- id#
Unique identifier for the resource budget
- created#
Timestamp when the resource budget was created
- modified#
Timestamp when the resource budget was last modified
- org_display_name#
Display name of the organization
- org_nca_id#
NCA ID of the organization
- cpu#
Number of CPU cores allocated
- memory#
Memory allocated, in MiB
- disk_storage_total#
Total disk storage allocated, in GB
- disk_storage_per_node#
Disk storage per node, in GB
- image_storage#
Image storage allocated, in GB
- userconfigs#
Total UserConfig content allocated, in bytes
- usage#
Current resource usage
- created: datetime.datetime#
- modified: datetime.datetime#
- classmethod get_model_api() type[OrganizationEndpointAPI][source]#
Returns the respective AirModelAPI type for this model.
- property model_api: OrganizationEndpointAPI#
- class air_sdk.endpoints.organizations.OrganizationEndpointAPI(
- api: air_sdk.AirApi,
- default_filters: dict[str, Any] | None = None,
Bases:
air_sdk.air_model.BaseEndpointAPI[Organization]API client for Organization / ResourceBudget endpoints.
This endpoint is read-only and provides access to organization resource budget information.
Also aliased as ResourceBudgetEndpointAPI.
- model: type[Organization]#
- list(
- *,
- limit: int = ...,
- offset: int = ...,
- ordering: str = ...,
- org_display_name: str = ...,
- org_nca_id: str = ...,
- search: str = ...,
List all organizations / resource budgets with optional filtering.
- Parameters:
limit – Maximum number of results to return per page
offset – The initial index from which to return the results
ordering – Order by field. Prefix with “-” for descending order
org_display_name – Filter by the display name of the organization
org_nca_id – Filter by the NCA ID of the organization
search – Search resource budgets by org_display_name
- Returns:
Iterator of Organization instances
Example
>>> # List all organizations >>> for org in api.organizations.list(): ... print(org.name, org.org_nca_id)
>>> # Filter by org_nca_id >>> for org in api.organizations.list(org_nca_id='nca-123'): ... print(org.name)
>>> # Search by name >>> for org in api.organizations.list(search='NVIDIA'): ... print(org.name)
- get(pk: air_sdk.air_model.PrimaryKey) Organization#
Get a specific organization / resource budget by ID.
- Parameters:
pk – The resource budget ID (string or UUID)
- Returns:
The Organization instance
Example
>>> org = api.organizations.get('b4d0480c-6f0b-4c40-b143-c141531fc14e') >>> print(org.name, org.cpu, org.memory)
- air_sdk.endpoints.organizations.ResourceBudget#
- air_sdk.endpoints.organizations.ResourceBudgetEndpointAPI#