Skip to content

import_volume

Operation

import_volume

import_volume(request: ImportVolumeInput | ImportVolumeInputDict | None = None, /, *, plugins: list[Plugin] | None = None, **kwargs: Unpack[ImportVolumeInputDict]) -> ImportVolumeOutput
Note

This API action supports only single-volume VMs. To import multi-volume VMs, use ImportImage instead. To import a disk to a snapshot, use ImportSnapshot instead.

Creates an import volume task using metadata from the specified disk image.

For information about the import manifest referenced by this API action, see VM Import Manifest.

This API action is not supported by the Command Line Interface (CLI).

Parameters:

Name Type Description Default
request ImportVolumeInput | ImportVolumeInputDict | None

The input as a model or dictionary. Pass this or keyword arguments, not both.

None
plugins list[Plugin] | None

A list of callables that modify the configuration dynamically. Changes made by these plugins only apply for the duration of the operation execution and will not affect any other operation invocations.

None
**kwargs Unpack[ImportVolumeInputDict]

The input fields as keyword arguments.

{}

Returns:

Type Description
ImportVolumeOutput

An instance of ImportVolumeOutput.

import_volume async

import_volume(request: ImportVolumeInput | ImportVolumeInputDict | None = None, /, *, plugins: list[Plugin] | None = None, **kwargs: Unpack[ImportVolumeInputDict]) -> ImportVolumeOutput
Note

This API action supports only single-volume VMs. To import multi-volume VMs, use ImportImage instead. To import a disk to a snapshot, use ImportSnapshot instead.

Creates an import volume task using metadata from the specified disk image.

For information about the import manifest referenced by this API action, see VM Import Manifest.

This API action is not supported by the Command Line Interface (CLI).

Parameters:

Name Type Description Default
request ImportVolumeInput | ImportVolumeInputDict | None

The input as a model or dictionary. Pass this or keyword arguments, not both.

None
plugins list[Plugin] | None

A list of callables that modify the configuration dynamically. Changes made by these plugins only apply for the duration of the operation execution and will not affect any other operation invocations.

None
**kwargs Unpack[ImportVolumeInputDict]

The input fields as keyword arguments.

{}

Returns:

Type Description
ImportVolumeOutput

An instance of ImportVolumeOutput.

Input

Pass the input as keyword arguments, a positional dictionary, or a positional model object. Pass plugins separately as a keyword argument.

ImportVolumeInputDict

Bases: TypedDict

Dictionary form of ImportVolumeInput.

Attributes

availability_zone instance-attribute
availability_zone: str | None

The Availability Zone for the resulting EBS volume.

Either AvailabilityZone or AvailabilityZoneId must be specified, but not both.

availability_zone_id instance-attribute
availability_zone_id: str | None

The ID of the Availability Zone for the resulting EBS volume.

Either AvailabilityZone or AvailabilityZoneId must be specified, but not both.

description instance-attribute
description: str | None

A description of the volume.

dry_run instance-attribute
dry_run: bool | None

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

image instance-attribute

The disk image.

volume instance-attribute

The volume size.

ImportVolumeInput dataclass

Bases: _SerdeShape

Dataclass for ImportVolumeInput structure.

Attributes

availability_zone class-attribute instance-attribute
availability_zone: str | None = ...

The Availability Zone for the resulting EBS volume.

Either AvailabilityZone or AvailabilityZoneId must be specified, but not both.

availability_zone_id class-attribute instance-attribute
availability_zone_id: str | None = ...

The ID of the Availability Zone for the resulting EBS volume.

Either AvailabilityZone or AvailabilityZoneId must be specified, but not both.

description class-attribute instance-attribute
description: str | None = ...

A description of the volume.

dry_run class-attribute instance-attribute
dry_run: bool | None = ...

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

image class-attribute instance-attribute
image: DiskImageDetail | None = ...

The disk image.

volume class-attribute instance-attribute
volume: VolumeDetail | None = ...

The volume size.

Output

ImportVolumeOutput dataclass

Bases: _SerdeShape

Dataclass for ImportVolumeOutput structure.

Attributes

conversion_task class-attribute instance-attribute
conversion_task: ConversionTask | None = ...

Information about the conversion task.

response_metadata class-attribute instance-attribute
response_metadata: ResponseMetadata = ...

Metadata about the response that produced this output. Use this to recover the request identifiers a service's support team needs in order to investigate a call. Members of the metadata are individually optional.