Skip to main content

Restore an EC2 instance

Restores the specified EC2 instance backup to the specified target destination.

Query Parameters
  • embed string

    Embeds the details of each associated resource. Set the parameter to one of the following embeddable links to include additional details associated with the resource.

    Embeddable LinkDescription
    read-taskEmbeds the associated task in the response. For example, ?embed=read-task
    For more information about embedded links, refer to the Embedding Referenced Resources section of this guide.
Request Body required
  • source object required

    The EC2 instance backup to be restored.

  • backup_id string required

    The Clumio-assigned ID of the EC2 instance backup to be restored. Use the GET /backups/aws/ec2-instances endpoint to fetch valid values.

  • target object required

    The target configuration per EC2 restore type. Only one of these fields should be set.

  • ami_restore_target object

    The configuration for the restore to AMI.

  • description string

    The description for the AMI.

  • ebs_block_device_mappings object[] required

    Block device mappings chosen for the EBS volumes being restored.

  • kms_key_native_id string

    The AWS-assigned ID for a customer managed KMS key under which the EBS volume is encrypted.

  • name string required

    The device name where the EBS volume is attached to the instance, needed by instance_restore_target and ami_restore_target restore type and by volumes_restore_target when target_instance_native_id is provided.

  • tags object[]

    The AWS tags to be applied to the volume.

  • key string required

    The AWS-assigned tag key.

  • value string

    The AWS-assigned tag value.

  • volume_native_id string required

    The AWS-assigned ID of the backed-up volume.

  • environment_id string required

    The Clumio-assigned ID of the AWS environment to be used as the restore destination. Use the GET /datasources/aws/environments endpoint to fetch valid values.

  • name string required

    The name for the AMI.

  • tags object[]

    The AWS tags to be applied to the restored AMI.

  • key string required

    The AWS-assigned tag key.

  • value string

    The AWS-assigned tag value.

  • instance_restore_target object

    The configuration of an EC2 instance to be restored.

  • ami_native_id string

    The AWS-assigned ID of the Amazon Machine Image (AMI) used to launch the EC2 instance.

  • aws_az string required

    The availability zone for the instance. This is determined by the subnet chosen to restore the EC2 instance into.

  • ebs_block_device_mappings object[] required

    Block device mappings for the EBS volumes to restore.

  • kms_key_native_id string

    The AWS-assigned ID for a customer managed KMS key under which the EBS volume is encrypted.

  • name string required

    The device name where the EBS volume is attached to the instance, needed by instance_restore_target and ami_restore_target restore type and by volumes_restore_target when target_instance_native_id is provided.

  • tags object[]

    The AWS tags to be applied to the volume.

  • key string required

    The AWS-assigned tag key.

  • value string

    The AWS-assigned tag value.

  • volume_native_id string required

    The AWS-assigned ID of the backed-up volume.

  • environment_id string required

    The Clumio-assigned ID of the AWS environment to be used as the restore destination. Use the GET /datasources/aws/environments endpoint to fetch valid values.

  • iam_instance_profile_name string

    The name of IAM instance profile to launch the instance with.

  • key_pair_name string

    The name of SSH KeyPair to be used.

  • network_interfaces object[] required

    The network interfaces to associate with the instance.

  • device_index int64 required

    The position of the network interface in the attachment order. A primary network interface has a device index of 0.

  • network_interface_native_id string

    The AWS-assigned ID of the existing network interface to attach to the restored instance. If one wishes to restore this network interface from the backup, then this field should be set to null.

  • restore_default boolean

    Whether or not a default network interface should be restored. It will not have any of the same configurations as the backup network interface.

  • restore_from_backup boolean

    Whether or not the network interface should be restored the backup network interface. It will be configured with the same configurations as the backup network interface.

  • security_group_native_ids string[]

    The AWS-assigned IDs for the security groups to associate with this network interface. If one wishes to attach an existing network interface, then this field should be set to null.

  • subnet_native_id string

    The AWS-assigned ID of the subnet associated with the network interface. If one wishes to attach an existing network interface, then this field should be set to null.

  • should_power_on boolean

    Default value: false

    Whether or not to power the instance on at the end of restore. If this is set to true, the instance state will be 'running.' If it is set to false, the state will be 'stopped.'

  • subnet_native_id string required

    The AWS-assigned ID of the subnet to launch the instance into.

  • tags object[]

    The AWS tags to be applied to the restored instance.

  • key string required

    The AWS-assigned tag key.

  • value string

    The AWS-assigned tag value.

  • vpc_native_id string required

    The AWS-assigned ID of the vpc to launch the instance into.

  • volumes_restore_target object

    The target configuration for the volumes to be restored.

  • aws_az string

    The availability zone for restoring the volumes unattached. Either this or target_instance_native_id needs to be specified.

  • ebs_block_device_mappings object[] required

    Block device mappings chosen for the EBS volumes being restored.

  • kms_key_native_id string

    The AWS-assigned ID for a customer managed KMS key under which the EBS volume is encrypted.

  • name string required

    The device name where the EBS volume is attached to the instance, needed by instance_restore_target and ami_restore_target restore type and by volumes_restore_target when target_instance_native_id is provided.

  • tags object[]

    The AWS tags to be applied to the volume.

  • key string required

    The AWS-assigned tag key.

  • value string

    The AWS-assigned tag value.

  • volume_native_id string required

    The AWS-assigned ID of the backed-up volume.

  • environment_id string required

    The Clumio-assigned ID of the AWS environment to be used as the restore destination. Use the GET /datasources/aws/environments endpoint to fetch valid values.

  • target_instance_native_id string

    The aws native ID of the EC2 instance to be used to attach the restored volumes. If not present, then aws_az need to be specified.

Responses

Success


Schema
  • _embedded object

    Embedded responses related to the resource.

  • read-task Embeds the associated task of a resource in the response if requested using the `embed` query parameter.

    Embeds the associated task of a resource in the response if requested using the embed query parameter.

  • _links object

    URLs to pages related to the resource.

  • _self object

    The HATEOAS link to this resource.

  • href string

    The URI for the referenced operation.

  • templated boolean

    Determines whether the "href" link is a URI template. If set to true, the "href" link is a URI template.

  • type string

    The HTTP method to be used with the "href" link for the referenced operation.

  • read-task object

    A HATEOAS link to the task associated with this resource.

  • href string

    The URI for the referenced operation.

  • templated boolean

    Determines whether the "href" link is a URI template. If set to true, the "href" link is a URI template.

  • type string

    The HTTP method to be used with the "href" link for the referenced operation.

  • task_id string

    The Clumio-assigned ID of the task created by this restore request. The progress of the task can be monitored using the GET /tasks/{task_id} endpoint.

POST /restores/aws/ec2-instances    

Authorization

Request

Click Edit to configure Base URL
https://us-west-2.api.clumio.com
Bearer Token
embed — query
Body required
{
"source": {
"backup_id": "string"
},
"target": {
"ami_restore_target": {
"description": "string",
"ebs_block_device_mappings": [
{
"kms_key_native_id": "string",
"name": "string",
"tags": [
{
"key": "string",
"value": "string"
}
],
"volume_native_id": "string"
}
],
"environment_id": "string",
"name": "string",
"tags": [
{
"key": "string",
"value": "string"
}
]
},
"instance_restore_target": {
"ami_native_id": "string",
"aws_az": "string",
"ebs_block_device_mappings": [
{
"kms_key_native_id": "string",
"name": "string",
"tags": [
{
"key": "string",
"value": "string"
}
],
"volume_native_id": "string"
}
],
"environment_id": "string",
"iam_instance_profile_name": "string",
"key_pair_name": "string",
"network_interfaces": [
{
"device_index": 0,
"network_interface_native_id": "string",
"restore_default": true,
"restore_from_backup": true,
"security_group_native_ids": [
"string"
],
"subnet_native_id": "string"
}
],
"should_power_on": false,
"subnet_native_id": "string",
"tags": [
{
"key": "string",
"value": "string"
}
],
"vpc_native_id": "string"
},
"volumes_restore_target": {
"aws_az": "string",
"ebs_block_device_mappings": [
{
"kms_key_native_id": "string",
"name": "string",
"tags": [
{
"key": "string",
"value": "string"
}
],
"volume_native_id": "string"
}
],
"environment_id": "string",
"target_instance_native_id": "string"
}
}
}
curl -L -X POST 'https://us-west-2.api.clumio.com/restores/aws/ec2-instances' \
-H 'Content-Type: application/json' \
-H 'Accept: application/api.clumio.restored-aws-ec2-instances=v1+json' \
-H 'Authorization: Bearer <TOKEN>' \
--data-raw '{
"source": {
"backup_id": "string"
},
"target": {
"ami_restore_target": {
"description": "string",
"ebs_block_device_mappings": [
{
"kms_key_native_id": "string",
"name": "string",
"tags": [
{
"key": "string",
"value": "string"
}
],
"volume_native_id": "string"
}
],
"environment_id": "string",
"name": "string",
"tags": [
{
"key": "string",
"value": "string"
}
]
},
"instance_restore_target": {
"ami_native_id": "string",
"aws_az": "string",
"ebs_block_device_mappings": [
{
"kms_key_native_id": "string",
"name": "string",
"tags": [
{
"key": "string",
"value": "string"
}
],
"volume_native_id": "string"
}
],
"environment_id": "string",
"iam_instance_profile_name": "string",
"key_pair_name": "string",
"network_interfaces": [
{
"device_index": 0,
"network_interface_native_id": "string",
"restore_default": true,
"restore_from_backup": true,
"security_group_native_ids": [
"string"
],
"subnet_native_id": "string"
}
],
"should_power_on": false,
"subnet_native_id": "string",
"tags": [
{
"key": "string",
"value": "string"
}
],
"vpc_native_id": "string"
},
"volumes_restore_target": {
"aws_az": "string",
"ebs_block_device_mappings": [
{
"kms_key_native_id": "string",
"name": "string",
"tags": [
{
"key": "string",
"value": "string"
}
],
"volume_native_id": "string"
}
],
"environment_id": "string",
"target_instance_native_id": "string"
}
}
}'