2025-06-06 08:20:45 +03:00
|
|
|
import typing as _typing
|
|
|
|
|
|
|
|
|
|
import dynamix_sdk.base as _base
|
|
|
|
|
import dynamix_sdk.api._nested as _nested
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class CloudapiImageGetResultModel(
|
|
|
|
|
_base.BaseAPIResultModel,
|
|
|
|
|
_nested.BaseImageAPIResultNM,
|
|
|
|
|
):
|
|
|
|
|
acl: list[_typing.Any]
|
|
|
|
|
cd_presented_to: dict[str, list[int]]
|
|
|
|
|
ckey: str
|
|
|
|
|
deleted_timestamp: int
|
|
|
|
|
enabled: bool
|
|
|
|
|
grid_id: int
|
|
|
|
|
guid: int
|
|
|
|
|
history: list[_nested.ImageHistoryRecordAPIResultNM]
|
|
|
|
|
last_modified: int
|
|
|
|
|
milestones: int
|
|
|
|
|
os_password: str | None
|
2025-06-30 15:09:41 +03:00
|
|
|
present_to: dict[str, int]
|
2025-06-06 08:20:45 +03:00
|
|
|
provider_name: str
|
|
|
|
|
purge_attempt_count: int
|
|
|
|
|
res_id: str
|
|
|
|
|
rescue_cd: bool
|
|
|
|
|
shared_with: list[int]
|
|
|
|
|
snapshot_id: str = ''
|
|
|
|
|
tech_status: _nested.ImageTechStatus
|
|
|
|
|
unc_path: str
|
|
|
|
|
version: str
|
|
|
|
|
vm_ci_id: int
|
|
|
|
|
|
|
|
|
|
@property
|
|
|
|
|
def deleted_datetime(self):
|
|
|
|
|
return self._get_datetime_from_timestamp(self.deleted_timestamp)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class CloudapiImageGetProtocol(_base.BasePostAPIFunctionProtocol):
|
|
|
|
|
def get(
|
|
|
|
|
self,
|
|
|
|
|
*,
|
|
|
|
|
image_id: int,
|
|
|
|
|
show_all: bool = False,
|
|
|
|
|
) -> CloudapiImageGetResultModel:
|
|
|
|
|
...
|