Options
All
  • Public
  • Public/Protected
  • All
Menu

Class DetachInternetGatewayCommand

Detaches an internet gateway from a VPC, disabling connectivity between the internet and the VPC. The VPC must not contain any running instances with Elastic IP addresses or public IPv4 addresses.

example

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

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

DetachInternetGatewayCommandInput for command's input shape.

see

DetachInternetGatewayCommandOutput for command's response shape.

see

config for EC2Client's config shape.

Hierarchy

Implements

Index

Constructors

constructor

Properties

Readonly input

input: DetachInternetGatewayCommandInput

Readonly middlewareStack

Methods

Static getEndpointParameterInstructions