Skip to content

Commit

Permalink
Regenerating amazonka-ec2 from latest service definition
Browse files Browse the repository at this point in the history
  • Loading branch information
brendanhay committed Nov 29, 2016
1 parent 582c047 commit 4117a08
Show file tree
Hide file tree
Showing 223 changed files with 1,179 additions and 278 deletions.
2 changes: 2 additions & 0 deletions amazonka-ec2/amazonka-ec2.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ library

exposed-modules:
Network.AWS.EC2
, Network.AWS.EC2.AcceptReservedInstancesExchangeQuote
, Network.AWS.EC2.AcceptVPCPeeringConnection
, Network.AWS.EC2.AllocateAddress
, Network.AWS.EC2.AllocateHosts
Expand Down Expand Up @@ -199,6 +200,7 @@ library
, Network.AWS.EC2.GetConsoleScreenshot
, Network.AWS.EC2.GetHostReservationPurchasePreview
, Network.AWS.EC2.GetPasswordData
, Network.AWS.EC2.GetReservedInstancesExchangeQuote
, Network.AWS.EC2.ImportImage
, Network.AWS.EC2.ImportInstance
, Network.AWS.EC2.ImportKeyPair
Expand Down
Empty file.
Empty file.
Empty file.
Empty file.
53 changes: 53 additions & 0 deletions amazonka-ec2/gen/Network/AWS/EC2.hs
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,9 @@ module Network.AWS.EC2
-- ** VolumeDeleted
, volumeDeleted

-- ** VPCExists
, vpcExists

-- ** BundleTaskComplete
, bundleTaskComplete

Expand Down Expand Up @@ -155,6 +158,9 @@ module Network.AWS.EC2
-- ** CancelBundleTask
, module Network.AWS.EC2.CancelBundleTask

-- ** AcceptReservedInstancesExchangeQuote
, module Network.AWS.EC2.AcceptReservedInstancesExchangeQuote

-- ** ReleaseAddress
, module Network.AWS.EC2.ReleaseAddress

Expand Down Expand Up @@ -734,6 +740,9 @@ module Network.AWS.EC2
-- ** CreateKeyPair
, module Network.AWS.EC2.CreateKeyPair

-- ** GetReservedInstancesExchangeQuote
, module Network.AWS.EC2.GetReservedInstancesExchangeQuote

-- ** DeleteVolume
, module Network.AWS.EC2.DeleteVolume

Expand Down Expand Up @@ -883,6 +892,9 @@ module Network.AWS.EC2
-- ** NetworkInterfaceType
, NetworkInterfaceType (..)

-- ** OfferingClassType
, OfferingClassType (..)

-- ** OfferingTypeValues
, OfferingTypeValues (..)

Expand Down Expand Up @@ -940,6 +952,9 @@ module Network.AWS.EC2
-- ** RuleAction
, RuleAction (..)

-- ** Scope
, Scope (..)

-- ** ShutdownBehavior
, ShutdownBehavior (..)

Expand Down Expand Up @@ -2022,12 +2037,25 @@ module Network.AWS.EC2
, rReservationId
, rOwnerId

-- ** ReservationValue
, ReservationValue
, reservationValue
, rvHourlyPrice
, rvRemainingTotalValue
, rvRemainingUpfrontValue

-- ** ReservedInstanceLimitPrice
, ReservedInstanceLimitPrice
, reservedInstanceLimitPrice
, rilpAmount
, rilpCurrencyCode

-- ** ReservedInstanceReservationValue
, ReservedInstanceReservationValue
, reservedInstanceReservationValue
, rirvReservationValue
, rirvReservedInstanceId

-- ** ReservedInstances
, ReservedInstances
, reservedInstances
Expand All @@ -2039,12 +2067,14 @@ module Network.AWS.EC2
, riInstanceType
, riEnd
, riAvailabilityZone
, riScope
, riRecurringCharges
, riOfferingType
, riUsagePrice
, riFixedPrice
, riReservedInstancesId
, riInstanceTenancy
, riOfferingClass
, riDuration
, riTags

Expand All @@ -2055,6 +2085,7 @@ module Network.AWS.EC2
, ricInstanceCount
, ricInstanceType
, ricAvailabilityZone
, ricScope

-- ** ReservedInstancesId
, ReservedInstancesId
Expand Down Expand Up @@ -2103,12 +2134,14 @@ module Network.AWS.EC2
, rioInstanceType
, rioAvailabilityZone
, rioPricingDetails
, rioScope
, rioRecurringCharges
, rioOfferingType
, rioUsagePrice
, rioFixedPrice
, rioInstanceTenancy
, rioReservedInstancesOfferingId
, rioOfferingClass
, rioDuration

-- ** Route
Expand Down Expand Up @@ -2536,6 +2569,24 @@ module Network.AWS.EC2
, tdKey
, tdValue

-- ** TargetConfiguration
, TargetConfiguration
, targetConfiguration
, tcInstanceCount
, tcOfferingId

-- ** TargetConfigurationRequest
, TargetConfigurationRequest
, targetConfigurationRequest
, tcrInstanceCount
, tcrOfferingId

-- ** TargetReservationValue
, TargetReservationValue
, targetReservationValue
, trvReservationValue
, trvTargetConfiguration

-- ** UnsuccessfulItem
, UnsuccessfulItem
, unsuccessfulItem
Expand Down Expand Up @@ -2761,6 +2812,7 @@ module Network.AWS.EC2
, vsiVolumeId
) where

import Network.AWS.EC2.AcceptReservedInstancesExchangeQuote
import Network.AWS.EC2.AcceptVPCPeeringConnection
import Network.AWS.EC2.AllocateAddress
import Network.AWS.EC2.AllocateHosts
Expand Down Expand Up @@ -2920,6 +2972,7 @@ import Network.AWS.EC2.GetConsoleOutput
import Network.AWS.EC2.GetConsoleScreenshot
import Network.AWS.EC2.GetHostReservationPurchasePreview
import Network.AWS.EC2.GetPasswordData
import Network.AWS.EC2.GetReservedInstancesExchangeQuote
import Network.AWS.EC2.ImportImage
import Network.AWS.EC2.ImportInstance
import Network.AWS.EC2.ImportKeyPair
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,164 @@
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}

{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module : Network.AWS.EC2.AcceptReservedInstancesExchangeQuote
-- Copyright : (c) 2013-2016 Brendan Hay
-- License : Mozilla Public License, v. 2.0.
-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
-- Stability : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Purchases Convertible Reserved Instance offerings described in the 'GetReservedInstancesExchangeQuote' call.
--
--
module Network.AWS.EC2.AcceptReservedInstancesExchangeQuote
(
-- * Creating a Request
acceptReservedInstancesExchangeQuote
, AcceptReservedInstancesExchangeQuote
-- * Request Lenses
, arieqTargetConfigurations
, arieqDryRun
, arieqReservedInstanceIds

-- * Destructuring the Response
, acceptReservedInstancesExchangeQuoteResponse
, AcceptReservedInstancesExchangeQuoteResponse
-- * Response Lenses
, arieqrsExchangeId
, arieqrsResponseStatus
) where

import Network.AWS.EC2.Types
import Network.AWS.EC2.Types.Product
import Network.AWS.Lens
import Network.AWS.Prelude
import Network.AWS.Request
import Network.AWS.Response

-- | Contains the parameters for accepting the quote.
--
--
--
-- /See:/ 'acceptReservedInstancesExchangeQuote' smart constructor.
data AcceptReservedInstancesExchangeQuote = AcceptReservedInstancesExchangeQuote'
{ _arieqTargetConfigurations :: !(Maybe [TargetConfigurationRequest])
, _arieqDryRun :: !(Maybe Bool)
, _arieqReservedInstanceIds :: ![Text]
} deriving (Eq,Read,Show,Data,Typeable,Generic)

-- | Creates a value of 'AcceptReservedInstancesExchangeQuote' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'arieqTargetConfigurations' - The configurations of the Convertible Reserved Instance offerings you are purchasing in this exchange.
--
-- * 'arieqDryRun' - 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@ .
--
-- * 'arieqReservedInstanceIds' - The IDs of the Convertible Reserved Instances that you want to exchange for other Convertible Reserved Instances of the same or higher value.
acceptReservedInstancesExchangeQuote
:: AcceptReservedInstancesExchangeQuote
acceptReservedInstancesExchangeQuote =
AcceptReservedInstancesExchangeQuote'
{ _arieqTargetConfigurations = Nothing
, _arieqDryRun = Nothing
, _arieqReservedInstanceIds = mempty
}

-- | The configurations of the Convertible Reserved Instance offerings you are purchasing in this exchange.
arieqTargetConfigurations :: Lens' AcceptReservedInstancesExchangeQuote [TargetConfigurationRequest]
arieqTargetConfigurations = lens _arieqTargetConfigurations (\ s a -> s{_arieqTargetConfigurations = a}) . _Default . _Coerce;

-- | 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@ .
arieqDryRun :: Lens' AcceptReservedInstancesExchangeQuote (Maybe Bool)
arieqDryRun = lens _arieqDryRun (\ s a -> s{_arieqDryRun = a});

-- | The IDs of the Convertible Reserved Instances that you want to exchange for other Convertible Reserved Instances of the same or higher value.
arieqReservedInstanceIds :: Lens' AcceptReservedInstancesExchangeQuote [Text]
arieqReservedInstanceIds = lens _arieqReservedInstanceIds (\ s a -> s{_arieqReservedInstanceIds = a}) . _Coerce;

instance AWSRequest
AcceptReservedInstancesExchangeQuote where
type Rs AcceptReservedInstancesExchangeQuote =
AcceptReservedInstancesExchangeQuoteResponse
request = postQuery ec2
response
= receiveXML
(\ s h x ->
AcceptReservedInstancesExchangeQuoteResponse' <$>
(x .@? "exchangeId") <*> (pure (fromEnum s)))

instance Hashable
AcceptReservedInstancesExchangeQuote

instance NFData AcceptReservedInstancesExchangeQuote

instance ToHeaders
AcceptReservedInstancesExchangeQuote where
toHeaders = const mempty

instance ToPath AcceptReservedInstancesExchangeQuote
where
toPath = const "/"

instance ToQuery AcceptReservedInstancesExchangeQuote
where
toQuery AcceptReservedInstancesExchangeQuote'{..}
= mconcat
["Action" =:
("AcceptReservedInstancesExchangeQuote" ::
ByteString),
"Version" =: ("2016-09-15" :: ByteString),
toQuery
(toQueryList "TargetConfiguration" <$>
_arieqTargetConfigurations),
"DryRun" =: _arieqDryRun,
toQueryList "ReservedInstanceId"
_arieqReservedInstanceIds]

-- | The result of the exchange and whether it was @successful@ .
--
--
--
-- /See:/ 'acceptReservedInstancesExchangeQuoteResponse' smart constructor.
data AcceptReservedInstancesExchangeQuoteResponse = AcceptReservedInstancesExchangeQuoteResponse'
{ _arieqrsExchangeId :: !(Maybe Text)
, _arieqrsResponseStatus :: !Int
} deriving (Eq,Read,Show,Data,Typeable,Generic)

-- | Creates a value of 'AcceptReservedInstancesExchangeQuoteResponse' with the minimum fields required to make a request.
--
-- Use one of the following lenses to modify other fields as desired:
--
-- * 'arieqrsExchangeId' - The ID of the successful exchange.
--
-- * 'arieqrsResponseStatus' - -- | The response status code.
acceptReservedInstancesExchangeQuoteResponse
:: Int -- ^ 'arieqrsResponseStatus'
-> AcceptReservedInstancesExchangeQuoteResponse
acceptReservedInstancesExchangeQuoteResponse pResponseStatus_ =
AcceptReservedInstancesExchangeQuoteResponse'
{ _arieqrsExchangeId = Nothing
, _arieqrsResponseStatus = pResponseStatus_
}

-- | The ID of the successful exchange.
arieqrsExchangeId :: Lens' AcceptReservedInstancesExchangeQuoteResponse (Maybe Text)
arieqrsExchangeId = lens _arieqrsExchangeId (\ s a -> s{_arieqrsExchangeId = a});

-- | -- | The response status code.
arieqrsResponseStatus :: Lens' AcceptReservedInstancesExchangeQuoteResponse Int
arieqrsResponseStatus = lens _arieqrsResponseStatus (\ s a -> s{_arieqrsResponseStatus = a});

instance NFData
AcceptReservedInstancesExchangeQuoteResponse
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ instance ToQuery AcceptVPCPeeringConnection where
= mconcat
["Action" =:
("AcceptVpcPeeringConnection" :: ByteString),
"Version" =: ("2016-04-01" :: ByteString),
"Version" =: ("2016-09-15" :: ByteString),
"VpcPeeringConnectionId" =:
_avpcVPCPeeringConnectionId,
"DryRun" =: _avpcDryRun]
Expand Down
2 changes: 1 addition & 1 deletion amazonka-ec2/gen/Network/AWS/EC2/AllocateAddress.hs
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ instance ToQuery AllocateAddress where
toQuery AllocateAddress'{..}
= mconcat
["Action" =: ("AllocateAddress" :: ByteString),
"Version" =: ("2016-04-01" :: ByteString),
"Version" =: ("2016-09-15" :: ByteString),
"Domain" =: _aaDomain, "DryRun" =: _aaDryRun]

-- | Contains the output of AllocateAddress.
Expand Down
2 changes: 1 addition & 1 deletion amazonka-ec2/gen/Network/AWS/EC2/AllocateHosts.hs
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ instance ToQuery AllocateHosts where
toQuery AllocateHosts'{..}
= mconcat
["Action" =: ("AllocateHosts" :: ByteString),
"Version" =: ("2016-04-01" :: ByteString),
"Version" =: ("2016-09-15" :: ByteString),
"ClientToken" =: _ahClientToken,
"AutoPlacement" =: _ahAutoPlacement,
"InstanceType" =: _ahInstanceType,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ instance ToQuery AssignPrivateIPAddresses where
= mconcat
["Action" =:
("AssignPrivateIpAddresses" :: ByteString),
"Version" =: ("2016-04-01" :: ByteString),
"Version" =: ("2016-09-15" :: ByteString),
toQuery
(toQueryList "PrivateIpAddress" <$>
_apiaPrivateIPAddresses),
Expand Down
4 changes: 2 additions & 2 deletions amazonka-ec2/gen/Network/AWS/EC2/AssociateAddress.hs
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
--
-- [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.
-- /Important:/ This is an idempotent operation. If you perform the operation more than once, Amazon EC2 doesn't return an error, and you may be charged for each time the Elastic IP address is remapped to the same instance. For more information, see the /Elastic IP Addresses/ section of <http://aws.amazon.com/ec2/pricing/ Amazon EC2 Pricing> .
--
module Network.AWS.EC2.AssociateAddress
(
Expand Down Expand Up @@ -154,7 +154,7 @@ instance ToQuery AssociateAddress where
toQuery AssociateAddress'{..}
= mconcat
["Action" =: ("AssociateAddress" :: ByteString),
"Version" =: ("2016-04-01" :: ByteString),
"Version" =: ("2016-09-15" :: ByteString),
"InstanceId" =: _aasInstanceId,
"AllocationId" =: _aasAllocationId,
"NetworkInterfaceId" =: _aasNetworkInterfaceId,
Expand Down
2 changes: 1 addition & 1 deletion amazonka-ec2/gen/Network/AWS/EC2/AssociateDHCPOptions.hs
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ instance ToQuery AssociateDHCPOptions where
toQuery AssociateDHCPOptions'{..}
= mconcat
["Action" =: ("AssociateDhcpOptions" :: ByteString),
"Version" =: ("2016-04-01" :: ByteString),
"Version" =: ("2016-09-15" :: ByteString),
"DryRun" =: _adoDryRun,
"DhcpOptionsId" =: _adoDHCPOptionsId,
"VpcId" =: _adoVPCId]
Expand Down
Loading

0 comments on commit 4117a08

Please sign in to comment.