Skip to content

Get available images

Getting a list of installed images in the sandbox:

Code example
from ptsandbox import Sandbox, SandboxKey

async def example() -> None:
    key = SandboxKey(...)
    sandbox = Sandbox(key)

    images = await sandbox.get_images()
    print(images)

Example output

[
    SandboxImageInfo(image_id='ubuntu-jammy-x64', ...),
    SandboxImageInfo(image_id='win10-1803-x64', ...),
    ...
]

ptsandbox.sandbox.sandbox.Sandbox.get_images async

get_images() -> list[SandboxImageInfo]

Get a list of available images in the sandbox

Raises:

  • ClientResponseError

    if the server returns an error status

  • ClientError

    on connection or transport errors

  • ValidationError

    if the response body does not match the expected model

ptsandbox.sandbox.api._maintenance.MaintenanceMixin.get_images async

get_images() -> SandboxGetImagesResponse

Get a list of available images in the sandbox

Raises:

  • ClientResponseError

    if the server returns an error status

  • ClientError

    on connection or transport errors

  • ValidationError

    if the response body does not match the expected model