Amazon VPC VPCs API

Operations for creating and managing Virtual Private Clouds

OpenAPI Specification

amazon-vpc-vpcs-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: Amazon VPC Internet Gateways VPCs API
  description: Amazon Virtual Private Cloud (VPC) lets you provision a logically isolated section of the AWS Cloud where you can launch AWS resources in a virtual network that you define. VPC operations are part of the Amazon EC2 API and use the EC2 query-based API pattern.
  version: '2016-11-15'
  contact:
    name: Amazon Web Services
    url: https://aws.amazon.com/contact-us/
  termsOfService: https://aws.amazon.com/service-terms/
servers:
- url: https://ec2.{region}.amazonaws.com
  description: Amazon EC2 Regional Endpoint (VPC operations)
  variables:
    region:
      default: us-east-1
      description: AWS Region
security:
- sigv4Auth: []
tags:
- name: VPCs
  description: Operations for creating and managing Virtual Private Clouds
paths:
  /?Action=CreateVpc:
    get:
      operationId: createVpc
      summary: Amazon VPC Create a VPC
      description: Creates a VPC with the specified IPv4 CIDR block. The smallest VPC you can create uses a /28 netmask (16 IPv4 addresses), and the largest uses a /16 netmask (65,536 IPv4 addresses). After creating the VPC, you can add one or more subnets.
      tags:
      - VPCs
      parameters:
      - name: CidrBlock
        in: query
        required: true
        description: The IPv4 network range for the VPC in CIDR notation (e.g., 10.0.0.0/16)
        schema:
          type: string
        example: example-id
      - name: AmazonProvidedIpv6CidrBlock
        in: query
        description: Requests an Amazon-provided IPv6 CIDR block with a /56 prefix length
        schema:
          type: boolean
        example: true
      - name: InstanceTenancy
        in: query
        description: The tenancy options for instances launched into the VPC
        schema:
          type: string
          enum:
          - default
          - dedicated
          - host
        example: default
      responses:
        '200':
          description: Successfully created VPC
          content:
            application/xml:
              schema:
                $ref: '#/components/schemas/CreateVpcResponse'
        '400':
          description: Invalid request parameters
        '401':
          description: Authentication failure
        '403':
          description: Authorization failure
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
  /?Action=DescribeVpcs:
    get:
      operationId: describeVpcs
      summary: Amazon VPC Describe VPCs
      description: Describes one or more of your VPCs. Returns information about the VPC including the CIDR block, DHCP options set, state, and tags.
      tags:
      - VPCs
      parameters:
      - name: VpcId
        in: query
        description: The IDs of the VPCs to describe
        schema:
          type: array
          items:
            type: string
        example: example-id
      - name: Filter
        in: query
        description: Filters to apply to the results
        schema:
          type: array
          items:
            type: string
        example: example
      - name: MaxResults
        in: query
        description: Maximum number of results to return
        schema:
          type: integer
          minimum: 5
          maximum: 1000
        example: 1
      - name: NextToken
        in: query
        description: Token for the next page of results
        schema:
          type: string
        example: example
      responses:
        '200':
          description: Successfully described VPCs
          content:
            application/xml:
              schema:
                $ref: '#/components/schemas/DescribeVpcsResponse'
        '400':
          description: Invalid request parameters
        '401':
          description: Authentication failure
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
  /?Action=DeleteVpc:
    get:
      operationId: deleteVpc
      summary: Amazon VPC Delete a VPC
      description: Deletes the specified VPC. You must detach or delete all gateways and resources that are associated with the VPC before you can delete it. You must also delete all subnets associated with the VPC.
      tags:
      - VPCs
      parameters:
      - name: VpcId
        in: query
        required: true
        description: The ID of the VPC to delete
        schema:
          type: string
        example: example-id
      responses:
        '200':
          description: Successfully deleted VPC
        '400':
          description: Invalid request parameters
        '401':
          description: Authentication failure
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
  /?Action=ModifyVpcAttribute:
    get:
      operationId: modifyVpcAttribute
      summary: Amazon VPC Modify a VPC Attribute
      description: Modifies the specified attribute of the specified VPC. You can modify the DNS resolution and DNS hostname attributes.
      tags:
      - VPCs
      parameters:
      - name: VpcId
        in: query
        required: true
        description: The ID of the VPC
        schema:
          type: string
        example: example-id
      - name: EnableDnsSupport.Value
        in: query
        description: Indicates whether DNS resolution is supported for the VPC
        schema:
          type: boolean
        example: true
      - name: EnableDnsHostnames.Value
        in: query
        description: Indicates whether instances launched in the VPC get DNS hostnames
        schema:
          type: boolean
        example: true
      responses:
        '200':
          description: Successfully modified VPC attribute
        '400':
          description: Invalid request parameters
        '401':
          description: Authentication failure
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
components:
  schemas:
    DescribeVpcsResponse:
      type: object
      description: Response from the DescribeVpcs action
      properties:
        vpcSet:
          type: array
          description: Information about the VPCs
          items:
            $ref: '#/components/schemas/Vpc'
        nextToken:
          type: string
          description: Token for the next page of results
    Tag:
      type: object
      description: Describes a tag
      properties:
        key:
          type: string
          description: The key of the tag
        value:
          type: string
          description: The value of the tag
    CreateVpcResponse:
      type: object
      description: Response from the CreateVpc action
      properties:
        vpc:
          $ref: '#/components/schemas/Vpc'
    Vpc:
      type: object
      description: Describes a VPC
      properties:
        vpcId:
          type: string
          description: The ID of the VPC
        state:
          type: string
          description: The current state of the VPC
          enum:
          - pending
          - available
        cidrBlock:
          type: string
          description: The primary IPv4 CIDR block for the VPC
        cidrBlockAssociationSet:
          type: array
          description: Information about the IPv4 CIDR blocks associated with the VPC
          items:
            type: object
            properties:
              cidrBlock:
                type: string
              associationId:
                type: string
              cidrBlockState:
                type: object
                properties:
                  state:
                    type: string
        ipv6CidrBlockAssociationSet:
          type: array
          description: Information about the IPv6 CIDR blocks associated with the VPC
          items:
            type: object
            properties:
              ipv6CidrBlock:
                type: string
              associationId:
                type: string
              ipv6CidrBlockState:
                type: object
                properties:
                  state:
                    type: string
        dhcpOptionsId:
          type: string
          description: The ID of the set of DHCP options associated with the VPC
        instanceTenancy:
          type: string
          description: The allowed tenancy of instances launched into the VPC
          enum:
          - default
          - dedicated
          - host
        isDefault:
          type: boolean
          description: Indicates whether the VPC is the default VPC
        ownerId:
          type: string
          description: The ID of the AWS account that owns the VPC
        tags:
          type: array
          description: Any tags assigned to the VPC
          items:
            $ref: '#/components/schemas/Tag'
  securitySchemes:
    sigv4Auth:
      type: apiKey
      name: Authorization
      in: header
      description: AWS Signature Version 4 authentication
externalDocs:
  description: Amazon VPC API Reference
  url: https://docs.aws.amazon.com/AWSEC2/latest/APIReference/OperationList-query-vpc.html