amazonka-cloudformation (empty) → 0.0.0
raw patch · 23 files changed
+4427/−0 lines, 23 filesdep +amazonka-coredep +basesetup-changed
Dependencies added: amazonka-core, base
Files
- LICENSE +373/−0
- README.md +26/−0
- Setup.hs +2/−0
- amazonka-cloudformation.cabal +69/−0
- gen/Network/AWS/CloudFormation.hs +60/−0
- gen/Network/AWS/CloudFormation/CancelUpdateStack.hs +91/−0
- gen/Network/AWS/CloudFormation/CreateStack.hs +264/−0
- gen/Network/AWS/CloudFormation/DeleteStack.hs +90/−0
- gen/Network/AWS/CloudFormation/DescribeStackEvents.hs +140/−0
- gen/Network/AWS/CloudFormation/DescribeStackResource.hs +126/−0
- gen/Network/AWS/CloudFormation/DescribeStackResources.hs +160/−0
- gen/Network/AWS/CloudFormation/DescribeStacks.hs +137/−0
- gen/Network/AWS/CloudFormation/EstimateTemplateCost.hs +136/−0
- gen/Network/AWS/CloudFormation/GetStackPolicy.hs +111/−0
- gen/Network/AWS/CloudFormation/GetTemplate.hs +113/−0
- gen/Network/AWS/CloudFormation/GetTemplateSummary.hs +192/−0
- gen/Network/AWS/CloudFormation/ListStackResources.hs +142/−0
- gen/Network/AWS/CloudFormation/ListStacks.hs +145/−0
- gen/Network/AWS/CloudFormation/SetStackPolicy.hs +116/−0
- gen/Network/AWS/CloudFormation/SignalResource.hs +133/−0
- gen/Network/AWS/CloudFormation/Types.hs +1374/−0
- gen/Network/AWS/CloudFormation/UpdateStack.hs +268/−0
- gen/Network/AWS/CloudFormation/ValidateTemplate.hs +159/−0
+ LICENSE view
@@ -0,0 +1,373 @@+Mozilla Public License Version 2.0+==================================++1. Definitions+--------------++1.1. "Contributor"+ means each individual or legal entity that creates, contributes to+ the creation of, or owns Covered Software.++1.2. "Contributor Version"+ means the combination of the Contributions of others (if any) used+ by a Contributor and that particular Contributor's Contribution.++1.3. "Contribution"+ means Covered Software of a particular Contributor.++1.4. "Covered Software"+ means Source Code Form to which the initial Contributor has attached+ the notice in Exhibit A, the Executable Form of such Source Code+ Form, and Modifications of such Source Code Form, in each case+ including portions thereof.++1.5. "Incompatible With Secondary Licenses"+ means++ (a) that the initial Contributor has attached the notice described+ in Exhibit B to the Covered Software; or++ (b) that the Covered Software was made available under the terms of+ version 1.1 or earlier of the License, but not also under the+ terms of a Secondary License.++1.6. "Executable Form"+ means any form of the work other than Source Code Form.++1.7. "Larger Work"+ means a work that combines Covered Software with other material, in+ a separate file or files, that is not Covered Software.++1.8. "License"+ means this document.++1.9. "Licensable"+ means having the right to grant, to the maximum extent possible,+ whether at the time of the initial grant or subsequently, any and+ all of the rights conveyed by this License.++1.10. "Modifications"+ means any of the following:++ (a) any file in Source Code Form that results from an addition to,+ deletion from, or modification of the contents of Covered+ Software; or++ (b) any new file in Source Code Form that contains any Covered+ Software.++1.11. "Patent Claims" of a Contributor+ means any patent claim(s), including without limitation, method,+ process, and apparatus claims, in any patent Licensable by such+ Contributor that would be infringed, but for the grant of the+ License, by the making, using, selling, offering for sale, having+ made, import, or transfer of either its Contributions or its+ Contributor Version.++1.12. "Secondary License"+ means either the GNU General Public License, Version 2.0, the GNU+ Lesser General Public License, Version 2.1, the GNU Affero General+ Public License, Version 3.0, or any later versions of those+ licenses.++1.13. "Source Code Form"+ means the form of the work preferred for making modifications.++1.14. "You" (or "Your")+ means an individual or a legal entity exercising rights under this+ License. For legal entities, "You" includes any entity that+ controls, is controlled by, or is under common control with You. For+ purposes of this definition, "control" means (a) the power, direct+ or indirect, to cause the direction or management of such entity,+ whether by contract or otherwise, or (b) ownership of more than+ fifty percent (50%) of the outstanding shares or beneficial+ ownership of such entity.++2. License Grants and Conditions+--------------------------------++2.1. Grants++Each Contributor hereby grants You a world-wide, royalty-free,+non-exclusive license:++(a) under intellectual property rights (other than patent or trademark)+ Licensable by such Contributor to use, reproduce, make available,+ modify, display, perform, distribute, and otherwise exploit its+ Contributions, either on an unmodified basis, with Modifications, or+ as part of a Larger Work; and++(b) under Patent Claims of such Contributor to make, use, sell, offer+ for sale, have made, import, and otherwise transfer either its+ Contributions or its Contributor Version.++2.2. Effective Date++The licenses granted in Section 2.1 with respect to any Contribution+become effective for each Contribution on the date the Contributor first+distributes such Contribution.++2.3. Limitations on Grant Scope++The licenses granted in this Section 2 are the only rights granted under+this License. No additional rights or licenses will be implied from the+distribution or licensing of Covered Software under this License.+Notwithstanding Section 2.1(b) above, no patent license is granted by a+Contributor:++(a) for any code that a Contributor has removed from Covered Software;+ or++(b) for infringements caused by: (i) Your and any other third party's+ modifications of Covered Software, or (ii) the combination of its+ Contributions with other software (except as part of its Contributor+ Version); or++(c) under Patent Claims infringed by Covered Software in the absence of+ its Contributions.++This License does not grant any rights in the trademarks, service marks,+or logos of any Contributor (except as may be necessary to comply with+the notice requirements in Section 3.4).++2.4. Subsequent Licenses++No Contributor makes additional grants as a result of Your choice to+distribute the Covered Software under a subsequent version of this+License (see Section 10.2) or under the terms of a Secondary License (if+permitted under the terms of Section 3.3).++2.5. Representation++Each Contributor represents that the Contributor believes its+Contributions are its original creation(s) or it has sufficient rights+to grant the rights to its Contributions conveyed by this License.++2.6. Fair Use++This License is not intended to limit any rights You have under+applicable copyright doctrines of fair use, fair dealing, or other+equivalents.++2.7. Conditions++Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted+in Section 2.1.++3. Responsibilities+-------------------++3.1. Distribution of Source Form++All distribution of Covered Software in Source Code Form, including any+Modifications that You create or to which You contribute, must be under+the terms of this License. You must inform recipients that the Source+Code Form of the Covered Software is governed by the terms of this+License, and how they can obtain a copy of this License. You may not+attempt to alter or restrict the recipients' rights in the Source Code+Form.++3.2. Distribution of Executable Form++If You distribute Covered Software in Executable Form then:++(a) such Covered Software must also be made available in Source Code+ Form, as described in Section 3.1, and You must inform recipients of+ the Executable Form how they can obtain a copy of such Source Code+ Form by reasonable means in a timely manner, at a charge no more+ than the cost of distribution to the recipient; and++(b) You may distribute such Executable Form under the terms of this+ License, or sublicense it under different terms, provided that the+ license for the Executable Form does not attempt to limit or alter+ the recipients' rights in the Source Code Form under this License.++3.3. Distribution of a Larger Work++You may create and distribute a Larger Work under terms of Your choice,+provided that You also comply with the requirements of this License for+the Covered Software. If the Larger Work is a combination of Covered+Software with a work governed by one or more Secondary Licenses, and the+Covered Software is not Incompatible With Secondary Licenses, this+License permits You to additionally distribute such Covered Software+under the terms of such Secondary License(s), so that the recipient of+the Larger Work may, at their option, further distribute the Covered+Software under the terms of either this License or such Secondary+License(s).++3.4. Notices++You may not remove or alter the substance of any license notices+(including copyright notices, patent notices, disclaimers of warranty,+or limitations of liability) contained within the Source Code Form of+the Covered Software, except that You may alter any license notices to+the extent required to remedy known factual inaccuracies.++3.5. Application of Additional Terms++You may choose to offer, and to charge a fee for, warranty, support,+indemnity or liability obligations to one or more recipients of Covered+Software. However, You may do so only on Your own behalf, and not on+behalf of any Contributor. You must make it absolutely clear that any+such warranty, support, indemnity, or liability obligation is offered by+You alone, and You hereby agree to indemnify every Contributor for any+liability incurred by such Contributor as a result of warranty, support,+indemnity or liability terms You offer. You may include additional+disclaimers of warranty and limitations of liability specific to any+jurisdiction.++4. Inability to Comply Due to Statute or Regulation+---------------------------------------------------++If it is impossible for You to comply with any of the terms of this+License with respect to some or all of the Covered Software due to+statute, judicial order, or regulation then You must: (a) comply with+the terms of this License to the maximum extent possible; and (b)+describe the limitations and the code they affect. Such description must+be placed in a text file included with all distributions of the Covered+Software under this License. Except to the extent prohibited by statute+or regulation, such description must be sufficiently detailed for a+recipient of ordinary skill to be able to understand it.++5. Termination+--------------++5.1. The rights granted under this License will terminate automatically+if You fail to comply with any of its terms. However, if You become+compliant, then the rights granted under this License from a particular+Contributor are reinstated (a) provisionally, unless and until such+Contributor explicitly and finally terminates Your grants, and (b) on an+ongoing basis, if such Contributor fails to notify You of the+non-compliance by some reasonable means prior to 60 days after You have+come back into compliance. Moreover, Your grants from a particular+Contributor are reinstated on an ongoing basis if such Contributor+notifies You of the non-compliance by some reasonable means, this is the+first time You have received notice of non-compliance with this License+from such Contributor, and You become compliant prior to 30 days after+Your receipt of the notice.++5.2. If You initiate litigation against any entity by asserting a patent+infringement claim (excluding declaratory judgment actions,+counter-claims, and cross-claims) alleging that a Contributor Version+directly or indirectly infringes any patent, then the rights granted to+You by any and all Contributors for the Covered Software under Section+2.1 of this License shall terminate.++5.3. In the event of termination under Sections 5.1 or 5.2 above, all+end user license agreements (excluding distributors and resellers) which+have been validly granted by You or Your distributors under this License+prior to termination shall survive termination.++************************************************************************+* *+* 6. Disclaimer of Warranty *+* ------------------------- *+* *+* Covered Software is provided under this License on an "as is" *+* basis, without warranty of any kind, either expressed, implied, or *+* statutory, including, without limitation, warranties that the *+* Covered Software is free of defects, merchantable, fit for a *+* particular purpose or non-infringing. The entire risk as to the *+* quality and performance of the Covered Software is with You. *+* Should any Covered Software prove defective in any respect, You *+* (not any Contributor) assume the cost of any necessary servicing, *+* repair, or correction. This disclaimer of warranty constitutes an *+* essential part of this License. No use of any Covered Software is *+* authorized under this License except under this disclaimer. *+* *+************************************************************************++************************************************************************+* *+* 7. Limitation of Liability *+* -------------------------- *+* *+* Under no circumstances and under no legal theory, whether tort *+* (including negligence), contract, or otherwise, shall any *+* Contributor, or anyone who distributes Covered Software as *+* permitted above, be liable to You for any direct, indirect, *+* special, incidental, or consequential damages of any character *+* including, without limitation, damages for lost profits, loss of *+* goodwill, work stoppage, computer failure or malfunction, or any *+* and all other commercial damages or losses, even if such party *+* shall have been informed of the possibility of such damages. This *+* limitation of liability shall not apply to liability for death or *+* personal injury resulting from such party's negligence to the *+* extent applicable law prohibits such limitation. Some *+* jurisdictions do not allow the exclusion or limitation of *+* incidental or consequential damages, so this exclusion and *+* limitation may not apply to You. *+* *+************************************************************************++8. Litigation+-------------++Any litigation relating to this License may be brought only in the+courts of a jurisdiction where the defendant maintains its principal+place of business and such litigation shall be governed by laws of that+jurisdiction, without reference to its conflict-of-law provisions.+Nothing in this Section shall prevent a party's ability to bring+cross-claims or counter-claims.++9. Miscellaneous+----------------++This License represents the complete agreement concerning the subject+matter hereof. If any provision of this License is held to be+unenforceable, such provision shall be reformed only to the extent+necessary to make it enforceable. Any law or regulation which provides+that the language of a contract shall be construed against the drafter+shall not be used to construe this License against a Contributor.++10. Versions of the License+---------------------------++10.1. New Versions++Mozilla Foundation is the license steward. Except as provided in Section+10.3, no one other than the license steward has the right to modify or+publish new versions of this License. Each version will be given a+distinguishing version number.++10.2. Effect of New Versions++You may distribute the Covered Software under the terms of the version+of the License under which You originally received the Covered Software,+or under the terms of any subsequent version published by the license+steward.++10.3. Modified Versions++If you create software not governed by this License, and you want to+create a new license for such software, you may create and use a+modified version of this License if you rename the license and remove+any references to the name of the license steward (except to note that+such modified license differs from this License).++10.4. Distributing Source Code Form that is Incompatible With Secondary+Licenses++If You choose to distribute Source Code Form that is Incompatible With+Secondary Licenses under the terms of this version of the License, the+notice described in Exhibit B of this License must be attached.++Exhibit A - Source Code Form License Notice+-------------------------------------------++ This Source Code Form is subject to the terms of the Mozilla Public+ License, v. 2.0. If a copy of the MPL was not distributed with this+ file, You can obtain one at http://mozilla.org/MPL/2.0/.++If it is not possible or desirable to put the notice in a particular+file, then You may include the notice in a location (such as a LICENSE+file in a relevant directory) where a recipient would be likely to look+for such a notice.++You may add additional accurate notices of copyright ownership.++Exhibit B - "Incompatible With Secondary Licenses" Notice+---------------------------------------------------------++ This Source Code Form is "Incompatible With Secondary Licenses", as+ defined by the Mozilla Public License, v. 2.0.
+ README.md view
@@ -0,0 +1,26 @@+# Amazon CloudFormation SDK++> _Warning:_ This is an experimental preview release which is still under heavy development and not intended for public consumption, _caveat emptor_!++* [description](#description)+* [Contribute](#contribute)+* [Licence](#licence)++## Description++AWS CloudFormation gives developers and systems administrators an easy way to create and manage a collection of related AWS resources, provisioning and updating them in an orderly and predictable fashion. You can use AWS CloudFormation’s sample templates or create your own templates to describe the AWS resources, and any associated dependencies or runtime parameters, required to run your application. You don’t need to figure out the order for provisioning AWS services or the subtleties of making those dependencies work. CloudFormation takes care of this for you. After the AWS resources are deployed, you can modify and update them in a controlled and predictable way, in effect applying version control to your AWS infrastructure the same way you do with your software.++Documentation is available via [Hackage](http://hackage.haskell.org/package/amazonka-cloudformation)+and [AWS API Reference](http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/Welcome.html).+++## Contribute++For any problems, comments, or feedback please create an issue [here on GitHub](https://github.com/brendanhay/amazonka/issues).++> _Note:_ this library is an auto-generated Haskell package. Please see `amazonka-gen` for more information.+++## Licence++`amazonka-cloudformation` is released under the [Mozilla Public License Version 2.0](http://www.mozilla.org/MPL/).
+ Setup.hs view
@@ -0,0 +1,2 @@+import Distribution.Simple+main = defaultMain
+ amazonka-cloudformation.cabal view
@@ -0,0 +1,69 @@+name: amazonka-cloudformation+version: 0.0.0+synopsis: Amazon CloudFormation SDK.+homepage: https://github.com/brendanhay/amazonka+license: OtherLicense+license-file: LICENSE+author: Brendan Hay+maintainer: Brendan Hay <brendan.g.hay@gmail.com>+copyright: Copyright (c) 2013-2014 Brendan Hay+category: Network, AWS, Cloud+build-type: Simple+extra-source-files: README.md+cabal-version: >= 1.10++description:+ AWS CloudFormation gives developers and systems administrators an easy+ way to create and manage a collection of related AWS resources,+ provisioning and updating them in an orderly and predictable fashion.+ You can use AWS CloudFormation’s sample templates or create your own+ templates to describe the AWS resources, and any associated+ dependencies or runtime parameters, required to run your application.+ You don’t need to figure out the order for provisioning AWS services or+ the subtleties of making those dependencies work. CloudFormation takes+ care of this for you. After the AWS resources are deployed, you can+ modify and update them in a controlled and predictable way, in effect+ applying version control to your AWS infrastructure the same way you do+ with your software.+ .+ /See:/ <http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/Welcome.html AWS API Reference>+ .+ /Warning:/ This is an experimental preview release which is still under+ heavy development and not intended for public consumption, caveat emptor!++source-repository head+ type: git+ location: git://github.com/brendanhay/amazonka.git++library+ default-language: Haskell2010+ hs-source-dirs: src gen++ ghc-options: -Wall++ exposed-modules:+ Network.AWS.CloudFormation+ , Network.AWS.CloudFormation.CancelUpdateStack+ , Network.AWS.CloudFormation.CreateStack+ , Network.AWS.CloudFormation.DeleteStack+ , Network.AWS.CloudFormation.DescribeStackEvents+ , Network.AWS.CloudFormation.DescribeStackResource+ , Network.AWS.CloudFormation.DescribeStackResources+ , Network.AWS.CloudFormation.DescribeStacks+ , Network.AWS.CloudFormation.EstimateTemplateCost+ , Network.AWS.CloudFormation.GetStackPolicy+ , Network.AWS.CloudFormation.GetTemplate+ , Network.AWS.CloudFormation.GetTemplateSummary+ , Network.AWS.CloudFormation.ListStackResources+ , Network.AWS.CloudFormation.ListStacks+ , Network.AWS.CloudFormation.SetStackPolicy+ , Network.AWS.CloudFormation.SignalResource+ , Network.AWS.CloudFormation.Types+ , Network.AWS.CloudFormation.UpdateStack+ , Network.AWS.CloudFormation.ValidateTemplate++ other-modules:++ build-depends:+ amazonka-core+ , base >= 4.7 && < 5
+ gen/Network/AWS/CloudFormation.hs view
@@ -0,0 +1,60 @@+-- Module : Network.AWS.CloudFormation+-- Copyright : (c) 2013-2014 Brendan Hay <brendan.g.hay@gmail.com>+-- License : This Source Code Form is subject to the terms of+-- the Mozilla Public License, v. 2.0.+-- A copy of the MPL can be found in the LICENSE file or+-- you can obtain it at http://mozilla.org/MPL/2.0/.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : experimental+-- Portability : non-portable (GHC extensions)++-- | AWS CloudFormation gives developers and systems administrators an easy way+-- to create and manage a collection of related AWS resources, provisioning+-- and updating them in an orderly and predictable fashion. You can use AWS+-- CloudFormation’s sample templates or create your own templates to describe+-- the AWS resources, and any associated dependencies or runtime parameters,+-- required to run your application. You don’t need to figure out the order+-- for provisioning AWS services or the subtleties of making those+-- dependencies work. CloudFormation takes care of this for you. After the AWS+-- resources are deployed, you can modify and update them in a controlled and+-- predictable way, in effect applying version control to your AWS+-- infrastructure the same way you do with your software.+module Network.AWS.CloudFormation+ ( module Network.AWS.CloudFormation.CancelUpdateStack+ , module Network.AWS.CloudFormation.CreateStack+ , module Network.AWS.CloudFormation.DeleteStack+ , module Network.AWS.CloudFormation.DescribeStackEvents+ , module Network.AWS.CloudFormation.DescribeStackResource+ , module Network.AWS.CloudFormation.DescribeStackResources+ , module Network.AWS.CloudFormation.DescribeStacks+ , module Network.AWS.CloudFormation.EstimateTemplateCost+ , module Network.AWS.CloudFormation.GetStackPolicy+ , module Network.AWS.CloudFormation.GetTemplate+ , module Network.AWS.CloudFormation.GetTemplateSummary+ , module Network.AWS.CloudFormation.ListStackResources+ , module Network.AWS.CloudFormation.ListStacks+ , module Network.AWS.CloudFormation.SetStackPolicy+ , module Network.AWS.CloudFormation.SignalResource+ , module Network.AWS.CloudFormation.Types+ , module Network.AWS.CloudFormation.UpdateStack+ , module Network.AWS.CloudFormation.ValidateTemplate+ ) where++import Network.AWS.CloudFormation.CancelUpdateStack+import Network.AWS.CloudFormation.CreateStack+import Network.AWS.CloudFormation.DeleteStack+import Network.AWS.CloudFormation.DescribeStackEvents+import Network.AWS.CloudFormation.DescribeStackResource+import Network.AWS.CloudFormation.DescribeStackResources+import Network.AWS.CloudFormation.DescribeStacks+import Network.AWS.CloudFormation.EstimateTemplateCost+import Network.AWS.CloudFormation.GetStackPolicy+import Network.AWS.CloudFormation.GetTemplate+import Network.AWS.CloudFormation.GetTemplateSummary+import Network.AWS.CloudFormation.ListStackResources+import Network.AWS.CloudFormation.ListStacks+import Network.AWS.CloudFormation.SetStackPolicy+import Network.AWS.CloudFormation.SignalResource+import Network.AWS.CloudFormation.Types+import Network.AWS.CloudFormation.UpdateStack+import Network.AWS.CloudFormation.ValidateTemplate
+ gen/Network/AWS/CloudFormation/CancelUpdateStack.hs view
@@ -0,0 +1,91 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE FlexibleInstances #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE TypeFamilies #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Module : Network.AWS.CloudFormation.CancelUpdateStack+-- Copyright : (c) 2013-2014 Brendan Hay <brendan.g.hay@gmail.com>+-- License : This Source Code Form is subject to the terms of+-- the Mozilla Public License, v. 2.0.+-- A copy of the MPL can be found in the LICENSE file or+-- you can obtain it at http://mozilla.org/MPL/2.0/.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : experimental+-- Portability : non-portable (GHC extensions)++-- | Cancels an update on the specified stack. If the call completes+-- successfully, the stack will roll back the update and revert to the+-- previous stack configuration. Only stacks that are in the+-- UPDATE_IN_PROGRESS state can be canceled.+--+-- <http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_CancelUpdateStack.html>+module Network.AWS.CloudFormation.CancelUpdateStack+ (+ -- * Request+ CancelUpdateStack+ -- ** Request constructor+ , cancelUpdateStack+ -- ** Request lenses+ , cusStackName++ -- * Response+ , CancelUpdateStackResponse+ -- ** Response constructor+ , cancelUpdateStackResponse+ ) where++import Network.AWS.Prelude+import Network.AWS.Request.Query+import Network.AWS.CloudFormation.Types+import qualified GHC.Exts++newtype CancelUpdateStack = CancelUpdateStack+ { _cusStackName :: Text+ } deriving (Eq, Ord, Show, Monoid, IsString)++-- | 'CancelUpdateStack' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'cusStackName' @::@ 'Text'+--+cancelUpdateStack :: Text -- ^ 'cusStackName'+ -> CancelUpdateStack+cancelUpdateStack p1 = CancelUpdateStack+ { _cusStackName = p1+ }++-- | The name or the unique identifier associated with the stack.+cusStackName :: Lens' CancelUpdateStack Text+cusStackName = lens _cusStackName (\s a -> s { _cusStackName = a })++data CancelUpdateStackResponse = CancelUpdateStackResponse+ deriving (Eq, Ord, Show, Generic)++-- | 'CancelUpdateStackResponse' constructor.+cancelUpdateStackResponse :: CancelUpdateStackResponse+cancelUpdateStackResponse = CancelUpdateStackResponse++instance ToPath CancelUpdateStack where+ toPath = const "/"++instance ToQuery CancelUpdateStack where+ toQuery CancelUpdateStack{..} = mconcat+ [ "StackName" =? _cusStackName+ ]++instance ToHeaders CancelUpdateStack++instance AWSRequest CancelUpdateStack where+ type Sv CancelUpdateStack = CloudFormation+ type Rs CancelUpdateStack = CancelUpdateStackResponse++ request = post "CancelUpdateStack"+ response = nullResponse CancelUpdateStackResponse
+ gen/Network/AWS/CloudFormation/CreateStack.hs view
@@ -0,0 +1,264 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE FlexibleInstances #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE TypeFamilies #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Module : Network.AWS.CloudFormation.CreateStack+-- Copyright : (c) 2013-2014 Brendan Hay <brendan.g.hay@gmail.com>+-- License : This Source Code Form is subject to the terms of+-- the Mozilla Public License, v. 2.0.+-- A copy of the MPL can be found in the LICENSE file or+-- you can obtain it at http://mozilla.org/MPL/2.0/.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : experimental+-- Portability : non-portable (GHC extensions)++-- | Creates a stack as specified in the template. After the call completes+-- successfully, the stack creation starts. You can check the status of the+-- stack via the DescribeStacks API.+--+-- <http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_CreateStack.html>+module Network.AWS.CloudFormation.CreateStack+ (+ -- * Request+ CreateStack+ -- ** Request constructor+ , createStack+ -- ** Request lenses+ , csCapabilities+ , csDisableRollback+ , csNotificationARNs+ , csOnFailure+ , csParameters+ , csStackName+ , csStackPolicyBody+ , csStackPolicyURL+ , csTags+ , csTemplateBody+ , csTemplateURL+ , csTimeoutInMinutes++ -- * Response+ , CreateStackResponse+ -- ** Response constructor+ , createStackResponse+ -- ** Response lenses+ , csrStackId+ ) where++import Network.AWS.Prelude+import Network.AWS.Request.Query+import Network.AWS.CloudFormation.Types+import qualified GHC.Exts++data CreateStack = CreateStack+ { _csCapabilities :: List "Capabilities" Text+ , _csDisableRollback :: Maybe Bool+ , _csNotificationARNs :: List "NotificationARNs" Text+ , _csOnFailure :: Maybe Text+ , _csParameters :: List "Parameters" Parameter+ , _csStackName :: Text+ , _csStackPolicyBody :: Maybe Text+ , _csStackPolicyURL :: Maybe Text+ , _csTags :: List "Tags" Tag+ , _csTemplateBody :: Maybe Text+ , _csTemplateURL :: Maybe Text+ , _csTimeoutInMinutes :: Maybe Nat+ } deriving (Eq, Show)++-- | 'CreateStack' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'csCapabilities' @::@ ['Text']+--+-- * 'csDisableRollback' @::@ 'Maybe' 'Bool'+--+-- * 'csNotificationARNs' @::@ ['Text']+--+-- * 'csOnFailure' @::@ 'Maybe' 'Text'+--+-- * 'csParameters' @::@ ['Parameter']+--+-- * 'csStackName' @::@ 'Text'+--+-- * 'csStackPolicyBody' @::@ 'Maybe' 'Text'+--+-- * 'csStackPolicyURL' @::@ 'Maybe' 'Text'+--+-- * 'csTags' @::@ ['Tag']+--+-- * 'csTemplateBody' @::@ 'Maybe' 'Text'+--+-- * 'csTemplateURL' @::@ 'Maybe' 'Text'+--+-- * 'csTimeoutInMinutes' @::@ 'Maybe' 'Natural'+--+createStack :: Text -- ^ 'csStackName'+ -> CreateStack+createStack p1 = CreateStack+ { _csStackName = p1+ , _csTemplateBody = Nothing+ , _csTemplateURL = Nothing+ , _csParameters = mempty+ , _csDisableRollback = Nothing+ , _csTimeoutInMinutes = Nothing+ , _csNotificationARNs = mempty+ , _csCapabilities = mempty+ , _csOnFailure = Nothing+ , _csStackPolicyBody = Nothing+ , _csStackPolicyURL = Nothing+ , _csTags = mempty+ }++-- | A list of capabilities that you must specify before AWS CloudFormation+-- can create or update certain stacks. Some stack templates might include+-- resources that can affect permissions in your AWS account. For those+-- stacks, you must explicitly acknowledge their capabilities by specifying+-- this parameter. Currently, the only valid value is CAPABILITY_IAM, which+-- is required for the following resources: AWS::CloudFormation::Stack,+-- AWS::IAM::AccessKey, AWS::IAM::Group, AWS::IAM::InstanceProfile,+-- AWS::IAM::Policy, AWS::IAM::Role, AWS::IAM::User, and+-- AWS::IAM::UserToGroupAddition. If your stack template contains these+-- resources, we recommend that you review any permissions associated with+-- them. If you don't specify this parameter, this action returns an+-- InsufficientCapabilities error.+csCapabilities :: Lens' CreateStack [Text]+csCapabilities = lens _csCapabilities (\s a -> s { _csCapabilities = a }) . _List++-- | Set to true to disable rollback of the stack if stack creation failed.+-- You can specify either DisableRollback or OnFailure, but not both.+-- Default: false.+csDisableRollback :: Lens' CreateStack (Maybe Bool)+csDisableRollback =+ lens _csDisableRollback (\s a -> s { _csDisableRollback = a })++-- | The Simple Notification Service (SNS) topic ARNs to publish stack related+-- events. You can find your SNS topic ARNs using the SNS console or your+-- Command Line Interface (CLI).+csNotificationARNs :: Lens' CreateStack [Text]+csNotificationARNs =+ lens _csNotificationARNs (\s a -> s { _csNotificationARNs = a })+ . _List++-- | Determines what action will be taken if stack creation fails. This must+-- be one of: DO_NOTHING, ROLLBACK, or DELETE. You can specify either+-- OnFailure or DisableRollback, but not both. Default: ROLLBACK.+csOnFailure :: Lens' CreateStack (Maybe Text)+csOnFailure = lens _csOnFailure (\s a -> s { _csOnFailure = a })++-- | A list of Parameter structures that specify input parameters for the+-- stack.+csParameters :: Lens' CreateStack [Parameter]+csParameters = lens _csParameters (\s a -> s { _csParameters = a }) . _List++-- | The name associated with the stack. The name must be unique within your+-- AWS account. Must contain only alphanumeric characters (case sensitive)+-- and start with an alpha character. Maximum length of the name is 255+-- characters.+csStackName :: Lens' CreateStack Text+csStackName = lens _csStackName (\s a -> s { _csStackName = a })++-- | Structure containing the stack policy body. For more information, go to+-- Prevent Updates to Stack Resources in the AWS CloudFormation User Guide.+-- You can specify either the StackPolicyBody or the StackPolicyURL+-- parameter, but not both.+csStackPolicyBody :: Lens' CreateStack (Maybe Text)+csStackPolicyBody =+ lens _csStackPolicyBody (\s a -> s { _csStackPolicyBody = a })++-- | Location of a file containing the stack policy. The URL must point to a+-- policy (max size: 16KB) located in an S3 bucket in the same region as the+-- stack. You can specify either the StackPolicyBody or the StackPolicyURL+-- parameter, but not both.+csStackPolicyURL :: Lens' CreateStack (Maybe Text)+csStackPolicyURL = lens _csStackPolicyURL (\s a -> s { _csStackPolicyURL = a })++-- | A set of user-defined Tags to associate with this stack, represented by+-- key/value pairs. Tags defined for the stack are propagated to EC2+-- resources that are created as part of the stack. A maximum number of 10+-- tags can be specified.+csTags :: Lens' CreateStack [Tag]+csTags = lens _csTags (\s a -> s { _csTags = a }) . _List++-- | Structure containing the template body with a minimum length of 1 byte+-- and a maximum length of 51,200 bytes. For more information, go to+-- Template Anatomy in the AWS CloudFormation User Guide. Conditional: You+-- must specify either the TemplateBody or the TemplateURL parameter, but+-- not both.+csTemplateBody :: Lens' CreateStack (Maybe Text)+csTemplateBody = lens _csTemplateBody (\s a -> s { _csTemplateBody = a })++-- | Location of file containing the template body. The URL must point to a+-- template (max size: 307,200 bytes) located in an S3 bucket in the same+-- region as the stack. For more information, go to the Template Anatomy in+-- the AWS CloudFormation User Guide. Conditional: You must specify either+-- the TemplateBody or the TemplateURL parameter, but not both.+csTemplateURL :: Lens' CreateStack (Maybe Text)+csTemplateURL = lens _csTemplateURL (\s a -> s { _csTemplateURL = a })++-- | The amount of time that can pass before the stack status becomes+-- CREATE_FAILED; if DisableRollback is not set or is set to false, the+-- stack will be rolled back.+csTimeoutInMinutes :: Lens' CreateStack (Maybe Natural)+csTimeoutInMinutes =+ lens _csTimeoutInMinutes (\s a -> s { _csTimeoutInMinutes = a })+ . mapping _Nat++newtype CreateStackResponse = CreateStackResponse+ { _csrStackId :: Maybe Text+ } deriving (Eq, Ord, Show, Monoid)++-- | 'CreateStackResponse' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'csrStackId' @::@ 'Maybe' 'Text'+--+createStackResponse :: CreateStackResponse+createStackResponse = CreateStackResponse+ { _csrStackId = Nothing+ }++-- | Unique identifier of the stack.+csrStackId :: Lens' CreateStackResponse (Maybe Text)+csrStackId = lens _csrStackId (\s a -> s { _csrStackId = a })++instance ToPath CreateStack where+ toPath = const "/"++instance ToQuery CreateStack where+ toQuery CreateStack{..} = mconcat+ [ "Capabilities" =? _csCapabilities+ , "DisableRollback" =? _csDisableRollback+ , "NotificationARNs" =? _csNotificationARNs+ , "OnFailure" =? _csOnFailure+ , "Parameters" =? _csParameters+ , "StackName" =? _csStackName+ , "StackPolicyBody" =? _csStackPolicyBody+ , "StackPolicyURL" =? _csStackPolicyURL+ , "Tags" =? _csTags+ , "TemplateBody" =? _csTemplateBody+ , "TemplateURL" =? _csTemplateURL+ , "TimeoutInMinutes" =? _csTimeoutInMinutes+ ]++instance ToHeaders CreateStack++instance AWSRequest CreateStack where+ type Sv CreateStack = CloudFormation+ type Rs CreateStack = CreateStackResponse++ request = post "CreateStack"+ response = xmlResponse++instance FromXML CreateStackResponse where+ parseXML = withElement "CreateStackResult" $ \x -> CreateStackResponse+ <$> x .@? "StackId"
+ gen/Network/AWS/CloudFormation/DeleteStack.hs view
@@ -0,0 +1,90 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE FlexibleInstances #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE TypeFamilies #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Module : Network.AWS.CloudFormation.DeleteStack+-- Copyright : (c) 2013-2014 Brendan Hay <brendan.g.hay@gmail.com>+-- License : This Source Code Form is subject to the terms of+-- the Mozilla Public License, v. 2.0.+-- A copy of the MPL can be found in the LICENSE file or+-- you can obtain it at http://mozilla.org/MPL/2.0/.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : experimental+-- Portability : non-portable (GHC extensions)++-- | Deletes a specified stack. Once the call completes successfully, stack+-- deletion starts. Deleted stacks do not show up in the DescribeStacks API if+-- the deletion has been completed successfully.+--+-- <http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_DeleteStack.html>+module Network.AWS.CloudFormation.DeleteStack+ (+ -- * Request+ DeleteStack+ -- ** Request constructor+ , deleteStack+ -- ** Request lenses+ , dsStackName++ -- * Response+ , DeleteStackResponse+ -- ** Response constructor+ , deleteStackResponse+ ) where++import Network.AWS.Prelude+import Network.AWS.Request.Query+import Network.AWS.CloudFormation.Types+import qualified GHC.Exts++newtype DeleteStack = DeleteStack+ { _dsStackName :: Text+ } deriving (Eq, Ord, Show, Monoid, IsString)++-- | 'DeleteStack' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'dsStackName' @::@ 'Text'+--+deleteStack :: Text -- ^ 'dsStackName'+ -> DeleteStack+deleteStack p1 = DeleteStack+ { _dsStackName = p1+ }++-- | The name or the unique identifier associated with the stack.+dsStackName :: Lens' DeleteStack Text+dsStackName = lens _dsStackName (\s a -> s { _dsStackName = a })++data DeleteStackResponse = DeleteStackResponse+ deriving (Eq, Ord, Show, Generic)++-- | 'DeleteStackResponse' constructor.+deleteStackResponse :: DeleteStackResponse+deleteStackResponse = DeleteStackResponse++instance ToPath DeleteStack where+ toPath = const "/"++instance ToQuery DeleteStack where+ toQuery DeleteStack{..} = mconcat+ [ "StackName" =? _dsStackName+ ]++instance ToHeaders DeleteStack++instance AWSRequest DeleteStack where+ type Sv DeleteStack = CloudFormation+ type Rs DeleteStack = DeleteStackResponse++ request = post "DeleteStack"+ response = nullResponse DeleteStackResponse
+ gen/Network/AWS/CloudFormation/DescribeStackEvents.hs view
@@ -0,0 +1,140 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE FlexibleInstances #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE TypeFamilies #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Module : Network.AWS.CloudFormation.DescribeStackEvents+-- Copyright : (c) 2013-2014 Brendan Hay <brendan.g.hay@gmail.com>+-- License : This Source Code Form is subject to the terms of+-- the Mozilla Public License, v. 2.0.+-- A copy of the MPL can be found in the LICENSE file or+-- you can obtain it at http://mozilla.org/MPL/2.0/.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : experimental+-- Portability : non-portable (GHC extensions)++-- | Returns all stack related events for a specified stack. For more+-- information about a stack's event history, go to Stacks in the AWS+-- CloudFormation User Guide. You can list events for stacks that have failed+-- to create or have been deleted by specifying the unique stack identifier+-- (stack ID).+--+-- <http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_DescribeStackEvents.html>+module Network.AWS.CloudFormation.DescribeStackEvents+ (+ -- * Request+ DescribeStackEvents+ -- ** Request constructor+ , describeStackEvents+ -- ** Request lenses+ , dseNextToken+ , dseStackName++ -- * Response+ , DescribeStackEventsResponse+ -- ** Response constructor+ , describeStackEventsResponse+ -- ** Response lenses+ , dserNextToken+ , dserStackEvents+ ) where++import Network.AWS.Prelude+import Network.AWS.Request.Query+import Network.AWS.CloudFormation.Types+import qualified GHC.Exts++data DescribeStackEvents = DescribeStackEvents+ { _dseNextToken :: Maybe Text+ , _dseStackName :: Maybe Text+ } deriving (Eq, Ord, Show)++-- | 'DescribeStackEvents' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'dseNextToken' @::@ 'Maybe' 'Text'+--+-- * 'dseStackName' @::@ 'Maybe' 'Text'+--+describeStackEvents :: DescribeStackEvents+describeStackEvents = DescribeStackEvents+ { _dseStackName = Nothing+ , _dseNextToken = Nothing+ }++-- | String that identifies the start of the next list of events, if there is+-- one. Default: There is no default value.+dseNextToken :: Lens' DescribeStackEvents (Maybe Text)+dseNextToken = lens _dseNextToken (\s a -> s { _dseNextToken = a })++-- | The name or the unique identifier associated with the stack, which are+-- not always interchangeable: Running stacks: You can specify either the+-- stack's name or its unique stack ID. Deleted stacks: You must specify the+-- unique stack ID. Default: There is no default value.+dseStackName :: Lens' DescribeStackEvents (Maybe Text)+dseStackName = lens _dseStackName (\s a -> s { _dseStackName = a })++data DescribeStackEventsResponse = DescribeStackEventsResponse+ { _dserNextToken :: Maybe Text+ , _dserStackEvents :: List "StackEvents" StackEvent+ } deriving (Eq, Show)++-- | 'DescribeStackEventsResponse' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'dserNextToken' @::@ 'Maybe' 'Text'+--+-- * 'dserStackEvents' @::@ ['StackEvent']+--+describeStackEventsResponse :: DescribeStackEventsResponse+describeStackEventsResponse = DescribeStackEventsResponse+ { _dserStackEvents = mempty+ , _dserNextToken = Nothing+ }++-- | String that identifies the start of the next list of events, if there is+-- one.+dserNextToken :: Lens' DescribeStackEventsResponse (Maybe Text)+dserNextToken = lens _dserNextToken (\s a -> s { _dserNextToken = a })++-- | A list of StackEvents structures.+dserStackEvents :: Lens' DescribeStackEventsResponse [StackEvent]+dserStackEvents = lens _dserStackEvents (\s a -> s { _dserStackEvents = a }) . _List++instance ToPath DescribeStackEvents where+ toPath = const "/"++instance ToQuery DescribeStackEvents where+ toQuery DescribeStackEvents{..} = mconcat+ [ "NextToken" =? _dseNextToken+ , "StackName" =? _dseStackName+ ]++instance ToHeaders DescribeStackEvents++instance AWSRequest DescribeStackEvents where+ type Sv DescribeStackEvents = CloudFormation+ type Rs DescribeStackEvents = DescribeStackEventsResponse++ request = post "DescribeStackEvents"+ response = xmlResponse++instance FromXML DescribeStackEventsResponse where+ parseXML = withElement "DescribeStackEventsResult" $ \x -> DescribeStackEventsResponse+ <$> x .@? "NextToken"+ <*> x .@ "StackEvents"++instance AWSPager DescribeStackEvents where+ page rq rs+ | stop (rq ^. dseNextToken) = Nothing+ | otherwise = (\x -> rq & dseNextToken ?~ x)+ <$> (rs ^. dserNextToken)
+ gen/Network/AWS/CloudFormation/DescribeStackResource.hs view
@@ -0,0 +1,126 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE FlexibleInstances #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE TypeFamilies #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Module : Network.AWS.CloudFormation.DescribeStackResource+-- Copyright : (c) 2013-2014 Brendan Hay <brendan.g.hay@gmail.com>+-- License : This Source Code Form is subject to the terms of+-- the Mozilla Public License, v. 2.0.+-- A copy of the MPL can be found in the LICENSE file or+-- you can obtain it at http://mozilla.org/MPL/2.0/.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : experimental+-- Portability : non-portable (GHC extensions)++-- | Returns a description of the specified resource in the specified stack. For+-- deleted stacks, DescribeStackResource returns resource information for up+-- to 90 days after the stack has been deleted.+--+-- <http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_DescribeStackResource.html>+module Network.AWS.CloudFormation.DescribeStackResource+ (+ -- * Request+ DescribeStackResource+ -- ** Request constructor+ , describeStackResource+ -- ** Request lenses+ , dsr1LogicalResourceId+ , dsr1StackName++ -- * Response+ , DescribeStackResourceResponse+ -- ** Response constructor+ , describeStackResourceResponse+ -- ** Response lenses+ , dsrrStackResourceDetail+ ) where++import Network.AWS.Prelude+import Network.AWS.Request.Query+import Network.AWS.CloudFormation.Types+import qualified GHC.Exts++data DescribeStackResource = DescribeStackResource+ { _dsr1LogicalResourceId :: Text+ , _dsr1StackName :: Text+ } deriving (Eq, Ord, Show)++-- | 'DescribeStackResource' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'dsr1LogicalResourceId' @::@ 'Text'+--+-- * 'dsr1StackName' @::@ 'Text'+--+describeStackResource :: Text -- ^ 'dsr1StackName'+ -> Text -- ^ 'dsr1LogicalResourceId'+ -> DescribeStackResource+describeStackResource p1 p2 = DescribeStackResource+ { _dsr1StackName = p1+ , _dsr1LogicalResourceId = p2+ }++-- | The logical name of the resource as specified in the template. Default:+-- There is no default value.+dsr1LogicalResourceId :: Lens' DescribeStackResource Text+dsr1LogicalResourceId =+ lens _dsr1LogicalResourceId (\s a -> s { _dsr1LogicalResourceId = a })++-- | The name or the unique identifier associated with the stack, which are+-- not always interchangeable: Running stacks: You can specify either the+-- stack's name or its unique stack ID. Deleted stacks: You must specify the+-- unique stack ID. Default: There is no default value.+dsr1StackName :: Lens' DescribeStackResource Text+dsr1StackName = lens _dsr1StackName (\s a -> s { _dsr1StackName = a })++newtype DescribeStackResourceResponse = DescribeStackResourceResponse+ { _dsrrStackResourceDetail :: Maybe StackResourceDetail+ } deriving (Eq, Show)++-- | 'DescribeStackResourceResponse' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'dsrrStackResourceDetail' @::@ 'Maybe' 'StackResourceDetail'+--+describeStackResourceResponse :: DescribeStackResourceResponse+describeStackResourceResponse = DescribeStackResourceResponse+ { _dsrrStackResourceDetail = Nothing+ }++-- | A StackResourceDetail structure containing the description of the+-- specified resource in the specified stack.+dsrrStackResourceDetail :: Lens' DescribeStackResourceResponse (Maybe StackResourceDetail)+dsrrStackResourceDetail =+ lens _dsrrStackResourceDetail (\s a -> s { _dsrrStackResourceDetail = a })++instance ToPath DescribeStackResource where+ toPath = const "/"++instance ToQuery DescribeStackResource where+ toQuery DescribeStackResource{..} = mconcat+ [ "LogicalResourceId" =? _dsr1LogicalResourceId+ , "StackName" =? _dsr1StackName+ ]++instance ToHeaders DescribeStackResource++instance AWSRequest DescribeStackResource where+ type Sv DescribeStackResource = CloudFormation+ type Rs DescribeStackResource = DescribeStackResourceResponse++ request = post "DescribeStackResource"+ response = xmlResponse++instance FromXML DescribeStackResourceResponse where+ parseXML = withElement "DescribeStackResourceResult" $ \x -> DescribeStackResourceResponse+ <$> x .@? "StackResourceDetail"
+ gen/Network/AWS/CloudFormation/DescribeStackResources.hs view
@@ -0,0 +1,160 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE FlexibleInstances #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE TypeFamilies #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Module : Network.AWS.CloudFormation.DescribeStackResources+-- Copyright : (c) 2013-2014 Brendan Hay <brendan.g.hay@gmail.com>+-- License : This Source Code Form is subject to the terms of+-- the Mozilla Public License, v. 2.0.+-- A copy of the MPL can be found in the LICENSE file or+-- you can obtain it at http://mozilla.org/MPL/2.0/.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : experimental+-- Portability : non-portable (GHC extensions)++-- | Returns AWS resource descriptions for running and deleted stacks. If+-- StackName is specified, all the associated resources that are part of the+-- stack are returned. If PhysicalResourceId is specified, the associated+-- resources of the stack that the resource belongs to are returned. Only the+-- first 100 resources will be returned. If your stack has more resources than+-- this, you should use ListStackResources instead. For deleted stacks,+-- DescribeStackResources returns resource information for up to 90 days after+-- the stack has been deleted. You must specify either StackName or+-- PhysicalResourceId, but not both. In addition, you can specify+-- LogicalResourceId to filter the returned result. For more information about+-- resources, the LogicalResourceId and PhysicalResourceId, go to the AWS+-- CloudFormation User Guide. A ValidationError is returned if you specify+-- both StackName and PhysicalResourceId in the same request.+--+-- <http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_DescribeStackResources.html>+module Network.AWS.CloudFormation.DescribeStackResources+ (+ -- * Request+ DescribeStackResources+ -- ** Request constructor+ , describeStackResources+ -- ** Request lenses+ , dsrLogicalResourceId+ , dsrPhysicalResourceId+ , dsrStackName++ -- * Response+ , DescribeStackResourcesResponse+ -- ** Response constructor+ , describeStackResourcesResponse+ -- ** Response lenses+ , dsrrStackResources+ ) where++import Network.AWS.Prelude+import Network.AWS.Request.Query+import Network.AWS.CloudFormation.Types+import qualified GHC.Exts++data DescribeStackResources = DescribeStackResources+ { _dsrLogicalResourceId :: Maybe Text+ , _dsrPhysicalResourceId :: Maybe Text+ , _dsrStackName :: Maybe Text+ } deriving (Eq, Ord, Show)++-- | 'DescribeStackResources' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'dsrLogicalResourceId' @::@ 'Maybe' 'Text'+--+-- * 'dsrPhysicalResourceId' @::@ 'Maybe' 'Text'+--+-- * 'dsrStackName' @::@ 'Maybe' 'Text'+--+describeStackResources :: DescribeStackResources+describeStackResources = DescribeStackResources+ { _dsrStackName = Nothing+ , _dsrLogicalResourceId = Nothing+ , _dsrPhysicalResourceId = Nothing+ }++-- | The logical name of the resource as specified in the template. Default:+-- There is no default value.+dsrLogicalResourceId :: Lens' DescribeStackResources (Maybe Text)+dsrLogicalResourceId =+ lens _dsrLogicalResourceId (\s a -> s { _dsrLogicalResourceId = a })++-- | The name or unique identifier that corresponds to a physical instance ID+-- of a resource supported by AWS CloudFormation. For example, for an Amazon+-- Elastic Compute Cloud (EC2) instance, PhysicalResourceId corresponds to+-- the InstanceId. You can pass the EC2 InstanceId to DescribeStackResources+-- to find which stack the instance belongs to and what other resources are+-- part of the stack. Required: Conditional. If you do not specify+-- PhysicalResourceId, you must specify StackName. Default: There is no+-- default value.+dsrPhysicalResourceId :: Lens' DescribeStackResources (Maybe Text)+dsrPhysicalResourceId =+ lens _dsrPhysicalResourceId (\s a -> s { _dsrPhysicalResourceId = a })++-- | The name or the unique identifier associated with the stack, which are+-- not always interchangeable: Running stacks: You can specify either the+-- stack's name or its unique stack ID. Deleted stacks: You must specify the+-- unique stack ID. Default: There is no default value. Required:+-- Conditional. If you do not specify StackName, you must specify+-- PhysicalResourceId.+dsrStackName :: Lens' DescribeStackResources (Maybe Text)+dsrStackName = lens _dsrStackName (\s a -> s { _dsrStackName = a })++newtype DescribeStackResourcesResponse = DescribeStackResourcesResponse+ { _dsrrStackResources :: List "StackResources" StackResource+ } deriving (Eq, Show, Monoid, Semigroup)++instance GHC.Exts.IsList DescribeStackResourcesResponse where+ type Item DescribeStackResourcesResponse = StackResource++ fromList = DescribeStackResourcesResponse . GHC.Exts.fromList+ toList = GHC.Exts.toList . _dsrrStackResources++-- | 'DescribeStackResourcesResponse' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'dsrrStackResources' @::@ ['StackResource']+--+describeStackResourcesResponse :: DescribeStackResourcesResponse+describeStackResourcesResponse = DescribeStackResourcesResponse+ { _dsrrStackResources = mempty+ }++-- | A list of StackResource structures.+dsrrStackResources :: Lens' DescribeStackResourcesResponse [StackResource]+dsrrStackResources =+ lens _dsrrStackResources (\s a -> s { _dsrrStackResources = a })+ . _List++instance ToPath DescribeStackResources where+ toPath = const "/"++instance ToQuery DescribeStackResources where+ toQuery DescribeStackResources{..} = mconcat+ [ "LogicalResourceId" =? _dsrLogicalResourceId+ , "PhysicalResourceId" =? _dsrPhysicalResourceId+ , "StackName" =? _dsrStackName+ ]++instance ToHeaders DescribeStackResources++instance AWSRequest DescribeStackResources where+ type Sv DescribeStackResources = CloudFormation+ type Rs DescribeStackResources = DescribeStackResourcesResponse++ request = post "DescribeStackResources"+ response = xmlResponse++instance FromXML DescribeStackResourcesResponse where+ parseXML = withElement "DescribeStackResourcesResult" $ \x -> DescribeStackResourcesResponse+ <$> x .@ "StackResources"
+ gen/Network/AWS/CloudFormation/DescribeStacks.hs view
@@ -0,0 +1,137 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE FlexibleInstances #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE TypeFamilies #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Module : Network.AWS.CloudFormation.DescribeStacks+-- Copyright : (c) 2013-2014 Brendan Hay <brendan.g.hay@gmail.com>+-- License : This Source Code Form is subject to the terms of+-- the Mozilla Public License, v. 2.0.+-- A copy of the MPL can be found in the LICENSE file or+-- you can obtain it at http://mozilla.org/MPL/2.0/.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : experimental+-- Portability : non-portable (GHC extensions)++-- | Returns the description for the specified stack; if no stack name was+-- specified, then it returns the description for all the stacks created.+--+-- <http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_DescribeStacks.html>+module Network.AWS.CloudFormation.DescribeStacks+ (+ -- * Request+ DescribeStacks+ -- ** Request constructor+ , describeStacks+ -- ** Request lenses+ , ds1NextToken+ , ds1StackName++ -- * Response+ , DescribeStacksResponse+ -- ** Response constructor+ , describeStacksResponse+ -- ** Response lenses+ , dsrNextToken+ , dsrStacks+ ) where++import Network.AWS.Prelude+import Network.AWS.Request.Query+import Network.AWS.CloudFormation.Types+import qualified GHC.Exts++data DescribeStacks = DescribeStacks+ { _ds1NextToken :: Maybe Text+ , _ds1StackName :: Maybe Text+ } deriving (Eq, Ord, Show)++-- | 'DescribeStacks' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'ds1NextToken' @::@ 'Maybe' 'Text'+--+-- * 'ds1StackName' @::@ 'Maybe' 'Text'+--+describeStacks :: DescribeStacks+describeStacks = DescribeStacks+ { _ds1StackName = Nothing+ , _ds1NextToken = Nothing+ }++-- | String that identifies the start of the next list of stacks, if there is+-- one.+ds1NextToken :: Lens' DescribeStacks (Maybe Text)+ds1NextToken = lens _ds1NextToken (\s a -> s { _ds1NextToken = a })++-- | The name or the unique identifier associated with the stack, which are+-- not always interchangeable: Running stacks: You can specify either the+-- stack's name or its unique stack ID. Deleted stacks: You must specify the+-- unique stack ID. Default: There is no default value.+ds1StackName :: Lens' DescribeStacks (Maybe Text)+ds1StackName = lens _ds1StackName (\s a -> s { _ds1StackName = a })++data DescribeStacksResponse = DescribeStacksResponse+ { _dsrNextToken :: Maybe Text+ , _dsrStacks :: List "Stacks" Stack+ } deriving (Eq, Show)++-- | 'DescribeStacksResponse' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'dsrNextToken' @::@ 'Maybe' 'Text'+--+-- * 'dsrStacks' @::@ ['Stack']+--+describeStacksResponse :: DescribeStacksResponse+describeStacksResponse = DescribeStacksResponse+ { _dsrStacks = mempty+ , _dsrNextToken = Nothing+ }++-- | String that identifies the start of the next list of stacks, if there is+-- one.+dsrNextToken :: Lens' DescribeStacksResponse (Maybe Text)+dsrNextToken = lens _dsrNextToken (\s a -> s { _dsrNextToken = a })++-- | A list of stack structures.+dsrStacks :: Lens' DescribeStacksResponse [Stack]+dsrStacks = lens _dsrStacks (\s a -> s { _dsrStacks = a }) . _List++instance ToPath DescribeStacks where+ toPath = const "/"++instance ToQuery DescribeStacks where+ toQuery DescribeStacks{..} = mconcat+ [ "NextToken" =? _ds1NextToken+ , "StackName" =? _ds1StackName+ ]++instance ToHeaders DescribeStacks++instance AWSRequest DescribeStacks where+ type Sv DescribeStacks = CloudFormation+ type Rs DescribeStacks = DescribeStacksResponse++ request = post "DescribeStacks"+ response = xmlResponse++instance FromXML DescribeStacksResponse where+ parseXML = withElement "DescribeStacksResult" $ \x -> DescribeStacksResponse+ <$> x .@? "NextToken"+ <*> x .@ "Stacks"++instance AWSPager DescribeStacks where+ page rq rs+ | stop (rq ^. ds1NextToken) = Nothing+ | otherwise = (\x -> rq & ds1NextToken ?~ x)+ <$> (rs ^. dsrNextToken)
+ gen/Network/AWS/CloudFormation/EstimateTemplateCost.hs view
@@ -0,0 +1,136 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE FlexibleInstances #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE TypeFamilies #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Module : Network.AWS.CloudFormation.EstimateTemplateCost+-- Copyright : (c) 2013-2014 Brendan Hay <brendan.g.hay@gmail.com>+-- License : This Source Code Form is subject to the terms of+-- the Mozilla Public License, v. 2.0.+-- A copy of the MPL can be found in the LICENSE file or+-- you can obtain it at http://mozilla.org/MPL/2.0/.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : experimental+-- Portability : non-portable (GHC extensions)++-- | Returns the estimated monthly cost of a template. The return value is an+-- AWS Simple Monthly Calculator URL with a query string that describes the+-- resources required to run the template.+--+-- <http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_EstimateTemplateCost.html>+module Network.AWS.CloudFormation.EstimateTemplateCost+ (+ -- * Request+ EstimateTemplateCost+ -- ** Request constructor+ , estimateTemplateCost+ -- ** Request lenses+ , etcParameters+ , etcTemplateBody+ , etcTemplateURL++ -- * Response+ , EstimateTemplateCostResponse+ -- ** Response constructor+ , estimateTemplateCostResponse+ -- ** Response lenses+ , etcrUrl+ ) where++import Network.AWS.Prelude+import Network.AWS.Request.Query+import Network.AWS.CloudFormation.Types+import qualified GHC.Exts++data EstimateTemplateCost = EstimateTemplateCost+ { _etcParameters :: List "Parameters" Parameter+ , _etcTemplateBody :: Maybe Text+ , _etcTemplateURL :: Maybe Text+ } deriving (Eq, Show)++-- | 'EstimateTemplateCost' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'etcParameters' @::@ ['Parameter']+--+-- * 'etcTemplateBody' @::@ 'Maybe' 'Text'+--+-- * 'etcTemplateURL' @::@ 'Maybe' 'Text'+--+estimateTemplateCost :: EstimateTemplateCost+estimateTemplateCost = EstimateTemplateCost+ { _etcTemplateBody = Nothing+ , _etcTemplateURL = Nothing+ , _etcParameters = mempty+ }++-- | A list of Parameter structures that specify input parameters.+etcParameters :: Lens' EstimateTemplateCost [Parameter]+etcParameters = lens _etcParameters (\s a -> s { _etcParameters = a }) . _List++-- | Structure containing the template body with a minimum length of 1 byte+-- and a maximum length of 51,200 bytes. (For more information, go to+-- Template Anatomy in the AWS CloudFormation User Guide.) Conditional: You+-- must pass TemplateBody or TemplateURL. If both are passed, only+-- TemplateBody is used.+etcTemplateBody :: Lens' EstimateTemplateCost (Maybe Text)+etcTemplateBody = lens _etcTemplateBody (\s a -> s { _etcTemplateBody = a })++-- | Location of file containing the template body. The URL must point to a+-- template located in an S3 bucket in the same region as the stack. For+-- more information, go to Template Anatomy in the AWS CloudFormation User+-- Guide. Conditional: You must pass TemplateURL or TemplateBody. If both+-- are passed, only TemplateBody is used.+etcTemplateURL :: Lens' EstimateTemplateCost (Maybe Text)+etcTemplateURL = lens _etcTemplateURL (\s a -> s { _etcTemplateURL = a })++newtype EstimateTemplateCostResponse = EstimateTemplateCostResponse+ { _etcrUrl :: Maybe Text+ } deriving (Eq, Ord, Show, Monoid)++-- | 'EstimateTemplateCostResponse' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'etcrUrl' @::@ 'Maybe' 'Text'+--+estimateTemplateCostResponse :: EstimateTemplateCostResponse+estimateTemplateCostResponse = EstimateTemplateCostResponse+ { _etcrUrl = Nothing+ }++-- | An AWS Simple Monthly Calculator URL with a query string that describes+-- the resources required to run the template.+etcrUrl :: Lens' EstimateTemplateCostResponse (Maybe Text)+etcrUrl = lens _etcrUrl (\s a -> s { _etcrUrl = a })++instance ToPath EstimateTemplateCost where+ toPath = const "/"++instance ToQuery EstimateTemplateCost where+ toQuery EstimateTemplateCost{..} = mconcat+ [ "Parameters" =? _etcParameters+ , "TemplateBody" =? _etcTemplateBody+ , "TemplateURL" =? _etcTemplateURL+ ]++instance ToHeaders EstimateTemplateCost++instance AWSRequest EstimateTemplateCost where+ type Sv EstimateTemplateCost = CloudFormation+ type Rs EstimateTemplateCost = EstimateTemplateCostResponse++ request = post "EstimateTemplateCost"+ response = xmlResponse++instance FromXML EstimateTemplateCostResponse where+ parseXML = withElement "EstimateTemplateCostResult" $ \x -> EstimateTemplateCostResponse+ <$> x .@? "Url"
+ gen/Network/AWS/CloudFormation/GetStackPolicy.hs view
@@ -0,0 +1,111 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE FlexibleInstances #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE TypeFamilies #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Module : Network.AWS.CloudFormation.GetStackPolicy+-- Copyright : (c) 2013-2014 Brendan Hay <brendan.g.hay@gmail.com>+-- License : This Source Code Form is subject to the terms of+-- the Mozilla Public License, v. 2.0.+-- A copy of the MPL can be found in the LICENSE file or+-- you can obtain it at http://mozilla.org/MPL/2.0/.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : experimental+-- Portability : non-portable (GHC extensions)++-- | Returns the stack policy for a specified stack. If a stack doesn't have a+-- policy, a null value is returned.+--+-- <http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_GetStackPolicy.html>+module Network.AWS.CloudFormation.GetStackPolicy+ (+ -- * Request+ GetStackPolicy+ -- ** Request constructor+ , getStackPolicy+ -- ** Request lenses+ , gspStackName++ -- * Response+ , GetStackPolicyResponse+ -- ** Response constructor+ , getStackPolicyResponse+ -- ** Response lenses+ , gsprStackPolicyBody+ ) where++import Network.AWS.Prelude+import Network.AWS.Request.Query+import Network.AWS.CloudFormation.Types+import qualified GHC.Exts++newtype GetStackPolicy = GetStackPolicy+ { _gspStackName :: Text+ } deriving (Eq, Ord, Show, Monoid, IsString)++-- | 'GetStackPolicy' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'gspStackName' @::@ 'Text'+--+getStackPolicy :: Text -- ^ 'gspStackName'+ -> GetStackPolicy+getStackPolicy p1 = GetStackPolicy+ { _gspStackName = p1+ }++-- | The name or stack ID that is associated with the stack whose policy you+-- want to get.+gspStackName :: Lens' GetStackPolicy Text+gspStackName = lens _gspStackName (\s a -> s { _gspStackName = a })++newtype GetStackPolicyResponse = GetStackPolicyResponse+ { _gsprStackPolicyBody :: Maybe Text+ } deriving (Eq, Ord, Show, Monoid)++-- | 'GetStackPolicyResponse' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'gsprStackPolicyBody' @::@ 'Maybe' 'Text'+--+getStackPolicyResponse :: GetStackPolicyResponse+getStackPolicyResponse = GetStackPolicyResponse+ { _gsprStackPolicyBody = Nothing+ }++-- | Structure containing the stack policy body. (For more information, go to+-- Prevent Updates to Stack Resources in the AWS CloudFormation User+-- Guide.).+gsprStackPolicyBody :: Lens' GetStackPolicyResponse (Maybe Text)+gsprStackPolicyBody =+ lens _gsprStackPolicyBody (\s a -> s { _gsprStackPolicyBody = a })++instance ToPath GetStackPolicy where+ toPath = const "/"++instance ToQuery GetStackPolicy where+ toQuery GetStackPolicy{..} = mconcat+ [ "StackName" =? _gspStackName+ ]++instance ToHeaders GetStackPolicy++instance AWSRequest GetStackPolicy where+ type Sv GetStackPolicy = CloudFormation+ type Rs GetStackPolicy = GetStackPolicyResponse++ request = post "GetStackPolicy"+ response = xmlResponse++instance FromXML GetStackPolicyResponse where+ parseXML = withElement "GetStackPolicyResult" $ \x -> GetStackPolicyResponse+ <$> x .@? "StackPolicyBody"
+ gen/Network/AWS/CloudFormation/GetTemplate.hs view
@@ -0,0 +1,113 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE FlexibleInstances #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE TypeFamilies #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Module : Network.AWS.CloudFormation.GetTemplate+-- Copyright : (c) 2013-2014 Brendan Hay <brendan.g.hay@gmail.com>+-- License : This Source Code Form is subject to the terms of+-- the Mozilla Public License, v. 2.0.+-- A copy of the MPL can be found in the LICENSE file or+-- you can obtain it at http://mozilla.org/MPL/2.0/.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : experimental+-- Portability : non-portable (GHC extensions)++-- | Returns the template body for a specified stack. You can get the template+-- for running or deleted stacks. For deleted stacks, GetTemplate returns the+-- template for up to 90 days after the stack has been deleted. If the+-- template does not exist, a ValidationError is returned.+--+-- <http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_GetTemplate.html>+module Network.AWS.CloudFormation.GetTemplate+ (+ -- * Request+ GetTemplate+ -- ** Request constructor+ , getTemplate+ -- ** Request lenses+ , gtStackName++ -- * Response+ , GetTemplateResponse+ -- ** Response constructor+ , getTemplateResponse+ -- ** Response lenses+ , gtrTemplateBody+ ) where++import Network.AWS.Prelude+import Network.AWS.Request.Query+import Network.AWS.CloudFormation.Types+import qualified GHC.Exts++newtype GetTemplate = GetTemplate+ { _gtStackName :: Text+ } deriving (Eq, Ord, Show, Monoid, IsString)++-- | 'GetTemplate' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'gtStackName' @::@ 'Text'+--+getTemplate :: Text -- ^ 'gtStackName'+ -> GetTemplate+getTemplate p1 = GetTemplate+ { _gtStackName = p1+ }++-- | The name or the unique identifier associated with the stack, which are+-- not always interchangeable: Running stacks: You can specify either the+-- stack's name or its unique stack ID. Deleted stacks: You must specify the+-- unique stack ID. Default: There is no default value.+gtStackName :: Lens' GetTemplate Text+gtStackName = lens _gtStackName (\s a -> s { _gtStackName = a })++newtype GetTemplateResponse = GetTemplateResponse+ { _gtrTemplateBody :: Maybe Text+ } deriving (Eq, Ord, Show, Monoid)++-- | 'GetTemplateResponse' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'gtrTemplateBody' @::@ 'Maybe' 'Text'+--+getTemplateResponse :: GetTemplateResponse+getTemplateResponse = GetTemplateResponse+ { _gtrTemplateBody = Nothing+ }++-- | Structure containing the template body. (For more information, go to+-- Template Anatomy in the AWS CloudFormation User Guide.).+gtrTemplateBody :: Lens' GetTemplateResponse (Maybe Text)+gtrTemplateBody = lens _gtrTemplateBody (\s a -> s { _gtrTemplateBody = a })++instance ToPath GetTemplate where+ toPath = const "/"++instance ToQuery GetTemplate where+ toQuery GetTemplate{..} = mconcat+ [ "StackName" =? _gtStackName+ ]++instance ToHeaders GetTemplate++instance AWSRequest GetTemplate where+ type Sv GetTemplate = CloudFormation+ type Rs GetTemplate = GetTemplateResponse++ request = post "GetTemplate"+ response = xmlResponse++instance FromXML GetTemplateResponse where+ parseXML = withElement "GetTemplateResult" $ \x -> GetTemplateResponse+ <$> x .@? "TemplateBody"
+ gen/Network/AWS/CloudFormation/GetTemplateSummary.hs view
@@ -0,0 +1,192 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE FlexibleInstances #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE TypeFamilies #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Module : Network.AWS.CloudFormation.GetTemplateSummary+-- Copyright : (c) 2013-2014 Brendan Hay <brendan.g.hay@gmail.com>+-- License : This Source Code Form is subject to the terms of+-- the Mozilla Public License, v. 2.0.+-- A copy of the MPL can be found in the LICENSE file or+-- you can obtain it at http://mozilla.org/MPL/2.0/.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : experimental+-- Portability : non-portable (GHC extensions)++-- | Returns information about a new or existing template. The+-- GetTemplateSummary action is useful for viewing parameter information, such+-- as default parameter values and parameter types, before you create or+-- update a stack. You can use the GetTemplateSummary action when you submit a+-- template, or you can get template information for a running or deleted+-- stack. For deleted stacks, GetTemplateSummary returns the template+-- information for up to 90 days after the stack has been deleted. If the+-- template does not exist, a ValidationError is returned.+--+-- <http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_GetTemplateSummary.html>+module Network.AWS.CloudFormation.GetTemplateSummary+ (+ -- * Request+ GetTemplateSummary+ -- ** Request constructor+ , getTemplateSummary+ -- ** Request lenses+ , gtsStackName+ , gtsTemplateBody+ , gtsTemplateURL++ -- * Response+ , GetTemplateSummaryResponse+ -- ** Response constructor+ , getTemplateSummaryResponse+ -- ** Response lenses+ , gtsrCapabilities+ , gtsrCapabilitiesReason+ , gtsrDescription+ , gtsrParameters+ , gtsrVersion+ ) where++import Network.AWS.Prelude+import Network.AWS.Request.Query+import Network.AWS.CloudFormation.Types+import qualified GHC.Exts++data GetTemplateSummary = GetTemplateSummary+ { _gtsStackName :: Maybe Text+ , _gtsTemplateBody :: Maybe Text+ , _gtsTemplateURL :: Maybe Text+ } deriving (Eq, Ord, Show)++-- | 'GetTemplateSummary' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'gtsStackName' @::@ 'Maybe' 'Text'+--+-- * 'gtsTemplateBody' @::@ 'Maybe' 'Text'+--+-- * 'gtsTemplateURL' @::@ 'Maybe' 'Text'+--+getTemplateSummary :: GetTemplateSummary+getTemplateSummary = GetTemplateSummary+ { _gtsTemplateBody = Nothing+ , _gtsTemplateURL = Nothing+ , _gtsStackName = Nothing+ }++-- | The name or the unique identifier associated with the stack, which are+-- not always interchangeable. For running stacks, you can specify either+-- the stack's name or its unique stack ID. For deleted stack, you must+-- specify the unique stack ID. Conditional: You must specify only one of+-- the following parameters: StackName, TemplateBody, or TemplateURL.+gtsStackName :: Lens' GetTemplateSummary (Maybe Text)+gtsStackName = lens _gtsStackName (\s a -> s { _gtsStackName = a })++-- | Structure containing the template body with a minimum length of 1 byte+-- and a maximum length of 51,200 bytes. For more information about+-- templates, see Template Anatomy in the AWS CloudFormation User Guide.+-- Conditional: You must specify only one of the following parameters:+-- StackName, TemplateBody, or TemplateURL.+gtsTemplateBody :: Lens' GetTemplateSummary (Maybe Text)+gtsTemplateBody = lens _gtsTemplateBody (\s a -> s { _gtsTemplateBody = a })++-- | Location of file containing the template body. The URL must point to a+-- template (max size: 307,200 bytes) located in an Amazon S3 bucket. For+-- more information about templates, see Template Anatomy in the AWS+-- CloudFormation User Guide. Conditional: You must specify only one of the+-- following parameters: StackName, TemplateBody, or TemplateURL.+gtsTemplateURL :: Lens' GetTemplateSummary (Maybe Text)+gtsTemplateURL = lens _gtsTemplateURL (\s a -> s { _gtsTemplateURL = a })++data GetTemplateSummaryResponse = GetTemplateSummaryResponse+ { _gtsrCapabilities :: List "Capabilities" Text+ , _gtsrCapabilitiesReason :: Maybe Text+ , _gtsrDescription :: Maybe Text+ , _gtsrParameters :: List "Parameters" ParameterDeclaration+ , _gtsrVersion :: Maybe Text+ } deriving (Eq, Show)++-- | 'GetTemplateSummaryResponse' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'gtsrCapabilities' @::@ ['Text']+--+-- * 'gtsrCapabilitiesReason' @::@ 'Maybe' 'Text'+--+-- * 'gtsrDescription' @::@ 'Maybe' 'Text'+--+-- * 'gtsrParameters' @::@ ['ParameterDeclaration']+--+-- * 'gtsrVersion' @::@ 'Maybe' 'Text'+--+getTemplateSummaryResponse :: GetTemplateSummaryResponse+getTemplateSummaryResponse = GetTemplateSummaryResponse+ { _gtsrParameters = mempty+ , _gtsrDescription = Nothing+ , _gtsrCapabilities = mempty+ , _gtsrCapabilitiesReason = Nothing+ , _gtsrVersion = Nothing+ }++-- | The capabilities found within the template. Currently, AWS CloudFormation+-- supports only the CAPABILITY_IAM capability. If your template contains+-- IAM resources, you must specify the CAPABILITY_IAM value for this+-- parameter when you use the CreateStack or UpdateStack actions with your+-- template; otherwise, those actions return an InsufficientCapabilities+-- error.+gtsrCapabilities :: Lens' GetTemplateSummaryResponse [Text]+gtsrCapabilities = lens _gtsrCapabilities (\s a -> s { _gtsrCapabilities = a }) . _List++-- | The capabilities reason found within the template.+gtsrCapabilitiesReason :: Lens' GetTemplateSummaryResponse (Maybe Text)+gtsrCapabilitiesReason =+ lens _gtsrCapabilitiesReason (\s a -> s { _gtsrCapabilitiesReason = a })++-- | The value that is defined in the Description property of the template.+gtsrDescription :: Lens' GetTemplateSummaryResponse (Maybe Text)+gtsrDescription = lens _gtsrDescription (\s a -> s { _gtsrDescription = a })++-- | A list of parameter declarations that describe various properties for+-- each parameter.+gtsrParameters :: Lens' GetTemplateSummaryResponse [ParameterDeclaration]+gtsrParameters = lens _gtsrParameters (\s a -> s { _gtsrParameters = a }) . _List++-- | The AWS template format version, which identifies the capabilities of the+-- template.+gtsrVersion :: Lens' GetTemplateSummaryResponse (Maybe Text)+gtsrVersion = lens _gtsrVersion (\s a -> s { _gtsrVersion = a })++instance ToPath GetTemplateSummary where+ toPath = const "/"++instance ToQuery GetTemplateSummary where+ toQuery GetTemplateSummary{..} = mconcat+ [ "StackName" =? _gtsStackName+ , "TemplateBody" =? _gtsTemplateBody+ , "TemplateURL" =? _gtsTemplateURL+ ]++instance ToHeaders GetTemplateSummary++instance AWSRequest GetTemplateSummary where+ type Sv GetTemplateSummary = CloudFormation+ type Rs GetTemplateSummary = GetTemplateSummaryResponse++ request = post "GetTemplateSummary"+ response = xmlResponse++instance FromXML GetTemplateSummaryResponse where+ parseXML = withElement "GetTemplateSummaryResult" $ \x -> GetTemplateSummaryResponse+ <$> x .@ "Capabilities"+ <*> x .@? "CapabilitiesReason"+ <*> x .@? "Description"+ <*> x .@ "Parameters"+ <*> x .@? "Version"
+ gen/Network/AWS/CloudFormation/ListStackResources.hs view
@@ -0,0 +1,142 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE FlexibleInstances #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE TypeFamilies #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Module : Network.AWS.CloudFormation.ListStackResources+-- Copyright : (c) 2013-2014 Brendan Hay <brendan.g.hay@gmail.com>+-- License : This Source Code Form is subject to the terms of+-- the Mozilla Public License, v. 2.0.+-- A copy of the MPL can be found in the LICENSE file or+-- you can obtain it at http://mozilla.org/MPL/2.0/.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : experimental+-- Portability : non-portable (GHC extensions)++-- | Returns descriptions of all resources of the specified stack. For deleted+-- stacks, ListStackResources returns resource information for up to 90 days+-- after the stack has been deleted.+--+-- <http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_ListStackResources.html>+module Network.AWS.CloudFormation.ListStackResources+ (+ -- * Request+ ListStackResources+ -- ** Request constructor+ , listStackResources+ -- ** Request lenses+ , lsrNextToken+ , lsrStackName++ -- * Response+ , ListStackResourcesResponse+ -- ** Response constructor+ , listStackResourcesResponse+ -- ** Response lenses+ , lsrrNextToken+ , lsrrStackResourceSummaries+ ) where++import Network.AWS.Prelude+import Network.AWS.Request.Query+import Network.AWS.CloudFormation.Types+import qualified GHC.Exts++data ListStackResources = ListStackResources+ { _lsrNextToken :: Maybe Text+ , _lsrStackName :: Text+ } deriving (Eq, Ord, Show)++-- | 'ListStackResources' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'lsrNextToken' @::@ 'Maybe' 'Text'+--+-- * 'lsrStackName' @::@ 'Text'+--+listStackResources :: Text -- ^ 'lsrStackName'+ -> ListStackResources+listStackResources p1 = ListStackResources+ { _lsrStackName = p1+ , _lsrNextToken = Nothing+ }++-- | String that identifies the start of the next list of stack resource+-- summaries, if there is one. Default: There is no default value.+lsrNextToken :: Lens' ListStackResources (Maybe Text)+lsrNextToken = lens _lsrNextToken (\s a -> s { _lsrNextToken = a })++-- | The name or the unique identifier associated with the stack, which are+-- not always interchangeable: Running stacks: You can specify either the+-- stack's name or its unique stack ID. Deleted stacks: You must specify the+-- unique stack ID. Default: There is no default value.+lsrStackName :: Lens' ListStackResources Text+lsrStackName = lens _lsrStackName (\s a -> s { _lsrStackName = a })++data ListStackResourcesResponse = ListStackResourcesResponse+ { _lsrrNextToken :: Maybe Text+ , _lsrrStackResourceSummaries :: List "StackResourceSummaries" StackResourceSummary+ } deriving (Eq, Show)++-- | 'ListStackResourcesResponse' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'lsrrNextToken' @::@ 'Maybe' 'Text'+--+-- * 'lsrrStackResourceSummaries' @::@ ['StackResourceSummary']+--+listStackResourcesResponse :: ListStackResourcesResponse+listStackResourcesResponse = ListStackResourcesResponse+ { _lsrrStackResourceSummaries = mempty+ , _lsrrNextToken = Nothing+ }++-- | String that identifies the start of the next list of stack resources, if+-- there is one.+lsrrNextToken :: Lens' ListStackResourcesResponse (Maybe Text)+lsrrNextToken = lens _lsrrNextToken (\s a -> s { _lsrrNextToken = a })++-- | A list of StackResourceSummary structures.+lsrrStackResourceSummaries :: Lens' ListStackResourcesResponse [StackResourceSummary]+lsrrStackResourceSummaries =+ lens _lsrrStackResourceSummaries+ (\s a -> s { _lsrrStackResourceSummaries = a })+ . _List++instance ToPath ListStackResources where+ toPath = const "/"++instance ToQuery ListStackResources where+ toQuery ListStackResources{..} = mconcat+ [ "NextToken" =? _lsrNextToken+ , "StackName" =? _lsrStackName+ ]++instance ToHeaders ListStackResources++instance AWSRequest ListStackResources where+ type Sv ListStackResources = CloudFormation+ type Rs ListStackResources = ListStackResourcesResponse++ request = post "ListStackResources"+ response = xmlResponse++instance FromXML ListStackResourcesResponse where+ parseXML = withElement "ListStackResourcesResult" $ \x -> ListStackResourcesResponse+ <$> x .@? "NextToken"+ <*> x .@ "StackResourceSummaries"++instance AWSPager ListStackResources where+ page rq rs+ | stop (rq ^. lsrNextToken) = Nothing+ | otherwise = (\x -> rq & lsrNextToken ?~ x)+ <$> (rs ^. lsrrNextToken)
+ gen/Network/AWS/CloudFormation/ListStacks.hs view
@@ -0,0 +1,145 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE FlexibleInstances #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE TypeFamilies #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Module : Network.AWS.CloudFormation.ListStacks+-- Copyright : (c) 2013-2014 Brendan Hay <brendan.g.hay@gmail.com>+-- License : This Source Code Form is subject to the terms of+-- the Mozilla Public License, v. 2.0.+-- A copy of the MPL can be found in the LICENSE file or+-- you can obtain it at http://mozilla.org/MPL/2.0/.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : experimental+-- Portability : non-portable (GHC extensions)++-- | Returns the summary information for stacks whose status matches the+-- specified StackStatusFilter. Summary information for stacks that have been+-- deleted is kept for 90 days after the stack is deleted. If no+-- StackStatusFilter is specified, summary information for all stacks is+-- returned (including existing stacks and stacks that have been deleted).+--+-- <http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_ListStacks.html>+module Network.AWS.CloudFormation.ListStacks+ (+ -- * Request+ ListStacks+ -- ** Request constructor+ , listStacks+ -- ** Request lenses+ , lsNextToken+ , lsStackStatusFilter++ -- * Response+ , ListStacksResponse+ -- ** Response constructor+ , listStacksResponse+ -- ** Response lenses+ , lsr1NextToken+ , lsr1StackSummaries+ ) where++import Network.AWS.Prelude+import Network.AWS.Request.Query+import Network.AWS.CloudFormation.Types+import qualified GHC.Exts++data ListStacks = ListStacks+ { _lsNextToken :: Maybe Text+ , _lsStackStatusFilter :: List "StackStatusFilter" Text+ } deriving (Eq, Ord, Show)++-- | 'ListStacks' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'lsNextToken' @::@ 'Maybe' 'Text'+--+-- * 'lsStackStatusFilter' @::@ ['Text']+--+listStacks :: ListStacks+listStacks = ListStacks+ { _lsNextToken = Nothing+ , _lsStackStatusFilter = mempty+ }++-- | String that identifies the start of the next list of stacks, if there is+-- one. Default: There is no default value.+lsNextToken :: Lens' ListStacks (Maybe Text)+lsNextToken = lens _lsNextToken (\s a -> s { _lsNextToken = a })++-- | Stack status to use as a filter. Specify one or more stack status codes+-- to list only stacks with the specified status codes. For a complete list+-- of stack status codes, see the StackStatus parameter of the Stack data+-- type.+lsStackStatusFilter :: Lens' ListStacks [Text]+lsStackStatusFilter =+ lens _lsStackStatusFilter (\s a -> s { _lsStackStatusFilter = a })+ . _List++data ListStacksResponse = ListStacksResponse+ { _lsr1NextToken :: Maybe Text+ , _lsr1StackSummaries :: List "StackSummaries" StackSummary+ } deriving (Eq, Show)++-- | 'ListStacksResponse' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'lsr1NextToken' @::@ 'Maybe' 'Text'+--+-- * 'lsr1StackSummaries' @::@ ['StackSummary']+--+listStacksResponse :: ListStacksResponse+listStacksResponse = ListStacksResponse+ { _lsr1StackSummaries = mempty+ , _lsr1NextToken = Nothing+ }++-- | String that identifies the start of the next list of stacks, if there is+-- one.+lsr1NextToken :: Lens' ListStacksResponse (Maybe Text)+lsr1NextToken = lens _lsr1NextToken (\s a -> s { _lsr1NextToken = a })++-- | A list of StackSummary structures containing information about the+-- specified stacks.+lsr1StackSummaries :: Lens' ListStacksResponse [StackSummary]+lsr1StackSummaries =+ lens _lsr1StackSummaries (\s a -> s { _lsr1StackSummaries = a })+ . _List++instance ToPath ListStacks where+ toPath = const "/"++instance ToQuery ListStacks where+ toQuery ListStacks{..} = mconcat+ [ "NextToken" =? _lsNextToken+ , "StackStatusFilter" =? _lsStackStatusFilter+ ]++instance ToHeaders ListStacks++instance AWSRequest ListStacks where+ type Sv ListStacks = CloudFormation+ type Rs ListStacks = ListStacksResponse++ request = post "ListStacks"+ response = xmlResponse++instance FromXML ListStacksResponse where+ parseXML = withElement "ListStacksResult" $ \x -> ListStacksResponse+ <$> x .@? "NextToken"+ <*> x .@ "StackSummaries"++instance AWSPager ListStacks where+ page rq rs+ | stop (rq ^. lsNextToken) = Nothing+ | otherwise = (\x -> rq & lsNextToken ?~ x)+ <$> (rs ^. lsr1NextToken)
+ gen/Network/AWS/CloudFormation/SetStackPolicy.hs view
@@ -0,0 +1,116 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE FlexibleInstances #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE TypeFamilies #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Module : Network.AWS.CloudFormation.SetStackPolicy+-- Copyright : (c) 2013-2014 Brendan Hay <brendan.g.hay@gmail.com>+-- License : This Source Code Form is subject to the terms of+-- the Mozilla Public License, v. 2.0.+-- A copy of the MPL can be found in the LICENSE file or+-- you can obtain it at http://mozilla.org/MPL/2.0/.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : experimental+-- Portability : non-portable (GHC extensions)++-- | Sets a stack policy for a specified stack.+--+-- <http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_SetStackPolicy.html>+module Network.AWS.CloudFormation.SetStackPolicy+ (+ -- * Request+ SetStackPolicy+ -- ** Request constructor+ , setStackPolicy+ -- ** Request lenses+ , sspStackName+ , sspStackPolicyBody+ , sspStackPolicyURL++ -- * Response+ , SetStackPolicyResponse+ -- ** Response constructor+ , setStackPolicyResponse+ ) where++import Network.AWS.Prelude+import Network.AWS.Request.Query+import Network.AWS.CloudFormation.Types+import qualified GHC.Exts++data SetStackPolicy = SetStackPolicy+ { _sspStackName :: Text+ , _sspStackPolicyBody :: Maybe Text+ , _sspStackPolicyURL :: Maybe Text+ } deriving (Eq, Ord, Show)++-- | 'SetStackPolicy' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'sspStackName' @::@ 'Text'+--+-- * 'sspStackPolicyBody' @::@ 'Maybe' 'Text'+--+-- * 'sspStackPolicyURL' @::@ 'Maybe' 'Text'+--+setStackPolicy :: Text -- ^ 'sspStackName'+ -> SetStackPolicy+setStackPolicy p1 = SetStackPolicy+ { _sspStackName = p1+ , _sspStackPolicyBody = Nothing+ , _sspStackPolicyURL = Nothing+ }++-- | The name or stack ID that you want to associate a policy with.+sspStackName :: Lens' SetStackPolicy Text+sspStackName = lens _sspStackName (\s a -> s { _sspStackName = a })++-- | Structure containing the stack policy body. For more information, go to+-- Prevent Updates to Stack Resources in the AWS CloudFormation User Guide.+-- You can specify either the StackPolicyBody or the StackPolicyURL+-- parameter, but not both.+sspStackPolicyBody :: Lens' SetStackPolicy (Maybe Text)+sspStackPolicyBody =+ lens _sspStackPolicyBody (\s a -> s { _sspStackPolicyBody = a })++-- | Location of a file containing the stack policy. The URL must point to a+-- policy (max size: 16KB) located in an S3 bucket in the same region as the+-- stack. You can specify either the StackPolicyBody or the StackPolicyURL+-- parameter, but not both.+sspStackPolicyURL :: Lens' SetStackPolicy (Maybe Text)+sspStackPolicyURL =+ lens _sspStackPolicyURL (\s a -> s { _sspStackPolicyURL = a })++data SetStackPolicyResponse = SetStackPolicyResponse+ deriving (Eq, Ord, Show, Generic)++-- | 'SetStackPolicyResponse' constructor.+setStackPolicyResponse :: SetStackPolicyResponse+setStackPolicyResponse = SetStackPolicyResponse++instance ToPath SetStackPolicy where+ toPath = const "/"++instance ToQuery SetStackPolicy where+ toQuery SetStackPolicy{..} = mconcat+ [ "StackName" =? _sspStackName+ , "StackPolicyBody" =? _sspStackPolicyBody+ , "StackPolicyURL" =? _sspStackPolicyURL+ ]++instance ToHeaders SetStackPolicy++instance AWSRequest SetStackPolicy where+ type Sv SetStackPolicy = CloudFormation+ type Rs SetStackPolicy = SetStackPolicyResponse++ request = post "SetStackPolicy"+ response = nullResponse SetStackPolicyResponse
+ gen/Network/AWS/CloudFormation/SignalResource.hs view
@@ -0,0 +1,133 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE FlexibleInstances #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE TypeFamilies #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Module : Network.AWS.CloudFormation.SignalResource+-- Copyright : (c) 2013-2014 Brendan Hay <brendan.g.hay@gmail.com>+-- License : This Source Code Form is subject to the terms of+-- the Mozilla Public License, v. 2.0.+-- A copy of the MPL can be found in the LICENSE file or+-- you can obtain it at http://mozilla.org/MPL/2.0/.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : experimental+-- Portability : non-portable (GHC extensions)++-- | Sends a signal to the specified resource with a success or failure status.+-- You can use the SignalResource API in conjunction with a creation policy or+-- update policy. AWS CloudFormation doesn't proceed with a stack creation or+-- update until resources receive the required number of signals or the+-- timeout period is exceeded. The SignalResource API is useful in cases where+-- you want to send signals from anywhere other than an Amazon EC2 instance.+--+-- <http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_SignalResource.html>+module Network.AWS.CloudFormation.SignalResource+ (+ -- * Request+ SignalResource+ -- ** Request constructor+ , signalResource+ -- ** Request lenses+ , srLogicalResourceId+ , srStackName+ , srStatus+ , srUniqueId++ -- * Response+ , SignalResourceResponse+ -- ** Response constructor+ , signalResourceResponse+ ) where++import Network.AWS.Prelude+import Network.AWS.Request.Query+import Network.AWS.CloudFormation.Types+import qualified GHC.Exts++data SignalResource = SignalResource+ { _srLogicalResourceId :: Text+ , _srStackName :: Text+ , _srStatus :: Text+ , _srUniqueId :: Text+ } deriving (Eq, Ord, Show)++-- | 'SignalResource' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'srLogicalResourceId' @::@ 'Text'+--+-- * 'srStackName' @::@ 'Text'+--+-- * 'srStatus' @::@ 'Text'+--+-- * 'srUniqueId' @::@ 'Text'+--+signalResource :: Text -- ^ 'srStackName'+ -> Text -- ^ 'srLogicalResourceId'+ -> Text -- ^ 'srUniqueId'+ -> Text -- ^ 'srStatus'+ -> SignalResource+signalResource p1 p2 p3 p4 = SignalResource+ { _srStackName = p1+ , _srLogicalResourceId = p2+ , _srUniqueId = p3+ , _srStatus = p4+ }++-- | The logical ID of the resource that you want to signal. The logical ID is+-- the name of the resource that given in the template.+srLogicalResourceId :: Lens' SignalResource Text+srLogicalResourceId =+ lens _srLogicalResourceId (\s a -> s { _srLogicalResourceId = a })++-- | The stack name or ID that includes the resource that you want to signal.+srStackName :: Lens' SignalResource Text+srStackName = lens _srStackName (\s a -> s { _srStackName = a })++-- | The status of the signal, which is either success or failure. A failure+-- signal causes AWS CloudFormation to immediately fail the stack creation+-- or update.+srStatus :: Lens' SignalResource Text+srStatus = lens _srStatus (\s a -> s { _srStatus = a })++-- | A unique ID of the signal. When you signal Amazon EC2 instances or Auto+-- Scaling groups, specify the instance ID that you are signaling as the+-- unique ID. If you send multiple signals to a single resource (such as+-- signaling a wait condition), each signal requires a different unique ID.+srUniqueId :: Lens' SignalResource Text+srUniqueId = lens _srUniqueId (\s a -> s { _srUniqueId = a })++data SignalResourceResponse = SignalResourceResponse+ deriving (Eq, Ord, Show, Generic)++-- | 'SignalResourceResponse' constructor.+signalResourceResponse :: SignalResourceResponse+signalResourceResponse = SignalResourceResponse++instance ToPath SignalResource where+ toPath = const "/"++instance ToQuery SignalResource where+ toQuery SignalResource{..} = mconcat+ [ "LogicalResourceId" =? _srLogicalResourceId+ , "StackName" =? _srStackName+ , "Status" =? _srStatus+ , "UniqueId" =? _srUniqueId+ ]++instance ToHeaders SignalResource++instance AWSRequest SignalResource where+ type Sv SignalResource = CloudFormation+ type Rs SignalResource = SignalResourceResponse++ request = post "SignalResource"+ response = nullResponse SignalResourceResponse
+ gen/Network/AWS/CloudFormation/Types.hs view
@@ -0,0 +1,1374 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE FlexibleInstances #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE TypeFamilies #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Module : Network.AWS.CloudFormation.Types+-- Copyright : (c) 2013-2014 Brendan Hay <brendan.g.hay@gmail.com>+-- License : This Source Code Form is subject to the terms of+-- the Mozilla Public License, v. 2.0.+-- A copy of the MPL can be found in the LICENSE file or+-- you can obtain it at http://mozilla.org/MPL/2.0/.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : experimental+-- Portability : non-portable (GHC extensions)++module Network.AWS.CloudFormation.Types+ (+ -- * Service+ CloudFormation+ -- ** Error+ , RESTError+ -- ** XML+ , ns++ -- * Tag+ , Tag+ , tag+ , tagKey+ , tagValue++ -- * StackStatus+ , StackStatus (..)++ -- * StackEvent+ , StackEvent+ , stackEvent+ , seEventId+ , seLogicalResourceId+ , sePhysicalResourceId+ , seResourceProperties+ , seResourceStatus+ , seResourceStatusReason+ , seResourceType+ , seStackId+ , seStackName+ , seTimestamp++ -- * StackSummary+ , StackSummary+ , stackSummary+ , ssCreationTime+ , ssDeletionTime+ , ssLastUpdatedTime+ , ssStackId+ , ssStackName+ , ssStackStatus+ , ssStackStatusReason+ , ssTemplateDescription++ -- * StackResourceDetail+ , StackResourceDetail+ , stackResourceDetail+ , srdDescription+ , srdLastUpdatedTimestamp+ , srdLogicalResourceId+ , srdMetadata+ , srdPhysicalResourceId+ , srdResourceStatus+ , srdResourceStatusReason+ , srdResourceType+ , srdStackId+ , srdStackName++ -- * ResourceStatus+ , ResourceStatus (..)++ -- * TemplateParameter+ , TemplateParameter+ , templateParameter+ , tpDefaultValue+ , tpDescription+ , tpNoEcho+ , tpParameterKey++ -- * ParameterDeclaration+ , ParameterDeclaration+ , parameterDeclaration+ , pdDefaultValue+ , pdDescription+ , pdNoEcho+ , pdParameterKey+ , pdParameterType++ -- * StackResource+ , StackResource+ , stackResource+ , sr1Description+ , sr1LogicalResourceId+ , sr1PhysicalResourceId+ , sr1ResourceStatus+ , sr1ResourceStatusReason+ , sr1ResourceType+ , sr1StackId+ , sr1StackName+ , sr1Timestamp++ -- * Output+ , Output+ , output+ , oDescription+ , oOutputKey+ , oOutputValue++ -- * StackResourceSummary+ , StackResourceSummary+ , stackResourceSummary+ , srsLastUpdatedTimestamp+ , srsLogicalResourceId+ , srsPhysicalResourceId+ , srsResourceStatus+ , srsResourceStatusReason+ , srsResourceType++ -- * Capability+ , Capability (..)++ -- * ResourceSignalStatus+ , ResourceSignalStatus (..)++ -- * Stack+ , Stack+ , stack+ , sCapabilities+ , sCreationTime+ , sDescription+ , sDisableRollback+ , sLastUpdatedTime+ , sNotificationARNs+ , sOutputs+ , sParameters+ , sStackId+ , sStackName+ , sStackStatus+ , sStackStatusReason+ , sTags+ , sTimeoutInMinutes++ -- * OnFailure+ , OnFailure (..)++ -- * Parameter+ , Parameter+ , parameter+ , pParameterKey+ , pParameterValue+ , pUsePreviousValue+ ) where++import Network.AWS.Error+import Network.AWS.Prelude+import Network.AWS.Signing.V4+import qualified GHC.Exts++-- | Version @2010-05-15@ of the Amazon CloudFormation service.+data CloudFormation++instance AWSService CloudFormation where+ type Sg CloudFormation = V4+ type Er CloudFormation = RESTError++ service = Service+ { _svcEndpoint = regional+ , _svcAbbrev = "CloudFormation"+ , _svcPrefix = "cloudformation"+ , _svcVersion = "2010-05-15"+ , _svcTargetPrefix = Nothing+ , _svcJSONVersion = Nothing+ }++ handle = restError statusSuccess++ns :: Text+ns = "http://cloudformation.amazonaws.com/doc/2010-05-15/"++data Tag = Tag+ { _tagKey :: Maybe Text+ , _tagValue :: Maybe Text+ } deriving (Eq, Ord, Show)++-- | 'Tag' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'tagKey' @::@ 'Maybe' 'Text'+--+-- * 'tagValue' @::@ 'Maybe' 'Text'+--+tag :: Tag+tag = Tag+ { _tagKey = Nothing+ , _tagValue = Nothing+ }++-- | Required. A string used to identify this tag. You can specify a maximum+-- of 128 characters for a tag key. Tags owned by Amazon Web Services (AWS)+-- have the reserved prefix: aws:.+tagKey :: Lens' Tag (Maybe Text)+tagKey = lens _tagKey (\s a -> s { _tagKey = a })++-- | Required. A string containing the value for this tag. You can specify a+-- maximum of 256 characters for a tag value.+tagValue :: Lens' Tag (Maybe Text)+tagValue = lens _tagValue (\s a -> s { _tagValue = a })++instance FromXML Tag where+ parseXML x = Tag+ <$> x .@? "Key"+ <*> x .@? "Value"++instance ToQuery Tag where+ toQuery Tag{..} = mconcat+ [ "Key" =? _tagKey+ , "Value" =? _tagValue+ ]++data StackStatus+ = CreateComplete -- ^ CREATE_COMPLETE+ | CreateFailed -- ^ CREATE_FAILED+ | CreateInProgress -- ^ CREATE_IN_PROGRESS+ | DeleteComplete -- ^ DELETE_COMPLETE+ | DeleteFailed -- ^ DELETE_FAILED+ | DeleteInProgress -- ^ DELETE_IN_PROGRESS+ | RollbackComplete -- ^ ROLLBACK_COMPLETE+ | RollbackFailed -- ^ ROLLBACK_FAILED+ | RollbackInProgress -- ^ ROLLBACK_IN_PROGRESS+ | UpdateComplete -- ^ UPDATE_COMPLETE+ | UpdateCompleteCleanupInProgress -- ^ UPDATE_COMPLETE_CLEANUP_IN_PROGRESS+ | UpdateInProgress -- ^ UPDATE_IN_PROGRESS+ | UpdateRollbackComplete -- ^ UPDATE_ROLLBACK_COMPLETE+ | UpdateRollbackCompleteCleanupInProgress -- ^ UPDATE_ROLLBACK_COMPLETE_CLEANUP_IN_PROGRESS+ | UpdateRollbackFailed -- ^ UPDATE_ROLLBACK_FAILED+ | UpdateRollbackInProgress -- ^ UPDATE_ROLLBACK_IN_PROGRESS+ deriving (Eq, Ord, Show, Generic, Enum)++instance Hashable StackStatus++instance FromText StackStatus where+ parser = match "CREATE_COMPLETE" CreateComplete+ <|> match "CREATE_FAILED" CreateFailed+ <|> match "CREATE_IN_PROGRESS" CreateInProgress+ <|> match "DELETE_COMPLETE" DeleteComplete+ <|> match "DELETE_FAILED" DeleteFailed+ <|> match "DELETE_IN_PROGRESS" DeleteInProgress+ <|> match "ROLLBACK_COMPLETE" RollbackComplete+ <|> match "ROLLBACK_FAILED" RollbackFailed+ <|> match "ROLLBACK_IN_PROGRESS" RollbackInProgress+ <|> match "UPDATE_COMPLETE" UpdateComplete+ <|> match "UPDATE_COMPLETE_CLEANUP_IN_PROGRESS" UpdateCompleteCleanupInProgress+ <|> match "UPDATE_IN_PROGRESS" UpdateInProgress+ <|> match "UPDATE_ROLLBACK_COMPLETE" UpdateRollbackComplete+ <|> match "UPDATE_ROLLBACK_COMPLETE_CLEANUP_IN_PROGRESS" UpdateRollbackCompleteCleanupInProgress+ <|> match "UPDATE_ROLLBACK_FAILED" UpdateRollbackFailed+ <|> match "UPDATE_ROLLBACK_IN_PROGRESS" UpdateRollbackInProgress++instance ToText StackStatus where+ toText = \case+ CreateComplete -> "CREATE_COMPLETE"+ CreateFailed -> "CREATE_FAILED"+ CreateInProgress -> "CREATE_IN_PROGRESS"+ DeleteComplete -> "DELETE_COMPLETE"+ DeleteFailed -> "DELETE_FAILED"+ DeleteInProgress -> "DELETE_IN_PROGRESS"+ RollbackComplete -> "ROLLBACK_COMPLETE"+ RollbackFailed -> "ROLLBACK_FAILED"+ RollbackInProgress -> "ROLLBACK_IN_PROGRESS"+ UpdateComplete -> "UPDATE_COMPLETE"+ UpdateCompleteCleanupInProgress -> "UPDATE_COMPLETE_CLEANUP_IN_PROGRESS"+ UpdateInProgress -> "UPDATE_IN_PROGRESS"+ UpdateRollbackComplete -> "UPDATE_ROLLBACK_COMPLETE"+ UpdateRollbackCompleteCleanupInProgress -> "UPDATE_ROLLBACK_COMPLETE_CLEANUP_IN_PROGRESS"+ UpdateRollbackFailed -> "UPDATE_ROLLBACK_FAILED"+ UpdateRollbackInProgress -> "UPDATE_ROLLBACK_IN_PROGRESS"++instance FromXML StackStatus where+ parseXML = parseXMLText "StackStatus"++instance ToQuery StackStatus where+ toQuery = toQuery . toText++data StackEvent = StackEvent+ { _seEventId :: Text+ , _seLogicalResourceId :: Maybe Text+ , _sePhysicalResourceId :: Maybe Text+ , _seResourceProperties :: Maybe Text+ , _seResourceStatus :: Maybe Text+ , _seResourceStatusReason :: Maybe Text+ , _seResourceType :: Maybe Text+ , _seStackId :: Text+ , _seStackName :: Text+ , _seTimestamp :: RFC822+ } deriving (Eq, Ord, Show)++-- | 'StackEvent' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'seEventId' @::@ 'Text'+--+-- * 'seLogicalResourceId' @::@ 'Maybe' 'Text'+--+-- * 'sePhysicalResourceId' @::@ 'Maybe' 'Text'+--+-- * 'seResourceProperties' @::@ 'Maybe' 'Text'+--+-- * 'seResourceStatus' @::@ 'Maybe' 'Text'+--+-- * 'seResourceStatusReason' @::@ 'Maybe' 'Text'+--+-- * 'seResourceType' @::@ 'Maybe' 'Text'+--+-- * 'seStackId' @::@ 'Text'+--+-- * 'seStackName' @::@ 'Text'+--+-- * 'seTimestamp' @::@ 'UTCTime'+--+stackEvent :: Text -- ^ 'seStackId'+ -> Text -- ^ 'seEventId'+ -> Text -- ^ 'seStackName'+ -> UTCTime -- ^ 'seTimestamp'+ -> StackEvent+stackEvent p1 p2 p3 p4 = StackEvent+ { _seStackId = p1+ , _seEventId = p2+ , _seStackName = p3+ , _seTimestamp = withIso _Time (const id) p4+ , _seLogicalResourceId = Nothing+ , _sePhysicalResourceId = Nothing+ , _seResourceType = Nothing+ , _seResourceStatus = Nothing+ , _seResourceStatusReason = Nothing+ , _seResourceProperties = Nothing+ }++-- | The unique ID of this event.+seEventId :: Lens' StackEvent Text+seEventId = lens _seEventId (\s a -> s { _seEventId = a })++-- | The logical name of the resource specified in the template.+seLogicalResourceId :: Lens' StackEvent (Maybe Text)+seLogicalResourceId =+ lens _seLogicalResourceId (\s a -> s { _seLogicalResourceId = a })++-- | The name or unique identifier associated with the physical instance of+-- the resource.+sePhysicalResourceId :: Lens' StackEvent (Maybe Text)+sePhysicalResourceId =+ lens _sePhysicalResourceId (\s a -> s { _sePhysicalResourceId = a })++-- | BLOB of the properties used to create the resource.+seResourceProperties :: Lens' StackEvent (Maybe Text)+seResourceProperties =+ lens _seResourceProperties (\s a -> s { _seResourceProperties = a })++-- | Current status of the resource.+seResourceStatus :: Lens' StackEvent (Maybe Text)+seResourceStatus = lens _seResourceStatus (\s a -> s { _seResourceStatus = a })++-- | Success/failure message associated with the resource.+seResourceStatusReason :: Lens' StackEvent (Maybe Text)+seResourceStatusReason =+ lens _seResourceStatusReason (\s a -> s { _seResourceStatusReason = a })++-- | Type of resource. (For more information, go to AWS Resource Types+-- Reference in the AWS CloudFormation User Guide.).+seResourceType :: Lens' StackEvent (Maybe Text)+seResourceType = lens _seResourceType (\s a -> s { _seResourceType = a })++-- | The unique ID name of the instance of the stack.+seStackId :: Lens' StackEvent Text+seStackId = lens _seStackId (\s a -> s { _seStackId = a })++-- | The name associated with a stack.+seStackName :: Lens' StackEvent Text+seStackName = lens _seStackName (\s a -> s { _seStackName = a })++-- | Time the status was updated.+seTimestamp :: Lens' StackEvent UTCTime+seTimestamp = lens _seTimestamp (\s a -> s { _seTimestamp = a }) . _Time++instance FromXML StackEvent where+ parseXML x = StackEvent+ <$> x .@ "EventId"+ <*> x .@? "LogicalResourceId"+ <*> x .@? "PhysicalResourceId"+ <*> x .@? "ResourceProperties"+ <*> x .@? "ResourceStatus"+ <*> x .@? "ResourceStatusReason"+ <*> x .@? "ResourceType"+ <*> x .@ "StackId"+ <*> x .@ "StackName"+ <*> x .@ "Timestamp"++instance ToQuery StackEvent where+ toQuery StackEvent{..} = mconcat+ [ "EventId" =? _seEventId+ , "LogicalResourceId" =? _seLogicalResourceId+ , "PhysicalResourceId" =? _sePhysicalResourceId+ , "ResourceProperties" =? _seResourceProperties+ , "ResourceStatus" =? _seResourceStatus+ , "ResourceStatusReason" =? _seResourceStatusReason+ , "ResourceType" =? _seResourceType+ , "StackId" =? _seStackId+ , "StackName" =? _seStackName+ , "Timestamp" =? _seTimestamp+ ]++data StackSummary = StackSummary+ { _ssCreationTime :: RFC822+ , _ssDeletionTime :: Maybe RFC822+ , _ssLastUpdatedTime :: Maybe RFC822+ , _ssStackId :: Maybe Text+ , _ssStackName :: Text+ , _ssStackStatus :: Text+ , _ssStackStatusReason :: Maybe Text+ , _ssTemplateDescription :: Maybe Text+ } deriving (Eq, Ord, Show)++-- | 'StackSummary' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'ssCreationTime' @::@ 'UTCTime'+--+-- * 'ssDeletionTime' @::@ 'Maybe' 'UTCTime'+--+-- * 'ssLastUpdatedTime' @::@ 'Maybe' 'UTCTime'+--+-- * 'ssStackId' @::@ 'Maybe' 'Text'+--+-- * 'ssStackName' @::@ 'Text'+--+-- * 'ssStackStatus' @::@ 'Text'+--+-- * 'ssStackStatusReason' @::@ 'Maybe' 'Text'+--+-- * 'ssTemplateDescription' @::@ 'Maybe' 'Text'+--+stackSummary :: Text -- ^ 'ssStackName'+ -> UTCTime -- ^ 'ssCreationTime'+ -> Text -- ^ 'ssStackStatus'+ -> StackSummary+stackSummary p1 p2 p3 = StackSummary+ { _ssStackName = p1+ , _ssCreationTime = withIso _Time (const id) p2+ , _ssStackStatus = p3+ , _ssStackId = Nothing+ , _ssTemplateDescription = Nothing+ , _ssLastUpdatedTime = Nothing+ , _ssDeletionTime = Nothing+ , _ssStackStatusReason = Nothing+ }++-- | The time the stack was created.+ssCreationTime :: Lens' StackSummary UTCTime+ssCreationTime = lens _ssCreationTime (\s a -> s { _ssCreationTime = a }) . _Time++-- | The time the stack was deleted.+ssDeletionTime :: Lens' StackSummary (Maybe UTCTime)+ssDeletionTime = lens _ssDeletionTime (\s a -> s { _ssDeletionTime = a }) . mapping _Time++-- | The time the stack was last updated. This field will only be returned if+-- the stack has been updated at least once.+ssLastUpdatedTime :: Lens' StackSummary (Maybe UTCTime)+ssLastUpdatedTime =+ lens _ssLastUpdatedTime (\s a -> s { _ssLastUpdatedTime = a })+ . mapping _Time++-- | Unique stack identifier.+ssStackId :: Lens' StackSummary (Maybe Text)+ssStackId = lens _ssStackId (\s a -> s { _ssStackId = a })++-- | The name associated with the stack.+ssStackName :: Lens' StackSummary Text+ssStackName = lens _ssStackName (\s a -> s { _ssStackName = a })++-- | The current status of the stack.+ssStackStatus :: Lens' StackSummary Text+ssStackStatus = lens _ssStackStatus (\s a -> s { _ssStackStatus = a })++-- | Success/Failure message associated with the stack status.+ssStackStatusReason :: Lens' StackSummary (Maybe Text)+ssStackStatusReason =+ lens _ssStackStatusReason (\s a -> s { _ssStackStatusReason = a })++-- | The template description of the template used to create the stack.+ssTemplateDescription :: Lens' StackSummary (Maybe Text)+ssTemplateDescription =+ lens _ssTemplateDescription (\s a -> s { _ssTemplateDescription = a })++instance FromXML StackSummary where+ parseXML x = StackSummary+ <$> x .@ "CreationTime"+ <*> x .@? "DeletionTime"+ <*> x .@? "LastUpdatedTime"+ <*> x .@? "StackId"+ <*> x .@ "StackName"+ <*> x .@ "StackStatus"+ <*> x .@? "StackStatusReason"+ <*> x .@? "TemplateDescription"++instance ToQuery StackSummary where+ toQuery StackSummary{..} = mconcat+ [ "CreationTime" =? _ssCreationTime+ , "DeletionTime" =? _ssDeletionTime+ , "LastUpdatedTime" =? _ssLastUpdatedTime+ , "StackId" =? _ssStackId+ , "StackName" =? _ssStackName+ , "StackStatus" =? _ssStackStatus+ , "StackStatusReason" =? _ssStackStatusReason+ , "TemplateDescription" =? _ssTemplateDescription+ ]++data StackResourceDetail = StackResourceDetail+ { _srdDescription :: Maybe Text+ , _srdLastUpdatedTimestamp :: RFC822+ , _srdLogicalResourceId :: Text+ , _srdMetadata :: Maybe Text+ , _srdPhysicalResourceId :: Maybe Text+ , _srdResourceStatus :: Text+ , _srdResourceStatusReason :: Maybe Text+ , _srdResourceType :: Text+ , _srdStackId :: Maybe Text+ , _srdStackName :: Maybe Text+ } deriving (Eq, Ord, Show)++-- | 'StackResourceDetail' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'srdDescription' @::@ 'Maybe' 'Text'+--+-- * 'srdLastUpdatedTimestamp' @::@ 'UTCTime'+--+-- * 'srdLogicalResourceId' @::@ 'Text'+--+-- * 'srdMetadata' @::@ 'Maybe' 'Text'+--+-- * 'srdPhysicalResourceId' @::@ 'Maybe' 'Text'+--+-- * 'srdResourceStatus' @::@ 'Text'+--+-- * 'srdResourceStatusReason' @::@ 'Maybe' 'Text'+--+-- * 'srdResourceType' @::@ 'Text'+--+-- * 'srdStackId' @::@ 'Maybe' 'Text'+--+-- * 'srdStackName' @::@ 'Maybe' 'Text'+--+stackResourceDetail :: Text -- ^ 'srdLogicalResourceId'+ -> Text -- ^ 'srdResourceType'+ -> UTCTime -- ^ 'srdLastUpdatedTimestamp'+ -> Text -- ^ 'srdResourceStatus'+ -> StackResourceDetail+stackResourceDetail p1 p2 p3 p4 = StackResourceDetail+ { _srdLogicalResourceId = p1+ , _srdResourceType = p2+ , _srdLastUpdatedTimestamp = withIso _Time (const id) p3+ , _srdResourceStatus = p4+ , _srdStackName = Nothing+ , _srdStackId = Nothing+ , _srdPhysicalResourceId = Nothing+ , _srdResourceStatusReason = Nothing+ , _srdDescription = Nothing+ , _srdMetadata = Nothing+ }++-- | User defined description associated with the resource.+srdDescription :: Lens' StackResourceDetail (Maybe Text)+srdDescription = lens _srdDescription (\s a -> s { _srdDescription = a })++-- | Time the status was updated.+srdLastUpdatedTimestamp :: Lens' StackResourceDetail UTCTime+srdLastUpdatedTimestamp =+ lens _srdLastUpdatedTimestamp (\s a -> s { _srdLastUpdatedTimestamp = a })+ . _Time++-- | The logical name of the resource specified in the template.+srdLogicalResourceId :: Lens' StackResourceDetail Text+srdLogicalResourceId =+ lens _srdLogicalResourceId (\s a -> s { _srdLogicalResourceId = a })++-- | The JSON format content of the Metadata attribute declared for the+-- resource. For more information, see Metadata Attribute in the AWS+-- CloudFormation User Guide.+srdMetadata :: Lens' StackResourceDetail (Maybe Text)+srdMetadata = lens _srdMetadata (\s a -> s { _srdMetadata = a })++-- | The name or unique identifier that corresponds to a physical instance ID+-- of a resource supported by AWS CloudFormation.+srdPhysicalResourceId :: Lens' StackResourceDetail (Maybe Text)+srdPhysicalResourceId =+ lens _srdPhysicalResourceId (\s a -> s { _srdPhysicalResourceId = a })++-- | Current status of the resource.+srdResourceStatus :: Lens' StackResourceDetail Text+srdResourceStatus =+ lens _srdResourceStatus (\s a -> s { _srdResourceStatus = a })++-- | Success/failure message associated with the resource.+srdResourceStatusReason :: Lens' StackResourceDetail (Maybe Text)+srdResourceStatusReason =+ lens _srdResourceStatusReason (\s a -> s { _srdResourceStatusReason = a })++-- | Type of resource. ((For more information, go to AWS Resource Types+-- Reference in the AWS CloudFormation User Guide.).+srdResourceType :: Lens' StackResourceDetail Text+srdResourceType = lens _srdResourceType (\s a -> s { _srdResourceType = a })++-- | Unique identifier of the stack.+srdStackId :: Lens' StackResourceDetail (Maybe Text)+srdStackId = lens _srdStackId (\s a -> s { _srdStackId = a })++-- | The name associated with the stack.+srdStackName :: Lens' StackResourceDetail (Maybe Text)+srdStackName = lens _srdStackName (\s a -> s { _srdStackName = a })++instance FromXML StackResourceDetail where+ parseXML x = StackResourceDetail+ <$> x .@? "Description"+ <*> x .@ "LastUpdatedTimestamp"+ <*> x .@ "LogicalResourceId"+ <*> x .@? "Metadata"+ <*> x .@? "PhysicalResourceId"+ <*> x .@ "ResourceStatus"+ <*> x .@? "ResourceStatusReason"+ <*> x .@ "ResourceType"+ <*> x .@? "StackId"+ <*> x .@? "StackName"++instance ToQuery StackResourceDetail where+ toQuery StackResourceDetail{..} = mconcat+ [ "Description" =? _srdDescription+ , "LastUpdatedTimestamp" =? _srdLastUpdatedTimestamp+ , "LogicalResourceId" =? _srdLogicalResourceId+ , "Metadata" =? _srdMetadata+ , "PhysicalResourceId" =? _srdPhysicalResourceId+ , "ResourceStatus" =? _srdResourceStatus+ , "ResourceStatusReason" =? _srdResourceStatusReason+ , "ResourceType" =? _srdResourceType+ , "StackId" =? _srdStackId+ , "StackName" =? _srdStackName+ ]++data ResourceStatus+ = RSCreateComplete -- ^ CREATE_COMPLETE+ | RSCreateFailed -- ^ CREATE_FAILED+ | RSCreateInProgress -- ^ CREATE_IN_PROGRESS+ | RSDeleteComplete -- ^ DELETE_COMPLETE+ | RSDeleteFailed -- ^ DELETE_FAILED+ | RSDeleteInProgress -- ^ DELETE_IN_PROGRESS+ | RSDeleteSkipped -- ^ DELETE_SKIPPED+ | RSUpdateComplete -- ^ UPDATE_COMPLETE+ | RSUpdateFailed -- ^ UPDATE_FAILED+ | RSUpdateInProgress -- ^ UPDATE_IN_PROGRESS+ deriving (Eq, Ord, Show, Generic, Enum)++instance Hashable ResourceStatus++instance FromText ResourceStatus where+ parser = match "CREATE_COMPLETE" RSCreateComplete+ <|> match "CREATE_FAILED" RSCreateFailed+ <|> match "CREATE_IN_PROGRESS" RSCreateInProgress+ <|> match "DELETE_COMPLETE" RSDeleteComplete+ <|> match "DELETE_FAILED" RSDeleteFailed+ <|> match "DELETE_IN_PROGRESS" RSDeleteInProgress+ <|> match "DELETE_SKIPPED" RSDeleteSkipped+ <|> match "UPDATE_COMPLETE" RSUpdateComplete+ <|> match "UPDATE_FAILED" RSUpdateFailed+ <|> match "UPDATE_IN_PROGRESS" RSUpdateInProgress++instance ToText ResourceStatus where+ toText = \case+ RSCreateComplete -> "CREATE_COMPLETE"+ RSCreateFailed -> "CREATE_FAILED"+ RSCreateInProgress -> "CREATE_IN_PROGRESS"+ RSDeleteComplete -> "DELETE_COMPLETE"+ RSDeleteFailed -> "DELETE_FAILED"+ RSDeleteInProgress -> "DELETE_IN_PROGRESS"+ RSDeleteSkipped -> "DELETE_SKIPPED"+ RSUpdateComplete -> "UPDATE_COMPLETE"+ RSUpdateFailed -> "UPDATE_FAILED"+ RSUpdateInProgress -> "UPDATE_IN_PROGRESS"++instance FromXML ResourceStatus where+ parseXML = parseXMLText "ResourceStatus"++instance ToQuery ResourceStatus where+ toQuery = toQuery . toText++data TemplateParameter = TemplateParameter+ { _tpDefaultValue :: Maybe Text+ , _tpDescription :: Maybe Text+ , _tpNoEcho :: Maybe Bool+ , _tpParameterKey :: Maybe Text+ } deriving (Eq, Ord, Show)++-- | 'TemplateParameter' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'tpDefaultValue' @::@ 'Maybe' 'Text'+--+-- * 'tpDescription' @::@ 'Maybe' 'Text'+--+-- * 'tpNoEcho' @::@ 'Maybe' 'Bool'+--+-- * 'tpParameterKey' @::@ 'Maybe' 'Text'+--+templateParameter :: TemplateParameter+templateParameter = TemplateParameter+ { _tpParameterKey = Nothing+ , _tpDefaultValue = Nothing+ , _tpNoEcho = Nothing+ , _tpDescription = Nothing+ }++-- | The default value associated with the parameter.+tpDefaultValue :: Lens' TemplateParameter (Maybe Text)+tpDefaultValue = lens _tpDefaultValue (\s a -> s { _tpDefaultValue = a })++-- | User defined description associated with the parameter.+tpDescription :: Lens' TemplateParameter (Maybe Text)+tpDescription = lens _tpDescription (\s a -> s { _tpDescription = a })++-- | Flag indicating whether the parameter should be displayed as plain text+-- in logs and UIs.+tpNoEcho :: Lens' TemplateParameter (Maybe Bool)+tpNoEcho = lens _tpNoEcho (\s a -> s { _tpNoEcho = a })++-- | The name associated with the parameter.+tpParameterKey :: Lens' TemplateParameter (Maybe Text)+tpParameterKey = lens _tpParameterKey (\s a -> s { _tpParameterKey = a })++instance FromXML TemplateParameter where+ parseXML x = TemplateParameter+ <$> x .@? "DefaultValue"+ <*> x .@? "Description"+ <*> x .@? "NoEcho"+ <*> x .@? "ParameterKey"++instance ToQuery TemplateParameter where+ toQuery TemplateParameter{..} = mconcat+ [ "DefaultValue" =? _tpDefaultValue+ , "Description" =? _tpDescription+ , "NoEcho" =? _tpNoEcho+ , "ParameterKey" =? _tpParameterKey+ ]++data ParameterDeclaration = ParameterDeclaration+ { _pdDefaultValue :: Maybe Text+ , _pdDescription :: Maybe Text+ , _pdNoEcho :: Maybe Bool+ , _pdParameterKey :: Maybe Text+ , _pdParameterType :: Maybe Text+ } deriving (Eq, Ord, Show)++-- | 'ParameterDeclaration' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'pdDefaultValue' @::@ 'Maybe' 'Text'+--+-- * 'pdDescription' @::@ 'Maybe' 'Text'+--+-- * 'pdNoEcho' @::@ 'Maybe' 'Bool'+--+-- * 'pdParameterKey' @::@ 'Maybe' 'Text'+--+-- * 'pdParameterType' @::@ 'Maybe' 'Text'+--+parameterDeclaration :: ParameterDeclaration+parameterDeclaration = ParameterDeclaration+ { _pdParameterKey = Nothing+ , _pdDefaultValue = Nothing+ , _pdParameterType = Nothing+ , _pdNoEcho = Nothing+ , _pdDescription = Nothing+ }++-- | The default value of the parameter.+pdDefaultValue :: Lens' ParameterDeclaration (Maybe Text)+pdDefaultValue = lens _pdDefaultValue (\s a -> s { _pdDefaultValue = a })++-- | The description that is associate with the parameter.+pdDescription :: Lens' ParameterDeclaration (Maybe Text)+pdDescription = lens _pdDescription (\s a -> s { _pdDescription = a })++-- | Flag that indicates whether the parameter value is shown as plain text in+-- logs and in the AWS Management Console.+pdNoEcho :: Lens' ParameterDeclaration (Maybe Bool)+pdNoEcho = lens _pdNoEcho (\s a -> s { _pdNoEcho = a })++-- | The name that is associated with the parameter.+pdParameterKey :: Lens' ParameterDeclaration (Maybe Text)+pdParameterKey = lens _pdParameterKey (\s a -> s { _pdParameterKey = a })++-- | The type of parameter.+pdParameterType :: Lens' ParameterDeclaration (Maybe Text)+pdParameterType = lens _pdParameterType (\s a -> s { _pdParameterType = a })++instance FromXML ParameterDeclaration where+ parseXML x = ParameterDeclaration+ <$> x .@? "DefaultValue"+ <*> x .@? "Description"+ <*> x .@? "NoEcho"+ <*> x .@? "ParameterKey"+ <*> x .@? "ParameterType"++instance ToQuery ParameterDeclaration where+ toQuery ParameterDeclaration{..} = mconcat+ [ "DefaultValue" =? _pdDefaultValue+ , "Description" =? _pdDescription+ , "NoEcho" =? _pdNoEcho+ , "ParameterKey" =? _pdParameterKey+ , "ParameterType" =? _pdParameterType+ ]++data StackResource = StackResource+ { _sr1Description :: Maybe Text+ , _sr1LogicalResourceId :: Text+ , _sr1PhysicalResourceId :: Maybe Text+ , _sr1ResourceStatus :: Text+ , _sr1ResourceStatusReason :: Maybe Text+ , _sr1ResourceType :: Text+ , _sr1StackId :: Maybe Text+ , _sr1StackName :: Maybe Text+ , _sr1Timestamp :: RFC822+ } deriving (Eq, Ord, Show)++-- | 'StackResource' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'sr1Description' @::@ 'Maybe' 'Text'+--+-- * 'sr1LogicalResourceId' @::@ 'Text'+--+-- * 'sr1PhysicalResourceId' @::@ 'Maybe' 'Text'+--+-- * 'sr1ResourceStatus' @::@ 'Text'+--+-- * 'sr1ResourceStatusReason' @::@ 'Maybe' 'Text'+--+-- * 'sr1ResourceType' @::@ 'Text'+--+-- * 'sr1StackId' @::@ 'Maybe' 'Text'+--+-- * 'sr1StackName' @::@ 'Maybe' 'Text'+--+-- * 'sr1Timestamp' @::@ 'UTCTime'+--+stackResource :: Text -- ^ 'sr1LogicalResourceId'+ -> Text -- ^ 'sr1ResourceType'+ -> UTCTime -- ^ 'sr1Timestamp'+ -> Text -- ^ 'sr1ResourceStatus'+ -> StackResource+stackResource p1 p2 p3 p4 = StackResource+ { _sr1LogicalResourceId = p1+ , _sr1ResourceType = p2+ , _sr1Timestamp = withIso _Time (const id) p3+ , _sr1ResourceStatus = p4+ , _sr1StackName = Nothing+ , _sr1StackId = Nothing+ , _sr1PhysicalResourceId = Nothing+ , _sr1ResourceStatusReason = Nothing+ , _sr1Description = Nothing+ }++-- | User defined description associated with the resource.+sr1Description :: Lens' StackResource (Maybe Text)+sr1Description = lens _sr1Description (\s a -> s { _sr1Description = a })++-- | The logical name of the resource specified in the template.+sr1LogicalResourceId :: Lens' StackResource Text+sr1LogicalResourceId =+ lens _sr1LogicalResourceId (\s a -> s { _sr1LogicalResourceId = a })++-- | The name or unique identifier that corresponds to a physical instance ID+-- of a resource supported by AWS CloudFormation.+sr1PhysicalResourceId :: Lens' StackResource (Maybe Text)+sr1PhysicalResourceId =+ lens _sr1PhysicalResourceId (\s a -> s { _sr1PhysicalResourceId = a })++-- | Current status of the resource.+sr1ResourceStatus :: Lens' StackResource Text+sr1ResourceStatus =+ lens _sr1ResourceStatus (\s a -> s { _sr1ResourceStatus = a })++-- | Success/failure message associated with the resource.+sr1ResourceStatusReason :: Lens' StackResource (Maybe Text)+sr1ResourceStatusReason =+ lens _sr1ResourceStatusReason (\s a -> s { _sr1ResourceStatusReason = a })++-- | Type of resource. (For more information, go to AWS Resource Types+-- Reference in the AWS CloudFormation User Guide.).+sr1ResourceType :: Lens' StackResource Text+sr1ResourceType = lens _sr1ResourceType (\s a -> s { _sr1ResourceType = a })++-- | Unique identifier of the stack.+sr1StackId :: Lens' StackResource (Maybe Text)+sr1StackId = lens _sr1StackId (\s a -> s { _sr1StackId = a })++-- | The name associated with the stack.+sr1StackName :: Lens' StackResource (Maybe Text)+sr1StackName = lens _sr1StackName (\s a -> s { _sr1StackName = a })++-- | Time the status was updated.+sr1Timestamp :: Lens' StackResource UTCTime+sr1Timestamp = lens _sr1Timestamp (\s a -> s { _sr1Timestamp = a }) . _Time++instance FromXML StackResource where+ parseXML x = StackResource+ <$> x .@? "Description"+ <*> x .@ "LogicalResourceId"+ <*> x .@? "PhysicalResourceId"+ <*> x .@ "ResourceStatus"+ <*> x .@? "ResourceStatusReason"+ <*> x .@ "ResourceType"+ <*> x .@? "StackId"+ <*> x .@? "StackName"+ <*> x .@ "Timestamp"++instance ToQuery StackResource where+ toQuery StackResource{..} = mconcat+ [ "Description" =? _sr1Description+ , "LogicalResourceId" =? _sr1LogicalResourceId+ , "PhysicalResourceId" =? _sr1PhysicalResourceId+ , "ResourceStatus" =? _sr1ResourceStatus+ , "ResourceStatusReason" =? _sr1ResourceStatusReason+ , "ResourceType" =? _sr1ResourceType+ , "StackId" =? _sr1StackId+ , "StackName" =? _sr1StackName+ , "Timestamp" =? _sr1Timestamp+ ]++data Output = Output+ { _oDescription :: Maybe Text+ , _oOutputKey :: Maybe Text+ , _oOutputValue :: Maybe Text+ } deriving (Eq, Ord, Show)++-- | 'Output' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'oDescription' @::@ 'Maybe' 'Text'+--+-- * 'oOutputKey' @::@ 'Maybe' 'Text'+--+-- * 'oOutputValue' @::@ 'Maybe' 'Text'+--+output :: Output+output = Output+ { _oOutputKey = Nothing+ , _oOutputValue = Nothing+ , _oDescription = Nothing+ }++-- | User defined description associated with the output.+oDescription :: Lens' Output (Maybe Text)+oDescription = lens _oDescription (\s a -> s { _oDescription = a })++-- | The key associated with the output.+oOutputKey :: Lens' Output (Maybe Text)+oOutputKey = lens _oOutputKey (\s a -> s { _oOutputKey = a })++-- | The value associated with the output.+oOutputValue :: Lens' Output (Maybe Text)+oOutputValue = lens _oOutputValue (\s a -> s { _oOutputValue = a })++instance FromXML Output where+ parseXML x = Output+ <$> x .@? "Description"+ <*> x .@? "OutputKey"+ <*> x .@? "OutputValue"++instance ToQuery Output where+ toQuery Output{..} = mconcat+ [ "Description" =? _oDescription+ , "OutputKey" =? _oOutputKey+ , "OutputValue" =? _oOutputValue+ ]++data StackResourceSummary = StackResourceSummary+ { _srsLastUpdatedTimestamp :: RFC822+ , _srsLogicalResourceId :: Text+ , _srsPhysicalResourceId :: Maybe Text+ , _srsResourceStatus :: Text+ , _srsResourceStatusReason :: Maybe Text+ , _srsResourceType :: Text+ } deriving (Eq, Ord, Show)++-- | 'StackResourceSummary' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'srsLastUpdatedTimestamp' @::@ 'UTCTime'+--+-- * 'srsLogicalResourceId' @::@ 'Text'+--+-- * 'srsPhysicalResourceId' @::@ 'Maybe' 'Text'+--+-- * 'srsResourceStatus' @::@ 'Text'+--+-- * 'srsResourceStatusReason' @::@ 'Maybe' 'Text'+--+-- * 'srsResourceType' @::@ 'Text'+--+stackResourceSummary :: Text -- ^ 'srsLogicalResourceId'+ -> Text -- ^ 'srsResourceType'+ -> UTCTime -- ^ 'srsLastUpdatedTimestamp'+ -> Text -- ^ 'srsResourceStatus'+ -> StackResourceSummary+stackResourceSummary p1 p2 p3 p4 = StackResourceSummary+ { _srsLogicalResourceId = p1+ , _srsResourceType = p2+ , _srsLastUpdatedTimestamp = withIso _Time (const id) p3+ , _srsResourceStatus = p4+ , _srsPhysicalResourceId = Nothing+ , _srsResourceStatusReason = Nothing+ }++-- | Time the status was updated.+srsLastUpdatedTimestamp :: Lens' StackResourceSummary UTCTime+srsLastUpdatedTimestamp =+ lens _srsLastUpdatedTimestamp (\s a -> s { _srsLastUpdatedTimestamp = a })+ . _Time++-- | The logical name of the resource specified in the template.+srsLogicalResourceId :: Lens' StackResourceSummary Text+srsLogicalResourceId =+ lens _srsLogicalResourceId (\s a -> s { _srsLogicalResourceId = a })++-- | The name or unique identifier that corresponds to a physical instance ID+-- of the resource.+srsPhysicalResourceId :: Lens' StackResourceSummary (Maybe Text)+srsPhysicalResourceId =+ lens _srsPhysicalResourceId (\s a -> s { _srsPhysicalResourceId = a })++-- | Current status of the resource.+srsResourceStatus :: Lens' StackResourceSummary Text+srsResourceStatus =+ lens _srsResourceStatus (\s a -> s { _srsResourceStatus = a })++-- | Success/failure message associated with the resource.+srsResourceStatusReason :: Lens' StackResourceSummary (Maybe Text)+srsResourceStatusReason =+ lens _srsResourceStatusReason (\s a -> s { _srsResourceStatusReason = a })++-- | Type of resource. (For more information, go to AWS Resource Types+-- Reference in the AWS CloudFormation User Guide.).+srsResourceType :: Lens' StackResourceSummary Text+srsResourceType = lens _srsResourceType (\s a -> s { _srsResourceType = a })++instance FromXML StackResourceSummary where+ parseXML x = StackResourceSummary+ <$> x .@ "LastUpdatedTimestamp"+ <*> x .@ "LogicalResourceId"+ <*> x .@? "PhysicalResourceId"+ <*> x .@ "ResourceStatus"+ <*> x .@? "ResourceStatusReason"+ <*> x .@ "ResourceType"++instance ToQuery StackResourceSummary where+ toQuery StackResourceSummary{..} = mconcat+ [ "LastUpdatedTimestamp" =? _srsLastUpdatedTimestamp+ , "LogicalResourceId" =? _srsLogicalResourceId+ , "PhysicalResourceId" =? _srsPhysicalResourceId+ , "ResourceStatus" =? _srsResourceStatus+ , "ResourceStatusReason" =? _srsResourceStatusReason+ , "ResourceType" =? _srsResourceType+ ]++data Capability+ = CapabilityIam -- ^ CAPABILITY_IAM+ deriving (Eq, Ord, Show, Generic, Enum)++instance Hashable Capability++instance FromText Capability where+ parser = match "CAPABILITY_IAM" CapabilityIam++instance ToText Capability where+ toText CapabilityIam = "CAPABILITY_IAM"++instance FromXML Capability where+ parseXML = parseXMLText "Capability"++instance ToQuery Capability where+ toQuery = toQuery . toText++data ResourceSignalStatus+ = Failure -- ^ FAILURE+ | Success -- ^ SUCCESS+ deriving (Eq, Ord, Show, Generic, Enum)++instance Hashable ResourceSignalStatus++instance FromText ResourceSignalStatus where+ parser = match "FAILURE" Failure+ <|> match "SUCCESS" Success++instance ToText ResourceSignalStatus where+ toText = \case+ Failure -> "FAILURE"+ Success -> "SUCCESS"++instance FromXML ResourceSignalStatus where+ parseXML = parseXMLText "ResourceSignalStatus"++instance ToQuery ResourceSignalStatus where+ toQuery = toQuery . toText++data Stack = Stack+ { _sCapabilities :: List "Capabilities" Text+ , _sCreationTime :: RFC822+ , _sDescription :: Maybe Text+ , _sDisableRollback :: Maybe Bool+ , _sLastUpdatedTime :: Maybe RFC822+ , _sNotificationARNs :: List "NotificationARNs" Text+ , _sOutputs :: List "Outputs" Output+ , _sParameters :: List "Parameters" Parameter+ , _sStackId :: Maybe Text+ , _sStackName :: Text+ , _sStackStatus :: Text+ , _sStackStatusReason :: Maybe Text+ , _sTags :: List "Tags" Tag+ , _sTimeoutInMinutes :: Maybe Nat+ } deriving (Eq, Show)++-- | 'Stack' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'sCapabilities' @::@ ['Text']+--+-- * 'sCreationTime' @::@ 'UTCTime'+--+-- * 'sDescription' @::@ 'Maybe' 'Text'+--+-- * 'sDisableRollback' @::@ 'Maybe' 'Bool'+--+-- * 'sLastUpdatedTime' @::@ 'Maybe' 'UTCTime'+--+-- * 'sNotificationARNs' @::@ ['Text']+--+-- * 'sOutputs' @::@ ['Output']+--+-- * 'sParameters' @::@ ['Parameter']+--+-- * 'sStackId' @::@ 'Maybe' 'Text'+--+-- * 'sStackName' @::@ 'Text'+--+-- * 'sStackStatus' @::@ 'Text'+--+-- * 'sStackStatusReason' @::@ 'Maybe' 'Text'+--+-- * 'sTags' @::@ ['Tag']+--+-- * 'sTimeoutInMinutes' @::@ 'Maybe' 'Natural'+--+stack :: Text -- ^ 'sStackName'+ -> UTCTime -- ^ 'sCreationTime'+ -> Text -- ^ 'sStackStatus'+ -> Stack+stack p1 p2 p3 = Stack+ { _sStackName = p1+ , _sCreationTime = withIso _Time (const id) p2+ , _sStackStatus = p3+ , _sStackId = Nothing+ , _sDescription = Nothing+ , _sParameters = mempty+ , _sLastUpdatedTime = Nothing+ , _sStackStatusReason = Nothing+ , _sDisableRollback = Nothing+ , _sNotificationARNs = mempty+ , _sTimeoutInMinutes = Nothing+ , _sCapabilities = mempty+ , _sOutputs = mempty+ , _sTags = mempty+ }++-- | The capabilities allowed in the stack.+sCapabilities :: Lens' Stack [Text]+sCapabilities = lens _sCapabilities (\s a -> s { _sCapabilities = a }) . _List++-- | Time at which the stack was created.+sCreationTime :: Lens' Stack UTCTime+sCreationTime = lens _sCreationTime (\s a -> s { _sCreationTime = a }) . _Time++-- | User defined description associated with the stack.+sDescription :: Lens' Stack (Maybe Text)+sDescription = lens _sDescription (\s a -> s { _sDescription = a })++-- | Boolean to enable or disable rollback on stack creation failures: true:+-- disable rollback false: enable rollback.+sDisableRollback :: Lens' Stack (Maybe Bool)+sDisableRollback = lens _sDisableRollback (\s a -> s { _sDisableRollback = a })++-- | The time the stack was last updated. This field will only be returned if+-- the stack has been updated at least once.+sLastUpdatedTime :: Lens' Stack (Maybe UTCTime)+sLastUpdatedTime = lens _sLastUpdatedTime (\s a -> s { _sLastUpdatedTime = a }) . mapping _Time++-- | SNS topic ARNs to which stack related events are published.+sNotificationARNs :: Lens' Stack [Text]+sNotificationARNs =+ lens _sNotificationARNs (\s a -> s { _sNotificationARNs = a })+ . _List++-- | A list of output structures.+sOutputs :: Lens' Stack [Output]+sOutputs = lens _sOutputs (\s a -> s { _sOutputs = a }) . _List++-- | A list of Parameter structures.+sParameters :: Lens' Stack [Parameter]+sParameters = lens _sParameters (\s a -> s { _sParameters = a }) . _List++-- | Unique identifier of the stack.+sStackId :: Lens' Stack (Maybe Text)+sStackId = lens _sStackId (\s a -> s { _sStackId = a })++-- | The name associated with the stack.+sStackName :: Lens' Stack Text+sStackName = lens _sStackName (\s a -> s { _sStackName = a })++-- | Current status of the stack.+sStackStatus :: Lens' Stack Text+sStackStatus = lens _sStackStatus (\s a -> s { _sStackStatus = a })++-- | Success/failure message associated with the stack status.+sStackStatusReason :: Lens' Stack (Maybe Text)+sStackStatusReason =+ lens _sStackStatusReason (\s a -> s { _sStackStatusReason = a })++-- | A list of Tags that specify cost allocation information for the stack.+sTags :: Lens' Stack [Tag]+sTags = lens _sTags (\s a -> s { _sTags = a }) . _List++-- | The amount of time within which stack creation should complete.+sTimeoutInMinutes :: Lens' Stack (Maybe Natural)+sTimeoutInMinutes =+ lens _sTimeoutInMinutes (\s a -> s { _sTimeoutInMinutes = a })+ . mapping _Nat++instance FromXML Stack where+ parseXML x = Stack+ <$> x .@ "Capabilities"+ <*> x .@ "CreationTime"+ <*> x .@? "Description"+ <*> x .@? "DisableRollback"+ <*> x .@? "LastUpdatedTime"+ <*> x .@ "NotificationARNs"+ <*> x .@ "Outputs"+ <*> x .@ "Parameters"+ <*> x .@? "StackId"+ <*> x .@ "StackName"+ <*> x .@ "StackStatus"+ <*> x .@? "StackStatusReason"+ <*> x .@ "Tags"+ <*> x .@? "TimeoutInMinutes"++instance ToQuery Stack where+ toQuery Stack{..} = mconcat+ [ "Capabilities" =? _sCapabilities+ , "CreationTime" =? _sCreationTime+ , "Description" =? _sDescription+ , "DisableRollback" =? _sDisableRollback+ , "LastUpdatedTime" =? _sLastUpdatedTime+ , "NotificationARNs" =? _sNotificationARNs+ , "Outputs" =? _sOutputs+ , "Parameters" =? _sParameters+ , "StackId" =? _sStackId+ , "StackName" =? _sStackName+ , "StackStatus" =? _sStackStatus+ , "StackStatusReason" =? _sStackStatusReason+ , "Tags" =? _sTags+ , "TimeoutInMinutes" =? _sTimeoutInMinutes+ ]++data OnFailure+ = Delete' -- ^ DELETE+ | DoNothing -- ^ DO_NOTHING+ | Rollback -- ^ ROLLBACK+ deriving (Eq, Ord, Show, Generic, Enum)++instance Hashable OnFailure++instance FromText OnFailure where+ parser = match "DELETE" Delete'+ <|> match "DO_NOTHING" DoNothing+ <|> match "ROLLBACK" Rollback++instance ToText OnFailure where+ toText = \case+ Delete' -> "DELETE"+ DoNothing -> "DO_NOTHING"+ Rollback -> "ROLLBACK"++instance FromXML OnFailure where+ parseXML = parseXMLText "OnFailure"++instance ToQuery OnFailure where+ toQuery = toQuery . toText++data Parameter = Parameter+ { _pParameterKey :: Maybe Text+ , _pParameterValue :: Maybe Text+ , _pUsePreviousValue :: Maybe Bool+ } deriving (Eq, Ord, Show)++-- | 'Parameter' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'pParameterKey' @::@ 'Maybe' 'Text'+--+-- * 'pParameterValue' @::@ 'Maybe' 'Text'+--+-- * 'pUsePreviousValue' @::@ 'Maybe' 'Bool'+--+parameter :: Parameter+parameter = Parameter+ { _pParameterKey = Nothing+ , _pParameterValue = Nothing+ , _pUsePreviousValue = Nothing+ }++-- | The key associated with the parameter.+pParameterKey :: Lens' Parameter (Maybe Text)+pParameterKey = lens _pParameterKey (\s a -> s { _pParameterKey = a })++-- | The value associated with the parameter.+pParameterValue :: Lens' Parameter (Maybe Text)+pParameterValue = lens _pParameterValue (\s a -> s { _pParameterValue = a })++-- | During a stack update, use the existing parameter value that is being+-- used for the stack.+pUsePreviousValue :: Lens' Parameter (Maybe Bool)+pUsePreviousValue =+ lens _pUsePreviousValue (\s a -> s { _pUsePreviousValue = a })++instance FromXML Parameter where+ parseXML x = Parameter+ <$> x .@? "ParameterKey"+ <*> x .@? "ParameterValue"+ <*> x .@? "UsePreviousValue"++instance ToQuery Parameter where+ toQuery Parameter{..} = mconcat+ [ "ParameterKey" =? _pParameterKey+ , "ParameterValue" =? _pParameterValue+ , "UsePreviousValue" =? _pUsePreviousValue+ ]
+ gen/Network/AWS/CloudFormation/UpdateStack.hs view
@@ -0,0 +1,268 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE FlexibleInstances #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE TypeFamilies #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Module : Network.AWS.CloudFormation.UpdateStack+-- Copyright : (c) 2013-2014 Brendan Hay <brendan.g.hay@gmail.com>+-- License : This Source Code Form is subject to the terms of+-- the Mozilla Public License, v. 2.0.+-- A copy of the MPL can be found in the LICENSE file or+-- you can obtain it at http://mozilla.org/MPL/2.0/.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : experimental+-- Portability : non-portable (GHC extensions)++-- | Updates a stack as specified in the template. After the call completes+-- successfully, the stack update starts. You can check the status of the+-- stack via the DescribeStacks action. To get a copy of the template for an+-- existing stack, you can use the GetTemplate action. Tags that were+-- associated with this stack during creation time will still be associated+-- with the stack after an UpdateStack operation. For more information about+-- creating an update template, updating a stack, and monitoring the progress+-- of the update, see Updating a Stack.+--+-- <http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_UpdateStack.html>+module Network.AWS.CloudFormation.UpdateStack+ (+ -- * Request+ UpdateStack+ -- ** Request constructor+ , updateStack+ -- ** Request lenses+ , usCapabilities+ , usNotificationARNs+ , usParameters+ , usStackName+ , usStackPolicyBody+ , usStackPolicyDuringUpdateBody+ , usStackPolicyDuringUpdateURL+ , usStackPolicyURL+ , usTemplateBody+ , usTemplateURL+ , usUsePreviousTemplate++ -- * Response+ , UpdateStackResponse+ -- ** Response constructor+ , updateStackResponse+ -- ** Response lenses+ , usrStackId+ ) where++import Network.AWS.Prelude+import Network.AWS.Request.Query+import Network.AWS.CloudFormation.Types+import qualified GHC.Exts++data UpdateStack = UpdateStack+ { _usCapabilities :: List "Capabilities" Text+ , _usNotificationARNs :: List "NotificationARNs" Text+ , _usParameters :: List "Parameters" Parameter+ , _usStackName :: Text+ , _usStackPolicyBody :: Maybe Text+ , _usStackPolicyDuringUpdateBody :: Maybe Text+ , _usStackPolicyDuringUpdateURL :: Maybe Text+ , _usStackPolicyURL :: Maybe Text+ , _usTemplateBody :: Maybe Text+ , _usTemplateURL :: Maybe Text+ , _usUsePreviousTemplate :: Maybe Bool+ } deriving (Eq, Show)++-- | 'UpdateStack' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'usCapabilities' @::@ ['Text']+--+-- * 'usNotificationARNs' @::@ ['Text']+--+-- * 'usParameters' @::@ ['Parameter']+--+-- * 'usStackName' @::@ 'Text'+--+-- * 'usStackPolicyBody' @::@ 'Maybe' 'Text'+--+-- * 'usStackPolicyDuringUpdateBody' @::@ 'Maybe' 'Text'+--+-- * 'usStackPolicyDuringUpdateURL' @::@ 'Maybe' 'Text'+--+-- * 'usStackPolicyURL' @::@ 'Maybe' 'Text'+--+-- * 'usTemplateBody' @::@ 'Maybe' 'Text'+--+-- * 'usTemplateURL' @::@ 'Maybe' 'Text'+--+-- * 'usUsePreviousTemplate' @::@ 'Maybe' 'Bool'+--+updateStack :: Text -- ^ 'usStackName'+ -> UpdateStack+updateStack p1 = UpdateStack+ { _usStackName = p1+ , _usTemplateBody = Nothing+ , _usTemplateURL = Nothing+ , _usUsePreviousTemplate = Nothing+ , _usStackPolicyDuringUpdateBody = Nothing+ , _usStackPolicyDuringUpdateURL = Nothing+ , _usParameters = mempty+ , _usCapabilities = mempty+ , _usStackPolicyBody = Nothing+ , _usStackPolicyURL = Nothing+ , _usNotificationARNs = mempty+ }++-- | A list of capabilities that you must specify before AWS CloudFormation+-- can create or update certain stacks. Some stack templates might include+-- resources that can affect permissions in your AWS account. For those+-- stacks, you must explicitly acknowledge their capabilities by specifying+-- this parameter. Currently, the only valid value is CAPABILITY_IAM, which+-- is required for the following resources: AWS::CloudFormation::Stack,+-- AWS::IAM::AccessKey, AWS::IAM::Group, AWS::IAM::InstanceProfile,+-- AWS::IAM::Policy, AWS::IAM::Role, AWS::IAM::User, and+-- AWS::IAM::UserToGroupAddition. If your stack template contains these+-- resources, we recommend that you review any permissions associated with+-- them. If you don't specify this parameter, this action returns an+-- InsufficientCapabilities error.+usCapabilities :: Lens' UpdateStack [Text]+usCapabilities = lens _usCapabilities (\s a -> s { _usCapabilities = a }) . _List++-- | Update the ARNs for the Amazon SNS topics that are associated with the+-- stack.+usNotificationARNs :: Lens' UpdateStack [Text]+usNotificationARNs =+ lens _usNotificationARNs (\s a -> s { _usNotificationARNs = a })+ . _List++-- | A list of Parameter structures that specify input parameters for the+-- stack.+usParameters :: Lens' UpdateStack [Parameter]+usParameters = lens _usParameters (\s a -> s { _usParameters = a }) . _List++-- | The name or stack ID of the stack to update. Must contain only+-- alphanumeric characters (case sensitive) and start with an alpha+-- character. Maximum length of the name is 255 characters.+usStackName :: Lens' UpdateStack Text+usStackName = lens _usStackName (\s a -> s { _usStackName = a })++-- | Structure containing a new stack policy body. You can specify either the+-- StackPolicyBody or the StackPolicyURL parameter, but not both. You might+-- update the stack policy, for example, in order to protect a new resource+-- that you created during a stack update. If you do not specify a stack+-- policy, the current policy that is associated with the stack is+-- unchanged.+usStackPolicyBody :: Lens' UpdateStack (Maybe Text)+usStackPolicyBody =+ lens _usStackPolicyBody (\s a -> s { _usStackPolicyBody = a })++-- | Structure containing the temporary overriding stack policy body. You can+-- specify either the StackPolicyDuringUpdateBody or the+-- StackPolicyDuringUpdateURL parameter, but not both. If you want to update+-- protected resources, specify a temporary overriding stack policy during+-- this update. If you do not specify a stack policy, the current policy+-- that is associated with the stack will be used.+usStackPolicyDuringUpdateBody :: Lens' UpdateStack (Maybe Text)+usStackPolicyDuringUpdateBody =+ lens _usStackPolicyDuringUpdateBody+ (\s a -> s { _usStackPolicyDuringUpdateBody = a })++-- | Location of a file containing the temporary overriding stack policy. The+-- URL must point to a policy (max size: 16KB) located in an S3 bucket in+-- the same region as the stack. You can specify either the+-- StackPolicyDuringUpdateBody or the StackPolicyDuringUpdateURL parameter,+-- but not both. If you want to update protected resources, specify a+-- temporary overriding stack policy during this update. If you do not+-- specify a stack policy, the current policy that is associated with the+-- stack will be used.+usStackPolicyDuringUpdateURL :: Lens' UpdateStack (Maybe Text)+usStackPolicyDuringUpdateURL =+ lens _usStackPolicyDuringUpdateURL+ (\s a -> s { _usStackPolicyDuringUpdateURL = a })++-- | Location of a file containing the updated stack policy. The URL must+-- point to a policy (max size: 16KB) located in an S3 bucket in the same+-- region as the stack. You can specify either the StackPolicyBody or the+-- StackPolicyURL parameter, but not both. You might update the stack+-- policy, for example, in order to protect a new resource that you created+-- during a stack update. If you do not specify a stack policy, the current+-- policy that is associated with the stack is unchanged.+usStackPolicyURL :: Lens' UpdateStack (Maybe Text)+usStackPolicyURL = lens _usStackPolicyURL (\s a -> s { _usStackPolicyURL = a })++-- | Structure containing the template body with a minimum length of 1 byte+-- and a maximum length of 51,200 bytes. (For more information, go to+-- Template Anatomy in the AWS CloudFormation User Guide.) Conditional: You+-- must specify either the TemplateBody or the TemplateURL parameter, but+-- not both.+usTemplateBody :: Lens' UpdateStack (Maybe Text)+usTemplateBody = lens _usTemplateBody (\s a -> s { _usTemplateBody = a })++-- | Location of file containing the template body. The URL must point to a+-- template located in an S3 bucket in the same region as the stack. For+-- more information, go to Template Anatomy in the AWS CloudFormation User+-- Guide. Conditional: You must specify either the TemplateBody or the+-- TemplateURL parameter, but not both.+usTemplateURL :: Lens' UpdateStack (Maybe Text)+usTemplateURL = lens _usTemplateURL (\s a -> s { _usTemplateURL = a })++-- | Reuse the existing template that is associated with the stack that you+-- are updating.+usUsePreviousTemplate :: Lens' UpdateStack (Maybe Bool)+usUsePreviousTemplate =+ lens _usUsePreviousTemplate (\s a -> s { _usUsePreviousTemplate = a })++newtype UpdateStackResponse = UpdateStackResponse+ { _usrStackId :: Maybe Text+ } deriving (Eq, Ord, Show, Monoid)++-- | 'UpdateStackResponse' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'usrStackId' @::@ 'Maybe' 'Text'+--+updateStackResponse :: UpdateStackResponse+updateStackResponse = UpdateStackResponse+ { _usrStackId = Nothing+ }++-- | Unique identifier of the stack.+usrStackId :: Lens' UpdateStackResponse (Maybe Text)+usrStackId = lens _usrStackId (\s a -> s { _usrStackId = a })++instance ToPath UpdateStack where+ toPath = const "/"++instance ToQuery UpdateStack where+ toQuery UpdateStack{..} = mconcat+ [ "Capabilities" =? _usCapabilities+ , "NotificationARNs" =? _usNotificationARNs+ , "Parameters" =? _usParameters+ , "StackName" =? _usStackName+ , "StackPolicyBody" =? _usStackPolicyBody+ , "StackPolicyDuringUpdateBody" =? _usStackPolicyDuringUpdateBody+ , "StackPolicyDuringUpdateURL" =? _usStackPolicyDuringUpdateURL+ , "StackPolicyURL" =? _usStackPolicyURL+ , "TemplateBody" =? _usTemplateBody+ , "TemplateURL" =? _usTemplateURL+ , "UsePreviousTemplate" =? _usUsePreviousTemplate+ ]++instance ToHeaders UpdateStack++instance AWSRequest UpdateStack where+ type Sv UpdateStack = CloudFormation+ type Rs UpdateStack = UpdateStackResponse++ request = post "UpdateStack"+ response = xmlResponse++instance FromXML UpdateStackResponse where+ parseXML = withElement "UpdateStackResult" $ \x -> UpdateStackResponse+ <$> x .@? "StackId"
+ gen/Network/AWS/CloudFormation/ValidateTemplate.hs view
@@ -0,0 +1,159 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE FlexibleInstances #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE TypeFamilies #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Module : Network.AWS.CloudFormation.ValidateTemplate+-- Copyright : (c) 2013-2014 Brendan Hay <brendan.g.hay@gmail.com>+-- License : This Source Code Form is subject to the terms of+-- the Mozilla Public License, v. 2.0.+-- A copy of the MPL can be found in the LICENSE file or+-- you can obtain it at http://mozilla.org/MPL/2.0/.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : experimental+-- Portability : non-portable (GHC extensions)++-- | Validates a specified template.+--+-- <http://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_ValidateTemplate.html>+module Network.AWS.CloudFormation.ValidateTemplate+ (+ -- * Request+ ValidateTemplate+ -- ** Request constructor+ , validateTemplate+ -- ** Request lenses+ , vtTemplateBody+ , vtTemplateURL++ -- * Response+ , ValidateTemplateResponse+ -- ** Response constructor+ , validateTemplateResponse+ -- ** Response lenses+ , vtrCapabilities+ , vtrCapabilitiesReason+ , vtrDescription+ , vtrParameters+ ) where++import Network.AWS.Prelude+import Network.AWS.Request.Query+import Network.AWS.CloudFormation.Types+import qualified GHC.Exts++data ValidateTemplate = ValidateTemplate+ { _vtTemplateBody :: Maybe Text+ , _vtTemplateURL :: Maybe Text+ } deriving (Eq, Ord, Show)++-- | 'ValidateTemplate' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'vtTemplateBody' @::@ 'Maybe' 'Text'+--+-- * 'vtTemplateURL' @::@ 'Maybe' 'Text'+--+validateTemplate :: ValidateTemplate+validateTemplate = ValidateTemplate+ { _vtTemplateBody = Nothing+ , _vtTemplateURL = Nothing+ }++-- | Structure containing the template body with a minimum length of 1 byte+-- and a maximum length of 51,200 bytes. For more information, go to+-- Template Anatomy in the AWS CloudFormation User Guide. Conditional: You+-- must pass TemplateURL or TemplateBody. If both are passed, only+-- TemplateBody is used.+vtTemplateBody :: Lens' ValidateTemplate (Maybe Text)+vtTemplateBody = lens _vtTemplateBody (\s a -> s { _vtTemplateBody = a })++-- | Location of file containing the template body. The URL must point to a+-- template (max size: 307,200 bytes) located in an S3 bucket in the same+-- region as the stack. For more information, go to Template Anatomy in the+-- AWS CloudFormation User Guide. Conditional: You must pass TemplateURL or+-- TemplateBody. If both are passed, only TemplateBody is used.+vtTemplateURL :: Lens' ValidateTemplate (Maybe Text)+vtTemplateURL = lens _vtTemplateURL (\s a -> s { _vtTemplateURL = a })++data ValidateTemplateResponse = ValidateTemplateResponse+ { _vtrCapabilities :: List "Capabilities" Text+ , _vtrCapabilitiesReason :: Maybe Text+ , _vtrDescription :: Maybe Text+ , _vtrParameters :: List "Parameters" TemplateParameter+ } deriving (Eq, Show)++-- | 'ValidateTemplateResponse' constructor.+--+-- The fields accessible through corresponding lenses are:+--+-- * 'vtrCapabilities' @::@ ['Text']+--+-- * 'vtrCapabilitiesReason' @::@ 'Maybe' 'Text'+--+-- * 'vtrDescription' @::@ 'Maybe' 'Text'+--+-- * 'vtrParameters' @::@ ['TemplateParameter']+--+validateTemplateResponse :: ValidateTemplateResponse+validateTemplateResponse = ValidateTemplateResponse+ { _vtrParameters = mempty+ , _vtrDescription = Nothing+ , _vtrCapabilities = mempty+ , _vtrCapabilitiesReason = Nothing+ }++-- | The capabilities found within the template. Currently, AWS CloudFormation+-- supports only the CAPABILITY_IAM capability. If your template contains+-- IAM resources, you must specify the CAPABILITY_IAM value for this+-- parameter when you use the CreateStack or UpdateStack actions with your+-- template; otherwise, those actions return an InsufficientCapabilities+-- error.+vtrCapabilities :: Lens' ValidateTemplateResponse [Text]+vtrCapabilities = lens _vtrCapabilities (\s a -> s { _vtrCapabilities = a }) . _List++-- | The capabilities reason found within the template.+vtrCapabilitiesReason :: Lens' ValidateTemplateResponse (Maybe Text)+vtrCapabilitiesReason =+ lens _vtrCapabilitiesReason (\s a -> s { _vtrCapabilitiesReason = a })++-- | The description found within the template.+vtrDescription :: Lens' ValidateTemplateResponse (Maybe Text)+vtrDescription = lens _vtrDescription (\s a -> s { _vtrDescription = a })++-- | A list of TemplateParameter structures.+vtrParameters :: Lens' ValidateTemplateResponse [TemplateParameter]+vtrParameters = lens _vtrParameters (\s a -> s { _vtrParameters = a }) . _List++instance ToPath ValidateTemplate where+ toPath = const "/"++instance ToQuery ValidateTemplate where+ toQuery ValidateTemplate{..} = mconcat+ [ "TemplateBody" =? _vtTemplateBody+ , "TemplateURL" =? _vtTemplateURL+ ]++instance ToHeaders ValidateTemplate++instance AWSRequest ValidateTemplate where+ type Sv ValidateTemplate = CloudFormation+ type Rs ValidateTemplate = ValidateTemplateResponse++ request = post "ValidateTemplate"+ response = xmlResponse++instance FromXML ValidateTemplateResponse where+ parseXML = withElement "ValidateTemplateResult" $ \x -> ValidateTemplateResponse+ <$> x .@ "Capabilities"+ <*> x .@? "CapabilitiesReason"+ <*> x .@? "Description"+ <*> x .@ "Parameters"