Options
All
  • Public
  • Public/Protected
  • All
Menu

Class DisassociateVpcCidrBlockCommand

Disassociates a CIDR block from a VPC. To disassociate the CIDR block, you must specify its association ID. You can get the association ID by using DescribeVpcs. You must detach or delete all gateways and resources that are associated with the CIDR block before you can disassociate it.

You cannot disassociate the CIDR block with which you originally created the VPC (the primary CIDR block).

example

Use a bare-bones client and the command you need to make an API call.

import { EC2Client, DisassociateVpcCidrBlockCommand } from "@aws-sdk/client-ec2"; // ES Modules import
// const { EC2Client, DisassociateVpcCidrBlockCommand } = require("@aws-sdk/client-ec2"); // CommonJS import
const client = new EC2Client(config);
const command = new DisassociateVpcCidrBlockCommand(input);
const response = await client.send(command);
see

DisassociateVpcCidrBlockCommandInput for command's input shape.

see

DisassociateVpcCidrBlockCommandOutput for command's response shape.

see

config for EC2Client's config shape.

Hierarchy

Implements

Index

Constructors

constructor

Properties

Readonly input

input: DisassociateVpcCidrBlockCommandInput

Readonly middlewareStack

Methods

Static getEndpointParameterInstructions