SDK for PHP 3.x

Client: Aws\Ec2\Ec2Client
Service ID: ec2
Version: 2015-10-01

This page describes the parameters and results for the operations of the Amazon Elastic Compute Cloud (2015-10-01), and shows how to use the Aws\Ec2\Ec2Client object to call the described operations. This documentation is specific to the 2015-10-01 API version of the service.

Operation Summary

Each of the following operations can be created from a client using $client->getCommand('CommandName'), where "CommandName" is the name of one of the following operations. Note: a command is a value that encapsulates an operation and the parameters used to create an HTTP request.

You can also create and send a command immediately using the magic methods available on a client object: $client->commandName(/* parameters */). You can send the command asynchronously (returning a promise) by appending the word "Async" to the operation name: $client->commandNameAsync(/* parameters */).

AcceptVpcPeeringConnection ( array $params = [] )
Accept a VPC peering connection request.
AllocateAddress ( array $params = [] )
Acquires an Elastic IP address.
AllocateHosts ( array $params = [] )
Allocates a Dedicated host to your account.
AssignPrivateIpAddresses ( array $params = [] )
Assigns one or more secondary private IP addresses to the specified network interface.
AssociateAddress ( array $params = [] )
Associates an Elastic IP address with an instance or a network interface.
AssociateDhcpOptions ( array $params = [] )
Associates a set of DHCP options (that you've previously created) with the specified VPC, or associates no DHCP options with the VPC.
AssociateRouteTable ( array $params = [] )
Associates a subnet with a route table.
AttachClassicLinkVpc ( array $params = [] )
Links an EC2-Classic instance to a ClassicLink-enabled VPC through one or more of the VPC's security groups.
AttachInternetGateway ( array $params = [] )
Attaches an Internet gateway to a VPC, enabling connectivity between the Internet and the VPC.
AttachNetworkInterface ( array $params = [] )
Attaches a network interface to an instance.
AttachVolume ( array $params = [] )
Attaches an EBS volume to a running or stopped instance and exposes it to the instance with the specified device name.
AttachVpnGateway ( array $params = [] )
Attaches a virtual private gateway to a VPC.
AuthorizeSecurityGroupEgress ( array $params = [] )
[EC2-VPC only] Adds one or more egress rules to a security group for use with a VPC.
AuthorizeSecurityGroupIngress ( array $params = [] )
Adds one or more ingress rules to a security group.
BundleInstance ( array $params = [] )
Bundles an Amazon instance store-backed Windows instance.
CancelBundleTask ( array $params = [] )
Cancels a bundling operation for an instance store-backed Windows instance.
CancelConversionTask ( array $params = [] )
Cancels an active conversion task.
CancelExportTask ( array $params = [] )
Cancels an active export task.
CancelImportTask ( array $params = [] )
Cancels an in-process import virtual machine or import snapshot task.
CancelReservedInstancesListing ( array $params = [] )
Cancels the specified Reserved Instance listing in the Reserved Instance Marketplace.
CancelSpotFleetRequests ( array $params = [] )
Cancels the specified Spot fleet requests.
CancelSpotInstanceRequests ( array $params = [] )
Cancels one or more Spot instance requests.
ConfirmProductInstance ( array $params = [] )
Determines whether a product code is associated with an instance.
CopyImage ( array $params = [] )
Initiates the copy of an AMI from the specified source region to the current region.
CopySnapshot ( array $params = [] )
Copies a point-in-time snapshot of an EBS volume and stores it in Amazon S3.
CreateCustomerGateway ( array $params = [] )
Provides information to AWS about your VPN customer gateway device.
CreateDhcpOptions ( array $params = [] )
Creates a set of DHCP options for your VPC.
CreateFlowLogs ( array $params = [] )
Creates one or more flow logs to capture IP traffic for a specific network interface, subnet, or VPC.
CreateImage ( array $params = [] )
Creates an Amazon EBS-backed AMI from an Amazon EBS-backed instance that is either running or stopped.
CreateInstanceExportTask ( array $params = [] )
Exports a running or stopped instance to an S3 bucket.
CreateInternetGateway ( array $params = [] )
Creates an Internet gateway for use with a VPC.
CreateKeyPair ( array $params = [] )
Creates a 2048-bit RSA key pair with the specified name.
CreateNatGateway ( array $params = [] )
Creates a NAT gateway in the specified subnet.
CreateNetworkAcl ( array $params = [] )
Creates a network ACL in a VPC.
CreateNetworkAclEntry ( array $params = [] )
Creates an entry (a rule) in a network ACL with the specified rule number.
CreateNetworkInterface ( array $params = [] )
Creates a network interface in the specified subnet.
CreatePlacementGroup ( array $params = [] )
Creates a placement group that you launch cluster instances into.
CreateReservedInstancesListing ( array $params = [] )
Creates a listing for Amazon EC2 Reserved Instances to be sold in the Reserved Instance Marketplace.
CreateRoute ( array $params = [] )
Creates a route in a route table within a VPC.
CreateRouteTable ( array $params = [] )
Creates a route table for the specified VPC.
CreateSecurityGroup ( array $params = [] )
Creates a security group.
CreateSnapshot ( array $params = [] )
Creates a snapshot of an EBS volume and stores it in Amazon S3.
CreateSpotDatafeedSubscription ( array $params = [] )
Creates a data feed for Spot instances, enabling you to view Spot instance usage logs.
CreateSubnet ( array $params = [] )
Creates a subnet in an existing VPC.
CreateTags ( array $params = [] )
Adds or overwrites one or more tags for the specified Amazon EC2 resource or resources.
CreateVolume ( array $params = [] )
Creates an EBS volume that can be attached to an instance in the same Availability Zone.
CreateVpc ( array $params = [] )
Creates a VPC with the specified CIDR block.
CreateVpcEndpoint ( array $params = [] )
Creates a VPC endpoint for a specified AWS service.
CreateVpcPeeringConnection ( array $params = [] )
Requests a VPC peering connection between two VPCs: a requester VPC that you own and a peer VPC with which to create the connection.
CreateVpnConnection ( array $params = [] )
Creates a VPN connection between an existing virtual private gateway and a VPN customer gateway.
CreateVpnConnectionRoute ( array $params = [] )
Creates a static route associated with a VPN connection between an existing virtual private gateway and a VPN customer gateway.
CreateVpnGateway ( array $params = [] )
Creates a virtual private gateway.
DeleteCustomerGateway ( array $params = [] )
Deletes the specified customer gateway.
DeleteDhcpOptions ( array $params = [] )
Deletes the specified set of DHCP options.
DeleteFlowLogs ( array $params = [] )
Deletes one or more flow logs.
DeleteInternetGateway ( array $params = [] )
Deletes the specified Internet gateway.
DeleteKeyPair ( array $params = [] )
Deletes the specified key pair, by removing the public key from Amazon EC2.
DeleteNatGateway ( array $params = [] )
Deletes the specified NAT gateway.
DeleteNetworkAcl ( array $params = [] )
Deletes the specified network ACL.
DeleteNetworkAclEntry ( array $params = [] )
Deletes the specified ingress or egress entry (rule) from the specified network ACL.
DeleteNetworkInterface ( array $params = [] )
Deletes the specified network interface.
DeletePlacementGroup ( array $params = [] )
Deletes the specified placement group.
DeleteRoute ( array $params = [] )
Deletes the specified route from the specified route table.
DeleteRouteTable ( array $params = [] )
Deletes the specified route table.
DeleteSecurityGroup ( array $params = [] )
Deletes a security group.
DeleteSnapshot ( array $params = [] )
Deletes the specified snapshot.
DeleteSpotDatafeedSubscription ( array $params = [] )
Deletes the data feed for Spot instances.
DeleteSubnet ( array $params = [] )
Deletes the specified subnet.
DeleteTags ( array $params = [] )
Deletes the specified set of tags from the specified set of resources.
DeleteVolume ( array $params = [] )
Deletes the specified EBS volume.
DeleteVpc ( array $params = [] )
Deletes the specified VPC.
DeleteVpcEndpoints ( array $params = [] )
Deletes one or more specified VPC endpoints.
DeleteVpcPeeringConnection ( array $params = [] )
Deletes a VPC peering connection.
DeleteVpnConnection ( array $params = [] )
Deletes the specified VPN connection.
DeleteVpnConnectionRoute ( array $params = [] )
Deletes the specified static route associated with a VPN connection between an existing virtual private gateway and a VPN customer gateway.
DeleteVpnGateway ( array $params = [] )
Deletes the specified virtual private gateway.
DeregisterImage ( array $params = [] )
Deregisters the specified AMI.
DescribeAccountAttributes ( array $params = [] )
Describes attributes of your AWS account.
DescribeAddresses ( array $params = [] )
Describes one or more of your Elastic IP addresses.
DescribeAvailabilityZones ( array $params = [] )
Describes one or more of the Availability Zones that are available to you.
DescribeBundleTasks ( array $params = [] )
Describes one or more of your bundling tasks.
DescribeClassicLinkInstances ( array $params = [] )
Describes one or more of your linked EC2-Classic instances.
DescribeConversionTasks ( array $params = [] )
Describes one or more of your conversion tasks.
DescribeCustomerGateways ( array $params = [] )
Describes one or more of your VPN customer gateways.
DescribeDhcpOptions ( array $params = [] )
Describes one or more of your DHCP options sets.
DescribeExportTasks ( array $params = [] )
Describes one or more of your export tasks.
DescribeFlowLogs ( array $params = [] )
Describes one or more flow logs.
DescribeHosts ( array $params = [] )
Describes one or more of your Dedicated hosts.
DescribeIdFormat ( array $params = [] )
Describes the ID format settings for your resources on a per-region basis, for example, to view which resource types are enabled for longer IDs.
DescribeImageAttribute ( array $params = [] )
Describes the specified attribute of the specified AMI.
DescribeImages ( array $params = [] )
Describes one or more of the images (AMIs, AKIs, and ARIs) available to you.
DescribeImportImageTasks ( array $params = [] )
Displays details about an import virtual machine or import snapshot tasks that are already created.
DescribeImportSnapshotTasks ( array $params = [] )
Describes your import snapshot tasks.
DescribeInstanceAttribute ( array $params = [] )
Describes the specified attribute of the specified instance.
DescribeInstanceStatus ( array $params = [] )
Describes the status of one or more instances.
DescribeInstances ( array $params = [] )
Describes one or more of your instances.
DescribeInternetGateways ( array $params = [] )
Describes one or more of your Internet gateways.
DescribeKeyPairs ( array $params = [] )
Describes one or more of your key pairs.
DescribeMovingAddresses ( array $params = [] )
Describes your Elastic IP addresses that are being moved to the EC2-VPC platform, or that are being restored to the EC2-Classic platform.
DescribeNatGateways ( array $params = [] )
Describes one or more of the your NAT gateways.
DescribeNetworkAcls ( array $params = [] )
Describes one or more of your network ACLs.
DescribeNetworkInterfaceAttribute ( array $params = [] )
Describes a network interface attribute.
DescribeNetworkInterfaces ( array $params = [] )
Describes one or more of your network interfaces.
DescribePlacementGroups ( array $params = [] )
Describes one or more of your placement groups.
DescribePrefixLists ( array $params = [] )
Describes available AWS services in a prefix list format, which includes the prefix list name and prefix list ID of the service and the IP address range for the service.
DescribeRegions ( array $params = [] )
Describes one or more regions that are currently available to you.
DescribeReservedInstances ( array $params = [] )
Describes one or more of the Reserved Instances that you purchased.
DescribeReservedInstancesListings ( array $params = [] )
Describes your account's Reserved Instance listings in the Reserved Instance Marketplace.
DescribeReservedInstancesModifications ( array $params = [] )
Describes the modifications made to your Reserved Instances.
DescribeReservedInstancesOfferings ( array $params = [] )
Describes Reserved Instance offerings that are available for purchase.
DescribeRouteTables ( array $params = [] )
Describes one or more of your route tables.
DescribeScheduledInstanceAvailability ( array $params = [] )
Finds available schedules that meet the specified criteria.
DescribeScheduledInstances ( array $params = [] )
Describes one or more of your Scheduled Instances.
DescribeSecurityGroupReferences ( array $params = [] )
[EC2-VPC only] Describes the VPCs on the other side of a VPC peering connection that are referencing the security groups you've specified in this request.
DescribeSecurityGroups ( array $params = [] )
Describes one or more of your security groups.
DescribeSnapshotAttribute ( array $params = [] )
Describes the specified attribute of the specified snapshot.
DescribeSnapshots ( array $params = [] )
Describes one or more of the EBS snapshots available to you.
DescribeSpotDatafeedSubscription ( array $params = [] )
Describes the data feed for Spot instances.
DescribeSpotFleetInstances ( array $params = [] )
Describes the running instances for the specified Spot fleet.
DescribeSpotFleetRequestHistory ( array $params = [] )
Describes the events for the specified Spot fleet request during the specified time.
DescribeSpotFleetRequests ( array $params = [] )
Describes your Spot fleet requests.
DescribeSpotInstanceRequests ( array $params = [] )
Describes the Spot instance requests that belong to your account.
DescribeSpotPriceHistory ( array $params = [] )
Describes the Spot price history.
DescribeStaleSecurityGroups ( array $params = [] )
[EC2-VPC only] Describes the stale security group rules for security groups in a specified VPC.
DescribeSubnets ( array $params = [] )
Describes one or more of your subnets.
DescribeTags ( array $params = [] )
Describes one or more of the tags for your EC2 resources.
DescribeVolumeAttribute ( array $params = [] )
Describes the specified attribute of the specified volume.
DescribeVolumeStatus ( array $params = [] )
Describes the status of the specified volumes.
DescribeVolumes ( array $params = [] )
Describes the specified EBS volumes.
DescribeVpcAttribute ( array $params = [] )
Describes the specified attribute of the specified VPC.
DescribeVpcClassicLink ( array $params = [] )
Describes the ClassicLink status of one or more VPCs.
DescribeVpcClassicLinkDnsSupport ( array $params = [] )
Describes the ClassicLink DNS support status of one or more VPCs.
DescribeVpcEndpointServices ( array $params = [] )
Describes all supported AWS services that can be specified when creating a VPC endpoint.
DescribeVpcEndpoints ( array $params = [] )
Describes one or more of your VPC endpoints.
DescribeVpcPeeringConnections ( array $params = [] )
Describes one or more of your VPC peering connections.
DescribeVpcs ( array $params = [] )
Describes one or more of your VPCs.
DescribeVpnConnections ( array $params = [] )
Describes one or more of your VPN connections.
DescribeVpnGateways ( array $params = [] )
Describes one or more of your virtual private gateways.
DetachClassicLinkVpc ( array $params = [] )
Unlinks (detaches) a linked EC2-Classic instance from a VPC.
DetachInternetGateway ( array $params = [] )
Detaches an Internet gateway from a VPC, disabling connectivity between the Internet and the VPC.
DetachNetworkInterface ( array $params = [] )
Detaches a network interface from an instance.
DetachVolume ( array $params = [] )
Detaches an EBS volume from an instance.
DetachVpnGateway ( array $params = [] )
Detaches a virtual private gateway from a VPC.
DisableVgwRoutePropagation ( array $params = [] )
Disables a virtual private gateway (VGW) from propagating routes to a specified route table of a VPC.
DisableVpcClassicLink ( array $params = [] )
Disables ClassicLink for a VPC.
DisableVpcClassicLinkDnsSupport ( array $params = [] )
Disables ClassicLink DNS support for a VPC.
DisassociateAddress ( array $params = [] )
Disassociates an Elastic IP address from the instance or network interface it's associated with.
DisassociateRouteTable ( array $params = [] )
Disassociates a subnet from a route table.
EnableVgwRoutePropagation ( array $params = [] )
Enables a virtual private gateway (VGW) to propagate routes to the specified route table of a VPC.
EnableVolumeIO ( array $params = [] )
Enables I/O operations for a volume that had I/O operations disabled because the data on the volume was potentially inconsistent.
EnableVpcClassicLink ( array $params = [] )
Enables a VPC for ClassicLink.
EnableVpcClassicLinkDnsSupport ( array $params = [] )
Enables a VPC to support DNS hostname resolution for ClassicLink.
GetConsoleOutput ( array $params = [] )
Gets the console output for the specified instance.
GetConsoleScreenshot ( array $params = [] )
Retrieve a JPG-format screenshot of a running instance to help with troubleshooting.
GetPasswordData ( array $params = [] )
Retrieves the encrypted administrator password for an instance running Windows.
ImportImage ( array $params = [] )
Import single or multi-volume disk images or EBS snapshots into an Amazon Machine Image (AMI).
ImportInstance ( array $params = [] )
Creates an import instance task using metadata from the specified disk image.
ImportKeyPair ( array $params = [] )
Imports the public key from an RSA key pair that you created with a third-party tool.
ImportSnapshot ( array $params = [] )
Imports a disk into an EBS snapshot.
ImportVolume ( array $params = [] )
Creates an import volume task using metadata from the specified disk image.
ModifyHosts ( array $params = [] )
Modify the auto-placement setting of a Dedicated host.
ModifyIdFormat ( array $params = [] )
Modifies the ID format for the specified resource on a per-region basis.
ModifyImageAttribute ( array $params = [] )
Modifies the specified attribute of the specified AMI.
ModifyInstanceAttribute ( array $params = [] )
Modifies the specified attribute of the specified instance.
ModifyInstancePlacement ( array $params = [] )
Set the instance affinity value for a specific stopped instance and modify the instance tenancy setting.
ModifyNetworkInterfaceAttribute ( array $params = [] )
Modifies the specified network interface attribute.
ModifyReservedInstances ( array $params = [] )
Modifies the Availability Zone, instance count, instance type, or network platform (EC2-Classic or EC2-VPC) of your Reserved Instances.
ModifySnapshotAttribute ( array $params = [] )
Adds or removes permission settings for the specified snapshot.
ModifySpotFleetRequest ( array $params = [] )
Modifies the specified Spot fleet request.
ModifySubnetAttribute ( array $params = [] )
Modifies a subnet attribute.
ModifyVolumeAttribute ( array $params = [] )
Modifies a volume attribute.
ModifyVpcAttribute ( array $params = [] )
Modifies the specified attribute of the specified VPC.
ModifyVpcEndpoint ( array $params = [] )
Modifies attributes of a specified VPC endpoint.
ModifyVpcPeeringConnectionOptions ( array $params = [] )
Modifies the VPC peering connection options on one side of a VPC peering connection.
MonitorInstances ( array $params = [] )
Enables monitoring for a running instance.
MoveAddressToVpc ( array $params = [] )
Moves an Elastic IP address from the EC2-Classic platform to the EC2-VPC platform.
PurchaseReservedInstancesOffering ( array $params = [] )
Purchases a Reserved Instance for use with your account.
PurchaseScheduledInstances ( array $params = [] )
Purchases one or more Scheduled Instances with the specified schedule.
RebootInstances ( array $params = [] )
Requests a reboot of one or more instances.
RegisterImage ( array $params = [] )
Registers an AMI.
RejectVpcPeeringConnection ( array $params = [] )
Rejects a VPC peering connection request.
ReleaseAddress ( array $params = [] )
Releases the specified Elastic IP address.
ReleaseHosts ( array $params = [] )
When you no longer want to use a Dedicated host it can be released.
ReplaceNetworkAclAssociation ( array $params = [] )
Changes which network ACL a subnet is associated with.
ReplaceNetworkAclEntry ( array $params = [] )
Replaces an entry (rule) in a network ACL.
ReplaceRoute ( array $params = [] )
Replaces an existing route within a route table in a VPC.
ReplaceRouteTableAssociation ( array $params = [] )
Changes the route table associated with a given subnet in a VPC.
ReportInstanceStatus ( array $params = [] )
Submits feedback about the status of an instance.
RequestSpotFleet ( array $params = [] )
Creates a Spot fleet request.
RequestSpotInstances ( array $params = [] )
Creates a Spot instance request.
ResetImageAttribute ( array $params = [] )
Resets an attribute of an AMI to its default value.
ResetInstanceAttribute ( array $params = [] )
Resets an attribute of an instance to its default value.
ResetNetworkInterfaceAttribute ( array $params = [] )
Resets a network interface attribute.
ResetSnapshotAttribute ( array $params = [] )
Resets permission settings for the specified snapshot.
RestoreAddressToClassic ( array $params = [] )
Restores an Elastic IP address that was previously moved to the EC2-VPC platform back to the EC2-Classic platform.
RevokeSecurityGroupEgress ( array $params = [] )
[EC2-VPC only] Removes one or more egress rules from a security group for EC2-VPC.
RevokeSecurityGroupIngress ( array $params = [] )
Removes one or more ingress rules from a security group.
RunInstances ( array $params = [] )
Launches the specified number of instances using an AMI for which you have permissions.
RunScheduledInstances ( array $params = [] )
Launches the specified Scheduled Instances.
StartInstances ( array $params = [] )
Starts an Amazon EBS-backed AMI that you've previously stopped.
StopInstances ( array $params = [] )
Stops an Amazon EBS-backed instance.
TerminateInstances ( array $params = [] )
Shuts down one or more instances.
UnassignPrivateIpAddresses ( array $params = [] )
Unassigns one or more secondary private IP addresses from a network interface.
UnmonitorInstances ( array $params = [] )
Disables monitoring for a running instance.

Paginators

Paginators handle automatically iterating over paginated API results. Paginators are associated with specific API operations, and they accept the parameters that the corresponding API operation accepts. You can get a paginator from a client class using getPaginator($paginatorName, $operationParameters). This client supports the following paginators:

DescribeAccountAttributes
DescribeAddresses
DescribeAvailabilityZones
DescribeBundleTasks
DescribeConversionTasks
DescribeCustomerGateways
DescribeDhcpOptions
DescribeExportTasks
DescribeImages
DescribeInstanceStatus
DescribeInstances
DescribeInternetGateways
DescribeKeyPairs
DescribeNetworkAcls
DescribeNetworkInterfaces
DescribePlacementGroups
DescribeRegions
DescribeReservedInstances
DescribeReservedInstancesListings
DescribeReservedInstancesOfferings
DescribeReservedInstancesModifications
DescribeRouteTables
DescribeSecurityGroups
DescribeSnapshots
DescribeSpotInstanceRequests
DescribeSpotFleetRequests
DescribeSpotPriceHistory
DescribeSubnets
DescribeTags
DescribeVolumeStatus
DescribeVolumes
DescribeVpcs
DescribeVpcPeeringConnections
DescribeVpnConnections
DescribeVpnGateways

Waiters

Waiters allow you to poll a resource until it enters into a desired state. A waiter has a name used to describe what it does, and is associated with an API operation. When creating a waiter, you can provide the API operation parameters associated with the corresponding operation. Waiters can be accessed using the getWaiter($waiterName, $operationParameters) method of a client object. This client supports the following waiters:

Waiter name API Operation Delay Max Attempts
InstanceExists DescribeInstances 5 40
BundleTaskComplete DescribeBundleTasks 15 40
ConversionTaskCancelled DescribeConversionTasks 15 40
ConversionTaskCompleted DescribeConversionTasks 15 40
ConversionTaskDeleted DescribeConversionTasks 15 40
CustomerGatewayAvailable DescribeCustomerGateways 15 40
ExportTaskCancelled DescribeExportTasks 15 40
ExportTaskCompleted DescribeExportTasks 15 40
ImageExists DescribeImages 15 40
ImageAvailable DescribeImages 15 40
InstanceRunning DescribeInstances 15 40
InstanceStatusOk DescribeInstanceStatus 15 40
InstanceStopped DescribeInstances 15 40
InstanceTerminated DescribeInstances 15 40
KeyPairExists DescribeKeyPairs 5 6
NatGatewayAvailable DescribeNatGateways 15 40
NetworkInterfaceAvailable DescribeNetworkInterfaces 20 10
PasswordDataAvailable GetPasswordData 15 40
SnapshotCompleted DescribeSnapshots 15 40
SpotInstanceRequestFulfilled DescribeSpotInstanceRequests 15 40
SubnetAvailable DescribeSubnets 15 40
SystemStatusOk DescribeInstanceStatus 15 40
VolumeAvailable DescribeVolumes 15 40
VolumeDeleted DescribeVolumes 15 40
VolumeInUse DescribeVolumes 15 40
VpcAvailable DescribeVpcs 15 40
VpcExists DescribeVpcs 1 5
VpnConnectionAvailable DescribeVpnConnections 15 40
VpnConnectionDeleted DescribeVpnConnections 15 40
VpcPeeringConnectionExists DescribeVpcPeeringConnections 15 40

Operations

AcceptVpcPeeringConnection

$result = $client->acceptVpcPeeringConnection([/* ... */]);
$promise = $client->acceptVpcPeeringConnectionAsync([/* ... */]);

Accept a VPC peering connection request. To accept a request, the VPC peering connection must be in the pending-acceptance state, and you must be the owner of the peer VPC. Use the DescribeVpcPeeringConnections request to view your outstanding VPC peering connection requests.

Parameter Syntax

$result = $client->acceptVpcPeeringConnection([
    'DryRun' => true || false,
    'VpcPeeringConnectionId' => '<string>',
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VpcPeeringConnectionId
Type: string

The ID of the VPC peering connection.

Result Syntax

[
    'VpcPeeringConnection' => [
        'AccepterVpcInfo' => [
            'CidrBlock' => '<string>',
            'OwnerId' => '<string>',
            'PeeringOptions' => [
                'AllowEgressFromLocalClassicLinkToRemoteVpc' => true || false,
                'AllowEgressFromLocalVpcToRemoteClassicLink' => true || false,
            ],
            'VpcId' => '<string>',
        ],
        'ExpirationTime' => <DateTime>,
        'RequesterVpcInfo' => [
            'CidrBlock' => '<string>',
            'OwnerId' => '<string>',
            'PeeringOptions' => [
                'AllowEgressFromLocalClassicLinkToRemoteVpc' => true || false,
                'AllowEgressFromLocalVpcToRemoteClassicLink' => true || false,
            ],
            'VpcId' => '<string>',
        ],
        'Status' => [
            'Code' => 'initiating-request|pending-acceptance|active|deleted|rejected|failed|expired|provisioning|deleting',
            'Message' => '<string>',
        ],
        'Tags' => [
            [
                'Key' => '<string>',
                'Value' => '<string>',
            ],
            // ...
        ],
        'VpcPeeringConnectionId' => '<string>',
    ],
]

Result Details

Members
VpcPeeringConnection
Type: VpcPeeringConnection structure

Information about the VPC peering connection.

Errors

There are no errors described for this operation.

AllocateAddress

$result = $client->allocateAddress([/* ... */]);
$promise = $client->allocateAddressAsync([/* ... */]);

Acquires an Elastic IP address.

An Elastic IP address is for use either in the EC2-Classic platform or in a VPC. For more information, see Elastic IP Addresses in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->allocateAddress([
    'Domain' => 'vpc|standard',
    'DryRun' => true || false,
]);

Parameter Details

Members
Domain
Type: string

Set to vpc to allocate the address for use with instances in a VPC.

Default: The address is for use with instances in EC2-Classic.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Result Syntax

[
    'AllocationId' => '<string>',
    'Domain' => 'vpc|standard',
    'PublicIp' => '<string>',
]

Result Details

Members
AllocationId
Type: string

[EC2-VPC] The ID that AWS assigns to represent the allocation of the Elastic IP address for use with instances in a VPC.

Domain
Type: string

Indicates whether this Elastic IP address is for use with instances in EC2-Classic (standard) or instances in a VPC (vpc).

PublicIp
Type: string

The Elastic IP address.

Errors

There are no errors described for this operation.

AllocateHosts

$result = $client->allocateHosts([/* ... */]);
$promise = $client->allocateHostsAsync([/* ... */]);

Allocates a Dedicated host to your account. At minimum you need to specify the instance size type, Availability Zone, and quantity of hosts you want to allocate.

Parameter Syntax

$result = $client->allocateHosts([
    'AutoPlacement' => 'on|off',
    'AvailabilityZone' => '<string>', // REQUIRED
    'ClientToken' => '<string>',
    'InstanceType' => '<string>', // REQUIRED
    'Quantity' => <integer>, // REQUIRED
]);

Parameter Details

Members
AutoPlacement
Type: string

This is enabled by default. This property allows instances to be automatically placed onto available Dedicated hosts, when you are launching instances without specifying a host ID.

Default: Enabled

AvailabilityZone
Required: Yes
Type: string

The Availability Zone for the Dedicated hosts.

ClientToken
Type: string

Unique, case-sensitive identifier you provide to ensure idempotency of the request. For more information, see How to Ensure Idempotency in the Amazon Elastic Compute Cloud User Guide.

InstanceType
Required: Yes
Type: string

Specify the instance type that you want your Dedicated hosts to be configured for. When you specify the instance type, that is the only instance type that you can launch onto that host.

Quantity
Required: Yes
Type: int

The number of Dedicated hosts you want to allocate to your account with these parameters.

Result Syntax

[
    'HostIds' => ['<string>', ...],
]

Result Details

Members
HostIds
Type: Array of strings

The ID of the allocated Dedicated host. This is used when you want to launch an instance onto a specific host.

Errors

There are no errors described for this operation.

AssignPrivateIpAddresses

$result = $client->assignPrivateIpAddresses([/* ... */]);
$promise = $client->assignPrivateIpAddressesAsync([/* ... */]);

Assigns one or more secondary private IP addresses to the specified network interface. You can specify one or more specific secondary IP addresses, or you can specify the number of secondary IP addresses to be automatically assigned within the subnet's CIDR block range. The number of secondary IP addresses that you can assign to an instance varies by instance type. For information about instance types, see Instance Types in the Amazon Elastic Compute Cloud User Guide. For more information about Elastic IP addresses, see Elastic IP Addresses in the Amazon Elastic Compute Cloud User Guide.

AssignPrivateIpAddresses is available only in EC2-VPC.

Parameter Syntax

$result = $client->assignPrivateIpAddresses([
    'AllowReassignment' => true || false,
    'NetworkInterfaceId' => '<string>', // REQUIRED
    'PrivateIpAddresses' => ['<string>', ...],
    'SecondaryPrivateIpAddressCount' => <integer>,
]);

Parameter Details

Members
AllowReassignment
Type: boolean

Indicates whether to allow an IP address that is already assigned to another network interface or instance to be reassigned to the specified network interface.

NetworkInterfaceId
Required: Yes
Type: string

The ID of the network interface.

PrivateIpAddresses
Type: Array of strings

One or more IP addresses to be assigned as a secondary private IP address to the network interface. You can't specify this parameter when also specifying a number of secondary IP addresses.

If you don't specify an IP address, Amazon EC2 automatically selects an IP address within the subnet range.

SecondaryPrivateIpAddressCount
Type: int

The number of secondary IP addresses to assign to the network interface. You can't specify this parameter when also specifying private IP addresses.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

AssociateAddress

$result = $client->associateAddress([/* ... */]);
$promise = $client->associateAddressAsync([/* ... */]);

Associates an Elastic IP address with an instance or a network interface.

An Elastic IP address is for use in either the EC2-Classic platform or in a VPC. For more information, see Elastic IP Addresses in the Amazon Elastic Compute Cloud User Guide.

[EC2-Classic, VPC in an EC2-VPC-only account] If the Elastic IP address is already associated with a different instance, it is disassociated from that instance and associated with the specified instance.

[VPC in an EC2-Classic account] If you don't specify a private IP address, the Elastic IP address is associated with the primary IP address. If the Elastic IP address is already associated with a different instance or a network interface, you get an error unless you allow reassociation.

This is an idempotent operation. If you perform the operation more than once, Amazon EC2 doesn't return an error.

Parameter Syntax

$result = $client->associateAddress([
    'AllocationId' => '<string>',
    'AllowReassociation' => true || false,
    'DryRun' => true || false,
    'InstanceId' => '<string>',
    'NetworkInterfaceId' => '<string>',
    'PrivateIpAddress' => '<string>',
    'PublicIp' => '<string>',
]);

Parameter Details

Members
AllocationId
Type: string

[EC2-VPC] The allocation ID. This is required for EC2-VPC.

AllowReassociation
Type: boolean

[EC2-VPC] For a VPC in an EC2-Classic account, specify true to allow an Elastic IP address that is already associated with an instance or network interface to be reassociated with the specified instance or network interface. Otherwise, the operation fails. In a VPC in an EC2-VPC-only account, reassociation is automatic, therefore you can specify false to ensure the operation fails if the Elastic IP address is already associated with another resource.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

InstanceId
Type: string

The ID of the instance. This is required for EC2-Classic. For EC2-VPC, you can specify either the instance ID or the network interface ID, but not both. The operation fails if you specify an instance ID unless exactly one network interface is attached.

NetworkInterfaceId
Type: string

[EC2-VPC] The ID of the network interface. If the instance has more than one network interface, you must specify a network interface ID.

PrivateIpAddress
Type: string

[EC2-VPC] The primary or secondary private IP address to associate with the Elastic IP address. If no private IP address is specified, the Elastic IP address is associated with the primary private IP address.

PublicIp
Type: string

The Elastic IP address. This is required for EC2-Classic.

Result Syntax

[
    'AssociationId' => '<string>',
]

Result Details

Members
AssociationId
Type: string

[EC2-VPC] The ID that represents the association of the Elastic IP address with an instance.

Errors

There are no errors described for this operation.

AssociateDhcpOptions

$result = $client->associateDhcpOptions([/* ... */]);
$promise = $client->associateDhcpOptionsAsync([/* ... */]);

Associates a set of DHCP options (that you've previously created) with the specified VPC, or associates no DHCP options with the VPC.

After you associate the options with the VPC, any existing instances and all new instances that you launch in that VPC use the options. You don't need to restart or relaunch the instances. They automatically pick up the changes within a few hours, depending on how frequently the instance renews its DHCP lease. You can explicitly renew the lease using the operating system on the instance.

For more information, see DHCP Options Sets in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->associateDhcpOptions([
    'DhcpOptionsId' => '<string>', // REQUIRED
    'DryRun' => true || false,
    'VpcId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DhcpOptionsId
Required: Yes
Type: string

The ID of the DHCP options set, or default to associate no DHCP options with the VPC.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VpcId
Required: Yes
Type: string

The ID of the VPC.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

AssociateRouteTable

$result = $client->associateRouteTable([/* ... */]);
$promise = $client->associateRouteTableAsync([/* ... */]);

Associates a subnet with a route table. The subnet and route table must be in the same VPC. This association causes traffic originating from the subnet to be routed according to the routes in the route table. The action returns an association ID, which you need in order to disassociate the route table from the subnet later. A route table can be associated with multiple subnets.

For more information about route tables, see Route Tables in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->associateRouteTable([
    'DryRun' => true || false,
    'RouteTableId' => '<string>', // REQUIRED
    'SubnetId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

RouteTableId
Required: Yes
Type: string

The ID of the route table.

SubnetId
Required: Yes
Type: string

The ID of the subnet.

Result Syntax

[
    'AssociationId' => '<string>',
]

Result Details

Members
AssociationId
Type: string

The route table association ID (needed to disassociate the route table).

Errors

There are no errors described for this operation.

AttachClassicLinkVpc

$result = $client->attachClassicLinkVpc([/* ... */]);
$promise = $client->attachClassicLinkVpcAsync([/* ... */]);

Links an EC2-Classic instance to a ClassicLink-enabled VPC through one or more of the VPC's security groups. You cannot link an EC2-Classic instance to more than one VPC at a time. You can only link an instance that's in the running state. An instance is automatically unlinked from a VPC when it's stopped - you can link it to the VPC again when you restart it.

After you've linked an instance, you cannot change the VPC security groups that are associated with it. To change the security groups, you must first unlink the instance, and then link it again.

Linking your instance to a VPC is sometimes referred to as attaching your instance.

Parameter Syntax

$result = $client->attachClassicLinkVpc([
    'DryRun' => true || false,
    'Groups' => ['<string>', ...], // REQUIRED
    'InstanceId' => '<string>', // REQUIRED
    'VpcId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Groups
Required: Yes
Type: Array of strings

The ID of one or more of the VPC's security groups. You cannot specify security groups from a different VPC.

InstanceId
Required: Yes
Type: string

The ID of an EC2-Classic instance to link to the ClassicLink-enabled VPC.

VpcId
Required: Yes
Type: string

The ID of a ClassicLink-enabled VPC.

Result Syntax

[
    'Return' => true || false,
]

Result Details

Members
Return
Type: boolean

Returns true if the request succeeds; otherwise, it returns an error.

Errors

There are no errors described for this operation.

AttachInternetGateway

$result = $client->attachInternetGateway([/* ... */]);
$promise = $client->attachInternetGatewayAsync([/* ... */]);

Attaches an Internet gateway to a VPC, enabling connectivity between the Internet and the VPC. For more information about your VPC and Internet gateway, see the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->attachInternetGateway([
    'DryRun' => true || false,
    'InternetGatewayId' => '<string>', // REQUIRED
    'VpcId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

InternetGatewayId
Required: Yes
Type: string

The ID of the Internet gateway.

VpcId
Required: Yes
Type: string

The ID of the VPC.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

AttachNetworkInterface

$result = $client->attachNetworkInterface([/* ... */]);
$promise = $client->attachNetworkInterfaceAsync([/* ... */]);

Attaches a network interface to an instance.

Parameter Syntax

$result = $client->attachNetworkInterface([
    'DeviceIndex' => <integer>, // REQUIRED
    'DryRun' => true || false,
    'InstanceId' => '<string>', // REQUIRED
    'NetworkInterfaceId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DeviceIndex
Required: Yes
Type: int

The index of the device for the network interface attachment.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

InstanceId
Required: Yes
Type: string

The ID of the instance.

NetworkInterfaceId
Required: Yes
Type: string

The ID of the network interface.

Result Syntax

[
    'AttachmentId' => '<string>',
]

Result Details

Members
AttachmentId
Type: string

The ID of the network interface attachment.

Errors

There are no errors described for this operation.

AttachVolume

$result = $client->attachVolume([/* ... */]);
$promise = $client->attachVolumeAsync([/* ... */]);

Attaches an EBS volume to a running or stopped instance and exposes it to the instance with the specified device name.

Encrypted EBS volumes may only be attached to instances that support Amazon EBS encryption. For more information, see Amazon EBS Encryption in the Amazon Elastic Compute Cloud User Guide.

For a list of supported device names, see Attaching an EBS Volume to an Instance. Any device names that aren't reserved for instance store volumes can be used for EBS volumes. For more information, see Amazon EC2 Instance Store in the Amazon Elastic Compute Cloud User Guide.

If a volume has an AWS Marketplace product code:

  • The volume can be attached only to a stopped instance.

  • AWS Marketplace product codes are copied from the volume to the instance.

  • You must be subscribed to the product.

  • The instance type and operating system of the instance must support the product. For example, you can't detach a volume from a Windows instance and attach it to a Linux instance.

For an overview of the AWS Marketplace, see Introducing AWS Marketplace.

For more information about EBS volumes, see Attaching Amazon EBS Volumes in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->attachVolume([
    'Device' => '<string>', // REQUIRED
    'DryRun' => true || false,
    'InstanceId' => '<string>', // REQUIRED
    'VolumeId' => '<string>', // REQUIRED
]);

Parameter Details

Members
Device
Required: Yes
Type: string

The device name to expose to the instance (for example, /dev/sdh or xvdh).

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

InstanceId
Required: Yes
Type: string

The ID of the instance.

VolumeId
Required: Yes
Type: string

The ID of the EBS volume. The volume and instance must be within the same Availability Zone.

Result Syntax

[
    'AttachTime' => <DateTime>,
    'DeleteOnTermination' => true || false,
    'Device' => '<string>',
    'InstanceId' => '<string>',
    'State' => 'attaching|attached|detaching|detached',
    'VolumeId' => '<string>',
]

Result Details

Members
AttachTime
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time stamp when the attachment initiated.

DeleteOnTermination
Type: boolean

Indicates whether the EBS volume is deleted on instance termination.

Device
Type: string

The device name.

InstanceId
Type: string

The ID of the instance.

State
Type: string

The attachment state of the volume.

VolumeId
Type: string

The ID of the volume.

Errors

There are no errors described for this operation.

AttachVpnGateway

$result = $client->attachVpnGateway([/* ... */]);
$promise = $client->attachVpnGatewayAsync([/* ... */]);

Attaches a virtual private gateway to a VPC. For more information, see Adding a Hardware Virtual Private Gateway to Your VPC in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->attachVpnGateway([
    'DryRun' => true || false,
    'VpcId' => '<string>', // REQUIRED
    'VpnGatewayId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VpcId
Required: Yes
Type: string

The ID of the VPC.

VpnGatewayId
Required: Yes
Type: string

The ID of the virtual private gateway.

Result Syntax

[
    'VpcAttachment' => [
        'State' => 'attaching|attached|detaching|detached',
        'VpcId' => '<string>',
    ],
]

Result Details

Members
VpcAttachment
Type: VpcAttachment structure

Information about the attachment.

Errors

There are no errors described for this operation.

AuthorizeSecurityGroupEgress

$result = $client->authorizeSecurityGroupEgress([/* ... */]);
$promise = $client->authorizeSecurityGroupEgressAsync([/* ... */]);

[EC2-VPC only] Adds one or more egress rules to a security group for use with a VPC. Specifically, this action permits instances to send traffic to one or more destination CIDR IP address ranges, or to one or more destination security groups for the same VPC. This action doesn't apply to security groups for use in EC2-Classic. For more information, see Security Groups for Your VPC in the Amazon Virtual Private Cloud User Guide.

You can have up to 50 rules per security group (covering both ingress and egress rules).

Each rule consists of the protocol (for example, TCP), plus either a CIDR range or a source group. For the TCP and UDP protocols, you must also specify the destination port or port range. For the ICMP protocol, you must also specify the ICMP type and code. You can use -1 for the type or code to mean all types or all codes.

Rule changes are propagated to affected instances as quickly as possible. However, a small delay might occur.

Parameter Syntax

$result = $client->authorizeSecurityGroupEgress([
    'CidrIp' => '<string>',
    'DryRun' => true || false,
    'FromPort' => <integer>,
    'GroupId' => '<string>', // REQUIRED
    'IpPermissions' => [
        [
            'FromPort' => <integer>,
            'IpProtocol' => '<string>',
            'IpRanges' => [
                [
                    'CidrIp' => '<string>',
                ],
                // ...
            ],
            'PrefixListIds' => [
                [
                    'PrefixListId' => '<string>',
                ],
                // ...
            ],
            'ToPort' => <integer>,
            'UserIdGroupPairs' => [
                [
                    'GroupId' => '<string>',
                    'GroupName' => '<string>',
                    'PeeringStatus' => '<string>',
                    'UserId' => '<string>',
                    'VpcId' => '<string>',
                    'VpcPeeringConnectionId' => '<string>',
                ],
                // ...
            ],
        ],
        // ...
    ],
    'IpProtocol' => '<string>',
    'SourceSecurityGroupName' => '<string>',
    'SourceSecurityGroupOwnerId' => '<string>',
    'ToPort' => <integer>,
]);

Parameter Details

Members
CidrIp
Type: string

The CIDR IP address range. We recommend that you specify the CIDR range in a set of IP permissions instead.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

FromPort
Type: int

The start of port range for the TCP and UDP protocols, or an ICMP type number. We recommend that you specify the port range in a set of IP permissions instead.

GroupId
Required: Yes
Type: string

The ID of the security group.

IpPermissions
Type: Array of IpPermission structures

A set of IP permissions. You can't specify a destination security group and a CIDR IP address range.

IpProtocol
Type: string

The IP protocol name or number. We recommend that you specify the protocol in a set of IP permissions instead.

SourceSecurityGroupName
Type: string

The name of a destination security group. To authorize outbound access to a destination security group, we recommend that you use a set of IP permissions instead.

SourceSecurityGroupOwnerId
Type: string

The AWS account number for a destination security group. To authorize outbound access to a destination security group, we recommend that you use a set of IP permissions instead.

ToPort
Type: int

The end of port range for the TCP and UDP protocols, or an ICMP type number. We recommend that you specify the port range in a set of IP permissions instead.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

AuthorizeSecurityGroupIngress

$result = $client->authorizeSecurityGroupIngress([/* ... */]);
$promise = $client->authorizeSecurityGroupIngressAsync([/* ... */]);

Adds one or more ingress rules to a security group.

EC2-Classic: You can have up to 100 rules per group.

EC2-VPC: You can have up to 50 rules per group (covering both ingress and egress rules).

Rule changes are propagated to instances within the security group as quickly as possible. However, a small delay might occur.

[EC2-Classic] This action gives one or more CIDR IP address ranges permission to access a security group in your account, or gives one or more security groups (called the source groups) permission to access a security group for your account. A source group can be for your own AWS account, or another.

[EC2-VPC] This action gives one or more CIDR IP address ranges permission to access a security group in your VPC, or gives one or more other security groups (called the source groups) permission to access a security group for your VPC. The security groups must all be for the same VPC.

Parameter Syntax

$result = $client->authorizeSecurityGroupIngress([
    'CidrIp' => '<string>',
    'DryRun' => true || false,
    'FromPort' => <integer>,
    'GroupId' => '<string>',
    'GroupName' => '<string>',
    'IpPermissions' => [
        [
            'FromPort' => <integer>,
            'IpProtocol' => '<string>',
            'IpRanges' => [
                [
                    'CidrIp' => '<string>',
                ],
                // ...
            ],
            'PrefixListIds' => [
                [
                    'PrefixListId' => '<string>',
                ],
                // ...
            ],
            'ToPort' => <integer>,
            'UserIdGroupPairs' => [
                [
                    'GroupId' => '<string>',
                    'GroupName' => '<string>',
                    'PeeringStatus' => '<string>',
                    'UserId' => '<string>',
                    'VpcId' => '<string>',
                    'VpcPeeringConnectionId' => '<string>',
                ],
                // ...
            ],
        ],
        // ...
    ],
    'IpProtocol' => '<string>',
    'SourceSecurityGroupName' => '<string>',
    'SourceSecurityGroupOwnerId' => '<string>',
    'ToPort' => <integer>,
]);

Parameter Details

Members
CidrIp
Type: string

The CIDR IP address range. You can't specify this parameter when specifying a source security group.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

FromPort
Type: int

The start of port range for the TCP and UDP protocols, or an ICMP type number. For the ICMP type number, use -1 to specify all ICMP types.

GroupId
Type: string

The ID of the security group. Required for a nondefault VPC.

GroupName
Type: string

[EC2-Classic, default VPC] The name of the security group.

IpPermissions
Type: Array of IpPermission structures

A set of IP permissions. Can be used to specify multiple rules in a single command.

IpProtocol
Type: string

The IP protocol name (tcp, udp, icmp) or number (see Protocol Numbers). (VPC only) Use -1 to specify all.

SourceSecurityGroupName
Type: string

[EC2-Classic, default VPC] The name of the source security group. You can't specify this parameter in combination with the following parameters: the CIDR IP address range, the start of the port range, the IP protocol, and the end of the port range. Creates rules that grant full ICMP, UDP, and TCP access. To create a rule with a specific IP protocol and port range, use a set of IP permissions instead. For EC2-VPC, the source security group must be in the same VPC.

SourceSecurityGroupOwnerId
Type: string

[EC2-Classic] The AWS account number for the source security group, if the source security group is in a different account. You can't specify this parameter in combination with the following parameters: the CIDR IP address range, the IP protocol, the start of the port range, and the end of the port range. Creates rules that grant full ICMP, UDP, and TCP access. To create a rule with a specific IP protocol and port range, use a set of IP permissions instead.

ToPort
Type: int

The end of port range for the TCP and UDP protocols, or an ICMP code number. For the ICMP code number, use -1 to specify all ICMP codes for the ICMP type.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

BundleInstance

$result = $client->bundleInstance([/* ... */]);
$promise = $client->bundleInstanceAsync([/* ... */]);

Bundles an Amazon instance store-backed Windows instance.

During bundling, only the root device volume (C:\) is bundled. Data on other instance store volumes is not preserved.

This action is not applicable for Linux/Unix instances or Windows instances that are backed by Amazon EBS.

For more information, see Creating an Instance Store-Backed Windows AMI.

Parameter Syntax

$result = $client->bundleInstance([
    'DryRun' => true || false,
    'InstanceId' => '<string>', // REQUIRED
    'Storage' => [ // REQUIRED
        'S3' => [
            'AWSAccessKeyId' => '<string>',
            'Bucket' => '<string>',
            'Prefix' => '<string>',
            'UploadPolicy' => <string || resource || Psr\Http\Message\StreamInterface>,
            'UploadPolicySignature' => '<string>',
        ],
    ],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

InstanceId
Required: Yes
Type: string

The ID of the instance to bundle.

Type: String

Default: None

Required: Yes

Storage
Required: Yes
Type: Storage structure

The bucket in which to store the AMI. You can specify a bucket that you already own or a new bucket that Amazon EC2 creates on your behalf. If you specify a bucket that belongs to someone else, Amazon EC2 returns an error.

Result Syntax

[
    'BundleTask' => [
        'BundleId' => '<string>',
        'BundleTaskError' => [
            'Code' => '<string>',
            'Message' => '<string>',
        ],
        'InstanceId' => '<string>',
        'Progress' => '<string>',
        'StartTime' => <DateTime>,
        'State' => 'pending|waiting-for-shutdown|bundling|storing|cancelling|complete|failed',
        'Storage' => [
            'S3' => [
                'AWSAccessKeyId' => '<string>',
                'Bucket' => '<string>',
                'Prefix' => '<string>',
                'UploadPolicy' => <string || resource || Psr\Http\Message\StreamInterface>,
                'UploadPolicySignature' => '<string>',
            ],
        ],
        'UpdateTime' => <DateTime>,
    ],
]

Result Details

Members
BundleTask
Type: BundleTask structure

Information about the bundle task.

Errors

There are no errors described for this operation.

CancelBundleTask

$result = $client->cancelBundleTask([/* ... */]);
$promise = $client->cancelBundleTaskAsync([/* ... */]);

Cancels a bundling operation for an instance store-backed Windows instance.

Parameter Syntax

$result = $client->cancelBundleTask([
    'BundleId' => '<string>', // REQUIRED
    'DryRun' => true || false,
]);

Parameter Details

Members
BundleId
Required: Yes
Type: string

The ID of the bundle task.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Result Syntax

[
    'BundleTask' => [
        'BundleId' => '<string>',
        'BundleTaskError' => [
            'Code' => '<string>',
            'Message' => '<string>',
        ],
        'InstanceId' => '<string>',
        'Progress' => '<string>',
        'StartTime' => <DateTime>,
        'State' => 'pending|waiting-for-shutdown|bundling|storing|cancelling|complete|failed',
        'Storage' => [
            'S3' => [
                'AWSAccessKeyId' => '<string>',
                'Bucket' => '<string>',
                'Prefix' => '<string>',
                'UploadPolicy' => <string || resource || Psr\Http\Message\StreamInterface>,
                'UploadPolicySignature' => '<string>',
            ],
        ],
        'UpdateTime' => <DateTime>,
    ],
]

Result Details

Members
BundleTask
Type: BundleTask structure

Information about the bundle task.

Errors

There are no errors described for this operation.

CancelConversionTask

$result = $client->cancelConversionTask([/* ... */]);
$promise = $client->cancelConversionTaskAsync([/* ... */]);

Cancels an active conversion task. The task can be the import of an instance or volume. The action removes all artifacts of the conversion, including a partially uploaded volume or instance. If the conversion is complete or is in the process of transferring the final disk image, the command fails and returns an exception.

For more information, see Using the Command Line Tools to Import Your Virtual Machine to Amazon EC2 in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->cancelConversionTask([
    'ConversionTaskId' => '<string>', // REQUIRED
    'DryRun' => true || false,
    'ReasonMessage' => '<string>',
]);

Parameter Details

Members
ConversionTaskId
Required: Yes
Type: string

The ID of the conversion task.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

ReasonMessage
Type: string

The reason for canceling the conversion task.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

CancelExportTask

$result = $client->cancelExportTask([/* ... */]);
$promise = $client->cancelExportTaskAsync([/* ... */]);

Cancels an active export task. The request removes all artifacts of the export, including any partially-created Amazon S3 objects. If the export task is complete or is in the process of transferring the final disk image, the command fails and returns an error.

Parameter Syntax

$result = $client->cancelExportTask([
    'ExportTaskId' => '<string>', // REQUIRED
]);

Parameter Details

Members
ExportTaskId
Required: Yes
Type: string

The ID of the export task. This is the ID returned by CreateInstanceExportTask.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

CancelImportTask

$result = $client->cancelImportTask([/* ... */]);
$promise = $client->cancelImportTaskAsync([/* ... */]);

Cancels an in-process import virtual machine or import snapshot task.

Parameter Syntax

$result = $client->cancelImportTask([
    'CancelReason' => '<string>',
    'DryRun' => true || false,
    'ImportTaskId' => '<string>',
]);

Parameter Details

Members
CancelReason
Type: string

The reason for canceling the task.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

ImportTaskId
Type: string

The ID of the import image or import snapshot task to be canceled.

Result Syntax

[
    'ImportTaskId' => '<string>',
    'PreviousState' => '<string>',
    'State' => '<string>',
]

Result Details

Members
ImportTaskId
Type: string

The ID of the task being canceled.

PreviousState
Type: string

The current state of the task being canceled.

State
Type: string

The current state of the task being canceled.

Errors

There are no errors described for this operation.

CancelReservedInstancesListing

$result = $client->cancelReservedInstancesListing([/* ... */]);
$promise = $client->cancelReservedInstancesListingAsync([/* ... */]);

Cancels the specified Reserved Instance listing in the Reserved Instance Marketplace.

For more information, see Reserved Instance Marketplace in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->cancelReservedInstancesListing([
    'ReservedInstancesListingId' => '<string>', // REQUIRED
]);

Parameter Details

Members
ReservedInstancesListingId
Required: Yes
Type: string

The ID of the Reserved Instance listing.

Result Syntax

[
    'ReservedInstancesListings' => [
        [
            'ClientToken' => '<string>',
            'CreateDate' => <DateTime>,
            'InstanceCounts' => [
                [
                    'InstanceCount' => <integer>,
                    'State' => 'available|sold|cancelled|pending',
                ],
                // ...
            ],
            'PriceSchedules' => [
                [
                    'Active' => true || false,
                    'CurrencyCode' => 'USD',
                    'Price' => <float>,
                    'Term' => <integer>,
                ],
                // ...
            ],
            'ReservedInstancesId' => '<string>',
            'ReservedInstancesListingId' => '<string>',
            'Status' => 'active|pending|cancelled|closed',
            'StatusMessage' => '<string>',
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'UpdateDate' => <DateTime>,
        ],
        // ...
    ],
]

Result Details

Members
ReservedInstancesListings
Type: Array of ReservedInstancesListing structures

The Reserved Instance listing.

Errors

There are no errors described for this operation.

CancelSpotFleetRequests

$result = $client->cancelSpotFleetRequests([/* ... */]);
$promise = $client->cancelSpotFleetRequestsAsync([/* ... */]);

Cancels the specified Spot fleet requests.

After you cancel a Spot fleet request, the Spot fleet launches no new Spot instances. You must specify whether the Spot fleet should also terminate its Spot instances. If you terminate the instances, the Spot fleet request enters the cancelled_terminating state. Otherwise, the Spot fleet request enters the cancelled_running state and the instances continue to run until they are interrupted or you terminate them manually.

Parameter Syntax

$result = $client->cancelSpotFleetRequests([
    'DryRun' => true || false,
    'SpotFleetRequestIds' => ['<string>', ...], // REQUIRED
    'TerminateInstances' => true || false, // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

SpotFleetRequestIds
Required: Yes
Type: Array of strings

The IDs of the Spot fleet requests.

TerminateInstances
Required: Yes
Type: boolean

Indicates whether to terminate instances for a Spot fleet request if it is canceled successfully.

Result Syntax

[
    'SuccessfulFleetRequests' => [
        [
            'CurrentSpotFleetRequestState' => 'submitted|active|cancelled|failed|cancelled_running|cancelled_terminating|modifying',
            'PreviousSpotFleetRequestState' => 'submitted|active|cancelled|failed|cancelled_running|cancelled_terminating|modifying',
            'SpotFleetRequestId' => '<string>',
        ],
        // ...
    ],
    'UnsuccessfulFleetRequests' => [
        [
            'Error' => [
                'Code' => 'fleetRequestIdDoesNotExist|fleetRequestIdMalformed|fleetRequestNotInCancellableState|unexpectedError',
                'Message' => '<string>',
            ],
            'SpotFleetRequestId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
SuccessfulFleetRequests
Type: Array of CancelSpotFleetRequestsSuccessItem structures

Information about the Spot fleet requests that are successfully canceled.

UnsuccessfulFleetRequests
Type: Array of CancelSpotFleetRequestsErrorItem structures

Information about the Spot fleet requests that are not successfully canceled.

Errors

There are no errors described for this operation.

CancelSpotInstanceRequests

$result = $client->cancelSpotInstanceRequests([/* ... */]);
$promise = $client->cancelSpotInstanceRequestsAsync([/* ... */]);

Cancels one or more Spot instance requests. Spot instances are instances that Amazon EC2 starts on your behalf when the bid price that you specify exceeds the current Spot price. Amazon EC2 periodically sets the Spot price based on available Spot instance capacity and current Spot instance requests. For more information, see Spot Instance Requests in the Amazon Elastic Compute Cloud User Guide.

Canceling a Spot instance request does not terminate running Spot instances associated with the request.

Parameter Syntax

$result = $client->cancelSpotInstanceRequests([
    'DryRun' => true || false,
    'SpotInstanceRequestIds' => ['<string>', ...], // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

SpotInstanceRequestIds
Required: Yes
Type: Array of strings

One or more Spot instance request IDs.

Result Syntax

[
    'CancelledSpotInstanceRequests' => [
        [
            'SpotInstanceRequestId' => '<string>',
            'State' => 'active|open|closed|cancelled|completed',
        ],
        // ...
    ],
]

Result Details

Members
CancelledSpotInstanceRequests
Type: Array of CancelledSpotInstanceRequest structures

One or more Spot instance requests.

Errors

There are no errors described for this operation.

ConfirmProductInstance

$result = $client->confirmProductInstance([/* ... */]);
$promise = $client->confirmProductInstanceAsync([/* ... */]);

Determines whether a product code is associated with an instance. This action can only be used by the owner of the product code. It is useful when a product code owner needs to verify whether another user's instance is eligible for support.

Parameter Syntax

$result = $client->confirmProductInstance([
    'DryRun' => true || false,
    'InstanceId' => '<string>', // REQUIRED
    'ProductCode' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

InstanceId
Required: Yes
Type: string

The ID of the instance.

ProductCode
Required: Yes
Type: string

The product code. This must be a product code that you own.

Result Syntax

[
    'OwnerId' => '<string>',
    'Return' => true || false,
]

Result Details

Members
OwnerId
Type: string

The AWS account ID of the instance owner. This is only present if the product code is attached to the instance.

Return
Type: boolean

The return value of the request. Returns true if the specified product code is owned by the requester and associated with the specified instance.

Errors

There are no errors described for this operation.

CopyImage

$result = $client->copyImage([/* ... */]);
$promise = $client->copyImageAsync([/* ... */]);

Initiates the copy of an AMI from the specified source region to the current region. You specify the destination region by using its endpoint when making the request.

For more information, see Copying AMIs in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->copyImage([
    'ClientToken' => '<string>',
    'Description' => '<string>',
    'DryRun' => true || false,
    'Encrypted' => true || false,
    'KmsKeyId' => '<string>',
    'Name' => '<string>', // REQUIRED
    'SourceImageId' => '<string>', // REQUIRED
    'SourceRegion' => '<string>', // REQUIRED
]);

Parameter Details

Members
ClientToken
Type: string

Unique, case-sensitive identifier you provide to ensure idempotency of the request. For more information, see How to Ensure Idempotency in the Amazon Elastic Compute Cloud User Guide.

Description
Type: string

A description for the new AMI in the destination region.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Encrypted
Type: boolean

Specifies whether the destination snapshots of the copied image should be encrypted. The default CMK for EBS is used unless a non-default AWS Key Management Service (AWS KMS) CMK is specified with KmsKeyId. For more information, see Amazon EBS Encryption in the Amazon Elastic Compute Cloud User Guide.

KmsKeyId
Type: string

The full ARN of the AWS Key Management Service (AWS KMS) CMK to use when encrypting the snapshots of an image during a copy operation. This parameter is only required if you want to use a non-default CMK; if this parameter is not specified, the default CMK for EBS is used. The ARN contains the arn:aws:kms namespace, followed by the region of the CMK, the AWS account ID of the CMK owner, the key namespace, and then the CMK ID. For example, arn:aws:kms:us-east-1:012345678910:key/abcd1234-a123-456a-a12b-a123b4cd56ef. The specified CMK must exist in the region that the snapshot is being copied to. If a KmsKeyId is specified, the Encrypted flag must also be set.

Name
Required: Yes
Type: string

The name of the new AMI in the destination region.

SourceImageId
Required: Yes
Type: string

The ID of the AMI to copy.

SourceRegion
Required: Yes
Type: string

The name of the region that contains the AMI to copy.

Result Syntax

[
    'ImageId' => '<string>',
]

Result Details

Members
ImageId
Type: string

The ID of the new AMI.

Errors

There are no errors described for this operation.

CopySnapshot

$result = $client->copySnapshot([/* ... */]);
$promise = $client->copySnapshotAsync([/* ... */]);

Copies a point-in-time snapshot of an EBS volume and stores it in Amazon S3. You can copy the snapshot within the same region or from one region to another. You can use the snapshot to create EBS volumes or Amazon Machine Images (AMIs). The snapshot is copied to the regional endpoint that you send the HTTP request to.

Copies of encrypted EBS snapshots remain encrypted. Copies of unencrypted snapshots remain unencrypted, unless the Encrypted flag is specified during the snapshot copy operation. By default, encrypted snapshot copies use the default AWS Key Management Service (AWS KMS) customer master key (CMK); however, you can specify a non-default CMK with the KmsKeyId parameter.

For more information, see Copying an Amazon EBS Snapshot in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->copySnapshot([
    'Description' => '<string>',
    'DestinationRegion' => '<string>',
    'DryRun' => true || false,
    'Encrypted' => true || false,
    'KmsKeyId' => '<string>',
    'PresignedUrl' => '<string>',
    'SourceRegion' => '<string>', // REQUIRED
    'SourceSnapshotId' => '<string>', // REQUIRED
]);

Parameter Details

Members
Description
Type: string

A description for the EBS snapshot.

DestinationRegion
Type: string
The SDK will populate this parameter on your behalf using the configured region value of the client.
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Encrypted
Type: boolean

Specifies whether the destination snapshot should be encrypted. There is no way to create an unencrypted snapshot copy from an encrypted snapshot; however, you can encrypt a copy of an unencrypted snapshot with this flag. The default CMK for EBS is used unless a non-default AWS Key Management Service (AWS KMS) CMK is specified with KmsKeyId. For more information, see Amazon EBS Encryption in the Amazon Elastic Compute Cloud User Guide.

KmsKeyId
Type: string

The full ARN of the AWS Key Management Service (AWS KMS) CMK to use when creating the snapshot copy. This parameter is only required if you want to use a non-default CMK; if this parameter is not specified, the default CMK for EBS is used. The ARN contains the arn:aws:kms namespace, followed by the region of the CMK, the AWS account ID of the CMK owner, the key namespace, and then the CMK ID. For example, arn:aws:kms:us-east-1:012345678910:key/abcd1234-a123-456a-a12b-a123b4cd56ef. The specified CMK must exist in the region that the snapshot is being copied to. If a KmsKeyId is specified, the Encrypted flag must also be set.

PresignedUrl
Type: string
The SDK will compute this value for you on your behalf.
SourceRegion
Required: Yes
Type: string

The ID of the region that contains the snapshot to be copied.

SourceSnapshotId
Required: Yes
Type: string

The ID of the EBS snapshot to copy.

Result Syntax

[
    'SnapshotId' => '<string>',
]

Result Details

Members
SnapshotId
Type: string

The ID of the new snapshot.

Errors

There are no errors described for this operation.

CreateCustomerGateway

$result = $client->createCustomerGateway([/* ... */]);
$promise = $client->createCustomerGatewayAsync([/* ... */]);

Provides information to AWS about your VPN customer gateway device. The customer gateway is the appliance at your end of the VPN connection. (The device on the AWS side of the VPN connection is the virtual private gateway.) You must provide the Internet-routable IP address of the customer gateway's external interface. The IP address must be static and may be behind a device performing network address translation (NAT).

For devices that use Border Gateway Protocol (BGP), you can also provide the device's BGP Autonomous System Number (ASN). You can use an existing ASN assigned to your network. If you don't have an ASN already, you can use a private ASN (in the 64512 - 65534 range).

Amazon EC2 supports all 2-byte ASN numbers in the range of 1 - 65534, with the exception of 7224, which is reserved in the us-east-1 region, and 9059, which is reserved in the eu-west-1 region.

For more information about VPN customer gateways, see Adding a Hardware Virtual Private Gateway to Your VPC in the Amazon Virtual Private Cloud User Guide.

You cannot create more than one customer gateway with the same VPN type, IP address, and BGP ASN parameter values. If you run an identical request more than one time, the first request creates the customer gateway, and subsequent requests return information about the existing customer gateway. The subsequent requests do not create new customer gateway resources.

Parameter Syntax

$result = $client->createCustomerGateway([
    'BgpAsn' => <integer>, // REQUIRED
    'DryRun' => true || false,
    'PublicIp' => '<string>', // REQUIRED
    'Type' => 'ipsec.1', // REQUIRED
]);

Parameter Details

Members
BgpAsn
Required: Yes
Type: int

For devices that support BGP, the customer gateway's BGP ASN.

Default: 65000

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

PublicIp
Required: Yes
Type: string

The Internet-routable IP address for the customer gateway's outside interface. The address must be static.

Type
Required: Yes
Type: string

The type of VPN connection that this customer gateway supports (ipsec.1).

Result Syntax

[
    'CustomerGateway' => [
        'BgpAsn' => '<string>',
        'CustomerGatewayId' => '<string>',
        'IpAddress' => '<string>',
        'State' => '<string>',
        'Tags' => [
            [
                'Key' => '<string>',
                'Value' => '<string>',
            ],
            // ...
        ],
        'Type' => '<string>',
    ],
]

Result Details

Members
CustomerGateway
Type: CustomerGateway structure

Information about the customer gateway.

Errors

There are no errors described for this operation.

CreateDhcpOptions

$result = $client->createDhcpOptions([/* ... */]);
$promise = $client->createDhcpOptionsAsync([/* ... */]);

Creates a set of DHCP options for your VPC. After creating the set, you must associate it with the VPC, causing all existing and new instances that you launch in the VPC to use this set of DHCP options. The following are the individual DHCP options you can specify. For more information about the options, see RFC 2132.

  • domain-name-servers - The IP addresses of up to four domain name servers, or AmazonProvidedDNS. The default DHCP option set specifies AmazonProvidedDNS. If specifying more than one domain name server, specify the IP addresses in a single parameter, separated by commas.

  • domain-name - If you're using AmazonProvidedDNS in "us-east-1", specify "ec2.internal". If you're using AmazonProvidedDNS in another region, specify "region.compute.internal" (for example, "ap-northeast-1.compute.internal"). Otherwise, specify a domain name (for example, "MyCompany.com"). Important: Some Linux operating systems accept multiple domain names separated by spaces. However, Windows and other Linux operating systems treat the value as a single domain, which results in unexpected behavior. If your DHCP options set is associated with a VPC that has instances with multiple operating systems, specify only one domain name.

  • ntp-servers - The IP addresses of up to four Network Time Protocol (NTP) servers.

  • netbios-name-servers - The IP addresses of up to four NetBIOS name servers.

  • netbios-node-type - The NetBIOS node type (1, 2, 4, or 8). We recommend that you specify 2 (broadcast and multicast are not currently supported). For more information about these node types, see RFC 2132.

Your VPC automatically starts out with a set of DHCP options that includes only a DNS server that we provide (AmazonProvidedDNS). If you create a set of options, and if your VPC has an Internet gateway, make sure to set the domain-name-servers option either to AmazonProvidedDNS or to a domain name server of your choice. For more information about DHCP options, see DHCP Options Sets in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->createDhcpOptions([
    'DhcpConfigurations' => [ // REQUIRED
        [
            'Key' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'DryRun' => true || false,
]);

Parameter Details

Members
DhcpConfigurations
Required: Yes
Type: Array of NewDhcpConfiguration structures

A DHCP configuration option.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Result Syntax

[
    'DhcpOptions' => [
        'DhcpConfigurations' => [
            [
                'Key' => '<string>',
                'Values' => [
                    [
                        'Value' => '<string>',
                    ],
                    // ...
                ],
            ],
            // ...
        ],
        'DhcpOptionsId' => '<string>',
        'Tags' => [
            [
                'Key' => '<string>',
                'Value' => '<string>',
            ],
            // ...
        ],
    ],
]

Result Details

Members
DhcpOptions
Type: DhcpOptions structure

A set of DHCP options.

Errors

There are no errors described for this operation.

CreateFlowLogs

$result = $client->createFlowLogs([/* ... */]);
$promise = $client->createFlowLogsAsync([/* ... */]);

Creates one or more flow logs to capture IP traffic for a specific network interface, subnet, or VPC. Flow logs are delivered to a specified log group in Amazon CloudWatch Logs. If you specify a VPC or subnet in the request, a log stream is created in CloudWatch Logs for each network interface in the subnet or VPC. Log streams can include information about accepted and rejected traffic to a network interface. You can view the data in your log streams using Amazon CloudWatch Logs.

In your request, you must also specify an IAM role that has permission to publish logs to CloudWatch Logs.

Parameter Syntax

$result = $client->createFlowLogs([
    'ClientToken' => '<string>',
    'DeliverLogsPermissionArn' => '<string>', // REQUIRED
    'LogGroupName' => '<string>', // REQUIRED
    'ResourceIds' => ['<string>', ...], // REQUIRED
    'ResourceType' => 'VPC|Subnet|NetworkInterface', // REQUIRED
    'TrafficType' => 'ACCEPT|REJECT|ALL', // REQUIRED
]);

Parameter Details

Members
ClientToken
Type: string

Unique, case-sensitive identifier you provide to ensure the idempotency of the request. For more information, see How to Ensure Idempotency.

DeliverLogsPermissionArn
Required: Yes
Type: string

The ARN for the IAM role that's used to post flow logs to a CloudWatch Logs log group.

LogGroupName
Required: Yes
Type: string

The name of the CloudWatch log group.

ResourceIds
Required: Yes
Type: Array of strings

One or more subnet, network interface, or VPC IDs.

Constraints: Maximum of 1000 resources

ResourceType
Required: Yes
Type: string

The type of resource on which to create the flow log.

TrafficType
Required: Yes
Type: string

The type of traffic to log.

Result Syntax

[
    'ClientToken' => '<string>',
    'FlowLogIds' => ['<string>', ...],
    'Unsuccessful' => [
        [
            'Error' => [
                'Code' => '<string>',
                'Message' => '<string>',
            ],
            'ResourceId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
ClientToken
Type: string

Unique, case-sensitive identifier you provide to ensure the idempotency of the request.

FlowLogIds
Type: Array of strings

The IDs of the flow logs.

Unsuccessful
Type: Array of UnsuccessfulItem structures

Information about the flow logs that could not be created successfully.

Errors

There are no errors described for this operation.

CreateImage

$result = $client->createImage([/* ... */]);
$promise = $client->createImageAsync([/* ... */]);

Creates an Amazon EBS-backed AMI from an Amazon EBS-backed instance that is either running or stopped.

If you customized your instance with instance store volumes or EBS volumes in addition to the root device volume, the new AMI contains block device mapping information for those volumes. When you launch an instance from this new AMI, the instance automatically launches with those additional volumes.

For more information, see Creating Amazon EBS-Backed Linux AMIs in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->createImage([
    'BlockDeviceMappings' => [
        [
            'DeviceName' => '<string>',
            'Ebs' => [
                'DeleteOnTermination' => true || false,
                'Encrypted' => true || false,
                'Iops' => <integer>,
                'SnapshotId' => '<string>',
                'VolumeSize' => <integer>,
                'VolumeType' => 'standard|io1|gp2|sc1|st1',
            ],
            'NoDevice' => '<string>',
            'VirtualName' => '<string>',
        ],
        // ...
    ],
    'Description' => '<string>',
    'DryRun' => true || false,
    'InstanceId' => '<string>', // REQUIRED
    'Name' => '<string>', // REQUIRED
    'NoReboot' => true || false,
]);

Parameter Details

Members
BlockDeviceMappings
Type: Array of BlockDeviceMapping structures

Information about one or more block device mappings.

Description
Type: string

A description for the new image.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

InstanceId
Required: Yes
Type: string

The ID of the instance.

Name
Required: Yes
Type: string

A name for the new image.

Constraints: 3-128 alphanumeric characters, parentheses (()), square brackets ([]), spaces ( ), periods (.), slashes (/), dashes (-), single quotes ('), at-signs (@), or underscores(_)

NoReboot
Type: boolean

By default, Amazon EC2 attempts to shut down and reboot the instance before creating the image. If the 'No Reboot' option is set, Amazon EC2 doesn't shut down the instance before creating the image. When this option is used, file system integrity on the created image can't be guaranteed.

Result Syntax

[
    'ImageId' => '<string>',
]

Result Details

Members
ImageId
Type: string

The ID of the new AMI.

Errors

There are no errors described for this operation.

CreateInstanceExportTask

$result = $client->createInstanceExportTask([/* ... */]);
$promise = $client->createInstanceExportTaskAsync([/* ... */]);

Exports a running or stopped instance to an S3 bucket.

For information about the supported operating systems, image formats, and known limitations for the types of instances you can export, see Exporting EC2 Instances in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->createInstanceExportTask([
    'Description' => '<string>',
    'ExportToS3Task' => [
        'ContainerFormat' => 'ova',
        'DiskImageFormat' => 'VMDK|RAW|VHD',
        'S3Bucket' => '<string>',
        'S3Prefix' => '<string>',
    ],
    'InstanceId' => '<string>', // REQUIRED
    'TargetEnvironment' => 'citrix|vmware|microsoft',
]);

Parameter Details

Members
Description
Type: string

A description for the conversion task or the resource being exported. The maximum length is 255 bytes.

ExportToS3Task
Type: ExportToS3TaskSpecification structure

The format and location for an instance export task.

InstanceId
Required: Yes
Type: string

The ID of the instance.

TargetEnvironment
Type: string

The target virtualization environment.

Result Syntax

[
    'ExportTask' => [
        'Description' => '<string>',
        'ExportTaskId' => '<string>',
        'ExportToS3Task' => [
            'ContainerFormat' => 'ova',
            'DiskImageFormat' => 'VMDK|RAW|VHD',
            'S3Bucket' => '<string>',
            'S3Key' => '<string>',
        ],
        'InstanceExportDetails' => [
            'InstanceId' => '<string>',
            'TargetEnvironment' => 'citrix|vmware|microsoft',
        ],
        'State' => 'active|cancelling|cancelled|completed',
        'StatusMessage' => '<string>',
    ],
]

Result Details

Members
ExportTask
Type: ExportTask structure

Information about the instance export task.

Errors

There are no errors described for this operation.

CreateInternetGateway

$result = $client->createInternetGateway([/* ... */]);
$promise = $client->createInternetGatewayAsync([/* ... */]);

Creates an Internet gateway for use with a VPC. After creating the Internet gateway, you attach it to a VPC using AttachInternetGateway.

For more information about your VPC and Internet gateway, see the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->createInternetGateway([
    'DryRun' => true || false,
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Result Syntax

[
    'InternetGateway' => [
        'Attachments' => [
            [
                'State' => 'attaching|attached|detaching|detached',
                'VpcId' => '<string>',
            ],
            // ...
        ],
        'InternetGatewayId' => '<string>',
        'Tags' => [
            [
                'Key' => '<string>',
                'Value' => '<string>',
            ],
            // ...
        ],
    ],
]

Result Details

Members
InternetGateway
Type: InternetGateway structure

Information about the Internet gateway.

Errors

There are no errors described for this operation.

CreateKeyPair

$result = $client->createKeyPair([/* ... */]);
$promise = $client->createKeyPairAsync([/* ... */]);

Creates a 2048-bit RSA key pair with the specified name. Amazon EC2 stores the public key and displays the private key for you to save to a file. The private key is returned as an unencrypted PEM encoded PKCS#8 private key. If a key with the specified name already exists, Amazon EC2 returns an error.

You can have up to five thousand key pairs per region.

The key pair returned to you is available only in the region in which you create it. To create a key pair that is available in all regions, use ImportKeyPair.

For more information about key pairs, see Key Pairs in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->createKeyPair([
    'DryRun' => true || false,
    'KeyName' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

KeyName
Required: Yes
Type: string

A unique name for the key pair.

Constraints: Up to 255 ASCII characters

Result Syntax

[
    'KeyFingerprint' => '<string>',
    'KeyMaterial' => '<string>',
    'KeyName' => '<string>',
]

Result Details

Members
KeyFingerprint
Type: string

The SHA-1 digest of the DER encoded private key.

KeyMaterial
Type: string

An unencrypted PEM encoded RSA private key.

KeyName
Type: string

The name of the key pair.

Errors

There are no errors described for this operation.

CreateNatGateway

$result = $client->createNatGateway([/* ... */]);
$promise = $client->createNatGatewayAsync([/* ... */]);

Creates a NAT gateway in the specified subnet. A NAT gateway can be used to enable instances in a private subnet to connect to the Internet. This action creates a network interface in the specified subnet with a private IP address from the IP address range of the subnet. For more information, see NAT Gateways in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->createNatGateway([
    'AllocationId' => '<string>', // REQUIRED
    'ClientToken' => '<string>',
    'SubnetId' => '<string>', // REQUIRED
]);

Parameter Details

Members
AllocationId
Required: Yes
Type: string

The allocation ID of an Elastic IP address to associate with the NAT gateway. If the Elastic IP address is associated with another resource, you must first disassociate it.

ClientToken
Type: string

Unique, case-sensitive identifier you provide to ensure the idempotency of the request. For more information, see How to Ensure Idempotency.

Constraint: Maximum 64 ASCII characters.

SubnetId
Required: Yes
Type: string

The subnet in which to create the NAT gateway.

Result Syntax

[
    'ClientToken' => '<string>',
    'NatGateway' => [
        'CreateTime' => <DateTime>,
        'DeleteTime' => <DateTime>,
        'FailureCode' => '<string>',
        'FailureMessage' => '<string>',
        'NatGatewayAddresses' => [
            [
                'AllocationId' => '<string>',
                'NetworkInterfaceId' => '<string>',
                'PrivateIp' => '<string>',
                'PublicIp' => '<string>',
            ],
            // ...
        ],
        'NatGatewayId' => '<string>',
        'ProvisionedBandwidth' => [
            'ProvisionTime' => <DateTime>,
            'Provisioned' => '<string>',
            'RequestTime' => <DateTime>,
            'Requested' => '<string>',
            'Status' => '<string>',
        ],
        'State' => 'pending|failed|available|deleting|deleted',
        'SubnetId' => '<string>',
        'VpcId' => '<string>',
    ],
]

Result Details

Members
ClientToken
Type: string

Unique, case-sensitive identifier to ensure the idempotency of the request. Only returned if a client token was provided in the request.

NatGateway
Type: NatGateway structure

Information about the NAT gateway.

Errors

There are no errors described for this operation.

CreateNetworkAcl

$result = $client->createNetworkAcl([/* ... */]);
$promise = $client->createNetworkAclAsync([/* ... */]);

Creates a network ACL in a VPC. Network ACLs provide an optional layer of security (in addition to security groups) for the instances in your VPC.

For more information about network ACLs, see Network ACLs in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->createNetworkAcl([
    'DryRun' => true || false,
    'VpcId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VpcId
Required: Yes
Type: string

The ID of the VPC.

Result Syntax

[
    'NetworkAcl' => [
        'Associations' => [
            [
                'NetworkAclAssociationId' => '<string>',
                'NetworkAclId' => '<string>',
                'SubnetId' => '<string>',
            ],
            // ...
        ],
        'Entries' => [
            [
                'CidrBlock' => '<string>',
                'Egress' => true || false,
                'IcmpTypeCode' => [
                    'Code' => <integer>,
                    'Type' => <integer>,
                ],
                'PortRange' => [
                    'From' => <integer>,
                    'To' => <integer>,
                ],
                'Protocol' => '<string>',
                'RuleAction' => 'allow|deny',
                'RuleNumber' => <integer>,
            ],
            // ...
        ],
        'IsDefault' => true || false,
        'NetworkAclId' => '<string>',
        'Tags' => [
            [
                'Key' => '<string>',
                'Value' => '<string>',
            ],
            // ...
        ],
        'VpcId' => '<string>',
    ],
]

Result Details

Members
NetworkAcl
Type: NetworkAcl structure

Information about the network ACL.

Errors

There are no errors described for this operation.

CreateNetworkAclEntry

$result = $client->createNetworkAclEntry([/* ... */]);
$promise = $client->createNetworkAclEntryAsync([/* ... */]);

Creates an entry (a rule) in a network ACL with the specified rule number. Each network ACL has a set of numbered ingress rules and a separate set of numbered egress rules. When determining whether a packet should be allowed in or out of a subnet associated with the ACL, we process the entries in the ACL according to the rule numbers, in ascending order. Each network ACL has a set of ingress rules and a separate set of egress rules.

We recommend that you leave room between the rule numbers (for example, 100, 110, 120, ...), and not number them one right after the other (for example, 101, 102, 103, ...). This makes it easier to add a rule between existing ones without having to renumber the rules.

After you add an entry, you can't modify it; you must either replace it, or create an entry and delete the old one.

For more information about network ACLs, see Network ACLs in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->createNetworkAclEntry([
    'CidrBlock' => '<string>', // REQUIRED
    'DryRun' => true || false,
    'Egress' => true || false, // REQUIRED
    'IcmpTypeCode' => [
        'Code' => <integer>,
        'Type' => <integer>,
    ],
    'NetworkAclId' => '<string>', // REQUIRED
    'PortRange' => [
        'From' => <integer>,
        'To' => <integer>,
    ],
    'Protocol' => '<string>', // REQUIRED
    'RuleAction' => 'allow|deny', // REQUIRED
    'RuleNumber' => <integer>, // REQUIRED
]);

Parameter Details

Members
CidrBlock
Required: Yes
Type: string

The network range to allow or deny, in CIDR notation (for example 172.16.0.0/24).

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Egress
Required: Yes
Type: boolean

Indicates whether this is an egress rule (rule is applied to traffic leaving the subnet).

IcmpTypeCode
Type: IcmpTypeCode structure

ICMP protocol: The ICMP type and code. Required if specifying ICMP for the protocol.

NetworkAclId
Required: Yes
Type: string

The ID of the network ACL.

PortRange
Type: PortRange structure

TCP or UDP protocols: The range of ports the rule applies to.

Protocol
Required: Yes
Type: string

The protocol. A value of -1 means all protocols.

RuleAction
Required: Yes
Type: string

Indicates whether to allow or deny the traffic that matches the rule.

RuleNumber
Required: Yes
Type: int

The rule number for the entry (for example, 100). ACL entries are processed in ascending order by rule number.

Constraints: Positive integer from 1 to 32766. The range 32767 to 65535 is reserved for internal use.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

CreateNetworkInterface

$result = $client->createNetworkInterface([/* ... */]);
$promise = $client->createNetworkInterfaceAsync([/* ... */]);

Creates a network interface in the specified subnet.

For more information about network interfaces, see Elastic Network Interfaces in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->createNetworkInterface([
    'Description' => '<string>',
    'DryRun' => true || false,
    'Groups' => ['<string>', ...],
    'PrivateIpAddress' => '<string>',
    'PrivateIpAddresses' => [
        [
            'Primary' => true || false,
            'PrivateIpAddress' => '<string>', // REQUIRED
        ],
        // ...
    ],
    'SecondaryPrivateIpAddressCount' => <integer>,
    'SubnetId' => '<string>', // REQUIRED
]);

Parameter Details

Members
Description
Type: string

A description for the network interface.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Groups
Type: Array of strings

The IDs of one or more security groups.

PrivateIpAddress
Type: string

The primary private IP address of the network interface. If you don't specify an IP address, Amazon EC2 selects one for you from the subnet range. If you specify an IP address, you cannot indicate any IP addresses specified in privateIpAddresses as primary (only one IP address can be designated as primary).

PrivateIpAddresses
Type: Array of PrivateIpAddressSpecification structures

One or more private IP addresses.

SecondaryPrivateIpAddressCount
Type: int

The number of secondary private IP addresses to assign to a network interface. When you specify a number of secondary IP addresses, Amazon EC2 selects these IP addresses within the subnet range. You can't specify this option and specify more than one private IP address using privateIpAddresses.

The number of IP addresses you can assign to a network interface varies by instance type. For more information, see Private IP Addresses Per ENI Per Instance Type in the Amazon Elastic Compute Cloud User Guide.

SubnetId
Required: Yes
Type: string

The ID of the subnet to associate with the network interface.

Result Syntax

[
    'NetworkInterface' => [
        'Association' => [
            'AllocationId' => '<string>',
            'AssociationId' => '<string>',
            'IpOwnerId' => '<string>',
            'PublicDnsName' => '<string>',
            'PublicIp' => '<string>',
        ],
        'Attachment' => [
            'AttachTime' => <DateTime>,
            'AttachmentId' => '<string>',
            'DeleteOnTermination' => true || false,
            'DeviceIndex' => <integer>,
            'InstanceId' => '<string>',
            'InstanceOwnerId' => '<string>',
            'Status' => 'attaching|attached|detaching|detached',
        ],
        'AvailabilityZone' => '<string>',
        'Description' => '<string>',
        'Groups' => [
            [
                'GroupId' => '<string>',
                'GroupName' => '<string>',
            ],
            // ...
        ],
        'InterfaceType' => 'interface|natGateway',
        'MacAddress' => '<string>',
        'NetworkInterfaceId' => '<string>',
        'OwnerId' => '<string>',
        'PrivateDnsName' => '<string>',
        'PrivateIpAddress' => '<string>',
        'PrivateIpAddresses' => [
            [
                'Association' => [
                    'AllocationId' => '<string>',
                    'AssociationId' => '<string>',
                    'IpOwnerId' => '<string>',
                    'PublicDnsName' => '<string>',
                    'PublicIp' => '<string>',
                ],
                'Primary' => true || false,
                'PrivateDnsName' => '<string>',
                'PrivateIpAddress' => '<string>',
            ],
            // ...
        ],
        'RequesterId' => '<string>',
        'RequesterManaged' => true || false,
        'SourceDestCheck' => true || false,
        'Status' => 'available|attaching|in-use|detaching',
        'SubnetId' => '<string>',
        'TagSet' => [
            [
                'Key' => '<string>',
                'Value' => '<string>',
            ],
            // ...
        ],
        'VpcId' => '<string>',
    ],
]

Result Details

Members
NetworkInterface
Type: NetworkInterface structure

Information about the network interface.

Errors

There are no errors described for this operation.

CreatePlacementGroup

$result = $client->createPlacementGroup([/* ... */]);
$promise = $client->createPlacementGroupAsync([/* ... */]);

Creates a placement group that you launch cluster instances into. You must give the group a name that's unique within the scope of your account.

For more information about placement groups and cluster instances, see Cluster Instances in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->createPlacementGroup([
    'DryRun' => true || false,
    'GroupName' => '<string>', // REQUIRED
    'Strategy' => 'cluster', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

GroupName
Required: Yes
Type: string

A name for the placement group.

Constraints: Up to 255 ASCII characters

Strategy
Required: Yes
Type: string

The placement strategy.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

CreateReservedInstancesListing

$result = $client->createReservedInstancesListing([/* ... */]);
$promise = $client->createReservedInstancesListingAsync([/* ... */]);

Creates a listing for Amazon EC2 Reserved Instances to be sold in the Reserved Instance Marketplace. You can submit one Reserved Instance listing at a time. To get a list of your Reserved Instances, you can use the DescribeReservedInstances operation.

The Reserved Instance Marketplace matches sellers who want to resell Reserved Instance capacity that they no longer need with buyers who want to purchase additional capacity. Reserved Instances bought and sold through the Reserved Instance Marketplace work like any other Reserved Instances.

To sell your Reserved Instances, you must first register as a seller in the Reserved Instance Marketplace. After completing the registration process, you can create a Reserved Instance Marketplace listing of some or all of your Reserved Instances, and specify the upfront price to receive for them. Your Reserved Instance listings then become available for purchase. To view the details of your Reserved Instance listing, you can use the DescribeReservedInstancesListings operation.

For more information, see Reserved Instance Marketplace in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->createReservedInstancesListing([
    'ClientToken' => '<string>', // REQUIRED
    'InstanceCount' => <integer>, // REQUIRED
    'PriceSchedules' => [ // REQUIRED
        [
            'CurrencyCode' => 'USD',
            'Price' => <float>,
            'Term' => <integer>,
        ],
        // ...
    ],
    'ReservedInstancesId' => '<string>', // REQUIRED
]);

Parameter Details

Members
ClientToken
Required: Yes
Type: string

Unique, case-sensitive identifier you provide to ensure idempotency of your listings. This helps avoid duplicate listings. For more information, see Ensuring Idempotency.

InstanceCount
Required: Yes
Type: int

The number of instances that are a part of a Reserved Instance account to be listed in the Reserved Instance Marketplace. This number should be less than or equal to the instance count associated with the Reserved Instance ID specified in this call.

PriceSchedules
Required: Yes
Type: Array of PriceScheduleSpecification structures

A list specifying the price of the Reserved Instance for each month remaining in the Reserved Instance term.

ReservedInstancesId
Required: Yes
Type: string

The ID of the active Reserved Instance.

Result Syntax

[
    'ReservedInstancesListings' => [
        [
            'ClientToken' => '<string>',
            'CreateDate' => <DateTime>,
            'InstanceCounts' => [
                [
                    'InstanceCount' => <integer>,
                    'State' => 'available|sold|cancelled|pending',
                ],
                // ...
            ],
            'PriceSchedules' => [
                [
                    'Active' => true || false,
                    'CurrencyCode' => 'USD',
                    'Price' => <float>,
                    'Term' => <integer>,
                ],
                // ...
            ],
            'ReservedInstancesId' => '<string>',
            'ReservedInstancesListingId' => '<string>',
            'Status' => 'active|pending|cancelled|closed',
            'StatusMessage' => '<string>',
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'UpdateDate' => <DateTime>,
        ],
        // ...
    ],
]

Result Details

Members
ReservedInstancesListings
Type: Array of ReservedInstancesListing structures

Information about the Reserved Instance listing.

Errors

There are no errors described for this operation.

CreateRoute

$result = $client->createRoute([/* ... */]);
$promise = $client->createRouteAsync([/* ... */]);

Creates a route in a route table within a VPC.

You must specify one of the following targets: Internet gateway or virtual private gateway, NAT instance, NAT gateway, VPC peering connection, or network interface.

When determining how to route traffic, we use the route with the most specific match. For example, let's say the traffic is destined for 192.0.2.3, and the route table includes the following two routes:

  • 192.0.2.0/24 (goes to some target A)

  • 192.0.2.0/28 (goes to some target B)

Both routes apply to the traffic destined for 192.0.2.3. However, the second route in the list covers a smaller number of IP addresses and is therefore more specific, so we use that route to determine where to target the traffic.

For more information about route tables, see Route Tables in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->createRoute([
    'DestinationCidrBlock' => '<string>', // REQUIRED
    'DryRun' => true || false,
    'GatewayId' => '<string>',
    'InstanceId' => '<string>',
    'NatGatewayId' => '<string>',
    'NetworkInterfaceId' => '<string>',
    'RouteTableId' => '<string>', // REQUIRED
    'VpcPeeringConnectionId' => '<string>',
]);

Parameter Details

Members
DestinationCidrBlock
Required: Yes
Type: string

The CIDR address block used for the destination match. Routing decisions are based on the most specific match.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

GatewayId
Type: string

The ID of an Internet gateway or virtual private gateway attached to your VPC.

InstanceId
Type: string

The ID of a NAT instance in your VPC. The operation fails if you specify an instance ID unless exactly one network interface is attached.

NatGatewayId
Type: string

The ID of a NAT gateway.

NetworkInterfaceId
Type: string

The ID of a network interface.

RouteTableId
Required: Yes
Type: string

The ID of the route table for the route.

VpcPeeringConnectionId
Type: string

The ID of a VPC peering connection.

Result Syntax

[
    'Return' => true || false,
]

Result Details

Members
Return
Type: boolean

Returns true if the request succeeds; otherwise, it returns an error.

Errors

There are no errors described for this operation.

CreateRouteTable

$result = $client->createRouteTable([/* ... */]);
$promise = $client->createRouteTableAsync([/* ... */]);

Creates a route table for the specified VPC. After you create a route table, you can add routes and associate the table with a subnet.

For more information about route tables, see Route Tables in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->createRouteTable([
    'DryRun' => true || false,
    'VpcId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VpcId
Required: Yes
Type: string

The ID of the VPC.

Result Syntax

[
    'RouteTable' => [
        'Associations' => [
            [
                'Main' => true || false,
                'RouteTableAssociationId' => '<string>',
                'RouteTableId' => '<string>',
                'SubnetId' => '<string>',
            ],
            // ...
        ],
        'PropagatingVgws' => [
            [
                'GatewayId' => '<string>',
            ],
            // ...
        ],
        'RouteTableId' => '<string>',
        'Routes' => [
            [
                'DestinationCidrBlock' => '<string>',
                'DestinationPrefixListId' => '<string>',
                'GatewayId' => '<string>',
                'InstanceId' => '<string>',
                'InstanceOwnerId' => '<string>',
                'NatGatewayId' => '<string>',
                'NetworkInterfaceId' => '<string>',
                'Origin' => 'CreateRouteTable|CreateRoute|EnableVgwRoutePropagation',
                'State' => 'active|blackhole',
                'VpcPeeringConnectionId' => '<string>',
            ],
            // ...
        ],
        'Tags' => [
            [
                'Key' => '<string>',
                'Value' => '<string>',
            ],
            // ...
        ],
        'VpcId' => '<string>',
    ],
]

Result Details

Members
RouteTable
Type: RouteTable structure

Information about the route table.

Errors

There are no errors described for this operation.

CreateSecurityGroup

$result = $client->createSecurityGroup([/* ... */]);
$promise = $client->createSecurityGroupAsync([/* ... */]);

Creates a security group.

A security group is for use with instances either in the EC2-Classic platform or in a specific VPC. For more information, see Amazon EC2 Security Groups in the Amazon Elastic Compute Cloud User Guide and Security Groups for Your VPC in the Amazon Virtual Private Cloud User Guide.

EC2-Classic: You can have up to 500 security groups.

EC2-VPC: You can create up to 500 security groups per VPC.

When you create a security group, you specify a friendly name of your choice. You can have a security group for use in EC2-Classic with the same name as a security group for use in a VPC. However, you can't have two security groups for use in EC2-Classic with the same name or two security groups for use in a VPC with the same name.

You have a default security group for use in EC2-Classic and a default security group for use in your VPC. If you don't specify a security group when you launch an instance, the instance is launched into the appropriate default security group. A default security group includes a default rule that grants instances unrestricted network access to each other.

You can add or remove rules from your security groups using AuthorizeSecurityGroupIngress, AuthorizeSecurityGroupEgress, RevokeSecurityGroupIngress, and RevokeSecurityGroupEgress.

Parameter Syntax

$result = $client->createSecurityGroup([
    'Description' => '<string>', // REQUIRED
    'DryRun' => true || false,
    'GroupName' => '<string>', // REQUIRED
    'VpcId' => '<string>',
]);

Parameter Details

Members
Description
Required: Yes
Type: string

A description for the security group. This is informational only.

Constraints: Up to 255 characters in length

Constraints for EC2-Classic: ASCII characters

Constraints for EC2-VPC: a-z, A-Z, 0-9, spaces, and ._-:/()#,@[]+=;{}!$*

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

GroupName
Required: Yes
Type: string

The name of the security group.

Constraints: Up to 255 characters in length

Constraints for EC2-Classic: ASCII characters

Constraints for EC2-VPC: a-z, A-Z, 0-9, spaces, and ._-:/()#,@[]+=;{}!$*

VpcId
Type: string

[EC2-VPC] The ID of the VPC. Required for EC2-VPC.

Result Syntax

[
    'GroupId' => '<string>',
]

Result Details

Members
GroupId
Type: string

The ID of the security group.

Errors

There are no errors described for this operation.

CreateSnapshot

$result = $client->createSnapshot([/* ... */]);
$promise = $client->createSnapshotAsync([/* ... */]);

Creates a snapshot of an EBS volume and stores it in Amazon S3. You can use snapshots for backups, to make copies of EBS volumes, and to save data before shutting down an instance.

When a snapshot is created, any AWS Marketplace product codes that are associated with the source volume are propagated to the snapshot.

You can take a snapshot of an attached volume that is in use. However, snapshots only capture data that has been written to your EBS volume at the time the snapshot command is issued; this may exclude any data that has been cached by any applications or the operating system. If you can pause any file systems on the volume long enough to take a snapshot, your snapshot should be complete. However, if you cannot pause all file writes to the volume, you should unmount the volume from within the instance, issue the snapshot command, and then remount the volume to ensure a consistent and complete snapshot. You may remount and use your volume while the snapshot status is pending.

To create a snapshot for EBS volumes that serve as root devices, you should stop the instance before taking the snapshot.

Snapshots that are taken from encrypted volumes are automatically encrypted. Volumes that are created from encrypted snapshots are also automatically encrypted. Your encrypted volumes and any associated snapshots always remain protected.

For more information, see Amazon Elastic Block Store and Amazon EBS Encryption in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->createSnapshot([
    'Description' => '<string>',
    'DryRun' => true || false,
    'VolumeId' => '<string>', // REQUIRED
]);

Parameter Details

Members
Description
Type: string

A description for the snapshot.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VolumeId
Required: Yes
Type: string

The ID of the EBS volume.

Result Syntax

[
    'DataEncryptionKeyId' => '<string>',
    'Description' => '<string>',
    'Encrypted' => true || false,
    'KmsKeyId' => '<string>',
    'OwnerAlias' => '<string>',
    'OwnerId' => '<string>',
    'Progress' => '<string>',
    'SnapshotId' => '<string>',
    'StartTime' => <DateTime>,
    'State' => 'pending|completed|error',
    'StateMessage' => '<string>',
    'Tags' => [
        [
            'Key' => '<string>',
            'Value' => '<string>',
        ],
        // ...
    ],
    'VolumeId' => '<string>',
    'VolumeSize' => <integer>,
]

Result Details

Members
DataEncryptionKeyId
Type: string

The data encryption key identifier for the snapshot. This value is a unique identifier that corresponds to the data encryption key that was used to encrypt the original volume or snapshot copy. Because data encryption keys are inherited by volumes created from snapshots, and vice versa, if snapshots share the same data encryption key identifier, then they belong to the same volume/snapshot lineage. This parameter is only returned by the DescribeSnapshots API operation.

Description
Type: string

The description for the snapshot.

Encrypted
Type: boolean

Indicates whether the snapshot is encrypted.

KmsKeyId
Type: string

The full ARN of the AWS Key Management Service (AWS KMS) customer master key (CMK) that was used to protect the volume encryption key for the parent volume.

OwnerAlias
Type: string

The AWS account alias (for example, amazon, self) or AWS account ID that owns the snapshot.

OwnerId
Type: string

The AWS account ID of the EBS snapshot owner.

Progress
Type: string

The progress of the snapshot, as a percentage.

SnapshotId
Type: string

The ID of the snapshot. Each snapshot receives a unique identifier when it is created.

StartTime
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time stamp when the snapshot was initiated.

State
Type: string

The snapshot state.

StateMessage
Type: string

Encrypted Amazon EBS snapshots are copied asynchronously. If a snapshot copy operation fails (for example, if the proper AWS Key Management Service (AWS KMS) permissions are not obtained) this field displays error state details to help you diagnose why the error occurred. This parameter is only returned by the DescribeSnapshots API operation.

Tags
Type: Array of Tag structures

Any tags assigned to the snapshot.

VolumeId
Type: string

The ID of the volume that was used to create the snapshot.

VolumeSize
Type: int

The size of the volume, in GiB.

Errors

There are no errors described for this operation.

CreateSpotDatafeedSubscription

$result = $client->createSpotDatafeedSubscription([/* ... */]);
$promise = $client->createSpotDatafeedSubscriptionAsync([/* ... */]);

Creates a data feed for Spot instances, enabling you to view Spot instance usage logs. You can create one data feed per AWS account. For more information, see Spot Instance Data Feed in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->createSpotDatafeedSubscription([
    'Bucket' => '<string>', // REQUIRED
    'DryRun' => true || false,
    'Prefix' => '<string>',
]);

Parameter Details

Members
Bucket
Required: Yes
Type: string

The Amazon S3 bucket in which to store the Spot instance data feed.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Prefix
Type: string

A prefix for the data feed file names.

Result Syntax

[
    'SpotDatafeedSubscription' => [
        'Bucket' => '<string>',
        'Fault' => [
            'Code' => '<string>',
            'Message' => '<string>',
        ],
        'OwnerId' => '<string>',
        'Prefix' => '<string>',
        'State' => 'Active|Inactive',
    ],
]

Result Details

Members
SpotDatafeedSubscription
Type: SpotDatafeedSubscription structure

The Spot instance data feed subscription.

Errors

There are no errors described for this operation.

CreateSubnet

$result = $client->createSubnet([/* ... */]);
$promise = $client->createSubnetAsync([/* ... */]);

Creates a subnet in an existing VPC.

When you create each subnet, you provide the VPC ID and the CIDR block you want for the subnet. After you create a subnet, you can't change its CIDR block. The subnet's CIDR block can be the same as the VPC's CIDR block (assuming you want only a single subnet in the VPC), or a subset of the VPC's CIDR block. If you create more than one subnet in a VPC, the subnets' CIDR blocks must not overlap. The smallest subnet (and VPC) you can create uses a /28 netmask (16 IP addresses), and the largest uses a /16 netmask (65,536 IP addresses).

AWS reserves both the first four and the last IP address in each subnet's CIDR block. They're not available for use.

If you add more than one subnet to a VPC, they're set up in a star topology with a logical router in the middle.

If you launch an instance in a VPC using an Amazon EBS-backed AMI, the IP address doesn't change if you stop and restart the instance (unlike a similar instance launched outside a VPC, which gets a new IP address when restarted). It's therefore possible to have a subnet with no running instances (they're all stopped), but no remaining IP addresses available.

For more information about subnets, see Your VPC and Subnets in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->createSubnet([
    'AvailabilityZone' => '<string>',
    'CidrBlock' => '<string>', // REQUIRED
    'DryRun' => true || false,
    'VpcId' => '<string>', // REQUIRED
]);

Parameter Details

Members
AvailabilityZone
Type: string

The Availability Zone for the subnet.

Default: AWS selects one for you. If you create more than one subnet in your VPC, we may not necessarily select a different zone for each subnet.

CidrBlock
Required: Yes
Type: string

The network range for the subnet, in CIDR notation. For example, 10.0.0.0/24.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VpcId
Required: Yes
Type: string

The ID of the VPC.

Result Syntax

[
    'Subnet' => [
        'AvailabilityZone' => '<string>',
        'AvailableIpAddressCount' => <integer>,
        'CidrBlock' => '<string>',
        'DefaultForAz' => true || false,
        'MapPublicIpOnLaunch' => true || false,
        'State' => 'pending|available',
        'SubnetId' => '<string>',
        'Tags' => [
            [
                'Key' => '<string>',
                'Value' => '<string>',
            ],
            // ...
        ],
        'VpcId' => '<string>',
    ],
]

Result Details

Members
Subnet
Type: Subnet structure

Information about the subnet.

Errors

There are no errors described for this operation.

CreateTags

$result = $client->createTags([/* ... */]);
$promise = $client->createTagsAsync([/* ... */]);

Adds or overwrites one or more tags for the specified Amazon EC2 resource or resources. Each resource can have a maximum of 10 tags. Each tag consists of a key and optional value. Tag keys must be unique per resource.

For more information about tags, see Tagging Your Resources in the Amazon Elastic Compute Cloud User Guide. For more information about creating IAM policies that control users' access to resources based on tags, see Supported Resource-Level Permissions for Amazon EC2 API Actions in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->createTags([
    'DryRun' => true || false,
    'Resources' => ['<string>', ...], // REQUIRED
    'Tags' => [ // REQUIRED
        [
            'Key' => '<string>',
            'Value' => '<string>',
        ],
        // ...
    ],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Resources
Required: Yes
Type: Array of strings

The IDs of one or more resources to tag. For example, ami-1a2b3c4d.

Tags
Required: Yes
Type: Array of Tag structures

One or more tags. The value parameter is required, but if you don't want the tag to have a value, specify the parameter with no value, and we set the value to an empty string.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

CreateVolume

$result = $client->createVolume([/* ... */]);
$promise = $client->createVolumeAsync([/* ... */]);

Creates an EBS volume that can be attached to an instance in the same Availability Zone. The volume is created in the regional endpoint that you send the HTTP request to. For more information see Regions and Endpoints.

You can create a new empty volume or restore a volume from an EBS snapshot. Any AWS Marketplace product codes from the snapshot are propagated to the volume.

You can create encrypted volumes with the Encrypted parameter. Encrypted volumes may only be attached to instances that support Amazon EBS encryption. Volumes that are created from encrypted snapshots are also automatically encrypted. For more information, see Amazon EBS Encryption in the Amazon Elastic Compute Cloud User Guide.

For more information, see Creating or Restoring an Amazon EBS Volume in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->createVolume([
    'AvailabilityZone' => '<string>', // REQUIRED
    'DryRun' => true || false,
    'Encrypted' => true || false,
    'Iops' => <integer>,
    'KmsKeyId' => '<string>',
    'Size' => <integer>,
    'SnapshotId' => '<string>',
    'VolumeType' => 'standard|io1|gp2|sc1|st1',
]);

Parameter Details

Members
AvailabilityZone
Required: Yes
Type: string

The Availability Zone in which to create the volume. Use DescribeAvailabilityZones to list the Availability Zones that are currently available to you.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Encrypted
Type: boolean

Specifies whether the volume should be encrypted. Encrypted Amazon EBS volumes may only be attached to instances that support Amazon EBS encryption. Volumes that are created from encrypted snapshots are automatically encrypted. There is no way to create an encrypted volume from an unencrypted snapshot or vice versa. If your AMI uses encrypted volumes, you can only launch it on supported instance types. For more information, see Amazon EBS Encryption in the Amazon Elastic Compute Cloud User Guide.

Iops
Type: int

Only valid for Provisioned IOPS SSD volumes. The number of I/O operations per second (IOPS) to provision for the volume, with a maximum ratio of 30 IOPS/GiB.

Constraint: Range is 100 to 20000 for Provisioned IOPS SSD volumes

KmsKeyId
Type: string

The full ARN of the AWS Key Management Service (AWS KMS) customer master key (CMK) to use when creating the encrypted volume. This parameter is only required if you want to use a non-default CMK; if this parameter is not specified, the default CMK for EBS is used. The ARN contains the arn:aws:kms namespace, followed by the region of the CMK, the AWS account ID of the CMK owner, the key namespace, and then the CMK ID. For example, arn:aws:kms:us-east-1:012345678910:key/abcd1234-a123-456a-a12b-a123b4cd56ef. If a KmsKeyId is specified, the Encrypted flag must also be set.

Size
Type: int

The size of the volume, in GiBs.

Constraints: 1-16384 for gp2, 4-16384 for io1, 500-16384 for st1, 500-16384 for sc1, and 1-1024 for standard. If you specify a snapshot, the volume size must be equal to or larger than the snapshot size.

Default: If you're creating the volume from a snapshot and don't specify a volume size, the default is the snapshot size.

SnapshotId
Type: string

The snapshot from which to create the volume.

VolumeType
Type: string

The volume type. This can be gp2 for General Purpose SSD, io1 for Provisioned IOPS SSD, st1 for Throughput Optimized HDD, sc1 for Cold HDD, or standard for Magnetic volumes.

Default: standard

Result Syntax

[
    'Attachments' => [
        [
            'AttachTime' => <DateTime>,
            'DeleteOnTermination' => true || false,
            'Device' => '<string>',
            'InstanceId' => '<string>',
            'State' => 'attaching|attached|detaching|detached',
            'VolumeId' => '<string>',
        ],
        // ...
    ],
    'AvailabilityZone' => '<string>',
    'CreateTime' => <DateTime>,
    'Encrypted' => true || false,
    'Iops' => <integer>,
    'KmsKeyId' => '<string>',
    'Size' => <integer>,
    'SnapshotId' => '<string>',
    'State' => 'creating|available|in-use|deleting|deleted|error',
    'Tags' => [
        [
            'Key' => '<string>',
            'Value' => '<string>',
        ],
        // ...
    ],
    'VolumeId' => '<string>',
    'VolumeType' => 'standard|io1|gp2|sc1|st1',
]

Result Details

Members
Attachments
Type: Array of VolumeAttachment structures

Information about the volume attachments.

AvailabilityZone
Type: string

The Availability Zone for the volume.

CreateTime
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time stamp when volume creation was initiated.

Encrypted
Type: boolean

Indicates whether the volume will be encrypted.

Iops
Type: int

The number of I/O operations per second (IOPS) that the volume supports. For Provisioned IOPS SSD volumes, this represents the number of IOPS that are provisioned for the volume. For General Purpose SSD volumes, this represents the baseline performance of the volume and the rate at which the volume accumulates I/O credits for bursting. For more information on General Purpose SSD baseline performance, I/O credits, and bursting, see Amazon EBS Volume Types in the Amazon Elastic Compute Cloud User Guide.

Constraint: Range is 100-20000 IOPS for io1 volumes and 100-10000 IOPS for gp2 volumes.

Condition: This parameter is required for requests to create io1 volumes; it is not used in requests to create gp2, st1, sc1, or standard volumes.

KmsKeyId
Type: string

The full ARN of the AWS Key Management Service (AWS KMS) customer master key (CMK) that was used to protect the volume encryption key for the volume.

Size
Type: int

The size of the volume, in GiBs.

SnapshotId
Type: string

The snapshot from which the volume was created, if applicable.

State
Type: string

The volume state.

Tags
Type: Array of Tag structures

Any tags assigned to the volume.

VolumeId
Type: string

The ID of the volume.

VolumeType
Type: string

The volume type. This can be gp2 for General Purpose SSD, io1 for Provisioned IOPS SSD, st1 for Throughput Optimized HDD, sc1 for Cold HDD, or standard for Magnetic volumes.

Errors

There are no errors described for this operation.

CreateVpc

$result = $client->createVpc([/* ... */]);
$promise = $client->createVpcAsync([/* ... */]);

Creates a VPC with the specified CIDR block.

The smallest VPC you can create uses a /28 netmask (16 IP addresses), and the largest uses a /16 netmask (65,536 IP addresses). To help you decide how big to make your VPC, see Your VPC and Subnets in the Amazon Virtual Private Cloud User Guide.

By default, each instance you launch in the VPC has the default DHCP options, which includes only a default DNS server that we provide (AmazonProvidedDNS). For more information about DHCP options, see DHCP Options Sets in the Amazon Virtual Private Cloud User Guide.

You can specify the instance tenancy value for the VPC when you create it. You can't change this value for the VPC after you create it. For more information, see Dedicated Instances in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->createVpc([
    'CidrBlock' => '<string>', // REQUIRED
    'DryRun' => true || false,
    'InstanceTenancy' => 'default|dedicated|host',
]);

Parameter Details

Members
CidrBlock
Required: Yes
Type: string

The network range for the VPC, in CIDR notation. For example, 10.0.0.0/16.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

InstanceTenancy
Type: string

The tenancy options for instances launched into the VPC. For default, instances are launched with shared tenancy by default. You can launch instances with any tenancy into a shared tenancy VPC. For dedicated, instances are launched as dedicated tenancy instances by default. You can only launch instances with a tenancy of dedicated or host into a dedicated tenancy VPC.

Important: The host value cannot be used with this parameter. Use the default or dedicated values only.

Default: default

Result Syntax

[
    'Vpc' => [
        'CidrBlock' => '<string>',
        'DhcpOptionsId' => '<string>',
        'InstanceTenancy' => 'default|dedicated|host',
        'IsDefault' => true || false,
        'State' => 'pending|available',
        'Tags' => [
            [
                'Key' => '<string>',
                'Value' => '<string>',
            ],
            // ...
        ],
        'VpcId' => '<string>',
    ],
]

Result Details

Members
Vpc
Type: Vpc structure

Information about the VPC.

Errors

There are no errors described for this operation.

CreateVpcEndpoint

$result = $client->createVpcEndpoint([/* ... */]);
$promise = $client->createVpcEndpointAsync([/* ... */]);

Creates a VPC endpoint for a specified AWS service. An endpoint enables you to create a private connection between your VPC and another AWS service in your account. You can specify an endpoint policy to attach to the endpoint that will control access to the service from your VPC. You can also specify the VPC route tables that use the endpoint.

Currently, only endpoints to Amazon S3 are supported.

Parameter Syntax

$result = $client->createVpcEndpoint([
    'ClientToken' => '<string>',
    'DryRun' => true || false,
    'PolicyDocument' => '<string>',
    'RouteTableIds' => ['<string>', ...],
    'ServiceName' => '<string>', // REQUIRED
    'VpcId' => '<string>', // REQUIRED
]);

Parameter Details

Members
ClientToken
Type: string

Unique, case-sensitive identifier you provide to ensure the idempotency of the request. For more information, see How to Ensure Idempotency.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

PolicyDocument
Type: string

A policy to attach to the endpoint that controls access to the service. The policy must be in valid JSON format. If this parameter is not specified, we attach a default policy that allows full access to the service.

RouteTableIds
Type: Array of strings

One or more route table IDs.

ServiceName
Required: Yes
Type: string

The AWS service name, in the form com.amazonaws.region.service. To get a list of available services, use the DescribeVpcEndpointServices request.

VpcId
Required: Yes
Type: string

The ID of the VPC in which the endpoint will be used.

Result Syntax

[
    'ClientToken' => '<string>',
    'VpcEndpoint' => [
        'CreationTimestamp' => <DateTime>,
        'PolicyDocument' => '<string>',
        'RouteTableIds' => ['<string>', ...],
        'ServiceName' => '<string>',
        'State' => 'Pending|Available|Deleting|Deleted',
        'VpcEndpointId' => '<string>',
        'VpcId' => '<string>',
    ],
]

Result Details

Members
ClientToken
Type: string

Unique, case-sensitive identifier you provide to ensure the idempotency of the request.

VpcEndpoint
Type: VpcEndpoint structure

Information about the endpoint.

Errors

There are no errors described for this operation.

CreateVpcPeeringConnection

$result = $client->createVpcPeeringConnection([/* ... */]);
$promise = $client->createVpcPeeringConnectionAsync([/* ... */]);

Requests a VPC peering connection between two VPCs: a requester VPC that you own and a peer VPC with which to create the connection. The peer VPC can belong to another AWS account. The requester VPC and peer VPC cannot have overlapping CIDR blocks.

The owner of the peer VPC must accept the peering request to activate the peering connection. The VPC peering connection request expires after 7 days, after which it cannot be accepted or rejected.

A CreateVpcPeeringConnection request between VPCs with overlapping CIDR blocks results in the VPC peering connection having a status of failed.

Parameter Syntax

$result = $client->createVpcPeeringConnection([
    'DryRun' => true || false,
    'PeerOwnerId' => '<string>',
    'PeerVpcId' => '<string>',
    'VpcId' => '<string>',
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

PeerOwnerId
Type: string

The AWS account ID of the owner of the peer VPC.

Default: Your AWS account ID

PeerVpcId
Type: string

The ID of the VPC with which you are creating the VPC peering connection.

VpcId
Type: string

The ID of the requester VPC.

Result Syntax

[
    'VpcPeeringConnection' => [
        'AccepterVpcInfo' => [
            'CidrBlock' => '<string>',
            'OwnerId' => '<string>',
            'PeeringOptions' => [
                'AllowEgressFromLocalClassicLinkToRemoteVpc' => true || false,
                'AllowEgressFromLocalVpcToRemoteClassicLink' => true || false,
            ],
            'VpcId' => '<string>',
        ],
        'ExpirationTime' => <DateTime>,
        'RequesterVpcInfo' => [
            'CidrBlock' => '<string>',
            'OwnerId' => '<string>',
            'PeeringOptions' => [
                'AllowEgressFromLocalClassicLinkToRemoteVpc' => true || false,
                'AllowEgressFromLocalVpcToRemoteClassicLink' => true || false,
            ],
            'VpcId' => '<string>',
        ],
        'Status' => [
            'Code' => 'initiating-request|pending-acceptance|active|deleted|rejected|failed|expired|provisioning|deleting',
            'Message' => '<string>',
        ],
        'Tags' => [
            [
                'Key' => '<string>',
                'Value' => '<string>',
            ],
            // ...
        ],
        'VpcPeeringConnectionId' => '<string>',
    ],
]

Result Details

Members
VpcPeeringConnection
Type: VpcPeeringConnection structure

Information about the VPC peering connection.

Errors

There are no errors described for this operation.

CreateVpnConnection

$result = $client->createVpnConnection([/* ... */]);
$promise = $client->createVpnConnectionAsync([/* ... */]);

Creates a VPN connection between an existing virtual private gateway and a VPN customer gateway. The only supported connection type is ipsec.1.

The response includes information that you need to give to your network administrator to configure your customer gateway.

We strongly recommend that you use HTTPS when calling this operation because the response contains sensitive cryptographic information for configuring your customer gateway.

If you decide to shut down your VPN connection for any reason and later create a new VPN connection, you must reconfigure your customer gateway with the new information returned from this call.

This is an idempotent operation. If you perform the operation more than once, Amazon EC2 doesn't return an error.

For more information about VPN connections, see Adding a Hardware Virtual Private Gateway to Your VPC in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->createVpnConnection([
    'CustomerGatewayId' => '<string>', // REQUIRED
    'DryRun' => true || false,
    'Options' => [
        'StaticRoutesOnly' => true || false,
    ],
    'Type' => '<string>', // REQUIRED
    'VpnGatewayId' => '<string>', // REQUIRED
]);

Parameter Details

Members
CustomerGatewayId
Required: Yes
Type: string

The ID of the customer gateway.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Options

Indicates whether the VPN connection requires static routes. If you are creating a VPN connection for a device that does not support BGP, you must specify true.

Default: false

Type
Required: Yes
Type: string

The type of VPN connection (ipsec.1).

VpnGatewayId
Required: Yes
Type: string

The ID of the virtual private gateway.

Result Syntax

[
    'VpnConnection' => [
        'CustomerGatewayConfiguration' => '<string>',
        'CustomerGatewayId' => '<string>',
        'Options' => [
            'StaticRoutesOnly' => true || false,
        ],
        'Routes' => [
            [
                'DestinationCidrBlock' => '<string>',
                'Source' => 'Static',
                'State' => 'pending|available|deleting|deleted',
            ],
            // ...
        ],
        'State' => 'pending|available|deleting|deleted',
        'Tags' => [
            [
                'Key' => '<string>',
                'Value' => '<string>',
            ],
            // ...
        ],
        'Type' => 'ipsec.1',
        'VgwTelemetry' => [
            [
                'AcceptedRouteCount' => <integer>,
                'LastStatusChange' => <DateTime>,
                'OutsideIpAddress' => '<string>',
                'Status' => 'UP|DOWN',
                'StatusMessage' => '<string>',
            ],
            // ...
        ],
        'VpnConnectionId' => '<string>',
        'VpnGatewayId' => '<string>',
    ],
]

Result Details

Members
VpnConnection
Type: VpnConnection structure

Information about the VPN connection.

Errors

There are no errors described for this operation.

CreateVpnConnectionRoute

$result = $client->createVpnConnectionRoute([/* ... */]);
$promise = $client->createVpnConnectionRouteAsync([/* ... */]);

Creates a static route associated with a VPN connection between an existing virtual private gateway and a VPN customer gateway. The static route allows traffic to be routed from the virtual private gateway to the VPN customer gateway.

For more information about VPN connections, see Adding a Hardware Virtual Private Gateway to Your VPC in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->createVpnConnectionRoute([
    'DestinationCidrBlock' => '<string>', // REQUIRED
    'VpnConnectionId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DestinationCidrBlock
Required: Yes
Type: string

The CIDR block associated with the local subnet of the customer network.

VpnConnectionId
Required: Yes
Type: string

The ID of the VPN connection.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

CreateVpnGateway

$result = $client->createVpnGateway([/* ... */]);
$promise = $client->createVpnGatewayAsync([/* ... */]);

Creates a virtual private gateway. A virtual private gateway is the endpoint on the VPC side of your VPN connection. You can create a virtual private gateway before creating the VPC itself.

For more information about virtual private gateways, see Adding a Hardware Virtual Private Gateway to Your VPC in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->createVpnGateway([
    'AvailabilityZone' => '<string>',
    'DryRun' => true || false,
    'Type' => 'ipsec.1', // REQUIRED
]);

Parameter Details

Members
AvailabilityZone
Type: string

The Availability Zone for the virtual private gateway.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Type
Required: Yes
Type: string

The type of VPN connection this virtual private gateway supports.

Result Syntax

[
    'VpnGateway' => [
        'AvailabilityZone' => '<string>',
        'State' => 'pending|available|deleting|deleted',
        'Tags' => [
            [
                'Key' => '<string>',
                'Value' => '<string>',
            ],
            // ...
        ],
        'Type' => 'ipsec.1',
        'VpcAttachments' => [
            [
                'State' => 'attaching|attached|detaching|detached',
                'VpcId' => '<string>',
            ],
            // ...
        ],
        'VpnGatewayId' => '<string>',
    ],
]

Result Details

Members
VpnGateway
Type: VpnGateway structure

Information about the virtual private gateway.

Errors

There are no errors described for this operation.

DeleteCustomerGateway

$result = $client->deleteCustomerGateway([/* ... */]);
$promise = $client->deleteCustomerGatewayAsync([/* ... */]);

Deletes the specified customer gateway. You must delete the VPN connection before you can delete the customer gateway.

Parameter Syntax

$result = $client->deleteCustomerGateway([
    'CustomerGatewayId' => '<string>', // REQUIRED
    'DryRun' => true || false,
]);

Parameter Details

Members
CustomerGatewayId
Required: Yes
Type: string

The ID of the customer gateway.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeleteDhcpOptions

$result = $client->deleteDhcpOptions([/* ... */]);
$promise = $client->deleteDhcpOptionsAsync([/* ... */]);

Deletes the specified set of DHCP options. You must disassociate the set of DHCP options before you can delete it. You can disassociate the set of DHCP options by associating either a new set of options or the default set of options with the VPC.

Parameter Syntax

$result = $client->deleteDhcpOptions([
    'DhcpOptionsId' => '<string>', // REQUIRED
    'DryRun' => true || false,
]);

Parameter Details

Members
DhcpOptionsId
Required: Yes
Type: string

The ID of the DHCP options set.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeleteFlowLogs

$result = $client->deleteFlowLogs([/* ... */]);
$promise = $client->deleteFlowLogsAsync([/* ... */]);

Deletes one or more flow logs.

Parameter Syntax

$result = $client->deleteFlowLogs([
    'FlowLogIds' => ['<string>', ...], // REQUIRED
]);

Parameter Details

Members
FlowLogIds
Required: Yes
Type: Array of strings

One or more flow log IDs.

Result Syntax

[
    'Unsuccessful' => [
        [
            'Error' => [
                'Code' => '<string>',
                'Message' => '<string>',
            ],
            'ResourceId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
Unsuccessful
Type: Array of UnsuccessfulItem structures

Information about the flow logs that could not be deleted successfully.

Errors

There are no errors described for this operation.

DeleteInternetGateway

$result = $client->deleteInternetGateway([/* ... */]);
$promise = $client->deleteInternetGatewayAsync([/* ... */]);

Deletes the specified Internet gateway. You must detach the Internet gateway from the VPC before you can delete it.

Parameter Syntax

$result = $client->deleteInternetGateway([
    'DryRun' => true || false,
    'InternetGatewayId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

InternetGatewayId
Required: Yes
Type: string

The ID of the Internet gateway.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeleteKeyPair

$result = $client->deleteKeyPair([/* ... */]);
$promise = $client->deleteKeyPairAsync([/* ... */]);

Deletes the specified key pair, by removing the public key from Amazon EC2.

Parameter Syntax

$result = $client->deleteKeyPair([
    'DryRun' => true || false,
    'KeyName' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

KeyName
Required: Yes
Type: string

The name of the key pair.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeleteNatGateway

$result = $client->deleteNatGateway([/* ... */]);
$promise = $client->deleteNatGatewayAsync([/* ... */]);

Deletes the specified NAT gateway. Deleting a NAT gateway disassociates its Elastic IP address, but does not release the address from your account. Deleting a NAT gateway does not delete any NAT gateway routes in your route tables.

Parameter Syntax

$result = $client->deleteNatGateway([
    'NatGatewayId' => '<string>', // REQUIRED
]);

Parameter Details

Members
NatGatewayId
Required: Yes
Type: string

The ID of the NAT gateway.

Result Syntax

[
    'NatGatewayId' => '<string>',
]

Result Details

Members
NatGatewayId
Type: string

The ID of the NAT gateway.

Errors

There are no errors described for this operation.

DeleteNetworkAcl

$result = $client->deleteNetworkAcl([/* ... */]);
$promise = $client->deleteNetworkAclAsync([/* ... */]);

Deletes the specified network ACL. You can't delete the ACL if it's associated with any subnets. You can't delete the default network ACL.

Parameter Syntax

$result = $client->deleteNetworkAcl([
    'DryRun' => true || false,
    'NetworkAclId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

NetworkAclId
Required: Yes
Type: string

The ID of the network ACL.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeleteNetworkAclEntry

$result = $client->deleteNetworkAclEntry([/* ... */]);
$promise = $client->deleteNetworkAclEntryAsync([/* ... */]);

Deletes the specified ingress or egress entry (rule) from the specified network ACL.

Parameter Syntax

$result = $client->deleteNetworkAclEntry([
    'DryRun' => true || false,
    'Egress' => true || false, // REQUIRED
    'NetworkAclId' => '<string>', // REQUIRED
    'RuleNumber' => <integer>, // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Egress
Required: Yes
Type: boolean

Indicates whether the rule is an egress rule.

NetworkAclId
Required: Yes
Type: string

The ID of the network ACL.

RuleNumber
Required: Yes
Type: int

The rule number of the entry to delete.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeleteNetworkInterface

$result = $client->deleteNetworkInterface([/* ... */]);
$promise = $client->deleteNetworkInterfaceAsync([/* ... */]);

Deletes the specified network interface. You must detach the network interface before you can delete it.

Parameter Syntax

$result = $client->deleteNetworkInterface([
    'DryRun' => true || false,
    'NetworkInterfaceId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

NetworkInterfaceId
Required: Yes
Type: string

The ID of the network interface.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeletePlacementGroup

$result = $client->deletePlacementGroup([/* ... */]);
$promise = $client->deletePlacementGroupAsync([/* ... */]);

Deletes the specified placement group. You must terminate all instances in the placement group before you can delete the placement group. For more information about placement groups and cluster instances, see Cluster Instances in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->deletePlacementGroup([
    'DryRun' => true || false,
    'GroupName' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

GroupName
Required: Yes
Type: string

The name of the placement group.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeleteRoute

$result = $client->deleteRoute([/* ... */]);
$promise = $client->deleteRouteAsync([/* ... */]);

Deletes the specified route from the specified route table.

Parameter Syntax

$result = $client->deleteRoute([
    'DestinationCidrBlock' => '<string>', // REQUIRED
    'DryRun' => true || false,
    'RouteTableId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DestinationCidrBlock
Required: Yes
Type: string

The CIDR range for the route. The value you specify must match the CIDR for the route exactly.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

RouteTableId
Required: Yes
Type: string

The ID of the route table.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeleteRouteTable

$result = $client->deleteRouteTable([/* ... */]);
$promise = $client->deleteRouteTableAsync([/* ... */]);

Deletes the specified route table. You must disassociate the route table from any subnets before you can delete it. You can't delete the main route table.

Parameter Syntax

$result = $client->deleteRouteTable([
    'DryRun' => true || false,
    'RouteTableId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

RouteTableId
Required: Yes
Type: string

The ID of the route table.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeleteSecurityGroup

$result = $client->deleteSecurityGroup([/* ... */]);
$promise = $client->deleteSecurityGroupAsync([/* ... */]);

Deletes a security group.

If you attempt to delete a security group that is associated with an instance, or is referenced by another security group, the operation fails with InvalidGroup.InUse in EC2-Classic or DependencyViolation in EC2-VPC.

Parameter Syntax

$result = $client->deleteSecurityGroup([
    'DryRun' => true || false,
    'GroupId' => '<string>',
    'GroupName' => '<string>',
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

GroupId
Type: string

The ID of the security group. Required for a nondefault VPC.

GroupName
Type: string

[EC2-Classic, default VPC] The name of the security group. You can specify either the security group name or the security group ID.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeleteSnapshot

$result = $client->deleteSnapshot([/* ... */]);
$promise = $client->deleteSnapshotAsync([/* ... */]);

Deletes the specified snapshot.

When you make periodic snapshots of a volume, the snapshots are incremental, and only the blocks on the device that have changed since your last snapshot are saved in the new snapshot. When you delete a snapshot, only the data not needed for any other snapshot is removed. So regardless of which prior snapshots have been deleted, all active snapshots will have access to all the information needed to restore the volume.

You cannot delete a snapshot of the root device of an EBS volume used by a registered AMI. You must first de-register the AMI before you can delete the snapshot.

For more information, see Deleting an Amazon EBS Snapshot in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->deleteSnapshot([
    'DryRun' => true || false,
    'SnapshotId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

SnapshotId
Required: Yes
Type: string

The ID of the EBS snapshot.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeleteSpotDatafeedSubscription

$result = $client->deleteSpotDatafeedSubscription([/* ... */]);
$promise = $client->deleteSpotDatafeedSubscriptionAsync([/* ... */]);

Deletes the data feed for Spot instances.

Parameter Syntax

$result = $client->deleteSpotDatafeedSubscription([
    'DryRun' => true || false,
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeleteSubnet

$result = $client->deleteSubnet([/* ... */]);
$promise = $client->deleteSubnetAsync([/* ... */]);

Deletes the specified subnet. You must terminate all running instances in the subnet before you can delete the subnet.

Parameter Syntax

$result = $client->deleteSubnet([
    'DryRun' => true || false,
    'SubnetId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

SubnetId
Required: Yes
Type: string

The ID of the subnet.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeleteTags

$result = $client->deleteTags([/* ... */]);
$promise = $client->deleteTagsAsync([/* ... */]);

Deletes the specified set of tags from the specified set of resources. This call is designed to follow a DescribeTags request.

For more information about tags, see Tagging Your Resources in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->deleteTags([
    'DryRun' => true || false,
    'Resources' => ['<string>', ...], // REQUIRED
    'Tags' => [
        [
            'Key' => '<string>',
            'Value' => '<string>',
        ],
        // ...
    ],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Resources
Required: Yes
Type: Array of strings

The ID of the resource. For example, ami-1a2b3c4d. You can specify more than one resource ID.

Tags
Type: Array of Tag structures

One or more tags to delete. If you omit the value parameter, we delete the tag regardless of its value. If you specify this parameter with an empty string as the value, we delete the key only if its value is an empty string.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeleteVolume

$result = $client->deleteVolume([/* ... */]);
$promise = $client->deleteVolumeAsync([/* ... */]);

Deletes the specified EBS volume. The volume must be in the available state (not attached to an instance).

The volume may remain in the deleting state for several minutes.

For more information, see Deleting an Amazon EBS Volume in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->deleteVolume([
    'DryRun' => true || false,
    'VolumeId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VolumeId
Required: Yes
Type: string

The ID of the volume.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeleteVpc

$result = $client->deleteVpc([/* ... */]);
$promise = $client->deleteVpcAsync([/* ... */]);

Deletes the specified VPC. You must detach or delete all gateways and resources that are associated with the VPC before you can delete it. For example, you must terminate all instances running in the VPC, delete all security groups associated with the VPC (except the default one), delete all route tables associated with the VPC (except the default one), and so on.

Parameter Syntax

$result = $client->deleteVpc([
    'DryRun' => true || false,
    'VpcId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VpcId
Required: Yes
Type: string

The ID of the VPC.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeleteVpcEndpoints

$result = $client->deleteVpcEndpoints([/* ... */]);
$promise = $client->deleteVpcEndpointsAsync([/* ... */]);

Deletes one or more specified VPC endpoints. Deleting the endpoint also deletes the endpoint routes in the route tables that were associated with the endpoint.

Parameter Syntax

$result = $client->deleteVpcEndpoints([
    'DryRun' => true || false,
    'VpcEndpointIds' => ['<string>', ...], // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VpcEndpointIds
Required: Yes
Type: Array of strings

One or more endpoint IDs.

Result Syntax

[
    'Unsuccessful' => [
        [
            'Error' => [
                'Code' => '<string>',
                'Message' => '<string>',
            ],
            'ResourceId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
Unsuccessful
Type: Array of UnsuccessfulItem structures

Information about the endpoints that were not successfully deleted.

Errors

There are no errors described for this operation.

DeleteVpcPeeringConnection

$result = $client->deleteVpcPeeringConnection([/* ... */]);
$promise = $client->deleteVpcPeeringConnectionAsync([/* ... */]);

Deletes a VPC peering connection. Either the owner of the requester VPC or the owner of the peer VPC can delete the VPC peering connection if it's in the active state. The owner of the requester VPC can delete a VPC peering connection in the pending-acceptance state.

Parameter Syntax

$result = $client->deleteVpcPeeringConnection([
    'DryRun' => true || false,
    'VpcPeeringConnectionId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VpcPeeringConnectionId
Required: Yes
Type: string

The ID of the VPC peering connection.

Result Syntax

[
    'Return' => true || false,
]

Result Details

Members
Return
Type: boolean

Returns true if the request succeeds; otherwise, it returns an error.

Errors

There are no errors described for this operation.

DeleteVpnConnection

$result = $client->deleteVpnConnection([/* ... */]);
$promise = $client->deleteVpnConnectionAsync([/* ... */]);

Deletes the specified VPN connection.

If you're deleting the VPC and its associated components, we recommend that you detach the virtual private gateway from the VPC and delete the VPC before deleting the VPN connection. If you believe that the tunnel credentials for your VPN connection have been compromised, you can delete the VPN connection and create a new one that has new keys, without needing to delete the VPC or virtual private gateway. If you create a new VPN connection, you must reconfigure the customer gateway using the new configuration information returned with the new VPN connection ID.

Parameter Syntax

$result = $client->deleteVpnConnection([
    'DryRun' => true || false,
    'VpnConnectionId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VpnConnectionId
Required: Yes
Type: string

The ID of the VPN connection.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeleteVpnConnectionRoute

$result = $client->deleteVpnConnectionRoute([/* ... */]);
$promise = $client->deleteVpnConnectionRouteAsync([/* ... */]);

Deletes the specified static route associated with a VPN connection between an existing virtual private gateway and a VPN customer gateway. The static route allows traffic to be routed from the virtual private gateway to the VPN customer gateway.

Parameter Syntax

$result = $client->deleteVpnConnectionRoute([
    'DestinationCidrBlock' => '<string>', // REQUIRED
    'VpnConnectionId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DestinationCidrBlock
Required: Yes
Type: string

The CIDR block associated with the local subnet of the customer network.

VpnConnectionId
Required: Yes
Type: string

The ID of the VPN connection.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeleteVpnGateway

$result = $client->deleteVpnGateway([/* ... */]);
$promise = $client->deleteVpnGatewayAsync([/* ... */]);

Deletes the specified virtual private gateway. We recommend that before you delete a virtual private gateway, you detach it from the VPC and delete the VPN connection. Note that you don't need to delete the virtual private gateway if you plan to delete and recreate the VPN connection between your VPC and your network.

Parameter Syntax

$result = $client->deleteVpnGateway([
    'DryRun' => true || false,
    'VpnGatewayId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VpnGatewayId
Required: Yes
Type: string

The ID of the virtual private gateway.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DeregisterImage

$result = $client->deregisterImage([/* ... */]);
$promise = $client->deregisterImageAsync([/* ... */]);

Deregisters the specified AMI. After you deregister an AMI, it can't be used to launch new instances.

This command does not delete the AMI.

Parameter Syntax

$result = $client->deregisterImage([
    'DryRun' => true || false,
    'ImageId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

ImageId
Required: Yes
Type: string

The ID of the AMI.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DescribeAccountAttributes

$result = $client->describeAccountAttributes([/* ... */]);
$promise = $client->describeAccountAttributesAsync([/* ... */]);

Describes attributes of your AWS account. The following are the supported account attributes:

  • supported-platforms: Indicates whether your account can launch instances into EC2-Classic and EC2-VPC, or only into EC2-VPC.

  • default-vpc: The ID of the default VPC for your account, or none.

  • max-instances: The maximum number of On-Demand instances that you can run.

  • vpc-max-security-groups-per-interface: The maximum number of security groups that you can assign to a network interface.

  • max-elastic-ips: The maximum number of Elastic IP addresses that you can allocate for use with EC2-Classic.

  • vpc-max-elastic-ips: The maximum number of Elastic IP addresses that you can allocate for use with EC2-VPC.

Parameter Syntax

$result = $client->describeAccountAttributes([
    'AttributeNames' => ['<string>', ...],
    'DryRun' => true || false,
]);

Parameter Details

Members
AttributeNames
Type: Array of strings

One or more account attribute names.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Result Syntax

[
    'AccountAttributes' => [
        [
            'AttributeName' => '<string>',
            'AttributeValues' => [
                [
                    'AttributeValue' => '<string>',
                ],
                // ...
            ],
        ],
        // ...
    ],
]

Result Details

Members
AccountAttributes
Type: Array of AccountAttribute structures

Information about one or more account attributes.

Errors

There are no errors described for this operation.

DescribeAddresses

$result = $client->describeAddresses([/* ... */]);
$promise = $client->describeAddressesAsync([/* ... */]);

Describes one or more of your Elastic IP addresses.

An Elastic IP address is for use in either the EC2-Classic platform or in a VPC. For more information, see Elastic IP Addresses in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->describeAddresses([
    'AllocationIds' => ['<string>', ...],
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'PublicIps' => ['<string>', ...],
]);

Parameter Details

Members
AllocationIds
Type: Array of strings

[EC2-VPC] One or more allocation IDs.

Default: Describes all your Elastic IP addresses.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters. Filter names and values are case-sensitive.

  • allocation-id - [EC2-VPC] The allocation ID for the address.

  • association-id - [EC2-VPC] The association ID for the address.

  • domain - Indicates whether the address is for use in EC2-Classic (standard) or in a VPC (vpc).

  • instance-id - The ID of the instance the address is associated with, if any.

  • network-interface-id - [EC2-VPC] The ID of the network interface that the address is associated with, if any.

  • network-interface-owner-id - The AWS account ID of the owner.

  • private-ip-address - [EC2-VPC] The private IP address associated with the Elastic IP address.

  • public-ip - The Elastic IP address.

PublicIps
Type: Array of strings

[EC2-Classic] One or more Elastic IP addresses.

Default: Describes all your Elastic IP addresses.

Result Syntax

[
    'Addresses' => [
        [
            'AllocationId' => '<string>',
            'AssociationId' => '<string>',
            'Domain' => 'vpc|standard',
            'InstanceId' => '<string>',
            'NetworkInterfaceId' => '<string>',
            'NetworkInterfaceOwnerId' => '<string>',
            'PrivateIpAddress' => '<string>',
            'PublicIp' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
Addresses
Type: Array of Address structures

Information about one or more Elastic IP addresses.

Errors

There are no errors described for this operation.

DescribeAvailabilityZones

$result = $client->describeAvailabilityZones([/* ... */]);
$promise = $client->describeAvailabilityZonesAsync([/* ... */]);

Describes one or more of the Availability Zones that are available to you. The results include zones only for the region you're currently using. If there is an event impacting an Availability Zone, you can use this request to view the state and any provided message for that Availability Zone.

For more information, see Regions and Availability Zones in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->describeAvailabilityZones([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'ZoneNames' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • message - Information about the Availability Zone.

  • region-name - The name of the region for the Availability Zone (for example, us-east-1).

  • state - The state of the Availability Zone (available | information | impaired | unavailable).

  • zone-name - The name of the Availability Zone (for example, us-east-1a).

ZoneNames
Type: Array of strings

The names of one or more Availability Zones.

Result Syntax

[
    'AvailabilityZones' => [
        [
            'Messages' => [
                [
                    'Message' => '<string>',
                ],
                // ...
            ],
            'RegionName' => '<string>',
            'State' => 'available|information|impaired|unavailable',
            'ZoneName' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
AvailabilityZones
Type: Array of AvailabilityZone structures

Information about one or more Availability Zones.

Errors

There are no errors described for this operation.

DescribeBundleTasks

$result = $client->describeBundleTasks([/* ... */]);
$promise = $client->describeBundleTasksAsync([/* ... */]);

Describes one or more of your bundling tasks.

Completed bundle tasks are listed for only a limited time. If your bundle task is no longer in the list, you can still register an AMI from it. Just use RegisterImage with the Amazon S3 bucket name and image manifest name you provided to the bundle task.

Parameter Syntax

$result = $client->describeBundleTasks([
    'BundleIds' => ['<string>', ...],
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
]);

Parameter Details

Members
BundleIds
Type: Array of strings

One or more bundle task IDs.

Default: Describes all your bundle tasks.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • bundle-id - The ID of the bundle task.

  • error-code - If the task failed, the error code returned.

  • error-message - If the task failed, the error message returned.

  • instance-id - The ID of the instance.

  • progress - The level of task completion, as a percentage (for example, 20%).

  • s3-bucket - The Amazon S3 bucket to store the AMI.

  • s3-prefix - The beginning of the AMI name.

  • start-time - The time the task started (for example, 2013-09-15T17:15:20.000Z).

  • state - The state of the task (pending | waiting-for-shutdown | bundling | storing | cancelling | complete | failed).

  • update-time - The time of the most recent update for the task.

Result Syntax

[
    'BundleTasks' => [
        [
            'BundleId' => '<string>',
            'BundleTaskError' => [
                'Code' => '<string>',
                'Message' => '<string>',
            ],
            'InstanceId' => '<string>',
            'Progress' => '<string>',
            'StartTime' => <DateTime>,
            'State' => 'pending|waiting-for-shutdown|bundling|storing|cancelling|complete|failed',
            'Storage' => [
                'S3' => [
                    'AWSAccessKeyId' => '<string>',
                    'Bucket' => '<string>',
                    'Prefix' => '<string>',
                    'UploadPolicy' => <string || resource || Psr\Http\Message\StreamInterface>,
                    'UploadPolicySignature' => '<string>',
                ],
            ],
            'UpdateTime' => <DateTime>,
        ],
        // ...
    ],
]

Result Details

Members
BundleTasks
Type: Array of BundleTask structures

Information about one or more bundle tasks.

Errors

There are no errors described for this operation.

DescribeClassicLinkInstances

$result = $client->describeClassicLinkInstances([/* ... */]);
$promise = $client->describeClassicLinkInstancesAsync([/* ... */]);

Describes one or more of your linked EC2-Classic instances. This request only returns information about EC2-Classic instances linked to a VPC through ClassicLink; you cannot use this request to return information about other instances.

Parameter Syntax

$result = $client->describeClassicLinkInstances([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'InstanceIds' => ['<string>', ...],
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • group-id - The ID of a VPC security group that's associated with the instance.

  • instance-id - The ID of the instance.

  • tag:key=value - The key/value combination of a tag assigned to the resource.

  • tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag:key=value filter.

  • tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.

  • vpc-id - The ID of the VPC that the instance is linked to.

InstanceIds
Type: Array of strings

One or more instance IDs. Must be instances linked to a VPC through ClassicLink.

MaxResults
Type: int

The maximum number of results to return for the request in a single page. The remaining results of the initial request can be seen by sending another request with the returned NextToken value. This value can be between 5 and 1000; if MaxResults is given a value larger than 1000, only 1000 results are returned. You cannot specify this parameter and the instance IDs parameter in the same request.

Constraint: If the value is greater than 1000, we return only 1000 items.

NextToken
Type: string

The token to retrieve the next page of results.

Result Syntax

[
    'Instances' => [
        [
            'Groups' => [
                [
                    'GroupId' => '<string>',
                    'GroupName' => '<string>',
                ],
                // ...
            ],
            'InstanceId' => '<string>',
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'VpcId' => '<string>',
        ],
        // ...
    ],
    'NextToken' => '<string>',
]

Result Details

Members
Instances
Type: Array of ClassicLinkInstance structures

Information about one or more linked EC2-Classic instances.

NextToken
Type: string

The token to use to retrieve the next page of results. This value is null when there are no more results to return.

Errors

There are no errors described for this operation.

DescribeConversionTasks

$result = $client->describeConversionTasks([/* ... */]);
$promise = $client->describeConversionTasksAsync([/* ... */]);

Describes one or more of your conversion tasks. For more information, see Using the Command Line Tools to Import Your Virtual Machine to Amazon EC2 in the Amazon Elastic Compute Cloud User Guide.

For information about the import manifest referenced by this API action, see VM Import Manifest.

Parameter Syntax

$result = $client->describeConversionTasks([
    'ConversionTaskIds' => ['<string>', ...],
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
]);

Parameter Details

Members
ConversionTaskIds
Type: Array of strings

One or more conversion task IDs.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

Result Syntax

[
    'ConversionTasks' => [
        [
            'ConversionTaskId' => '<string>',
            'ExpirationTime' => '<string>',
            'ImportInstance' => [
                'Description' => '<string>',
                'InstanceId' => '<string>',
                'Platform' => 'Windows',
                'Volumes' => [
                    [
                        'AvailabilityZone' => '<string>',
                        'BytesConverted' => <integer>,
                        'Description' => '<string>',
                        'Image' => [
                            'Checksum' => '<string>',
                            'Format' => 'VMDK|RAW|VHD',
                            'ImportManifestUrl' => '<string>',
                            'Size' => <integer>,
                        ],
                        'Status' => '<string>',
                        'StatusMessage' => '<string>',
                        'Volume' => [
                            'Id' => '<string>',
                            'Size' => <integer>,
                        ],
                    ],
                    // ...
                ],
            ],
            'ImportVolume' => [
                'AvailabilityZone' => '<string>',
                'BytesConverted' => <integer>,
                'Description' => '<string>',
                'Image' => [
                    'Checksum' => '<string>',
                    'Format' => 'VMDK|RAW|VHD',
                    'ImportManifestUrl' => '<string>',
                    'Size' => <integer>,
                ],
                'Volume' => [
                    'Id' => '<string>',
                    'Size' => <integer>,
                ],
            ],
            'State' => 'active|cancelling|cancelled|completed',
            'StatusMessage' => '<string>',
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
        ],
        // ...
    ],
]

Result Details

Members
ConversionTasks
Type: Array of ConversionTask structures

Information about the conversion tasks.

Errors

There are no errors described for this operation.

DescribeCustomerGateways

$result = $client->describeCustomerGateways([/* ... */]);
$promise = $client->describeCustomerGatewaysAsync([/* ... */]);

Describes one or more of your VPN customer gateways.

For more information about VPN customer gateways, see Adding a Hardware Virtual Private Gateway to Your VPC in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->describeCustomerGateways([
    'CustomerGatewayIds' => ['<string>', ...],
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
]);

Parameter Details

Members
CustomerGatewayIds
Type: Array of strings

One or more customer gateway IDs.

Default: Describes all your customer gateways.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • bgp-asn - The customer gateway's Border Gateway Protocol (BGP) Autonomous System Number (ASN).

  • customer-gateway-id - The ID of the customer gateway.

  • ip-address - The IP address of the customer gateway's Internet-routable external interface.

  • state - The state of the customer gateway (pending | available | deleting | deleted).

  • type - The type of customer gateway. Currently, the only supported type is ipsec.1.

  • tag:key=value - The key/value combination of a tag assigned to the resource.

  • tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag:key=value filter.

  • tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.

Result Syntax

[
    'CustomerGateways' => [
        [
            'BgpAsn' => '<string>',
            'CustomerGatewayId' => '<string>',
            'IpAddress' => '<string>',
            'State' => '<string>',
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'Type' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
CustomerGateways
Type: Array of CustomerGateway structures

Information about one or more customer gateways.

Errors

There are no errors described for this operation.

DescribeDhcpOptions

$result = $client->describeDhcpOptions([/* ... */]);
$promise = $client->describeDhcpOptionsAsync([/* ... */]);

Describes one or more of your DHCP options sets.

For more information about DHCP options sets, see DHCP Options Sets in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->describeDhcpOptions([
    'DhcpOptionsIds' => ['<string>', ...],
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
]);

Parameter Details

Members
DhcpOptionsIds
Type: Array of strings

The IDs of one or more DHCP options sets.

Default: Describes all your DHCP options sets.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • dhcp-options-id - The ID of a set of DHCP options.

  • key - The key for one of the options (for example, domain-name).

  • value - The value for one of the options.

  • tag:key=value - The key/value combination of a tag assigned to the resource.

  • tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag:key=value filter.

  • tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.

Result Syntax

[
    'DhcpOptions' => [
        [
            'DhcpConfigurations' => [
                [
                    'Key' => '<string>',
                    'Values' => [
                        [
                            'Value' => '<string>',
                        ],
                        // ...
                    ],
                ],
                // ...
            ],
            'DhcpOptionsId' => '<string>',
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
        ],
        // ...
    ],
]

Result Details

Members
DhcpOptions
Type: Array of DhcpOptions structures

Information about one or more DHCP options sets.

Errors

There are no errors described for this operation.

DescribeExportTasks

$result = $client->describeExportTasks([/* ... */]);
$promise = $client->describeExportTasksAsync([/* ... */]);

Describes one or more of your export tasks.

Parameter Syntax

$result = $client->describeExportTasks([
    'ExportTaskIds' => ['<string>', ...],
]);

Parameter Details

Members
ExportTaskIds
Type: Array of strings

One or more export task IDs.

Result Syntax

[
    'ExportTasks' => [
        [
            'Description' => '<string>',
            'ExportTaskId' => '<string>',
            'ExportToS3Task' => [
                'ContainerFormat' => 'ova',
                'DiskImageFormat' => 'VMDK|RAW|VHD',
                'S3Bucket' => '<string>',
                'S3Key' => '<string>',
            ],
            'InstanceExportDetails' => [
                'InstanceId' => '<string>',
                'TargetEnvironment' => 'citrix|vmware|microsoft',
            ],
            'State' => 'active|cancelling|cancelled|completed',
            'StatusMessage' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
ExportTasks
Type: Array of ExportTask structures

Information about the export tasks.

Errors

There are no errors described for this operation.

DescribeFlowLogs

$result = $client->describeFlowLogs([/* ... */]);
$promise = $client->describeFlowLogsAsync([/* ... */]);

Describes one or more flow logs. To view the information in your flow logs (the log streams for the network interfaces), you must use the CloudWatch Logs console or the CloudWatch Logs API.

Parameter Syntax

$result = $client->describeFlowLogs([
    'Filter' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'FlowLogIds' => ['<string>', ...],
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
]);

Parameter Details

Members
Filter
Type: Array of Filter structures

One or more filters.

  • deliver-log-status - The status of the logs delivery (SUCCESS | FAILED).

  • flow-log-id - The ID of the flow log.

  • log-group-name - The name of the log group.

  • resource-id - The ID of the VPC, subnet, or network interface.

  • traffic-type - The type of traffic (ACCEPT | REJECT | ALL)

FlowLogIds
Type: Array of strings

One or more flow log IDs.

MaxResults
Type: int

The maximum number of results to return for the request in a single page. The remaining results can be seen by sending another request with the returned NextToken value. This value can be between 5 and 1000; if MaxResults is given a value larger than 1000, only 1000 results are returned. You cannot specify this parameter and the flow log IDs parameter in the same request.

NextToken
Type: string

The token to retrieve the next page of results.

Result Syntax

[
    'FlowLogs' => [
        [
            'CreationTime' => <DateTime>,
            'DeliverLogsErrorMessage' => '<string>',
            'DeliverLogsPermissionArn' => '<string>',
            'DeliverLogsStatus' => '<string>',
            'FlowLogId' => '<string>',
            'FlowLogStatus' => '<string>',
            'LogGroupName' => '<string>',
            'ResourceId' => '<string>',
            'TrafficType' => 'ACCEPT|REJECT|ALL',
        ],
        // ...
    ],
    'NextToken' => '<string>',
]

Result Details

Members
FlowLogs
Type: Array of FlowLog structures

Information about the flow logs.

NextToken
Type: string

The token to use to retrieve the next page of results. This value is null when there are no more results to return.

Errors

There are no errors described for this operation.

DescribeHosts

$result = $client->describeHosts([/* ... */]);
$promise = $client->describeHostsAsync([/* ... */]);

Describes one or more of your Dedicated hosts.

The results describe only the Dedicated hosts in the region you're currently using. All listed instances consume capacity on your Dedicated host. Dedicated hosts that have recently been released will be listed with the state released.

Parameter Syntax

$result = $client->describeHosts([
    'Filter' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'HostIds' => ['<string>', ...],
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
]);

Parameter Details

Members
Filter
Type: Array of Filter structures

One or more filters.

  • instance-type - The instance type size that the Dedicated host is configured to support.

  • auto-placement - Whether auto-placement is enabled or disabled (on | off).

  • host-reservation-id - The ID of the reservation associated with this host.

  • client-token - The idempotency token you provided when you launched the instance

  • state- The allocation state of the Dedicated host (available | under-assessment | permanent-failure | released | released-permanent-failure).

  • availability-zone - The Availability Zone of the host.

HostIds
Type: Array of strings

The IDs of the Dedicated hosts. The IDs are used for targeted instance launches.

MaxResults
Type: int

The maximum number of results to return for the request in a single page. The remaining results can be seen by sending another request with the returned nextToken value. This value can be between 5 and 500; if maxResults is given a larger value than 500, you will receive an error. You cannot specify this parameter and the host IDs parameter in the same request.

NextToken
Type: string

The token to retrieve the next page of results.

Result Syntax

[
    'Hosts' => [
        [
            'AutoPlacement' => 'on|off',
            'AvailabilityZone' => '<string>',
            'AvailableCapacity' => [
                'AvailableInstanceCapacity' => [
                    [
                        'AvailableCapacity' => <integer>,
                        'InstanceType' => '<string>',
                        'TotalCapacity' => <integer>,
                    ],
                    // ...
                ],
                'AvailableVCpus' => <integer>,
            ],
            'ClientToken' => '<string>',
            'HostId' => '<string>',
            'HostProperties' => [
                'Cores' => <integer>,
                'InstanceType' => '<string>',
                'Sockets' => <integer>,
                'TotalVCpus' => <integer>,
            ],
            'HostReservationId' => '<string>',
            'Instances' => [
                [
                    'InstanceId' => '<string>',
                    'InstanceType' => '<string>',
                ],
                // ...
            ],
            'State' => 'available|under-assessment|permanent-failure|released|released-permanent-failure',
        ],
        // ...
    ],
    'NextToken' => '<string>',
]

Result Details

Members
Hosts
Type: Array of Host structures

Information about the Dedicated hosts.

NextToken
Type: string

The token to use to retrieve the next page of results. This value is null when there are no more results to return.

Errors

There are no errors described for this operation.

DescribeIdFormat

$result = $client->describeIdFormat([/* ... */]);
$promise = $client->describeIdFormatAsync([/* ... */]);

Describes the ID format settings for your resources on a per-region basis, for example, to view which resource types are enabled for longer IDs. This request only returns information about resource types whose ID formats can be modified; it does not return information about other resource types.

The following resource types support longer IDs: instance | reservation | snapshot | volume.

These settings apply to the IAM user who makes the request; they do not apply to the entire AWS account. By default, an IAM user defaults to the same settings as the root user, unless they explicitly override the settings by running the ModifyIdFormat command. Resources created with longer IDs are visible to all IAM users, regardless of these settings and provided that they have permission to use the relevant Describe command for the resource type.

Parameter Syntax

$result = $client->describeIdFormat([
    'Resource' => '<string>',
]);

Parameter Details

Members
Resource
Type: string

The type of resource.

Result Syntax

[
    'Statuses' => [
        [
            'Deadline' => <DateTime>,
            'Resource' => '<string>',
            'UseLongIds' => true || false,
        ],
        // ...
    ],
]

Result Details

Members
Statuses
Type: Array of IdFormat structures

Information about the ID format for the resource.

Errors

There are no errors described for this operation.

DescribeImageAttribute

$result = $client->describeImageAttribute([/* ... */]);
$promise = $client->describeImageAttributeAsync([/* ... */]);

Describes the specified attribute of the specified AMI. You can specify only one attribute at a time.

Parameter Syntax

$result = $client->describeImageAttribute([
    'Attribute' => 'description|kernel|ramdisk|launchPermission|productCodes|blockDeviceMapping|sriovNetSupport', // REQUIRED
    'DryRun' => true || false,
    'ImageId' => '<string>', // REQUIRED
]);

Parameter Details

Members
Attribute
Required: Yes
Type: string

The AMI attribute.

Note: Depending on your account privileges, the blockDeviceMapping attribute may return a Client.AuthFailure error. If this happens, use DescribeImages to get information about the block device mapping for the AMI.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

ImageId
Required: Yes
Type: string

The ID of the AMI.

Result Syntax

[
    'BlockDeviceMappings' => [
        [
            'DeviceName' => '<string>',
            'Ebs' => [
                'DeleteOnTermination' => true || false,
                'Encrypted' => true || false,
                'Iops' => <integer>,
                'SnapshotId' => '<string>',
                'VolumeSize' => <integer>,
                'VolumeType' => 'standard|io1|gp2|sc1|st1',
            ],
            'NoDevice' => '<string>',
            'VirtualName' => '<string>',
        ],
        // ...
    ],
    'Description' => [
        'Value' => '<string>',
    ],
    'ImageId' => '<string>',
    'KernelId' => [
        'Value' => '<string>',
    ],
    'LaunchPermissions' => [
        [
            'Group' => 'all',
            'UserId' => '<string>',
        ],
        // ...
    ],
    'ProductCodes' => [
        [
            'ProductCodeId' => '<string>',
            'ProductCodeType' => 'devpay|marketplace',
        ],
        // ...
    ],
    'RamdiskId' => [
        'Value' => '<string>',
    ],
    'SriovNetSupport' => [
        'Value' => '<string>',
    ],
]

Result Details

Members
BlockDeviceMappings
Type: Array of BlockDeviceMapping structures

One or more block device mapping entries.

Description
Type: AttributeValue structure

A description for the AMI.

ImageId
Type: string

The ID of the AMI.

KernelId
Type: AttributeValue structure

The kernel ID.

LaunchPermissions
Type: Array of LaunchPermission structures

One or more launch permissions.

ProductCodes
Type: Array of ProductCode structures

One or more product codes.

RamdiskId
Type: AttributeValue structure

The RAM disk ID.

SriovNetSupport
Type: AttributeValue structure

The value to use for a resource attribute.

Errors

There are no errors described for this operation.

DescribeImages

$result = $client->describeImages([/* ... */]);
$promise = $client->describeImagesAsync([/* ... */]);

Describes one or more of the images (AMIs, AKIs, and ARIs) available to you. Images available to you include public images, private images that you own, and private images owned by other AWS accounts but for which you have explicit launch permissions.

Deregistered images are included in the returned results for an unspecified interval after deregistration.

Parameter Syntax

$result = $client->describeImages([
    'DryRun' => true || false,
    'ExecutableUsers' => ['<string>', ...],
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'ImageIds' => ['<string>', ...],
    'Owners' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

ExecutableUsers
Type: Array of strings

Scopes the images by users with explicit launch permissions. Specify an AWS account ID, self (the sender of the request), or all (public AMIs).

Filters
Type: Array of Filter structures

One or more filters.

  • architecture - The image architecture (i386 | x86_64).

  • block-device-mapping.delete-on-termination - A Boolean value that indicates whether the Amazon EBS volume is deleted on instance termination.

  • block-device-mapping.device-name - The device name for the EBS volume (for example, /dev/sdh).

  • block-device-mapping.snapshot-id - The ID of the snapshot used for the EBS volume.

  • block-device-mapping.volume-size - The volume size of the EBS volume, in GiB.

  • block-device-mapping.volume-type - The volume type of the EBS volume (gp2 | io1 | st1 | sc1 | standard).

  • description - The description of the image (provided during image creation).

  • hypervisor - The hypervisor type (ovm | xen).

  • image-id - The ID of the image.

  • image-type - The image type (machine | kernel | ramdisk).

  • is-public - A Boolean that indicates whether the image is public.

  • kernel-id - The kernel ID.

  • manifest-location - The location of the image manifest.

  • name - The name of the AMI (provided during image creation).

  • owner-alias - The AWS account alias (for example, amazon).

  • owner-id - The AWS account ID of the image owner.

  • platform - The platform. To only list Windows-based AMIs, use windows.

  • product-code - The product code.

  • product-code.type - The type of the product code (devpay | marketplace).

  • ramdisk-id - The RAM disk ID.

  • root-device-name - The name of the root device volume (for example, /dev/sda1).

  • root-device-type - The type of the root device volume (ebs | instance-store).

  • state - The state of the image (available | pending | failed).

  • state-reason-code - The reason code for the state change.

  • state-reason-message - The message for the state change.

  • tag:key=value - The key/value combination of a tag assigned to the resource.

  • tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag:key=value filter.

  • tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.

  • virtualization-type - The virtualization type (paravirtual | hvm).

ImageIds
Type: Array of strings

One or more image IDs.

Default: Describes all images available to you.

Owners
Type: Array of strings

Filters the images by the owner. Specify an AWS account ID, amazon (owner is Amazon), aws-marketplace (owner is AWS Marketplace), self (owner is the sender of the request). Omitting this option returns all images for which you have launch permissions, regardless of ownership.

Result Syntax

[
    'Images' => [
        [
            'Architecture' => 'i386|x86_64',
            'BlockDeviceMappings' => [
                [
                    'DeviceName' => '<string>',
                    'Ebs' => [
                        'DeleteOnTermination' => true || false,
                        'Encrypted' => true || false,
                        'Iops' => <integer>,
                        'SnapshotId' => '<string>',
                        'VolumeSize' => <integer>,
                        'VolumeType' => 'standard|io1|gp2|sc1|st1',
                    ],
                    'NoDevice' => '<string>',
                    'VirtualName' => '<string>',
                ],
                // ...
            ],
            'CreationDate' => '<string>',
            'Description' => '<string>',
            'Hypervisor' => 'ovm|xen',
            'ImageId' => '<string>',
            'ImageLocation' => '<string>',
            'ImageOwnerAlias' => '<string>',
            'ImageType' => 'machine|kernel|ramdisk',
            'KernelId' => '<string>',
            'Name' => '<string>',
            'OwnerId' => '<string>',
            'Platform' => 'Windows',
            'ProductCodes' => [
                [
                    'ProductCodeId' => '<string>',
                    'ProductCodeType' => 'devpay|marketplace',
                ],
                // ...
            ],
            'Public' => true || false,
            'RamdiskId' => '<string>',
            'RootDeviceName' => '<string>',
            'RootDeviceType' => 'ebs|instance-store',
            'SriovNetSupport' => '<string>',
            'State' => 'pending|available|invalid|deregistered|transient|failed|error',
            'StateReason' => [
                'Code' => '<string>',
                'Message' => '<string>',
            ],
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'VirtualizationType' => 'hvm|paravirtual',
        ],
        // ...
    ],
]

Result Details

Members
Images
Type: Array of Image structures

Information about one or more images.

Errors

There are no errors described for this operation.

DescribeImportImageTasks

$result = $client->describeImportImageTasks([/* ... */]);
$promise = $client->describeImportImageTasksAsync([/* ... */]);

Displays details about an import virtual machine or import snapshot tasks that are already created.

Parameter Syntax

$result = $client->describeImportImageTasks([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'ImportTaskIds' => ['<string>', ...],
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

Filter tasks using the task-state filter and one of the following values: active, completed, deleting, deleted.

ImportTaskIds
Type: Array of strings

A list of import image task IDs.

MaxResults
Type: int

The maximum number of results to return in a single call. To retrieve the remaining results, make another call with the returned NextToken value.

NextToken
Type: string

A token that indicates the next page of results.

Result Syntax

[
    'ImportImageTasks' => [
        [
            'Architecture' => '<string>',
            'Description' => '<string>',
            'Hypervisor' => '<string>',
            'ImageId' => '<string>',
            'ImportTaskId' => '<string>',
            'LicenseType' => '<string>',
            'Platform' => '<string>',
            'Progress' => '<string>',
            'SnapshotDetails' => [
                [
                    'Description' => '<string>',
                    'DeviceName' => '<string>',
                    'DiskImageSize' => <float>,
                    'Format' => '<string>',
                    'Progress' => '<string>',
                    'SnapshotId' => '<string>',
                    'Status' => '<string>',
                    'StatusMessage' => '<string>',
                    'Url' => '<string>',
                    'UserBucket' => [
                        'S3Bucket' => '<string>',
                        'S3Key' => '<string>',
                    ],
                ],
                // ...
            ],
            'Status' => '<string>',
            'StatusMessage' => '<string>',
        ],
        // ...
    ],
    'NextToken' => '<string>',
]

Result Details

Members
ImportImageTasks
Type: Array of ImportImageTask structures

A list of zero or more import image tasks that are currently active or were completed or canceled in the previous 7 days.

NextToken
Type: string

The token to use to get the next page of results. This value is null when there are no more results to return.

Errors

There are no errors described for this operation.

DescribeImportSnapshotTasks

$result = $client->describeImportSnapshotTasks([/* ... */]);
$promise = $client->describeImportSnapshotTasksAsync([/* ... */]);

Describes your import snapshot tasks.

Parameter Syntax

$result = $client->describeImportSnapshotTasks([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'ImportTaskIds' => ['<string>', ...],
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

ImportTaskIds
Type: Array of strings

A list of import snapshot task IDs.

MaxResults
Type: int

The maximum number of results to return in a single call. To retrieve the remaining results, make another call with the returned NextToken value.

NextToken
Type: string

A token that indicates the next page of results.

Result Syntax

[
    'ImportSnapshotTasks' => [
        [
            'Description' => '<string>',
            'ImportTaskId' => '<string>',
            'SnapshotTaskDetail' => [
                'Description' => '<string>',
                'DiskImageSize' => <float>,
                'Format' => '<string>',
                'Progress' => '<string>',
                'SnapshotId' => '<string>',
                'Status' => '<string>',
                'StatusMessage' => '<string>',
                'Url' => '<string>',
                'UserBucket' => [
                    'S3Bucket' => '<string>',
                    'S3Key' => '<string>',
                ],
            ],
        ],
        // ...
    ],
    'NextToken' => '<string>',
]

Result Details

Members
ImportSnapshotTasks
Type: Array of ImportSnapshotTask structures

A list of zero or more import snapshot tasks that are currently active or were completed or canceled in the previous 7 days.

NextToken
Type: string

The token to use to get the next page of results. This value is null when there are no more results to return.

Errors

There are no errors described for this operation.

DescribeInstanceAttribute

$result = $client->describeInstanceAttribute([/* ... */]);
$promise = $client->describeInstanceAttributeAsync([/* ... */]);

Describes the specified attribute of the specified instance. You can specify only one attribute at a time. Valid attribute values are: instanceType | kernel | ramdisk | userData | disableApiTermination | instanceInitiatedShutdownBehavior | rootDeviceName | blockDeviceMapping | productCodes | sourceDestCheck | groupSet | ebsOptimized | sriovNetSupport

Parameter Syntax

$result = $client->describeInstanceAttribute([
    'Attribute' => 'instanceType|kernel|ramdisk|userData|disableApiTermination|instanceInitiatedShutdownBehavior|rootDeviceName|blockDeviceMapping|productCodes|sourceDestCheck|groupSet|ebsOptimized|sriovNetSupport', // REQUIRED
    'DryRun' => true || false,
    'InstanceId' => '<string>', // REQUIRED
]);

Parameter Details

Members
Attribute
Required: Yes
Type: string

The instance attribute.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

InstanceId
Required: Yes
Type: string

The ID of the instance.

Result Syntax

[
    'BlockDeviceMappings' => [
        [
            'DeviceName' => '<string>',
            'Ebs' => [
                'AttachTime' => <DateTime>,
                'DeleteOnTermination' => true || false,
                'Status' => 'attaching|attached|detaching|detached',
                'VolumeId' => '<string>',
            ],
        ],
        // ...
    ],
    'DisableApiTermination' => [
        'Value' => true || false,
    ],
    'EbsOptimized' => [
        'Value' => true || false,
    ],
    'Groups' => [
        [
            'GroupId' => '<string>',
            'GroupName' => '<string>',
        ],
        // ...
    ],
    'InstanceId' => '<string>',
    'InstanceInitiatedShutdownBehavior' => [
        'Value' => '<string>',
    ],
    'InstanceType' => [
        'Value' => '<string>',
    ],
    'KernelId' => [
        'Value' => '<string>',
    ],
    'ProductCodes' => [
        [
            'ProductCodeId' => '<string>',
            'ProductCodeType' => 'devpay|marketplace',
        ],
        // ...
    ],
    'RamdiskId' => [
        'Value' => '<string>',
    ],
    'RootDeviceName' => [
        'Value' => '<string>',
    ],
    'SourceDestCheck' => [
        'Value' => true || false,
    ],
    'SriovNetSupport' => [
        'Value' => '<string>',
    ],
    'UserData' => [
        'Value' => '<string>',
    ],
]

Result Details

Members
BlockDeviceMappings
Type: Array of InstanceBlockDeviceMapping structures

The block device mapping of the instance.

DisableApiTermination
Type: AttributeBooleanValue structure

If the value is true, you can't terminate the instance through the Amazon EC2 console, CLI, or API; otherwise, you can.

EbsOptimized
Type: AttributeBooleanValue structure

Indicates whether the instance is optimized for EBS I/O.

Groups
Type: Array of GroupIdentifier structures

The security groups associated with the instance.

InstanceId
Type: string

The ID of the instance.

InstanceInitiatedShutdownBehavior
Type: AttributeValue structure

Indicates whether an instance stops or terminates when you initiate shutdown from the instance (using the operating system command for system shutdown).

InstanceType
Type: AttributeValue structure

The instance type.

KernelId
Type: AttributeValue structure

The kernel ID.

ProductCodes
Type: Array of ProductCode structures

A list of product codes.

RamdiskId
Type: AttributeValue structure

The RAM disk ID.

RootDeviceName
Type: AttributeValue structure

The name of the root device (for example, /dev/sda1 or /dev/xvda).

SourceDestCheck
Type: AttributeBooleanValue structure

Indicates whether source/destination checking is enabled. A value of true means checking is enabled, and false means checking is disabled. This value must be false for a NAT instance to perform NAT.

SriovNetSupport
Type: AttributeValue structure

The value to use for a resource attribute.

UserData
Type: AttributeValue structure

The Base64-encoded MIME user data.

Errors

There are no errors described for this operation.

DescribeInstanceStatus

$result = $client->describeInstanceStatus([/* ... */]);
$promise = $client->describeInstanceStatusAsync([/* ... */]);

Describes the status of one or more instances. By default, only running instances are described, unless specified otherwise.

Instance status includes the following components:

  • Status checks - Amazon EC2 performs status checks on running EC2 instances to identify hardware and software issues. For more information, see Status Checks for Your Instances and Troubleshooting Instances with Failed Status Checks in the Amazon Elastic Compute Cloud User Guide.

  • Scheduled events - Amazon EC2 can schedule events (such as reboot, stop, or terminate) for your instances related to hardware issues, software updates, or system maintenance. For more information, see Scheduled Events for Your Instances in the Amazon Elastic Compute Cloud User Guide.

  • Instance state - You can manage your instances from the moment you launch them through their termination. For more information, see Instance Lifecycle in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->describeInstanceStatus([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'IncludeAllInstances' => true || false,
    'InstanceIds' => ['<string>', ...],
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • availability-zone - The Availability Zone of the instance.

  • event.code - The code for the scheduled event (instance-reboot | system-reboot | system-maintenance | instance-retirement | instance-stop).

  • event.description - A description of the event.

  • event.not-after - The latest end time for the scheduled event (for example, 2014-09-15T17:15:20.000Z).

  • event.not-before - The earliest start time for the scheduled event (for example, 2014-09-15T17:15:20.000Z).

  • instance-state-code - The code for the instance state, as a 16-bit unsigned integer. The high byte is an opaque internal value and should be ignored. The low byte is set based on the state represented. The valid values are 0 (pending), 16 (running), 32 (shutting-down), 48 (terminated), 64 (stopping), and 80 (stopped).

  • instance-state-name - The state of the instance (pending | running | shutting-down | terminated | stopping | stopped).

  • instance-status.reachability - Filters on instance status where the name is reachability (passed | failed | initializing | insufficient-data).

  • instance-status.status - The status of the instance (ok | impaired | initializing | insufficient-data | not-applicable).

  • system-status.reachability - Filters on system status where the name is reachability (passed | failed | initializing | insufficient-data).

  • system-status.status - The system status of the instance (ok | impaired | initializing | insufficient-data | not-applicable).

IncludeAllInstances
Type: boolean

When true, includes the health status for all instances. When false, includes the health status for running instances only.

Default: false

InstanceIds
Type: Array of strings

One or more instance IDs.

Default: Describes all your instances.

Constraints: Maximum 100 explicitly specified instance IDs.

MaxResults
Type: int

The maximum number of results to return in a single call. To retrieve the remaining results, make another call with the returned NextToken value. This value can be between 5 and 1000. You cannot specify this parameter and the instance IDs parameter in the same call.

NextToken
Type: string

The token to retrieve the next page of results.

Result Syntax

[
    'InstanceStatuses' => [
        [
            'AvailabilityZone' => '<string>',
            'Events' => [
                [
                    'Code' => 'instance-reboot|system-reboot|system-maintenance|instance-retirement|instance-stop',
                    'Description' => '<string>',
                    'NotAfter' => <DateTime>,
                    'NotBefore' => <DateTime>,
                ],
                // ...
            ],
            'InstanceId' => '<string>',
            'InstanceState' => [
                'Code' => <integer>,
                'Name' => 'pending|running|shutting-down|terminated|stopping|stopped',
            ],
            'InstanceStatus' => [
                'Details' => [
                    [
                        'ImpairedSince' => <DateTime>,
                        'Name' => 'reachability',
                        'Status' => 'passed|failed|insufficient-data|initializing',
                    ],
                    // ...
                ],
                'Status' => 'ok|impaired|insufficient-data|not-applicable|initializing',
            ],
            'SystemStatus' => [
                'Details' => [
                    [
                        'ImpairedSince' => <DateTime>,
                        'Name' => 'reachability',
                        'Status' => 'passed|failed|insufficient-data|initializing',
                    ],
                    // ...
                ],
                'Status' => 'ok|impaired|insufficient-data|not-applicable|initializing',
            ],
        ],
        // ...
    ],
    'NextToken' => '<string>',
]

Result Details

Members
InstanceStatuses
Type: Array of InstanceStatus structures

One or more instance status descriptions.

NextToken
Type: string

The token to use to retrieve the next page of results. This value is null when there are no more results to return.

Errors

There are no errors described for this operation.

DescribeInstances

$result = $client->describeInstances([/* ... */]);
$promise = $client->describeInstancesAsync([/* ... */]);

Describes one or more of your instances.

If you specify one or more instance IDs, Amazon EC2 returns information for those instances. If you do not specify instance IDs, Amazon EC2 returns information for all relevant instances. If you specify an instance ID that is not valid, an error is returned. If you specify an instance that you do not own, it is not included in the returned results.

Recently terminated instances might appear in the returned results. This interval is usually less than one hour.

Parameter Syntax

$result = $client->describeInstances([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'InstanceIds' => ['<string>', ...],
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • affinity - The affinity setting for an instance running on a Dedicated host (default | host).

  • architecture - The instance architecture (i386 | x86_64).

  • availability-zone - The Availability Zone of the instance.

  • block-device-mapping.attach-time - The attach time for an EBS volume mapped to the instance, for example, 2010-09-15T17:15:20.000Z.

  • block-device-mapping.delete-on-termination - A Boolean that indicates whether the EBS volume is deleted on instance termination.

  • block-device-mapping.device-name - The device name for the EBS volume (for example, /dev/sdh or xvdh).

  • block-device-mapping.status - The status for the EBS volume (attaching | attached | detaching | detached).

  • block-device-mapping.volume-id - The volume ID of the EBS volume.

  • client-token - The idempotency token you provided when you launched the instance.

  • dns-name - The public DNS name of the instance.

  • group-id - The ID of the security group for the instance. EC2-Classic only.

  • group-name - The name of the security group for the instance. EC2-Classic only.

  • host-Id - The ID of the Dedicated host on which the instance is running, if applicable.

  • hypervisor - The hypervisor type of the instance (ovm | xen).

  • iam-instance-profile.arn - The instance profile associated with the instance. Specified as an ARN.

  • image-id - The ID of the image used to launch the instance.

  • instance-id - The ID of the instance.

  • instance-lifecycle - Indicates whether this is a Spot Instance or a Scheduled Instance (spot | scheduled).

  • instance-state-code - The state of the instance, as a 16-bit unsigned integer. The high byte is an opaque internal value and should be ignored. The low byte is set based on the state represented. The valid values are: 0 (pending), 16 (running), 32 (shutting-down), 48 (terminated), 64 (stopping), and 80 (stopped).

  • instance-state-name - The state of the instance (pending | running | shutting-down | terminated | stopping | stopped).

  • instance-type - The type of instance (for example, t2.micro).

  • instance.group-id - The ID of the security group for the instance.

  • instance.group-name - The name of the security group for the instance.

  • ip-address - The public IP address of the instance.

  • kernel-id - The kernel ID.

  • key-name - The name of the key pair used when the instance was launched.

  • launch-index - When launching multiple instances, this is the index for the instance in the launch group (for example, 0, 1, 2, and so on).

  • launch-time - The time when the instance was launched.

  • monitoring-state - Indicates whether monitoring is enabled for the instance (disabled | enabled).

  • owner-id - The AWS account ID of the instance owner.

  • placement-group-name - The name of the placement group for the instance.

  • platform - The platform. Use windows if you have Windows instances; otherwise, leave blank.

  • private-dns-name - The private DNS name of the instance.

  • private-ip-address - The private IP address of the instance.

  • product-code - The product code associated with the AMI used to launch the instance.

  • product-code.type - The type of product code (devpay | marketplace).

  • ramdisk-id - The RAM disk ID.

  • reason - The reason for the current state of the instance (for example, shows "User Initiated [date]" when you stop or terminate the instance). Similar to the state-reason-code filter.

  • requester-id - The ID of the entity that launched the instance on your behalf (for example, AWS Management Console, Auto Scaling, and so on).

  • reservation-id - The ID of the instance's reservation. A reservation ID is created any time you launch an instance. A reservation ID has a one-to-one relationship with an instance launch request, but can be associated with more than one instance if you launch multiple instances using the same launch request. For example, if you launch one instance, you'll get one reservation ID. If you launch ten instances using the same launch request, you'll also get one reservation ID.

  • root-device-name - The name of the root device for the instance (for example, /dev/sda1 or /dev/xvda).

  • root-device-type - The type of root device that the instance uses (ebs | instance-store).

  • source-dest-check - Indicates whether the instance performs source/destination checking. A value of true means that checking is enabled, and false means checking is disabled. The value must be false for the instance to perform network address translation (NAT) in your VPC.

  • spot-instance-request-id - The ID of the Spot instance request.

  • state-reason-code - The reason code for the state change.

  • state-reason-message - A message that describes the state change.

  • subnet-id - The ID of the subnet for the instance.

  • tag:key=value - The key/value combination of a tag assigned to the resource, where tag:key is the tag's key.

  • tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag:key=value filter.

  • tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.

  • tenancy - The tenancy of an instance (dedicated | default | host).

  • virtualization-type - The virtualization type of the instance (paravirtual | hvm).

  • vpc-id - The ID of the VPC that the instance is running in.

  • network-interface.description - The description of the network interface.

  • network-interface.subnet-id - The ID of the subnet for the network interface.

  • network-interface.vpc-id - The ID of the VPC for the network interface.

  • network-interface.network-interface-id - The ID of the network interface.

  • network-interface.owner-id - The ID of the owner of the network interface.

  • network-interface.availability-zone - The Availability Zone for the network interface.

  • network-interface.requester-id - The requester ID for the network interface.

  • network-interface.requester-managed - Indicates whether the network interface is being managed by AWS.

  • network-interface.status - The status of the network interface (available) | in-use).

  • network-interface.mac-address - The MAC address of the network interface.

  • network-interface.private-dns-name - The private DNS name of the network interface.

  • network-interface.source-dest-check - Whether the network interface performs source/destination checking. A value of true means checking is enabled, and false means checking is disabled. The value must be false for the network interface to perform network address translation (NAT) in your VPC.

  • network-interface.group-id - The ID of a security group associated with the network interface.

  • network-interface.group-name - The name of a security group associated with the network interface.

  • network-interface.attachment.attachment-id - The ID of the interface attachment.

  • network-interface.attachment.instance-id - The ID of the instance to which the network interface is attached.

  • network-interface.attachment.instance-owner-id - The owner ID of the instance to which the network interface is attached.

  • network-interface.addresses.private-ip-address - The private IP address associated with the network interface.

  • network-interface.attachment.device-index - The device index to which the network interface is attached.

  • network-interface.attachment.status - The status of the attachment (attaching | attached | detaching | detached).

  • network-interface.attachment.attach-time - The time that the network interface was attached to an instance.

  • network-interface.attachment.delete-on-termination - Specifies whether the attachment is deleted when an instance is terminated.

  • network-interface.addresses.primary - Specifies whether the IP address of the network interface is the primary private IP address.

  • network-interface.addresses.association.public-ip - The ID of the association of an Elastic IP address with a network interface.

  • network-interface.addresses.association.ip-owner-id - The owner ID of the private IP address associated with the network interface.

  • association.public-ip - The address of the Elastic IP address bound to the network interface.

  • association.ip-owner-id - The owner of the Elastic IP address associated with the network interface.

  • association.allocation-id - The allocation ID returned when you allocated the Elastic IP address for your network interface.

  • association.association-id - The association ID returned when the network interface was associated with an IP address.

InstanceIds
Type: Array of strings

One or more instance IDs.

Default: Describes all your instances.

MaxResults
Type: int

The maximum number of results to return in a single call. To retrieve the remaining results, make another call with the returned NextToken value. This value can be between 5 and 1000. You cannot specify this parameter and the instance IDs parameter or tag filters in the same call.

NextToken
Type: string

The token to request the next page of results.

Result Syntax

[
    'NextToken' => '<string>',
    'Reservations' => [
        [
            'Groups' => [
                [
                    'GroupId' => '<string>',
                    'GroupName' => '<string>',
                ],
                // ...
            ],
            'Instances' => [
                [
                    'AmiLaunchIndex' => <integer>,
                    'Architecture' => 'i386|x86_64',
                    'BlockDeviceMappings' => [
                        [
                            'DeviceName' => '<string>',
                            'Ebs' => [
                                'AttachTime' => <DateTime>,
                                'DeleteOnTermination' => true || false,
                                'Status' => 'attaching|attached|detaching|detached',
                                'VolumeId' => '<string>',
                            ],
                        ],
                        // ...
                    ],
                    'ClientToken' => '<string>',
                    'EbsOptimized' => true || false,
                    'Hypervisor' => 'ovm|xen',
                    'IamInstanceProfile' => [
                        'Arn' => '<string>',
                        'Id' => '<string>',
                    ],
                    'ImageId' => '<string>',
                    'InstanceId' => '<string>',
                    'InstanceLifecycle' => 'spot|scheduled',
                    'InstanceType' => 't1.micro|m1.small|m1.medium|m1.large|m1.xlarge|m3.medium|m3.large|m3.xlarge|m3.2xlarge|m4.large|m4.xlarge|m4.2xlarge|m4.4xlarge|m4.10xlarge|t2.nano|t2.micro|t2.small|t2.medium|t2.large|m2.xlarge|m2.2xlarge|m2.4xlarge|cr1.8xlarge|x1.4xlarge|x1.8xlarge|x1.16xlarge|x1.32xlarge|i2.xlarge|i2.2xlarge|i2.4xlarge|i2.8xlarge|hi1.4xlarge|hs1.8xlarge|c1.medium|c1.xlarge|c3.large|c3.xlarge|c3.2xlarge|c3.4xlarge|c3.8xlarge|c4.large|c4.xlarge|c4.2xlarge|c4.4xlarge|c4.8xlarge|cc1.4xlarge|cc2.8xlarge|g2.2xlarge|g2.8xlarge|cg1.4xlarge|r3.large|r3.xlarge|r3.2xlarge|r3.4xlarge|r3.8xlarge|d2.xlarge|d2.2xlarge|d2.4xlarge|d2.8xlarge',
                    'KernelId' => '<string>',
                    'KeyName' => '<string>',
                    'LaunchTime' => <DateTime>,
                    'Monitoring' => [
                        'State' => 'disabled|disabling|enabled|pending',
                    ],
                    'NetworkInterfaces' => [
                        [
                            'Association' => [
                                'IpOwnerId' => '<string>',
                                'PublicDnsName' => '<string>',
                                'PublicIp' => '<string>',
                            ],
                            'Attachment' => [
                                'AttachTime' => <DateTime>,
                                'AttachmentId' => '<string>',
                                'DeleteOnTermination' => true || false,
                                'DeviceIndex' => <integer>,
                                'Status' => 'attaching|attached|detaching|detached',
                            ],
                            'Description' => '<string>',
                            'Groups' => [
                                [
                                    'GroupId' => '<string>',
                                    'GroupName' => '<string>',
                                ],
                                // ...
                            ],
                            'MacAddress' => '<string>',
                            'NetworkInterfaceId' => '<string>',
                            'OwnerId' => '<string>',
                            'PrivateDnsName' => '<string>',
                            'PrivateIpAddress' => '<string>',
                            'PrivateIpAddresses' => [
                                [
                                    'Association' => [
                                        'IpOwnerId' => '<string>',
                                        'PublicDnsName' => '<string>',
                                        'PublicIp' => '<string>',
                                    ],
                                    'Primary' => true || false,
                                    'PrivateDnsName' => '<string>',
                                    'PrivateIpAddress' => '<string>',
                                ],
                                // ...
                            ],
                            'SourceDestCheck' => true || false,
                            'Status' => 'available|attaching|in-use|detaching',
                            'SubnetId' => '<string>',
                            'VpcId' => '<string>',
                        ],
                        // ...
                    ],
                    'Placement' => [
                        'Affinity' => '<string>',
                        'AvailabilityZone' => '<string>',
                        'GroupName' => '<string>',
                        'HostId' => '<string>',
                        'Tenancy' => 'default|dedicated|host',
                    ],
                    'Platform' => 'Windows',
                    'PrivateDnsName' => '<string>',
                    'PrivateIpAddress' => '<string>',
                    'ProductCodes' => [
                        [
                            'ProductCodeId' => '<string>',
                            'ProductCodeType' => 'devpay|marketplace',
                        ],
                        // ...
                    ],
                    'PublicDnsName' => '<string>',
                    'PublicIpAddress' => '<string>',
                    'RamdiskId' => '<string>',
                    'RootDeviceName' => '<string>',
                    'RootDeviceType' => 'ebs|instance-store',
                    'SecurityGroups' => [
                        [
                            'GroupId' => '<string>',
                            'GroupName' => '<string>',
                        ],
                        // ...
                    ],
                    'SourceDestCheck' => true || false,
                    'SpotInstanceRequestId' => '<string>',
                    'SriovNetSupport' => '<string>',
                    'State' => [
                        'Code' => <integer>,
                        'Name' => 'pending|running|shutting-down|terminated|stopping|stopped',
                    ],
                    'StateReason' => [
                        'Code' => '<string>',
                        'Message' => '<string>',
                    ],
                    'StateTransitionReason' => '<string>',
                    'SubnetId' => '<string>',
                    'Tags' => [
                        [
                            'Key' => '<string>',
                            'Value' => '<string>',
                        ],
                        // ...
                    ],
                    'VirtualizationType' => 'hvm|paravirtual',
                    'VpcId' => '<string>',
                ],
                // ...
            ],
            'OwnerId' => '<string>',
            'RequesterId' => '<string>',
            'ReservationId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
NextToken
Type: string

The token to use to retrieve the next page of results. This value is null when there are no more results to return.

Reservations
Type: Array of Reservation structures

Zero or more reservations.

Errors

There are no errors described for this operation.

DescribeInternetGateways

$result = $client->describeInternetGateways([/* ... */]);
$promise = $client->describeInternetGatewaysAsync([/* ... */]);

Describes one or more of your Internet gateways.

Parameter Syntax

$result = $client->describeInternetGateways([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'InternetGatewayIds' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • attachment.state - The current state of the attachment between the gateway and the VPC (available). Present only if a VPC is attached.

  • attachment.vpc-id - The ID of an attached VPC.

  • internet-gateway-id - The ID of the Internet gateway.

  • tag:key=value - The key/value combination of a tag assigned to the resource.

  • tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag:key=value filter.

  • tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.

InternetGatewayIds
Type: Array of strings

One or more Internet gateway IDs.

Default: Describes all your Internet gateways.

Result Syntax

[
    'InternetGateways' => [
        [
            'Attachments' => [
                [
                    'State' => 'attaching|attached|detaching|detached',
                    'VpcId' => '<string>',
                ],
                // ...
            ],
            'InternetGatewayId' => '<string>',
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
        ],
        // ...
    ],
]

Result Details

Members
InternetGateways
Type: Array of InternetGateway structures

Information about one or more Internet gateways.

Errors

There are no errors described for this operation.

DescribeKeyPairs

$result = $client->describeKeyPairs([/* ... */]);
$promise = $client->describeKeyPairsAsync([/* ... */]);

Describes one or more of your key pairs.

For more information about key pairs, see Key Pairs in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->describeKeyPairs([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'KeyNames' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • fingerprint - The fingerprint of the key pair.

  • key-name - The name of the key pair.

KeyNames
Type: Array of strings

One or more key pair names.

Default: Describes all your key pairs.

Result Syntax

[
    'KeyPairs' => [
        [
            'KeyFingerprint' => '<string>',
            'KeyName' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
KeyPairs
Type: Array of KeyPairInfo structures

Information about one or more key pairs.

Errors

There are no errors described for this operation.

DescribeMovingAddresses

$result = $client->describeMovingAddresses([/* ... */]);
$promise = $client->describeMovingAddressesAsync([/* ... */]);

Describes your Elastic IP addresses that are being moved to the EC2-VPC platform, or that are being restored to the EC2-Classic platform. This request does not return information about any other Elastic IP addresses in your account.

Parameter Syntax

$result = $client->describeMovingAddresses([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
    'PublicIps' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • moving-status - The status of the Elastic IP address (MovingToVpc | RestoringToClassic).

MaxResults
Type: int

The maximum number of results to return for the request in a single page. The remaining results of the initial request can be seen by sending another request with the returned NextToken value. This value can be between 5 and 1000; if MaxResults is given a value outside of this range, an error is returned.

Default: If no value is provided, the default is 1000.

NextToken
Type: string

The token to use to retrieve the next page of results.

PublicIps
Type: Array of strings

One or more Elastic IP addresses.

Result Syntax

[
    'MovingAddressStatuses' => [
        [
            'MoveStatus' => 'movingToVpc|restoringToClassic',
            'PublicIp' => '<string>',
        ],
        // ...
    ],
    'NextToken' => '<string>',
]

Result Details

Members
MovingAddressStatuses
Type: Array of MovingAddressStatus structures

The status for each Elastic IP address.

NextToken
Type: string

The token to use to retrieve the next page of results. This value is null when there are no more results to return.

Errors

There are no errors described for this operation.

DescribeNatGateways

$result = $client->describeNatGateways([/* ... */]);
$promise = $client->describeNatGatewaysAsync([/* ... */]);

Describes one or more of the your NAT gateways.

Parameter Syntax

$result = $client->describeNatGateways([
    'Filter' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'MaxResults' => <integer>,
    'NatGatewayIds' => ['<string>', ...],
    'NextToken' => '<string>',
]);

Parameter Details

Members
Filter
Type: Array of Filter structures

One or more filters.

  • nat-gateway-id - The ID of the NAT gateway.

  • state - The state of the NAT gateway (pending | failed | available | deleting | deleted).

  • subnet-id - The ID of the subnet in which the NAT gateway resides.

  • vpc-id - The ID of the VPC in which the NAT gateway resides.

MaxResults
Type: int

The maximum number of items to return for this request. The request returns a token that you can specify in a subsequent call to get the next set of results.

Constraint: If the value specified is greater than 1000, we return only 1000 items.

NatGatewayIds
Type: Array of strings

One or more NAT gateway IDs.

NextToken
Type: string

The token to retrieve the next page of results.

Result Syntax

[
    'NatGateways' => [
        [
            'CreateTime' => <DateTime>,
            'DeleteTime' => <DateTime>,
            'FailureCode' => '<string>',
            'FailureMessage' => '<string>',
            'NatGatewayAddresses' => [
                [
                    'AllocationId' => '<string>',
                    'NetworkInterfaceId' => '<string>',
                    'PrivateIp' => '<string>',
                    'PublicIp' => '<string>',
                ],
                // ...
            ],
            'NatGatewayId' => '<string>',
            'ProvisionedBandwidth' => [
                'ProvisionTime' => <DateTime>,
                'Provisioned' => '<string>',
                'RequestTime' => <DateTime>,
                'Requested' => '<string>',
                'Status' => '<string>',
            ],
            'State' => 'pending|failed|available|deleting|deleted',
            'SubnetId' => '<string>',
            'VpcId' => '<string>',
        ],
        // ...
    ],
    'NextToken' => '<string>',
]

Result Details

Members
NatGateways
Type: Array of NatGateway structures

Information about the NAT gateways.

NextToken
Type: string

The token to use to retrieve the next page of results. This value is null when there are no more results to return.

Errors

There are no errors described for this operation.

DescribeNetworkAcls

$result = $client->describeNetworkAcls([/* ... */]);
$promise = $client->describeNetworkAclsAsync([/* ... */]);

Describes one or more of your network ACLs.

For more information about network ACLs, see Network ACLs in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->describeNetworkAcls([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'NetworkAclIds' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • association.association-id - The ID of an association ID for the ACL.

  • association.network-acl-id - The ID of the network ACL involved in the association.

  • association.subnet-id - The ID of the subnet involved in the association.

  • default - Indicates whether the ACL is the default network ACL for the VPC.

  • entry.cidr - The CIDR range specified in the entry.

  • entry.egress - Indicates whether the entry applies to egress traffic.

  • entry.icmp.code - The ICMP code specified in the entry, if any.

  • entry.icmp.type - The ICMP type specified in the entry, if any.

  • entry.port-range.from - The start of the port range specified in the entry.

  • entry.port-range.to - The end of the port range specified in the entry.

  • entry.protocol - The protocol specified in the entry (tcp | udp | icmp or a protocol number).

  • entry.rule-action - Allows or denies the matching traffic (allow | deny).

  • entry.rule-number - The number of an entry (in other words, rule) in the ACL's set of entries.

  • network-acl-id - The ID of the network ACL.

  • tag:key=value - The key/value combination of a tag assigned to the resource.

  • tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag:key=value filter.

  • tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.

  • vpc-id - The ID of the VPC for the network ACL.

NetworkAclIds
Type: Array of strings

One or more network ACL IDs.

Default: Describes all your network ACLs.

Result Syntax

[
    'NetworkAcls' => [
        [
            'Associations' => [
                [
                    'NetworkAclAssociationId' => '<string>',
                    'NetworkAclId' => '<string>',
                    'SubnetId' => '<string>',
                ],
                // ...
            ],
            'Entries' => [
                [
                    'CidrBlock' => '<string>',
                    'Egress' => true || false,
                    'IcmpTypeCode' => [
                        'Code' => <integer>,
                        'Type' => <integer>,
                    ],
                    'PortRange' => [
                        'From' => <integer>,
                        'To' => <integer>,
                    ],
                    'Protocol' => '<string>',
                    'RuleAction' => 'allow|deny',
                    'RuleNumber' => <integer>,
                ],
                // ...
            ],
            'IsDefault' => true || false,
            'NetworkAclId' => '<string>',
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'VpcId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
NetworkAcls
Type: Array of NetworkAcl structures

Information about one or more network ACLs.

Errors

There are no errors described for this operation.

DescribeNetworkInterfaceAttribute

$result = $client->describeNetworkInterfaceAttribute([/* ... */]);
$promise = $client->describeNetworkInterfaceAttributeAsync([/* ... */]);

Describes a network interface attribute. You can specify only one attribute at a time.

Parameter Syntax

$result = $client->describeNetworkInterfaceAttribute([
    'Attribute' => 'description|groupSet|sourceDestCheck|attachment',
    'DryRun' => true || false,
    'NetworkInterfaceId' => '<string>', // REQUIRED
]);

Parameter Details

Members
Attribute
Type: string

The attribute of the network interface.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

NetworkInterfaceId
Required: Yes
Type: string

The ID of the network interface.

Result Syntax

[
    'Attachment' => [
        'AttachTime' => <DateTime>,
        'AttachmentId' => '<string>',
        'DeleteOnTermination' => true || false,
        'DeviceIndex' => <integer>,
        'InstanceId' => '<string>',
        'InstanceOwnerId' => '<string>',
        'Status' => 'attaching|attached|detaching|detached',
    ],
    'Description' => [
        'Value' => '<string>',
    ],
    'Groups' => [
        [
            'GroupId' => '<string>',
            'GroupName' => '<string>',
        ],
        // ...
    ],
    'NetworkInterfaceId' => '<string>',
    'SourceDestCheck' => [
        'Value' => true || false,
    ],
]

Result Details

Members
Attachment
Type: NetworkInterfaceAttachment structure

The attachment (if any) of the network interface.

Description
Type: AttributeValue structure

The description of the network interface.

Groups
Type: Array of GroupIdentifier structures

The security groups associated with the network interface.

NetworkInterfaceId
Type: string

The ID of the network interface.

SourceDestCheck
Type: AttributeBooleanValue structure

Indicates whether source/destination checking is enabled.

Errors

There are no errors described for this operation.

DescribeNetworkInterfaces

$result = $client->describeNetworkInterfaces([/* ... */]);
$promise = $client->describeNetworkInterfacesAsync([/* ... */]);

Describes one or more of your network interfaces.

Parameter Syntax

$result = $client->describeNetworkInterfaces([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'NetworkInterfaceIds' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • addresses.private-ip-address - The private IP addresses associated with the network interface.

  • addresses.primary - Whether the private IP address is the primary IP address associated with the network interface.

  • addresses.association.public-ip - The association ID returned when the network interface was associated with the Elastic IP address.

  • addresses.association.owner-id - The owner ID of the addresses associated with the network interface.

  • association.association-id - The association ID returned when the network interface was associated with an IP address.

  • association.allocation-id - The allocation ID returned when you allocated the Elastic IP address for your network interface.

  • association.ip-owner-id - The owner of the Elastic IP address associated with the network interface.

  • association.public-ip - The address of the Elastic IP address bound to the network interface.

  • association.public-dns-name - The public DNS name for the network interface.

  • attachment.attachment-id - The ID of the interface attachment.

  • attachment.attach.time - The time that the network interface was attached to an instance.

  • attachment.delete-on-termination - Indicates whether the attachment is deleted when an instance is terminated.

  • attachment.device-index - The device index to which the network interface is attached.

  • attachment.instance-id - The ID of the instance to which the network interface is attached.

  • attachment.instance-owner-id - The owner ID of the instance to which the network interface is attached.

  • attachment.nat-gateway-id - The ID of the NAT gateway to which the network interface is attached.

  • attachment.status - The status of the attachment (attaching | attached | detaching | detached).

  • availability-zone - The Availability Zone of the network interface.

  • description - The description of the network interface.

  • group-id - The ID of a security group associated with the network interface.

  • group-name - The name of a security group associated with the network interface.

  • mac-address - The MAC address of the network interface.

  • network-interface-id - The ID of the network interface.

  • owner-id - The AWS account ID of the network interface owner.

  • private-ip-address - The private IP address or addresses of the network interface.

  • private-dns-name - The private DNS name of the network interface.

  • requester-id - The ID of the entity that launched the instance on your behalf (for example, AWS Management Console, Auto Scaling, and so on).

  • requester-managed - Indicates whether the network interface is being managed by an AWS service (for example, AWS Management Console, Auto Scaling, and so on).

  • source-desk-check - Indicates whether the network interface performs source/destination checking. A value of true means checking is enabled, and false means checking is disabled. The value must be false for the network interface to perform network address translation (NAT) in your VPC.

  • status - The status of the network interface. If the network interface is not attached to an instance, the status is available; if a network interface is attached to an instance the status is in-use.

  • subnet-id - The ID of the subnet for the network interface.

  • tag:key=value - The key/value combination of a tag assigned to the resource.

  • tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag:key=value filter.

  • tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.

  • vpc-id - The ID of the VPC for the network interface.

NetworkInterfaceIds
Type: Array of strings

One or more network interface IDs.

Default: Describes all your network interfaces.

Result Syntax

[
    'NetworkInterfaces' => [
        [
            'Association' => [
                'AllocationId' => '<string>',
                'AssociationId' => '<string>',
                'IpOwnerId' => '<string>',
                'PublicDnsName' => '<string>',
                'PublicIp' => '<string>',
            ],
            'Attachment' => [
                'AttachTime' => <DateTime>,
                'AttachmentId' => '<string>',
                'DeleteOnTermination' => true || false,
                'DeviceIndex' => <integer>,
                'InstanceId' => '<string>',
                'InstanceOwnerId' => '<string>',
                'Status' => 'attaching|attached|detaching|detached',
            ],
            'AvailabilityZone' => '<string>',
            'Description' => '<string>',
            'Groups' => [
                [
                    'GroupId' => '<string>',
                    'GroupName' => '<string>',
                ],
                // ...
            ],
            'InterfaceType' => 'interface|natGateway',
            'MacAddress' => '<string>',
            'NetworkInterfaceId' => '<string>',
            'OwnerId' => '<string>',
            'PrivateDnsName' => '<string>',
            'PrivateIpAddress' => '<string>',
            'PrivateIpAddresses' => [
                [
                    'Association' => [
                        'AllocationId' => '<string>',
                        'AssociationId' => '<string>',
                        'IpOwnerId' => '<string>',
                        'PublicDnsName' => '<string>',
                        'PublicIp' => '<string>',
                    ],
                    'Primary' => true || false,
                    'PrivateDnsName' => '<string>',
                    'PrivateIpAddress' => '<string>',
                ],
                // ...
            ],
            'RequesterId' => '<string>',
            'RequesterManaged' => true || false,
            'SourceDestCheck' => true || false,
            'Status' => 'available|attaching|in-use|detaching',
            'SubnetId' => '<string>',
            'TagSet' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'VpcId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
NetworkInterfaces
Type: Array of NetworkInterface structures

Information about one or more network interfaces.

Errors

There are no errors described for this operation.

DescribePlacementGroups

$result = $client->describePlacementGroups([/* ... */]);
$promise = $client->describePlacementGroupsAsync([/* ... */]);

Describes one or more of your placement groups. For more information about placement groups and cluster instances, see Cluster Instances in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->describePlacementGroups([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'GroupNames' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • group-name - The name of the placement group.

  • state - The state of the placement group (pending | available | deleting | deleted).

  • strategy - The strategy of the placement group (cluster).

GroupNames
Type: Array of strings

One or more placement group names.

Default: Describes all your placement groups, or only those otherwise specified.

Result Syntax

[
    'PlacementGroups' => [
        [
            'GroupName' => '<string>',
            'State' => 'pending|available|deleting|deleted',
            'Strategy' => 'cluster',
        ],
        // ...
    ],
]

Result Details

Members
PlacementGroups
Type: Array of PlacementGroup structures

One or more placement groups.

Errors

There are no errors described for this operation.

DescribePrefixLists

$result = $client->describePrefixLists([/* ... */]);
$promise = $client->describePrefixListsAsync([/* ... */]);

Describes available AWS services in a prefix list format, which includes the prefix list name and prefix list ID of the service and the IP address range for the service. A prefix list ID is required for creating an outbound security group rule that allows traffic from a VPC to access an AWS service through a VPC endpoint.

Parameter Syntax

$result = $client->describePrefixLists([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
    'PrefixListIds' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • prefix-list-id: The ID of a prefix list.

  • prefix-list-name: The name of a prefix list.

MaxResults
Type: int

The maximum number of items to return for this request. The request returns a token that you can specify in a subsequent call to get the next set of results.

Constraint: If the value specified is greater than 1000, we return only 1000 items.

NextToken
Type: string

The token for the next set of items to return. (You received this token from a prior call.)

PrefixListIds
Type: Array of strings

One or more prefix list IDs.

Result Syntax

[
    'NextToken' => '<string>',
    'PrefixLists' => [
        [
            'Cidrs' => ['<string>', ...],
            'PrefixListId' => '<string>',
            'PrefixListName' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
NextToken
Type: string

The token to use when requesting the next set of items. If there are no additional items to return, the string is empty.

PrefixLists
Type: Array of PrefixList structures

All available prefix lists.

Errors

There are no errors described for this operation.

DescribeRegions

$result = $client->describeRegions([/* ... */]);
$promise = $client->describeRegionsAsync([/* ... */]);

Describes one or more regions that are currently available to you.

For a list of the regions supported by Amazon EC2, see Regions and Endpoints.

Parameter Syntax

$result = $client->describeRegions([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'RegionNames' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • endpoint - The endpoint of the region (for example, ec2.us-east-1.amazonaws.com).

  • region-name - The name of the region (for example, us-east-1).

RegionNames
Type: Array of strings

The names of one or more regions.

Result Syntax

[
    'Regions' => [
        [
            'Endpoint' => '<string>',
            'RegionName' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
Regions
Type: Array of Region structures

Information about one or more regions.

Errors

There are no errors described for this operation.

DescribeReservedInstances

$result = $client->describeReservedInstances([/* ... */]);
$promise = $client->describeReservedInstancesAsync([/* ... */]);

Describes one or more of the Reserved Instances that you purchased.

For more information about Reserved Instances, see Reserved Instances in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->describeReservedInstances([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'OfferingType' => 'Heavy Utilization|Medium Utilization|Light Utilization|No Upfront|Partial Upfront|All Upfront',
    'ReservedInstancesIds' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • availability-zone - The Availability Zone where the Reserved Instance can be used.

  • duration - The duration of the Reserved Instance (one year or three years), in seconds (31536000 | 94608000).

  • end - The time when the Reserved Instance expires (for example, 2015-08-07T11:54:42.000Z).

  • fixed-price - The purchase price of the Reserved Instance (for example, 9800.0).

  • instance-type - The instance type that is covered by the reservation.

  • product-description - The Reserved Instance product platform description. Instances that include (Amazon VPC) in the product platform description will only be displayed to EC2-Classic account holders and are for use with Amazon VPC (Linux/UNIX | Linux/UNIX (Amazon VPC) | SUSE Linux | SUSE Linux (Amazon VPC) | Red Hat Enterprise Linux | Red Hat Enterprise Linux (Amazon VPC) | Windows | Windows (Amazon VPC) | Windows with SQL Server Standard | Windows with SQL Server Standard (Amazon VPC) | Windows with SQL Server Web | Windows with SQL Server Web (Amazon VPC) | Windows with SQL Server Enterprise | Windows with SQL Server Enterprise (Amazon VPC)).

  • reserved-instances-id - The ID of the Reserved Instance.

  • start - The time at which the Reserved Instance purchase request was placed (for example, 2014-08-07T11:54:42.000Z).

  • state - The state of the Reserved Instance (payment-pending | active | payment-failed | retired).

  • tag:key=value - The key/value combination of a tag assigned to the resource.

  • tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag:key=value filter.

  • tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.

  • usage-price - The usage price of the Reserved Instance, per hour (for example, 0.84).

OfferingType
Type: string

The Reserved Instance offering type. If you are using tools that predate the 2011-11-01 API version, you only have access to the Medium Utilization Reserved Instance offering type.

ReservedInstancesIds
Type: Array of strings

One or more Reserved Instance IDs.

Default: Describes all your Reserved Instances, or only those otherwise specified.

Result Syntax

[
    'ReservedInstances' => [
        [
            'AvailabilityZone' => '<string>',
            'CurrencyCode' => 'USD',
            'Duration' => <integer>,
            'End' => <DateTime>,
            'FixedPrice' => <float>,
            'InstanceCount' => <integer>,
            'InstanceTenancy' => 'default|dedicated|host',
            'InstanceType' => 't1.micro|m1.small|m1.medium|m1.large|m1.xlarge|m3.medium|m3.large|m3.xlarge|m3.2xlarge|m4.large|m4.xlarge|m4.2xlarge|m4.4xlarge|m4.10xlarge|t2.nano|t2.micro|t2.small|t2.medium|t2.large|m2.xlarge|m2.2xlarge|m2.4xlarge|cr1.8xlarge|x1.4xlarge|x1.8xlarge|x1.16xlarge|x1.32xlarge|i2.xlarge|i2.2xlarge|i2.4xlarge|i2.8xlarge|hi1.4xlarge|hs1.8xlarge|c1.medium|c1.xlarge|c3.large|c3.xlarge|c3.2xlarge|c3.4xlarge|c3.8xlarge|c4.large|c4.xlarge|c4.2xlarge|c4.4xlarge|c4.8xlarge|cc1.4xlarge|cc2.8xlarge|g2.2xlarge|g2.8xlarge|cg1.4xlarge|r3.large|r3.xlarge|r3.2xlarge|r3.4xlarge|r3.8xlarge|d2.xlarge|d2.2xlarge|d2.4xlarge|d2.8xlarge',
            'OfferingType' => 'Heavy Utilization|Medium Utilization|Light Utilization|No Upfront|Partial Upfront|All Upfront',
            'ProductDescription' => 'Linux/UNIX|Linux/UNIX (Amazon VPC)|Windows|Windows (Amazon VPC)',
            'RecurringCharges' => [
                [
                    'Amount' => <float>,
                    'Frequency' => 'Hourly',
                ],
                // ...
            ],
            'ReservedInstancesId' => '<string>',
            'Start' => <DateTime>,
            'State' => 'payment-pending|active|payment-failed|retired',
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'UsagePrice' => <float>,
        ],
        // ...
    ],
]

Result Details

Members
ReservedInstances
Type: Array of ReservedInstances structures

A list of Reserved Instances.

Errors

There are no errors described for this operation.

DescribeReservedInstancesListings

$result = $client->describeReservedInstancesListings([/* ... */]);
$promise = $client->describeReservedInstancesListingsAsync([/* ... */]);

Describes your account's Reserved Instance listings in the Reserved Instance Marketplace.

The Reserved Instance Marketplace matches sellers who want to resell Reserved Instance capacity that they no longer need with buyers who want to purchase additional capacity. Reserved Instances bought and sold through the Reserved Instance Marketplace work like any other Reserved Instances.

As a seller, you choose to list some or all of your Reserved Instances, and you specify the upfront price to receive for them. Your Reserved Instances are then listed in the Reserved Instance Marketplace and are available for purchase.

As a buyer, you specify the configuration of the Reserved Instance to purchase, and the Marketplace matches what you're searching for with what's available. The Marketplace first sells the lowest priced Reserved Instances to you, and continues to sell available Reserved Instance listings to you until your demand is met. You are charged based on the total price of all of the listings that you purchase.

For more information, see Reserved Instance Marketplace in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->describeReservedInstancesListings([
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'ReservedInstancesId' => '<string>',
    'ReservedInstancesListingId' => '<string>',
]);

Parameter Details

Members
Filters
Type: Array of Filter structures

One or more filters.

  • reserved-instances-id - The ID of the Reserved Instances.

  • reserved-instances-listing-id - The ID of the Reserved Instances listing.

  • status - The status of the Reserved Instance listing (pending | active | cancelled | closed).

  • status-message - The reason for the status.

ReservedInstancesId
Type: string

One or more Reserved Instance IDs.

ReservedInstancesListingId
Type: string

One or more Reserved Instance listing IDs.

Result Syntax

[
    'ReservedInstancesListings' => [
        [
            'ClientToken' => '<string>',
            'CreateDate' => <DateTime>,
            'InstanceCounts' => [
                [
                    'InstanceCount' => <integer>,
                    'State' => 'available|sold|cancelled|pending',
                ],
                // ...
            ],
            'PriceSchedules' => [
                [
                    'Active' => true || false,
                    'CurrencyCode' => 'USD',
                    'Price' => <float>,
                    'Term' => <integer>,
                ],
                // ...
            ],
            'ReservedInstancesId' => '<string>',
            'ReservedInstancesListingId' => '<string>',
            'Status' => 'active|pending|cancelled|closed',
            'StatusMessage' => '<string>',
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'UpdateDate' => <DateTime>,
        ],
        // ...
    ],
]

Result Details

Members
ReservedInstancesListings
Type: Array of ReservedInstancesListing structures

Information about the Reserved Instance listing.

Errors

There are no errors described for this operation.

DescribeReservedInstancesModifications

$result = $client->describeReservedInstancesModifications([/* ... */]);
$promise = $client->describeReservedInstancesModificationsAsync([/* ... */]);

Describes the modifications made to your Reserved Instances. If no parameter is specified, information about all your Reserved Instances modification requests is returned. If a modification ID is specified, only information about the specific modification is returned.

For more information, see Modifying Reserved Instances in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->describeReservedInstancesModifications([
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'NextToken' => '<string>',
    'ReservedInstancesModificationIds' => ['<string>', ...],
]);

Parameter Details

Members
Filters
Type: Array of Filter structures

One or more filters.

  • client-token - The idempotency token for the modification request.

  • create-date - The time when the modification request was created.

  • effective-date - The time when the modification becomes effective.

  • modification-result.reserved-instances-id - The ID for the Reserved Instances created as part of the modification request. This ID is only available when the status of the modification is fulfilled.

  • modification-result.target-configuration.availability-zone - The Availability Zone for the new Reserved Instances.

  • modification-result.target-configuration.instance-count - The number of new Reserved Instances.

  • modification-result.target-configuration.instance-type - The instance type of the new Reserved Instances.

  • modification-result.target-configuration.platform - The network platform of the new Reserved Instances (EC2-Classic | EC2-VPC).

  • reserved-instances-id - The ID of the Reserved Instances modified.

  • reserved-instances-modification-id - The ID of the modification request.

  • status - The status of the Reserved Instances modification request (processing | fulfilled | failed).

  • status-message - The reason for the status.

  • update-date - The time when the modification request was last updated.

NextToken
Type: string

The token to retrieve the next page of results.

ReservedInstancesModificationIds
Type: Array of strings

IDs for the submitted modification request.

Result Syntax

[
    'NextToken' => '<string>',
    'ReservedInstancesModifications' => [
        [
            'ClientToken' => '<string>',
            'CreateDate' => <DateTime>,
            'EffectiveDate' => <DateTime>,
            'ModificationResults' => [
                [
                    'ReservedInstancesId' => '<string>',
                    'TargetConfiguration' => [
                        'AvailabilityZone' => '<string>',
                        'InstanceCount' => <integer>,
                        'InstanceType' => 't1.micro|m1.small|m1.medium|m1.large|m1.xlarge|m3.medium|m3.large|m3.xlarge|m3.2xlarge|m4.large|m4.xlarge|m4.2xlarge|m4.4xlarge|m4.10xlarge|t2.nano|t2.micro|t2.small|t2.medium|t2.large|m2.xlarge|m2.2xlarge|m2.4xlarge|cr1.8xlarge|x1.4xlarge|x1.8xlarge|x1.16xlarge|x1.32xlarge|i2.xlarge|i2.2xlarge|i2.4xlarge|i2.8xlarge|hi1.4xlarge|hs1.8xlarge|c1.medium|c1.xlarge|c3.large|c3.xlarge|c3.2xlarge|c3.4xlarge|c3.8xlarge|c4.large|c4.xlarge|c4.2xlarge|c4.4xlarge|c4.8xlarge|cc1.4xlarge|cc2.8xlarge|g2.2xlarge|g2.8xlarge|cg1.4xlarge|r3.large|r3.xlarge|r3.2xlarge|r3.4xlarge|r3.8xlarge|d2.xlarge|d2.2xlarge|d2.4xlarge|d2.8xlarge',
                        'Platform' => '<string>',
                    ],
                ],
                // ...
            ],
            'ReservedInstancesIds' => [
                [
                    'ReservedInstancesId' => '<string>',
                ],
                // ...
            ],
            'ReservedInstancesModificationId' => '<string>',
            'Status' => '<string>',
            'StatusMessage' => '<string>',
            'UpdateDate' => <DateTime>,
        ],
        // ...
    ],
]

Result Details

Members
NextToken
Type: string

The token to use to retrieve the next page of results. This value is null when there are no more results to return.

ReservedInstancesModifications
Type: Array of ReservedInstancesModification structures

The Reserved Instance modification information.

Errors

There are no errors described for this operation.

DescribeReservedInstancesOfferings

$result = $client->describeReservedInstancesOfferings([/* ... */]);
$promise = $client->describeReservedInstancesOfferingsAsync([/* ... */]);

Describes Reserved Instance offerings that are available for purchase. With Reserved Instances, you purchase the right to launch instances for a period of time. During that time period, you do not receive insufficient capacity errors, and you pay a lower usage rate than the rate charged for On-Demand instances for the actual time used.

If you have listed your own Reserved Instances for sale in the Reserved Instance Marketplace, they will be excluded from these results. This is to ensure that you do not purchase your own Reserved Instances.

For more information, see Reserved Instance Marketplace in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->describeReservedInstancesOfferings([
    'AvailabilityZone' => '<string>',
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'IncludeMarketplace' => true || false,
    'InstanceTenancy' => 'default|dedicated|host',
    'InstanceType' => 't1.micro|m1.small|m1.medium|m1.large|m1.xlarge|m3.medium|m3.large|m3.xlarge|m3.2xlarge|m4.large|m4.xlarge|m4.2xlarge|m4.4xlarge|m4.10xlarge|t2.nano|t2.micro|t2.small|t2.medium|t2.large|m2.xlarge|m2.2xlarge|m2.4xlarge|cr1.8xlarge|x1.4xlarge|x1.8xlarge|x1.16xlarge|x1.32xlarge|i2.xlarge|i2.2xlarge|i2.4xlarge|i2.8xlarge|hi1.4xlarge|hs1.8xlarge|c1.medium|c1.xlarge|c3.large|c3.xlarge|c3.2xlarge|c3.4xlarge|c3.8xlarge|c4.large|c4.xlarge|c4.2xlarge|c4.4xlarge|c4.8xlarge|cc1.4xlarge|cc2.8xlarge|g2.2xlarge|g2.8xlarge|cg1.4xlarge|r3.large|r3.xlarge|r3.2xlarge|r3.4xlarge|r3.8xlarge|d2.xlarge|d2.2xlarge|d2.4xlarge|d2.8xlarge',
    'MaxDuration' => <integer>,
    'MaxInstanceCount' => <integer>,
    'MaxResults' => <integer>,
    'MinDuration' => <integer>,
    'NextToken' => '<string>',
    'OfferingType' => 'Heavy Utilization|Medium Utilization|Light Utilization|No Upfront|Partial Upfront|All Upfront',
    'ProductDescription' => 'Linux/UNIX|Linux/UNIX (Amazon VPC)|Windows|Windows (Amazon VPC)',
    'ReservedInstancesOfferingIds' => ['<string>', ...],
]);

Parameter Details

Members
AvailabilityZone
Type: string

The Availability Zone in which the Reserved Instance can be used.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • availability-zone - The Availability Zone where the Reserved Instance can be used.

  • duration - The duration of the Reserved Instance (for example, one year or three years), in seconds (31536000 | 94608000).

  • fixed-price - The purchase price of the Reserved Instance (for example, 9800.0).

  • instance-type - The instance type that is covered by the reservation.

  • marketplace - Set to true to show only Reserved Instance Marketplace offerings. When this filter is not used, which is the default behavior, all offerings from both AWS and the Reserved Instance Marketplace are listed.

  • product-description - The Reserved Instance product platform description. Instances that include (Amazon VPC) in the product platform description will only be displayed to EC2-Classic account holders and are for use with Amazon VPC. (Linux/UNIX | Linux/UNIX (Amazon VPC) | SUSE Linux | SUSE Linux (Amazon VPC) | Red Hat Enterprise Linux | Red Hat Enterprise Linux (Amazon VPC) | Windows | Windows (Amazon VPC) | Windows with SQL Server Standard | Windows with SQL Server Standard (Amazon VPC) | Windows with SQL Server Web | Windows with SQL Server Web (Amazon VPC) | Windows with SQL Server Enterprise | Windows with SQL Server Enterprise (Amazon VPC))

  • reserved-instances-offering-id - The Reserved Instances offering ID.

  • usage-price - The usage price of the Reserved Instance, per hour (for example, 0.84).

IncludeMarketplace
Type: boolean

Include Reserved Instance Marketplace offerings in the response.

InstanceTenancy
Type: string

The tenancy of the instances covered by the reservation. A Reserved Instance with a tenancy of dedicated is applied to instances that run in a VPC on single-tenant hardware (i.e., Dedicated Instances).

Default: default

InstanceType
Type: string

The instance type that the reservation will cover (for example, m1.small). For more information, see Instance Types in the Amazon Elastic Compute Cloud User Guide.

MaxDuration
Type: long (int|float)

The maximum duration (in seconds) to filter when searching for offerings.

Default: 94608000 (3 years)

MaxInstanceCount
Type: int

The maximum number of instances to filter when searching for offerings.

Default: 20

MaxResults
Type: int

The maximum number of results to return for the request in a single page. The remaining results of the initial request can be seen by sending another request with the returned NextToken value. The maximum is 100.

Default: 100

MinDuration
Type: long (int|float)

The minimum duration (in seconds) to filter when searching for offerings.

Default: 2592000 (1 month)

NextToken
Type: string

The token to retrieve the next page of results.

OfferingType
Type: string

The Reserved Instance offering type. If you are using tools that predate the 2011-11-01 API version, you only have access to the Medium Utilization Reserved Instance offering type.

ProductDescription
Type: string

The Reserved Instance product platform description. Instances that include (Amazon VPC) in the description are for use with Amazon VPC.

ReservedInstancesOfferingIds
Type: Array of strings

One or more Reserved Instances offering IDs.

Result Syntax

[
    'NextToken' => '<string>',
    'ReservedInstancesOfferings' => [
        [
            'AvailabilityZone' => '<string>',
            'CurrencyCode' => 'USD',
            'Duration' => <integer>,
            'FixedPrice' => <float>,
            'InstanceTenancy' => 'default|dedicated|host',
            'InstanceType' => 't1.micro|m1.small|m1.medium|m1.large|m1.xlarge|m3.medium|m3.large|m3.xlarge|m3.2xlarge|m4.large|m4.xlarge|m4.2xlarge|m4.4xlarge|m4.10xlarge|t2.nano|t2.micro|t2.small|t2.medium|t2.large|m2.xlarge|m2.2xlarge|m2.4xlarge|cr1.8xlarge|x1.4xlarge|x1.8xlarge|x1.16xlarge|x1.32xlarge|i2.xlarge|i2.2xlarge|i2.4xlarge|i2.8xlarge|hi1.4xlarge|hs1.8xlarge|c1.medium|c1.xlarge|c3.large|c3.xlarge|c3.2xlarge|c3.4xlarge|c3.8xlarge|c4.large|c4.xlarge|c4.2xlarge|c4.4xlarge|c4.8xlarge|cc1.4xlarge|cc2.8xlarge|g2.2xlarge|g2.8xlarge|cg1.4xlarge|r3.large|r3.xlarge|r3.2xlarge|r3.4xlarge|r3.8xlarge|d2.xlarge|d2.2xlarge|d2.4xlarge|d2.8xlarge',
            'Marketplace' => true || false,
            'OfferingType' => 'Heavy Utilization|Medium Utilization|Light Utilization|No Upfront|Partial Upfront|All Upfront',
            'PricingDetails' => [
                [
                    'Count' => <integer>,
                    'Price' => <float>,
                ],
                // ...
            ],
            'ProductDescription' => 'Linux/UNIX|Linux/UNIX (Amazon VPC)|Windows|Windows (Amazon VPC)',
            'RecurringCharges' => [
                [
                    'Amount' => <float>,
                    'Frequency' => 'Hourly',
                ],
                // ...
            ],
            'ReservedInstancesOfferingId' => '<string>',
            'UsagePrice' => <float>,
        ],
        // ...
    ],
]

Result Details

Members
NextToken
Type: string

The token to use to retrieve the next page of results. This value is null when there are no more results to return.

ReservedInstancesOfferings
Type: Array of ReservedInstancesOffering structures

A list of Reserved Instances offerings.

Errors

There are no errors described for this operation.

DescribeRouteTables

$result = $client->describeRouteTables([/* ... */]);
$promise = $client->describeRouteTablesAsync([/* ... */]);

Describes one or more of your route tables.

Each subnet in your VPC must be associated with a route table. If a subnet is not explicitly associated with any route table, it is implicitly associated with the main route table. This command does not return the subnet ID for implicit associations.

For more information about route tables, see Route Tables in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->describeRouteTables([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'RouteTableIds' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • association.route-table-association-id - The ID of an association ID for the route table.

  • association.route-table-id - The ID of the route table involved in the association.

  • association.subnet-id - The ID of the subnet involved in the association.

  • association.main - Indicates whether the route table is the main route table for the VPC (true | false).

  • route-table-id - The ID of the route table.

  • route.destination-cidr-block - The CIDR range specified in a route in the table.

  • route.destination-prefix-list-id - The ID (prefix) of the AWS service specified in a route in the table.

  • route.gateway-id - The ID of a gateway specified in a route in the table.

  • route.instance-id - The ID of an instance specified in a route in the table.

  • route.nat-gateway-id - The ID of a NAT gateway.

  • route.origin - Describes how the route was created. CreateRouteTable indicates that the route was automatically created when the route table was created; CreateRoute indicates that the route was manually added to the route table; EnableVgwRoutePropagation indicates that the route was propagated by route propagation.

  • route.state - The state of a route in the route table (active | blackhole). The blackhole state indicates that the route's target isn't available (for example, the specified gateway isn't attached to the VPC, the specified NAT instance has been terminated, and so on).

  • route.vpc-peering-connection-id - The ID of a VPC peering connection specified in a route in the table.

  • tag:key=value - The key/value combination of a tag assigned to the resource.

  • tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag:key=value filter.

  • tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.

  • vpc-id - The ID of the VPC for the route table.

RouteTableIds
Type: Array of strings

One or more route table IDs.

Default: Describes all your route tables.

Result Syntax

[
    'RouteTables' => [
        [
            'Associations' => [
                [
                    'Main' => true || false,
                    'RouteTableAssociationId' => '<string>',
                    'RouteTableId' => '<string>',
                    'SubnetId' => '<string>',
                ],
                // ...
            ],
            'PropagatingVgws' => [
                [
                    'GatewayId' => '<string>',
                ],
                // ...
            ],
            'RouteTableId' => '<string>',
            'Routes' => [
                [
                    'DestinationCidrBlock' => '<string>',
                    'DestinationPrefixListId' => '<string>',
                    'GatewayId' => '<string>',
                    'InstanceId' => '<string>',
                    'InstanceOwnerId' => '<string>',
                    'NatGatewayId' => '<string>',
                    'NetworkInterfaceId' => '<string>',
                    'Origin' => 'CreateRouteTable|CreateRoute|EnableVgwRoutePropagation',
                    'State' => 'active|blackhole',
                    'VpcPeeringConnectionId' => '<string>',
                ],
                // ...
            ],
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'VpcId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
RouteTables
Type: Array of RouteTable structures

Information about one or more route tables.

Errors

There are no errors described for this operation.

DescribeScheduledInstanceAvailability

$result = $client->describeScheduledInstanceAvailability([/* ... */]);
$promise = $client->describeScheduledInstanceAvailabilityAsync([/* ... */]);

Finds available schedules that meet the specified criteria.

You can search for an available schedule no more than 3 months in advance. You must meet the minimum required duration of 1,200 hours per year. For example, the minimum daily schedule is 4 hours, the minimum weekly schedule is 24 hours, and the minimum monthly schedule is 100 hours.

After you find a schedule that meets your needs, call PurchaseScheduledInstances to purchase Scheduled Instances with that schedule.

Parameter Syntax

$result = $client->describeScheduledInstanceAvailability([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'FirstSlotStartTimeRange' => [ // REQUIRED
        'EarliestTime' => <integer || string || DateTime>, // REQUIRED
        'LatestTime' => <integer || string || DateTime>, // REQUIRED
    ],
    'MaxResults' => <integer>,
    'MaxSlotDurationInHours' => <integer>,
    'MinSlotDurationInHours' => <integer>,
    'NextToken' => '<string>',
    'Recurrence' => [ // REQUIRED
        'Frequency' => '<string>',
        'Interval' => <integer>,
        'OccurrenceDays' => [<integer>, ...],
        'OccurrenceRelativeToEnd' => true || false,
        'OccurrenceUnit' => '<string>',
    ],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • availability-zone - The Availability Zone (for example, us-west-2a).

  • instance-type - The instance type (for example, c4.large).

  • network-platform - The network platform (EC2-Classic or EC2-VPC).

  • platform - The platform (Linux/UNIX or Windows).

FirstSlotStartTimeRange
Required: Yes
Type: SlotDateTimeRangeRequest structure

The time period for the first schedule to start.

MaxResults
Type: int

The maximum number of results to return in a single call. This value can be between 5 and 300. The default value is 300. To retrieve the remaining results, make another call with the returned NextToken value.

MaxSlotDurationInHours
Type: int

The maximum available duration, in hours. This value must be greater than MinSlotDurationInHours and less than 1,720.

MinSlotDurationInHours
Type: int

The minimum available duration, in hours. The minimum required duration is 1,200 hours per year. For example, the minimum daily schedule is 4 hours, the minimum weekly schedule is 24 hours, and the minimum monthly schedule is 100 hours.

NextToken
Type: string

The token for the next set of results.

Recurrence
Required: Yes
Type: ScheduledInstanceRecurrenceRequest structure

The schedule recurrence.

Result Syntax

[
    'NextToken' => '<string>',
    'ScheduledInstanceAvailabilitySet' => [
        [
            'AvailabilityZone' => '<string>',
            'AvailableInstanceCount' => <integer>,
            'FirstSlotStartTime' => <DateTime>,
            'HourlyPrice' => '<string>',
            'InstanceType' => '<string>',
            'MaxTermDurationInDays' => <integer>,
            'MinTermDurationInDays' => <integer>,
            'NetworkPlatform' => '<string>',
            'Platform' => '<string>',
            'PurchaseToken' => '<string>',
            'Recurrence' => [
                'Frequency' => '<string>',
                'Interval' => <integer>,
                'OccurrenceDaySet' => [<integer>, ...],
                'OccurrenceRelativeToEnd' => true || false,
                'OccurrenceUnit' => '<string>',
            ],
            'SlotDurationInHours' => <integer>,
            'TotalScheduledInstanceHours' => <integer>,
        ],
        // ...
    ],
]

Result Details

Members
NextToken
Type: string

The token required to retrieve the next set of results. This value is null when there are no more results to return.

ScheduledInstanceAvailabilitySet
Type: Array of ScheduledInstanceAvailability structures

Information about the available Scheduled Instances.

Errors

There are no errors described for this operation.

DescribeScheduledInstances

$result = $client->describeScheduledInstances([/* ... */]);
$promise = $client->describeScheduledInstancesAsync([/* ... */]);

Describes one or more of your Scheduled Instances.

Parameter Syntax

$result = $client->describeScheduledInstances([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
    'ScheduledInstanceIds' => ['<string>', ...],
    'SlotStartTimeRange' => [
        'EarliestTime' => <integer || string || DateTime>,
        'LatestTime' => <integer || string || DateTime>,
    ],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • availability-zone - The Availability Zone (for example, us-west-2a).

  • instance-type - The instance type (for example, c4.large).

  • network-platform - The network platform (EC2-Classic or EC2-VPC).

  • platform - The platform (Linux/UNIX or Windows).

MaxResults
Type: int

The maximum number of results to return in a single call. This value can be between 5 and 300. The default value is 100. To retrieve the remaining results, make another call with the returned NextToken value.

NextToken
Type: string

The token for the next set of results.

ScheduledInstanceIds
Type: Array of strings

One or more Scheduled Instance IDs.

SlotStartTimeRange
Type: SlotStartTimeRangeRequest structure

The time period for the first schedule to start.

Result Syntax

[
    'NextToken' => '<string>',
    'ScheduledInstanceSet' => [
        [
            'AvailabilityZone' => '<string>',
            'CreateDate' => <DateTime>,
            'HourlyPrice' => '<string>',
            'InstanceCount' => <integer>,
            'InstanceType' => '<string>',
            'NetworkPlatform' => '<string>',
            'NextSlotStartTime' => <DateTime>,
            'Platform' => '<string>',
            'PreviousSlotEndTime' => <DateTime>,
            'Recurrence' => [
                'Frequency' => '<string>',
                'Interval' => <integer>,
                'OccurrenceDaySet' => [<integer>, ...],
                'OccurrenceRelativeToEnd' => true || false,
                'OccurrenceUnit' => '<string>',
            ],
            'ScheduledInstanceId' => '<string>',
            'SlotDurationInHours' => <integer>,
            'TermEndDate' => <DateTime>,
            'TermStartDate' => <DateTime>,
            'TotalScheduledInstanceHours' => <integer>,
        ],
        // ...
    ],
]

Result Details

Members
NextToken
Type: string

The token required to retrieve the next set of results. This value is null when there are no more results to return.

ScheduledInstanceSet
Type: Array of ScheduledInstance structures

Information about the Scheduled Instances.

Errors

There are no errors described for this operation.

DescribeSecurityGroupReferences

$result = $client->describeSecurityGroupReferences([/* ... */]);
$promise = $client->describeSecurityGroupReferencesAsync([/* ... */]);

[EC2-VPC only] Describes the VPCs on the other side of a VPC peering connection that are referencing the security groups you've specified in this request.

Parameter Syntax

$result = $client->describeSecurityGroupReferences([
    'DryRun' => true || false,
    'GroupId' => ['<string>', ...], // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the operation, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

GroupId
Required: Yes
Type: Array of strings

One or more security group IDs in your account.

Result Syntax

[
    'SecurityGroupReferenceSet' => [
        [
            'GroupId' => '<string>',
            'ReferencingVpcId' => '<string>',
            'VpcPeeringConnectionId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
SecurityGroupReferenceSet
Type: Array of SecurityGroupReference structures

Information about the VPCs with the referencing security groups.

Errors

There are no errors described for this operation.

DescribeSecurityGroups

$result = $client->describeSecurityGroups([/* ... */]);
$promise = $client->describeSecurityGroupsAsync([/* ... */]);

Describes one or more of your security groups.

A security group is for use with instances either in the EC2-Classic platform or in a specific VPC. For more information, see Amazon EC2 Security Groups in the Amazon Elastic Compute Cloud User Guide and Security Groups for Your VPC in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->describeSecurityGroups([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'GroupIds' => ['<string>', ...],
    'GroupNames' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters. If using multiple filters for rules, the results include security groups for which any combination of rules - not necessarily a single rule - match all filters.

  • description - The description of the security group.

  • egress.ip-permission.prefix-list-id - The ID (prefix) of the AWS service to which the security group allows access.

  • group-id - The ID of the security group.

  • group-name - The name of the security group.

  • ip-permission.cidr - A CIDR range that has been granted permission.

  • ip-permission.from-port - The start of port range for the TCP and UDP protocols, or an ICMP type number.

  • ip-permission.group-id - The ID of a security group that has been granted permission.

  • ip-permission.group-name - The name of a security group that has been granted permission.

  • ip-permission.protocol - The IP protocol for the permission (tcp | udp | icmp or a protocol number).

  • ip-permission.to-port - The end of port range for the TCP and UDP protocols, or an ICMP code.

  • ip-permission.user-id - The ID of an AWS account that has been granted permission.

  • owner-id - The AWS account ID of the owner of the security group.

  • tag-key - The key of a tag assigned to the security group.

  • tag-value - The value of a tag assigned to the security group.

  • vpc-id - The ID of the VPC specified when the security group was created.

GroupIds
Type: Array of strings

One or more security group IDs. Required for security groups in a nondefault VPC.

Default: Describes all your security groups.

GroupNames
Type: Array of strings

[EC2-Classic and default VPC only] One or more security group names. You can specify either the security group name or the security group ID. For security groups in a nondefault VPC, use the group-name filter to describe security groups by name.

Default: Describes all your security groups.

Result Syntax

[
    'SecurityGroups' => [
        [
            'Description' => '<string>',
            'GroupId' => '<string>',
            'GroupName' => '<string>',
            'IpPermissions' => [
                [
                    'FromPort' => <integer>,
                    'IpProtocol' => '<string>',
                    'IpRanges' => [
                        [
                            'CidrIp' => '<string>',
                        ],
                        // ...
                    ],
                    'PrefixListIds' => [
                        [
                            'PrefixListId' => '<string>',
                        ],
                        // ...
                    ],
                    'ToPort' => <integer>,
                    'UserIdGroupPairs' => [
                        [
                            'GroupId' => '<string>',
                            'GroupName' => '<string>',
                            'PeeringStatus' => '<string>',
                            'UserId' => '<string>',
                            'VpcId' => '<string>',
                            'VpcPeeringConnectionId' => '<string>',
                        ],
                        // ...
                    ],
                ],
                // ...
            ],
            'IpPermissionsEgress' => [
                [
                    'FromPort' => <integer>,
                    'IpProtocol' => '<string>',
                    'IpRanges' => [
                        [
                            'CidrIp' => '<string>',
                        ],
                        // ...
                    ],
                    'PrefixListIds' => [
                        [
                            'PrefixListId' => '<string>',
                        ],
                        // ...
                    ],
                    'ToPort' => <integer>,
                    'UserIdGroupPairs' => [
                        [
                            'GroupId' => '<string>',
                            'GroupName' => '<string>',
                            'PeeringStatus' => '<string>',
                            'UserId' => '<string>',
                            'VpcId' => '<string>',
                            'VpcPeeringConnectionId' => '<string>',
                        ],
                        // ...
                    ],
                ],
                // ...
            ],
            'OwnerId' => '<string>',
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'VpcId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
SecurityGroups
Type: Array of SecurityGroup structures

Information about one or more security groups.

Errors

There are no errors described for this operation.

DescribeSnapshotAttribute

$result = $client->describeSnapshotAttribute([/* ... */]);
$promise = $client->describeSnapshotAttributeAsync([/* ... */]);

Describes the specified attribute of the specified snapshot. You can specify only one attribute at a time.

For more information about EBS snapshots, see Amazon EBS Snapshots in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->describeSnapshotAttribute([
    'Attribute' => 'productCodes|createVolumePermission', // REQUIRED
    'DryRun' => true || false,
    'SnapshotId' => '<string>', // REQUIRED
]);

Parameter Details

Members
Attribute
Required: Yes
Type: string

The snapshot attribute you would like to view.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

SnapshotId
Required: Yes
Type: string

The ID of the EBS snapshot.

Result Syntax

[
    'CreateVolumePermissions' => [
        [
            'Group' => 'all',
            'UserId' => '<string>',
        ],
        // ...
    ],
    'ProductCodes' => [
        [
            'ProductCodeId' => '<string>',
            'ProductCodeType' => 'devpay|marketplace',
        ],
        // ...
    ],
    'SnapshotId' => '<string>',
]

Result Details

Members
CreateVolumePermissions
Type: Array of CreateVolumePermission structures

A list of permissions for creating volumes from the snapshot.

ProductCodes
Type: Array of ProductCode structures

A list of product codes.

SnapshotId
Type: string

The ID of the EBS snapshot.

Errors

There are no errors described for this operation.

DescribeSnapshots

$result = $client->describeSnapshots([/* ... */]);
$promise = $client->describeSnapshotsAsync([/* ... */]);

Describes one or more of the EBS snapshots available to you. Available snapshots include public snapshots available for any AWS account to launch, private snapshots that you own, and private snapshots owned by another AWS account but for which you've been given explicit create volume permissions.

The create volume permissions fall into the following categories:

  • public: The owner of the snapshot granted create volume permissions for the snapshot to the all group. All AWS accounts have create volume permissions for these snapshots.

  • explicit: The owner of the snapshot granted create volume permissions to a specific AWS account.

  • implicit: An AWS account has implicit create volume permissions for all snapshots it owns.

The list of snapshots returned can be modified by specifying snapshot IDs, snapshot owners, or AWS accounts with create volume permissions. If no options are specified, Amazon EC2 returns all snapshots for which you have create volume permissions.

If you specify one or more snapshot IDs, only snapshots that have the specified IDs are returned. If you specify an invalid snapshot ID, an error is returned. If you specify a snapshot ID for which you do not have access, it is not included in the returned results.

If you specify one or more snapshot owners, only snapshots from the specified owners and for which you have access are returned. The results can include the AWS account IDs of the specified owners, amazon for snapshots owned by Amazon, or self for snapshots that you own.

If you specify a list of restorable users, only snapshots with create snapshot permissions for those users are returned. You can specify AWS account IDs (if you own the snapshots), self for snapshots for which you own or have explicit permissions, or all for public snapshots.

If you are describing a long list of snapshots, you can paginate the output to make the list more manageable. The MaxResults parameter sets the maximum number of results returned in a single page. If the list of results exceeds your MaxResults value, then that number of results is returned along with a NextToken value that can be passed to a subsequent DescribeSnapshots request to retrieve the remaining results.

For more information about EBS snapshots, see Amazon EBS Snapshots in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->describeSnapshots([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
    'OwnerIds' => ['<string>', ...],
    'RestorableByUserIds' => ['<string>', ...],
    'SnapshotIds' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • description - A description of the snapshot.

  • owner-alias - The AWS account alias (for example, amazon) that owns the snapshot.

  • owner-id - The ID of the AWS account that owns the snapshot.

  • progress - The progress of the snapshot, as a percentage (for example, 80%).

  • snapshot-id - The snapshot ID.

  • start-time - The time stamp when the snapshot was initiated.

  • status - The status of the snapshot (pending | completed | error).

  • tag:key=value - The key/value combination of a tag assigned to the resource.

  • tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag:key=value filter.

  • tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.

  • volume-id - The ID of the volume the snapshot is for.

  • volume-size - The size of the volume, in GiB.

MaxResults
Type: int

The maximum number of snapshot results returned by DescribeSnapshots in paginated output. When this parameter is used, DescribeSnapshots only returns MaxResults results in a single page along with a NextToken response element. The remaining results of the initial request can be seen by sending another DescribeSnapshots request with the returned NextToken value. This value can be between 5 and 1000; if MaxResults is given a value larger than 1000, only 1000 results are returned. If this parameter is not used, then DescribeSnapshots returns all results. You cannot specify this parameter and the snapshot IDs parameter in the same request.

NextToken
Type: string

The NextToken value returned from a previous paginated DescribeSnapshots request where MaxResults was used and the results exceeded the value of that parameter. Pagination continues from the end of the previous results that returned the NextToken value. This value is null when there are no more results to return.

OwnerIds
Type: Array of strings

Returns the snapshots owned by the specified owner. Multiple owners can be specified.

RestorableByUserIds
Type: Array of strings

One or more AWS accounts IDs that can create volumes from the snapshot.

SnapshotIds
Type: Array of strings

One or more snapshot IDs.

Default: Describes snapshots for which you have launch permissions.

Result Syntax

[
    'NextToken' => '<string>',
    'Snapshots' => [
        [
            'DataEncryptionKeyId' => '<string>',
            'Description' => '<string>',
            'Encrypted' => true || false,
            'KmsKeyId' => '<string>',
            'OwnerAlias' => '<string>',
            'OwnerId' => '<string>',
            'Progress' => '<string>',
            'SnapshotId' => '<string>',
            'StartTime' => <DateTime>,
            'State' => 'pending|completed|error',
            'StateMessage' => '<string>',
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'VolumeId' => '<string>',
            'VolumeSize' => <integer>,
        ],
        // ...
    ],
]

Result Details

Members
NextToken
Type: string

The NextToken value to include in a future DescribeSnapshots request. When the results of a DescribeSnapshots request exceed MaxResults, this value can be used to retrieve the next page of results. This value is null when there are no more results to return.

Snapshots
Type: Array of Snapshot structures

Information about the snapshots.

Errors

There are no errors described for this operation.

DescribeSpotDatafeedSubscription

$result = $client->describeSpotDatafeedSubscription([/* ... */]);
$promise = $client->describeSpotDatafeedSubscriptionAsync([/* ... */]);

Describes the data feed for Spot instances. For more information, see Spot Instance Data Feed in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->describeSpotDatafeedSubscription([
    'DryRun' => true || false,
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Result Syntax

[
    'SpotDatafeedSubscription' => [
        'Bucket' => '<string>',
        'Fault' => [
            'Code' => '<string>',
            'Message' => '<string>',
        ],
        'OwnerId' => '<string>',
        'Prefix' => '<string>',
        'State' => 'Active|Inactive',
    ],
]

Result Details

Members
SpotDatafeedSubscription
Type: SpotDatafeedSubscription structure

The Spot instance data feed subscription.

Errors

There are no errors described for this operation.

DescribeSpotFleetInstances

$result = $client->describeSpotFleetInstances([/* ... */]);
$promise = $client->describeSpotFleetInstancesAsync([/* ... */]);

Describes the running instances for the specified Spot fleet.

Parameter Syntax

$result = $client->describeSpotFleetInstances([
    'DryRun' => true || false,
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
    'SpotFleetRequestId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

MaxResults
Type: int

The maximum number of results to return in a single call. Specify a value between 1 and 1000. The default value is 1000. To retrieve the remaining results, make another call with the returned NextToken value.

NextToken
Type: string

The token for the next set of results.

SpotFleetRequestId
Required: Yes
Type: string

The ID of the Spot fleet request.

Result Syntax

[
    'ActiveInstances' => [
        [
            'InstanceId' => '<string>',
            'InstanceType' => '<string>',
            'SpotInstanceRequestId' => '<string>',
        ],
        // ...
    ],
    'NextToken' => '<string>',
    'SpotFleetRequestId' => '<string>',
]

Result Details

Members
ActiveInstances
Required: Yes
Type: Array of ActiveInstance structures

The running instances. Note that this list is refreshed periodically and might be out of date.

NextToken
Type: string

The token required to retrieve the next set of results. This value is null when there are no more results to return.

SpotFleetRequestId
Required: Yes
Type: string

The ID of the Spot fleet request.

Errors

There are no errors described for this operation.

DescribeSpotFleetRequestHistory

$result = $client->describeSpotFleetRequestHistory([/* ... */]);
$promise = $client->describeSpotFleetRequestHistoryAsync([/* ... */]);

Describes the events for the specified Spot fleet request during the specified time.

Spot fleet events are delayed by up to 30 seconds before they can be described. This ensures that you can query by the last evaluated time and not miss a recorded event.

Parameter Syntax

$result = $client->describeSpotFleetRequestHistory([
    'DryRun' => true || false,
    'EventType' => 'instanceChange|fleetRequestChange|error',
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
    'SpotFleetRequestId' => '<string>', // REQUIRED
    'StartTime' => <integer || string || DateTime>, // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

EventType
Type: string

The type of events to describe. By default, all events are described.

MaxResults
Type: int

The maximum number of results to return in a single call. Specify a value between 1 and 1000. The default value is 1000. To retrieve the remaining results, make another call with the returned NextToken value.

NextToken
Type: string

The token for the next set of results.

SpotFleetRequestId
Required: Yes
Type: string

The ID of the Spot fleet request.

StartTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The starting date and time for the events, in UTC format (for example, YYYY-MM-DDTHH:MM:SSZ).

Result Syntax

[
    'HistoryRecords' => [
        [
            'EventInformation' => [
                'EventDescription' => '<string>',
                'EventSubType' => '<string>',
                'InstanceId' => '<string>',
            ],
            'EventType' => 'instanceChange|fleetRequestChange|error',
            'Timestamp' => <DateTime>,
        ],
        // ...
    ],
    'LastEvaluatedTime' => <DateTime>,
    'NextToken' => '<string>',
    'SpotFleetRequestId' => '<string>',
    'StartTime' => <DateTime>,
]

Result Details

Members
HistoryRecords
Required: Yes
Type: Array of HistoryRecord structures

Information about the events in the history of the Spot fleet request.

LastEvaluatedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The last date and time for the events, in UTC format (for example, YYYY-MM-DDTHH:MM:SSZ). All records up to this time were retrieved.

If nextToken indicates that there are more results, this value is not present.

NextToken
Type: string

The token required to retrieve the next set of results. This value is null when there are no more results to return.

SpotFleetRequestId
Required: Yes
Type: string

The ID of the Spot fleet request.

StartTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The starting date and time for the events, in UTC format (for example, YYYY-MM-DDTHH:MM:SSZ).

Errors

There are no errors described for this operation.

DescribeSpotFleetRequests

$result = $client->describeSpotFleetRequests([/* ... */]);
$promise = $client->describeSpotFleetRequestsAsync([/* ... */]);

Describes your Spot fleet requests.

Parameter Syntax

$result = $client->describeSpotFleetRequests([
    'DryRun' => true || false,
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
    'SpotFleetRequestIds' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

MaxResults
Type: int

The maximum number of results to return in a single call. Specify a value between 1 and 1000. The default value is 1000. To retrieve the remaining results, make another call with the returned NextToken value.

NextToken
Type: string

The token for the next set of results.

SpotFleetRequestIds
Type: Array of strings

The IDs of the Spot fleet requests.

Result Syntax

[
    'NextToken' => '<string>',
    'SpotFleetRequestConfigs' => [
        [
            'CreateTime' => <DateTime>,
            'SpotFleetRequestConfig' => [
                'AllocationStrategy' => 'lowestPrice|diversified',
                'ClientToken' => '<string>',
                'ExcessCapacityTerminationPolicy' => 'noTermination|default',
                'FulfilledCapacity' => <float>,
                'IamFleetRole' => '<string>',
                'LaunchSpecifications' => [
                    [
                        'AddressingType' => '<string>',
                        'BlockDeviceMappings' => [
                            [
                                'DeviceName' => '<string>',
                                'Ebs' => [
                                    'DeleteOnTermination' => true || false,
                                    'Encrypted' => true || false,
                                    'Iops' => <integer>,
                                    'SnapshotId' => '<string>',
                                    'VolumeSize' => <integer>,
                                    'VolumeType' => 'standard|io1|gp2|sc1|st1',
                                ],
                                'NoDevice' => '<string>',
                                'VirtualName' => '<string>',
                            ],
                            // ...
                        ],
                        'EbsOptimized' => true || false,
                        'IamInstanceProfile' => [
                            'Arn' => '<string>',
                            'Name' => '<string>',
                        ],
                        'ImageId' => '<string>',
                        'InstanceType' => 't1.micro|m1.small|m1.medium|m1.large|m1.xlarge|m3.medium|m3.large|m3.xlarge|m3.2xlarge|m4.large|m4.xlarge|m4.2xlarge|m4.4xlarge|m4.10xlarge|t2.nano|t2.micro|t2.small|t2.medium|t2.large|m2.xlarge|m2.2xlarge|m2.4xlarge|cr1.8xlarge|x1.4xlarge|x1.8xlarge|x1.16xlarge|x1.32xlarge|i2.xlarge|i2.2xlarge|i2.4xlarge|i2.8xlarge|hi1.4xlarge|hs1.8xlarge|c1.medium|c1.xlarge|c3.large|c3.xlarge|c3.2xlarge|c3.4xlarge|c3.8xlarge|c4.large|c4.xlarge|c4.2xlarge|c4.4xlarge|c4.8xlarge|cc1.4xlarge|cc2.8xlarge|g2.2xlarge|g2.8xlarge|cg1.4xlarge|r3.large|r3.xlarge|r3.2xlarge|r3.4xlarge|r3.8xlarge|d2.xlarge|d2.2xlarge|d2.4xlarge|d2.8xlarge',
                        'KernelId' => '<string>',
                        'KeyName' => '<string>',
                        'Monitoring' => [
                            'Enabled' => true || false,
                        ],
                        'NetworkInterfaces' => [
                            [
                                'AssociatePublicIpAddress' => true || false,
                                'DeleteOnTermination' => true || false,
                                'Description' => '<string>',
                                'DeviceIndex' => <integer>,
                                'Groups' => ['<string>', ...],
                                'NetworkInterfaceId' => '<string>',
                                'PrivateIpAddress' => '<string>',
                                'PrivateIpAddresses' => [
                                    [
                                        'Primary' => true || false,
                                        'PrivateIpAddress' => '<string>',
                                    ],
                                    // ...
                                ],
                                'SecondaryPrivateIpAddressCount' => <integer>,
                                'SubnetId' => '<string>',
                            ],
                            // ...
                        ],
                        'Placement' => [
                            'AvailabilityZone' => '<string>',
                            'GroupName' => '<string>',
                        ],
                        'RamdiskId' => '<string>',
                        'SecurityGroups' => [
                            [
                                'GroupId' => '<string>',
                                'GroupName' => '<string>',
                            ],
                            // ...
                        ],
                        'SpotPrice' => '<string>',
                        'SubnetId' => '<string>',
                        'UserData' => '<string>',
                        'WeightedCapacity' => <float>,
                    ],
                    // ...
                ],
                'SpotPrice' => '<string>',
                'TargetCapacity' => <integer>,
                'TerminateInstancesWithExpiration' => true || false,
                'Type' => 'request|maintain',
                'ValidFrom' => <DateTime>,
                'ValidUntil' => <DateTime>,
            ],
            'SpotFleetRequestId' => '<string>',
            'SpotFleetRequestState' => 'submitted|active|cancelled|failed|cancelled_running|cancelled_terminating|modifying',
        ],
        // ...
    ],
]

Result Details

Members
NextToken
Type: string

The token required to retrieve the next set of results. This value is null when there are no more results to return.

SpotFleetRequestConfigs
Required: Yes
Type: Array of SpotFleetRequestConfig structures

Information about the configuration of your Spot fleet.

Errors

There are no errors described for this operation.

DescribeSpotInstanceRequests

$result = $client->describeSpotInstanceRequests([/* ... */]);
$promise = $client->describeSpotInstanceRequestsAsync([/* ... */]);

Describes the Spot instance requests that belong to your account. Spot instances are instances that Amazon EC2 launches when the bid price that you specify exceeds the current Spot price. Amazon EC2 periodically sets the Spot price based on available Spot instance capacity and current Spot instance requests. For more information, see Spot Instance Requests in the Amazon Elastic Compute Cloud User Guide.

You can use DescribeSpotInstanceRequests to find a running Spot instance by examining the response. If the status of the Spot instance is fulfilled, the instance ID appears in the response and contains the identifier of the instance. Alternatively, you can use DescribeInstances with a filter to look for instances where the instance lifecycle is spot.

Parameter Syntax

$result = $client->describeSpotInstanceRequests([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'SpotInstanceRequestIds' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • availability-zone-group - The Availability Zone group.

  • create-time - The time stamp when the Spot instance request was created.

  • fault-code - The fault code related to the request.

  • fault-message - The fault message related to the request.

  • instance-id - The ID of the instance that fulfilled the request.

  • launch-group - The Spot instance launch group.

  • launch.block-device-mapping.delete-on-termination - Indicates whether the Amazon EBS volume is deleted on instance termination.

  • launch.block-device-mapping.device-name - The device name for the Amazon EBS volume (for example, /dev/sdh).

  • launch.block-device-mapping.snapshot-id - The ID of the snapshot used for the Amazon EBS volume.

  • launch.block-device-mapping.volume-size - The size of the Amazon EBS volume, in GiB.

  • launch.block-device-mapping.volume-type - The type of the Amazon EBS volume: gp2 for General Purpose SSD, io1 for Provisioned IOPS SSD, st1 for Throughput Optimized HDD, sc1for Cold HDD, or standard for Magnetic.

  • launch.group-id - The security group for the instance.

  • launch.image-id - The ID of the AMI.

  • launch.instance-type - The type of instance (for example, m3.medium).

  • launch.kernel-id - The kernel ID.

  • launch.key-name - The name of the key pair the instance launched with.

  • launch.monitoring-enabled - Whether monitoring is enabled for the Spot instance.

  • launch.ramdisk-id - The RAM disk ID.

  • network-interface.network-interface-id - The ID of the network interface.

  • network-interface.device-index - The index of the device for the network interface attachment on the instance.

  • network-interface.subnet-id - The ID of the subnet for the instance.

  • network-interface.description - A description of the network interface.

  • network-interface.private-ip-address - The primary private IP address of the network interface.

  • network-interface.delete-on-termination - Indicates whether the network interface is deleted when the instance is terminated.

  • network-interface.group-id - The ID of the security group associated with the network interface.

  • network-interface.group-name - The name of the security group associated with the network interface.

  • network-interface.addresses.primary - Indicates whether the IP address is the primary private IP address.

  • product-description - The product description associated with the instance (Linux/UNIX | Windows).

  • spot-instance-request-id - The Spot instance request ID.

  • spot-price - The maximum hourly price for any Spot instance launched to fulfill the request.

  • state - The state of the Spot instance request (open | active | closed | cancelled | failed). Spot bid status information can help you track your Amazon EC2 Spot instance requests. For more information, see Spot Bid Status in the Amazon Elastic Compute Cloud User Guide.

  • status-code - The short code describing the most recent evaluation of your Spot instance request.

  • status-message - The message explaining the status of the Spot instance request.

  • tag:key=value - The key/value combination of a tag assigned to the resource.

  • tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag:key=value filter.

  • tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.

  • type - The type of Spot instance request (one-time | persistent).

  • launched-availability-zone - The Availability Zone in which the bid is launched.

  • valid-from - The start date of the request.

  • valid-until - The end date of the request.

SpotInstanceRequestIds
Type: Array of strings

One or more Spot instance request IDs.

Result Syntax

[
    'SpotInstanceRequests' => [
        [
            'ActualBlockHourlyPrice' => '<string>',
            'AvailabilityZoneGroup' => '<string>',
            'BlockDurationMinutes' => <integer>,
            'CreateTime' => <DateTime>,
            'Fault' => [
                'Code' => '<string>',
                'Message' => '<string>',
            ],
            'InstanceId' => '<string>',
            'LaunchGroup' => '<string>',
            'LaunchSpecification' => [
                'AddressingType' => '<string>',
                'BlockDeviceMappings' => [
                    [
                        'DeviceName' => '<string>',
                        'Ebs' => [
                            'DeleteOnTermination' => true || false,
                            'Encrypted' => true || false,
                            'Iops' => <integer>,
                            'SnapshotId' => '<string>',
                            'VolumeSize' => <integer>,
                            'VolumeType' => 'standard|io1|gp2|sc1|st1',
                        ],
                        'NoDevice' => '<string>',
                        'VirtualName' => '<string>',
                    ],
                    // ...
                ],
                'EbsOptimized' => true || false,
                'IamInstanceProfile' => [
                    'Arn' => '<string>',
                    'Name' => '<string>',
                ],
                'ImageId' => '<string>',
                'InstanceType' => 't1.micro|m1.small|m1.medium|m1.large|m1.xlarge|m3.medium|m3.large|m3.xlarge|m3.2xlarge|m4.large|m4.xlarge|m4.2xlarge|m4.4xlarge|m4.10xlarge|t2.nano|t2.micro|t2.small|t2.medium|t2.large|m2.xlarge|m2.2xlarge|m2.4xlarge|cr1.8xlarge|x1.4xlarge|x1.8xlarge|x1.16xlarge|x1.32xlarge|i2.xlarge|i2.2xlarge|i2.4xlarge|i2.8xlarge|hi1.4xlarge|hs1.8xlarge|c1.medium|c1.xlarge|c3.large|c3.xlarge|c3.2xlarge|c3.4xlarge|c3.8xlarge|c4.large|c4.xlarge|c4.2xlarge|c4.4xlarge|c4.8xlarge|cc1.4xlarge|cc2.8xlarge|g2.2xlarge|g2.8xlarge|cg1.4xlarge|r3.large|r3.xlarge|r3.2xlarge|r3.4xlarge|r3.8xlarge|d2.xlarge|d2.2xlarge|d2.4xlarge|d2.8xlarge',
                'KernelId' => '<string>',
                'KeyName' => '<string>',
                'Monitoring' => [
                    'Enabled' => true || false,
                ],
                'NetworkInterfaces' => [
                    [
                        'AssociatePublicIpAddress' => true || false,
                        'DeleteOnTermination' => true || false,
                        'Description' => '<string>',
                        'DeviceIndex' => <integer>,
                        'Groups' => ['<string>', ...],
                        'NetworkInterfaceId' => '<string>',
                        'PrivateIpAddress' => '<string>',
                        'PrivateIpAddresses' => [
                            [
                                'Primary' => true || false,
                                'PrivateIpAddress' => '<string>',
                            ],
                            // ...
                        ],
                        'SecondaryPrivateIpAddressCount' => <integer>,
                        'SubnetId' => '<string>',
                    ],
                    // ...
                ],
                'Placement' => [
                    'AvailabilityZone' => '<string>',
                    'GroupName' => '<string>',
                ],
                'RamdiskId' => '<string>',
                'SecurityGroups' => [
                    [
                        'GroupId' => '<string>',
                        'GroupName' => '<string>',
                    ],
                    // ...
                ],
                'SubnetId' => '<string>',
                'UserData' => '<string>',
            ],
            'LaunchedAvailabilityZone' => '<string>',
            'ProductDescription' => 'Linux/UNIX|Linux/UNIX (Amazon VPC)|Windows|Windows (Amazon VPC)',
            'SpotInstanceRequestId' => '<string>',
            'SpotPrice' => '<string>',
            'State' => 'open|active|closed|cancelled|failed',
            'Status' => [
                'Code' => '<string>',
                'Message' => '<string>',
                'UpdateTime' => <DateTime>,
            ],
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'Type' => 'one-time|persistent',
            'ValidFrom' => <DateTime>,
            'ValidUntil' => <DateTime>,
        ],
        // ...
    ],
]

Result Details

Members
SpotInstanceRequests
Type: Array of SpotInstanceRequest structures

One or more Spot instance requests.

Errors

There are no errors described for this operation.

DescribeSpotPriceHistory

$result = $client->describeSpotPriceHistory([/* ... */]);
$promise = $client->describeSpotPriceHistoryAsync([/* ... */]);

Describes the Spot price history. The prices returned are listed in chronological order, from the oldest to the most recent, for up to the past 90 days. For more information, see Spot Instance Pricing History in the Amazon Elastic Compute Cloud User Guide.

When you specify a start and end time, this operation returns the prices of the instance types within the time range that you specified and the time when the price changed. The price is valid within the time period that you specified; the response merely indicates the last time that the price changed.

Parameter Syntax

$result = $client->describeSpotPriceHistory([
    'AvailabilityZone' => '<string>',
    'DryRun' => true || false,
    'EndTime' => <integer || string || DateTime>,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'InstanceTypes' => ['<string>', ...],
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
    'ProductDescriptions' => ['<string>', ...],
    'StartTime' => <integer || string || DateTime>,
]);

Parameter Details

Members
AvailabilityZone
Type: string

Filters the results by the specified Availability Zone.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

EndTime
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time, up to the current date, from which to stop retrieving the price history data, in UTC format (for example, YYYY-MM-DDTHH:MM:SSZ).

Filters
Type: Array of Filter structures

One or more filters.

  • availability-zone - The Availability Zone for which prices should be returned.

  • instance-type - The type of instance (for example, m3.medium).

  • product-description - The product description for the Spot price (Linux/UNIX | SUSE Linux | Windows | Linux/UNIX (Amazon VPC) | SUSE Linux (Amazon VPC) | Windows (Amazon VPC)).

  • spot-price - The Spot price. The value must match exactly (or use wildcards; greater than or less than comparison is not supported).

  • timestamp - The timestamp of the Spot price history, in UTC format (for example, YYYY-MM-DDTHH:MM:SSZ). You can use wildcards (* and ?). Greater than or less than comparison is not supported.

InstanceTypes
Type: Array of strings

Filters the results by the specified instance types.

MaxResults
Type: int

The maximum number of results to return in a single call. Specify a value between 1 and 1000. The default value is 1000. To retrieve the remaining results, make another call with the returned NextToken value.

NextToken
Type: string

The token for the next set of results.

ProductDescriptions
Type: Array of strings

Filters the results by the specified basic product descriptions.

StartTime
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time, up to the past 90 days, from which to start retrieving the price history data, in UTC format (for example, YYYY-MM-DDTHH:MM:SSZ).

Result Syntax

[
    'NextToken' => '<string>',
    'SpotPriceHistory' => [
        [
            'AvailabilityZone' => '<string>',
            'InstanceType' => 't1.micro|m1.small|m1.medium|m1.large|m1.xlarge|m3.medium|m3.large|m3.xlarge|m3.2xlarge|m4.large|m4.xlarge|m4.2xlarge|m4.4xlarge|m4.10xlarge|t2.nano|t2.micro|t2.small|t2.medium|t2.large|m2.xlarge|m2.2xlarge|m2.4xlarge|cr1.8xlarge|x1.4xlarge|x1.8xlarge|x1.16xlarge|x1.32xlarge|i2.xlarge|i2.2xlarge|i2.4xlarge|i2.8xlarge|hi1.4xlarge|hs1.8xlarge|c1.medium|c1.xlarge|c3.large|c3.xlarge|c3.2xlarge|c3.4xlarge|c3.8xlarge|c4.large|c4.xlarge|c4.2xlarge|c4.4xlarge|c4.8xlarge|cc1.4xlarge|cc2.8xlarge|g2.2xlarge|g2.8xlarge|cg1.4xlarge|r3.large|r3.xlarge|r3.2xlarge|r3.4xlarge|r3.8xlarge|d2.xlarge|d2.2xlarge|d2.4xlarge|d2.8xlarge',
            'ProductDescription' => 'Linux/UNIX|Linux/UNIX (Amazon VPC)|Windows|Windows (Amazon VPC)',
            'SpotPrice' => '<string>',
            'Timestamp' => <DateTime>,
        ],
        // ...
    ],
]

Result Details

Members
NextToken
Type: string

The token required to retrieve the next set of results. This value is null when there are no more results to return.

SpotPriceHistory
Type: Array of SpotPrice structures

The historical Spot prices.

Errors

There are no errors described for this operation.

DescribeStaleSecurityGroups

$result = $client->describeStaleSecurityGroups([/* ... */]);
$promise = $client->describeStaleSecurityGroupsAsync([/* ... */]);

[EC2-VPC only] Describes the stale security group rules for security groups in a specified VPC. Rules are stale when they reference a deleted security group in a peer VPC, or a security group in a peer VPC for which the VPC peering connection has been deleted.

Parameter Syntax

$result = $client->describeStaleSecurityGroups([
    'DryRun' => true || false,
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
    'VpcId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the operation, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

MaxResults
Type: int

The maximum number of items to return for this request. The request returns a token that you can specify in a subsequent call to get the next set of results.

NextToken
Type: string

The token for the next set of items to return. (You received this token from a prior call.)

VpcId
Required: Yes
Type: string

The ID of the VPC.

Result Syntax

[
    'NextToken' => '<string>',
    'StaleSecurityGroupSet' => [
        [
            'Description' => '<string>',
            'GroupId' => '<string>',
            'GroupName' => '<string>',
            'StaleIpPermissions' => [
                [
                    'FromPort' => <integer>,
                    'IpProtocol' => '<string>',
                    'IpRanges' => ['<string>', ...],
                    'PrefixListIds' => ['<string>', ...],
                    'ToPort' => <integer>,
                    'UserIdGroupPairs' => [
                        [
                            'GroupId' => '<string>',
                            'GroupName' => '<string>',
                            'PeeringStatus' => '<string>',
                            'UserId' => '<string>',
                            'VpcId' => '<string>',
                            'VpcPeeringConnectionId' => '<string>',
                        ],
                        // ...
                    ],
                ],
                // ...
            ],
            'StaleIpPermissionsEgress' => [
                [
                    'FromPort' => <integer>,
                    'IpProtocol' => '<string>',
                    'IpRanges' => ['<string>', ...],
                    'PrefixListIds' => ['<string>', ...],
                    'ToPort' => <integer>,
                    'UserIdGroupPairs' => [
                        [
                            'GroupId' => '<string>',
                            'GroupName' => '<string>',
                            'PeeringStatus' => '<string>',
                            'UserId' => '<string>',
                            'VpcId' => '<string>',
                            'VpcPeeringConnectionId' => '<string>',
                        ],
                        // ...
                    ],
                ],
                // ...
            ],
            'VpcId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
NextToken
Type: string

The token to use when requesting the next set of items. If there are no additional items to return, the string is empty.

StaleSecurityGroupSet
Type: Array of StaleSecurityGroup structures

Information about the stale security groups.

Errors

There are no errors described for this operation.

DescribeSubnets

$result = $client->describeSubnets([/* ... */]);
$promise = $client->describeSubnetsAsync([/* ... */]);

Describes one or more of your subnets.

For more information about subnets, see Your VPC and Subnets in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->describeSubnets([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'SubnetIds' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • availabilityZone - The Availability Zone for the subnet. You can also use availability-zone as the filter name.

  • available-ip-address-count - The number of IP addresses in the subnet that are available.

  • cidrBlock - The CIDR block of the subnet. The CIDR block you specify must exactly match the subnet's CIDR block for information to be returned for the subnet. You can also use cidr or cidr-block as the filter names.

  • defaultForAz - Indicates whether this is the default subnet for the Availability Zone. You can also use default-for-az as the filter name.

  • state - The state of the subnet (pending | available).

  • subnet-id - The ID of the subnet.

  • tag:key=value - The key/value combination of a tag assigned to the resource.

  • tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag:key=value filter.

  • tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.

  • vpc-id - The ID of the VPC for the subnet.

SubnetIds
Type: Array of strings

One or more subnet IDs.

Default: Describes all your subnets.

Result Syntax

[
    'Subnets' => [
        [
            'AvailabilityZone' => '<string>',
            'AvailableIpAddressCount' => <integer>,
            'CidrBlock' => '<string>',
            'DefaultForAz' => true || false,
            'MapPublicIpOnLaunch' => true || false,
            'State' => 'pending|available',
            'SubnetId' => '<string>',
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'VpcId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
Subnets
Type: Array of Subnet structures

Information about one or more subnets.

Errors

There are no errors described for this operation.

DescribeTags

$result = $client->describeTags([/* ... */]);
$promise = $client->describeTagsAsync([/* ... */]);

Describes one or more of the tags for your EC2 resources.

For more information about tags, see Tagging Your Resources in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->describeTags([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • key - The tag key.

  • resource-id - The resource ID.

  • resource-type - The resource type (customer-gateway | dhcp-options | image | instance | internet-gateway | network-acl | network-interface | reserved-instances | route-table | security-group | snapshot | spot-instances-request | subnet | volume | vpc | vpn-connection | vpn-gateway).

  • value - The tag value.

MaxResults
Type: int

The maximum number of results to return in a single call. This value can be between 5 and 1000. To retrieve the remaining results, make another call with the returned NextToken value.

NextToken
Type: string

The token to retrieve the next page of results.

Result Syntax

[
    'NextToken' => '<string>',
    'Tags' => [
        [
            'Key' => '<string>',
            'ResourceId' => '<string>',
            'ResourceType' => 'customer-gateway|dhcp-options|image|instance|internet-gateway|network-acl|network-interface|reserved-instances|route-table|snapshot|spot-instances-request|subnet|security-group|volume|vpc|vpn-connection|vpn-gateway',
            'Value' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
NextToken
Type: string

The token to use to retrieve the next page of results. This value is null when there are no more results to return..

Tags
Type: Array of TagDescription structures

A list of tags.

Errors

There are no errors described for this operation.

DescribeVolumeAttribute

$result = $client->describeVolumeAttribute([/* ... */]);
$promise = $client->describeVolumeAttributeAsync([/* ... */]);

Describes the specified attribute of the specified volume. You can specify only one attribute at a time.

For more information about EBS volumes, see Amazon EBS Volumes in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->describeVolumeAttribute([
    'Attribute' => 'autoEnableIO|productCodes',
    'DryRun' => true || false,
    'VolumeId' => '<string>', // REQUIRED
]);

Parameter Details

Members
Attribute
Type: string

The instance attribute.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VolumeId
Required: Yes
Type: string

The ID of the volume.

Result Syntax

[
    'AutoEnableIO' => [
        'Value' => true || false,
    ],
    'ProductCodes' => [
        [
            'ProductCodeId' => '<string>',
            'ProductCodeType' => 'devpay|marketplace',
        ],
        // ...
    ],
    'VolumeId' => '<string>',
]

Result Details

Members
AutoEnableIO
Type: AttributeBooleanValue structure

The state of autoEnableIO attribute.

ProductCodes
Type: Array of ProductCode structures

A list of product codes.

VolumeId
Type: string

The ID of the volume.

Errors

There are no errors described for this operation.

DescribeVolumeStatus

$result = $client->describeVolumeStatus([/* ... */]);
$promise = $client->describeVolumeStatusAsync([/* ... */]);

Describes the status of the specified volumes. Volume status provides the result of the checks performed on your volumes to determine events that can impair the performance of your volumes. The performance of a volume can be affected if an issue occurs on the volume's underlying host. If the volume's underlying host experiences a power outage or system issue, after the system is restored, there could be data inconsistencies on the volume. Volume events notify you if this occurs. Volume actions notify you if any action needs to be taken in response to the event.

The DescribeVolumeStatus operation provides the following information about the specified volumes:

Status: Reflects the current status of the volume. The possible values are ok, impaired , warning, or insufficient-data. If all checks pass, the overall status of the volume is ok. If the check fails, the overall status is impaired. If the status is insufficient-data, then the checks may still be taking place on your volume at the time. We recommend that you retry the request. For more information on volume status, see Monitoring the Status of Your Volumes.

Events: Reflect the cause of a volume status and may require you to take action. For example, if your volume returns an impaired status, then the volume event might be potential-data-inconsistency. This means that your volume has been affected by an issue with the underlying host, has all I/O operations disabled, and may have inconsistent data.

Actions: Reflect the actions you may have to take in response to an event. For example, if the status of the volume is impaired and the volume event shows potential-data-inconsistency, then the action shows enable-volume-io. This means that you may want to enable the I/O operations for the volume by calling the EnableVolumeIO action and then check the volume for data consistency.

Volume status is based on the volume status checks, and does not reflect the volume state. Therefore, volume status does not indicate volumes in the error state (for example, when a volume is incapable of accepting I/O.)

Parameter Syntax

$result = $client->describeVolumeStatus([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
    'VolumeIds' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • action.code - The action code for the event (for example, enable-volume-io).

  • action.description - A description of the action.

  • action.event-id - The event ID associated with the action.

  • availability-zone - The Availability Zone of the instance.

  • event.description - A description of the event.

  • event.event-id - The event ID.

  • event.event-type - The event type (for io-enabled: passed | failed; for io-performance: io-performance:degraded | io-performance:severely-degraded | io-performance:stalled).

  • event.not-after - The latest end time for the event.

  • event.not-before - The earliest start time for the event.

  • volume-status.details-name - The cause for volume-status.status (io-enabled | io-performance).

  • volume-status.details-status - The status of volume-status.details-name (for io-enabled: passed | failed; for io-performance: normal | degraded | severely-degraded | stalled).

  • volume-status.status - The status of the volume (ok | impaired | warning | insufficient-data).

MaxResults
Type: int

The maximum number of volume results returned by DescribeVolumeStatus in paginated output. When this parameter is used, the request only returns MaxResults results in a single page along with a NextToken response element. The remaining results of the initial request can be seen by sending another request with the returned NextToken value. This value can be between 5 and 1000; if MaxResults is given a value larger than 1000, only 1000 results are returned. If this parameter is not used, then DescribeVolumeStatus returns all results. You cannot specify this parameter and the volume IDs parameter in the same request.

NextToken
Type: string

The NextToken value to include in a future DescribeVolumeStatus request. When the results of the request exceed MaxResults, this value can be used to retrieve the next page of results. This value is null when there are no more results to return.

VolumeIds
Type: Array of strings

One or more volume IDs.

Default: Describes all your volumes.

Result Syntax

[
    'NextToken' => '<string>',
    'VolumeStatuses' => [
        [
            'Actions' => [
                [
                    'Code' => '<string>',
                    'Description' => '<string>',
                    'EventId' => '<string>',
                    'EventType' => '<string>',
                ],
                // ...
            ],
            'AvailabilityZone' => '<string>',
            'Events' => [
                [
                    'Description' => '<string>',
                    'EventId' => '<string>',
                    'EventType' => '<string>',
                    'NotAfter' => <DateTime>,
                    'NotBefore' => <DateTime>,
                ],
                // ...
            ],
            'VolumeId' => '<string>',
            'VolumeStatus' => [
                'Details' => [
                    [
                        'Name' => 'io-enabled|io-performance',
                        'Status' => '<string>',
                    ],
                    // ...
                ],
                'Status' => 'ok|impaired|insufficient-data',
            ],
        ],
        // ...
    ],
]

Result Details

Members
NextToken
Type: string

The token to use to retrieve the next page of results. This value is null when there are no more results to return.

VolumeStatuses
Type: Array of VolumeStatusItem structures

A list of volumes.

Errors

There are no errors described for this operation.

DescribeVolumes

$result = $client->describeVolumes([/* ... */]);
$promise = $client->describeVolumesAsync([/* ... */]);

Describes the specified EBS volumes.

If you are describing a long list of volumes, you can paginate the output to make the list more manageable. The MaxResults parameter sets the maximum number of results returned in a single page. If the list of results exceeds your MaxResults value, then that number of results is returned along with a NextToken value that can be passed to a subsequent DescribeVolumes request to retrieve the remaining results.

For more information about EBS volumes, see Amazon EBS Volumes in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->describeVolumes([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
    'VolumeIds' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • attachment.attach-time - The time stamp when the attachment initiated.

  • attachment.delete-on-termination - Whether the volume is deleted on instance termination.

  • attachment.device - The device name that is exposed to the instance (for example, /dev/sda1).

  • attachment.instance-id - The ID of the instance the volume is attached to.

  • attachment.status - The attachment state (attaching | attached | detaching | detached).

  • availability-zone - The Availability Zone in which the volume was created.

  • create-time - The time stamp when the volume was created.

  • encrypted - The encryption status of the volume.

  • size - The size of the volume, in GiB.

  • snapshot-id - The snapshot from which the volume was created.

  • status - The status of the volume (creating | available | in-use | deleting | deleted | error).

  • tag:key=value - The key/value combination of a tag assigned to the resource.

  • tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag:key=value filter.

  • tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.

  • volume-id - The volume ID.

  • volume-type - The Amazon EBS volume type. This can be gp2 for General Purpose SSD, io1 for Provisioned IOPS SSD, st1 for Throughput Optimized HDD, sc1 for Cold HDD, or standard for Magnetic volumes.

MaxResults
Type: int

The maximum number of volume results returned by DescribeVolumes in paginated output. When this parameter is used, DescribeVolumes only returns MaxResults results in a single page along with a NextToken response element. The remaining results of the initial request can be seen by sending another DescribeVolumes request with the returned NextToken value. This value can be between 5 and 1000; if MaxResults is given a value larger than 1000, only 1000 results are returned. If this parameter is not used, then DescribeVolumes returns all results. You cannot specify this parameter and the volume IDs parameter in the same request.

NextToken
Type: string

The NextToken value returned from a previous paginated DescribeVolumes request where MaxResults was used and the results exceeded the value of that parameter. Pagination continues from the end of the previous results that returned the NextToken value. This value is null when there are no more results to return.

VolumeIds
Type: Array of strings

One or more volume IDs.

Result Syntax

[
    'NextToken' => '<string>',
    'Volumes' => [
        [
            'Attachments' => [
                [
                    'AttachTime' => <DateTime>,
                    'DeleteOnTermination' => true || false,
                    'Device' => '<string>',
                    'InstanceId' => '<string>',
                    'State' => 'attaching|attached|detaching|detached',
                    'VolumeId' => '<string>',
                ],
                // ...
            ],
            'AvailabilityZone' => '<string>',
            'CreateTime' => <DateTime>,
            'Encrypted' => true || false,
            'Iops' => <integer>,
            'KmsKeyId' => '<string>',
            'Size' => <integer>,
            'SnapshotId' => '<string>',
            'State' => 'creating|available|in-use|deleting|deleted|error',
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'VolumeId' => '<string>',
            'VolumeType' => 'standard|io1|gp2|sc1|st1',
        ],
        // ...
    ],
]

Result Details

Members
NextToken
Type: string

The NextToken value to include in a future DescribeVolumes request. When the results of a DescribeVolumes request exceed MaxResults, this value can be used to retrieve the next page of results. This value is null when there are no more results to return.

Volumes
Type: Array of Volume structures

Information about the volumes.

Errors

There are no errors described for this operation.

DescribeVpcAttribute

$result = $client->describeVpcAttribute([/* ... */]);
$promise = $client->describeVpcAttributeAsync([/* ... */]);

Describes the specified attribute of the specified VPC. You can specify only one attribute at a time.

Parameter Syntax

$result = $client->describeVpcAttribute([
    'Attribute' => 'enableDnsSupport|enableDnsHostnames', // REQUIRED
    'DryRun' => true || false,
    'VpcId' => '<string>', // REQUIRED
]);

Parameter Details

Members
Attribute
Required: Yes
Type: string

The VPC attribute.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VpcId
Required: Yes
Type: string

The ID of the VPC.

Result Syntax

[
    'EnableDnsHostnames' => [
        'Value' => true || false,
    ],
    'EnableDnsSupport' => [
        'Value' => true || false,
    ],
    'VpcId' => '<string>',
]

Result Details

Members
EnableDnsHostnames
Type: AttributeBooleanValue structure

Indicates whether the instances launched in the VPC get DNS hostnames. If this attribute is true, instances in the VPC get DNS hostnames; otherwise, they do not.

EnableDnsSupport
Type: AttributeBooleanValue structure

Indicates whether DNS resolution is enabled for the VPC. If this attribute is true, the Amazon DNS server resolves DNS hostnames for your instances to their corresponding IP addresses; otherwise, it does not.

VpcId
Type: string

The ID of the VPC.

Errors

There are no errors described for this operation.

$result = $client->describeVpcClassicLink([/* ... */]);
$promise = $client->describeVpcClassicLinkAsync([/* ... */]);

Describes the ClassicLink status of one or more VPCs.

Parameter Syntax

$result = $client->describeVpcClassicLink([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'VpcIds' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • is-classic-link-enabled - Whether the VPC is enabled for ClassicLink (true | false).

  • tag:key=value - The key/value combination of a tag assigned to the resource.

  • tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag:key=value filter.

  • tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.

VpcIds
Type: Array of strings

One or more VPCs for which you want to describe the ClassicLink status.

Result Syntax

[
    'Vpcs' => [
        [
            'ClassicLinkEnabled' => true || false,
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'VpcId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
Vpcs
Type: Array of VpcClassicLink structures

The ClassicLink status of one or more VPCs.

Errors

There are no errors described for this operation.

DescribeVpcClassicLinkDnsSupport

$result = $client->describeVpcClassicLinkDnsSupport([/* ... */]);
$promise = $client->describeVpcClassicLinkDnsSupportAsync([/* ... */]);

Describes the ClassicLink DNS support status of one or more VPCs. If enabled, the DNS hostname of a linked EC2-Classic instance resolves to its private IP address when addressed from an instance in the VPC to which it's linked. Similarly, the DNS hostname of an instance in a VPC resolves to its private IP address when addressed from a linked EC2-Classic instance. For more information about ClassicLink, see ClassicLink in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->describeVpcClassicLinkDnsSupport([
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
    'VpcIds' => ['<string>', ...],
]);

Parameter Details

Members
MaxResults
Type: int

The maximum number of items to return for this request. The request returns a token that you can specify in a subsequent call to get the next set of results.

NextToken
Type: string

The token for the next set of items to return. (You received this token from a prior call.)

VpcIds
Type: Array of strings

One or more VPC IDs.

Result Syntax

[
    'NextToken' => '<string>',
    'Vpcs' => [
        [
            'ClassicLinkDnsSupported' => true || false,
            'VpcId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
NextToken
Type: string

The token to use when requesting the next set of items.

Vpcs
Type: Array of ClassicLinkDnsSupport structures

Information about the ClassicLink DNS support status of the VPCs.

Errors

There are no errors described for this operation.

DescribeVpcEndpointServices

$result = $client->describeVpcEndpointServices([/* ... */]);
$promise = $client->describeVpcEndpointServicesAsync([/* ... */]);

Describes all supported AWS services that can be specified when creating a VPC endpoint.

Parameter Syntax

$result = $client->describeVpcEndpointServices([
    'DryRun' => true || false,
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

MaxResults
Type: int

The maximum number of items to return for this request. The request returns a token that you can specify in a subsequent call to get the next set of results.

Constraint: If the value is greater than 1000, we return only 1000 items.

NextToken
Type: string

The token for the next set of items to return. (You received this token from a prior call.)

Result Syntax

[
    'NextToken' => '<string>',
    'ServiceNames' => ['<string>', ...],
]

Result Details

Members
NextToken
Type: string

The token to use when requesting the next set of items. If there are no additional items to return, the string is empty.

ServiceNames
Type: Array of strings

A list of supported AWS services.

Errors

There are no errors described for this operation.

DescribeVpcEndpoints

$result = $client->describeVpcEndpoints([/* ... */]);
$promise = $client->describeVpcEndpointsAsync([/* ... */]);

Describes one or more of your VPC endpoints.

Parameter Syntax

$result = $client->describeVpcEndpoints([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
    'VpcEndpointIds' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • service-name: The name of the AWS service.

  • vpc-id: The ID of the VPC in which the endpoint resides.

  • vpc-endpoint-id: The ID of the endpoint.

  • vpc-endpoint-state: The state of the endpoint. (pending | available | deleting | deleted)

MaxResults
Type: int

The maximum number of items to return for this request. The request returns a token that you can specify in a subsequent call to get the next set of results.

Constraint: If the value is greater than 1000, we return only 1000 items.

NextToken
Type: string

The token for the next set of items to return. (You received this token from a prior call.)

VpcEndpointIds
Type: Array of strings

One or more endpoint IDs.

Result Syntax

[
    'NextToken' => '<string>',
    'VpcEndpoints' => [
        [
            'CreationTimestamp' => <DateTime>,
            'PolicyDocument' => '<string>',
            'RouteTableIds' => ['<string>', ...],
            'ServiceName' => '<string>',
            'State' => 'Pending|Available|Deleting|Deleted',
            'VpcEndpointId' => '<string>',
            'VpcId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
NextToken
Type: string

The token to use when requesting the next set of items. If there are no additional items to return, the string is empty.

VpcEndpoints
Type: Array of VpcEndpoint structures

Information about the endpoints.

Errors

There are no errors described for this operation.

DescribeVpcPeeringConnections

$result = $client->describeVpcPeeringConnections([/* ... */]);
$promise = $client->describeVpcPeeringConnectionsAsync([/* ... */]);

Describes one or more of your VPC peering connections.

Parameter Syntax

$result = $client->describeVpcPeeringConnections([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'VpcPeeringConnectionIds' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • accepter-vpc-info.cidr-block - The CIDR block of the peer VPC.

  • accepter-vpc-info.owner-id - The AWS account ID of the owner of the peer VPC.

  • accepter-vpc-info.vpc-id - The ID of the peer VPC.

  • expiration-time - The expiration date and time for the VPC peering connection.

  • requester-vpc-info.cidr-block - The CIDR block of the requester's VPC.

  • requester-vpc-info.owner-id - The AWS account ID of the owner of the requester VPC.

  • requester-vpc-info.vpc-id - The ID of the requester VPC.

  • status-code - The status of the VPC peering connection (pending-acceptance | failed | expired | provisioning | active | deleted | rejected).

  • status-message - A message that provides more information about the status of the VPC peering connection, if applicable.

  • tag:key=value - The key/value combination of a tag assigned to the resource.

  • tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag:key=value filter.

  • tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.

  • vpc-peering-connection-id - The ID of the VPC peering connection.

VpcPeeringConnectionIds
Type: Array of strings

One or more VPC peering connection IDs.

Default: Describes all your VPC peering connections.

Result Syntax

[
    'VpcPeeringConnections' => [
        [
            'AccepterVpcInfo' => [
                'CidrBlock' => '<string>',
                'OwnerId' => '<string>',
                'PeeringOptions' => [
                    'AllowEgressFromLocalClassicLinkToRemoteVpc' => true || false,
                    'AllowEgressFromLocalVpcToRemoteClassicLink' => true || false,
                ],
                'VpcId' => '<string>',
            ],
            'ExpirationTime' => <DateTime>,
            'RequesterVpcInfo' => [
                'CidrBlock' => '<string>',
                'OwnerId' => '<string>',
                'PeeringOptions' => [
                    'AllowEgressFromLocalClassicLinkToRemoteVpc' => true || false,
                    'AllowEgressFromLocalVpcToRemoteClassicLink' => true || false,
                ],
                'VpcId' => '<string>',
            ],
            'Status' => [
                'Code' => 'initiating-request|pending-acceptance|active|deleted|rejected|failed|expired|provisioning|deleting',
                'Message' => '<string>',
            ],
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'VpcPeeringConnectionId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
VpcPeeringConnections
Type: Array of VpcPeeringConnection structures

Information about the VPC peering connections.

Errors

There are no errors described for this operation.

DescribeVpcs

$result = $client->describeVpcs([/* ... */]);
$promise = $client->describeVpcsAsync([/* ... */]);

Describes one or more of your VPCs.

Parameter Syntax

$result = $client->describeVpcs([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'VpcIds' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • cidr - The CIDR block of the VPC. The CIDR block you specify must exactly match the VPC's CIDR block for information to be returned for the VPC. Must contain the slash followed by one or two digits (for example, /28).

  • dhcp-options-id - The ID of a set of DHCP options.

  • isDefault - Indicates whether the VPC is the default VPC.

  • state - The state of the VPC (pending | available).

  • tag:key=value - The key/value combination of a tag assigned to the resource.

  • tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag:key=value filter.

  • tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.

  • vpc-id - The ID of the VPC.

VpcIds
Type: Array of strings

One or more VPC IDs.

Default: Describes all your VPCs.

Result Syntax

[
    'Vpcs' => [
        [
            'CidrBlock' => '<string>',
            'DhcpOptionsId' => '<string>',
            'InstanceTenancy' => 'default|dedicated|host',
            'IsDefault' => true || false,
            'State' => 'pending|available',
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'VpcId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
Vpcs
Type: Array of Vpc structures

Information about one or more VPCs.

Errors

There are no errors described for this operation.

DescribeVpnConnections

$result = $client->describeVpnConnections([/* ... */]);
$promise = $client->describeVpnConnectionsAsync([/* ... */]);

Describes one or more of your VPN connections.

For more information about VPN connections, see Adding a Hardware Virtual Private Gateway to Your VPC in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->describeVpnConnections([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'VpnConnectionIds' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • customer-gateway-configuration - The configuration information for the customer gateway.

  • customer-gateway-id - The ID of a customer gateway associated with the VPN connection.

  • state - The state of the VPN connection (pending | available | deleting | deleted).

  • option.static-routes-only - Indicates whether the connection has static routes only. Used for devices that do not support Border Gateway Protocol (BGP).

  • route.destination-cidr-block - The destination CIDR block. This corresponds to the subnet used in a customer data center.

  • bgp-asn - The BGP Autonomous System Number (ASN) associated with a BGP device.

  • tag:key=value - The key/value combination of a tag assigned to the resource.

  • tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag:key=value filter.

  • tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.

  • type - The type of VPN connection. Currently the only supported type is ipsec.1.

  • vpn-connection-id - The ID of the VPN connection.

  • vpn-gateway-id - The ID of a virtual private gateway associated with the VPN connection.

VpnConnectionIds
Type: Array of strings

One or more VPN connection IDs.

Default: Describes your VPN connections.

Result Syntax

[
    'VpnConnections' => [
        [
            'CustomerGatewayConfiguration' => '<string>',
            'CustomerGatewayId' => '<string>',
            'Options' => [
                'StaticRoutesOnly' => true || false,
            ],
            'Routes' => [
                [
                    'DestinationCidrBlock' => '<string>',
                    'Source' => 'Static',
                    'State' => 'pending|available|deleting|deleted',
                ],
                // ...
            ],
            'State' => 'pending|available|deleting|deleted',
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'Type' => 'ipsec.1',
            'VgwTelemetry' => [
                [
                    'AcceptedRouteCount' => <integer>,
                    'LastStatusChange' => <DateTime>,
                    'OutsideIpAddress' => '<string>',
                    'Status' => 'UP|DOWN',
                    'StatusMessage' => '<string>',
                ],
                // ...
            ],
            'VpnConnectionId' => '<string>',
            'VpnGatewayId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
VpnConnections
Type: Array of VpnConnection structures

Information about one or more VPN connections.

Errors

There are no errors described for this operation.

DescribeVpnGateways

$result = $client->describeVpnGateways([/* ... */]);
$promise = $client->describeVpnGatewaysAsync([/* ... */]);

Describes one or more of your virtual private gateways.

For more information about virtual private gateways, see Adding an IPsec Hardware VPN to Your VPC in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->describeVpnGateways([
    'DryRun' => true || false,
    'Filters' => [
        [
            'Name' => '<string>',
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'VpnGatewayIds' => ['<string>', ...],
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Filters
Type: Array of Filter structures

One or more filters.

  • attachment.state - The current state of the attachment between the gateway and the VPC (attaching | attached | detaching | detached).

  • attachment.vpc-id - The ID of an attached VPC.

  • availability-zone - The Availability Zone for the virtual private gateway (if applicable).

  • state - The state of the virtual private gateway (pending | available | deleting | deleted).

  • tag:key=value - The key/value combination of a tag assigned to the resource.

  • tag-key - The key of a tag assigned to the resource. This filter is independent of the tag-value filter. For example, if you use both the filter "tag-key=Purpose" and the filter "tag-value=X", you get any resources assigned both the tag key Purpose (regardless of what the tag's value is), and the tag value X (regardless of what the tag's key is). If you want to list only resources where Purpose is X, see the tag:key=value filter.

  • tag-value - The value of a tag assigned to the resource. This filter is independent of the tag-key filter.

  • type - The type of virtual private gateway. Currently the only supported type is ipsec.1.

  • vpn-gateway-id - The ID of the virtual private gateway.

VpnGatewayIds
Type: Array of strings

One or more virtual private gateway IDs.

Default: Describes all your virtual private gateways.

Result Syntax

[
    'VpnGateways' => [
        [
            'AvailabilityZone' => '<string>',
            'State' => 'pending|available|deleting|deleted',
            'Tags' => [
                [
                    'Key' => '<string>',
                    'Value' => '<string>',
                ],
                // ...
            ],
            'Type' => 'ipsec.1',
            'VpcAttachments' => [
                [
                    'State' => 'attaching|attached|detaching|detached',
                    'VpcId' => '<string>',
                ],
                // ...
            ],
            'VpnGatewayId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
VpnGateways
Type: Array of VpnGateway structures

Information about one or more virtual private gateways.

Errors

There are no errors described for this operation.

DetachClassicLinkVpc

$result = $client->detachClassicLinkVpc([/* ... */]);
$promise = $client->detachClassicLinkVpcAsync([/* ... */]);

Unlinks (detaches) a linked EC2-Classic instance from a VPC. After the instance has been unlinked, the VPC security groups are no longer associated with it. An instance is automatically unlinked from a VPC when it's stopped.

Parameter Syntax

$result = $client->detachClassicLinkVpc([
    'DryRun' => true || false,
    'InstanceId' => '<string>', // REQUIRED
    'VpcId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

InstanceId
Required: Yes
Type: string

The ID of the instance to unlink from the VPC.

VpcId
Required: Yes
Type: string

The ID of the VPC to which the instance is linked.

Result Syntax

[
    'Return' => true || false,
]

Result Details

Members
Return
Type: boolean

Returns true if the request succeeds; otherwise, it returns an error.

Errors

There are no errors described for this operation.

DetachInternetGateway

$result = $client->detachInternetGateway([/* ... */]);
$promise = $client->detachInternetGatewayAsync([/* ... */]);

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.

Parameter Syntax

$result = $client->detachInternetGateway([
    'DryRun' => true || false,
    'InternetGatewayId' => '<string>', // REQUIRED
    'VpcId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

InternetGatewayId
Required: Yes
Type: string

The ID of the Internet gateway.

VpcId
Required: Yes
Type: string

The ID of the VPC.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DetachNetworkInterface

$result = $client->detachNetworkInterface([/* ... */]);
$promise = $client->detachNetworkInterfaceAsync([/* ... */]);

Detaches a network interface from an instance.

Parameter Syntax

$result = $client->detachNetworkInterface([
    'AttachmentId' => '<string>', // REQUIRED
    'DryRun' => true || false,
    'Force' => true || false,
]);

Parameter Details

Members
AttachmentId
Required: Yes
Type: string

The ID of the attachment.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Force
Type: boolean

Specifies whether to force a detachment.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DetachVolume

$result = $client->detachVolume([/* ... */]);
$promise = $client->detachVolumeAsync([/* ... */]);

Detaches an EBS volume from an instance. Make sure to unmount any file systems on the device within your operating system before detaching the volume. Failure to do so results in the volume being stuck in a busy state while detaching.

If an Amazon EBS volume is the root device of an instance, it can't be detached while the instance is running. To detach the root volume, stop the instance first.

When a volume with an AWS Marketplace product code is detached from an instance, the product code is no longer associated with the instance.

For more information, see Detaching an Amazon EBS Volume in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->detachVolume([
    'Device' => '<string>',
    'DryRun' => true || false,
    'Force' => true || false,
    'InstanceId' => '<string>',
    'VolumeId' => '<string>', // REQUIRED
]);

Parameter Details

Members
Device
Type: string

The device name.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Force
Type: boolean

Forces detachment if the previous detachment attempt did not occur cleanly (for example, logging into an instance, unmounting the volume, and detaching normally). This option can lead to data loss or a corrupted file system. Use this option only as a last resort to detach a volume from a failed instance. The instance won't have an opportunity to flush file system caches or file system metadata. If you use this option, you must perform file system check and repair procedures.

InstanceId
Type: string

The ID of the instance.

VolumeId
Required: Yes
Type: string

The ID of the volume.

Result Syntax

[
    'AttachTime' => <DateTime>,
    'DeleteOnTermination' => true || false,
    'Device' => '<string>',
    'InstanceId' => '<string>',
    'State' => 'attaching|attached|detaching|detached',
    'VolumeId' => '<string>',
]

Result Details

Members
AttachTime
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time stamp when the attachment initiated.

DeleteOnTermination
Type: boolean

Indicates whether the EBS volume is deleted on instance termination.

Device
Type: string

The device name.

InstanceId
Type: string

The ID of the instance.

State
Type: string

The attachment state of the volume.

VolumeId
Type: string

The ID of the volume.

Errors

There are no errors described for this operation.

DetachVpnGateway

$result = $client->detachVpnGateway([/* ... */]);
$promise = $client->detachVpnGatewayAsync([/* ... */]);

Detaches a virtual private gateway from a VPC. You do this if you're planning to turn off the VPC and not use it anymore. You can confirm a virtual private gateway has been completely detached from a VPC by describing the virtual private gateway (any attachments to the virtual private gateway are also described).

You must wait for the attachment's state to switch to detached before you can delete the VPC or attach a different VPC to the virtual private gateway.

Parameter Syntax

$result = $client->detachVpnGateway([
    'DryRun' => true || false,
    'VpcId' => '<string>', // REQUIRED
    'VpnGatewayId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VpcId
Required: Yes
Type: string

The ID of the VPC.

VpnGatewayId
Required: Yes
Type: string

The ID of the virtual private gateway.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DisableVgwRoutePropagation

$result = $client->disableVgwRoutePropagation([/* ... */]);
$promise = $client->disableVgwRoutePropagationAsync([/* ... */]);

Disables a virtual private gateway (VGW) from propagating routes to a specified route table of a VPC.

Parameter Syntax

$result = $client->disableVgwRoutePropagation([
    'GatewayId' => '<string>', // REQUIRED
    'RouteTableId' => '<string>', // REQUIRED
]);

Parameter Details

Members
GatewayId
Required: Yes
Type: string

The ID of the virtual private gateway.

RouteTableId
Required: Yes
Type: string

The ID of the route table.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

$result = $client->disableVpcClassicLink([/* ... */]);
$promise = $client->disableVpcClassicLinkAsync([/* ... */]);

Disables ClassicLink for a VPC. You cannot disable ClassicLink for a VPC that has EC2-Classic instances linked to it.

Parameter Syntax

$result = $client->disableVpcClassicLink([
    'DryRun' => true || false,
    'VpcId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VpcId
Required: Yes
Type: string

The ID of the VPC.

Result Syntax

[
    'Return' => true || false,
]

Result Details

Members
Return
Type: boolean

Returns true if the request succeeds; otherwise, it returns an error.

Errors

There are no errors described for this operation.

DisableVpcClassicLinkDnsSupport

$result = $client->disableVpcClassicLinkDnsSupport([/* ... */]);
$promise = $client->disableVpcClassicLinkDnsSupportAsync([/* ... */]);

Disables ClassicLink DNS support for a VPC. If disabled, DNS hostnames resolve to public IP addresses when addressed between a linked EC2-Classic instance and instances in the VPC to which it's linked. For more information about ClassicLink, see ClassicLink in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->disableVpcClassicLinkDnsSupport([
    'VpcId' => '<string>',
]);

Parameter Details

Members
VpcId
Type: string

The ID of the VPC.

Result Syntax

[
    'Return' => true || false,
]

Result Details

Members
Return
Type: boolean

Returns true if the request succeeds; otherwise, it returns an error.

Errors

There are no errors described for this operation.

DisassociateAddress

$result = $client->disassociateAddress([/* ... */]);
$promise = $client->disassociateAddressAsync([/* ... */]);

Disassociates an Elastic IP address from the instance or network interface it's associated with.

An Elastic IP address is for use in either the EC2-Classic platform or in a VPC. For more information, see Elastic IP Addresses in the Amazon Elastic Compute Cloud User Guide.

This is an idempotent operation. If you perform the operation more than once, Amazon EC2 doesn't return an error.

Parameter Syntax

$result = $client->disassociateAddress([
    'AssociationId' => '<string>',
    'DryRun' => true || false,
    'PublicIp' => '<string>',
]);

Parameter Details

Members
AssociationId
Type: string

[EC2-VPC] The association ID. Required for EC2-VPC.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

PublicIp
Type: string

[EC2-Classic] The Elastic IP address. Required for EC2-Classic.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

DisassociateRouteTable

$result = $client->disassociateRouteTable([/* ... */]);
$promise = $client->disassociateRouteTableAsync([/* ... */]);

Disassociates a subnet from a route table.

After you perform this action, the subnet no longer uses the routes in the route table. Instead, it uses the routes in the VPC's main route table. For more information about route tables, see Route Tables in the Amazon Virtual Private Cloud User Guide.

Parameter Syntax

$result = $client->disassociateRouteTable([
    'AssociationId' => '<string>', // REQUIRED
    'DryRun' => true || false,
]);

Parameter Details

Members
AssociationId
Required: Yes
Type: string

The association ID representing the current association between the route table and subnet.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

EnableVgwRoutePropagation

$result = $client->enableVgwRoutePropagation([/* ... */]);
$promise = $client->enableVgwRoutePropagationAsync([/* ... */]);

Enables a virtual private gateway (VGW) to propagate routes to the specified route table of a VPC.

Parameter Syntax

$result = $client->enableVgwRoutePropagation([
    'GatewayId' => '<string>', // REQUIRED
    'RouteTableId' => '<string>', // REQUIRED
]);

Parameter Details

Members
GatewayId
Required: Yes
Type: string

The ID of the virtual private gateway.

RouteTableId
Required: Yes
Type: string

The ID of the route table.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

EnableVolumeIO

$result = $client->enableVolumeIO([/* ... */]);
$promise = $client->enableVolumeIOAsync([/* ... */]);

Enables I/O operations for a volume that had I/O operations disabled because the data on the volume was potentially inconsistent.

Parameter Syntax

$result = $client->enableVolumeIO([
    'DryRun' => true || false,
    'VolumeId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VolumeId
Required: Yes
Type: string

The ID of the volume.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

$result = $client->enableVpcClassicLink([/* ... */]);
$promise = $client->enableVpcClassicLinkAsync([/* ... */]);

Enables a VPC for ClassicLink. You can then link EC2-Classic instances to your ClassicLink-enabled VPC to allow communication over private IP addresses. You cannot enable your VPC for ClassicLink if any of your VPC's route tables have existing routes for address ranges within the 10.0.0.0/8 IP address range, excluding local routes for VPCs in the 10.0.0.0/16 and 10.1.0.0/16 IP address ranges. For more information, see ClassicLink in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->enableVpcClassicLink([
    'DryRun' => true || false,
    'VpcId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VpcId
Required: Yes
Type: string

The ID of the VPC.

Result Syntax

[
    'Return' => true || false,
]

Result Details

Members
Return
Type: boolean

Returns true if the request succeeds; otherwise, it returns an error.

Errors

There are no errors described for this operation.

EnableVpcClassicLinkDnsSupport

$result = $client->enableVpcClassicLinkDnsSupport([/* ... */]);
$promise = $client->enableVpcClassicLinkDnsSupportAsync([/* ... */]);

Enables a VPC to support DNS hostname resolution for ClassicLink. If enabled, the DNS hostname of a linked EC2-Classic instance resolves to its private IP address when addressed from an instance in the VPC to which it's linked. Similarly, the DNS hostname of an instance in a VPC resolves to its private IP address when addressed from a linked EC2-Classic instance. For more information about ClassicLink, see ClassicLink in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->enableVpcClassicLinkDnsSupport([
    'VpcId' => '<string>',
]);

Parameter Details

Members
VpcId
Type: string

The ID of the VPC.

Result Syntax

[
    'Return' => true || false,
]

Result Details

Members
Return
Type: boolean

Returns true if the request succeeds; otherwise, it returns an error.

Errors

There are no errors described for this operation.

GetConsoleOutput

$result = $client->getConsoleOutput([/* ... */]);
$promise = $client->getConsoleOutputAsync([/* ... */]);

Gets the console output for the specified instance.

Instances do not have a physical monitor through which you can view their console output. They also lack physical controls that allow you to power up, reboot, or shut them down. To allow these actions, we provide them through the Amazon EC2 API and command line interface.

Instance console output is buffered and posted shortly after instance boot, reboot, and termination. Amazon EC2 preserves the most recent 64 KB output which is available for at least one hour after the most recent post.

For Linux instances, the instance console output displays the exact console output that would normally be displayed on a physical monitor attached to a computer. This output is buffered because the instance produces it and then posts it to a store where the instance's owner can retrieve it.

For Windows instances, the instance console output includes output from the EC2Config service.

Parameter Syntax

$result = $client->getConsoleOutput([
    'DryRun' => true || false,
    'InstanceId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

InstanceId
Required: Yes
Type: string

The ID of the instance.

Result Syntax

[
    'InstanceId' => '<string>',
    'Output' => '<string>',
    'Timestamp' => <DateTime>,
]

Result Details

Members
InstanceId
Type: string

The ID of the instance.

Output
Type: string

The console output, base64-encoded. If using a command line tool, the tools decode the output for you.

Timestamp
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time the output was last updated.

Errors

There are no errors described for this operation.

GetConsoleScreenshot

$result = $client->getConsoleScreenshot([/* ... */]);
$promise = $client->getConsoleScreenshotAsync([/* ... */]);

Retrieve a JPG-format screenshot of a running instance to help with troubleshooting.

The returned content is base64-encoded.

Parameter Syntax

$result = $client->getConsoleScreenshot([
    'DryRun' => true || false,
    'InstanceId' => '<string>', // REQUIRED
    'WakeUp' => true || false,
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

InstanceId
Required: Yes
Type: string

The ID of the instance.

WakeUp
Type: boolean

When set to true, acts as keystroke input and wakes up an instance that's in standby or "sleep" mode.

Result Syntax

[
    'ImageData' => '<string>',
    'InstanceId' => '<string>',
]

Result Details

Members
ImageData
Type: string

The data that comprises the image.

InstanceId
Type: string

The ID of the instance.

Errors

There are no errors described for this operation.

GetPasswordData

$result = $client->getPasswordData([/* ... */]);
$promise = $client->getPasswordDataAsync([/* ... */]);

Retrieves the encrypted administrator password for an instance running Windows.

The Windows password is generated at boot if the EC2Config service plugin, Ec2SetPassword, is enabled. This usually only happens the first time an AMI is launched, and then Ec2SetPassword is automatically disabled. The password is not generated for rebundled AMIs unless Ec2SetPassword is enabled before bundling.

The password is encrypted using the key pair that you specified when you launched the instance. You must provide the corresponding key pair file.

Password generation and encryption takes a few moments. We recommend that you wait up to 15 minutes after launching an instance before trying to retrieve the generated password.

Parameter Syntax

$result = $client->getPasswordData([
    'DryRun' => true || false,
    'InstanceId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

InstanceId
Required: Yes
Type: string

The ID of the Windows instance.

Result Syntax

[
    'InstanceId' => '<string>',
    'PasswordData' => '<string>',
    'Timestamp' => <DateTime>,
]

Result Details

Members
InstanceId
Type: string

The ID of the Windows instance.

PasswordData
Type: string

The password of the instance.

Timestamp
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time the data was last updated.

Errors

There are no errors described for this operation.

ImportImage

$result = $client->importImage([/* ... */]);
$promise = $client->importImageAsync([/* ... */]);

Import single or multi-volume disk images or EBS snapshots into an Amazon Machine Image (AMI).

Parameter Syntax

$result = $client->importImage([
    'Architecture' => '<string>',
    'ClientData' => [
        'Comment' => '<string>',
        'UploadEnd' => <integer || string || DateTime>,
        'UploadSize' => <float>,
        'UploadStart' => <integer || string || DateTime>,
    ],
    'ClientToken' => '<string>',
    'Description' => '<string>',
    'DiskContainers' => [
        [
            'Description' => '<string>',
            'DeviceName' => '<string>',
            'Format' => '<string>',
            'SnapshotId' => '<string>',
            'Url' => '<string>',
            'UserBucket' => [
                'S3Bucket' => '<string>',
                'S3Key' => '<string>',
            ],
        ],
        // ...
    ],
    'DryRun' => true || false,
    'Hypervisor' => '<string>',
    'LicenseType' => '<string>',
    'Platform' => '<string>',
    'RoleName' => '<string>',
]);

Parameter Details

Members
Architecture
Type: string

The architecture of the virtual machine.

Valid values: i386 | x86_64

ClientData
Type: ClientData structure

The client-specific data.

ClientToken
Type: string

The token to enable idempotency for VM import requests.

Description
Type: string

A description string for the import image task.

DiskContainers
Type: Array of ImageDiskContainer structures

Information about the disk containers.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Hypervisor
Type: string

The target hypervisor platform.

Valid values: xen

LicenseType
Type: string

The license type to be used for the Amazon Machine Image (AMI) after importing.

Note: You may only use BYOL if you have existing licenses with rights to use these licenses in a third party cloud like AWS. For more information, see VM Import/Export Prerequisites in the Amazon Elastic Compute Cloud User Guide.

Valid values: AWS | BYOL

Platform
Type: string

The operating system of the virtual machine.

Valid values: Windows | Linux

RoleName
Type: string

The name of the role to use when not using the default role, 'vmimport'.

Result Syntax

[
    'Architecture' => '<string>',
    'Description' => '<string>',
    'Hypervisor' => '<string>',
    'ImageId' => '<string>',
    'ImportTaskId' => '<string>',
    'LicenseType' => '<string>',
    'Platform' => '<string>',
    'Progress' => '<string>',
    'SnapshotDetails' => [
        [
            'Description' => '<string>',
            'DeviceName' => '<string>',
            'DiskImageSize' => <float>,
            'Format' => '<string>',
            'Progress' => '<string>',
            'SnapshotId' => '<string>',
            'Status' => '<string>',
            'StatusMessage' => '<string>',
            'Url' => '<string>',
            'UserBucket' => [
                'S3Bucket' => '<string>',
                'S3Key' => '<string>',
            ],
        ],
        // ...
    ],
    'Status' => '<string>',
    'StatusMessage' => '<string>',
]

Result Details

Members
Architecture
Type: string

The architecture of the virtual machine.

Description
Type: string

A description of the import task.

Hypervisor
Type: string

The target hypervisor of the import task.

ImageId
Type: string

The ID of the Amazon Machine Image (AMI) created by the import task.

ImportTaskId
Type: string

The task ID of the import image task.

LicenseType
Type: string

The license type of the virtual machine.

Platform
Type: string

The operating system of the virtual machine.

Progress
Type: string

The progress of the task.

SnapshotDetails
Type: Array of SnapshotDetail structures

Information about the snapshots.

Status
Type: string

A brief status of the task.

StatusMessage
Type: string

A detailed status message of the import task.

Errors

There are no errors described for this operation.

ImportInstance

$result = $client->importInstance([/* ... */]);
$promise = $client->importInstanceAsync([/* ... */]);

Creates an import instance task using metadata from the specified disk image. ImportInstance only supports single-volume VMs. To import multi-volume VMs, use ImportImage. After importing the image, you then upload it using the ec2-import-volume command in the EC2 command line tools. For more information, see Using the Command Line Tools to Import Your Virtual Machine to Amazon EC2 in the Amazon Elastic Compute Cloud User Guide.

For information about the import manifest referenced by this API action, see VM Import Manifest.

Parameter Syntax

$result = $client->importInstance([
    'Description' => '<string>',
    'DiskImages' => [
        [
            'Description' => '<string>',
            'Image' => [
                'Bytes' => <integer>, // REQUIRED
                'Format' => 'VMDK|RAW|VHD', // REQUIRED
                'ImportManifestUrl' => '<string>', // REQUIRED
            ],
            'Volume' => [
                'Size' => <integer>, // REQUIRED
            ],
        ],
        // ...
    ],
    'DryRun' => true || false,
    'LaunchSpecification' => [
        'AdditionalInfo' => '<string>',
        'Architecture' => 'i386|x86_64',
        'GroupIds' => ['<string>', ...],
        'GroupNames' => ['<string>', ...],
        'InstanceInitiatedShutdownBehavior' => 'stop|terminate',
        'InstanceType' => 't1.micro|m1.small|m1.medium|m1.large|m1.xlarge|m3.medium|m3.large|m3.xlarge|m3.2xlarge|m4.large|m4.xlarge|m4.2xlarge|m4.4xlarge|m4.10xlarge|t2.nano|t2.micro|t2.small|t2.medium|t2.large|m2.xlarge|m2.2xlarge|m2.4xlarge|cr1.8xlarge|x1.4xlarge|x1.8xlarge|x1.16xlarge|x1.32xlarge|i2.xlarge|i2.2xlarge|i2.4xlarge|i2.8xlarge|hi1.4xlarge|hs1.8xlarge|c1.medium|c1.xlarge|c3.large|c3.xlarge|c3.2xlarge|c3.4xlarge|c3.8xlarge|c4.large|c4.xlarge|c4.2xlarge|c4.4xlarge|c4.8xlarge|cc1.4xlarge|cc2.8xlarge|g2.2xlarge|g2.8xlarge|cg1.4xlarge|r3.large|r3.xlarge|r3.2xlarge|r3.4xlarge|r3.8xlarge|d2.xlarge|d2.2xlarge|d2.4xlarge|d2.8xlarge',
        'Monitoring' => true || false,
        'Placement' => [
            'Affinity' => '<string>',
            'AvailabilityZone' => '<string>',
            'GroupName' => '<string>',
            'HostId' => '<string>',
            'Tenancy' => 'default|dedicated|host',
        ],
        'PrivateIpAddress' => '<string>',
        'SubnetId' => '<string>',
        'UserData' => [
            'Data' => '<string>',
        ],
    ],
    'Platform' => 'Windows', // REQUIRED
]);

Parameter Details

Members
Description
Type: string

A description for the instance being imported.

DiskImages
Type: Array of DiskImage structures

The disk image.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

LaunchSpecification

The launch specification.

Platform
Required: Yes
Type: string

The instance operating system.

Result Syntax

[
    'ConversionTask' => [
        'ConversionTaskId' => '<string>',
        'ExpirationTime' => '<string>',
        'ImportInstance' => [
            'Description' => '<string>',
            'InstanceId' => '<string>',
            'Platform' => 'Windows',
            'Volumes' => [
                [
                    'AvailabilityZone' => '<string>',
                    'BytesConverted' => <integer>,
                    'Description' => '<string>',
                    'Image' => [
                        'Checksum' => '<string>',
                        'Format' => 'VMDK|RAW|VHD',
                        'ImportManifestUrl' => '<string>',
                        'Size' => <integer>,
                    ],
                    'Status' => '<string>',
                    'StatusMessage' => '<string>',
                    'Volume' => [
                        'Id' => '<string>',
                        'Size' => <integer>,
                    ],
                ],
                // ...
            ],
        ],
        'ImportVolume' => [
            'AvailabilityZone' => '<string>',
            'BytesConverted' => <integer>,
            'Description' => '<string>',
            'Image' => [
                'Checksum' => '<string>',
                'Format' => 'VMDK|RAW|VHD',
                'ImportManifestUrl' => '<string>',
                'Size' => <integer>,
            ],
            'Volume' => [
                'Id' => '<string>',
                'Size' => <integer>,
            ],
        ],
        'State' => 'active|cancelling|cancelled|completed',
        'StatusMessage' => '<string>',
        'Tags' => [
            [
                'Key' => '<string>',
                'Value' => '<string>',
            ],
            // ...
        ],
    ],
]

Result Details

Members
ConversionTask
Type: ConversionTask structure

Information about the conversion task.

Errors

There are no errors described for this operation.

ImportKeyPair

$result = $client->importKeyPair([/* ... */]);
$promise = $client->importKeyPairAsync([/* ... */]);

Imports the public key from an RSA key pair that you created with a third-party tool. Compare this with CreateKeyPair, in which AWS creates the key pair and gives the keys to you (AWS keeps a copy of the public key). With ImportKeyPair, you create the key pair and give AWS just the public key. The private key is never transferred between you and AWS.

For more information about key pairs, see Key Pairs in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->importKeyPair([
    'DryRun' => true || false,
    'KeyName' => '<string>', // REQUIRED
    'PublicKeyMaterial' => <string || resource || Psr\Http\Message\StreamInterface>, // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

KeyName
Required: Yes
Type: string

A unique name for the key pair.

PublicKeyMaterial
Required: Yes
Type: blob (string|resource|Psr\Http\Message\StreamInterface)

The public key. For API calls, the text must be base64-encoded. For command line tools, base64 encoding is performed for you.

Result Syntax

[
    'KeyFingerprint' => '<string>',
    'KeyName' => '<string>',
]

Result Details

Members
KeyFingerprint
Type: string

The MD5 public key fingerprint as specified in section 4 of RFC 4716.

KeyName
Type: string

The key pair name you provided.

Errors

There are no errors described for this operation.

ImportSnapshot

$result = $client->importSnapshot([/* ... */]);
$promise = $client->importSnapshotAsync([/* ... */]);

Imports a disk into an EBS snapshot.

Parameter Syntax

$result = $client->importSnapshot([
    'ClientData' => [
        'Comment' => '<string>',
        'UploadEnd' => <integer || string || DateTime>,
        'UploadSize' => <float>,
        'UploadStart' => <integer || string || DateTime>,
    ],
    'ClientToken' => '<string>',
    'Description' => '<string>',
    'DiskContainer' => [
        'Description' => '<string>',
        'Format' => '<string>',
        'Url' => '<string>',
        'UserBucket' => [
            'S3Bucket' => '<string>',
            'S3Key' => '<string>',
        ],
    ],
    'DryRun' => true || false,
    'RoleName' => '<string>',
]);

Parameter Details

Members
ClientData
Type: ClientData structure

The client-specific data.

ClientToken
Type: string

Token to enable idempotency for VM import requests.

Description
Type: string

The description string for the import snapshot task.

DiskContainer
Type: SnapshotDiskContainer structure

Information about the disk container.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

RoleName
Type: string

The name of the role to use when not using the default role, 'vmimport'.

Result Syntax

[
    'Description' => '<string>',
    'ImportTaskId' => '<string>',
    'SnapshotTaskDetail' => [
        'Description' => '<string>',
        'DiskImageSize' => <float>,
        'Format' => '<string>',
        'Progress' => '<string>',
        'SnapshotId' => '<string>',
        'Status' => '<string>',
        'StatusMessage' => '<string>',
        'Url' => '<string>',
        'UserBucket' => [
            'S3Bucket' => '<string>',
            'S3Key' => '<string>',
        ],
    ],
]

Result Details

Members
Description
Type: string

A description of the import snapshot task.

ImportTaskId
Type: string

The ID of the import snapshot task.

SnapshotTaskDetail
Type: SnapshotTaskDetail structure

Information about the import snapshot task.

Errors

There are no errors described for this operation.

ImportVolume

$result = $client->importVolume([/* ... */]);
$promise = $client->importVolumeAsync([/* ... */]);

Creates an import volume task using metadata from the specified disk image. After importing the image, you then upload it using the ec2-import-volume command in the Amazon EC2 command-line interface (CLI) tools. For more information, see Using the Command Line Tools to Import Your Virtual Machine to Amazon EC2 in the Amazon Elastic Compute Cloud User Guide.

For information about the import manifest referenced by this API action, see VM Import Manifest.

Parameter Syntax

$result = $client->importVolume([
    'AvailabilityZone' => '<string>', // REQUIRED
    'Description' => '<string>',
    'DryRun' => true || false,
    'Image' => [ // REQUIRED
        'Bytes' => <integer>, // REQUIRED
        'Format' => 'VMDK|RAW|VHD', // REQUIRED
        'ImportManifestUrl' => '<string>', // REQUIRED
    ],
    'Volume' => [ // REQUIRED
        'Size' => <integer>, // REQUIRED
    ],
]);

Parameter Details

Members
AvailabilityZone
Required: Yes
Type: string

The Availability Zone for the resulting EBS volume.

Description
Type: string

A description of the volume.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Image
Required: Yes
Type: DiskImageDetail structure

The disk image.

Volume
Required: Yes
Type: VolumeDetail structure

The volume size.

Result Syntax

[
    'ConversionTask' => [
        'ConversionTaskId' => '<string>',
        'ExpirationTime' => '<string>',
        'ImportInstance' => [
            'Description' => '<string>',
            'InstanceId' => '<string>',
            'Platform' => 'Windows',
            'Volumes' => [
                [
                    'AvailabilityZone' => '<string>',
                    'BytesConverted' => <integer>,
                    'Description' => '<string>',
                    'Image' => [
                        'Checksum' => '<string>',
                        'Format' => 'VMDK|RAW|VHD',
                        'ImportManifestUrl' => '<string>',
                        'Size' => <integer>,
                    ],
                    'Status' => '<string>',
                    'StatusMessage' => '<string>',
                    'Volume' => [
                        'Id' => '<string>',
                        'Size' => <integer>,
                    ],
                ],
                // ...
            ],
        ],
        'ImportVolume' => [
            'AvailabilityZone' => '<string>',
            'BytesConverted' => <integer>,
            'Description' => '<string>',
            'Image' => [
                'Checksum' => '<string>',
                'Format' => 'VMDK|RAW|VHD',
                'ImportManifestUrl' => '<string>',
                'Size' => <integer>,
            ],
            'Volume' => [
                'Id' => '<string>',
                'Size' => <integer>,
            ],
        ],
        'State' => 'active|cancelling|cancelled|completed',
        'StatusMessage' => '<string>',
        'Tags' => [
            [
                'Key' => '<string>',
                'Value' => '<string>',
            ],
            // ...
        ],
    ],
]

Result Details

Members
ConversionTask
Type: ConversionTask structure

Information about the conversion task.

Errors

There are no errors described for this operation.

ModifyHosts

$result = $client->modifyHosts([/* ... */]);
$promise = $client->modifyHostsAsync([/* ... */]);

Modify the auto-placement setting of a Dedicated host. When auto-placement is enabled, AWS will place instances that you launch with a tenancy of host, but without targeting a specific host ID, onto any available Dedicated host in your account which has auto-placement enabled. When auto-placement is disabled, you need to provide a host ID if you want the instance to launch onto a specific host. If no host ID is provided, the instance will be launched onto a suitable host which has auto-placement enabled.

Parameter Syntax

$result = $client->modifyHosts([
    'AutoPlacement' => 'on|off', // REQUIRED
    'HostIds' => ['<string>', ...], // REQUIRED
]);

Parameter Details

Members
AutoPlacement
Required: Yes
Type: string

Specify whether to enable or disable auto-placement.

HostIds
Required: Yes
Type: Array of strings

The host IDs of the Dedicated hosts you want to modify.

Result Syntax

[
    'Successful' => ['<string>', ...],
    'Unsuccessful' => [
        [
            'Error' => [
                'Code' => '<string>',
                'Message' => '<string>',
            ],
            'ResourceId' => '<string>',
        ],
        // ...
    ],
]

Result Details

Members
Successful
Type: Array of strings

The IDs of the Dedicated hosts that were successfully modified.

Unsuccessful
Type: Array of UnsuccessfulItem structures

The IDs of the Dedicated hosts that could not be modified. Check whether the setting you requested can be used.

Errors

There are no errors described for this operation.

ModifyIdFormat

$result = $client->modifyIdFormat([/* ... */]);
$promise = $client->modifyIdFormatAsync([/* ... */]);

Modifies the ID format for the specified resource on a per-region basis. You can specify that resources should receive longer IDs (17-character IDs) when they are created. The following resource types support longer IDs: instance | reservation | snapshot | volume.

This setting applies to the IAM user who makes the request; it does not apply to the entire AWS account. By default, an IAM user defaults to the same settings as the root user. If you're using this action as the root user or as an IAM role that has permission to use this action, then these settings apply to the entire account, unless an IAM user explicitly overrides these settings for themselves. For more information, see Controlling Access to Longer ID Settings in the Amazon Elastic Compute Cloud User Guide.

Resources created with longer IDs are visible to all IAM users, regardless of these settings and provided that they have permission to use the relevant Describe command for the resource type.

Parameter Syntax

$result = $client->modifyIdFormat([
    'Resource' => '<string>', // REQUIRED
    'UseLongIds' => true || false, // REQUIRED
]);

Parameter Details

Members
Resource
Required: Yes
Type: string

The type of resource.

UseLongIds
Required: Yes
Type: boolean

Indicate whether the resource should use longer IDs (17-character IDs).

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

ModifyImageAttribute

$result = $client->modifyImageAttribute([/* ... */]);
$promise = $client->modifyImageAttributeAsync([/* ... */]);

Modifies the specified attribute of the specified AMI. You can specify only one attribute at a time.

AWS Marketplace product codes cannot be modified. Images with an AWS Marketplace product code cannot be made public.

Parameter Syntax

$result = $client->modifyImageAttribute([
    'Attribute' => '<string>',
    'Description' => [
        'Value' => '<string>',
    ],
    'DryRun' => true || false,
    'ImageId' => '<string>', // REQUIRED
    'LaunchPermission' => [
        'Add' => [
            [
                'Group' => 'all',
                'UserId' => '<string>',
            ],
            // ...
        ],
        'Remove' => [
            [
                'Group' => 'all',
                'UserId' => '<string>',
            ],
            // ...
        ],
    ],
    'OperationType' => 'add|remove',
    'ProductCodes' => ['<string>', ...],
    'UserGroups' => ['<string>', ...],
    'UserIds' => ['<string>', ...],
    'Value' => '<string>',
]);

Parameter Details

Members
Attribute
Type: string

The name of the attribute to modify.

Description
Type: AttributeValue structure

A description for the AMI.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

ImageId
Required: Yes
Type: string

The ID of the AMI.

LaunchPermission

A launch permission modification.

OperationType
Type: string

The operation type.

ProductCodes
Type: Array of strings

One or more product codes. After you add a product code to an AMI, it can't be removed. This is only valid when modifying the productCodes attribute.

UserGroups
Type: Array of strings

One or more user groups. This is only valid when modifying the launchPermission attribute.

UserIds
Type: Array of strings

One or more AWS account IDs. This is only valid when modifying the launchPermission attribute.

Value
Type: string

The value of the attribute being modified. This is only valid when modifying the description attribute.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

ModifyInstanceAttribute

$result = $client->modifyInstanceAttribute([/* ... */]);
$promise = $client->modifyInstanceAttributeAsync([/* ... */]);

Modifies the specified attribute of the specified instance. You can specify only one attribute at a time.

To modify some attributes, the instance must be stopped. For more information, see Modifying Attributes of a Stopped Instance in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->modifyInstanceAttribute([
    'Attribute' => 'instanceType|kernel|ramdisk|userData|disableApiTermination|instanceInitiatedShutdownBehavior|rootDeviceName|blockDeviceMapping|productCodes|sourceDestCheck|groupSet|ebsOptimized|sriovNetSupport',
    'BlockDeviceMappings' => [
        [
            'DeviceName' => '<string>',
            'Ebs' => [
                'DeleteOnTermination' => true || false,
                'VolumeId' => '<string>',
            ],
            'NoDevice' => '<string>',
            'VirtualName' => '<string>',
        ],
        // ...
    ],
    'DisableApiTermination' => [
        'Value' => true || false,
    ],
    'DryRun' => true || false,
    'EbsOptimized' => [
        'Value' => true || false,
    ],
    'Groups' => ['<string>', ...],
    'InstanceId' => '<string>', // REQUIRED
    'InstanceInitiatedShutdownBehavior' => [
        'Value' => '<string>',
    ],
    'InstanceType' => [
        'Value' => '<string>',
    ],
    'Kernel' => [
        'Value' => '<string>',
    ],
    'Ramdisk' => [
        'Value' => '<string>',
    ],
    'SourceDestCheck' => [
        'Value' => true || false,
    ],
    'SriovNetSupport' => [
        'Value' => '<string>',
    ],
    'UserData' => [
        'Value' => <string || resource || Psr\Http\Message\StreamInterface>,
    ],
    'Value' => '<string>',
]);

Parameter Details

Members
Attribute
Type: string

The name of the attribute.

BlockDeviceMappings
Type: Array of InstanceBlockDeviceMappingSpecification structures

Modifies the DeleteOnTermination attribute for volumes that are currently attached. The volume must be owned by the caller. If no value is specified for DeleteOnTermination, the default is true and the volume is deleted when the instance is terminated.

To add instance store volumes to an Amazon EBS-backed instance, you must add them when you launch the instance. For more information, see Updating the Block Device Mapping when Launching an Instance in the Amazon Elastic Compute Cloud User Guide.

DisableApiTermination
Type: AttributeBooleanValue structure

If the value is true, you can't terminate the instance using the Amazon EC2 console, CLI, or API; otherwise, you can. You cannot use this paramater for Spot Instances.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

EbsOptimized
Type: AttributeBooleanValue structure

Specifies whether the instance is optimized for EBS I/O. This optimization provides dedicated throughput to Amazon EBS and an optimized configuration stack to provide optimal EBS I/O performance. This optimization isn't available with all instance types. Additional usage charges apply when using an EBS Optimized instance.

Groups
Type: Array of strings

[EC2-VPC] Changes the security groups of the instance. You must specify at least one security group, even if it's just the default security group for the VPC. You must specify the security group ID, not the security group name.

InstanceId
Required: Yes
Type: string

The ID of the instance.

InstanceInitiatedShutdownBehavior
Type: AttributeValue structure

Specifies whether an instance stops or terminates when you initiate shutdown from the instance (using the operating system command for system shutdown).

InstanceType
Type: AttributeValue structure

Changes the instance type to the specified value. For more information, see Instance Types. If the instance type is not valid, the error returned is InvalidInstanceAttributeValue.

Kernel
Type: AttributeValue structure

Changes the instance's kernel to the specified value. We recommend that you use PV-GRUB instead of kernels and RAM disks. For more information, see PV-GRUB.

Ramdisk
Type: AttributeValue structure

Changes the instance's RAM disk to the specified value. We recommend that you use PV-GRUB instead of kernels and RAM disks. For more information, see PV-GRUB.

SourceDestCheck
Type: AttributeBooleanValue structure

Specifies whether source/destination checking is enabled. A value of true means that checking is enabled, and false means checking is disabled. This value must be false for a NAT instance to perform NAT.

SriovNetSupport
Type: AttributeValue structure

Set to simple to enable enhanced networking for the instance.

There is no way to disable enhanced networking at this time.

This option is supported only for HVM instances. Specifying this option with a PV instance can make it unreachable.

UserData
Type: BlobAttributeValue structure

Changes the instance's user data to the specified base64-encoded value. For command line tools, base64 encoding is performed for you.

Value
Type: string

A new value for the attribute. Use only with the kernel, ramdisk, userData, disableApiTermination, or instanceInitiatedShutdownBehavior attribute.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

ModifyInstancePlacement

$result = $client->modifyInstancePlacement([/* ... */]);
$promise = $client->modifyInstancePlacementAsync([/* ... */]);

Set the instance affinity value for a specific stopped instance and modify the instance tenancy setting.

Instance affinity is disabled by default. When instance affinity is host and it is not associated with a specific Dedicated host, the next time it is launched it will automatically be associated with the host it lands on. This relationship will persist if the instance is stopped/started, or rebooted.

You can modify the host ID associated with a stopped instance. If a stopped instance has a new host ID association, the instance will target that host when restarted.

You can modify the tenancy of a stopped instance with a tenancy of host or dedicated.

Affinity, hostID, and tenancy are not required parameters, but at least one of them must be specified in the request. Affinity and tenancy can be modified in the same request, but tenancy can only be modified on instances that are stopped.

Parameter Syntax

$result = $client->modifyInstancePlacement([
    'Affinity' => 'default|host',
    'HostId' => '<string>',
    'InstanceId' => '<string>', // REQUIRED
    'Tenancy' => 'dedicated|host',
]);

Parameter Details

Members
Affinity
Type: string

The new affinity setting for the instance.

HostId
Type: string

The ID of the Dedicated host that the instance will have affinity with.

InstanceId
Required: Yes
Type: string

The ID of the instance that you are modifying.

Tenancy
Type: string

The tenancy of the instance that you are modifying.

Result Syntax

[
    'Return' => true || false,
]

Result Details

Members
Return
Type: boolean

Is true if the request succeeds, and an error otherwise.

Errors

There are no errors described for this operation.

ModifyNetworkInterfaceAttribute

$result = $client->modifyNetworkInterfaceAttribute([/* ... */]);
$promise = $client->modifyNetworkInterfaceAttributeAsync([/* ... */]);

Modifies the specified network interface attribute. You can specify only one attribute at a time.

Parameter Syntax

$result = $client->modifyNetworkInterfaceAttribute([
    'Attachment' => [
        'AttachmentId' => '<string>',
        'DeleteOnTermination' => true || false,
    ],
    'Description' => [
        'Value' => '<string>',
    ],
    'DryRun' => true || false,
    'Groups' => ['<string>', ...],
    'NetworkInterfaceId' => '<string>', // REQUIRED
    'SourceDestCheck' => [
        'Value' => true || false,
    ],
]);

Parameter Details

Members
Attachment

Information about the interface attachment. If modifying the 'delete on termination' attribute, you must specify the ID of the interface attachment.

Description
Type: AttributeValue structure

A description for the network interface.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Groups
Type: Array of strings

Changes the security groups for the network interface. The new set of groups you specify replaces the current set. You must specify at least one group, even if it's just the default security group in the VPC. You must specify the ID of the security group, not the name.

NetworkInterfaceId
Required: Yes
Type: string

The ID of the network interface.

SourceDestCheck
Type: AttributeBooleanValue structure

Indicates whether source/destination checking is enabled. A value of true means checking is enabled, and false means checking is disabled. This value must be false for a NAT instance to perform NAT. For more information, see NAT Instances in the Amazon Virtual Private Cloud User Guide.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

ModifyReservedInstances

$result = $client->modifyReservedInstances([/* ... */]);
$promise = $client->modifyReservedInstancesAsync([/* ... */]);

Modifies the Availability Zone, instance count, instance type, or network platform (EC2-Classic or EC2-VPC) of your Reserved Instances. The Reserved Instances to be modified must be identical, except for Availability Zone, network platform, and instance type.

For more information, see Modifying Reserved Instances in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->modifyReservedInstances([
    'ClientToken' => '<string>',
    'ReservedInstancesIds' => ['<string>', ...], // REQUIRED
    'TargetConfigurations' => [ // REQUIRED
        [
            'AvailabilityZone' => '<string>',
            'InstanceCount' => <integer>,
            'InstanceType' => 't1.micro|m1.small|m1.medium|m1.large|m1.xlarge|m3.medium|m3.large|m3.xlarge|m3.2xlarge|m4.large|m4.xlarge|m4.2xlarge|m4.4xlarge|m4.10xlarge|t2.nano|t2.micro|t2.small|t2.medium|t2.large|m2.xlarge|m2.2xlarge|m2.4xlarge|cr1.8xlarge|x1.4xlarge|x1.8xlarge|x1.16xlarge|x1.32xlarge|i2.xlarge|i2.2xlarge|i2.4xlarge|i2.8xlarge|hi1.4xlarge|hs1.8xlarge|c1.medium|c1.xlarge|c3.large|c3.xlarge|c3.2xlarge|c3.4xlarge|c3.8xlarge|c4.large|c4.xlarge|c4.2xlarge|c4.4xlarge|c4.8xlarge|cc1.4xlarge|cc2.8xlarge|g2.2xlarge|g2.8xlarge|cg1.4xlarge|r3.large|r3.xlarge|r3.2xlarge|r3.4xlarge|r3.8xlarge|d2.xlarge|d2.2xlarge|d2.4xlarge|d2.8xlarge',
            'Platform' => '<string>',
        ],
        // ...
    ],
]);

Parameter Details

Members
ClientToken
Type: string

A unique, case-sensitive token you provide to ensure idempotency of your modification request. For more information, see Ensuring Idempotency.

ReservedInstancesIds
Required: Yes
Type: Array of strings

The IDs of the Reserved Instances to modify.

TargetConfigurations
Required: Yes
Type: Array of ReservedInstancesConfiguration structures

The configuration settings for the Reserved Instances to modify.

Result Syntax

[
    'ReservedInstancesModificationId' => '<string>',
]

Result Details

Members
ReservedInstancesModificationId
Type: string

The ID for the modification.

Errors

There are no errors described for this operation.

ModifySnapshotAttribute

$result = $client->modifySnapshotAttribute([/* ... */]);
$promise = $client->modifySnapshotAttributeAsync([/* ... */]);

Adds or removes permission settings for the specified snapshot. You may add or remove specified AWS account IDs from a snapshot's list of create volume permissions, but you cannot do both in a single API call. If you need to both add and remove account IDs for a snapshot, you must use multiple API calls.

For more information on modifying snapshot permissions, see Sharing Snapshots in the Amazon Elastic Compute Cloud User Guide.

Snapshots with AWS Marketplace product codes cannot be made public.

Parameter Syntax

$result = $client->modifySnapshotAttribute([
    'Attribute' => 'productCodes|createVolumePermission',
    'CreateVolumePermission' => [
        'Add' => [
            [
                'Group' => 'all',
                'UserId' => '<string>',
            ],
            // ...
        ],
        'Remove' => [
            [
                'Group' => 'all',
                'UserId' => '<string>',
            ],
            // ...
        ],
    ],
    'DryRun' => true || false,
    'GroupNames' => ['<string>', ...],
    'OperationType' => 'add|remove',
    'SnapshotId' => '<string>', // REQUIRED
    'UserIds' => ['<string>', ...],
]);

Parameter Details

Members
Attribute
Type: string

The snapshot attribute to modify.

Only volume creation permissions may be modified at the customer level.

CreateVolumePermission

A JSON representation of the snapshot attribute modification.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

GroupNames
Type: Array of strings

The group to modify for the snapshot.

OperationType
Type: string

The type of operation to perform to the attribute.

SnapshotId
Required: Yes
Type: string

The ID of the snapshot.

UserIds
Type: Array of strings

The account ID to modify for the snapshot.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

ModifySpotFleetRequest

$result = $client->modifySpotFleetRequest([/* ... */]);
$promise = $client->modifySpotFleetRequestAsync([/* ... */]);

Modifies the specified Spot fleet request.

While the Spot fleet request is being modified, it is in the modifying state.

To scale up your Spot fleet, increase its target capacity. The Spot fleet launches the additional Spot instances according to the allocation strategy for the Spot fleet request. If the allocation strategy is lowestPrice, the Spot fleet launches instances using the Spot pool with the lowest price. If the allocation strategy is diversified, the Spot fleet distributes the instances across the Spot pools.

To scale down your Spot fleet, decrease its target capacity. First, the Spot fleet cancels any open bids that exceed the new target capacity. You can request that the Spot fleet terminate Spot instances until the size of the fleet no longer exceeds the new target capacity. If the allocation strategy is lowestPrice, the Spot fleet terminates the instances with the highest price per unit. If the allocation strategy is diversified, the Spot fleet terminates instances across the Spot pools. Alternatively, you can request that the Spot fleet keep the fleet at its current size, but not replace any Spot instances that are interrupted or that you terminate manually.

Parameter Syntax

$result = $client->modifySpotFleetRequest([
    'ExcessCapacityTerminationPolicy' => 'noTermination|default',
    'SpotFleetRequestId' => '<string>', // REQUIRED
    'TargetCapacity' => <integer>,
]);

Parameter Details

Members
ExcessCapacityTerminationPolicy
Type: string

Indicates whether running Spot instances should be terminated if the target capacity of the Spot fleet request is decreased below the current size of the Spot fleet.

SpotFleetRequestId
Required: Yes
Type: string

The ID of the Spot fleet request.

TargetCapacity
Type: int

The size of the fleet.

Result Syntax

[
    'Return' => true || false,
]

Result Details

Members
Return
Type: boolean

Is true if the request succeeds, and an error otherwise.

Errors

There are no errors described for this operation.

ModifySubnetAttribute

$result = $client->modifySubnetAttribute([/* ... */]);
$promise = $client->modifySubnetAttributeAsync([/* ... */]);

Modifies a subnet attribute.

Parameter Syntax

$result = $client->modifySubnetAttribute([
    'MapPublicIpOnLaunch' => [
        'Value' => true || false,
    ],
    'SubnetId' => '<string>', // REQUIRED
]);

Parameter Details

Members
MapPublicIpOnLaunch
Type: AttributeBooleanValue structure

Specify true to indicate that instances launched into the specified subnet should be assigned public IP address.

SubnetId
Required: Yes
Type: string

The ID of the subnet.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

ModifyVolumeAttribute

$result = $client->modifyVolumeAttribute([/* ... */]);
$promise = $client->modifyVolumeAttributeAsync([/* ... */]);

Modifies a volume attribute.

By default, all I/O operations for the volume are suspended when the data on the volume is determined to be potentially inconsistent, to prevent undetectable, latent data corruption. The I/O access to the volume can be resumed by first enabling I/O access and then checking the data consistency on your volume.

You can change the default behavior to resume I/O operations. We recommend that you change this only for boot volumes or for volumes that are stateless or disposable.

Parameter Syntax

$result = $client->modifyVolumeAttribute([
    'AutoEnableIO' => [
        'Value' => true || false,
    ],
    'DryRun' => true || false,
    'VolumeId' => '<string>', // REQUIRED
]);

Parameter Details

Members
AutoEnableIO
Type: AttributeBooleanValue structure

Indicates whether the volume should be auto-enabled for I/O operations.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

VolumeId
Required: Yes
Type: string

The ID of the volume.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

ModifyVpcAttribute

$result = $client->modifyVpcAttribute([/* ... */]);
$promise = $client->modifyVpcAttributeAsync([/* ... */]);

Modifies the specified attribute of the specified VPC.

Parameter Syntax

$result = $client->modifyVpcAttribute([
    'EnableDnsHostnames' => [
        'Value' => true || false,
    ],
    'EnableDnsSupport' => [
        'Value' => true || false,
    ],
    'VpcId' => '<string>', // REQUIRED
]);

Parameter Details

Members
EnableDnsHostnames
Type: AttributeBooleanValue structure

Indicates whether the instances launched in the VPC get DNS hostnames. If enabled, instances in the VPC get DNS hostnames; otherwise, they do not.

You cannot modify the DNS resolution and DNS hostnames attributes in the same request. Use separate requests for each attribute. You can only enable DNS hostnames if you've enabled DNS support.

EnableDnsSupport
Type: AttributeBooleanValue structure

Indicates whether the DNS resolution is supported for the VPC. If enabled, queries to the Amazon provided DNS server at the 169.254.169.253 IP address, or the reserved IP address at the base of the VPC network range "plus two" will succeed. If disabled, the Amazon provided DNS service in the VPC that resolves public DNS hostnames to IP addresses is not enabled.

You cannot modify the DNS resolution and DNS hostnames attributes in the same request. Use separate requests for each attribute.

VpcId
Required: Yes
Type: string

The ID of the VPC.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

There are no errors described for this operation.

ModifyVpcEndpoint

$result = $client->modifyVpcEndpoint([/* ... */]);
$promise = $client->modifyVpcEndpointAsync([/* ... */]);

Modifies attributes of a specified VPC endpoint. You can modify the policy associated with the endpoint, and you can add and remove route tables associated with the endpoint.

Parameter Syntax

$result = $client->modifyVpcEndpoint([
    'AddRouteTableIds' => ['<string>', ...],
    'DryRun' => true || false,
    'PolicyDocument' => '<string>',
    'RemoveRouteTableIds' => ['<string>', ...],
    'ResetPolicy' => true || false,
    'VpcEndpointId' => '<string>', // REQUIRED
]);

Parameter Details

Members
AddRouteTableIds
Type: Array of strings

One or more route tables IDs to associate with the endpoint.

DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

PolicyDocument
Type: string

A policy document to attach to the endpoint. The policy must be in valid JSON format.

RemoveRouteTableIds
Type: Array of strings

One or more route table IDs to disassociate from the endpoint.

ResetPolicy
Type: boolean

Specify true to reset the policy document to the default policy. The default policy allows access to the service.

VpcEndpointId
Required: Yes
Type: string

The ID of the endpoint.

Result Syntax

[
    'Return' => true || false,
]

Result Details

Members
Return
Type: boolean

Returns true if the request succeeds; otherwise, it returns an error.

Errors

There are no errors described for this operation.

ModifyVpcPeeringConnectionOptions

$result = $client->modifyVpcPeeringConnectionOptions([/* ... */]);
$promise = $client->modifyVpcPeeringConnectionOptionsAsync([/* ... */]);

Modifies the VPC peering connection options on one side of a VPC peering connection. You can do the following:

  • Enable/disable communication over the peering connection between an EC2-Classic instance that's linked to your VPC (using ClassicLink) and instances in the peer VPC.

  • Enable/disable communication over the peering connection between instances in your VPC and an EC2-Classic instance that's linked to the peer VPC.

If the peered VPCs are in different accounts, each owner must initiate a separate request to enable or disable communication in either direction, depending on whether their VPC was the requester or accepter for the VPC peering connection. If the peered VPCs are in the same account, you can modify the requester and accepter options in the same request. To confirm which VPC is the accepter and requester for a VPC peering connection, use the DescribeVpcPeeringConnections command.

Parameter Syntax

$result = $client->modifyVpcPeeringConnectionOptions([
    'AccepterPeeringConnectionOptions' => [
        'AllowEgressFromLocalClassicLinkToRemoteVpc' => true || false, // REQUIRED
        'AllowEgressFromLocalVpcToRemoteClassicLink' => true || false, // REQUIRED
    ],
    'DryRun' => true || false,
    'RequesterPeeringConnectionOptions' => [
        'AllowEgressFromLocalClassicLinkToRemoteVpc' => true || false, // REQUIRED
        'AllowEgressFromLocalVpcToRemoteClassicLink' => true || false, // REQUIRED
    ],
    'VpcPeeringConnectionId' => '<string>', // REQUIRED
]);

Parameter Details

Members
AccepterPeeringConnectionOptions

The VPC peering connection options for the accepter VPC.

DryRun
Type: boolean

Checks whether you have the required permissions for the operation, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

RequesterPeeringConnectionOptions

The VPC peering connection options for the requester VPC.

VpcPeeringConnectionId
Required: Yes
Type: string

The ID of the VPC peering connection.

Result Syntax

[
    'AccepterPeeringConnectionOptions' => [
        'AllowEgressFromLocalClassicLinkToRemoteVpc' => true || false,
        'AllowEgressFromLocalVpcToRemoteClassicLink' => true || false,
    ],
    'RequesterPeeringConnectionOptions' => [
        'AllowEgressFromLocalClassicLinkToRemoteVpc' => true || false,
        'AllowEgressFromLocalVpcToRemoteClassicLink' => true || false,
    ],
]

Result Details

Members
AccepterPeeringConnectionOptions
Type: PeeringConnectionOptions structure

Information about the VPC peering connection options for the accepter VPC.

RequesterPeeringConnectionOptions
Type: PeeringConnectionOptions structure

Information about the VPC peering connection options for the requester VPC.

Errors

There are no errors described for this operation.

MonitorInstances

$result = $client->monitorInstances([/* ... */]);
$promise = $client->monitorInstancesAsync([/* ... */]);

Enables monitoring for a running instance. For more information about monitoring instances, see Monitoring Your Instances and Volumes in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->monitorInstances([
    'DryRun' => true || false,
    'InstanceIds' => ['<string>', ...], // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

InstanceIds
Required: Yes
Type: Array of strings

One or more instance IDs.

Result Syntax

[
    'InstanceMonitorings' => [
        [
            'InstanceId' => '<string>',
            'Monitoring' => [
                'State' => 'disabled|disabling|enabled|pending',
            ],
        ],
        // ...
    ],
]

Result Details

Members
InstanceMonitorings
Type: Array of InstanceMonitoring structures

Monitoring information for one or more instances.

Errors

There are no errors described for this operation.

MoveAddressToVpc

$result = $client->moveAddressToVpc([/* ... */]);
$promise = $client->moveAddressToVpcAsync([/* ... */]);

Moves an Elastic IP address from the EC2-Classic platform to the EC2-VPC platform. The Elastic IP address must be allocated to your account for more than 24 hours, and it must not be associated with an instance. After the Elastic IP address is moved, it is no longer available for use in the EC2-Classic platform, unless you move it back using the RestoreAddressToClassic request. You cannot move an Elastic IP address that was originally allocated for use in the EC2-VPC platform to the EC2-Classic platform.

Parameter Syntax

$result = $client->moveAddressToVpc([
    'DryRun' => true || false,
    'PublicIp' => '<string>', // REQUIRED
]);

Parameter Details

Members
DryRun
Type: boolean

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

PublicIp
Required: Yes
Type: string

The Elastic IP address.

Result Syntax

[
    'AllocationId' => '<string>',
    'Status' => 'MoveInProgress|InVpc|InClassic',
]

Result Details

Members
AllocationId
Type: string

The allocation ID for the Elastic IP address.

Status
Type: string

The status of the move of the IP address.

Errors

There are no errors described for this operation.

PurchaseReservedInstancesOffering

$result = $client->purchaseReservedInstancesOffering([/* ... */]);
$promise = $client->purchaseReservedInstancesOfferingAsync([/* ... */]);

Purchases a Reserved Instance for use with your account. With Reserved Instances, you obtain a capacity reservation for a certain instance configuration over a specified period of time and pay a lower hourly rate compared to On-Demand instance pricing.

Use DescribeReservedInstancesOfferings to get a list of Reserved Instance offerings that match your specifications. After you've purchased a Reserved Instance, you can check for your new Reserved Instance with DescribeReservedInstances.

For more information, see Reserved Instances and Reserved Instance Marketplace in the Amazon Elastic Compute Cloud User Guide.

Parameter Syntax

$result = $client->purchaseReservedInstancesOffering([
    'DryRun' => true || false,
    'InstanceCount' => <integer>, // REQUI