Skip to content

EC2  >  Operations  >  restore_snapshot_tier

restore_snapshot_tier

Operation

restore_snapshot_tier async

restore_snapshot_tier(request: RestoreSnapshotTierInput | RestoreSnapshotTierInputDict, /, *, plugins: list[Plugin] | None = None) -> RestoreSnapshotTierOutput
restore_snapshot_tier(*, plugins: list[Plugin] | None = None, **kwargs: Unpack[RestoreSnapshotTierInputDict]) -> RestoreSnapshotTierOutput

Restores an archived Amazon EBS snapshot for use temporarily or permanently, or modifies the restore period or restore type for a snapshot that was previously temporarily restored.

For more information see Restore an archived snapshot and modify the restore period or restore type for a temporarily restored snapshot in the Amazon EBS User Guide.

Parameters:

Name Type Description Default
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

Returns:

Type Description
RestoreSnapshotTierOutput

An instance of RestoreSnapshotTierOutput.

Input

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

Model

RestoreSnapshotTierInput dataclass

Bases: _SerdeShape

Dataclass for RestoreSnapshotTierInput structure.

Attributes
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.

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

Indicates whether to permanently restore an archived snapshot. To permanently restore an archived snapshot, specify true and omit the RestoreSnapshotTierRequest$TemporaryRestoreDays parameter.

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

The ID of the snapshot to restore.

temporary_restore_days class-attribute instance-attribute
temporary_restore_days: int | None = ...

Specifies the number of days for which to temporarily restore an archived snapshot. Required for temporary restores only. The snapshot will be automatically re-archived after this period.

To temporarily restore an archived snapshot, specify the number of days and omit the PermanentRestore parameter or set it to false.

Dictionaries

RestoreSnapshotTierInputDict

Bases: TypedDict

Dictionary form of RestoreSnapshotTierInput.

Attributes
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.

permanent_restore instance-attribute
permanent_restore: bool | None

Indicates whether to permanently restore an archived snapshot. To permanently restore an archived snapshot, specify true and omit the RestoreSnapshotTierRequest$TemporaryRestoreDays parameter.

snapshot_id instance-attribute
snapshot_id: Required[str]

The ID of the snapshot to restore.

temporary_restore_days instance-attribute
temporary_restore_days: int | None

Specifies the number of days for which to temporarily restore an archived snapshot. Required for temporary restores only. The snapshot will be automatically re-archived after this period.

To temporarily restore an archived snapshot, specify the number of days and omit the PermanentRestore parameter or set it to false.

Output

RestoreSnapshotTierOutput dataclass

Bases: _SerdeShape

Dataclass for RestoreSnapshotTierOutput structure.

Attributes

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

Indicates whether the snapshot is permanently restored. true indicates a permanent restore. false indicates a temporary restore.

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.

restore_duration class-attribute instance-attribute
restore_duration: int | None = ...

For temporary restores only. The number of days for which the archived snapshot is temporarily restored.

restore_start_time class-attribute instance-attribute
restore_start_time: datetime | None = ...

The date and time when the snapshot restore process started.

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

The ID of the snapshot.