packages feed

amazonka-mq (empty) → 1.6.0

raw patch · 65 files changed

+5368/−0 lines, 65 filesdep +amazonka-coredep +amazonka-mqdep +amazonka-testsetup-changed

Dependencies added: amazonka-core, amazonka-mq, amazonka-test, base, bytestring, tasty, tasty-hunit, text, time, unordered-containers

Files

+ LICENSE view
@@ -0,0 +1,367 @@+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.
+ README.md view
@@ -0,0 +1,45 @@+# Amazon MQ SDK++* [Version](#version)+* [Description](#description)+* [Contribute](#contribute)+* [Licence](#licence)+++## Version++`1.6.0`+++## Description++Documentation is available via [Hackage](http://hackage.haskell.org/package/amazonka-mq)+and the [AWS API Reference](https://aws.amazon.com/documentation/).++The types from this library are intended to be used with [amazonka](http://hackage.haskell.org/package/amazonka),+which provides mechanisms for specifying AuthN/AuthZ information, sending requests,+and receiving responses.++Lenses are used for constructing and manipulating types,+due to the depth of nesting of AWS types and transparency regarding+de/serialisation into more palatable Haskell values.+The provided lenses should be compatible with any of the major lens libraries+[lens](http://hackage.haskell.org/package/lens) or [lens-family-core](http://hackage.haskell.org/package/lens-family-core).++See [Network.AWS.MQ](http://hackage.haskell.org/package/amazonka-mq/docs/Network-AWS-MQ.html)+or [the AWS documentation](https://aws.amazon.com/documentation/) to get started.+++## 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-mq` is released under the [Mozilla Public License Version 2.0](http://www.mozilla.org/MPL/).++Parts of the code are derived from AWS service descriptions, licensed under Apache 2.0.+Source files subject to this contain an additional licensing clause in their header.
+ Setup.hs view
@@ -0,0 +1,2 @@+import           Distribution.Simple+main = defaultMain
+ amazonka-mq.cabal view
@@ -0,0 +1,102 @@+name:                  amazonka-mq+version:               1.6.0+synopsis:              Amazon MQ SDK.+homepage:              https://github.com/brendanhay/amazonka+bug-reports:           https://github.com/brendanhay/amazonka/issues+license:               MPL-2.0+license-file:          LICENSE+author:                Brendan Hay+maintainer:            Brendan Hay <brendan.g.hay+amazonka@gmail.com>+copyright:             Copyright (c) 2013-2018 Brendan Hay+category:              Network, AWS, Cloud, Distributed Computing+build-type:            Simple+cabal-version:         >= 1.10+extra-source-files:    README.md fixture/*.yaml fixture/*.proto src/.gitkeep+description:+    The types from this library are intended to be used with+    <http://hackage.haskell.org/package/amazonka amazonka>, which provides+    mechanisms for specifying AuthN/AuthZ information, sending requests,+    and receiving responses.+    .+    Lenses are used for constructing and manipulating types,+    due to the depth of nesting of AWS types and transparency regarding+    de/serialisation into more palatable Haskell values.+    The provided lenses should be compatible with any of the major lens libraries+    such as <http://hackage.haskell.org/package/lens lens> or+    <http://hackage.haskell.org/package/lens-family-core lens-family-core>.+    .+    See "Network.AWS.MQ" or <https://aws.amazon.com/documentation/ the AWS documentation>+    to get started.++source-repository head+    type:              git+    location:          git://github.com/brendanhay/amazonka.git+    subdir:            amazonka-mq++library+    default-language:  Haskell2010+    hs-source-dirs:    src gen++    ghc-options:+        -Wall+        -fwarn-incomplete-uni-patterns+        -fwarn-incomplete-record-updates+        -funbox-strict-fields++    exposed-modules:+          Network.AWS.MQ+        , Network.AWS.MQ.CreateBroker+        , Network.AWS.MQ.CreateConfiguration+        , Network.AWS.MQ.CreateUser+        , Network.AWS.MQ.DeleteBroker+        , Network.AWS.MQ.DeleteUser+        , Network.AWS.MQ.DescribeBroker+        , Network.AWS.MQ.DescribeConfiguration+        , Network.AWS.MQ.DescribeConfigurationRevision+        , Network.AWS.MQ.DescribeUser+        , Network.AWS.MQ.ListBrokers+        , Network.AWS.MQ.ListConfigurationRevisions+        , Network.AWS.MQ.ListConfigurations+        , Network.AWS.MQ.ListUsers+        , Network.AWS.MQ.RebootBroker+        , Network.AWS.MQ.Types+        , Network.AWS.MQ.UpdateBroker+        , Network.AWS.MQ.UpdateConfiguration+        , Network.AWS.MQ.UpdateUser+        , Network.AWS.MQ.Waiters++    other-modules:+          Network.AWS.MQ.Types.Product+        , Network.AWS.MQ.Types.Sum++    build-depends:+          amazonka-core == 1.6.0.*+        , base          >= 4.7     && < 5++test-suite amazonka-mq-test+    type:              exitcode-stdio-1.0+    default-language:  Haskell2010+    hs-source-dirs:    test+    main-is:           Main.hs++    ghc-options:       -Wall -threaded++    -- This section is encoded by the template and any modules added by+    -- hand outside these namespaces will not correctly be added to the+    -- distribution package.+    other-modules:+          Test.AWS.MQ+        , Test.AWS.Gen.MQ+        , Test.AWS.MQ.Internal++    build-depends:+          amazonka-core == 1.6.0.*+        , amazonka-test == 1.6.0.*+        , amazonka-mq+        , base+        , bytestring+        , tasty+        , tasty-hunit+        , text+        , time+        , unordered-containers
+ fixture/CreateBroker.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/mq/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  mq.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/CreateBrokerResponse.proto view
+ fixture/CreateConfiguration.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/mq/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  mq.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/CreateConfigurationResponse.proto view
+ fixture/CreateUser.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/mq/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  mq.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/CreateUserResponse.proto view
+ fixture/DeleteBroker.yaml view
@@ -0,0 +1,10 @@+---+method: DELETE+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/mq/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  mq.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/DeleteBrokerResponse.proto view
+ fixture/DeleteUser.yaml view
@@ -0,0 +1,10 @@+---+method: DELETE+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/mq/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  mq.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/DeleteUserResponse.proto view
+ fixture/DescribeBroker.yaml view
@@ -0,0 +1,10 @@+---+method: GET+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/mq/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  mq.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/DescribeBrokerResponse.proto view
+ fixture/DescribeConfiguration.yaml view
@@ -0,0 +1,10 @@+---+method: GET+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/mq/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  mq.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/DescribeConfigurationResponse.proto view
+ fixture/DescribeConfigurationRevision.yaml view
@@ -0,0 +1,10 @@+---+method: GET+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/mq/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  mq.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/DescribeConfigurationRevisionResponse.proto view
+ fixture/DescribeUser.yaml view
@@ -0,0 +1,10 @@+---+method: GET+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/mq/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  mq.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/DescribeUserResponse.proto view
+ fixture/ListBrokers.yaml view
@@ -0,0 +1,10 @@+---+method: GET+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/mq/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  mq.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/ListBrokersResponse.proto view
+ fixture/ListConfigurationRevisions.yaml view
@@ -0,0 +1,10 @@+---+method: GET+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/mq/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  mq.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/ListConfigurationRevisionsResponse.proto view
+ fixture/ListConfigurations.yaml view
@@ -0,0 +1,10 @@+---+method: GET+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/mq/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  mq.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/ListConfigurationsResponse.proto view
+ fixture/ListUsers.yaml view
@@ -0,0 +1,10 @@+---+method: GET+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/mq/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  mq.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/ListUsersResponse.proto view
+ fixture/RebootBroker.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/mq/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  mq.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/RebootBrokerResponse.proto view
+ fixture/UpdateBroker.yaml view
@@ -0,0 +1,10 @@+---+method: PUT+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/mq/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  mq.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/UpdateBrokerResponse.proto view
+ fixture/UpdateConfiguration.yaml view
@@ -0,0 +1,10 @@+---+method: PUT+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/mq/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  mq.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/UpdateConfigurationResponse.proto view
+ fixture/UpdateUser.yaml view
@@ -0,0 +1,10 @@+---+method: PUT+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/mq/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  mq.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/UpdateUserResponse.proto view
+ gen/Network/AWS/MQ.hs view
@@ -0,0 +1,248 @@+{-# OPTIONS_GHC -fno-warn-unused-imports    #-}+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Amazon MQ is a managed message broker service for Apache ActiveMQ that makes it easy to set up and operate message brokers in the cloud. A message broker allows software applications and components to communicate using various programming languages, operating systems, and formal messaging protocols.+module Network.AWS.MQ+    (+    -- * Service Configuration+      mq++    -- * Errors+    -- $errors++    -- ** ConflictException+    , _ConflictException++    -- ** ForbiddenException+    , _ForbiddenException++    -- ** NotFoundException+    , _NotFoundException++    -- ** InternalServerErrorException+    , _InternalServerErrorException++    -- ** UnauthorizedException+    , _UnauthorizedException++    -- ** BadRequestException+    , _BadRequestException++    -- * Waiters+    -- $waiters++    -- * Operations+    -- $operations++    -- ** CreateConfiguration+    , module Network.AWS.MQ.CreateConfiguration++    -- ** CreateBroker+    , module Network.AWS.MQ.CreateBroker++    -- ** DeleteBroker+    , module Network.AWS.MQ.DeleteBroker++    -- ** UpdateBroker+    , module Network.AWS.MQ.UpdateBroker++    -- ** RebootBroker+    , module Network.AWS.MQ.RebootBroker++    -- ** ListConfigurationRevisions+    , module Network.AWS.MQ.ListConfigurationRevisions++    -- ** ListUsers+    , module Network.AWS.MQ.ListUsers++    -- ** ListConfigurations+    , module Network.AWS.MQ.ListConfigurations++    -- ** DescribeUser+    , module Network.AWS.MQ.DescribeUser++    -- ** ListBrokers+    , module Network.AWS.MQ.ListBrokers++    -- ** CreateUser+    , module Network.AWS.MQ.CreateUser++    -- ** DescribeConfiguration+    , module Network.AWS.MQ.DescribeConfiguration++    -- ** UpdateUser+    , module Network.AWS.MQ.UpdateUser++    -- ** DeleteUser+    , module Network.AWS.MQ.DeleteUser++    -- ** DescribeConfigurationRevision+    , module Network.AWS.MQ.DescribeConfigurationRevision++    -- ** DescribeBroker+    , module Network.AWS.MQ.DescribeBroker++    -- ** UpdateConfiguration+    , module Network.AWS.MQ.UpdateConfiguration++    -- * Types++    -- ** BrokerState+    , BrokerState (..)++    -- ** ChangeType+    , ChangeType (..)++    -- ** DayOfWeek+    , DayOfWeek (..)++    -- ** DeploymentMode+    , DeploymentMode (..)++    -- ** EngineType+    , EngineType (..)++    -- ** SanitizationWarningReason+    , SanitizationWarningReason (..)++    -- ** BrokerInstance+    , BrokerInstance+    , brokerInstance+    , biConsoleURL+    , biEndpoints++    -- ** BrokerSummary+    , BrokerSummary+    , brokerSummary+    , bsBrokerName+    , bsBrokerState+    , bsDeploymentMode+    , bsBrokerId+    , bsBrokerARN+    , bsHostInstanceType++    -- ** Configuration+    , Configuration+    , configuration+    , cEngineVersion+    , cARN+    , cLatestRevision+    , cName+    , cId+    , cDescription+    , cEngineType++    -- ** ConfigurationId+    , ConfigurationId+    , configurationId+    , ciId+    , ciRevision++    -- ** ConfigurationRevision+    , ConfigurationRevision+    , configurationRevision+    , crRevision+    , crDescription++    -- ** Configurations+    , Configurations+    , configurations+    , cPending+    , cHistory+    , cCurrent++    -- ** SanitizationWarning+    , SanitizationWarning+    , sanitizationWarning+    , swReason+    , swAttributeName+    , swElementName++    -- ** User+    , User+    , user+    , uGroups+    , uConsoleAccess+    , uUsername+    , uPassword++    -- ** UserPendingChanges+    , UserPendingChanges+    , userPendingChanges+    , upcGroups+    , upcConsoleAccess+    , upcPendingChange++    -- ** UserSummary+    , UserSummary+    , userSummary+    , usUsername+    , usPendingChange++    -- ** WeeklyStartTime+    , WeeklyStartTime+    , weeklyStartTime+    , wstTimeOfDay+    , wstTimeZone+    , wstDayOfWeek+    ) where++import Network.AWS.MQ.CreateBroker+import Network.AWS.MQ.CreateConfiguration+import Network.AWS.MQ.CreateUser+import Network.AWS.MQ.DeleteBroker+import Network.AWS.MQ.DeleteUser+import Network.AWS.MQ.DescribeBroker+import Network.AWS.MQ.DescribeConfiguration+import Network.AWS.MQ.DescribeConfigurationRevision+import Network.AWS.MQ.DescribeUser+import Network.AWS.MQ.ListBrokers+import Network.AWS.MQ.ListConfigurationRevisions+import Network.AWS.MQ.ListConfigurations+import Network.AWS.MQ.ListUsers+import Network.AWS.MQ.RebootBroker+import Network.AWS.MQ.Types+import Network.AWS.MQ.UpdateBroker+import Network.AWS.MQ.UpdateConfiguration+import Network.AWS.MQ.UpdateUser+import Network.AWS.MQ.Waiters++{- $errors+Error matchers are designed for use with the functions provided by+<http://hackage.haskell.org/package/lens/docs/Control-Exception-Lens.html Control.Exception.Lens>.+This allows catching (and rethrowing) service specific errors returned+by 'MQ'.+-}++{- $operations+Some AWS operations return results that are incomplete and require subsequent+requests in order to obtain the entire result set. The process of sending+subsequent requests to continue where a previous request left off is called+pagination. For example, the 'ListObjects' operation of Amazon S3 returns up to+1000 objects at a time, and you must send subsequent requests with the+appropriate Marker in order to retrieve the next page of results.++Operations that have an 'AWSPager' instance can transparently perform subsequent+requests, correctly setting Markers and other request facets to iterate through+the entire result set of a truncated API operation. Operations which support+this have an additional note in the documentation.++Many operations have the ability to filter results on the server side. See the+individual operation parameters for details.+-}++{- $waiters+Waiters poll by repeatedly sending a request until some remote success condition+configured by the 'Wait' specification is fulfilled. The 'Wait' specification+determines how many attempts should be made, in addition to delay and retry strategies.+-}
+ gen/Network/AWS/MQ/CreateBroker.hs view
@@ -0,0 +1,266 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.CreateBroker+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Creates a broker. Note: This API is asynchronous.+module Network.AWS.MQ.CreateBroker+    (+    -- * Creating a Request+      createBroker+    , CreateBroker+    -- * Request Lenses+    , cbBrokerName+    , cbEngineVersion+    , cbPubliclyAccessible+    , cbAutoMinorVersionUpgrade+    , cbSecurityGroups+    , cbUsers+    , cbSubnetIds+    , cbCreatorRequestId+    , cbMaintenanceWindowStartTime+    , cbDeploymentMode+    , cbConfiguration+    , cbEngineType+    , cbHostInstanceType++    -- * Destructuring the Response+    , createBrokerResponse+    , CreateBrokerResponse+    -- * Response Lenses+    , cbrsBrokerId+    , cbrsBrokerARN+    , cbrsResponseStatus+    ) where++import Network.AWS.Lens+import Network.AWS.MQ.Types+import Network.AWS.MQ.Types.Product+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | Creates a broker using the specified properties.+--+-- /See:/ 'createBroker' smart constructor.+data CreateBroker = CreateBroker'+  { _cbBrokerName                 :: !(Maybe Text)+  , _cbEngineVersion              :: !(Maybe Text)+  , _cbPubliclyAccessible         :: !(Maybe Bool)+  , _cbAutoMinorVersionUpgrade    :: !(Maybe Bool)+  , _cbSecurityGroups             :: !(Maybe [Text])+  , _cbUsers                      :: !(Maybe [User])+  , _cbSubnetIds                  :: !(Maybe [Text])+  , _cbCreatorRequestId           :: !(Maybe Text)+  , _cbMaintenanceWindowStartTime :: !(Maybe WeeklyStartTime)+  , _cbDeploymentMode             :: !(Maybe DeploymentMode)+  , _cbConfiguration              :: !(Maybe ConfigurationId)+  , _cbEngineType                 :: !(Maybe EngineType)+  , _cbHostInstanceType           :: !(Maybe Text)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'CreateBroker' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'cbBrokerName' - Required. The name of the broker. This value must be unique in your AWS account, 1-50 characters long, must contain only letters, numbers, dashes, and underscores, and must not contain whitespaces, brackets, wildcard characters, or special characters.+--+-- * 'cbEngineVersion' - Required. The version of the broker engine. Note: Currently, Amazon MQ supports only 5.15.0.+--+-- * 'cbPubliclyAccessible' - Required. Enables connections from applications outside of the VPC that hosts the broker's subnets.+--+-- * 'cbAutoMinorVersionUpgrade' - Required. Enables automatic upgrades to new minor versions for brokers, as Apache releases the versions. The automatic upgrades occur during the maintenance window of the broker or after a manual broker reboot.+--+-- * 'cbSecurityGroups' - Required. The list of rules (1 minimum, 125 maximum) that authorize connections to brokers.+--+-- * 'cbUsers' - Required. The list of ActiveMQ users (persons or applications) who can access queues and topics. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+--+-- * 'cbSubnetIds' - Required. The list of groups (2 maximum) that define which subnets and IP ranges the broker can use from different Availability Zones. A SINGLE_INSTANCE deployment requires one subnet (for example, the default subnet). An ACTIVE_STANDBY_MULTI_AZ deployment requires two subnets.+--+-- * 'cbCreatorRequestId' - The unique ID that the requester receives for the created broker. Amazon MQ passes your ID with the API action. Note: We recommend using a Universally Unique Identifier (UUID) for the creatorRequestId. You may omit the creatorRequestId if your application doesn't require idempotency.+--+-- * 'cbMaintenanceWindowStartTime' - The parameters that determine the WeeklyStartTime.+--+-- * 'cbDeploymentMode' - Required. The deployment mode of the broker. Possible values: SINGLE_INSTANCE, ACTIVE_STANDBY_MULTI_AZ SINGLE_INSTANCE creates a single-instance broker in a single Availability Zone. ACTIVE_STANDBY_MULTI_AZ creates an active/standby broker for high availability.+--+-- * 'cbConfiguration' - A list of information about the configuration.+--+-- * 'cbEngineType' - Required. The type of broker engine. Note: Currently, Amazon MQ supports only ACTIVEMQ.+--+-- * 'cbHostInstanceType' - Required. The broker's instance type. Possible values: mq.t2.micro, mq.m4.large+createBroker+    :: CreateBroker+createBroker =+  CreateBroker'+    { _cbBrokerName = Nothing+    , _cbEngineVersion = Nothing+    , _cbPubliclyAccessible = Nothing+    , _cbAutoMinorVersionUpgrade = Nothing+    , _cbSecurityGroups = Nothing+    , _cbUsers = Nothing+    , _cbSubnetIds = Nothing+    , _cbCreatorRequestId = Nothing+    , _cbMaintenanceWindowStartTime = Nothing+    , _cbDeploymentMode = Nothing+    , _cbConfiguration = Nothing+    , _cbEngineType = Nothing+    , _cbHostInstanceType = Nothing+    }+++-- | Required. The name of the broker. This value must be unique in your AWS account, 1-50 characters long, must contain only letters, numbers, dashes, and underscores, and must not contain whitespaces, brackets, wildcard characters, or special characters.+cbBrokerName :: Lens' CreateBroker (Maybe Text)+cbBrokerName = lens _cbBrokerName (\ s a -> s{_cbBrokerName = a})++-- | Required. The version of the broker engine. Note: Currently, Amazon MQ supports only 5.15.0.+cbEngineVersion :: Lens' CreateBroker (Maybe Text)+cbEngineVersion = lens _cbEngineVersion (\ s a -> s{_cbEngineVersion = a})++-- | Required. Enables connections from applications outside of the VPC that hosts the broker's subnets.+cbPubliclyAccessible :: Lens' CreateBroker (Maybe Bool)+cbPubliclyAccessible = lens _cbPubliclyAccessible (\ s a -> s{_cbPubliclyAccessible = a})++-- | Required. Enables automatic upgrades to new minor versions for brokers, as Apache releases the versions. The automatic upgrades occur during the maintenance window of the broker or after a manual broker reboot.+cbAutoMinorVersionUpgrade :: Lens' CreateBroker (Maybe Bool)+cbAutoMinorVersionUpgrade = lens _cbAutoMinorVersionUpgrade (\ s a -> s{_cbAutoMinorVersionUpgrade = a})++-- | Required. The list of rules (1 minimum, 125 maximum) that authorize connections to brokers.+cbSecurityGroups :: Lens' CreateBroker [Text]+cbSecurityGroups = lens _cbSecurityGroups (\ s a -> s{_cbSecurityGroups = a}) . _Default . _Coerce++-- | Required. The list of ActiveMQ users (persons or applications) who can access queues and topics. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+cbUsers :: Lens' CreateBroker [User]+cbUsers = lens _cbUsers (\ s a -> s{_cbUsers = a}) . _Default . _Coerce++-- | Required. The list of groups (2 maximum) that define which subnets and IP ranges the broker can use from different Availability Zones. A SINGLE_INSTANCE deployment requires one subnet (for example, the default subnet). An ACTIVE_STANDBY_MULTI_AZ deployment requires two subnets.+cbSubnetIds :: Lens' CreateBroker [Text]+cbSubnetIds = lens _cbSubnetIds (\ s a -> s{_cbSubnetIds = a}) . _Default . _Coerce++-- | The unique ID that the requester receives for the created broker. Amazon MQ passes your ID with the API action. Note: We recommend using a Universally Unique Identifier (UUID) for the creatorRequestId. You may omit the creatorRequestId if your application doesn't require idempotency.+cbCreatorRequestId :: Lens' CreateBroker (Maybe Text)+cbCreatorRequestId = lens _cbCreatorRequestId (\ s a -> s{_cbCreatorRequestId = a})++-- | The parameters that determine the WeeklyStartTime.+cbMaintenanceWindowStartTime :: Lens' CreateBroker (Maybe WeeklyStartTime)+cbMaintenanceWindowStartTime = lens _cbMaintenanceWindowStartTime (\ s a -> s{_cbMaintenanceWindowStartTime = a})++-- | Required. The deployment mode of the broker. Possible values: SINGLE_INSTANCE, ACTIVE_STANDBY_MULTI_AZ SINGLE_INSTANCE creates a single-instance broker in a single Availability Zone. ACTIVE_STANDBY_MULTI_AZ creates an active/standby broker for high availability.+cbDeploymentMode :: Lens' CreateBroker (Maybe DeploymentMode)+cbDeploymentMode = lens _cbDeploymentMode (\ s a -> s{_cbDeploymentMode = a})++-- | A list of information about the configuration.+cbConfiguration :: Lens' CreateBroker (Maybe ConfigurationId)+cbConfiguration = lens _cbConfiguration (\ s a -> s{_cbConfiguration = a})++-- | Required. The type of broker engine. Note: Currently, Amazon MQ supports only ACTIVEMQ.+cbEngineType :: Lens' CreateBroker (Maybe EngineType)+cbEngineType = lens _cbEngineType (\ s a -> s{_cbEngineType = a})++-- | Required. The broker's instance type. Possible values: mq.t2.micro, mq.m4.large+cbHostInstanceType :: Lens' CreateBroker (Maybe Text)+cbHostInstanceType = lens _cbHostInstanceType (\ s a -> s{_cbHostInstanceType = a})++instance AWSRequest CreateBroker where+        type Rs CreateBroker = CreateBrokerResponse+        request = postJSON mq+        response+          = receiveJSON+              (\ s h x ->+                 CreateBrokerResponse' <$>+                   (x .?> "brokerId") <*> (x .?> "brokerArn") <*>+                     (pure (fromEnum s)))++instance Hashable CreateBroker where++instance NFData CreateBroker where++instance ToHeaders CreateBroker where+        toHeaders+          = const+              (mconcat+                 ["Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToJSON CreateBroker where+        toJSON CreateBroker'{..}+          = object+              (catMaybes+                 [("brokerName" .=) <$> _cbBrokerName,+                  ("engineVersion" .=) <$> _cbEngineVersion,+                  ("publiclyAccessible" .=) <$> _cbPubliclyAccessible,+                  ("autoMinorVersionUpgrade" .=) <$>+                    _cbAutoMinorVersionUpgrade,+                  ("securityGroups" .=) <$> _cbSecurityGroups,+                  ("users" .=) <$> _cbUsers,+                  ("subnetIds" .=) <$> _cbSubnetIds,+                  ("creatorRequestId" .=) <$> _cbCreatorRequestId,+                  ("maintenanceWindowStartTime" .=) <$>+                    _cbMaintenanceWindowStartTime,+                  ("deploymentMode" .=) <$> _cbDeploymentMode,+                  ("configuration" .=) <$> _cbConfiguration,+                  ("engineType" .=) <$> _cbEngineType,+                  ("hostInstanceType" .=) <$> _cbHostInstanceType])++instance ToPath CreateBroker where+        toPath = const "/v1/brokers"++instance ToQuery CreateBroker where+        toQuery = const mempty++-- | /See:/ 'createBrokerResponse' smart constructor.+data CreateBrokerResponse = CreateBrokerResponse'+  { _cbrsBrokerId       :: !(Maybe Text)+  , _cbrsBrokerARN      :: !(Maybe Text)+  , _cbrsResponseStatus :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'CreateBrokerResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'cbrsBrokerId' - The unique ID that Amazon MQ generates for the broker.+--+-- * 'cbrsBrokerARN' - The Amazon Resource Name (ARN) of the broker.+--+-- * 'cbrsResponseStatus' - -- | The response status code.+createBrokerResponse+    :: Int -- ^ 'cbrsResponseStatus'+    -> CreateBrokerResponse+createBrokerResponse pResponseStatus_ =+  CreateBrokerResponse'+    { _cbrsBrokerId = Nothing+    , _cbrsBrokerARN = Nothing+    , _cbrsResponseStatus = pResponseStatus_+    }+++-- | The unique ID that Amazon MQ generates for the broker.+cbrsBrokerId :: Lens' CreateBrokerResponse (Maybe Text)+cbrsBrokerId = lens _cbrsBrokerId (\ s a -> s{_cbrsBrokerId = a})++-- | The Amazon Resource Name (ARN) of the broker.+cbrsBrokerARN :: Lens' CreateBrokerResponse (Maybe Text)+cbrsBrokerARN = lens _cbrsBrokerARN (\ s a -> s{_cbrsBrokerARN = a})++-- | -- | The response status code.+cbrsResponseStatus :: Lens' CreateBrokerResponse Int+cbrsResponseStatus = lens _cbrsResponseStatus (\ s a -> s{_cbrsResponseStatus = a})++instance NFData CreateBrokerResponse where
+ gen/Network/AWS/MQ/CreateConfiguration.hs view
@@ -0,0 +1,182 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.CreateConfiguration+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Creates a new configuration for the specified configuration name. Amazon MQ uses the default configuration (the engine type and version). Note: If the configuration name already exists, Amazon MQ doesn't create a configuration.+module Network.AWS.MQ.CreateConfiguration+    (+    -- * Creating a Request+      createConfiguration+    , CreateConfiguration+    -- * Request Lenses+    , ccEngineVersion+    , ccName+    , ccEngineType++    -- * Destructuring the Response+    , createConfigurationResponse+    , CreateConfigurationResponse+    -- * Response Lenses+    , ccrsARN+    , ccrsLatestRevision+    , ccrsName+    , ccrsId+    , ccrsResponseStatus+    ) where++import Network.AWS.Lens+import Network.AWS.MQ.Types+import Network.AWS.MQ.Types.Product+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | Creates a new configuration for the specified configuration name. Amazon MQ uses the default configuration (the engine type and version). Note: If the configuration name already exists, Amazon MQ doesn't create a configuration.+--+-- /See:/ 'createConfiguration' smart constructor.+data CreateConfiguration = CreateConfiguration'+  { _ccEngineVersion :: !(Maybe Text)+  , _ccName          :: !(Maybe Text)+  , _ccEngineType    :: !(Maybe EngineType)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'CreateConfiguration' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'ccEngineVersion' - Required. The version of the broker engine. Note: Currently, Amazon MQ supports only 5.15.0.+--+-- * 'ccName' - Required. The name of the configuration. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 1-150 characters long.+--+-- * 'ccEngineType' - Required. The type of broker engine. Note: Currently, Amazon MQ supports only ACTIVEMQ.+createConfiguration+    :: CreateConfiguration+createConfiguration =+  CreateConfiguration'+    {_ccEngineVersion = Nothing, _ccName = Nothing, _ccEngineType = Nothing}+++-- | Required. The version of the broker engine. Note: Currently, Amazon MQ supports only 5.15.0.+ccEngineVersion :: Lens' CreateConfiguration (Maybe Text)+ccEngineVersion = lens _ccEngineVersion (\ s a -> s{_ccEngineVersion = a})++-- | Required. The name of the configuration. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 1-150 characters long.+ccName :: Lens' CreateConfiguration (Maybe Text)+ccName = lens _ccName (\ s a -> s{_ccName = a})++-- | Required. The type of broker engine. Note: Currently, Amazon MQ supports only ACTIVEMQ.+ccEngineType :: Lens' CreateConfiguration (Maybe EngineType)+ccEngineType = lens _ccEngineType (\ s a -> s{_ccEngineType = a})++instance AWSRequest CreateConfiguration where+        type Rs CreateConfiguration =+             CreateConfigurationResponse+        request = postJSON mq+        response+          = receiveJSON+              (\ s h x ->+                 CreateConfigurationResponse' <$>+                   (x .?> "arn") <*> (x .?> "latestRevision") <*>+                     (x .?> "name")+                     <*> (x .?> "id")+                     <*> (pure (fromEnum s)))++instance Hashable CreateConfiguration where++instance NFData CreateConfiguration where++instance ToHeaders CreateConfiguration where+        toHeaders+          = const+              (mconcat+                 ["Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToJSON CreateConfiguration where+        toJSON CreateConfiguration'{..}+          = object+              (catMaybes+                 [("engineVersion" .=) <$> _ccEngineVersion,+                  ("name" .=) <$> _ccName,+                  ("engineType" .=) <$> _ccEngineType])++instance ToPath CreateConfiguration where+        toPath = const "/v1/configurations"++instance ToQuery CreateConfiguration where+        toQuery = const mempty++-- | /See:/ 'createConfigurationResponse' smart constructor.+data CreateConfigurationResponse = CreateConfigurationResponse'+  { _ccrsARN            :: !(Maybe Text)+  , _ccrsLatestRevision :: !(Maybe ConfigurationRevision)+  , _ccrsName           :: !(Maybe Text)+  , _ccrsId             :: !(Maybe Text)+  , _ccrsResponseStatus :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'CreateConfigurationResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'ccrsARN' - Required. The Amazon Resource Name (ARN) of the configuration.+--+-- * 'ccrsLatestRevision' - The latest revision of the configuration.+--+-- * 'ccrsName' - Required. The name of the configuration. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 1-150 characters long.+--+-- * 'ccrsId' - Required. The unique ID that Amazon MQ generates for the configuration.+--+-- * 'ccrsResponseStatus' - -- | The response status code.+createConfigurationResponse+    :: Int -- ^ 'ccrsResponseStatus'+    -> CreateConfigurationResponse+createConfigurationResponse pResponseStatus_ =+  CreateConfigurationResponse'+    { _ccrsARN = Nothing+    , _ccrsLatestRevision = Nothing+    , _ccrsName = Nothing+    , _ccrsId = Nothing+    , _ccrsResponseStatus = pResponseStatus_+    }+++-- | Required. The Amazon Resource Name (ARN) of the configuration.+ccrsARN :: Lens' CreateConfigurationResponse (Maybe Text)+ccrsARN = lens _ccrsARN (\ s a -> s{_ccrsARN = a})++-- | The latest revision of the configuration.+ccrsLatestRevision :: Lens' CreateConfigurationResponse (Maybe ConfigurationRevision)+ccrsLatestRevision = lens _ccrsLatestRevision (\ s a -> s{_ccrsLatestRevision = a})++-- | Required. The name of the configuration. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 1-150 characters long.+ccrsName :: Lens' CreateConfigurationResponse (Maybe Text)+ccrsName = lens _ccrsName (\ s a -> s{_ccrsName = a})++-- | Required. The unique ID that Amazon MQ generates for the configuration.+ccrsId :: Lens' CreateConfigurationResponse (Maybe Text)+ccrsId = lens _ccrsId (\ s a -> s{_ccrsId = a})++-- | -- | The response status code.+ccrsResponseStatus :: Lens' CreateConfigurationResponse Int+ccrsResponseStatus = lens _ccrsResponseStatus (\ s a -> s{_ccrsResponseStatus = a})++instance NFData CreateConfigurationResponse where
+ gen/Network/AWS/MQ/CreateUser.hs view
@@ -0,0 +1,165 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.CreateUser+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Creates an ActiveMQ user.+module Network.AWS.MQ.CreateUser+    (+    -- * Creating a Request+      createUser+    , CreateUser+    -- * Request Lenses+    , cuGroups+    , cuConsoleAccess+    , cuPassword+    , cuUsername+    , cuBrokerId++    -- * Destructuring the Response+    , createUserResponse+    , CreateUserResponse+    -- * Response Lenses+    , cursResponseStatus+    ) where++import Network.AWS.Lens+import Network.AWS.MQ.Types+import Network.AWS.MQ.Types.Product+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | Creates a new ActiveMQ user.+--+-- /See:/ 'createUser' smart constructor.+data CreateUser = CreateUser'+  { _cuGroups        :: !(Maybe [Text])+  , _cuConsoleAccess :: !(Maybe Bool)+  , _cuPassword      :: !(Maybe Text)+  , _cuUsername      :: !Text+  , _cuBrokerId      :: !Text+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'CreateUser' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'cuGroups' - The list of groups (20 maximum) to which the ActiveMQ user belongs. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+--+-- * 'cuConsoleAccess' - Enables access to the the ActiveMQ Web Console for the ActiveMQ user.+--+-- * 'cuPassword' - Required. The password of the user. This value must be at least 12 characters long, must contain at least 4 unique characters, and must not contain commas.+--+-- * 'cuUsername' - The username of the ActiveMQ user. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+--+-- * 'cuBrokerId' - The unique ID that Amazon MQ generates for the broker.+createUser+    :: Text -- ^ 'cuUsername'+    -> Text -- ^ 'cuBrokerId'+    -> CreateUser+createUser pUsername_ pBrokerId_ =+  CreateUser'+    { _cuGroups = Nothing+    , _cuConsoleAccess = Nothing+    , _cuPassword = Nothing+    , _cuUsername = pUsername_+    , _cuBrokerId = pBrokerId_+    }+++-- | The list of groups (20 maximum) to which the ActiveMQ user belongs. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+cuGroups :: Lens' CreateUser [Text]+cuGroups = lens _cuGroups (\ s a -> s{_cuGroups = a}) . _Default . _Coerce++-- | Enables access to the the ActiveMQ Web Console for the ActiveMQ user.+cuConsoleAccess :: Lens' CreateUser (Maybe Bool)+cuConsoleAccess = lens _cuConsoleAccess (\ s a -> s{_cuConsoleAccess = a})++-- | Required. The password of the user. This value must be at least 12 characters long, must contain at least 4 unique characters, and must not contain commas.+cuPassword :: Lens' CreateUser (Maybe Text)+cuPassword = lens _cuPassword (\ s a -> s{_cuPassword = a})++-- | The username of the ActiveMQ user. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+cuUsername :: Lens' CreateUser Text+cuUsername = lens _cuUsername (\ s a -> s{_cuUsername = a})++-- | The unique ID that Amazon MQ generates for the broker.+cuBrokerId :: Lens' CreateUser Text+cuBrokerId = lens _cuBrokerId (\ s a -> s{_cuBrokerId = a})++instance AWSRequest CreateUser where+        type Rs CreateUser = CreateUserResponse+        request = postJSON mq+        response+          = receiveEmpty+              (\ s h x ->+                 CreateUserResponse' <$> (pure (fromEnum s)))++instance Hashable CreateUser where++instance NFData CreateUser where++instance ToHeaders CreateUser where+        toHeaders+          = const+              (mconcat+                 ["Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToJSON CreateUser where+        toJSON CreateUser'{..}+          = object+              (catMaybes+                 [("groups" .=) <$> _cuGroups,+                  ("consoleAccess" .=) <$> _cuConsoleAccess,+                  ("password" .=) <$> _cuPassword])++instance ToPath CreateUser where+        toPath CreateUser'{..}+          = mconcat+              ["/v1/brokers/", toBS _cuBrokerId, "/users/",+               toBS _cuUsername]++instance ToQuery CreateUser where+        toQuery = const mempty++-- | /See:/ 'createUserResponse' smart constructor.+newtype CreateUserResponse = CreateUserResponse'+  { _cursResponseStatus :: Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'CreateUserResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'cursResponseStatus' - -- | The response status code.+createUserResponse+    :: Int -- ^ 'cursResponseStatus'+    -> CreateUserResponse+createUserResponse pResponseStatus_ =+  CreateUserResponse' {_cursResponseStatus = pResponseStatus_}+++-- | -- | The response status code.+cursResponseStatus :: Lens' CreateUserResponse Int+cursResponseStatus = lens _cursResponseStatus (\ s a -> s{_cursResponseStatus = a})++instance NFData CreateUserResponse where
+ gen/Network/AWS/MQ/DeleteBroker.hs view
@@ -0,0 +1,123 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.DeleteBroker+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Deletes a broker. Note: This API is asynchronous.+module Network.AWS.MQ.DeleteBroker+    (+    -- * Creating a Request+      deleteBroker+    , DeleteBroker+    -- * Request Lenses+    , dbBrokerId++    -- * Destructuring the Response+    , deleteBrokerResponse+    , DeleteBrokerResponse+    -- * Response Lenses+    , drsBrokerId+    , drsResponseStatus+    ) where++import Network.AWS.Lens+import Network.AWS.MQ.Types+import Network.AWS.MQ.Types.Product+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'deleteBroker' smart constructor.+newtype DeleteBroker = DeleteBroker'+  { _dbBrokerId :: Text+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DeleteBroker' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'dbBrokerId' - The name of the broker. This value must be unique in your AWS account, 1-50 characters long, must contain only letters, numbers, dashes, and underscores, and must not contain whitespaces, brackets, wildcard characters, or special characters.+deleteBroker+    :: Text -- ^ 'dbBrokerId'+    -> DeleteBroker+deleteBroker pBrokerId_ = DeleteBroker' {_dbBrokerId = pBrokerId_}+++-- | The name of the broker. This value must be unique in your AWS account, 1-50 characters long, must contain only letters, numbers, dashes, and underscores, and must not contain whitespaces, brackets, wildcard characters, or special characters.+dbBrokerId :: Lens' DeleteBroker Text+dbBrokerId = lens _dbBrokerId (\ s a -> s{_dbBrokerId = a})++instance AWSRequest DeleteBroker where+        type Rs DeleteBroker = DeleteBrokerResponse+        request = delete mq+        response+          = receiveJSON+              (\ s h x ->+                 DeleteBrokerResponse' <$>+                   (x .?> "brokerId") <*> (pure (fromEnum s)))++instance Hashable DeleteBroker where++instance NFData DeleteBroker where++instance ToHeaders DeleteBroker where+        toHeaders+          = const+              (mconcat+                 ["Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToPath DeleteBroker where+        toPath DeleteBroker'{..}+          = mconcat ["/v1/brokers/", toBS _dbBrokerId]++instance ToQuery DeleteBroker where+        toQuery = const mempty++-- | /See:/ 'deleteBrokerResponse' smart constructor.+data DeleteBrokerResponse = DeleteBrokerResponse'+  { _drsBrokerId       :: !(Maybe Text)+  , _drsResponseStatus :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DeleteBrokerResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'drsBrokerId' - The unique ID that Amazon MQ generates for the broker.+--+-- * 'drsResponseStatus' - -- | The response status code.+deleteBrokerResponse+    :: Int -- ^ 'drsResponseStatus'+    -> DeleteBrokerResponse+deleteBrokerResponse pResponseStatus_ =+  DeleteBrokerResponse'+    {_drsBrokerId = Nothing, _drsResponseStatus = pResponseStatus_}+++-- | The unique ID that Amazon MQ generates for the broker.+drsBrokerId :: Lens' DeleteBrokerResponse (Maybe Text)+drsBrokerId = lens _drsBrokerId (\ s a -> s{_drsBrokerId = a})++-- | -- | The response status code.+drsResponseStatus :: Lens' DeleteBrokerResponse Int+drsResponseStatus = lens _drsResponseStatus (\ s a -> s{_drsResponseStatus = a})++instance NFData DeleteBrokerResponse where
+ gen/Network/AWS/MQ/DeleteUser.hs view
@@ -0,0 +1,125 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.DeleteUser+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Deletes an ActiveMQ user.+module Network.AWS.MQ.DeleteUser+    (+    -- * Creating a Request+      deleteUser+    , DeleteUser+    -- * Request Lenses+    , dUsername+    , dBrokerId++    -- * Destructuring the Response+    , deleteUserResponse+    , DeleteUserResponse+    -- * Response Lenses+    , delrsResponseStatus+    ) where++import Network.AWS.Lens+import Network.AWS.MQ.Types+import Network.AWS.MQ.Types.Product+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'deleteUser' smart constructor.+data DeleteUser = DeleteUser'+  { _dUsername :: !Text+  , _dBrokerId :: !Text+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DeleteUser' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'dUsername' - The username of the ActiveMQ user. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+--+-- * 'dBrokerId' - The unique ID that Amazon MQ generates for the broker.+deleteUser+    :: Text -- ^ 'dUsername'+    -> Text -- ^ 'dBrokerId'+    -> DeleteUser+deleteUser pUsername_ pBrokerId_ =+  DeleteUser' {_dUsername = pUsername_, _dBrokerId = pBrokerId_}+++-- | The username of the ActiveMQ user. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+dUsername :: Lens' DeleteUser Text+dUsername = lens _dUsername (\ s a -> s{_dUsername = a})++-- | The unique ID that Amazon MQ generates for the broker.+dBrokerId :: Lens' DeleteUser Text+dBrokerId = lens _dBrokerId (\ s a -> s{_dBrokerId = a})++instance AWSRequest DeleteUser where+        type Rs DeleteUser = DeleteUserResponse+        request = delete mq+        response+          = receiveEmpty+              (\ s h x ->+                 DeleteUserResponse' <$> (pure (fromEnum s)))++instance Hashable DeleteUser where++instance NFData DeleteUser where++instance ToHeaders DeleteUser where+        toHeaders+          = const+              (mconcat+                 ["Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToPath DeleteUser where+        toPath DeleteUser'{..}+          = mconcat+              ["/v1/brokers/", toBS _dBrokerId, "/users/",+               toBS _dUsername]++instance ToQuery DeleteUser where+        toQuery = const mempty++-- | /See:/ 'deleteUserResponse' smart constructor.+newtype DeleteUserResponse = DeleteUserResponse'+  { _delrsResponseStatus :: Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DeleteUserResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'delrsResponseStatus' - -- | The response status code.+deleteUserResponse+    :: Int -- ^ 'delrsResponseStatus'+    -> DeleteUserResponse+deleteUserResponse pResponseStatus_ =+  DeleteUserResponse' {_delrsResponseStatus = pResponseStatus_}+++-- | -- | The response status code.+delrsResponseStatus :: Lens' DeleteUserResponse Int+delrsResponseStatus = lens _delrsResponseStatus (\ s a -> s{_delrsResponseStatus = a})++instance NFData DeleteUserResponse where
+ gen/Network/AWS/MQ/DescribeBroker.hs view
@@ -0,0 +1,275 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.DescribeBroker+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Returns information about the specified broker.+module Network.AWS.MQ.DescribeBroker+    (+    -- * Creating a Request+      describeBroker+    , DescribeBroker+    -- * Request Lenses+    , desBrokerId++    -- * Destructuring the Response+    , describeBrokerResponse+    , DescribeBrokerResponse+    -- * Response Lenses+    , dbrsBrokerName+    , dbrsEngineVersion+    , dbrsBrokerState+    , dbrsPubliclyAccessible+    , dbrsAutoMinorVersionUpgrade+    , dbrsSecurityGroups+    , dbrsUsers+    , dbrsSubnetIds+    , dbrsConfigurations+    , dbrsMaintenanceWindowStartTime+    , dbrsDeploymentMode+    , dbrsBrokerId+    , dbrsEngineType+    , dbrsBrokerARN+    , dbrsBrokerInstances+    , dbrsHostInstanceType+    , dbrsResponseStatus+    ) where++import Network.AWS.Lens+import Network.AWS.MQ.Types+import Network.AWS.MQ.Types.Product+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'describeBroker' smart constructor.+newtype DescribeBroker = DescribeBroker'+  { _desBrokerId :: Text+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DescribeBroker' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'desBrokerId' - The name of the broker. This value must be unique in your AWS account, 1-50 characters long, must contain only letters, numbers, dashes, and underscores, and must not contain whitespaces, brackets, wildcard characters, or special characters.+describeBroker+    :: Text -- ^ 'desBrokerId'+    -> DescribeBroker+describeBroker pBrokerId_ = DescribeBroker' {_desBrokerId = pBrokerId_}+++-- | The name of the broker. This value must be unique in your AWS account, 1-50 characters long, must contain only letters, numbers, dashes, and underscores, and must not contain whitespaces, brackets, wildcard characters, or special characters.+desBrokerId :: Lens' DescribeBroker Text+desBrokerId = lens _desBrokerId (\ s a -> s{_desBrokerId = a})++instance AWSRequest DescribeBroker where+        type Rs DescribeBroker = DescribeBrokerResponse+        request = get mq+        response+          = receiveJSON+              (\ s h x ->+                 DescribeBrokerResponse' <$>+                   (x .?> "brokerName") <*> (x .?> "engineVersion") <*>+                     (x .?> "brokerState")+                     <*> (x .?> "publiclyAccessible")+                     <*> (x .?> "autoMinorVersionUpgrade")+                     <*> (x .?> "securityGroups" .!@ mempty)+                     <*> (x .?> "users" .!@ mempty)+                     <*> (x .?> "subnetIds" .!@ mempty)+                     <*> (x .?> "configurations")+                     <*> (x .?> "maintenanceWindowStartTime")+                     <*> (x .?> "deploymentMode")+                     <*> (x .?> "brokerId")+                     <*> (x .?> "engineType")+                     <*> (x .?> "brokerArn")+                     <*> (x .?> "brokerInstances" .!@ mempty)+                     <*> (x .?> "hostInstanceType")+                     <*> (pure (fromEnum s)))++instance Hashable DescribeBroker where++instance NFData DescribeBroker where++instance ToHeaders DescribeBroker where+        toHeaders+          = const+              (mconcat+                 ["Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToPath DescribeBroker where+        toPath DescribeBroker'{..}+          = mconcat ["/v1/brokers/", toBS _desBrokerId]++instance ToQuery DescribeBroker where+        toQuery = const mempty++-- | /See:/ 'describeBrokerResponse' smart constructor.+data DescribeBrokerResponse = DescribeBrokerResponse'+  { _dbrsBrokerName                 :: !(Maybe Text)+  , _dbrsEngineVersion              :: !(Maybe Text)+  , _dbrsBrokerState                :: !(Maybe BrokerState)+  , _dbrsPubliclyAccessible         :: !(Maybe Bool)+  , _dbrsAutoMinorVersionUpgrade    :: !(Maybe Bool)+  , _dbrsSecurityGroups             :: !(Maybe [Text])+  , _dbrsUsers                      :: !(Maybe [UserSummary])+  , _dbrsSubnetIds                  :: !(Maybe [Text])+  , _dbrsConfigurations             :: !(Maybe Configurations)+  , _dbrsMaintenanceWindowStartTime :: !(Maybe WeeklyStartTime)+  , _dbrsDeploymentMode             :: !(Maybe DeploymentMode)+  , _dbrsBrokerId                   :: !(Maybe Text)+  , _dbrsEngineType                 :: !(Maybe EngineType)+  , _dbrsBrokerARN                  :: !(Maybe Text)+  , _dbrsBrokerInstances            :: !(Maybe [BrokerInstance])+  , _dbrsHostInstanceType           :: !(Maybe Text)+  , _dbrsResponseStatus             :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DescribeBrokerResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'dbrsBrokerName' - The name of the broker. This value must be unique in your AWS account, 1-50 characters long, must contain only letters, numbers, dashes, and underscores, and must not contain whitespaces, brackets, wildcard characters, or special characters.+--+-- * 'dbrsEngineVersion' - The version of the broker engine. Note: Currently, Amazon MQ supports only 5.15.0.+--+-- * 'dbrsBrokerState' - The status of the broker. Possible values: CREATION_IN_PROGRESS, CREATION_FAILED, DELETION_IN_PROGRESS, RUNNING, REBOOT_IN_PROGRESS+--+-- * 'dbrsPubliclyAccessible' - Required. Enables connections from applications outside of the VPC that hosts the broker's subnets.+--+-- * 'dbrsAutoMinorVersionUpgrade' - Required. Enables automatic upgrades to new minor versions for brokers, as Apache releases the versions. The automatic upgrades occur during the maintenance window of the broker or after a manual broker reboot.+--+-- * 'dbrsSecurityGroups' - Required. The list of rules (1 minimum, 125 maximum) that authorize connections to brokers.+--+-- * 'dbrsUsers' - The list of all ActiveMQ usernames for the specified broker.+--+-- * 'dbrsSubnetIds' - The list of groups (2 maximum) that define which subnets and IP ranges the broker can use from different Availability Zones. A SINGLE_INSTANCE deployment requires one subnet (for example, the default subnet). An ACTIVE_STANDBY_MULTI_AZ deployment requires two subnets.+--+-- * 'dbrsConfigurations' - The list of all revisions for the specified configuration.+--+-- * 'dbrsMaintenanceWindowStartTime' - The parameters that determine the WeeklyStartTime.+--+-- * 'dbrsDeploymentMode' - Required. The deployment mode of the broker. Possible values: SINGLE_INSTANCE, ACTIVE_STANDBY_MULTI_AZ SINGLE_INSTANCE creates a single-instance broker in a single Availability Zone. ACTIVE_STANDBY_MULTI_AZ creates an active/standby broker for high availability.+--+-- * 'dbrsBrokerId' - The unique ID that Amazon MQ generates for the broker.+--+-- * 'dbrsEngineType' - Required. The type of broker engine. Note: Currently, Amazon MQ supports only ACTIVEMQ.+--+-- * 'dbrsBrokerARN' - The Amazon Resource Name (ARN) of the broker.+--+-- * 'dbrsBrokerInstances' - A list of information about allocated brokers.+--+-- * 'dbrsHostInstanceType' - The broker's instance type. Possible values: mq.t2.micro, mq.m4.large+--+-- * 'dbrsResponseStatus' - -- | The response status code.+describeBrokerResponse+    :: Int -- ^ 'dbrsResponseStatus'+    -> DescribeBrokerResponse+describeBrokerResponse pResponseStatus_ =+  DescribeBrokerResponse'+    { _dbrsBrokerName = Nothing+    , _dbrsEngineVersion = Nothing+    , _dbrsBrokerState = Nothing+    , _dbrsPubliclyAccessible = Nothing+    , _dbrsAutoMinorVersionUpgrade = Nothing+    , _dbrsSecurityGroups = Nothing+    , _dbrsUsers = Nothing+    , _dbrsSubnetIds = Nothing+    , _dbrsConfigurations = Nothing+    , _dbrsMaintenanceWindowStartTime = Nothing+    , _dbrsDeploymentMode = Nothing+    , _dbrsBrokerId = Nothing+    , _dbrsEngineType = Nothing+    , _dbrsBrokerARN = Nothing+    , _dbrsBrokerInstances = Nothing+    , _dbrsHostInstanceType = Nothing+    , _dbrsResponseStatus = pResponseStatus_+    }+++-- | The name of the broker. This value must be unique in your AWS account, 1-50 characters long, must contain only letters, numbers, dashes, and underscores, and must not contain whitespaces, brackets, wildcard characters, or special characters.+dbrsBrokerName :: Lens' DescribeBrokerResponse (Maybe Text)+dbrsBrokerName = lens _dbrsBrokerName (\ s a -> s{_dbrsBrokerName = a})++-- | The version of the broker engine. Note: Currently, Amazon MQ supports only 5.15.0.+dbrsEngineVersion :: Lens' DescribeBrokerResponse (Maybe Text)+dbrsEngineVersion = lens _dbrsEngineVersion (\ s a -> s{_dbrsEngineVersion = a})++-- | The status of the broker. Possible values: CREATION_IN_PROGRESS, CREATION_FAILED, DELETION_IN_PROGRESS, RUNNING, REBOOT_IN_PROGRESS+dbrsBrokerState :: Lens' DescribeBrokerResponse (Maybe BrokerState)+dbrsBrokerState = lens _dbrsBrokerState (\ s a -> s{_dbrsBrokerState = a})++-- | Required. Enables connections from applications outside of the VPC that hosts the broker's subnets.+dbrsPubliclyAccessible :: Lens' DescribeBrokerResponse (Maybe Bool)+dbrsPubliclyAccessible = lens _dbrsPubliclyAccessible (\ s a -> s{_dbrsPubliclyAccessible = a})++-- | Required. Enables automatic upgrades to new minor versions for brokers, as Apache releases the versions. The automatic upgrades occur during the maintenance window of the broker or after a manual broker reboot.+dbrsAutoMinorVersionUpgrade :: Lens' DescribeBrokerResponse (Maybe Bool)+dbrsAutoMinorVersionUpgrade = lens _dbrsAutoMinorVersionUpgrade (\ s a -> s{_dbrsAutoMinorVersionUpgrade = a})++-- | Required. The list of rules (1 minimum, 125 maximum) that authorize connections to brokers.+dbrsSecurityGroups :: Lens' DescribeBrokerResponse [Text]+dbrsSecurityGroups = lens _dbrsSecurityGroups (\ s a -> s{_dbrsSecurityGroups = a}) . _Default . _Coerce++-- | The list of all ActiveMQ usernames for the specified broker.+dbrsUsers :: Lens' DescribeBrokerResponse [UserSummary]+dbrsUsers = lens _dbrsUsers (\ s a -> s{_dbrsUsers = a}) . _Default . _Coerce++-- | The list of groups (2 maximum) that define which subnets and IP ranges the broker can use from different Availability Zones. A SINGLE_INSTANCE deployment requires one subnet (for example, the default subnet). An ACTIVE_STANDBY_MULTI_AZ deployment requires two subnets.+dbrsSubnetIds :: Lens' DescribeBrokerResponse [Text]+dbrsSubnetIds = lens _dbrsSubnetIds (\ s a -> s{_dbrsSubnetIds = a}) . _Default . _Coerce++-- | The list of all revisions for the specified configuration.+dbrsConfigurations :: Lens' DescribeBrokerResponse (Maybe Configurations)+dbrsConfigurations = lens _dbrsConfigurations (\ s a -> s{_dbrsConfigurations = a})++-- | The parameters that determine the WeeklyStartTime.+dbrsMaintenanceWindowStartTime :: Lens' DescribeBrokerResponse (Maybe WeeklyStartTime)+dbrsMaintenanceWindowStartTime = lens _dbrsMaintenanceWindowStartTime (\ s a -> s{_dbrsMaintenanceWindowStartTime = a})++-- | Required. The deployment mode of the broker. Possible values: SINGLE_INSTANCE, ACTIVE_STANDBY_MULTI_AZ SINGLE_INSTANCE creates a single-instance broker in a single Availability Zone. ACTIVE_STANDBY_MULTI_AZ creates an active/standby broker for high availability.+dbrsDeploymentMode :: Lens' DescribeBrokerResponse (Maybe DeploymentMode)+dbrsDeploymentMode = lens _dbrsDeploymentMode (\ s a -> s{_dbrsDeploymentMode = a})++-- | The unique ID that Amazon MQ generates for the broker.+dbrsBrokerId :: Lens' DescribeBrokerResponse (Maybe Text)+dbrsBrokerId = lens _dbrsBrokerId (\ s a -> s{_dbrsBrokerId = a})++-- | Required. The type of broker engine. Note: Currently, Amazon MQ supports only ACTIVEMQ.+dbrsEngineType :: Lens' DescribeBrokerResponse (Maybe EngineType)+dbrsEngineType = lens _dbrsEngineType (\ s a -> s{_dbrsEngineType = a})++-- | The Amazon Resource Name (ARN) of the broker.+dbrsBrokerARN :: Lens' DescribeBrokerResponse (Maybe Text)+dbrsBrokerARN = lens _dbrsBrokerARN (\ s a -> s{_dbrsBrokerARN = a})++-- | A list of information about allocated brokers.+dbrsBrokerInstances :: Lens' DescribeBrokerResponse [BrokerInstance]+dbrsBrokerInstances = lens _dbrsBrokerInstances (\ s a -> s{_dbrsBrokerInstances = a}) . _Default . _Coerce++-- | The broker's instance type. Possible values: mq.t2.micro, mq.m4.large+dbrsHostInstanceType :: Lens' DescribeBrokerResponse (Maybe Text)+dbrsHostInstanceType = lens _dbrsHostInstanceType (\ s a -> s{_dbrsHostInstanceType = a})++-- | -- | The response status code.+dbrsResponseStatus :: Lens' DescribeBrokerResponse Int+dbrsResponseStatus = lens _dbrsResponseStatus (\ s a -> s{_dbrsResponseStatus = a})++instance NFData DescribeBrokerResponse where
+ gen/Network/AWS/MQ/DescribeConfiguration.hs view
@@ -0,0 +1,188 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.DescribeConfiguration+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Returns information about the specified configuration.+module Network.AWS.MQ.DescribeConfiguration+    (+    -- * Creating a Request+      describeConfiguration+    , DescribeConfiguration+    -- * Request Lenses+    , dcConfigurationId++    -- * Destructuring the Response+    , describeConfigurationResponse+    , DescribeConfigurationResponse+    -- * Response Lenses+    , dcrsEngineVersion+    , dcrsARN+    , dcrsLatestRevision+    , dcrsName+    , dcrsId+    , dcrsDescription+    , dcrsEngineType+    , dcrsResponseStatus+    ) where++import Network.AWS.Lens+import Network.AWS.MQ.Types+import Network.AWS.MQ.Types.Product+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'describeConfiguration' smart constructor.+newtype DescribeConfiguration = DescribeConfiguration'+  { _dcConfigurationId :: Text+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DescribeConfiguration' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'dcConfigurationId' - The unique ID that Amazon MQ generates for the configuration.+describeConfiguration+    :: Text -- ^ 'dcConfigurationId'+    -> DescribeConfiguration+describeConfiguration pConfigurationId_ =+  DescribeConfiguration' {_dcConfigurationId = pConfigurationId_}+++-- | The unique ID that Amazon MQ generates for the configuration.+dcConfigurationId :: Lens' DescribeConfiguration Text+dcConfigurationId = lens _dcConfigurationId (\ s a -> s{_dcConfigurationId = a})++instance AWSRequest DescribeConfiguration where+        type Rs DescribeConfiguration =+             DescribeConfigurationResponse+        request = get mq+        response+          = receiveJSON+              (\ s h x ->+                 DescribeConfigurationResponse' <$>+                   (x .?> "engineVersion") <*> (x .?> "arn") <*>+                     (x .?> "latestRevision")+                     <*> (x .?> "name")+                     <*> (x .?> "id")+                     <*> (x .?> "description")+                     <*> (x .?> "engineType")+                     <*> (pure (fromEnum s)))++instance Hashable DescribeConfiguration where++instance NFData DescribeConfiguration where++instance ToHeaders DescribeConfiguration where+        toHeaders+          = const+              (mconcat+                 ["Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToPath DescribeConfiguration where+        toPath DescribeConfiguration'{..}+          = mconcat+              ["/v1/configurations/", toBS _dcConfigurationId]++instance ToQuery DescribeConfiguration where+        toQuery = const mempty++-- | /See:/ 'describeConfigurationResponse' smart constructor.+data DescribeConfigurationResponse = DescribeConfigurationResponse'+  { _dcrsEngineVersion  :: !(Maybe Text)+  , _dcrsARN            :: !(Maybe Text)+  , _dcrsLatestRevision :: !(Maybe ConfigurationRevision)+  , _dcrsName           :: !(Maybe Text)+  , _dcrsId             :: !(Maybe Text)+  , _dcrsDescription    :: !(Maybe Text)+  , _dcrsEngineType     :: !(Maybe EngineType)+  , _dcrsResponseStatus :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DescribeConfigurationResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'dcrsEngineVersion' - Required. The version of the broker engine.+--+-- * 'dcrsARN' - Required. The ARN of the configuration.+--+-- * 'dcrsLatestRevision' - Required. The latest revision of the configuration.+--+-- * 'dcrsName' - Required. The name of the configuration. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 1-150 characters long.+--+-- * 'dcrsId' - Required. The unique ID that Amazon MQ generates for the configuration.+--+-- * 'dcrsDescription' - Required. The description of the configuration.+--+-- * 'dcrsEngineType' - Required. The type of broker engine. Note: Currently, Amazon MQ supports only ACTIVEMQ.+--+-- * 'dcrsResponseStatus' - -- | The response status code.+describeConfigurationResponse+    :: Int -- ^ 'dcrsResponseStatus'+    -> DescribeConfigurationResponse+describeConfigurationResponse pResponseStatus_ =+  DescribeConfigurationResponse'+    { _dcrsEngineVersion = Nothing+    , _dcrsARN = Nothing+    , _dcrsLatestRevision = Nothing+    , _dcrsName = Nothing+    , _dcrsId = Nothing+    , _dcrsDescription = Nothing+    , _dcrsEngineType = Nothing+    , _dcrsResponseStatus = pResponseStatus_+    }+++-- | Required. The version of the broker engine.+dcrsEngineVersion :: Lens' DescribeConfigurationResponse (Maybe Text)+dcrsEngineVersion = lens _dcrsEngineVersion (\ s a -> s{_dcrsEngineVersion = a})++-- | Required. The ARN of the configuration.+dcrsARN :: Lens' DescribeConfigurationResponse (Maybe Text)+dcrsARN = lens _dcrsARN (\ s a -> s{_dcrsARN = a})++-- | Required. The latest revision of the configuration.+dcrsLatestRevision :: Lens' DescribeConfigurationResponse (Maybe ConfigurationRevision)+dcrsLatestRevision = lens _dcrsLatestRevision (\ s a -> s{_dcrsLatestRevision = a})++-- | Required. The name of the configuration. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 1-150 characters long.+dcrsName :: Lens' DescribeConfigurationResponse (Maybe Text)+dcrsName = lens _dcrsName (\ s a -> s{_dcrsName = a})++-- | Required. The unique ID that Amazon MQ generates for the configuration.+dcrsId :: Lens' DescribeConfigurationResponse (Maybe Text)+dcrsId = lens _dcrsId (\ s a -> s{_dcrsId = a})++-- | Required. The description of the configuration.+dcrsDescription :: Lens' DescribeConfigurationResponse (Maybe Text)+dcrsDescription = lens _dcrsDescription (\ s a -> s{_dcrsDescription = a})++-- | Required. The type of broker engine. Note: Currently, Amazon MQ supports only ACTIVEMQ.+dcrsEngineType :: Lens' DescribeConfigurationResponse (Maybe EngineType)+dcrsEngineType = lens _dcrsEngineType (\ s a -> s{_dcrsEngineType = a})++-- | -- | The response status code.+dcrsResponseStatus :: Lens' DescribeConfigurationResponse Int+dcrsResponseStatus = lens _dcrsResponseStatus (\ s a -> s{_dcrsResponseStatus = a})++instance NFData DescribeConfigurationResponse where
+ gen/Network/AWS/MQ/DescribeConfigurationRevision.hs view
@@ -0,0 +1,164 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.DescribeConfigurationRevision+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Returns the specified configuration revision for the specified configuration.+module Network.AWS.MQ.DescribeConfigurationRevision+    (+    -- * Creating a Request+      describeConfigurationRevision+    , DescribeConfigurationRevision+    -- * Request Lenses+    , dcrConfigurationRevision+    , dcrConfigurationId++    -- * Destructuring the Response+    , describeConfigurationRevisionResponse+    , DescribeConfigurationRevisionResponse+    -- * Response Lenses+    , dcrrsConfigurationId+    , dcrrsData+    , dcrrsDescription+    , dcrrsResponseStatus+    ) where++import Network.AWS.Lens+import Network.AWS.MQ.Types+import Network.AWS.MQ.Types.Product+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'describeConfigurationRevision' smart constructor.+data DescribeConfigurationRevision = DescribeConfigurationRevision'+  { _dcrConfigurationRevision :: !Text+  , _dcrConfigurationId       :: !Text+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DescribeConfigurationRevision' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'dcrConfigurationRevision' - The revision of the configuration.+--+-- * 'dcrConfigurationId' - The unique ID that Amazon MQ generates for the configuration.+describeConfigurationRevision+    :: Text -- ^ 'dcrConfigurationRevision'+    -> Text -- ^ 'dcrConfigurationId'+    -> DescribeConfigurationRevision+describeConfigurationRevision pConfigurationRevision_ pConfigurationId_ =+  DescribeConfigurationRevision'+    { _dcrConfigurationRevision = pConfigurationRevision_+    , _dcrConfigurationId = pConfigurationId_+    }+++-- | The revision of the configuration.+dcrConfigurationRevision :: Lens' DescribeConfigurationRevision Text+dcrConfigurationRevision = lens _dcrConfigurationRevision (\ s a -> s{_dcrConfigurationRevision = a})++-- | The unique ID that Amazon MQ generates for the configuration.+dcrConfigurationId :: Lens' DescribeConfigurationRevision Text+dcrConfigurationId = lens _dcrConfigurationId (\ s a -> s{_dcrConfigurationId = a})++instance AWSRequest DescribeConfigurationRevision+         where+        type Rs DescribeConfigurationRevision =+             DescribeConfigurationRevisionResponse+        request = get mq+        response+          = receiveJSON+              (\ s h x ->+                 DescribeConfigurationRevisionResponse' <$>+                   (x .?> "configurationId") <*> (x .?> "data") <*>+                     (x .?> "description")+                     <*> (pure (fromEnum s)))++instance Hashable DescribeConfigurationRevision where++instance NFData DescribeConfigurationRevision where++instance ToHeaders DescribeConfigurationRevision+         where+        toHeaders+          = const+              (mconcat+                 ["Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToPath DescribeConfigurationRevision where+        toPath DescribeConfigurationRevision'{..}+          = mconcat+              ["/v1/configurations/", toBS _dcrConfigurationId,+               "/revisions/", toBS _dcrConfigurationRevision]++instance ToQuery DescribeConfigurationRevision where+        toQuery = const mempty++-- | /See:/ 'describeConfigurationRevisionResponse' smart constructor.+data DescribeConfigurationRevisionResponse = DescribeConfigurationRevisionResponse'+  { _dcrrsConfigurationId :: !(Maybe Text)+  , _dcrrsData            :: !(Maybe Text)+  , _dcrrsDescription     :: !(Maybe Text)+  , _dcrrsResponseStatus  :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DescribeConfigurationRevisionResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'dcrrsConfigurationId' - Required. The unique ID that Amazon MQ generates for the configuration.+--+-- * 'dcrrsData' - Required. The base64-encoded XML configuration.+--+-- * 'dcrrsDescription' - The description of the configuration.+--+-- * 'dcrrsResponseStatus' - -- | The response status code.+describeConfigurationRevisionResponse+    :: Int -- ^ 'dcrrsResponseStatus'+    -> DescribeConfigurationRevisionResponse+describeConfigurationRevisionResponse pResponseStatus_ =+  DescribeConfigurationRevisionResponse'+    { _dcrrsConfigurationId = Nothing+    , _dcrrsData = Nothing+    , _dcrrsDescription = Nothing+    , _dcrrsResponseStatus = pResponseStatus_+    }+++-- | Required. The unique ID that Amazon MQ generates for the configuration.+dcrrsConfigurationId :: Lens' DescribeConfigurationRevisionResponse (Maybe Text)+dcrrsConfigurationId = lens _dcrrsConfigurationId (\ s a -> s{_dcrrsConfigurationId = a})++-- | Required. The base64-encoded XML configuration.+dcrrsData :: Lens' DescribeConfigurationRevisionResponse (Maybe Text)+dcrrsData = lens _dcrrsData (\ s a -> s{_dcrrsData = a})++-- | The description of the configuration.+dcrrsDescription :: Lens' DescribeConfigurationRevisionResponse (Maybe Text)+dcrrsDescription = lens _dcrrsDescription (\ s a -> s{_dcrrsDescription = a})++-- | -- | The response status code.+dcrrsResponseStatus :: Lens' DescribeConfigurationRevisionResponse Int+dcrrsResponseStatus = lens _dcrrsResponseStatus (\ s a -> s{_dcrrsResponseStatus = a})++instance NFData DescribeConfigurationRevisionResponse+         where
+ gen/Network/AWS/MQ/DescribeUser.hs view
@@ -0,0 +1,177 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.DescribeUser+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Returns information about an ActiveMQ user.+module Network.AWS.MQ.DescribeUser+    (+    -- * Creating a Request+      describeUser+    , DescribeUser+    -- * Request Lenses+    , duUsername+    , duBrokerId++    -- * Destructuring the Response+    , describeUserResponse+    , DescribeUserResponse+    -- * Response Lenses+    , dursGroups+    , dursPending+    , dursConsoleAccess+    , dursUsername+    , dursBrokerId+    , dursResponseStatus+    ) where++import Network.AWS.Lens+import Network.AWS.MQ.Types+import Network.AWS.MQ.Types.Product+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'describeUser' smart constructor.+data DescribeUser = DescribeUser'+  { _duUsername :: !Text+  , _duBrokerId :: !Text+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DescribeUser' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'duUsername' - The username of the ActiveMQ user. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+--+-- * 'duBrokerId' - The unique ID that Amazon MQ generates for the broker.+describeUser+    :: Text -- ^ 'duUsername'+    -> Text -- ^ 'duBrokerId'+    -> DescribeUser+describeUser pUsername_ pBrokerId_ =+  DescribeUser' {_duUsername = pUsername_, _duBrokerId = pBrokerId_}+++-- | The username of the ActiveMQ user. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+duUsername :: Lens' DescribeUser Text+duUsername = lens _duUsername (\ s a -> s{_duUsername = a})++-- | The unique ID that Amazon MQ generates for the broker.+duBrokerId :: Lens' DescribeUser Text+duBrokerId = lens _duBrokerId (\ s a -> s{_duBrokerId = a})++instance AWSRequest DescribeUser where+        type Rs DescribeUser = DescribeUserResponse+        request = get mq+        response+          = receiveJSON+              (\ s h x ->+                 DescribeUserResponse' <$>+                   (x .?> "groups" .!@ mempty) <*> (x .?> "pending") <*>+                     (x .?> "consoleAccess")+                     <*> (x .?> "username")+                     <*> (x .?> "brokerId")+                     <*> (pure (fromEnum s)))++instance Hashable DescribeUser where++instance NFData DescribeUser where++instance ToHeaders DescribeUser where+        toHeaders+          = const+              (mconcat+                 ["Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToPath DescribeUser where+        toPath DescribeUser'{..}+          = mconcat+              ["/v1/brokers/", toBS _duBrokerId, "/users/",+               toBS _duUsername]++instance ToQuery DescribeUser where+        toQuery = const mempty++-- | /See:/ 'describeUserResponse' smart constructor.+data DescribeUserResponse = DescribeUserResponse'+  { _dursGroups         :: !(Maybe [Text])+  , _dursPending        :: !(Maybe UserPendingChanges)+  , _dursConsoleAccess  :: !(Maybe Bool)+  , _dursUsername       :: !(Maybe Text)+  , _dursBrokerId       :: !(Maybe Text)+  , _dursResponseStatus :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DescribeUserResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'dursGroups' - The list of groups (20 maximum) to which the ActiveMQ user belongs. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+--+-- * 'dursPending' - The status of the changes pending for the ActiveMQ user.+--+-- * 'dursConsoleAccess' - Enables access to the the ActiveMQ Web Console for the ActiveMQ user.+--+-- * 'dursUsername' - Required. The username of the ActiveMQ user. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+--+-- * 'dursBrokerId' - Required. The unique ID that Amazon MQ generates for the broker.+--+-- * 'dursResponseStatus' - -- | The response status code.+describeUserResponse+    :: Int -- ^ 'dursResponseStatus'+    -> DescribeUserResponse+describeUserResponse pResponseStatus_ =+  DescribeUserResponse'+    { _dursGroups = Nothing+    , _dursPending = Nothing+    , _dursConsoleAccess = Nothing+    , _dursUsername = Nothing+    , _dursBrokerId = Nothing+    , _dursResponseStatus = pResponseStatus_+    }+++-- | The list of groups (20 maximum) to which the ActiveMQ user belongs. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+dursGroups :: Lens' DescribeUserResponse [Text]+dursGroups = lens _dursGroups (\ s a -> s{_dursGroups = a}) . _Default . _Coerce++-- | The status of the changes pending for the ActiveMQ user.+dursPending :: Lens' DescribeUserResponse (Maybe UserPendingChanges)+dursPending = lens _dursPending (\ s a -> s{_dursPending = a})++-- | Enables access to the the ActiveMQ Web Console for the ActiveMQ user.+dursConsoleAccess :: Lens' DescribeUserResponse (Maybe Bool)+dursConsoleAccess = lens _dursConsoleAccess (\ s a -> s{_dursConsoleAccess = a})++-- | Required. The username of the ActiveMQ user. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+dursUsername :: Lens' DescribeUserResponse (Maybe Text)+dursUsername = lens _dursUsername (\ s a -> s{_dursUsername = a})++-- | Required. The unique ID that Amazon MQ generates for the broker.+dursBrokerId :: Lens' DescribeUserResponse (Maybe Text)+dursBrokerId = lens _dursBrokerId (\ s a -> s{_dursBrokerId = a})++-- | -- | The response status code.+dursResponseStatus :: Lens' DescribeUserResponse Int+dursResponseStatus = lens _dursResponseStatus (\ s a -> s{_dursResponseStatus = a})++instance NFData DescribeUserResponse where
+ gen/Network/AWS/MQ/ListBrokers.hs view
@@ -0,0 +1,145 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.ListBrokers+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Returns a list of all brokers.+module Network.AWS.MQ.ListBrokers+    (+    -- * Creating a Request+      listBrokers+    , ListBrokers+    -- * Request Lenses+    , lbNextToken+    , lbMaxResults++    -- * Destructuring the Response+    , listBrokersResponse+    , ListBrokersResponse+    -- * Response Lenses+    , lbrsNextToken+    , lbrsBrokerSummaries+    , lbrsResponseStatus+    ) where++import Network.AWS.Lens+import Network.AWS.MQ.Types+import Network.AWS.MQ.Types.Product+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'listBrokers' smart constructor.+data ListBrokers = ListBrokers'+  { _lbNextToken  :: !(Maybe Text)+  , _lbMaxResults :: !(Maybe Nat)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'ListBrokers' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'lbNextToken' - The token that specifies the next page of results Amazon MQ should return. To request the first page, leave nextToken empty.+--+-- * 'lbMaxResults' - The maximum number of brokers that Amazon MQ can return per page (20 by default). This value must be an integer from 5 to 100.+listBrokers+    :: ListBrokers+listBrokers = ListBrokers' {_lbNextToken = Nothing, _lbMaxResults = Nothing}+++-- | The token that specifies the next page of results Amazon MQ should return. To request the first page, leave nextToken empty.+lbNextToken :: Lens' ListBrokers (Maybe Text)+lbNextToken = lens _lbNextToken (\ s a -> s{_lbNextToken = a})++-- | The maximum number of brokers that Amazon MQ can return per page (20 by default). This value must be an integer from 5 to 100.+lbMaxResults :: Lens' ListBrokers (Maybe Natural)+lbMaxResults = lens _lbMaxResults (\ s a -> s{_lbMaxResults = a}) . mapping _Nat++instance AWSRequest ListBrokers where+        type Rs ListBrokers = ListBrokersResponse+        request = get mq+        response+          = receiveJSON+              (\ s h x ->+                 ListBrokersResponse' <$>+                   (x .?> "nextToken") <*>+                     (x .?> "brokerSummaries" .!@ mempty)+                     <*> (pure (fromEnum s)))++instance Hashable ListBrokers where++instance NFData ListBrokers where++instance ToHeaders ListBrokers where+        toHeaders+          = const+              (mconcat+                 ["Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToPath ListBrokers where+        toPath = const "/v1/brokers"++instance ToQuery ListBrokers where+        toQuery ListBrokers'{..}+          = mconcat+              ["nextToken" =: _lbNextToken,+               "maxResults" =: _lbMaxResults]++-- | /See:/ 'listBrokersResponse' smart constructor.+data ListBrokersResponse = ListBrokersResponse'+  { _lbrsNextToken       :: !(Maybe Text)+  , _lbrsBrokerSummaries :: !(Maybe [BrokerSummary])+  , _lbrsResponseStatus  :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'ListBrokersResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'lbrsNextToken' - The token that specifies the next page of results Amazon MQ should return. To request the first page, leave nextToken empty.+--+-- * 'lbrsBrokerSummaries' - A list of information about all brokers.+--+-- * 'lbrsResponseStatus' - -- | The response status code.+listBrokersResponse+    :: Int -- ^ 'lbrsResponseStatus'+    -> ListBrokersResponse+listBrokersResponse pResponseStatus_ =+  ListBrokersResponse'+    { _lbrsNextToken = Nothing+    , _lbrsBrokerSummaries = Nothing+    , _lbrsResponseStatus = pResponseStatus_+    }+++-- | The token that specifies the next page of results Amazon MQ should return. To request the first page, leave nextToken empty.+lbrsNextToken :: Lens' ListBrokersResponse (Maybe Text)+lbrsNextToken = lens _lbrsNextToken (\ s a -> s{_lbrsNextToken = a})++-- | A list of information about all brokers.+lbrsBrokerSummaries :: Lens' ListBrokersResponse [BrokerSummary]+lbrsBrokerSummaries = lens _lbrsBrokerSummaries (\ s a -> s{_lbrsBrokerSummaries = a}) . _Default . _Coerce++-- | -- | The response status code.+lbrsResponseStatus :: Lens' ListBrokersResponse Int+lbrsResponseStatus = lens _lbrsResponseStatus (\ s a -> s{_lbrsResponseStatus = a})++instance NFData ListBrokersResponse where
+ gen/Network/AWS/MQ/ListConfigurationRevisions.hs view
@@ -0,0 +1,183 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.ListConfigurationRevisions+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Returns a list of all revisions for the specified configuration.+module Network.AWS.MQ.ListConfigurationRevisions+    (+    -- * Creating a Request+      listConfigurationRevisions+    , ListConfigurationRevisions+    -- * Request Lenses+    , lcrNextToken+    , lcrMaxResults+    , lcrConfigurationId++    -- * Destructuring the Response+    , listConfigurationRevisionsResponse+    , ListConfigurationRevisionsResponse+    -- * Response Lenses+    , lcrrsConfigurationId+    , lcrrsNextToken+    , lcrrsRevisions+    , lcrrsMaxResults+    , lcrrsResponseStatus+    ) where++import Network.AWS.Lens+import Network.AWS.MQ.Types+import Network.AWS.MQ.Types.Product+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'listConfigurationRevisions' smart constructor.+data ListConfigurationRevisions = ListConfigurationRevisions'+  { _lcrNextToken       :: !(Maybe Text)+  , _lcrMaxResults      :: !(Maybe Nat)+  , _lcrConfigurationId :: !Text+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'ListConfigurationRevisions' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'lcrNextToken' - The token that specifies the next page of results Amazon MQ should return. To request the first page, leave nextToken empty.+--+-- * 'lcrMaxResults' - The maximum number of configurations that Amazon MQ can return per page (20 by default). This value must be an integer from 5 to 100.+--+-- * 'lcrConfigurationId' - The unique ID that Amazon MQ generates for the configuration.+listConfigurationRevisions+    :: Text -- ^ 'lcrConfigurationId'+    -> ListConfigurationRevisions+listConfigurationRevisions pConfigurationId_ =+  ListConfigurationRevisions'+    { _lcrNextToken = Nothing+    , _lcrMaxResults = Nothing+    , _lcrConfigurationId = pConfigurationId_+    }+++-- | The token that specifies the next page of results Amazon MQ should return. To request the first page, leave nextToken empty.+lcrNextToken :: Lens' ListConfigurationRevisions (Maybe Text)+lcrNextToken = lens _lcrNextToken (\ s a -> s{_lcrNextToken = a})++-- | The maximum number of configurations that Amazon MQ can return per page (20 by default). This value must be an integer from 5 to 100.+lcrMaxResults :: Lens' ListConfigurationRevisions (Maybe Natural)+lcrMaxResults = lens _lcrMaxResults (\ s a -> s{_lcrMaxResults = a}) . mapping _Nat++-- | The unique ID that Amazon MQ generates for the configuration.+lcrConfigurationId :: Lens' ListConfigurationRevisions Text+lcrConfigurationId = lens _lcrConfigurationId (\ s a -> s{_lcrConfigurationId = a})++instance AWSRequest ListConfigurationRevisions where+        type Rs ListConfigurationRevisions =+             ListConfigurationRevisionsResponse+        request = get mq+        response+          = receiveJSON+              (\ s h x ->+                 ListConfigurationRevisionsResponse' <$>+                   (x .?> "configurationId") <*> (x .?> "nextToken") <*>+                     (x .?> "revisions" .!@ mempty)+                     <*> (x .?> "maxResults")+                     <*> (pure (fromEnum s)))++instance Hashable ListConfigurationRevisions where++instance NFData ListConfigurationRevisions where++instance ToHeaders ListConfigurationRevisions where+        toHeaders+          = const+              (mconcat+                 ["Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToPath ListConfigurationRevisions where+        toPath ListConfigurationRevisions'{..}+          = mconcat+              ["/v1/configurations/", toBS _lcrConfigurationId,+               "/revisions"]++instance ToQuery ListConfigurationRevisions where+        toQuery ListConfigurationRevisions'{..}+          = mconcat+              ["nextToken" =: _lcrNextToken,+               "maxResults" =: _lcrMaxResults]++-- | /See:/ 'listConfigurationRevisionsResponse' smart constructor.+data ListConfigurationRevisionsResponse = ListConfigurationRevisionsResponse'+  { _lcrrsConfigurationId :: !(Maybe Text)+  , _lcrrsNextToken       :: !(Maybe Text)+  , _lcrrsRevisions       :: !(Maybe [ConfigurationRevision])+  , _lcrrsMaxResults      :: !(Maybe Int)+  , _lcrrsResponseStatus  :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'ListConfigurationRevisionsResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'lcrrsConfigurationId' - The unique ID that Amazon MQ generates for the configuration.+--+-- * 'lcrrsNextToken' - The token that specifies the next page of results Amazon MQ should return. To request the first page, leave nextToken empty.+--+-- * 'lcrrsRevisions' - The list of all revisions for the specified configuration.+--+-- * 'lcrrsMaxResults' - The maximum number of configuration revisions that can be returned per page (20 by default). This value must be an integer from 5 to 100.+--+-- * 'lcrrsResponseStatus' - -- | The response status code.+listConfigurationRevisionsResponse+    :: Int -- ^ 'lcrrsResponseStatus'+    -> ListConfigurationRevisionsResponse+listConfigurationRevisionsResponse pResponseStatus_ =+  ListConfigurationRevisionsResponse'+    { _lcrrsConfigurationId = Nothing+    , _lcrrsNextToken = Nothing+    , _lcrrsRevisions = Nothing+    , _lcrrsMaxResults = Nothing+    , _lcrrsResponseStatus = pResponseStatus_+    }+++-- | The unique ID that Amazon MQ generates for the configuration.+lcrrsConfigurationId :: Lens' ListConfigurationRevisionsResponse (Maybe Text)+lcrrsConfigurationId = lens _lcrrsConfigurationId (\ s a -> s{_lcrrsConfigurationId = a})++-- | The token that specifies the next page of results Amazon MQ should return. To request the first page, leave nextToken empty.+lcrrsNextToken :: Lens' ListConfigurationRevisionsResponse (Maybe Text)+lcrrsNextToken = lens _lcrrsNextToken (\ s a -> s{_lcrrsNextToken = a})++-- | The list of all revisions for the specified configuration.+lcrrsRevisions :: Lens' ListConfigurationRevisionsResponse [ConfigurationRevision]+lcrrsRevisions = lens _lcrrsRevisions (\ s a -> s{_lcrrsRevisions = a}) . _Default . _Coerce++-- | The maximum number of configuration revisions that can be returned per page (20 by default). This value must be an integer from 5 to 100.+lcrrsMaxResults :: Lens' ListConfigurationRevisionsResponse (Maybe Int)+lcrrsMaxResults = lens _lcrrsMaxResults (\ s a -> s{_lcrrsMaxResults = a})++-- | -- | The response status code.+lcrrsResponseStatus :: Lens' ListConfigurationRevisionsResponse Int+lcrrsResponseStatus = lens _lcrrsResponseStatus (\ s a -> s{_lcrrsResponseStatus = a})++instance NFData ListConfigurationRevisionsResponse+         where
+ gen/Network/AWS/MQ/ListConfigurations.hs view
@@ -0,0 +1,157 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.ListConfigurations+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Returns a list of all configurations.+module Network.AWS.MQ.ListConfigurations+    (+    -- * Creating a Request+      listConfigurations+    , ListConfigurations+    -- * Request Lenses+    , lcNextToken+    , lcMaxResults++    -- * Destructuring the Response+    , listConfigurationsResponse+    , ListConfigurationsResponse+    -- * Response Lenses+    , lcrsConfigurations+    , lcrsNextToken+    , lcrsMaxResults+    , lcrsResponseStatus+    ) where++import Network.AWS.Lens+import Network.AWS.MQ.Types+import Network.AWS.MQ.Types.Product+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'listConfigurations' smart constructor.+data ListConfigurations = ListConfigurations'+  { _lcNextToken  :: !(Maybe Text)+  , _lcMaxResults :: !(Maybe Nat)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'ListConfigurations' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'lcNextToken' - The token that specifies the next page of results Amazon MQ should return. To request the first page, leave nextToken empty.+--+-- * 'lcMaxResults' - The maximum number of configurations that Amazon MQ can return per page (20 by default). This value must be an integer from 5 to 100.+listConfigurations+    :: ListConfigurations+listConfigurations =+  ListConfigurations' {_lcNextToken = Nothing, _lcMaxResults = Nothing}+++-- | The token that specifies the next page of results Amazon MQ should return. To request the first page, leave nextToken empty.+lcNextToken :: Lens' ListConfigurations (Maybe Text)+lcNextToken = lens _lcNextToken (\ s a -> s{_lcNextToken = a})++-- | The maximum number of configurations that Amazon MQ can return per page (20 by default). This value must be an integer from 5 to 100.+lcMaxResults :: Lens' ListConfigurations (Maybe Natural)+lcMaxResults = lens _lcMaxResults (\ s a -> s{_lcMaxResults = a}) . mapping _Nat++instance AWSRequest ListConfigurations where+        type Rs ListConfigurations =+             ListConfigurationsResponse+        request = get mq+        response+          = receiveJSON+              (\ s h x ->+                 ListConfigurationsResponse' <$>+                   (x .?> "configurations" .!@ mempty) <*>+                     (x .?> "nextToken")+                     <*> (x .?> "maxResults")+                     <*> (pure (fromEnum s)))++instance Hashable ListConfigurations where++instance NFData ListConfigurations where++instance ToHeaders ListConfigurations where+        toHeaders+          = const+              (mconcat+                 ["Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToPath ListConfigurations where+        toPath = const "/v1/configurations"++instance ToQuery ListConfigurations where+        toQuery ListConfigurations'{..}+          = mconcat+              ["nextToken" =: _lcNextToken,+               "maxResults" =: _lcMaxResults]++-- | /See:/ 'listConfigurationsResponse' smart constructor.+data ListConfigurationsResponse = ListConfigurationsResponse'+  { _lcrsConfigurations :: !(Maybe [Configuration])+  , _lcrsNextToken      :: !(Maybe Text)+  , _lcrsMaxResults     :: !(Maybe Int)+  , _lcrsResponseStatus :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'ListConfigurationsResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'lcrsConfigurations' - The list of all revisions for the specified configuration.+--+-- * 'lcrsNextToken' - The token that specifies the next page of results Amazon MQ should return. To request the first page, leave nextToken empty.+--+-- * 'lcrsMaxResults' - The maximum number of configurations that Amazon MQ can return per page (20 by default). This value must be an integer from 5 to 100.+--+-- * 'lcrsResponseStatus' - -- | The response status code.+listConfigurationsResponse+    :: Int -- ^ 'lcrsResponseStatus'+    -> ListConfigurationsResponse+listConfigurationsResponse pResponseStatus_ =+  ListConfigurationsResponse'+    { _lcrsConfigurations = Nothing+    , _lcrsNextToken = Nothing+    , _lcrsMaxResults = Nothing+    , _lcrsResponseStatus = pResponseStatus_+    }+++-- | The list of all revisions for the specified configuration.+lcrsConfigurations :: Lens' ListConfigurationsResponse [Configuration]+lcrsConfigurations = lens _lcrsConfigurations (\ s a -> s{_lcrsConfigurations = a}) . _Default . _Coerce++-- | The token that specifies the next page of results Amazon MQ should return. To request the first page, leave nextToken empty.+lcrsNextToken :: Lens' ListConfigurationsResponse (Maybe Text)+lcrsNextToken = lens _lcrsNextToken (\ s a -> s{_lcrsNextToken = a})++-- | The maximum number of configurations that Amazon MQ can return per page (20 by default). This value must be an integer from 5 to 100.+lcrsMaxResults :: Lens' ListConfigurationsResponse (Maybe Int)+lcrsMaxResults = lens _lcrsMaxResults (\ s a -> s{_lcrsMaxResults = a})++-- | -- | The response status code.+lcrsResponseStatus :: Lens' ListConfigurationsResponse Int+lcrsResponseStatus = lens _lcrsResponseStatus (\ s a -> s{_lcrsResponseStatus = a})++instance NFData ListConfigurationsResponse where
+ gen/Network/AWS/MQ/ListUsers.hs view
@@ -0,0 +1,177 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.ListUsers+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Returns a list of all ActiveMQ users.+module Network.AWS.MQ.ListUsers+    (+    -- * Creating a Request+      listUsers+    , ListUsers+    -- * Request Lenses+    , luNextToken+    , luMaxResults+    , luBrokerId++    -- * Destructuring the Response+    , listUsersResponse+    , ListUsersResponse+    -- * Response Lenses+    , lursUsers+    , lursNextToken+    , lursBrokerId+    , lursMaxResults+    , lursResponseStatus+    ) where++import Network.AWS.Lens+import Network.AWS.MQ.Types+import Network.AWS.MQ.Types.Product+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'listUsers' smart constructor.+data ListUsers = ListUsers'+  { _luNextToken  :: !(Maybe Text)+  , _luMaxResults :: !(Maybe Nat)+  , _luBrokerId   :: !Text+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'ListUsers' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'luNextToken' - The token that specifies the next page of results Amazon MQ should return. To request the first page, leave nextToken empty.+--+-- * 'luMaxResults' - The maximum number of ActiveMQ users that can be returned per page (20 by default). This value must be an integer from 5 to 100.+--+-- * 'luBrokerId' - The unique ID that Amazon MQ generates for the broker.+listUsers+    :: Text -- ^ 'luBrokerId'+    -> ListUsers+listUsers pBrokerId_ =+  ListUsers'+    {_luNextToken = Nothing, _luMaxResults = Nothing, _luBrokerId = pBrokerId_}+++-- | The token that specifies the next page of results Amazon MQ should return. To request the first page, leave nextToken empty.+luNextToken :: Lens' ListUsers (Maybe Text)+luNextToken = lens _luNextToken (\ s a -> s{_luNextToken = a})++-- | The maximum number of ActiveMQ users that can be returned per page (20 by default). This value must be an integer from 5 to 100.+luMaxResults :: Lens' ListUsers (Maybe Natural)+luMaxResults = lens _luMaxResults (\ s a -> s{_luMaxResults = a}) . mapping _Nat++-- | The unique ID that Amazon MQ generates for the broker.+luBrokerId :: Lens' ListUsers Text+luBrokerId = lens _luBrokerId (\ s a -> s{_luBrokerId = a})++instance AWSRequest ListUsers where+        type Rs ListUsers = ListUsersResponse+        request = get mq+        response+          = receiveJSON+              (\ s h x ->+                 ListUsersResponse' <$>+                   (x .?> "users" .!@ mempty) <*> (x .?> "nextToken")+                     <*> (x .?> "brokerId")+                     <*> (x .?> "maxResults")+                     <*> (pure (fromEnum s)))++instance Hashable ListUsers where++instance NFData ListUsers where++instance ToHeaders ListUsers where+        toHeaders+          = const+              (mconcat+                 ["Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToPath ListUsers where+        toPath ListUsers'{..}+          = mconcat+              ["/v1/brokers/", toBS _luBrokerId, "/users"]++instance ToQuery ListUsers where+        toQuery ListUsers'{..}+          = mconcat+              ["nextToken" =: _luNextToken,+               "maxResults" =: _luMaxResults]++-- | /See:/ 'listUsersResponse' smart constructor.+data ListUsersResponse = ListUsersResponse'+  { _lursUsers          :: !(Maybe [UserSummary])+  , _lursNextToken      :: !(Maybe Text)+  , _lursBrokerId       :: !(Maybe Text)+  , _lursMaxResults     :: !(Maybe Int)+  , _lursResponseStatus :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'ListUsersResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'lursUsers' - Required. The list of all ActiveMQ usernames for the specified broker.+--+-- * 'lursNextToken' - The token that specifies the next page of results Amazon MQ should return. To request the first page, leave nextToken empty.+--+-- * 'lursBrokerId' - Required. The unique ID that Amazon MQ generates for the broker.+--+-- * 'lursMaxResults' - Required. The maximum number of ActiveMQ users that can be returned per page (20 by default). This value must be an integer from 5 to 100.+--+-- * 'lursResponseStatus' - -- | The response status code.+listUsersResponse+    :: Int -- ^ 'lursResponseStatus'+    -> ListUsersResponse+listUsersResponse pResponseStatus_ =+  ListUsersResponse'+    { _lursUsers = Nothing+    , _lursNextToken = Nothing+    , _lursBrokerId = Nothing+    , _lursMaxResults = Nothing+    , _lursResponseStatus = pResponseStatus_+    }+++-- | Required. The list of all ActiveMQ usernames for the specified broker.+lursUsers :: Lens' ListUsersResponse [UserSummary]+lursUsers = lens _lursUsers (\ s a -> s{_lursUsers = a}) . _Default . _Coerce++-- | The token that specifies the next page of results Amazon MQ should return. To request the first page, leave nextToken empty.+lursNextToken :: Lens' ListUsersResponse (Maybe Text)+lursNextToken = lens _lursNextToken (\ s a -> s{_lursNextToken = a})++-- | Required. The unique ID that Amazon MQ generates for the broker.+lursBrokerId :: Lens' ListUsersResponse (Maybe Text)+lursBrokerId = lens _lursBrokerId (\ s a -> s{_lursBrokerId = a})++-- | Required. The maximum number of ActiveMQ users that can be returned per page (20 by default). This value must be an integer from 5 to 100.+lursMaxResults :: Lens' ListUsersResponse (Maybe Int)+lursMaxResults = lens _lursMaxResults (\ s a -> s{_lursMaxResults = a})++-- | -- | The response status code.+lursResponseStatus :: Lens' ListUsersResponse Int+lursResponseStatus = lens _lursResponseStatus (\ s a -> s{_lursResponseStatus = a})++instance NFData ListUsersResponse where
+ gen/Network/AWS/MQ/RebootBroker.hs view
@@ -0,0 +1,117 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.RebootBroker+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Reboots a broker. Note: This API is asynchronous.+module Network.AWS.MQ.RebootBroker+    (+    -- * Creating a Request+      rebootBroker+    , RebootBroker+    -- * Request Lenses+    , rbBrokerId++    -- * Destructuring the Response+    , rebootBrokerResponse+    , RebootBrokerResponse+    -- * Response Lenses+    , rbrsResponseStatus+    ) where++import Network.AWS.Lens+import Network.AWS.MQ.Types+import Network.AWS.MQ.Types.Product+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'rebootBroker' smart constructor.+newtype RebootBroker = RebootBroker'+  { _rbBrokerId :: Text+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'RebootBroker' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'rbBrokerId' - The unique ID that Amazon MQ generates for the broker.+rebootBroker+    :: Text -- ^ 'rbBrokerId'+    -> RebootBroker+rebootBroker pBrokerId_ = RebootBroker' {_rbBrokerId = pBrokerId_}+++-- | The unique ID that Amazon MQ generates for the broker.+rbBrokerId :: Lens' RebootBroker Text+rbBrokerId = lens _rbBrokerId (\ s a -> s{_rbBrokerId = a})++instance AWSRequest RebootBroker where+        type Rs RebootBroker = RebootBrokerResponse+        request = postJSON mq+        response+          = receiveEmpty+              (\ s h x ->+                 RebootBrokerResponse' <$> (pure (fromEnum s)))++instance Hashable RebootBroker where++instance NFData RebootBroker where++instance ToHeaders RebootBroker where+        toHeaders+          = const+              (mconcat+                 ["Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToJSON RebootBroker where+        toJSON = const (Object mempty)++instance ToPath RebootBroker where+        toPath RebootBroker'{..}+          = mconcat+              ["/v1/brokers/", toBS _rbBrokerId, "/reboot"]++instance ToQuery RebootBroker where+        toQuery = const mempty++-- | /See:/ 'rebootBrokerResponse' smart constructor.+newtype RebootBrokerResponse = RebootBrokerResponse'+  { _rbrsResponseStatus :: Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'RebootBrokerResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'rbrsResponseStatus' - -- | The response status code.+rebootBrokerResponse+    :: Int -- ^ 'rbrsResponseStatus'+    -> RebootBrokerResponse+rebootBrokerResponse pResponseStatus_ =+  RebootBrokerResponse' {_rbrsResponseStatus = pResponseStatus_}+++-- | -- | The response status code.+rbrsResponseStatus :: Lens' RebootBrokerResponse Int+rbrsResponseStatus = lens _rbrsResponseStatus (\ s a -> s{_rbrsResponseStatus = a})++instance NFData RebootBrokerResponse where
+ gen/Network/AWS/MQ/Types.hs view
@@ -0,0 +1,202 @@+{-# LANGUAGE OverloadedStrings #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.Types+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+module Network.AWS.MQ.Types+    (+    -- * Service Configuration+      mq++    -- * Errors+    , _ConflictException+    , _ForbiddenException+    , _NotFoundException+    , _InternalServerErrorException+    , _UnauthorizedException+    , _BadRequestException++    -- * BrokerState+    , BrokerState (..)++    -- * ChangeType+    , ChangeType (..)++    -- * DayOfWeek+    , DayOfWeek (..)++    -- * DeploymentMode+    , DeploymentMode (..)++    -- * EngineType+    , EngineType (..)++    -- * SanitizationWarningReason+    , SanitizationWarningReason (..)++    -- * BrokerInstance+    , BrokerInstance+    , brokerInstance+    , biConsoleURL+    , biEndpoints++    -- * BrokerSummary+    , BrokerSummary+    , brokerSummary+    , bsBrokerName+    , bsBrokerState+    , bsDeploymentMode+    , bsBrokerId+    , bsBrokerARN+    , bsHostInstanceType++    -- * Configuration+    , Configuration+    , configuration+    , cEngineVersion+    , cARN+    , cLatestRevision+    , cName+    , cId+    , cDescription+    , cEngineType++    -- * ConfigurationId+    , ConfigurationId+    , configurationId+    , ciId+    , ciRevision++    -- * ConfigurationRevision+    , ConfigurationRevision+    , configurationRevision+    , crRevision+    , crDescription++    -- * Configurations+    , Configurations+    , configurations+    , cPending+    , cHistory+    , cCurrent++    -- * SanitizationWarning+    , SanitizationWarning+    , sanitizationWarning+    , swReason+    , swAttributeName+    , swElementName++    -- * User+    , User+    , user+    , uGroups+    , uConsoleAccess+    , uUsername+    , uPassword++    -- * UserPendingChanges+    , UserPendingChanges+    , userPendingChanges+    , upcGroups+    , upcConsoleAccess+    , upcPendingChange++    -- * UserSummary+    , UserSummary+    , userSummary+    , usUsername+    , usPendingChange++    -- * WeeklyStartTime+    , WeeklyStartTime+    , weeklyStartTime+    , wstTimeOfDay+    , wstTimeZone+    , wstDayOfWeek+    ) where++import Network.AWS.Lens+import Network.AWS.MQ.Types.Product+import Network.AWS.MQ.Types.Sum+import Network.AWS.Prelude+import Network.AWS.Sign.V4++-- | API version @2017-11-27@ of the Amazon MQ SDK configuration.+mq :: Service+mq =+  Service+    { _svcAbbrev = "MQ"+    , _svcSigner = v4+    , _svcPrefix = "mq"+    , _svcVersion = "2017-11-27"+    , _svcEndpoint = defaultEndpoint mq+    , _svcTimeout = Just 70+    , _svcCheck = statusSuccess+    , _svcError = parseJSONError "MQ"+    , _svcRetry = retry+    }+  where+    retry =+      Exponential+        { _retryBase = 5.0e-2+        , _retryGrowth = 2+        , _retryAttempts = 5+        , _retryCheck = check+        }+    check e+      | has (hasCode "ThrottledException" . hasStatus 400) e =+        Just "throttled_exception"+      | has (hasStatus 429) e = Just "too_many_requests"+      | has (hasCode "ThrottlingException" . hasStatus 400) e =+        Just "throttling_exception"+      | has (hasCode "Throttling" . hasStatus 400) e = Just "throttling"+      | has (hasStatus 504) e = Just "gateway_timeout"+      | has (hasCode "RequestThrottledException" . hasStatus 400) e =+        Just "request_throttled_exception"+      | has (hasStatus 502) e = Just "bad_gateway"+      | has (hasStatus 503) e = Just "service_unavailable"+      | has (hasStatus 500) e = Just "general_server_error"+      | has (hasStatus 509) e = Just "limit_exceeded"+      | otherwise = Nothing+++-- | Returns information about an error.+_ConflictException :: AsError a => Getting (First ServiceError) a ServiceError+_ConflictException = _MatchServiceError mq "ConflictException" . hasStatus 409+++-- | Returns information about an error.+_ForbiddenException :: AsError a => Getting (First ServiceError) a ServiceError+_ForbiddenException = _MatchServiceError mq "ForbiddenException" . hasStatus 403+++-- | Returns information about an error.+_NotFoundException :: AsError a => Getting (First ServiceError) a ServiceError+_NotFoundException = _MatchServiceError mq "NotFoundException" . hasStatus 404+++-- | Returns information about an error.+_InternalServerErrorException :: AsError a => Getting (First ServiceError) a ServiceError+_InternalServerErrorException =+  _MatchServiceError mq "InternalServerErrorException" . hasStatus 500+++-- | Returns information about an error.+_UnauthorizedException :: AsError a => Getting (First ServiceError) a ServiceError+_UnauthorizedException =+  _MatchServiceError mq "UnauthorizedException" . hasStatus 401+++-- | Returns information about an error.+_BadRequestException :: AsError a => Getting (First ServiceError) a ServiceError+_BadRequestException =+  _MatchServiceError mq "BadRequestException" . hasStatus 400+
+ gen/Network/AWS/MQ/Types/Product.hs view
@@ -0,0 +1,635 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.Types.Product+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+module Network.AWS.MQ.Types.Product where++import Network.AWS.Lens+import Network.AWS.MQ.Types.Sum+import Network.AWS.Prelude++-- | Returns information about all brokers.+--+-- /See:/ 'brokerInstance' smart constructor.+data BrokerInstance = BrokerInstance'+  { _biConsoleURL :: !(Maybe Text)+  , _biEndpoints  :: !(Maybe [Text])+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'BrokerInstance' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'biConsoleURL' - The URL of the broker's ActiveMQ Web Console.+--+-- * 'biEndpoints' - The broker's wire-level protocol endpoints.+brokerInstance+    :: BrokerInstance+brokerInstance =+  BrokerInstance' {_biConsoleURL = Nothing, _biEndpoints = Nothing}+++-- | The URL of the broker's ActiveMQ Web Console.+biConsoleURL :: Lens' BrokerInstance (Maybe Text)+biConsoleURL = lens _biConsoleURL (\ s a -> s{_biConsoleURL = a})++-- | The broker's wire-level protocol endpoints.+biEndpoints :: Lens' BrokerInstance [Text]+biEndpoints = lens _biEndpoints (\ s a -> s{_biEndpoints = a}) . _Default . _Coerce++instance FromJSON BrokerInstance where+        parseJSON+          = withObject "BrokerInstance"+              (\ x ->+                 BrokerInstance' <$>+                   (x .:? "consoleURL") <*>+                     (x .:? "endpoints" .!= mempty))++instance Hashable BrokerInstance where++instance NFData BrokerInstance where++-- | The Amazon Resource Name (ARN) of the broker.+--+-- /See:/ 'brokerSummary' smart constructor.+data BrokerSummary = BrokerSummary'+  { _bsBrokerName       :: !(Maybe Text)+  , _bsBrokerState      :: !(Maybe BrokerState)+  , _bsDeploymentMode   :: !(Maybe DeploymentMode)+  , _bsBrokerId         :: !(Maybe Text)+  , _bsBrokerARN        :: !(Maybe Text)+  , _bsHostInstanceType :: !(Maybe Text)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'BrokerSummary' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'bsBrokerName' - The name of the broker. This value must be unique in your AWS account, 1-50 characters long, must contain only letters, numbers, dashes, and underscores, and must not contain whitespaces, brackets, wildcard characters, or special characters.+--+-- * 'bsBrokerState' - The status of the broker. Possible values: CREATION_IN_PROGRESS, CREATION_FAILED, DELETION_IN_PROGRESS, RUNNING, REBOOT_IN_PROGRESS+--+-- * 'bsDeploymentMode' - Required. The deployment mode of the broker. Possible values: SINGLE_INSTANCE, ACTIVE_STANDBY_MULTI_AZ SINGLE_INSTANCE creates a single-instance broker in a single Availability Zone. ACTIVE_STANDBY_MULTI_AZ creates an active/standby broker for high availability.+--+-- * 'bsBrokerId' - The unique ID that Amazon MQ generates for the broker.+--+-- * 'bsBrokerARN' - The Amazon Resource Name (ARN) of the broker.+--+-- * 'bsHostInstanceType' - The broker's instance type. Possible values: mq.t2.micro, mq.m4.large+brokerSummary+    :: BrokerSummary+brokerSummary =+  BrokerSummary'+    { _bsBrokerName = Nothing+    , _bsBrokerState = Nothing+    , _bsDeploymentMode = Nothing+    , _bsBrokerId = Nothing+    , _bsBrokerARN = Nothing+    , _bsHostInstanceType = Nothing+    }+++-- | The name of the broker. This value must be unique in your AWS account, 1-50 characters long, must contain only letters, numbers, dashes, and underscores, and must not contain whitespaces, brackets, wildcard characters, or special characters.+bsBrokerName :: Lens' BrokerSummary (Maybe Text)+bsBrokerName = lens _bsBrokerName (\ s a -> s{_bsBrokerName = a})++-- | The status of the broker. Possible values: CREATION_IN_PROGRESS, CREATION_FAILED, DELETION_IN_PROGRESS, RUNNING, REBOOT_IN_PROGRESS+bsBrokerState :: Lens' BrokerSummary (Maybe BrokerState)+bsBrokerState = lens _bsBrokerState (\ s a -> s{_bsBrokerState = a})++-- | Required. The deployment mode of the broker. Possible values: SINGLE_INSTANCE, ACTIVE_STANDBY_MULTI_AZ SINGLE_INSTANCE creates a single-instance broker in a single Availability Zone. ACTIVE_STANDBY_MULTI_AZ creates an active/standby broker for high availability.+bsDeploymentMode :: Lens' BrokerSummary (Maybe DeploymentMode)+bsDeploymentMode = lens _bsDeploymentMode (\ s a -> s{_bsDeploymentMode = a})++-- | The unique ID that Amazon MQ generates for the broker.+bsBrokerId :: Lens' BrokerSummary (Maybe Text)+bsBrokerId = lens _bsBrokerId (\ s a -> s{_bsBrokerId = a})++-- | The Amazon Resource Name (ARN) of the broker.+bsBrokerARN :: Lens' BrokerSummary (Maybe Text)+bsBrokerARN = lens _bsBrokerARN (\ s a -> s{_bsBrokerARN = a})++-- | The broker's instance type. Possible values: mq.t2.micro, mq.m4.large+bsHostInstanceType :: Lens' BrokerSummary (Maybe Text)+bsHostInstanceType = lens _bsHostInstanceType (\ s a -> s{_bsHostInstanceType = a})++instance FromJSON BrokerSummary where+        parseJSON+          = withObject "BrokerSummary"+              (\ x ->+                 BrokerSummary' <$>+                   (x .:? "brokerName") <*> (x .:? "brokerState") <*>+                     (x .:? "deploymentMode")+                     <*> (x .:? "brokerId")+                     <*> (x .:? "brokerArn")+                     <*> (x .:? "hostInstanceType"))++instance Hashable BrokerSummary where++instance NFData BrokerSummary where++-- | Returns information about all configurations.+--+-- /See:/ 'configuration' smart constructor.+data Configuration = Configuration'+  { _cEngineVersion  :: !(Maybe Text)+  , _cARN            :: !(Maybe Text)+  , _cLatestRevision :: !(Maybe ConfigurationRevision)+  , _cName           :: !(Maybe Text)+  , _cId             :: !(Maybe Text)+  , _cDescription    :: !(Maybe Text)+  , _cEngineType     :: !(Maybe EngineType)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'Configuration' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'cEngineVersion' - Required. The version of the broker engine.+--+-- * 'cARN' - Required. The ARN of the configuration.+--+-- * 'cLatestRevision' - Required. The latest revision of the configuration.+--+-- * 'cName' - Required. The name of the configuration. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 1-150 characters long.+--+-- * 'cId' - Required. The unique ID that Amazon MQ generates for the configuration.+--+-- * 'cDescription' - Required. The description of the configuration.+--+-- * 'cEngineType' - Required. The type of broker engine. Note: Currently, Amazon MQ supports only ACTIVEMQ.+configuration+    :: Configuration+configuration =+  Configuration'+    { _cEngineVersion = Nothing+    , _cARN = Nothing+    , _cLatestRevision = Nothing+    , _cName = Nothing+    , _cId = Nothing+    , _cDescription = Nothing+    , _cEngineType = Nothing+    }+++-- | Required. The version of the broker engine.+cEngineVersion :: Lens' Configuration (Maybe Text)+cEngineVersion = lens _cEngineVersion (\ s a -> s{_cEngineVersion = a})++-- | Required. The ARN of the configuration.+cARN :: Lens' Configuration (Maybe Text)+cARN = lens _cARN (\ s a -> s{_cARN = a})++-- | Required. The latest revision of the configuration.+cLatestRevision :: Lens' Configuration (Maybe ConfigurationRevision)+cLatestRevision = lens _cLatestRevision (\ s a -> s{_cLatestRevision = a})++-- | Required. The name of the configuration. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 1-150 characters long.+cName :: Lens' Configuration (Maybe Text)+cName = lens _cName (\ s a -> s{_cName = a})++-- | Required. The unique ID that Amazon MQ generates for the configuration.+cId :: Lens' Configuration (Maybe Text)+cId = lens _cId (\ s a -> s{_cId = a})++-- | Required. The description of the configuration.+cDescription :: Lens' Configuration (Maybe Text)+cDescription = lens _cDescription (\ s a -> s{_cDescription = a})++-- | Required. The type of broker engine. Note: Currently, Amazon MQ supports only ACTIVEMQ.+cEngineType :: Lens' Configuration (Maybe EngineType)+cEngineType = lens _cEngineType (\ s a -> s{_cEngineType = a})++instance FromJSON Configuration where+        parseJSON+          = withObject "Configuration"+              (\ x ->+                 Configuration' <$>+                   (x .:? "engineVersion") <*> (x .:? "arn") <*>+                     (x .:? "latestRevision")+                     <*> (x .:? "name")+                     <*> (x .:? "id")+                     <*> (x .:? "description")+                     <*> (x .:? "engineType"))++instance Hashable Configuration where++instance NFData Configuration where++-- | A list of information about the configuration.+--+-- /See:/ 'configurationId' smart constructor.+data ConfigurationId = ConfigurationId'+  { _ciId       :: !(Maybe Text)+  , _ciRevision :: !(Maybe Int)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'ConfigurationId' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'ciId' - Required. The unique ID that Amazon MQ generates for the configuration.+--+-- * 'ciRevision' - The Universally Unique Identifier (UUID) of the request.+configurationId+    :: ConfigurationId+configurationId = ConfigurationId' {_ciId = Nothing, _ciRevision = Nothing}+++-- | Required. The unique ID that Amazon MQ generates for the configuration.+ciId :: Lens' ConfigurationId (Maybe Text)+ciId = lens _ciId (\ s a -> s{_ciId = a})++-- | The Universally Unique Identifier (UUID) of the request.+ciRevision :: Lens' ConfigurationId (Maybe Int)+ciRevision = lens _ciRevision (\ s a -> s{_ciRevision = a})++instance FromJSON ConfigurationId where+        parseJSON+          = withObject "ConfigurationId"+              (\ x ->+                 ConfigurationId' <$>+                   (x .:? "id") <*> (x .:? "revision"))++instance Hashable ConfigurationId where++instance NFData ConfigurationId where++instance ToJSON ConfigurationId where+        toJSON ConfigurationId'{..}+          = object+              (catMaybes+                 [("id" .=) <$> _ciId,+                  ("revision" .=) <$> _ciRevision])++-- | Returns information about the specified configuration revision.+--+-- /See:/ 'configurationRevision' smart constructor.+data ConfigurationRevision = ConfigurationRevision'+  { _crRevision    :: !(Maybe Int)+  , _crDescription :: !(Maybe Text)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'ConfigurationRevision' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'crRevision' - Required. The revision of the configuration.+--+-- * 'crDescription' - The description of the configuration revision.+configurationRevision+    :: ConfigurationRevision+configurationRevision =+  ConfigurationRevision' {_crRevision = Nothing, _crDescription = Nothing}+++-- | Required. The revision of the configuration.+crRevision :: Lens' ConfigurationRevision (Maybe Int)+crRevision = lens _crRevision (\ s a -> s{_crRevision = a})++-- | The description of the configuration revision.+crDescription :: Lens' ConfigurationRevision (Maybe Text)+crDescription = lens _crDescription (\ s a -> s{_crDescription = a})++instance FromJSON ConfigurationRevision where+        parseJSON+          = withObject "ConfigurationRevision"+              (\ x ->+                 ConfigurationRevision' <$>+                   (x .:? "revision") <*> (x .:? "description"))++instance Hashable ConfigurationRevision where++instance NFData ConfigurationRevision where++-- | Broker configuration information+--+-- /See:/ 'configurations' smart constructor.+data Configurations = Configurations'+  { _cPending :: !(Maybe ConfigurationId)+  , _cHistory :: !(Maybe [ConfigurationId])+  , _cCurrent :: !(Maybe ConfigurationId)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'Configurations' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'cPending' - The pending configuration of the broker.+--+-- * 'cHistory' - The history of configurations applied to the broker.+--+-- * 'cCurrent' - The current configuration of the broker.+configurations+    :: Configurations+configurations =+  Configurations'+    {_cPending = Nothing, _cHistory = Nothing, _cCurrent = Nothing}+++-- | The pending configuration of the broker.+cPending :: Lens' Configurations (Maybe ConfigurationId)+cPending = lens _cPending (\ s a -> s{_cPending = a})++-- | The history of configurations applied to the broker.+cHistory :: Lens' Configurations [ConfigurationId]+cHistory = lens _cHistory (\ s a -> s{_cHistory = a}) . _Default . _Coerce++-- | The current configuration of the broker.+cCurrent :: Lens' Configurations (Maybe ConfigurationId)+cCurrent = lens _cCurrent (\ s a -> s{_cCurrent = a})++instance FromJSON Configurations where+        parseJSON+          = withObject "Configurations"+              (\ x ->+                 Configurations' <$>+                   (x .:? "pending") <*> (x .:? "history" .!= mempty)+                     <*> (x .:? "current"))++instance Hashable Configurations where++instance NFData Configurations where++-- | Returns information about the XML element or attribute that was sanitized in the configuration.+--+-- /See:/ 'sanitizationWarning' smart constructor.+data SanitizationWarning = SanitizationWarning'+  { _swReason        :: !(Maybe SanitizationWarningReason)+  , _swAttributeName :: !(Maybe Text)+  , _swElementName   :: !(Maybe Text)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'SanitizationWarning' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'swReason' - Required. The reason for which the XML elements or attributes were sanitized. Possible values: DISALLOWED_ELEMENT_REMOVED, DISALLOWED_ATTRIBUTE_REMOVED, INVALID_ATTRIBUTE_VALUE_REMOVED DISALLOWED_ELEMENT_REMOVED shows that the provided element isn't allowed and has been removed. DISALLOWED_ATTRIBUTE_REMOVED shows that the provided attribute isn't allowed and has been removed. INVALID_ATTRIBUTE_VALUE_REMOVED shows that the provided value for the attribute isn't allowed and has been removed.+--+-- * 'swAttributeName' - The name of the XML attribute that has been sanitized.+--+-- * 'swElementName' - The name of the XML element that has been sanitized.+sanitizationWarning+    :: SanitizationWarning+sanitizationWarning =+  SanitizationWarning'+    {_swReason = Nothing, _swAttributeName = Nothing, _swElementName = Nothing}+++-- | Required. The reason for which the XML elements or attributes were sanitized. Possible values: DISALLOWED_ELEMENT_REMOVED, DISALLOWED_ATTRIBUTE_REMOVED, INVALID_ATTRIBUTE_VALUE_REMOVED DISALLOWED_ELEMENT_REMOVED shows that the provided element isn't allowed and has been removed. DISALLOWED_ATTRIBUTE_REMOVED shows that the provided attribute isn't allowed and has been removed. INVALID_ATTRIBUTE_VALUE_REMOVED shows that the provided value for the attribute isn't allowed and has been removed.+swReason :: Lens' SanitizationWarning (Maybe SanitizationWarningReason)+swReason = lens _swReason (\ s a -> s{_swReason = a})++-- | The name of the XML attribute that has been sanitized.+swAttributeName :: Lens' SanitizationWarning (Maybe Text)+swAttributeName = lens _swAttributeName (\ s a -> s{_swAttributeName = a})++-- | The name of the XML element that has been sanitized.+swElementName :: Lens' SanitizationWarning (Maybe Text)+swElementName = lens _swElementName (\ s a -> s{_swElementName = a})++instance FromJSON SanitizationWarning where+        parseJSON+          = withObject "SanitizationWarning"+              (\ x ->+                 SanitizationWarning' <$>+                   (x .:? "reason") <*> (x .:? "attributeName") <*>+                     (x .:? "elementName"))++instance Hashable SanitizationWarning where++instance NFData SanitizationWarning where++-- | An ActiveMQ user associated with the broker.+--+-- /See:/ 'user' smart constructor.+data User = User'+  { _uGroups        :: !(Maybe [Text])+  , _uConsoleAccess :: !(Maybe Bool)+  , _uUsername      :: !(Maybe Text)+  , _uPassword      :: !(Maybe Text)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'User' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'uGroups' - The list of groups (20 maximum) to which the ActiveMQ user belongs. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+--+-- * 'uConsoleAccess' - Enables access to the the ActiveMQ Web Console for the ActiveMQ user.+--+-- * 'uUsername' - Required. The username of the ActiveMQ user. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+--+-- * 'uPassword' - Required. The password of the ActiveMQ user. This value must be at least 12 characters long, must contain at least 4 unique characters, and must not contain commas.+user+    :: User+user =+  User'+    { _uGroups = Nothing+    , _uConsoleAccess = Nothing+    , _uUsername = Nothing+    , _uPassword = Nothing+    }+++-- | The list of groups (20 maximum) to which the ActiveMQ user belongs. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+uGroups :: Lens' User [Text]+uGroups = lens _uGroups (\ s a -> s{_uGroups = a}) . _Default . _Coerce++-- | Enables access to the the ActiveMQ Web Console for the ActiveMQ user.+uConsoleAccess :: Lens' User (Maybe Bool)+uConsoleAccess = lens _uConsoleAccess (\ s a -> s{_uConsoleAccess = a})++-- | Required. The username of the ActiveMQ user. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+uUsername :: Lens' User (Maybe Text)+uUsername = lens _uUsername (\ s a -> s{_uUsername = a})++-- | Required. The password of the ActiveMQ user. This value must be at least 12 characters long, must contain at least 4 unique characters, and must not contain commas.+uPassword :: Lens' User (Maybe Text)+uPassword = lens _uPassword (\ s a -> s{_uPassword = a})++instance Hashable User where++instance NFData User where++instance ToJSON User where+        toJSON User'{..}+          = object+              (catMaybes+                 [("groups" .=) <$> _uGroups,+                  ("consoleAccess" .=) <$> _uConsoleAccess,+                  ("username" .=) <$> _uUsername,+                  ("password" .=) <$> _uPassword])++-- | Returns information about the status of the changes pending for the ActiveMQ user.+--+-- /See:/ 'userPendingChanges' smart constructor.+data UserPendingChanges = UserPendingChanges'+  { _upcGroups        :: !(Maybe [Text])+  , _upcConsoleAccess :: !(Maybe Bool)+  , _upcPendingChange :: !(Maybe ChangeType)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'UserPendingChanges' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'upcGroups' - The list of groups (20 maximum) to which the ActiveMQ user belongs. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+--+-- * 'upcConsoleAccess' - Enables access to the the ActiveMQ Web Console for the ActiveMQ user.+--+-- * 'upcPendingChange' - Required. The type of change pending for the ActiveMQ user. Possible values: CREATE, UPDATE, DELETE+userPendingChanges+    :: UserPendingChanges+userPendingChanges =+  UserPendingChanges'+    { _upcGroups = Nothing+    , _upcConsoleAccess = Nothing+    , _upcPendingChange = Nothing+    }+++-- | The list of groups (20 maximum) to which the ActiveMQ user belongs. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+upcGroups :: Lens' UserPendingChanges [Text]+upcGroups = lens _upcGroups (\ s a -> s{_upcGroups = a}) . _Default . _Coerce++-- | Enables access to the the ActiveMQ Web Console for the ActiveMQ user.+upcConsoleAccess :: Lens' UserPendingChanges (Maybe Bool)+upcConsoleAccess = lens _upcConsoleAccess (\ s a -> s{_upcConsoleAccess = a})++-- | Required. The type of change pending for the ActiveMQ user. Possible values: CREATE, UPDATE, DELETE+upcPendingChange :: Lens' UserPendingChanges (Maybe ChangeType)+upcPendingChange = lens _upcPendingChange (\ s a -> s{_upcPendingChange = a})++instance FromJSON UserPendingChanges where+        parseJSON+          = withObject "UserPendingChanges"+              (\ x ->+                 UserPendingChanges' <$>+                   (x .:? "groups" .!= mempty) <*>+                     (x .:? "consoleAccess")+                     <*> (x .:? "pendingChange"))++instance Hashable UserPendingChanges where++instance NFData UserPendingChanges where++-- | Returns a list of all ActiveMQ users.+--+-- /See:/ 'userSummary' smart constructor.+data UserSummary = UserSummary'+  { _usUsername      :: !(Maybe Text)+  , _usPendingChange :: !(Maybe ChangeType)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'UserSummary' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'usUsername' - Required. The username of the ActiveMQ user. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+--+-- * 'usPendingChange' - The type of change pending for the ActiveMQ user. Possible values: CREATE, UPDATE, DELETE+userSummary+    :: UserSummary+userSummary = UserSummary' {_usUsername = Nothing, _usPendingChange = Nothing}+++-- | Required. The username of the ActiveMQ user. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+usUsername :: Lens' UserSummary (Maybe Text)+usUsername = lens _usUsername (\ s a -> s{_usUsername = a})++-- | The type of change pending for the ActiveMQ user. Possible values: CREATE, UPDATE, DELETE+usPendingChange :: Lens' UserSummary (Maybe ChangeType)+usPendingChange = lens _usPendingChange (\ s a -> s{_usPendingChange = a})++instance FromJSON UserSummary where+        parseJSON+          = withObject "UserSummary"+              (\ x ->+                 UserSummary' <$>+                   (x .:? "username") <*> (x .:? "pendingChange"))++instance Hashable UserSummary where++instance NFData UserSummary where++-- | The scheduled time period relative to UTC during which Amazon MQ begins to apply pending updates or patches to the broker.+--+-- /See:/ 'weeklyStartTime' smart constructor.+data WeeklyStartTime = WeeklyStartTime'+  { _wstTimeOfDay :: !(Maybe Text)+  , _wstTimeZone  :: !(Maybe Text)+  , _wstDayOfWeek :: !(Maybe DayOfWeek)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'WeeklyStartTime' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'wstTimeOfDay' - Required. The time, in 24-hour format.+--+-- * 'wstTimeZone' - The time zone, UTC by default, in either the Country/City format, or the UTC offset format.+--+-- * 'wstDayOfWeek' - Required. The day of the week. Possible values: MONDAY, TUESDAY, WEDNESDAY, THURSDAY, FRIDAY, SATURDAY, SUNDAY+weeklyStartTime+    :: WeeklyStartTime+weeklyStartTime =+  WeeklyStartTime'+    {_wstTimeOfDay = Nothing, _wstTimeZone = Nothing, _wstDayOfWeek = Nothing}+++-- | Required. The time, in 24-hour format.+wstTimeOfDay :: Lens' WeeklyStartTime (Maybe Text)+wstTimeOfDay = lens _wstTimeOfDay (\ s a -> s{_wstTimeOfDay = a})++-- | The time zone, UTC by default, in either the Country/City format, or the UTC offset format.+wstTimeZone :: Lens' WeeklyStartTime (Maybe Text)+wstTimeZone = lens _wstTimeZone (\ s a -> s{_wstTimeZone = a})++-- | Required. The day of the week. Possible values: MONDAY, TUESDAY, WEDNESDAY, THURSDAY, FRIDAY, SATURDAY, SUNDAY+wstDayOfWeek :: Lens' WeeklyStartTime (Maybe DayOfWeek)+wstDayOfWeek = lens _wstDayOfWeek (\ s a -> s{_wstDayOfWeek = a})++instance FromJSON WeeklyStartTime where+        parseJSON+          = withObject "WeeklyStartTime"+              (\ x ->+                 WeeklyStartTime' <$>+                   (x .:? "timeOfDay") <*> (x .:? "timeZone") <*>+                     (x .:? "dayOfWeek"))++instance Hashable WeeklyStartTime where++instance NFData WeeklyStartTime where++instance ToJSON WeeklyStartTime where+        toJSON WeeklyStartTime'{..}+          = object+              (catMaybes+                 [("timeOfDay" .=) <$> _wstTimeOfDay,+                  ("timeZone" .=) <$> _wstTimeZone,+                  ("dayOfWeek" .=) <$> _wstDayOfWeek])
+ gen/Network/AWS/MQ/Types/Sum.hs view
@@ -0,0 +1,223 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE LambdaCase         #-}+{-# LANGUAGE OverloadedStrings  #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.Types.Sum+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+module Network.AWS.MQ.Types.Sum where++import Network.AWS.Prelude++-- | The status of the broker. Possible values: CREATION_IN_PROGRESS, CREATION_FAILED, DELETION_IN_PROGRESS, RUNNING, REBOOT_IN_PROGRESS+data BrokerState+  = CreationFailed+  | CreationInProgress+  | DeletionInProgress+  | RebootInProgress+  | Running+  deriving (Eq, Ord, Read, Show, Enum, Bounded, Data, Typeable, Generic)+++instance FromText BrokerState where+    parser = takeLowerText >>= \case+        "creation_failed" -> pure CreationFailed+        "creation_in_progress" -> pure CreationInProgress+        "deletion_in_progress" -> pure DeletionInProgress+        "reboot_in_progress" -> pure RebootInProgress+        "running" -> pure Running+        e -> fromTextError $ "Failure parsing BrokerState from value: '" <> e+           <> "'. Accepted values: creation_failed, creation_in_progress, deletion_in_progress, reboot_in_progress, running"++instance ToText BrokerState where+    toText = \case+        CreationFailed -> "CREATION_FAILED"+        CreationInProgress -> "CREATION_IN_PROGRESS"+        DeletionInProgress -> "DELETION_IN_PROGRESS"+        RebootInProgress -> "REBOOT_IN_PROGRESS"+        Running -> "RUNNING"++instance Hashable     BrokerState+instance NFData       BrokerState+instance ToByteString BrokerState+instance ToQuery      BrokerState+instance ToHeader     BrokerState++instance FromJSON BrokerState where+    parseJSON = parseJSONText "BrokerState"++-- | The type of change pending for the ActiveMQ user. Possible values: CREATE, UPDATE, DELETE+data ChangeType+  = Create+  | Delete+  | Update+  deriving (Eq, Ord, Read, Show, Enum, Bounded, Data, Typeable, Generic)+++instance FromText ChangeType where+    parser = takeLowerText >>= \case+        "create" -> pure Create+        "delete" -> pure Delete+        "update" -> pure Update+        e -> fromTextError $ "Failure parsing ChangeType from value: '" <> e+           <> "'. Accepted values: create, delete, update"++instance ToText ChangeType where+    toText = \case+        Create -> "CREATE"+        Delete -> "DELETE"+        Update -> "UPDATE"++instance Hashable     ChangeType+instance NFData       ChangeType+instance ToByteString ChangeType+instance ToQuery      ChangeType+instance ToHeader     ChangeType++instance FromJSON ChangeType where+    parseJSON = parseJSONText "ChangeType"++data DayOfWeek+  = Friday+  | Monday+  | Saturday+  | Sunday+  | Thursday+  | Tuesday+  | Wednesday+  deriving (Eq, Ord, Read, Show, Enum, Bounded, Data, Typeable, Generic)+++instance FromText DayOfWeek where+    parser = takeLowerText >>= \case+        "friday" -> pure Friday+        "monday" -> pure Monday+        "saturday" -> pure Saturday+        "sunday" -> pure Sunday+        "thursday" -> pure Thursday+        "tuesday" -> pure Tuesday+        "wednesday" -> pure Wednesday+        e -> fromTextError $ "Failure parsing DayOfWeek from value: '" <> e+           <> "'. Accepted values: friday, monday, saturday, sunday, thursday, tuesday, wednesday"++instance ToText DayOfWeek where+    toText = \case+        Friday -> "FRIDAY"+        Monday -> "MONDAY"+        Saturday -> "SATURDAY"+        Sunday -> "SUNDAY"+        Thursday -> "THURSDAY"+        Tuesday -> "TUESDAY"+        Wednesday -> "WEDNESDAY"++instance Hashable     DayOfWeek+instance NFData       DayOfWeek+instance ToByteString DayOfWeek+instance ToQuery      DayOfWeek+instance ToHeader     DayOfWeek++instance ToJSON DayOfWeek where+    toJSON = toJSONText++instance FromJSON DayOfWeek where+    parseJSON = parseJSONText "DayOfWeek"++-- | The deployment mode of the broker. Possible values: SINGLE_INSTANCE, ACTIVE_STANDBY_MULTI_AZ SINGLE_INSTANCE creates a single-instance broker in a single Availability Zone. ACTIVE_STANDBY_MULTI_AZ creates an active/standby broker for high availability.+data DeploymentMode+  = ActiveStandbyMultiAz+  | SingleInstance+  deriving (Eq, Ord, Read, Show, Enum, Bounded, Data, Typeable, Generic)+++instance FromText DeploymentMode where+    parser = takeLowerText >>= \case+        "active_standby_multi_az" -> pure ActiveStandbyMultiAz+        "single_instance" -> pure SingleInstance+        e -> fromTextError $ "Failure parsing DeploymentMode from value: '" <> e+           <> "'. Accepted values: active_standby_multi_az, single_instance"++instance ToText DeploymentMode where+    toText = \case+        ActiveStandbyMultiAz -> "ACTIVE_STANDBY_MULTI_AZ"+        SingleInstance -> "SINGLE_INSTANCE"++instance Hashable     DeploymentMode+instance NFData       DeploymentMode+instance ToByteString DeploymentMode+instance ToQuery      DeploymentMode+instance ToHeader     DeploymentMode++instance ToJSON DeploymentMode where+    toJSON = toJSONText++instance FromJSON DeploymentMode where+    parseJSON = parseJSONText "DeploymentMode"++-- | The type of broker engine. Note: Currently, Amazon MQ supports only ActiveMQ.+data EngineType =+  Activemq+  deriving (Eq, Ord, Read, Show, Enum, Bounded, Data, Typeable, Generic)+++instance FromText EngineType where+    parser = takeLowerText >>= \case+        "activemq" -> pure Activemq+        e -> fromTextError $ "Failure parsing EngineType from value: '" <> e+           <> "'. Accepted values: activemq"++instance ToText EngineType where+    toText = \case+        Activemq -> "ACTIVEMQ"++instance Hashable     EngineType+instance NFData       EngineType+instance ToByteString EngineType+instance ToQuery      EngineType+instance ToHeader     EngineType++instance ToJSON EngineType where+    toJSON = toJSONText++instance FromJSON EngineType where+    parseJSON = parseJSONText "EngineType"++-- | The reason for which the XML elements or attributes were sanitized. Possible values: DISALLOWED_ELEMENT_REMOVED, DISALLOWED_ATTRIBUTE_REMOVED, INVALID_ATTRIBUTE_VALUE_REMOVED DISALLOWED_ELEMENT_REMOVED shows that the provided element isn't allowed and has been removed. DISALLOWED_ATTRIBUTE_REMOVED shows that the provided attribute isn't allowed and has been removed. INVALID_ATTRIBUTE_VALUE_REMOVED shows that the provided value for the attribute isn't allowed and has been removed.+data SanitizationWarningReason+  = DisallowedAttributeRemoved+  | DisallowedElementRemoved+  | InvalidAttributeValueRemoved+  deriving (Eq, Ord, Read, Show, Enum, Bounded, Data, Typeable, Generic)+++instance FromText SanitizationWarningReason where+    parser = takeLowerText >>= \case+        "disallowed_attribute_removed" -> pure DisallowedAttributeRemoved+        "disallowed_element_removed" -> pure DisallowedElementRemoved+        "invalid_attribute_value_removed" -> pure InvalidAttributeValueRemoved+        e -> fromTextError $ "Failure parsing SanitizationWarningReason from value: '" <> e+           <> "'. Accepted values: disallowed_attribute_removed, disallowed_element_removed, invalid_attribute_value_removed"++instance ToText SanitizationWarningReason where+    toText = \case+        DisallowedAttributeRemoved -> "DISALLOWED_ATTRIBUTE_REMOVED"+        DisallowedElementRemoved -> "DISALLOWED_ELEMENT_REMOVED"+        InvalidAttributeValueRemoved -> "INVALID_ATTRIBUTE_VALUE_REMOVED"++instance Hashable     SanitizationWarningReason+instance NFData       SanitizationWarningReason+instance ToByteString SanitizationWarningReason+instance ToQuery      SanitizationWarningReason+instance ToHeader     SanitizationWarningReason++instance FromJSON SanitizationWarningReason where+    parseJSON = parseJSONText "SanitizationWarningReason"
+ gen/Network/AWS/MQ/UpdateBroker.hs view
@@ -0,0 +1,152 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.UpdateBroker+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Adds a pending configuration change to a broker.+module Network.AWS.MQ.UpdateBroker+    (+    -- * Creating a Request+      updateBroker+    , UpdateBroker+    -- * Request Lenses+    , ubConfiguration+    , ubBrokerId++    -- * Destructuring the Response+    , updateBrokerResponse+    , UpdateBrokerResponse+    -- * Response Lenses+    , ubrsConfiguration+    , ubrsBrokerId+    , ubrsResponseStatus+    ) where++import Network.AWS.Lens+import Network.AWS.MQ.Types+import Network.AWS.MQ.Types.Product+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | Updates the broker using the specified properties.+--+-- /See:/ 'updateBroker' smart constructor.+data UpdateBroker = UpdateBroker'+  { _ubConfiguration :: !(Maybe ConfigurationId)+  , _ubBrokerId      :: !Text+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'UpdateBroker' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'ubConfiguration' - A list of information about the configuration.+--+-- * 'ubBrokerId' - The name of the broker. This value must be unique in your AWS account, 1-50 characters long, must contain only letters, numbers, dashes, and underscores, and must not contain whitespaces, brackets, wildcard characters, or special characters.+updateBroker+    :: Text -- ^ 'ubBrokerId'+    -> UpdateBroker+updateBroker pBrokerId_ =+  UpdateBroker' {_ubConfiguration = Nothing, _ubBrokerId = pBrokerId_}+++-- | A list of information about the configuration.+ubConfiguration :: Lens' UpdateBroker (Maybe ConfigurationId)+ubConfiguration = lens _ubConfiguration (\ s a -> s{_ubConfiguration = a})++-- | The name of the broker. This value must be unique in your AWS account, 1-50 characters long, must contain only letters, numbers, dashes, and underscores, and must not contain whitespaces, brackets, wildcard characters, or special characters.+ubBrokerId :: Lens' UpdateBroker Text+ubBrokerId = lens _ubBrokerId (\ s a -> s{_ubBrokerId = a})++instance AWSRequest UpdateBroker where+        type Rs UpdateBroker = UpdateBrokerResponse+        request = putJSON mq+        response+          = receiveJSON+              (\ s h x ->+                 UpdateBrokerResponse' <$>+                   (x .?> "configuration") <*> (x .?> "brokerId") <*>+                     (pure (fromEnum s)))++instance Hashable UpdateBroker where++instance NFData UpdateBroker where++instance ToHeaders UpdateBroker where+        toHeaders+          = const+              (mconcat+                 ["Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToJSON UpdateBroker where+        toJSON UpdateBroker'{..}+          = object+              (catMaybes+                 [("configuration" .=) <$> _ubConfiguration])++instance ToPath UpdateBroker where+        toPath UpdateBroker'{..}+          = mconcat ["/v1/brokers/", toBS _ubBrokerId]++instance ToQuery UpdateBroker where+        toQuery = const mempty++-- | /See:/ 'updateBrokerResponse' smart constructor.+data UpdateBrokerResponse = UpdateBrokerResponse'+  { _ubrsConfiguration  :: !(Maybe ConfigurationId)+  , _ubrsBrokerId       :: !(Maybe Text)+  , _ubrsResponseStatus :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'UpdateBrokerResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'ubrsConfiguration' - The ID of the updated configuration.+--+-- * 'ubrsBrokerId' - Required. The unique ID that Amazon MQ generates for the broker.+--+-- * 'ubrsResponseStatus' - -- | The response status code.+updateBrokerResponse+    :: Int -- ^ 'ubrsResponseStatus'+    -> UpdateBrokerResponse+updateBrokerResponse pResponseStatus_ =+  UpdateBrokerResponse'+    { _ubrsConfiguration = Nothing+    , _ubrsBrokerId = Nothing+    , _ubrsResponseStatus = pResponseStatus_+    }+++-- | The ID of the updated configuration.+ubrsConfiguration :: Lens' UpdateBrokerResponse (Maybe ConfigurationId)+ubrsConfiguration = lens _ubrsConfiguration (\ s a -> s{_ubrsConfiguration = a})++-- | Required. The unique ID that Amazon MQ generates for the broker.+ubrsBrokerId :: Lens' UpdateBrokerResponse (Maybe Text)+ubrsBrokerId = lens _ubrsBrokerId (\ s a -> s{_ubrsBrokerId = a})++-- | -- | The response status code.+ubrsResponseStatus :: Lens' UpdateBrokerResponse Int+ubrsResponseStatus = lens _ubrsResponseStatus (\ s a -> s{_ubrsResponseStatus = a})++instance NFData UpdateBrokerResponse where
+ gen/Network/AWS/MQ/UpdateConfiguration.hs view
@@ -0,0 +1,197 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.UpdateConfiguration+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Updates the specified configuration.+module Network.AWS.MQ.UpdateConfiguration+    (+    -- * Creating a Request+      updateConfiguration+    , UpdateConfiguration+    -- * Request Lenses+    , ucData+    , ucDescription+    , ucConfigurationId++    -- * Destructuring the Response+    , updateConfigurationResponse+    , UpdateConfigurationResponse+    -- * Response Lenses+    , ucrsARN+    , ucrsLatestRevision+    , ucrsWarnings+    , ucrsName+    , ucrsId+    , ucrsResponseStatus+    ) where++import Network.AWS.Lens+import Network.AWS.MQ.Types+import Network.AWS.MQ.Types.Product+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | Updates the specified configuration.+--+-- /See:/ 'updateConfiguration' smart constructor.+data UpdateConfiguration = UpdateConfiguration'+  { _ucData            :: !(Maybe Text)+  , _ucDescription     :: !(Maybe Text)+  , _ucConfigurationId :: !Text+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'UpdateConfiguration' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'ucData' - Required. The base64-encoded XML configuration.+--+-- * 'ucDescription' - The description of the configuration.+--+-- * 'ucConfigurationId' - The unique ID that Amazon MQ generates for the configuration.+updateConfiguration+    :: Text -- ^ 'ucConfigurationId'+    -> UpdateConfiguration+updateConfiguration pConfigurationId_ =+  UpdateConfiguration'+    { _ucData = Nothing+    , _ucDescription = Nothing+    , _ucConfigurationId = pConfigurationId_+    }+++-- | Required. The base64-encoded XML configuration.+ucData :: Lens' UpdateConfiguration (Maybe Text)+ucData = lens _ucData (\ s a -> s{_ucData = a})++-- | The description of the configuration.+ucDescription :: Lens' UpdateConfiguration (Maybe Text)+ucDescription = lens _ucDescription (\ s a -> s{_ucDescription = a})++-- | The unique ID that Amazon MQ generates for the configuration.+ucConfigurationId :: Lens' UpdateConfiguration Text+ucConfigurationId = lens _ucConfigurationId (\ s a -> s{_ucConfigurationId = a})++instance AWSRequest UpdateConfiguration where+        type Rs UpdateConfiguration =+             UpdateConfigurationResponse+        request = putJSON mq+        response+          = receiveJSON+              (\ s h x ->+                 UpdateConfigurationResponse' <$>+                   (x .?> "arn") <*> (x .?> "latestRevision") <*>+                     (x .?> "warnings" .!@ mempty)+                     <*> (x .?> "name")+                     <*> (x .?> "id")+                     <*> (pure (fromEnum s)))++instance Hashable UpdateConfiguration where++instance NFData UpdateConfiguration where++instance ToHeaders UpdateConfiguration where+        toHeaders+          = const+              (mconcat+                 ["Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToJSON UpdateConfiguration where+        toJSON UpdateConfiguration'{..}+          = object+              (catMaybes+                 [("data" .=) <$> _ucData,+                  ("description" .=) <$> _ucDescription])++instance ToPath UpdateConfiguration where+        toPath UpdateConfiguration'{..}+          = mconcat+              ["/v1/configurations/", toBS _ucConfigurationId]++instance ToQuery UpdateConfiguration where+        toQuery = const mempty++-- | /See:/ 'updateConfigurationResponse' smart constructor.+data UpdateConfigurationResponse = UpdateConfigurationResponse'+  { _ucrsARN            :: !(Maybe Text)+  , _ucrsLatestRevision :: !(Maybe ConfigurationRevision)+  , _ucrsWarnings       :: !(Maybe [SanitizationWarning])+  , _ucrsName           :: !(Maybe Text)+  , _ucrsId             :: !(Maybe Text)+  , _ucrsResponseStatus :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'UpdateConfigurationResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'ucrsARN' - Required. The Amazon Resource Name (ARN) of the configuration.+--+-- * 'ucrsLatestRevision' - The latest revision of the configuration.+--+-- * 'ucrsWarnings' - The list of the first 20 warnings about the configuration XML elements or attributes that were sanitized.+--+-- * 'ucrsName' - Required. The name of the configuration. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 1-150 characters long.+--+-- * 'ucrsId' - Required. The unique ID that Amazon MQ generates for the configuration.+--+-- * 'ucrsResponseStatus' - -- | The response status code.+updateConfigurationResponse+    :: Int -- ^ 'ucrsResponseStatus'+    -> UpdateConfigurationResponse+updateConfigurationResponse pResponseStatus_ =+  UpdateConfigurationResponse'+    { _ucrsARN = Nothing+    , _ucrsLatestRevision = Nothing+    , _ucrsWarnings = Nothing+    , _ucrsName = Nothing+    , _ucrsId = Nothing+    , _ucrsResponseStatus = pResponseStatus_+    }+++-- | Required. The Amazon Resource Name (ARN) of the configuration.+ucrsARN :: Lens' UpdateConfigurationResponse (Maybe Text)+ucrsARN = lens _ucrsARN (\ s a -> s{_ucrsARN = a})++-- | The latest revision of the configuration.+ucrsLatestRevision :: Lens' UpdateConfigurationResponse (Maybe ConfigurationRevision)+ucrsLatestRevision = lens _ucrsLatestRevision (\ s a -> s{_ucrsLatestRevision = a})++-- | The list of the first 20 warnings about the configuration XML elements or attributes that were sanitized.+ucrsWarnings :: Lens' UpdateConfigurationResponse [SanitizationWarning]+ucrsWarnings = lens _ucrsWarnings (\ s a -> s{_ucrsWarnings = a}) . _Default . _Coerce++-- | Required. The name of the configuration. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 1-150 characters long.+ucrsName :: Lens' UpdateConfigurationResponse (Maybe Text)+ucrsName = lens _ucrsName (\ s a -> s{_ucrsName = a})++-- | Required. The unique ID that Amazon MQ generates for the configuration.+ucrsId :: Lens' UpdateConfigurationResponse (Maybe Text)+ucrsId = lens _ucrsId (\ s a -> s{_ucrsId = a})++-- | -- | The response status code.+ucrsResponseStatus :: Lens' UpdateConfigurationResponse Int+ucrsResponseStatus = lens _ucrsResponseStatus (\ s a -> s{_ucrsResponseStatus = a})++instance NFData UpdateConfigurationResponse where
+ gen/Network/AWS/MQ/UpdateUser.hs view
@@ -0,0 +1,165 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.UpdateUser+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Updates the information for an ActiveMQ user.+module Network.AWS.MQ.UpdateUser+    (+    -- * Creating a Request+      updateUser+    , UpdateUser+    -- * Request Lenses+    , uuGroups+    , uuConsoleAccess+    , uuPassword+    , uuUsername+    , uuBrokerId++    -- * Destructuring the Response+    , updateUserResponse+    , UpdateUserResponse+    -- * Response Lenses+    , uursResponseStatus+    ) where++import Network.AWS.Lens+import Network.AWS.MQ.Types+import Network.AWS.MQ.Types.Product+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | Updates the information for an ActiveMQ user.+--+-- /See:/ 'updateUser' smart constructor.+data UpdateUser = UpdateUser'+  { _uuGroups        :: !(Maybe [Text])+  , _uuConsoleAccess :: !(Maybe Bool)+  , _uuPassword      :: !(Maybe Text)+  , _uuUsername      :: !Text+  , _uuBrokerId      :: !Text+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'UpdateUser' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'uuGroups' - The list of groups (20 maximum) to which the ActiveMQ user belongs. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+--+-- * 'uuConsoleAccess' - Enables access to the the ActiveMQ Web Console for the ActiveMQ user.+--+-- * 'uuPassword' - The password of the user. This value must be at least 12 characters long, must contain at least 4 unique characters, and must not contain commas.+--+-- * 'uuUsername' - Required. The username of the ActiveMQ user. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+--+-- * 'uuBrokerId' - The unique ID that Amazon MQ generates for the broker.+updateUser+    :: Text -- ^ 'uuUsername'+    -> Text -- ^ 'uuBrokerId'+    -> UpdateUser+updateUser pUsername_ pBrokerId_ =+  UpdateUser'+    { _uuGroups = Nothing+    , _uuConsoleAccess = Nothing+    , _uuPassword = Nothing+    , _uuUsername = pUsername_+    , _uuBrokerId = pBrokerId_+    }+++-- | The list of groups (20 maximum) to which the ActiveMQ user belongs. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+uuGroups :: Lens' UpdateUser [Text]+uuGroups = lens _uuGroups (\ s a -> s{_uuGroups = a}) . _Default . _Coerce++-- | Enables access to the the ActiveMQ Web Console for the ActiveMQ user.+uuConsoleAccess :: Lens' UpdateUser (Maybe Bool)+uuConsoleAccess = lens _uuConsoleAccess (\ s a -> s{_uuConsoleAccess = a})++-- | The password of the user. This value must be at least 12 characters long, must contain at least 4 unique characters, and must not contain commas.+uuPassword :: Lens' UpdateUser (Maybe Text)+uuPassword = lens _uuPassword (\ s a -> s{_uuPassword = a})++-- | Required. The username of the ActiveMQ user. This value can contain only alphanumeric characters, dashes, periods, underscores, and tildes (- . _ ~). This value must be 2-100 characters long.+uuUsername :: Lens' UpdateUser Text+uuUsername = lens _uuUsername (\ s a -> s{_uuUsername = a})++-- | The unique ID that Amazon MQ generates for the broker.+uuBrokerId :: Lens' UpdateUser Text+uuBrokerId = lens _uuBrokerId (\ s a -> s{_uuBrokerId = a})++instance AWSRequest UpdateUser where+        type Rs UpdateUser = UpdateUserResponse+        request = putJSON mq+        response+          = receiveEmpty+              (\ s h x ->+                 UpdateUserResponse' <$> (pure (fromEnum s)))++instance Hashable UpdateUser where++instance NFData UpdateUser where++instance ToHeaders UpdateUser where+        toHeaders+          = const+              (mconcat+                 ["Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToJSON UpdateUser where+        toJSON UpdateUser'{..}+          = object+              (catMaybes+                 [("groups" .=) <$> _uuGroups,+                  ("consoleAccess" .=) <$> _uuConsoleAccess,+                  ("password" .=) <$> _uuPassword])++instance ToPath UpdateUser where+        toPath UpdateUser'{..}+          = mconcat+              ["/v1/brokers/", toBS _uuBrokerId, "/users/",+               toBS _uuUsername]++instance ToQuery UpdateUser where+        toQuery = const mempty++-- | /See:/ 'updateUserResponse' smart constructor.+newtype UpdateUserResponse = UpdateUserResponse'+  { _uursResponseStatus :: Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'UpdateUserResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'uursResponseStatus' - -- | The response status code.+updateUserResponse+    :: Int -- ^ 'uursResponseStatus'+    -> UpdateUserResponse+updateUserResponse pResponseStatus_ =+  UpdateUserResponse' {_uursResponseStatus = pResponseStatus_}+++-- | -- | The response status code.+uursResponseStatus :: Lens' UpdateUserResponse Int+uursResponseStatus = lens _uursResponseStatus (\ s a -> s{_uursResponseStatus = a})++instance NFData UpdateUserResponse where
+ gen/Network/AWS/MQ/Waiters.hs view
@@ -0,0 +1,21 @@+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE TypeFamilies      #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.MQ.Waiters+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+module Network.AWS.MQ.Waiters where++import Network.AWS.Lens+import Network.AWS.MQ.Types+import Network.AWS.Prelude+import Network.AWS.Waiter
+ src/.gitkeep view
+ test/Main.hs view
@@ -0,0 +1,21 @@+{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- |+-- Module      : Main+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+module Main (main) where++import Test.Tasty+import Test.AWS.MQ+import Test.AWS.MQ.Internal++main :: IO ()+main = defaultMain $ testGroup "MQ"+    [ testGroup "tests"    tests+    , testGroup "fixtures" fixtures+    ]
+ test/Test/AWS/Gen/MQ.hs view
@@ -0,0 +1,345 @@+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-orphans        #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Test.AWS.Gen.MQ+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+module Test.AWS.Gen.MQ where++import Data.Proxy+import Network.AWS.MQ+import Test.AWS.Fixture+import Test.AWS.MQ.Internal+import Test.AWS.Prelude+import Test.Tasty++-- Auto-generated: the actual test selection needs to be manually placed into+-- the top-level so that real test data can be incrementally added.+--+-- This commented snippet is what the entire set should look like:++-- fixtures :: TestTree+-- fixtures =+--     [ testGroup "request"+--         [ requestCreateConfiguration $+--             createConfiguration+--+--         , requestCreateBroker $+--             createBroker+--+--         , requestDeleteBroker $+--             deleteBroker+--+--         , requestUpdateBroker $+--             updateBroker+--+--         , requestRebootBroker $+--             rebootBroker+--+--         , requestListConfigurationRevisions $+--             listConfigurationRevisions+--+--         , requestListUsers $+--             listUsers+--+--         , requestListConfigurations $+--             listConfigurations+--+--         , requestDescribeUser $+--             describeUser+--+--         , requestListBrokers $+--             listBrokers+--+--         , requestCreateUser $+--             createUser+--+--         , requestDescribeConfiguration $+--             describeConfiguration+--+--         , requestUpdateUser $+--             updateUser+--+--         , requestDeleteUser $+--             deleteUser+--+--         , requestDescribeConfigurationRevision $+--             describeConfigurationRevision+--+--         , requestDescribeBroker $+--             describeBroker+--+--         , requestUpdateConfiguration $+--             updateConfiguration+--+--           ]++--     , testGroup "response"+--         [ responseCreateConfiguration $+--             createConfigurationResponse+--+--         , responseCreateBroker $+--             createBrokerResponse+--+--         , responseDeleteBroker $+--             deleteBrokerResponse+--+--         , responseUpdateBroker $+--             updateBrokerResponse+--+--         , responseRebootBroker $+--             rebootBrokerResponse+--+--         , responseListConfigurationRevisions $+--             listConfigurationRevisionsResponse+--+--         , responseListUsers $+--             listUsersResponse+--+--         , responseListConfigurations $+--             listConfigurationsResponse+--+--         , responseDescribeUser $+--             describeUserResponse+--+--         , responseListBrokers $+--             listBrokersResponse+--+--         , responseCreateUser $+--             createUserResponse+--+--         , responseDescribeConfiguration $+--             describeConfigurationResponse+--+--         , responseUpdateUser $+--             updateUserResponse+--+--         , responseDeleteUser $+--             deleteUserResponse+--+--         , responseDescribeConfigurationRevision $+--             describeConfigurationRevisionResponse+--+--         , responseDescribeBroker $+--             describeBrokerResponse+--+--         , responseUpdateConfiguration $+--             updateConfigurationResponse+--+--           ]+--     ]++-- Requests++requestCreateConfiguration :: CreateConfiguration -> TestTree+requestCreateConfiguration = req+    "CreateConfiguration"+    "fixture/CreateConfiguration.yaml"++requestCreateBroker :: CreateBroker -> TestTree+requestCreateBroker = req+    "CreateBroker"+    "fixture/CreateBroker.yaml"++requestDeleteBroker :: DeleteBroker -> TestTree+requestDeleteBroker = req+    "DeleteBroker"+    "fixture/DeleteBroker.yaml"++requestUpdateBroker :: UpdateBroker -> TestTree+requestUpdateBroker = req+    "UpdateBroker"+    "fixture/UpdateBroker.yaml"++requestRebootBroker :: RebootBroker -> TestTree+requestRebootBroker = req+    "RebootBroker"+    "fixture/RebootBroker.yaml"++requestListConfigurationRevisions :: ListConfigurationRevisions -> TestTree+requestListConfigurationRevisions = req+    "ListConfigurationRevisions"+    "fixture/ListConfigurationRevisions.yaml"++requestListUsers :: ListUsers -> TestTree+requestListUsers = req+    "ListUsers"+    "fixture/ListUsers.yaml"++requestListConfigurations :: ListConfigurations -> TestTree+requestListConfigurations = req+    "ListConfigurations"+    "fixture/ListConfigurations.yaml"++requestDescribeUser :: DescribeUser -> TestTree+requestDescribeUser = req+    "DescribeUser"+    "fixture/DescribeUser.yaml"++requestListBrokers :: ListBrokers -> TestTree+requestListBrokers = req+    "ListBrokers"+    "fixture/ListBrokers.yaml"++requestCreateUser :: CreateUser -> TestTree+requestCreateUser = req+    "CreateUser"+    "fixture/CreateUser.yaml"++requestDescribeConfiguration :: DescribeConfiguration -> TestTree+requestDescribeConfiguration = req+    "DescribeConfiguration"+    "fixture/DescribeConfiguration.yaml"++requestUpdateUser :: UpdateUser -> TestTree+requestUpdateUser = req+    "UpdateUser"+    "fixture/UpdateUser.yaml"++requestDeleteUser :: DeleteUser -> TestTree+requestDeleteUser = req+    "DeleteUser"+    "fixture/DeleteUser.yaml"++requestDescribeConfigurationRevision :: DescribeConfigurationRevision -> TestTree+requestDescribeConfigurationRevision = req+    "DescribeConfigurationRevision"+    "fixture/DescribeConfigurationRevision.yaml"++requestDescribeBroker :: DescribeBroker -> TestTree+requestDescribeBroker = req+    "DescribeBroker"+    "fixture/DescribeBroker.yaml"++requestUpdateConfiguration :: UpdateConfiguration -> TestTree+requestUpdateConfiguration = req+    "UpdateConfiguration"+    "fixture/UpdateConfiguration.yaml"++-- Responses++responseCreateConfiguration :: CreateConfigurationResponse -> TestTree+responseCreateConfiguration = res+    "CreateConfigurationResponse"+    "fixture/CreateConfigurationResponse.proto"+    mq+    (Proxy :: Proxy CreateConfiguration)++responseCreateBroker :: CreateBrokerResponse -> TestTree+responseCreateBroker = res+    "CreateBrokerResponse"+    "fixture/CreateBrokerResponse.proto"+    mq+    (Proxy :: Proxy CreateBroker)++responseDeleteBroker :: DeleteBrokerResponse -> TestTree+responseDeleteBroker = res+    "DeleteBrokerResponse"+    "fixture/DeleteBrokerResponse.proto"+    mq+    (Proxy :: Proxy DeleteBroker)++responseUpdateBroker :: UpdateBrokerResponse -> TestTree+responseUpdateBroker = res+    "UpdateBrokerResponse"+    "fixture/UpdateBrokerResponse.proto"+    mq+    (Proxy :: Proxy UpdateBroker)++responseRebootBroker :: RebootBrokerResponse -> TestTree+responseRebootBroker = res+    "RebootBrokerResponse"+    "fixture/RebootBrokerResponse.proto"+    mq+    (Proxy :: Proxy RebootBroker)++responseListConfigurationRevisions :: ListConfigurationRevisionsResponse -> TestTree+responseListConfigurationRevisions = res+    "ListConfigurationRevisionsResponse"+    "fixture/ListConfigurationRevisionsResponse.proto"+    mq+    (Proxy :: Proxy ListConfigurationRevisions)++responseListUsers :: ListUsersResponse -> TestTree+responseListUsers = res+    "ListUsersResponse"+    "fixture/ListUsersResponse.proto"+    mq+    (Proxy :: Proxy ListUsers)++responseListConfigurations :: ListConfigurationsResponse -> TestTree+responseListConfigurations = res+    "ListConfigurationsResponse"+    "fixture/ListConfigurationsResponse.proto"+    mq+    (Proxy :: Proxy ListConfigurations)++responseDescribeUser :: DescribeUserResponse -> TestTree+responseDescribeUser = res+    "DescribeUserResponse"+    "fixture/DescribeUserResponse.proto"+    mq+    (Proxy :: Proxy DescribeUser)++responseListBrokers :: ListBrokersResponse -> TestTree+responseListBrokers = res+    "ListBrokersResponse"+    "fixture/ListBrokersResponse.proto"+    mq+    (Proxy :: Proxy ListBrokers)++responseCreateUser :: CreateUserResponse -> TestTree+responseCreateUser = res+    "CreateUserResponse"+    "fixture/CreateUserResponse.proto"+    mq+    (Proxy :: Proxy CreateUser)++responseDescribeConfiguration :: DescribeConfigurationResponse -> TestTree+responseDescribeConfiguration = res+    "DescribeConfigurationResponse"+    "fixture/DescribeConfigurationResponse.proto"+    mq+    (Proxy :: Proxy DescribeConfiguration)++responseUpdateUser :: UpdateUserResponse -> TestTree+responseUpdateUser = res+    "UpdateUserResponse"+    "fixture/UpdateUserResponse.proto"+    mq+    (Proxy :: Proxy UpdateUser)++responseDeleteUser :: DeleteUserResponse -> TestTree+responseDeleteUser = res+    "DeleteUserResponse"+    "fixture/DeleteUserResponse.proto"+    mq+    (Proxy :: Proxy DeleteUser)++responseDescribeConfigurationRevision :: DescribeConfigurationRevisionResponse -> TestTree+responseDescribeConfigurationRevision = res+    "DescribeConfigurationRevisionResponse"+    "fixture/DescribeConfigurationRevisionResponse.proto"+    mq+    (Proxy :: Proxy DescribeConfigurationRevision)++responseDescribeBroker :: DescribeBrokerResponse -> TestTree+responseDescribeBroker = res+    "DescribeBrokerResponse"+    "fixture/DescribeBrokerResponse.proto"+    mq+    (Proxy :: Proxy DescribeBroker)++responseUpdateConfiguration :: UpdateConfigurationResponse -> TestTree+responseUpdateConfiguration = res+    "UpdateConfigurationResponse"+    "fixture/UpdateConfigurationResponse.proto"+    mq+    (Proxy :: Proxy UpdateConfiguration)
+ test/Test/AWS/MQ.hs view
@@ -0,0 +1,20 @@+-- |+-- Module      : Test.AWS.MQ+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+module Test.AWS.MQ+    ( tests+    , fixtures+    ) where++import Test.Tasty (TestTree)++tests :: [TestTree]+tests = []++fixtures :: [TestTree]+fixtures = []
+ test/Test/AWS/MQ/Internal.hs view
@@ -0,0 +1,9 @@+-- |+-- Module      : Test.AWS.MQ.Internal+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+module Test.AWS.MQ.Internal where