# EC2

### Supported operations <a href="#heading-supported-opertions" id="heading-supported-opertions"></a>

<table data-full-width="true"><thead><tr><th width="206.6363525390625">Operation</th><th width="233.63641357421875">Permissions Required</th><th>Example Prompts</th></tr></thead><tbody><tr><td>List vpcs</td><td>ec2:DescribeVpcs</td><td><pre data-full-width="true"><code>list all the vpcs

list all the vpcs which are not default </code></pre></td></tr><tr><td>Create vpc</td><td>ec2:CreateVpc</td><td><pre><code>create a vpc with '10.101.0.0/16' cidr\ </code></pre></td></tr><tr><td>Delete vpc</td><td>ec2:DeleteVpc</td><td><pre><code>delete a vpc with '\<vpc\_id>' id </code></pre></td></tr><tr><td>List subnets</td><td>ec2:DescribeSubnets</td><td><pre><code>list all the subnets

list all the subnets which are not default

list all the subnets under '\<vpc\_id>' vpc </code></pre></td></tr><tr><td>Create subnet</td><td>ec2:CreateSubnet</td><td><pre><code>create a subnet with '10.101.1.0/24' cidr under '\<vpc\_id>' id </code></pre></td></tr><tr><td>Delete subnet</td><td>ec2:DeleteSubnet</td><td><pre><code>delete a subnet with '\<subnet\_id>' id </code></pre></td></tr><tr><td>List instances</td><td>ec2:DescribeInstances</td><td><pre><code>list all the ec2 vms </code></pre></td></tr><tr><td>Provision instances</td><td>ec2:RunInstances</td><td><pre><code>Provision an ec2 vm with following details -
subnet id - \<subnet id>
ami id - \<ami id>
instance type - t2.micro
min count - 1
max count - 1 </code></pre></td></tr><tr><td>Start instances</td><td>ec2:StartInstances</td><td><pre><code>Start ec2 vms with following ids -
\<vm1 id>
\<vm2 id> </code></pre></td></tr><tr><td>Stop instances</td><td>ec2:StopInstances</td><td><pre><code>Stop ec2 vms with following ids -
\<vm1 id>
\<vm2 id> </code></pre></td></tr><tr><td>Describe instance types</td><td>ec2:DescribeInstanceTypes</td><td><pre><code>list all the instance types which are free tier eligible </code></pre></td></tr></tbody></table>


---

# Agent Instructions: 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.mechcloud.io/ai-agents/aws-agent/ec2.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.
