> For the complete documentation index, see [llms.txt](https://docs.skeddly.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.skeddly.com/data-types/attachvolumetoinstanceparameters-object.md).

# AttachVolumeToInstanceParameters Object

## Description

Specifies parameters to use when attaching an EBS volume to an EC2 instance.

## Properties

### deviceName

Name of the device to attach the volume as. For example, `/dev/xvda1`.

Type: `string`

Required: Yes

### instanceId

ID of the EC2 instance to which the EBS volume will be attached. Required when `instanceIdentificationMethod` is `by-instance-id`.

Type: `string`

Required: Conditional

### instanceIdentificationMethod

Method of identifying the EC2 instance to which attach the volume.

Type: `string`

Valid Values:

* `by-instance-id`

Required: Yes

### isDetachExistingDevice

Indicates whether an existing device previously using the specified device name should be detached first. If a device is already using the specified device name, and this field is `false`, then the volume cannot be attached.

Type: `boolean`

Required: No

Default: `false`

### IsStopInstance

Indicates whether the target EC2 instance should be stopped when attaching the EBS volume.

Type: `boolean`

Required: No

Default: `false`

## Sample JSON

```javascript
{
    "instanceIdentificationMethod": "by-instance-id",
    "instanceId": "i-00000000",
    "deviceName": "/dev/xvda1",
    "isDetachExistingDevice": true,
    "isStopInstance": true
}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.skeddly.com/data-types/attachvolumetoinstanceparameters-object.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
