amazonka-snow-device-management (empty) → 2.0
raw patch · 75 files changed
+7085/−0 lines, 75 filesdep +amazonka-coredep +amazonka-snow-device-managementdep +amazonka-test
Dependencies added: amazonka-core, amazonka-snow-device-management, amazonka-test, base, bytestring, case-insensitive, tasty, tasty-hunit, text, time, unordered-containers
Files
- LICENSE +367/−0
- README.md +44/−0
- amazonka-snow-device-management.cabal +120/−0
- fixture/CancelTask.yaml +10/−0
- fixture/CancelTaskResponse.proto +0/−0
- fixture/CreateTask.yaml +10/−0
- fixture/CreateTaskResponse.proto +0/−0
- fixture/DescribeDevice.yaml +10/−0
- fixture/DescribeDeviceEc2Instances.yaml +10/−0
- fixture/DescribeDeviceEc2InstancesResponse.proto +0/−0
- fixture/DescribeDeviceResponse.proto +0/−0
- fixture/DescribeExecution.yaml +10/−0
- fixture/DescribeExecutionResponse.proto +0/−0
- fixture/DescribeTask.yaml +10/−0
- fixture/DescribeTaskResponse.proto +0/−0
- fixture/ListDeviceResources.yaml +10/−0
- fixture/ListDeviceResourcesResponse.proto +0/−0
- fixture/ListDevices.yaml +10/−0
- fixture/ListDevicesResponse.proto +0/−0
- fixture/ListExecutions.yaml +10/−0
- fixture/ListExecutionsResponse.proto +0/−0
- fixture/ListTagsForResource.yaml +10/−0
- fixture/ListTagsForResourceResponse.proto +0/−0
- fixture/ListTasks.yaml +10/−0
- fixture/ListTasksResponse.proto +0/−0
- fixture/TagResource.yaml +10/−0
- fixture/TagResourceResponse.proto +0/−0
- fixture/UntagResource.yaml +10/−0
- fixture/UntagResourceResponse.proto +0/−0
- gen/Amazonka/SnowDeviceManagement.hs +259/−0
- gen/Amazonka/SnowDeviceManagement/CancelTask.hs +167/−0
- gen/Amazonka/SnowDeviceManagement/CreateTask.hs +245/−0
- gen/Amazonka/SnowDeviceManagement/DescribeDevice.hs +307/−0
- gen/Amazonka/SnowDeviceManagement/DescribeDeviceEc2Instances.hs +192/−0
- gen/Amazonka/SnowDeviceManagement/DescribeExecution.hs +246/−0
- gen/Amazonka/SnowDeviceManagement/DescribeTask.hs +261/−0
- gen/Amazonka/SnowDeviceManagement/Lens.hs +250/−0
- gen/Amazonka/SnowDeviceManagement/ListDeviceResources.hs +248/−0
- gen/Amazonka/SnowDeviceManagement/ListDevices.hs +223/−0
- gen/Amazonka/SnowDeviceManagement/ListExecutions.hs +245/−0
- gen/Amazonka/SnowDeviceManagement/ListTagsForResource.hs +159/−0
- gen/Amazonka/SnowDeviceManagement/ListTasks.hs +221/−0
- gen/Amazonka/SnowDeviceManagement/TagResource.hs +148/−0
- gen/Amazonka/SnowDeviceManagement/Types.hs +325/−0
- gen/Amazonka/SnowDeviceManagement/Types/AttachmentStatus.hs +81/−0
- gen/Amazonka/SnowDeviceManagement/Types/Capacity.hs +120/−0
- gen/Amazonka/SnowDeviceManagement/Types/Command.hs +84/−0
- gen/Amazonka/SnowDeviceManagement/Types/CpuOptions.hs +84/−0
- gen/Amazonka/SnowDeviceManagement/Types/DeviceSummary.hs +114/−0
- gen/Amazonka/SnowDeviceManagement/Types/EbsInstanceBlockDevice.hs +114/−0
- gen/Amazonka/SnowDeviceManagement/Types/ExecutionState.hs +96/−0
- gen/Amazonka/SnowDeviceManagement/Types/ExecutionSummary.hs +109/−0
- gen/Amazonka/SnowDeviceManagement/Types/Instance.hs +226/−0
- gen/Amazonka/SnowDeviceManagement/Types/InstanceBlockDeviceMapping.hs +89/−0
- gen/Amazonka/SnowDeviceManagement/Types/InstanceState.hs +159/−0
- gen/Amazonka/SnowDeviceManagement/Types/InstanceStateName.hs +91/−0
- gen/Amazonka/SnowDeviceManagement/Types/InstanceSummary.hs +85/−0
- gen/Amazonka/SnowDeviceManagement/Types/IpAddressAssignment.hs +71/−0
- gen/Amazonka/SnowDeviceManagement/Types/PhysicalConnectorType.hs +86/−0
- gen/Amazonka/SnowDeviceManagement/Types/PhysicalNetworkInterface.hs +147/−0
- gen/Amazonka/SnowDeviceManagement/Types/Reboot.hs +51/−0
- gen/Amazonka/SnowDeviceManagement/Types/ResourceSummary.hs +98/−0
- gen/Amazonka/SnowDeviceManagement/Types/SecurityGroupIdentifier.hs +84/−0
- gen/Amazonka/SnowDeviceManagement/Types/SoftwareInformation.hs +100/−0
- gen/Amazonka/SnowDeviceManagement/Types/TaskState.hs +76/−0
- gen/Amazonka/SnowDeviceManagement/Types/TaskSummary.hs +117/−0
- gen/Amazonka/SnowDeviceManagement/Types/Unlock.hs +51/−0
- gen/Amazonka/SnowDeviceManagement/Types/UnlockState.hs +76/−0
- gen/Amazonka/SnowDeviceManagement/UntagResource.hs +146/−0
- gen/Amazonka/SnowDeviceManagement/Waiters.hs +24/−0
- src/.gitkeep +0/−0
- test/Main.hs +23/−0
- test/Test/Amazonka/Gen/SnowDeviceManagement.hs +298/−0
- test/Test/Amazonka/SnowDeviceManagement.hs +20/−0
- test/Test/Amazonka/SnowDeviceManagement/Internal.hs +8/−0
+ 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,44 @@+# Amazon Snow Device Management SDK++* [Version](#version)+* [Description](#description)+* [Contribute](#contribute)+* [Licence](#licence)+++## Version+ +`2.0` - Derived from API version @2021-08-04@ of the AWS service descriptions, licensed under Apache 2.0.++## Description++Documentation is available via [Hackage](http://hackage.haskell.org/package/amazonka-snow-device-management)+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 [Amazonka.SnowDeviceManagement](http://hackage.haskell.org/package/amazonka-snow-device-management/docs/Amazonka-SnowDeviceManagement.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-snow-device-management` 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.
+ amazonka-snow-device-management.cabal view
@@ -0,0 +1,120 @@+cabal-version: 2.2+name: amazonka-snow-device-management+version: 2.0+synopsis: Amazon Snow Device Management 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>, Jack Kelly <jack@jackkelly.name>++copyright: Copyright (c) 2013-2023 Brendan Hay+category: AWS+build-type: Simple+extra-source-files:+ fixture/*.proto+ fixture/*.yaml+ README.md+ src/.gitkeep++description:+ Derived from API version @2021-08-04@ of the AWS service descriptions, licensed under Apache 2.0.+ .+ 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.+ .+ It is recommended to use generic lenses or optics from packages such as <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify optional fields and deconstruct responses.+ .+ Generated lenses can be found in "Amazonka.SnowDeviceManagement.Lens" and are+ suitable for use with a lens package such as <http://hackage.haskell.org/package/lens lens> or <http://hackage.haskell.org/package/lens-family-core lens-family-core>.+ .+ See "Amazonka.SnowDeviceManagement" and the <https://aws.amazon.com/documentation/ AWS documentation> to get started.++source-repository head+ type: git+ location: git://github.com/brendanhay/amazonka.git+ subdir: amazonka-snow-device-management++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:+ Amazonka.SnowDeviceManagement+ Amazonka.SnowDeviceManagement.CancelTask+ Amazonka.SnowDeviceManagement.CreateTask+ Amazonka.SnowDeviceManagement.DescribeDevice+ Amazonka.SnowDeviceManagement.DescribeDeviceEc2Instances+ Amazonka.SnowDeviceManagement.DescribeExecution+ Amazonka.SnowDeviceManagement.DescribeTask+ Amazonka.SnowDeviceManagement.Lens+ Amazonka.SnowDeviceManagement.ListDeviceResources+ Amazonka.SnowDeviceManagement.ListDevices+ Amazonka.SnowDeviceManagement.ListExecutions+ Amazonka.SnowDeviceManagement.ListTagsForResource+ Amazonka.SnowDeviceManagement.ListTasks+ Amazonka.SnowDeviceManagement.TagResource+ Amazonka.SnowDeviceManagement.Types+ Amazonka.SnowDeviceManagement.Types.AttachmentStatus+ Amazonka.SnowDeviceManagement.Types.Capacity+ Amazonka.SnowDeviceManagement.Types.Command+ Amazonka.SnowDeviceManagement.Types.CpuOptions+ Amazonka.SnowDeviceManagement.Types.DeviceSummary+ Amazonka.SnowDeviceManagement.Types.EbsInstanceBlockDevice+ Amazonka.SnowDeviceManagement.Types.ExecutionState+ Amazonka.SnowDeviceManagement.Types.ExecutionSummary+ Amazonka.SnowDeviceManagement.Types.Instance+ Amazonka.SnowDeviceManagement.Types.InstanceBlockDeviceMapping+ Amazonka.SnowDeviceManagement.Types.InstanceState+ Amazonka.SnowDeviceManagement.Types.InstanceStateName+ Amazonka.SnowDeviceManagement.Types.InstanceSummary+ Amazonka.SnowDeviceManagement.Types.IpAddressAssignment+ Amazonka.SnowDeviceManagement.Types.PhysicalConnectorType+ Amazonka.SnowDeviceManagement.Types.PhysicalNetworkInterface+ Amazonka.SnowDeviceManagement.Types.Reboot+ Amazonka.SnowDeviceManagement.Types.ResourceSummary+ Amazonka.SnowDeviceManagement.Types.SecurityGroupIdentifier+ Amazonka.SnowDeviceManagement.Types.SoftwareInformation+ Amazonka.SnowDeviceManagement.Types.TaskState+ Amazonka.SnowDeviceManagement.Types.TaskSummary+ Amazonka.SnowDeviceManagement.Types.Unlock+ Amazonka.SnowDeviceManagement.Types.UnlockState+ Amazonka.SnowDeviceManagement.UntagResource+ Amazonka.SnowDeviceManagement.Waiters++ build-depends:+ , amazonka-core >=2.0 && <2.1+ , base >=4.12 && <5++test-suite amazonka-snow-device-management-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.Amazonka.Gen.SnowDeviceManagement+ Test.Amazonka.SnowDeviceManagement+ Test.Amazonka.SnowDeviceManagement.Internal++ build-depends:+ , amazonka-core >=2.0 && <2.1+ , amazonka-snow-device-management+ , amazonka-test >=2.0 && <2.1+ , base+ , bytestring+ , case-insensitive+ , tasty+ , tasty-hunit+ , text+ , time+ , unordered-containers
+ fixture/CancelTask.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+ Authorization: AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/snow-device-management/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+ Host: snow-device-management.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/CancelTaskResponse.proto view
+ fixture/CreateTask.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+ Authorization: AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/snow-device-management/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+ Host: snow-device-management.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/CreateTaskResponse.proto view
+ fixture/DescribeDevice.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+ Authorization: AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/snow-device-management/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+ Host: snow-device-management.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/DescribeDeviceEc2Instances.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+ Authorization: AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/snow-device-management/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+ Host: snow-device-management.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/DescribeDeviceEc2InstancesResponse.proto view
+ fixture/DescribeDeviceResponse.proto view
+ fixture/DescribeExecution.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+ Authorization: AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/snow-device-management/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+ Host: snow-device-management.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/DescribeExecutionResponse.proto view
+ fixture/DescribeTask.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+ Authorization: AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/snow-device-management/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+ Host: snow-device-management.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/DescribeTaskResponse.proto view
+ fixture/ListDeviceResources.yaml view
@@ -0,0 +1,10 @@+---+method: GET+headers:+ Authorization: AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/snow-device-management/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+ Host: snow-device-management.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/ListDeviceResourcesResponse.proto view
+ fixture/ListDevices.yaml view
@@ -0,0 +1,10 @@+---+method: GET+headers:+ Authorization: AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/snow-device-management/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+ Host: snow-device-management.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/ListDevicesResponse.proto view
+ fixture/ListExecutions.yaml view
@@ -0,0 +1,10 @@+---+method: GET+headers:+ Authorization: AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/snow-device-management/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+ Host: snow-device-management.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/ListExecutionsResponse.proto view
+ fixture/ListTagsForResource.yaml view
@@ -0,0 +1,10 @@+---+method: GET+headers:+ Authorization: AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/snow-device-management/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+ Host: snow-device-management.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/ListTagsForResourceResponse.proto view
+ fixture/ListTasks.yaml view
@@ -0,0 +1,10 @@+---+method: GET+headers:+ Authorization: AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/snow-device-management/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+ Host: snow-device-management.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/ListTasksResponse.proto view
+ fixture/TagResource.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+ Authorization: AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/snow-device-management/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+ Host: snow-device-management.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/TagResourceResponse.proto view
+ fixture/UntagResource.yaml view
@@ -0,0 +1,10 @@+---+method: DELETE+headers:+ Authorization: AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/snow-device-management/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+ Host: snow-device-management.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/UntagResourceResponse.proto view
+ gen/Amazonka/SnowDeviceManagement.hs view
@@ -0,0 +1,259 @@+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- |+-- Module : Amazonka.SnowDeviceManagement+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Derived from API version @2021-08-04@ of the AWS service descriptions, licensed under Apache 2.0.+--+-- Amazon Web Services Snow Device Management documentation.+module Amazonka.SnowDeviceManagement+ ( -- * Service Configuration+ defaultService,++ -- * Errors+ -- $errors++ -- ** AccessDeniedException+ _AccessDeniedException,++ -- ** InternalServerException+ _InternalServerException,++ -- ** ResourceNotFoundException+ _ResourceNotFoundException,++ -- ** ServiceQuotaExceededException+ _ServiceQuotaExceededException,++ -- ** ThrottlingException+ _ThrottlingException,++ -- ** ValidationException+ _ValidationException,++ -- * Waiters+ -- $waiters++ -- * Operations+ -- $operations++ -- ** CancelTask+ CancelTask (CancelTask'),+ newCancelTask,+ CancelTaskResponse (CancelTaskResponse'),+ newCancelTaskResponse,++ -- ** CreateTask+ CreateTask (CreateTask'),+ newCreateTask,+ CreateTaskResponse (CreateTaskResponse'),+ newCreateTaskResponse,++ -- ** DescribeDevice+ DescribeDevice (DescribeDevice'),+ newDescribeDevice,+ DescribeDeviceResponse (DescribeDeviceResponse'),+ newDescribeDeviceResponse,++ -- ** DescribeDeviceEc2Instances+ DescribeDeviceEc2Instances (DescribeDeviceEc2Instances'),+ newDescribeDeviceEc2Instances,+ DescribeDeviceEc2InstancesResponse (DescribeDeviceEc2InstancesResponse'),+ newDescribeDeviceEc2InstancesResponse,++ -- ** DescribeExecution+ DescribeExecution (DescribeExecution'),+ newDescribeExecution,+ DescribeExecutionResponse (DescribeExecutionResponse'),+ newDescribeExecutionResponse,++ -- ** DescribeTask+ DescribeTask (DescribeTask'),+ newDescribeTask,+ DescribeTaskResponse (DescribeTaskResponse'),+ newDescribeTaskResponse,++ -- ** ListDeviceResources (Paginated)+ ListDeviceResources (ListDeviceResources'),+ newListDeviceResources,+ ListDeviceResourcesResponse (ListDeviceResourcesResponse'),+ newListDeviceResourcesResponse,++ -- ** ListDevices (Paginated)+ ListDevices (ListDevices'),+ newListDevices,+ ListDevicesResponse (ListDevicesResponse'),+ newListDevicesResponse,++ -- ** ListExecutions (Paginated)+ ListExecutions (ListExecutions'),+ newListExecutions,+ ListExecutionsResponse (ListExecutionsResponse'),+ newListExecutionsResponse,++ -- ** ListTagsForResource+ ListTagsForResource (ListTagsForResource'),+ newListTagsForResource,+ ListTagsForResourceResponse (ListTagsForResourceResponse'),+ newListTagsForResourceResponse,++ -- ** ListTasks (Paginated)+ ListTasks (ListTasks'),+ newListTasks,+ ListTasksResponse (ListTasksResponse'),+ newListTasksResponse,++ -- ** TagResource+ TagResource (TagResource'),+ newTagResource,+ TagResourceResponse (TagResourceResponse'),+ newTagResourceResponse,++ -- ** UntagResource+ UntagResource (UntagResource'),+ newUntagResource,+ UntagResourceResponse (UntagResourceResponse'),+ newUntagResourceResponse,++ -- * Types++ -- ** AttachmentStatus+ AttachmentStatus (..),++ -- ** ExecutionState+ ExecutionState (..),++ -- ** InstanceStateName+ InstanceStateName (..),++ -- ** IpAddressAssignment+ IpAddressAssignment (..),++ -- ** PhysicalConnectorType+ PhysicalConnectorType (..),++ -- ** TaskState+ TaskState (..),++ -- ** UnlockState+ UnlockState (..),++ -- ** Capacity+ Capacity (Capacity'),+ newCapacity,++ -- ** Command+ Command (Command'),+ newCommand,++ -- ** CpuOptions+ CpuOptions (CpuOptions'),+ newCpuOptions,++ -- ** DeviceSummary+ DeviceSummary (DeviceSummary'),+ newDeviceSummary,++ -- ** EbsInstanceBlockDevice+ EbsInstanceBlockDevice (EbsInstanceBlockDevice'),+ newEbsInstanceBlockDevice,++ -- ** ExecutionSummary+ ExecutionSummary (ExecutionSummary'),+ newExecutionSummary,++ -- ** Instance+ Instance (Instance'),+ newInstance,++ -- ** InstanceBlockDeviceMapping+ InstanceBlockDeviceMapping (InstanceBlockDeviceMapping'),+ newInstanceBlockDeviceMapping,++ -- ** InstanceState+ InstanceState (InstanceState'),+ newInstanceState,++ -- ** InstanceSummary+ InstanceSummary (InstanceSummary'),+ newInstanceSummary,++ -- ** PhysicalNetworkInterface+ PhysicalNetworkInterface (PhysicalNetworkInterface'),+ newPhysicalNetworkInterface,++ -- ** Reboot+ Reboot (Reboot'),+ newReboot,++ -- ** ResourceSummary+ ResourceSummary (ResourceSummary'),+ newResourceSummary,++ -- ** SecurityGroupIdentifier+ SecurityGroupIdentifier (SecurityGroupIdentifier'),+ newSecurityGroupIdentifier,++ -- ** SoftwareInformation+ SoftwareInformation (SoftwareInformation'),+ newSoftwareInformation,++ -- ** TaskSummary+ TaskSummary (TaskSummary'),+ newTaskSummary,++ -- ** Unlock+ Unlock (Unlock'),+ newUnlock,+ )+where++import Amazonka.SnowDeviceManagement.CancelTask+import Amazonka.SnowDeviceManagement.CreateTask+import Amazonka.SnowDeviceManagement.DescribeDevice+import Amazonka.SnowDeviceManagement.DescribeDeviceEc2Instances+import Amazonka.SnowDeviceManagement.DescribeExecution+import Amazonka.SnowDeviceManagement.DescribeTask+import Amazonka.SnowDeviceManagement.Lens+import Amazonka.SnowDeviceManagement.ListDeviceResources+import Amazonka.SnowDeviceManagement.ListDevices+import Amazonka.SnowDeviceManagement.ListExecutions+import Amazonka.SnowDeviceManagement.ListTagsForResource+import Amazonka.SnowDeviceManagement.ListTasks+import Amazonka.SnowDeviceManagement.TagResource+import Amazonka.SnowDeviceManagement.Types+import Amazonka.SnowDeviceManagement.UntagResource+import Amazonka.SnowDeviceManagement.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 'SnowDeviceManagement'.++-- $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/Amazonka/SnowDeviceManagement/CancelTask.hs view
@@ -0,0 +1,167 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-binds #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.CancelTask+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Sends a cancel request for a specified task. You can cancel a task only+-- if it\'s still in a @QUEUED@ state. Tasks that are already running+-- can\'t be cancelled.+--+-- A task might still run if it\'s processed from the queue before the+-- @CancelTask@ operation changes the task\'s state.+module Amazonka.SnowDeviceManagement.CancelTask+ ( -- * Creating a Request+ CancelTask (..),+ newCancelTask,++ -- * Request Lenses+ cancelTask_taskId,++ -- * Destructuring the Response+ CancelTaskResponse (..),+ newCancelTaskResponse,++ -- * Response Lenses+ cancelTaskResponse_taskId,+ cancelTaskResponse_httpStatus,+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import qualified Amazonka.Request as Request+import qualified Amazonka.Response as Response+import Amazonka.SnowDeviceManagement.Types++-- | /See:/ 'newCancelTask' smart constructor.+data CancelTask = CancelTask'+ { -- | The ID of the task that you are attempting to cancel. You can retrieve a+ -- task ID by using the @ListTasks@ operation.+ taskId :: Prelude.Text+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'CancelTask' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'taskId', 'cancelTask_taskId' - The ID of the task that you are attempting to cancel. You can retrieve a+-- task ID by using the @ListTasks@ operation.+newCancelTask ::+ -- | 'taskId'+ Prelude.Text ->+ CancelTask+newCancelTask pTaskId_ =+ CancelTask' {taskId = pTaskId_}++-- | The ID of the task that you are attempting to cancel. You can retrieve a+-- task ID by using the @ListTasks@ operation.+cancelTask_taskId :: Lens.Lens' CancelTask Prelude.Text+cancelTask_taskId = Lens.lens (\CancelTask' {taskId} -> taskId) (\s@CancelTask' {} a -> s {taskId = a} :: CancelTask)++instance Core.AWSRequest CancelTask where+ type AWSResponse CancelTask = CancelTaskResponse+ request overrides =+ Request.postJSON (overrides defaultService)+ response =+ Response.receiveJSON+ ( \s h x ->+ CancelTaskResponse'+ Prelude.<$> (x Data..?> "taskId")+ Prelude.<*> (Prelude.pure (Prelude.fromEnum s))+ )++instance Prelude.Hashable CancelTask where+ hashWithSalt _salt CancelTask' {..} =+ _salt `Prelude.hashWithSalt` taskId++instance Prelude.NFData CancelTask where+ rnf CancelTask' {..} = Prelude.rnf taskId++instance Data.ToHeaders CancelTask where+ toHeaders =+ Prelude.const+ ( Prelude.mconcat+ [ "Content-Type"+ Data.=# ( "application/x-amz-json-1.1" ::+ Prelude.ByteString+ )+ ]+ )++instance Data.ToJSON CancelTask where+ toJSON = Prelude.const (Data.Object Prelude.mempty)++instance Data.ToPath CancelTask where+ toPath CancelTask' {..} =+ Prelude.mconcat+ ["/task/", Data.toBS taskId, "/cancel"]++instance Data.ToQuery CancelTask where+ toQuery = Prelude.const Prelude.mempty++-- | /See:/ 'newCancelTaskResponse' smart constructor.+data CancelTaskResponse = CancelTaskResponse'+ { -- | The ID of the task that you are attempting to cancel.+ taskId :: Prelude.Maybe Prelude.Text,+ -- | The response's http status code.+ httpStatus :: Prelude.Int+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'CancelTaskResponse' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'taskId', 'cancelTaskResponse_taskId' - The ID of the task that you are attempting to cancel.+--+-- 'httpStatus', 'cancelTaskResponse_httpStatus' - The response's http status code.+newCancelTaskResponse ::+ -- | 'httpStatus'+ Prelude.Int ->+ CancelTaskResponse+newCancelTaskResponse pHttpStatus_ =+ CancelTaskResponse'+ { taskId = Prelude.Nothing,+ httpStatus = pHttpStatus_+ }++-- | The ID of the task that you are attempting to cancel.+cancelTaskResponse_taskId :: Lens.Lens' CancelTaskResponse (Prelude.Maybe Prelude.Text)+cancelTaskResponse_taskId = Lens.lens (\CancelTaskResponse' {taskId} -> taskId) (\s@CancelTaskResponse' {} a -> s {taskId = a} :: CancelTaskResponse)++-- | The response's http status code.+cancelTaskResponse_httpStatus :: Lens.Lens' CancelTaskResponse Prelude.Int+cancelTaskResponse_httpStatus = Lens.lens (\CancelTaskResponse' {httpStatus} -> httpStatus) (\s@CancelTaskResponse' {} a -> s {httpStatus = a} :: CancelTaskResponse)++instance Prelude.NFData CancelTaskResponse where+ rnf CancelTaskResponse' {..} =+ Prelude.rnf taskId+ `Prelude.seq` Prelude.rnf httpStatus
+ gen/Amazonka/SnowDeviceManagement/CreateTask.hs view
@@ -0,0 +1,245 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-binds #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.CreateTask+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Instructs one or more devices to start a task, such as unlocking or+-- rebooting.+module Amazonka.SnowDeviceManagement.CreateTask+ ( -- * Creating a Request+ CreateTask (..),+ newCreateTask,++ -- * Request Lenses+ createTask_clientToken,+ createTask_description,+ createTask_tags,+ createTask_command,+ createTask_targets,++ -- * Destructuring the Response+ CreateTaskResponse (..),+ newCreateTaskResponse,++ -- * Response Lenses+ createTaskResponse_taskArn,+ createTaskResponse_taskId,+ createTaskResponse_httpStatus,+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import qualified Amazonka.Request as Request+import qualified Amazonka.Response as Response+import Amazonka.SnowDeviceManagement.Types++-- | /See:/ 'newCreateTask' smart constructor.+data CreateTask = CreateTask'+ { -- | A token ensuring that the action is called only once with the specified+ -- details.+ clientToken :: Prelude.Maybe Prelude.Text,+ -- | A description of the task and its targets.+ description :: Prelude.Maybe Prelude.Text,+ -- | Optional metadata that you assign to a resource. You can use tags to+ -- categorize a resource in different ways, such as by purpose, owner, or+ -- environment.+ tags :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),+ -- | The task to be performed. Only one task is executed on a device at a+ -- time.+ command :: Command,+ -- | A list of managed device IDs.+ targets :: Prelude.NonEmpty Prelude.Text+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'CreateTask' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'clientToken', 'createTask_clientToken' - A token ensuring that the action is called only once with the specified+-- details.+--+-- 'description', 'createTask_description' - A description of the task and its targets.+--+-- 'tags', 'createTask_tags' - Optional metadata that you assign to a resource. You can use tags to+-- categorize a resource in different ways, such as by purpose, owner, or+-- environment.+--+-- 'command', 'createTask_command' - The task to be performed. Only one task is executed on a device at a+-- time.+--+-- 'targets', 'createTask_targets' - A list of managed device IDs.+newCreateTask ::+ -- | 'command'+ Command ->+ -- | 'targets'+ Prelude.NonEmpty Prelude.Text ->+ CreateTask+newCreateTask pCommand_ pTargets_ =+ CreateTask'+ { clientToken = Prelude.Nothing,+ description = Prelude.Nothing,+ tags = Prelude.Nothing,+ command = pCommand_,+ targets = Lens.coerced Lens.# pTargets_+ }++-- | A token ensuring that the action is called only once with the specified+-- details.+createTask_clientToken :: Lens.Lens' CreateTask (Prelude.Maybe Prelude.Text)+createTask_clientToken = Lens.lens (\CreateTask' {clientToken} -> clientToken) (\s@CreateTask' {} a -> s {clientToken = a} :: CreateTask)++-- | A description of the task and its targets.+createTask_description :: Lens.Lens' CreateTask (Prelude.Maybe Prelude.Text)+createTask_description = Lens.lens (\CreateTask' {description} -> description) (\s@CreateTask' {} a -> s {description = a} :: CreateTask)++-- | Optional metadata that you assign to a resource. You can use tags to+-- categorize a resource in different ways, such as by purpose, owner, or+-- environment.+createTask_tags :: Lens.Lens' CreateTask (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))+createTask_tags = Lens.lens (\CreateTask' {tags} -> tags) (\s@CreateTask' {} a -> s {tags = a} :: CreateTask) Prelude.. Lens.mapping Lens.coerced++-- | The task to be performed. Only one task is executed on a device at a+-- time.+createTask_command :: Lens.Lens' CreateTask Command+createTask_command = Lens.lens (\CreateTask' {command} -> command) (\s@CreateTask' {} a -> s {command = a} :: CreateTask)++-- | A list of managed device IDs.+createTask_targets :: Lens.Lens' CreateTask (Prelude.NonEmpty Prelude.Text)+createTask_targets = Lens.lens (\CreateTask' {targets} -> targets) (\s@CreateTask' {} a -> s {targets = a} :: CreateTask) Prelude.. Lens.coerced++instance Core.AWSRequest CreateTask where+ type AWSResponse CreateTask = CreateTaskResponse+ request overrides =+ Request.postJSON (overrides defaultService)+ response =+ Response.receiveJSON+ ( \s h x ->+ CreateTaskResponse'+ Prelude.<$> (x Data..?> "taskArn")+ Prelude.<*> (x Data..?> "taskId")+ Prelude.<*> (Prelude.pure (Prelude.fromEnum s))+ )++instance Prelude.Hashable CreateTask where+ hashWithSalt _salt CreateTask' {..} =+ _salt+ `Prelude.hashWithSalt` clientToken+ `Prelude.hashWithSalt` description+ `Prelude.hashWithSalt` tags+ `Prelude.hashWithSalt` command+ `Prelude.hashWithSalt` targets++instance Prelude.NFData CreateTask where+ rnf CreateTask' {..} =+ Prelude.rnf clientToken+ `Prelude.seq` Prelude.rnf description+ `Prelude.seq` Prelude.rnf tags+ `Prelude.seq` Prelude.rnf command+ `Prelude.seq` Prelude.rnf targets++instance Data.ToHeaders CreateTask where+ toHeaders =+ Prelude.const+ ( Prelude.mconcat+ [ "Content-Type"+ Data.=# ( "application/x-amz-json-1.1" ::+ Prelude.ByteString+ )+ ]+ )++instance Data.ToJSON CreateTask where+ toJSON CreateTask' {..} =+ Data.object+ ( Prelude.catMaybes+ [ ("clientToken" Data..=) Prelude.<$> clientToken,+ ("description" Data..=) Prelude.<$> description,+ ("tags" Data..=) Prelude.<$> tags,+ Prelude.Just ("command" Data..= command),+ Prelude.Just ("targets" Data..= targets)+ ]+ )++instance Data.ToPath CreateTask where+ toPath = Prelude.const "/task"++instance Data.ToQuery CreateTask where+ toQuery = Prelude.const Prelude.mempty++-- | /See:/ 'newCreateTaskResponse' smart constructor.+data CreateTaskResponse = CreateTaskResponse'+ { -- | The Amazon Resource Name (ARN) of the task that you created.+ taskArn :: Prelude.Maybe Prelude.Text,+ -- | The ID of the task that you created.+ taskId :: Prelude.Maybe Prelude.Text,+ -- | The response's http status code.+ httpStatus :: Prelude.Int+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'CreateTaskResponse' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'taskArn', 'createTaskResponse_taskArn' - The Amazon Resource Name (ARN) of the task that you created.+--+-- 'taskId', 'createTaskResponse_taskId' - The ID of the task that you created.+--+-- 'httpStatus', 'createTaskResponse_httpStatus' - The response's http status code.+newCreateTaskResponse ::+ -- | 'httpStatus'+ Prelude.Int ->+ CreateTaskResponse+newCreateTaskResponse pHttpStatus_ =+ CreateTaskResponse'+ { taskArn = Prelude.Nothing,+ taskId = Prelude.Nothing,+ httpStatus = pHttpStatus_+ }++-- | The Amazon Resource Name (ARN) of the task that you created.+createTaskResponse_taskArn :: Lens.Lens' CreateTaskResponse (Prelude.Maybe Prelude.Text)+createTaskResponse_taskArn = Lens.lens (\CreateTaskResponse' {taskArn} -> taskArn) (\s@CreateTaskResponse' {} a -> s {taskArn = a} :: CreateTaskResponse)++-- | The ID of the task that you created.+createTaskResponse_taskId :: Lens.Lens' CreateTaskResponse (Prelude.Maybe Prelude.Text)+createTaskResponse_taskId = Lens.lens (\CreateTaskResponse' {taskId} -> taskId) (\s@CreateTaskResponse' {} a -> s {taskId = a} :: CreateTaskResponse)++-- | The response's http status code.+createTaskResponse_httpStatus :: Lens.Lens' CreateTaskResponse Prelude.Int+createTaskResponse_httpStatus = Lens.lens (\CreateTaskResponse' {httpStatus} -> httpStatus) (\s@CreateTaskResponse' {} a -> s {httpStatus = a} :: CreateTaskResponse)++instance Prelude.NFData CreateTaskResponse where+ rnf CreateTaskResponse' {..} =+ Prelude.rnf taskArn+ `Prelude.seq` Prelude.rnf taskId+ `Prelude.seq` Prelude.rnf httpStatus
+ gen/Amazonka/SnowDeviceManagement/DescribeDevice.hs view
@@ -0,0 +1,307 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-binds #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.DescribeDevice+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Checks device-specific information, such as the device type, software+-- version, IP addresses, and lock status.+module Amazonka.SnowDeviceManagement.DescribeDevice+ ( -- * Creating a Request+ DescribeDevice (..),+ newDescribeDevice,++ -- * Request Lenses+ describeDevice_managedDeviceId,++ -- * Destructuring the Response+ DescribeDeviceResponse (..),+ newDescribeDeviceResponse,++ -- * Response Lenses+ describeDeviceResponse_associatedWithJob,+ describeDeviceResponse_deviceCapacities,+ describeDeviceResponse_deviceState,+ describeDeviceResponse_deviceType,+ describeDeviceResponse_lastReachedOutAt,+ describeDeviceResponse_lastUpdatedAt,+ describeDeviceResponse_managedDeviceArn,+ describeDeviceResponse_managedDeviceId,+ describeDeviceResponse_physicalNetworkInterfaces,+ describeDeviceResponse_software,+ describeDeviceResponse_tags,+ describeDeviceResponse_httpStatus,+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import qualified Amazonka.Request as Request+import qualified Amazonka.Response as Response+import Amazonka.SnowDeviceManagement.Types++-- | /See:/ 'newDescribeDevice' smart constructor.+data DescribeDevice = DescribeDevice'+ { -- | The ID of the device that you are checking the information of.+ managedDeviceId :: Prelude.Text+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'DescribeDevice' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'managedDeviceId', 'describeDevice_managedDeviceId' - The ID of the device that you are checking the information of.+newDescribeDevice ::+ -- | 'managedDeviceId'+ Prelude.Text ->+ DescribeDevice+newDescribeDevice pManagedDeviceId_ =+ DescribeDevice'+ { managedDeviceId =+ pManagedDeviceId_+ }++-- | The ID of the device that you are checking the information of.+describeDevice_managedDeviceId :: Lens.Lens' DescribeDevice Prelude.Text+describeDevice_managedDeviceId = Lens.lens (\DescribeDevice' {managedDeviceId} -> managedDeviceId) (\s@DescribeDevice' {} a -> s {managedDeviceId = a} :: DescribeDevice)++instance Core.AWSRequest DescribeDevice where+ type+ AWSResponse DescribeDevice =+ DescribeDeviceResponse+ request overrides =+ Request.postJSON (overrides defaultService)+ response =+ Response.receiveJSON+ ( \s h x ->+ DescribeDeviceResponse'+ Prelude.<$> (x Data..?> "associatedWithJob")+ Prelude.<*> ( x+ Data..?> "deviceCapacities"+ Core..!@ Prelude.mempty+ )+ Prelude.<*> (x Data..?> "deviceState")+ Prelude.<*> (x Data..?> "deviceType")+ Prelude.<*> (x Data..?> "lastReachedOutAt")+ Prelude.<*> (x Data..?> "lastUpdatedAt")+ Prelude.<*> (x Data..?> "managedDeviceArn")+ Prelude.<*> (x Data..?> "managedDeviceId")+ Prelude.<*> ( x+ Data..?> "physicalNetworkInterfaces"+ Core..!@ Prelude.mempty+ )+ Prelude.<*> (x Data..?> "software")+ Prelude.<*> (x Data..?> "tags" Core..!@ Prelude.mempty)+ Prelude.<*> (Prelude.pure (Prelude.fromEnum s))+ )++instance Prelude.Hashable DescribeDevice where+ hashWithSalt _salt DescribeDevice' {..} =+ _salt `Prelude.hashWithSalt` managedDeviceId++instance Prelude.NFData DescribeDevice where+ rnf DescribeDevice' {..} = Prelude.rnf managedDeviceId++instance Data.ToHeaders DescribeDevice where+ toHeaders =+ Prelude.const+ ( Prelude.mconcat+ [ "Content-Type"+ Data.=# ( "application/x-amz-json-1.1" ::+ Prelude.ByteString+ )+ ]+ )++instance Data.ToJSON DescribeDevice where+ toJSON = Prelude.const (Data.Object Prelude.mempty)++instance Data.ToPath DescribeDevice where+ toPath DescribeDevice' {..} =+ Prelude.mconcat+ [ "/managed-device/",+ Data.toBS managedDeviceId,+ "/describe"+ ]++instance Data.ToQuery DescribeDevice where+ toQuery = Prelude.const Prelude.mempty++-- | /See:/ 'newDescribeDeviceResponse' smart constructor.+data DescribeDeviceResponse = DescribeDeviceResponse'+ { -- | The ID of the job used when ordering the device.+ associatedWithJob :: Prelude.Maybe Prelude.Text,+ -- | The hardware specifications of the device.+ deviceCapacities :: Prelude.Maybe [Capacity],+ -- | The current state of the device.+ deviceState :: Prelude.Maybe UnlockState,+ -- | The type of Amazon Web Services Snow Family device.+ deviceType :: Prelude.Maybe Prelude.Text,+ -- | When the device last contacted the Amazon Web Services Cloud. Indicates+ -- that the device is online.+ lastReachedOutAt :: Prelude.Maybe Data.POSIX,+ -- | When the device last pushed an update to the Amazon Web Services Cloud.+ -- Indicates when the device cache was refreshed.+ lastUpdatedAt :: Prelude.Maybe Data.POSIX,+ -- | The Amazon Resource Name (ARN) of the device.+ managedDeviceArn :: Prelude.Maybe Prelude.Text,+ -- | The ID of the device that you checked the information for.+ managedDeviceId :: Prelude.Maybe Prelude.Text,+ -- | The network interfaces available on the device.+ physicalNetworkInterfaces :: Prelude.Maybe [PhysicalNetworkInterface],+ -- | The software installed on the device.+ software :: Prelude.Maybe SoftwareInformation,+ -- | Optional metadata that you assign to a resource. You can use tags to+ -- categorize a resource in different ways, such as by purpose, owner, or+ -- environment.+ tags :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),+ -- | The response's http status code.+ httpStatus :: Prelude.Int+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'DescribeDeviceResponse' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'associatedWithJob', 'describeDeviceResponse_associatedWithJob' - The ID of the job used when ordering the device.+--+-- 'deviceCapacities', 'describeDeviceResponse_deviceCapacities' - The hardware specifications of the device.+--+-- 'deviceState', 'describeDeviceResponse_deviceState' - The current state of the device.+--+-- 'deviceType', 'describeDeviceResponse_deviceType' - The type of Amazon Web Services Snow Family device.+--+-- 'lastReachedOutAt', 'describeDeviceResponse_lastReachedOutAt' - When the device last contacted the Amazon Web Services Cloud. Indicates+-- that the device is online.+--+-- 'lastUpdatedAt', 'describeDeviceResponse_lastUpdatedAt' - When the device last pushed an update to the Amazon Web Services Cloud.+-- Indicates when the device cache was refreshed.+--+-- 'managedDeviceArn', 'describeDeviceResponse_managedDeviceArn' - The Amazon Resource Name (ARN) of the device.+--+-- 'managedDeviceId', 'describeDeviceResponse_managedDeviceId' - The ID of the device that you checked the information for.+--+-- 'physicalNetworkInterfaces', 'describeDeviceResponse_physicalNetworkInterfaces' - The network interfaces available on the device.+--+-- 'software', 'describeDeviceResponse_software' - The software installed on the device.+--+-- 'tags', 'describeDeviceResponse_tags' - Optional metadata that you assign to a resource. You can use tags to+-- categorize a resource in different ways, such as by purpose, owner, or+-- environment.+--+-- 'httpStatus', 'describeDeviceResponse_httpStatus' - The response's http status code.+newDescribeDeviceResponse ::+ -- | 'httpStatus'+ Prelude.Int ->+ DescribeDeviceResponse+newDescribeDeviceResponse pHttpStatus_ =+ DescribeDeviceResponse'+ { associatedWithJob =+ Prelude.Nothing,+ deviceCapacities = Prelude.Nothing,+ deviceState = Prelude.Nothing,+ deviceType = Prelude.Nothing,+ lastReachedOutAt = Prelude.Nothing,+ lastUpdatedAt = Prelude.Nothing,+ managedDeviceArn = Prelude.Nothing,+ managedDeviceId = Prelude.Nothing,+ physicalNetworkInterfaces = Prelude.Nothing,+ software = Prelude.Nothing,+ tags = Prelude.Nothing,+ httpStatus = pHttpStatus_+ }++-- | The ID of the job used when ordering the device.+describeDeviceResponse_associatedWithJob :: Lens.Lens' DescribeDeviceResponse (Prelude.Maybe Prelude.Text)+describeDeviceResponse_associatedWithJob = Lens.lens (\DescribeDeviceResponse' {associatedWithJob} -> associatedWithJob) (\s@DescribeDeviceResponse' {} a -> s {associatedWithJob = a} :: DescribeDeviceResponse)++-- | The hardware specifications of the device.+describeDeviceResponse_deviceCapacities :: Lens.Lens' DescribeDeviceResponse (Prelude.Maybe [Capacity])+describeDeviceResponse_deviceCapacities = Lens.lens (\DescribeDeviceResponse' {deviceCapacities} -> deviceCapacities) (\s@DescribeDeviceResponse' {} a -> s {deviceCapacities = a} :: DescribeDeviceResponse) Prelude.. Lens.mapping Lens.coerced++-- | The current state of the device.+describeDeviceResponse_deviceState :: Lens.Lens' DescribeDeviceResponse (Prelude.Maybe UnlockState)+describeDeviceResponse_deviceState = Lens.lens (\DescribeDeviceResponse' {deviceState} -> deviceState) (\s@DescribeDeviceResponse' {} a -> s {deviceState = a} :: DescribeDeviceResponse)++-- | The type of Amazon Web Services Snow Family device.+describeDeviceResponse_deviceType :: Lens.Lens' DescribeDeviceResponse (Prelude.Maybe Prelude.Text)+describeDeviceResponse_deviceType = Lens.lens (\DescribeDeviceResponse' {deviceType} -> deviceType) (\s@DescribeDeviceResponse' {} a -> s {deviceType = a} :: DescribeDeviceResponse)++-- | When the device last contacted the Amazon Web Services Cloud. Indicates+-- that the device is online.+describeDeviceResponse_lastReachedOutAt :: Lens.Lens' DescribeDeviceResponse (Prelude.Maybe Prelude.UTCTime)+describeDeviceResponse_lastReachedOutAt = Lens.lens (\DescribeDeviceResponse' {lastReachedOutAt} -> lastReachedOutAt) (\s@DescribeDeviceResponse' {} a -> s {lastReachedOutAt = a} :: DescribeDeviceResponse) Prelude.. Lens.mapping Data._Time++-- | When the device last pushed an update to the Amazon Web Services Cloud.+-- Indicates when the device cache was refreshed.+describeDeviceResponse_lastUpdatedAt :: Lens.Lens' DescribeDeviceResponse (Prelude.Maybe Prelude.UTCTime)+describeDeviceResponse_lastUpdatedAt = Lens.lens (\DescribeDeviceResponse' {lastUpdatedAt} -> lastUpdatedAt) (\s@DescribeDeviceResponse' {} a -> s {lastUpdatedAt = a} :: DescribeDeviceResponse) Prelude.. Lens.mapping Data._Time++-- | The Amazon Resource Name (ARN) of the device.+describeDeviceResponse_managedDeviceArn :: Lens.Lens' DescribeDeviceResponse (Prelude.Maybe Prelude.Text)+describeDeviceResponse_managedDeviceArn = Lens.lens (\DescribeDeviceResponse' {managedDeviceArn} -> managedDeviceArn) (\s@DescribeDeviceResponse' {} a -> s {managedDeviceArn = a} :: DescribeDeviceResponse)++-- | The ID of the device that you checked the information for.+describeDeviceResponse_managedDeviceId :: Lens.Lens' DescribeDeviceResponse (Prelude.Maybe Prelude.Text)+describeDeviceResponse_managedDeviceId = Lens.lens (\DescribeDeviceResponse' {managedDeviceId} -> managedDeviceId) (\s@DescribeDeviceResponse' {} a -> s {managedDeviceId = a} :: DescribeDeviceResponse)++-- | The network interfaces available on the device.+describeDeviceResponse_physicalNetworkInterfaces :: Lens.Lens' DescribeDeviceResponse (Prelude.Maybe [PhysicalNetworkInterface])+describeDeviceResponse_physicalNetworkInterfaces = Lens.lens (\DescribeDeviceResponse' {physicalNetworkInterfaces} -> physicalNetworkInterfaces) (\s@DescribeDeviceResponse' {} a -> s {physicalNetworkInterfaces = a} :: DescribeDeviceResponse) Prelude.. Lens.mapping Lens.coerced++-- | The software installed on the device.+describeDeviceResponse_software :: Lens.Lens' DescribeDeviceResponse (Prelude.Maybe SoftwareInformation)+describeDeviceResponse_software = Lens.lens (\DescribeDeviceResponse' {software} -> software) (\s@DescribeDeviceResponse' {} a -> s {software = a} :: DescribeDeviceResponse)++-- | Optional metadata that you assign to a resource. You can use tags to+-- categorize a resource in different ways, such as by purpose, owner, or+-- environment.+describeDeviceResponse_tags :: Lens.Lens' DescribeDeviceResponse (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))+describeDeviceResponse_tags = Lens.lens (\DescribeDeviceResponse' {tags} -> tags) (\s@DescribeDeviceResponse' {} a -> s {tags = a} :: DescribeDeviceResponse) Prelude.. Lens.mapping Lens.coerced++-- | The response's http status code.+describeDeviceResponse_httpStatus :: Lens.Lens' DescribeDeviceResponse Prelude.Int+describeDeviceResponse_httpStatus = Lens.lens (\DescribeDeviceResponse' {httpStatus} -> httpStatus) (\s@DescribeDeviceResponse' {} a -> s {httpStatus = a} :: DescribeDeviceResponse)++instance Prelude.NFData DescribeDeviceResponse where+ rnf DescribeDeviceResponse' {..} =+ Prelude.rnf associatedWithJob+ `Prelude.seq` Prelude.rnf deviceCapacities+ `Prelude.seq` Prelude.rnf deviceState+ `Prelude.seq` Prelude.rnf deviceType+ `Prelude.seq` Prelude.rnf lastReachedOutAt+ `Prelude.seq` Prelude.rnf lastUpdatedAt+ `Prelude.seq` Prelude.rnf managedDeviceArn+ `Prelude.seq` Prelude.rnf managedDeviceId+ `Prelude.seq` Prelude.rnf physicalNetworkInterfaces+ `Prelude.seq` Prelude.rnf software+ `Prelude.seq` Prelude.rnf tags+ `Prelude.seq` Prelude.rnf httpStatus
+ gen/Amazonka/SnowDeviceManagement/DescribeDeviceEc2Instances.hs view
@@ -0,0 +1,192 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-binds #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.DescribeDeviceEc2Instances+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Checks the current state of the Amazon EC2 instances. The output is+-- similar to @describeDevice@, but the results are sourced from the device+-- cache in the Amazon Web Services Cloud and include a subset of the+-- available fields.+module Amazonka.SnowDeviceManagement.DescribeDeviceEc2Instances+ ( -- * Creating a Request+ DescribeDeviceEc2Instances (..),+ newDescribeDeviceEc2Instances,++ -- * Request Lenses+ describeDeviceEc2Instances_instanceIds,+ describeDeviceEc2Instances_managedDeviceId,++ -- * Destructuring the Response+ DescribeDeviceEc2InstancesResponse (..),+ newDescribeDeviceEc2InstancesResponse,++ -- * Response Lenses+ describeDeviceEc2InstancesResponse_instances,+ describeDeviceEc2InstancesResponse_httpStatus,+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import qualified Amazonka.Request as Request+import qualified Amazonka.Response as Response+import Amazonka.SnowDeviceManagement.Types++-- | /See:/ 'newDescribeDeviceEc2Instances' smart constructor.+data DescribeDeviceEc2Instances = DescribeDeviceEc2Instances'+ { -- | A list of instance IDs associated with the managed device.+ instanceIds :: [Prelude.Text],+ -- | The ID of the managed device.+ managedDeviceId :: Prelude.Text+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'DescribeDeviceEc2Instances' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'instanceIds', 'describeDeviceEc2Instances_instanceIds' - A list of instance IDs associated with the managed device.+--+-- 'managedDeviceId', 'describeDeviceEc2Instances_managedDeviceId' - The ID of the managed device.+newDescribeDeviceEc2Instances ::+ -- | 'managedDeviceId'+ Prelude.Text ->+ DescribeDeviceEc2Instances+newDescribeDeviceEc2Instances pManagedDeviceId_ =+ DescribeDeviceEc2Instances'+ { instanceIds =+ Prelude.mempty,+ managedDeviceId = pManagedDeviceId_+ }++-- | A list of instance IDs associated with the managed device.+describeDeviceEc2Instances_instanceIds :: Lens.Lens' DescribeDeviceEc2Instances [Prelude.Text]+describeDeviceEc2Instances_instanceIds = Lens.lens (\DescribeDeviceEc2Instances' {instanceIds} -> instanceIds) (\s@DescribeDeviceEc2Instances' {} a -> s {instanceIds = a} :: DescribeDeviceEc2Instances) Prelude.. Lens.coerced++-- | The ID of the managed device.+describeDeviceEc2Instances_managedDeviceId :: Lens.Lens' DescribeDeviceEc2Instances Prelude.Text+describeDeviceEc2Instances_managedDeviceId = Lens.lens (\DescribeDeviceEc2Instances' {managedDeviceId} -> managedDeviceId) (\s@DescribeDeviceEc2Instances' {} a -> s {managedDeviceId = a} :: DescribeDeviceEc2Instances)++instance Core.AWSRequest DescribeDeviceEc2Instances where+ type+ AWSResponse DescribeDeviceEc2Instances =+ DescribeDeviceEc2InstancesResponse+ request overrides =+ Request.postJSON (overrides defaultService)+ response =+ Response.receiveJSON+ ( \s h x ->+ DescribeDeviceEc2InstancesResponse'+ Prelude.<$> (x Data..?> "instances" Core..!@ Prelude.mempty)+ Prelude.<*> (Prelude.pure (Prelude.fromEnum s))+ )++instance Prelude.Hashable DescribeDeviceEc2Instances where+ hashWithSalt _salt DescribeDeviceEc2Instances' {..} =+ _salt+ `Prelude.hashWithSalt` instanceIds+ `Prelude.hashWithSalt` managedDeviceId++instance Prelude.NFData DescribeDeviceEc2Instances where+ rnf DescribeDeviceEc2Instances' {..} =+ Prelude.rnf instanceIds+ `Prelude.seq` Prelude.rnf managedDeviceId++instance Data.ToHeaders DescribeDeviceEc2Instances where+ toHeaders =+ Prelude.const+ ( Prelude.mconcat+ [ "Content-Type"+ Data.=# ( "application/x-amz-json-1.1" ::+ Prelude.ByteString+ )+ ]+ )++instance Data.ToJSON DescribeDeviceEc2Instances where+ toJSON DescribeDeviceEc2Instances' {..} =+ Data.object+ ( Prelude.catMaybes+ [Prelude.Just ("instanceIds" Data..= instanceIds)]+ )++instance Data.ToPath DescribeDeviceEc2Instances where+ toPath DescribeDeviceEc2Instances' {..} =+ Prelude.mconcat+ [ "/managed-device/",+ Data.toBS managedDeviceId,+ "/resources/ec2/describe"+ ]++instance Data.ToQuery DescribeDeviceEc2Instances where+ toQuery = Prelude.const Prelude.mempty++-- | /See:/ 'newDescribeDeviceEc2InstancesResponse' smart constructor.+data DescribeDeviceEc2InstancesResponse = DescribeDeviceEc2InstancesResponse'+ { -- | A list of structures containing information about each instance.+ instances :: Prelude.Maybe [InstanceSummary],+ -- | The response's http status code.+ httpStatus :: Prelude.Int+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'DescribeDeviceEc2InstancesResponse' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'instances', 'describeDeviceEc2InstancesResponse_instances' - A list of structures containing information about each instance.+--+-- 'httpStatus', 'describeDeviceEc2InstancesResponse_httpStatus' - The response's http status code.+newDescribeDeviceEc2InstancesResponse ::+ -- | 'httpStatus'+ Prelude.Int ->+ DescribeDeviceEc2InstancesResponse+newDescribeDeviceEc2InstancesResponse pHttpStatus_ =+ DescribeDeviceEc2InstancesResponse'+ { instances =+ Prelude.Nothing,+ httpStatus = pHttpStatus_+ }++-- | A list of structures containing information about each instance.+describeDeviceEc2InstancesResponse_instances :: Lens.Lens' DescribeDeviceEc2InstancesResponse (Prelude.Maybe [InstanceSummary])+describeDeviceEc2InstancesResponse_instances = Lens.lens (\DescribeDeviceEc2InstancesResponse' {instances} -> instances) (\s@DescribeDeviceEc2InstancesResponse' {} a -> s {instances = a} :: DescribeDeviceEc2InstancesResponse) Prelude.. Lens.mapping Lens.coerced++-- | The response's http status code.+describeDeviceEc2InstancesResponse_httpStatus :: Lens.Lens' DescribeDeviceEc2InstancesResponse Prelude.Int+describeDeviceEc2InstancesResponse_httpStatus = Lens.lens (\DescribeDeviceEc2InstancesResponse' {httpStatus} -> httpStatus) (\s@DescribeDeviceEc2InstancesResponse' {} a -> s {httpStatus = a} :: DescribeDeviceEc2InstancesResponse)++instance+ Prelude.NFData+ DescribeDeviceEc2InstancesResponse+ where+ rnf DescribeDeviceEc2InstancesResponse' {..} =+ Prelude.rnf instances+ `Prelude.seq` Prelude.rnf httpStatus
+ gen/Amazonka/SnowDeviceManagement/DescribeExecution.hs view
@@ -0,0 +1,246 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-binds #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.DescribeExecution+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Checks the status of a remote task running on one or more target+-- devices.+module Amazonka.SnowDeviceManagement.DescribeExecution+ ( -- * Creating a Request+ DescribeExecution (..),+ newDescribeExecution,++ -- * Request Lenses+ describeExecution_managedDeviceId,+ describeExecution_taskId,++ -- * Destructuring the Response+ DescribeExecutionResponse (..),+ newDescribeExecutionResponse,++ -- * Response Lenses+ describeExecutionResponse_executionId,+ describeExecutionResponse_lastUpdatedAt,+ describeExecutionResponse_managedDeviceId,+ describeExecutionResponse_startedAt,+ describeExecutionResponse_state,+ describeExecutionResponse_taskId,+ describeExecutionResponse_httpStatus,+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import qualified Amazonka.Request as Request+import qualified Amazonka.Response as Response+import Amazonka.SnowDeviceManagement.Types++-- | /See:/ 'newDescribeExecution' smart constructor.+data DescribeExecution = DescribeExecution'+ { -- | The ID of the managed device.+ managedDeviceId :: Prelude.Text,+ -- | The ID of the task that the action is describing.+ taskId :: Prelude.Text+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'DescribeExecution' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'managedDeviceId', 'describeExecution_managedDeviceId' - The ID of the managed device.+--+-- 'taskId', 'describeExecution_taskId' - The ID of the task that the action is describing.+newDescribeExecution ::+ -- | 'managedDeviceId'+ Prelude.Text ->+ -- | 'taskId'+ Prelude.Text ->+ DescribeExecution+newDescribeExecution pManagedDeviceId_ pTaskId_ =+ DescribeExecution'+ { managedDeviceId =+ pManagedDeviceId_,+ taskId = pTaskId_+ }++-- | The ID of the managed device.+describeExecution_managedDeviceId :: Lens.Lens' DescribeExecution Prelude.Text+describeExecution_managedDeviceId = Lens.lens (\DescribeExecution' {managedDeviceId} -> managedDeviceId) (\s@DescribeExecution' {} a -> s {managedDeviceId = a} :: DescribeExecution)++-- | The ID of the task that the action is describing.+describeExecution_taskId :: Lens.Lens' DescribeExecution Prelude.Text+describeExecution_taskId = Lens.lens (\DescribeExecution' {taskId} -> taskId) (\s@DescribeExecution' {} a -> s {taskId = a} :: DescribeExecution)++instance Core.AWSRequest DescribeExecution where+ type+ AWSResponse DescribeExecution =+ DescribeExecutionResponse+ request overrides =+ Request.postJSON (overrides defaultService)+ response =+ Response.receiveJSON+ ( \s h x ->+ DescribeExecutionResponse'+ Prelude.<$> (x Data..?> "executionId")+ Prelude.<*> (x Data..?> "lastUpdatedAt")+ Prelude.<*> (x Data..?> "managedDeviceId")+ Prelude.<*> (x Data..?> "startedAt")+ Prelude.<*> (x Data..?> "state")+ Prelude.<*> (x Data..?> "taskId")+ Prelude.<*> (Prelude.pure (Prelude.fromEnum s))+ )++instance Prelude.Hashable DescribeExecution where+ hashWithSalt _salt DescribeExecution' {..} =+ _salt+ `Prelude.hashWithSalt` managedDeviceId+ `Prelude.hashWithSalt` taskId++instance Prelude.NFData DescribeExecution where+ rnf DescribeExecution' {..} =+ Prelude.rnf managedDeviceId+ `Prelude.seq` Prelude.rnf taskId++instance Data.ToHeaders DescribeExecution where+ toHeaders =+ Prelude.const+ ( Prelude.mconcat+ [ "Content-Type"+ Data.=# ( "application/x-amz-json-1.1" ::+ Prelude.ByteString+ )+ ]+ )++instance Data.ToJSON DescribeExecution where+ toJSON = Prelude.const (Data.Object Prelude.mempty)++instance Data.ToPath DescribeExecution where+ toPath DescribeExecution' {..} =+ Prelude.mconcat+ [ "/task/",+ Data.toBS taskId,+ "/execution/",+ Data.toBS managedDeviceId+ ]++instance Data.ToQuery DescribeExecution where+ toQuery = Prelude.const Prelude.mempty++-- | /See:/ 'newDescribeExecutionResponse' smart constructor.+data DescribeExecutionResponse = DescribeExecutionResponse'+ { -- | The ID of the execution.+ executionId :: Prelude.Maybe Prelude.Text,+ -- | When the status of the execution was last updated.+ lastUpdatedAt :: Prelude.Maybe Data.POSIX,+ -- | The ID of the managed device that the task is being executed on.+ managedDeviceId :: Prelude.Maybe Prelude.Text,+ -- | When the execution began.+ startedAt :: Prelude.Maybe Data.POSIX,+ -- | The current state of the execution.+ state :: Prelude.Maybe ExecutionState,+ -- | The ID of the task being executed on the device.+ taskId :: Prelude.Maybe Prelude.Text,+ -- | The response's http status code.+ httpStatus :: Prelude.Int+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'DescribeExecutionResponse' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'executionId', 'describeExecutionResponse_executionId' - The ID of the execution.+--+-- 'lastUpdatedAt', 'describeExecutionResponse_lastUpdatedAt' - When the status of the execution was last updated.+--+-- 'managedDeviceId', 'describeExecutionResponse_managedDeviceId' - The ID of the managed device that the task is being executed on.+--+-- 'startedAt', 'describeExecutionResponse_startedAt' - When the execution began.+--+-- 'state', 'describeExecutionResponse_state' - The current state of the execution.+--+-- 'taskId', 'describeExecutionResponse_taskId' - The ID of the task being executed on the device.+--+-- 'httpStatus', 'describeExecutionResponse_httpStatus' - The response's http status code.+newDescribeExecutionResponse ::+ -- | 'httpStatus'+ Prelude.Int ->+ DescribeExecutionResponse+newDescribeExecutionResponse pHttpStatus_ =+ DescribeExecutionResponse'+ { executionId =+ Prelude.Nothing,+ lastUpdatedAt = Prelude.Nothing,+ managedDeviceId = Prelude.Nothing,+ startedAt = Prelude.Nothing,+ state = Prelude.Nothing,+ taskId = Prelude.Nothing,+ httpStatus = pHttpStatus_+ }++-- | The ID of the execution.+describeExecutionResponse_executionId :: Lens.Lens' DescribeExecutionResponse (Prelude.Maybe Prelude.Text)+describeExecutionResponse_executionId = Lens.lens (\DescribeExecutionResponse' {executionId} -> executionId) (\s@DescribeExecutionResponse' {} a -> s {executionId = a} :: DescribeExecutionResponse)++-- | When the status of the execution was last updated.+describeExecutionResponse_lastUpdatedAt :: Lens.Lens' DescribeExecutionResponse (Prelude.Maybe Prelude.UTCTime)+describeExecutionResponse_lastUpdatedAt = Lens.lens (\DescribeExecutionResponse' {lastUpdatedAt} -> lastUpdatedAt) (\s@DescribeExecutionResponse' {} a -> s {lastUpdatedAt = a} :: DescribeExecutionResponse) Prelude.. Lens.mapping Data._Time++-- | The ID of the managed device that the task is being executed on.+describeExecutionResponse_managedDeviceId :: Lens.Lens' DescribeExecutionResponse (Prelude.Maybe Prelude.Text)+describeExecutionResponse_managedDeviceId = Lens.lens (\DescribeExecutionResponse' {managedDeviceId} -> managedDeviceId) (\s@DescribeExecutionResponse' {} a -> s {managedDeviceId = a} :: DescribeExecutionResponse)++-- | When the execution began.+describeExecutionResponse_startedAt :: Lens.Lens' DescribeExecutionResponse (Prelude.Maybe Prelude.UTCTime)+describeExecutionResponse_startedAt = Lens.lens (\DescribeExecutionResponse' {startedAt} -> startedAt) (\s@DescribeExecutionResponse' {} a -> s {startedAt = a} :: DescribeExecutionResponse) Prelude.. Lens.mapping Data._Time++-- | The current state of the execution.+describeExecutionResponse_state :: Lens.Lens' DescribeExecutionResponse (Prelude.Maybe ExecutionState)+describeExecutionResponse_state = Lens.lens (\DescribeExecutionResponse' {state} -> state) (\s@DescribeExecutionResponse' {} a -> s {state = a} :: DescribeExecutionResponse)++-- | The ID of the task being executed on the device.+describeExecutionResponse_taskId :: Lens.Lens' DescribeExecutionResponse (Prelude.Maybe Prelude.Text)+describeExecutionResponse_taskId = Lens.lens (\DescribeExecutionResponse' {taskId} -> taskId) (\s@DescribeExecutionResponse' {} a -> s {taskId = a} :: DescribeExecutionResponse)++-- | The response's http status code.+describeExecutionResponse_httpStatus :: Lens.Lens' DescribeExecutionResponse Prelude.Int+describeExecutionResponse_httpStatus = Lens.lens (\DescribeExecutionResponse' {httpStatus} -> httpStatus) (\s@DescribeExecutionResponse' {} a -> s {httpStatus = a} :: DescribeExecutionResponse)++instance Prelude.NFData DescribeExecutionResponse where+ rnf DescribeExecutionResponse' {..} =+ Prelude.rnf executionId+ `Prelude.seq` Prelude.rnf lastUpdatedAt+ `Prelude.seq` Prelude.rnf managedDeviceId+ `Prelude.seq` Prelude.rnf startedAt+ `Prelude.seq` Prelude.rnf state+ `Prelude.seq` Prelude.rnf taskId+ `Prelude.seq` Prelude.rnf httpStatus
+ gen/Amazonka/SnowDeviceManagement/DescribeTask.hs view
@@ -0,0 +1,261 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-binds #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.DescribeTask+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Checks the metadata for a given task on a device.+module Amazonka.SnowDeviceManagement.DescribeTask+ ( -- * Creating a Request+ DescribeTask (..),+ newDescribeTask,++ -- * Request Lenses+ describeTask_taskId,++ -- * Destructuring the Response+ DescribeTaskResponse (..),+ newDescribeTaskResponse,++ -- * Response Lenses+ describeTaskResponse_completedAt,+ describeTaskResponse_createdAt,+ describeTaskResponse_description,+ describeTaskResponse_lastUpdatedAt,+ describeTaskResponse_state,+ describeTaskResponse_tags,+ describeTaskResponse_targets,+ describeTaskResponse_taskArn,+ describeTaskResponse_taskId,+ describeTaskResponse_httpStatus,+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import qualified Amazonka.Request as Request+import qualified Amazonka.Response as Response+import Amazonka.SnowDeviceManagement.Types++-- | /See:/ 'newDescribeTask' smart constructor.+data DescribeTask = DescribeTask'+ { -- | The ID of the task to be described.+ taskId :: Prelude.Text+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'DescribeTask' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'taskId', 'describeTask_taskId' - The ID of the task to be described.+newDescribeTask ::+ -- | 'taskId'+ Prelude.Text ->+ DescribeTask+newDescribeTask pTaskId_ =+ DescribeTask' {taskId = pTaskId_}++-- | The ID of the task to be described.+describeTask_taskId :: Lens.Lens' DescribeTask Prelude.Text+describeTask_taskId = Lens.lens (\DescribeTask' {taskId} -> taskId) (\s@DescribeTask' {} a -> s {taskId = a} :: DescribeTask)++instance Core.AWSRequest DescribeTask where+ type AWSResponse DescribeTask = DescribeTaskResponse+ request overrides =+ Request.postJSON (overrides defaultService)+ response =+ Response.receiveJSON+ ( \s h x ->+ DescribeTaskResponse'+ Prelude.<$> (x Data..?> "completedAt")+ Prelude.<*> (x Data..?> "createdAt")+ Prelude.<*> (x Data..?> "description")+ Prelude.<*> (x Data..?> "lastUpdatedAt")+ Prelude.<*> (x Data..?> "state")+ Prelude.<*> (x Data..?> "tags" Core..!@ Prelude.mempty)+ Prelude.<*> (x Data..?> "targets")+ Prelude.<*> (x Data..?> "taskArn")+ Prelude.<*> (x Data..?> "taskId")+ Prelude.<*> (Prelude.pure (Prelude.fromEnum s))+ )++instance Prelude.Hashable DescribeTask where+ hashWithSalt _salt DescribeTask' {..} =+ _salt `Prelude.hashWithSalt` taskId++instance Prelude.NFData DescribeTask where+ rnf DescribeTask' {..} = Prelude.rnf taskId++instance Data.ToHeaders DescribeTask where+ toHeaders =+ Prelude.const+ ( Prelude.mconcat+ [ "Content-Type"+ Data.=# ( "application/x-amz-json-1.1" ::+ Prelude.ByteString+ )+ ]+ )++instance Data.ToJSON DescribeTask where+ toJSON = Prelude.const (Data.Object Prelude.mempty)++instance Data.ToPath DescribeTask where+ toPath DescribeTask' {..} =+ Prelude.mconcat ["/task/", Data.toBS taskId]++instance Data.ToQuery DescribeTask where+ toQuery = Prelude.const Prelude.mempty++-- | /See:/ 'newDescribeTaskResponse' smart constructor.+data DescribeTaskResponse = DescribeTaskResponse'+ { -- | When the task was completed.+ completedAt :: Prelude.Maybe Data.POSIX,+ -- | When the @CreateTask@ operation was called.+ createdAt :: Prelude.Maybe Data.POSIX,+ -- | The description provided of the task and managed devices.+ description :: Prelude.Maybe Prelude.Text,+ -- | When the state of the task was last updated.+ lastUpdatedAt :: Prelude.Maybe Data.POSIX,+ -- | The current state of the task.+ state :: Prelude.Maybe TaskState,+ -- | Optional metadata that you assign to a resource. You can use tags to+ -- categorize a resource in different ways, such as by purpose, owner, or+ -- environment.+ tags :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),+ -- | The managed devices that the task was sent to.+ targets :: Prelude.Maybe (Prelude.NonEmpty Prelude.Text),+ -- | The Amazon Resource Name (ARN) of the task.+ taskArn :: Prelude.Maybe Prelude.Text,+ -- | The ID of the task.+ taskId :: Prelude.Maybe Prelude.Text,+ -- | The response's http status code.+ httpStatus :: Prelude.Int+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'DescribeTaskResponse' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'completedAt', 'describeTaskResponse_completedAt' - When the task was completed.+--+-- 'createdAt', 'describeTaskResponse_createdAt' - When the @CreateTask@ operation was called.+--+-- 'description', 'describeTaskResponse_description' - The description provided of the task and managed devices.+--+-- 'lastUpdatedAt', 'describeTaskResponse_lastUpdatedAt' - When the state of the task was last updated.+--+-- 'state', 'describeTaskResponse_state' - The current state of the task.+--+-- 'tags', 'describeTaskResponse_tags' - Optional metadata that you assign to a resource. You can use tags to+-- categorize a resource in different ways, such as by purpose, owner, or+-- environment.+--+-- 'targets', 'describeTaskResponse_targets' - The managed devices that the task was sent to.+--+-- 'taskArn', 'describeTaskResponse_taskArn' - The Amazon Resource Name (ARN) of the task.+--+-- 'taskId', 'describeTaskResponse_taskId' - The ID of the task.+--+-- 'httpStatus', 'describeTaskResponse_httpStatus' - The response's http status code.+newDescribeTaskResponse ::+ -- | 'httpStatus'+ Prelude.Int ->+ DescribeTaskResponse+newDescribeTaskResponse pHttpStatus_ =+ DescribeTaskResponse'+ { completedAt =+ Prelude.Nothing,+ createdAt = Prelude.Nothing,+ description = Prelude.Nothing,+ lastUpdatedAt = Prelude.Nothing,+ state = Prelude.Nothing,+ tags = Prelude.Nothing,+ targets = Prelude.Nothing,+ taskArn = Prelude.Nothing,+ taskId = Prelude.Nothing,+ httpStatus = pHttpStatus_+ }++-- | When the task was completed.+describeTaskResponse_completedAt :: Lens.Lens' DescribeTaskResponse (Prelude.Maybe Prelude.UTCTime)+describeTaskResponse_completedAt = Lens.lens (\DescribeTaskResponse' {completedAt} -> completedAt) (\s@DescribeTaskResponse' {} a -> s {completedAt = a} :: DescribeTaskResponse) Prelude.. Lens.mapping Data._Time++-- | When the @CreateTask@ operation was called.+describeTaskResponse_createdAt :: Lens.Lens' DescribeTaskResponse (Prelude.Maybe Prelude.UTCTime)+describeTaskResponse_createdAt = Lens.lens (\DescribeTaskResponse' {createdAt} -> createdAt) (\s@DescribeTaskResponse' {} a -> s {createdAt = a} :: DescribeTaskResponse) Prelude.. Lens.mapping Data._Time++-- | The description provided of the task and managed devices.+describeTaskResponse_description :: Lens.Lens' DescribeTaskResponse (Prelude.Maybe Prelude.Text)+describeTaskResponse_description = Lens.lens (\DescribeTaskResponse' {description} -> description) (\s@DescribeTaskResponse' {} a -> s {description = a} :: DescribeTaskResponse)++-- | When the state of the task was last updated.+describeTaskResponse_lastUpdatedAt :: Lens.Lens' DescribeTaskResponse (Prelude.Maybe Prelude.UTCTime)+describeTaskResponse_lastUpdatedAt = Lens.lens (\DescribeTaskResponse' {lastUpdatedAt} -> lastUpdatedAt) (\s@DescribeTaskResponse' {} a -> s {lastUpdatedAt = a} :: DescribeTaskResponse) Prelude.. Lens.mapping Data._Time++-- | The current state of the task.+describeTaskResponse_state :: Lens.Lens' DescribeTaskResponse (Prelude.Maybe TaskState)+describeTaskResponse_state = Lens.lens (\DescribeTaskResponse' {state} -> state) (\s@DescribeTaskResponse' {} a -> s {state = a} :: DescribeTaskResponse)++-- | Optional metadata that you assign to a resource. You can use tags to+-- categorize a resource in different ways, such as by purpose, owner, or+-- environment.+describeTaskResponse_tags :: Lens.Lens' DescribeTaskResponse (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))+describeTaskResponse_tags = Lens.lens (\DescribeTaskResponse' {tags} -> tags) (\s@DescribeTaskResponse' {} a -> s {tags = a} :: DescribeTaskResponse) Prelude.. Lens.mapping Lens.coerced++-- | The managed devices that the task was sent to.+describeTaskResponse_targets :: Lens.Lens' DescribeTaskResponse (Prelude.Maybe (Prelude.NonEmpty Prelude.Text))+describeTaskResponse_targets = Lens.lens (\DescribeTaskResponse' {targets} -> targets) (\s@DescribeTaskResponse' {} a -> s {targets = a} :: DescribeTaskResponse) Prelude.. Lens.mapping Lens.coerced++-- | The Amazon Resource Name (ARN) of the task.+describeTaskResponse_taskArn :: Lens.Lens' DescribeTaskResponse (Prelude.Maybe Prelude.Text)+describeTaskResponse_taskArn = Lens.lens (\DescribeTaskResponse' {taskArn} -> taskArn) (\s@DescribeTaskResponse' {} a -> s {taskArn = a} :: DescribeTaskResponse)++-- | The ID of the task.+describeTaskResponse_taskId :: Lens.Lens' DescribeTaskResponse (Prelude.Maybe Prelude.Text)+describeTaskResponse_taskId = Lens.lens (\DescribeTaskResponse' {taskId} -> taskId) (\s@DescribeTaskResponse' {} a -> s {taskId = a} :: DescribeTaskResponse)++-- | The response's http status code.+describeTaskResponse_httpStatus :: Lens.Lens' DescribeTaskResponse Prelude.Int+describeTaskResponse_httpStatus = Lens.lens (\DescribeTaskResponse' {httpStatus} -> httpStatus) (\s@DescribeTaskResponse' {} a -> s {httpStatus = a} :: DescribeTaskResponse)++instance Prelude.NFData DescribeTaskResponse where+ rnf DescribeTaskResponse' {..} =+ Prelude.rnf completedAt+ `Prelude.seq` Prelude.rnf createdAt+ `Prelude.seq` Prelude.rnf description+ `Prelude.seq` Prelude.rnf lastUpdatedAt+ `Prelude.seq` Prelude.rnf state+ `Prelude.seq` Prelude.rnf tags+ `Prelude.seq` Prelude.rnf targets+ `Prelude.seq` Prelude.rnf taskArn+ `Prelude.seq` Prelude.rnf taskId+ `Prelude.seq` Prelude.rnf httpStatus
+ gen/Amazonka/SnowDeviceManagement/Lens.hs view
@@ -0,0 +1,250 @@+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Lens+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Lens+ ( -- * Operations++ -- ** CancelTask+ cancelTask_taskId,+ cancelTaskResponse_taskId,+ cancelTaskResponse_httpStatus,++ -- ** CreateTask+ createTask_clientToken,+ createTask_description,+ createTask_tags,+ createTask_command,+ createTask_targets,+ createTaskResponse_taskArn,+ createTaskResponse_taskId,+ createTaskResponse_httpStatus,++ -- ** DescribeDevice+ describeDevice_managedDeviceId,+ describeDeviceResponse_associatedWithJob,+ describeDeviceResponse_deviceCapacities,+ describeDeviceResponse_deviceState,+ describeDeviceResponse_deviceType,+ describeDeviceResponse_lastReachedOutAt,+ describeDeviceResponse_lastUpdatedAt,+ describeDeviceResponse_managedDeviceArn,+ describeDeviceResponse_managedDeviceId,+ describeDeviceResponse_physicalNetworkInterfaces,+ describeDeviceResponse_software,+ describeDeviceResponse_tags,+ describeDeviceResponse_httpStatus,++ -- ** DescribeDeviceEc2Instances+ describeDeviceEc2Instances_instanceIds,+ describeDeviceEc2Instances_managedDeviceId,+ describeDeviceEc2InstancesResponse_instances,+ describeDeviceEc2InstancesResponse_httpStatus,++ -- ** DescribeExecution+ describeExecution_managedDeviceId,+ describeExecution_taskId,+ describeExecutionResponse_executionId,+ describeExecutionResponse_lastUpdatedAt,+ describeExecutionResponse_managedDeviceId,+ describeExecutionResponse_startedAt,+ describeExecutionResponse_state,+ describeExecutionResponse_taskId,+ describeExecutionResponse_httpStatus,++ -- ** DescribeTask+ describeTask_taskId,+ describeTaskResponse_completedAt,+ describeTaskResponse_createdAt,+ describeTaskResponse_description,+ describeTaskResponse_lastUpdatedAt,+ describeTaskResponse_state,+ describeTaskResponse_tags,+ describeTaskResponse_targets,+ describeTaskResponse_taskArn,+ describeTaskResponse_taskId,+ describeTaskResponse_httpStatus,++ -- ** ListDeviceResources+ listDeviceResources_maxResults,+ listDeviceResources_nextToken,+ listDeviceResources_type,+ listDeviceResources_managedDeviceId,+ listDeviceResourcesResponse_nextToken,+ listDeviceResourcesResponse_resources,+ listDeviceResourcesResponse_httpStatus,++ -- ** ListDevices+ listDevices_jobId,+ listDevices_maxResults,+ listDevices_nextToken,+ listDevicesResponse_devices,+ listDevicesResponse_nextToken,+ listDevicesResponse_httpStatus,++ -- ** ListExecutions+ listExecutions_maxResults,+ listExecutions_nextToken,+ listExecutions_state,+ listExecutions_taskId,+ listExecutionsResponse_executions,+ listExecutionsResponse_nextToken,+ listExecutionsResponse_httpStatus,++ -- ** ListTagsForResource+ listTagsForResource_resourceArn,+ listTagsForResourceResponse_tags,+ listTagsForResourceResponse_httpStatus,++ -- ** ListTasks+ listTasks_maxResults,+ listTasks_nextToken,+ listTasks_state,+ listTasksResponse_nextToken,+ listTasksResponse_tasks,+ listTasksResponse_httpStatus,++ -- ** TagResource+ tagResource_resourceArn,+ tagResource_tags,++ -- ** UntagResource+ untagResource_resourceArn,+ untagResource_tagKeys,++ -- * Types++ -- ** Capacity+ capacity_available,+ capacity_name,+ capacity_total,+ capacity_unit,+ capacity_used,++ -- ** Command+ command_reboot,+ command_unlock,++ -- ** CpuOptions+ cpuOptions_coreCount,+ cpuOptions_threadsPerCore,++ -- ** DeviceSummary+ deviceSummary_associatedWithJob,+ deviceSummary_managedDeviceArn,+ deviceSummary_managedDeviceId,+ deviceSummary_tags,++ -- ** EbsInstanceBlockDevice+ ebsInstanceBlockDevice_attachTime,+ ebsInstanceBlockDevice_deleteOnTermination,+ ebsInstanceBlockDevice_status,+ ebsInstanceBlockDevice_volumeId,++ -- ** ExecutionSummary+ executionSummary_executionId,+ executionSummary_managedDeviceId,+ executionSummary_state,+ executionSummary_taskId,++ -- ** Instance+ instance_amiLaunchIndex,+ instance_blockDeviceMappings,+ instance_cpuOptions,+ instance_createdAt,+ instance_imageId,+ instance_instanceId,+ instance_instanceType,+ instance_privateIpAddress,+ instance_publicIpAddress,+ instance_rootDeviceName,+ instance_securityGroups,+ instance_state,+ instance_updatedAt,++ -- ** InstanceBlockDeviceMapping+ instanceBlockDeviceMapping_deviceName,+ instanceBlockDeviceMapping_ebs,++ -- ** InstanceState+ instanceState_code,+ instanceState_name,++ -- ** InstanceSummary+ instanceSummary_instance,+ instanceSummary_lastUpdatedAt,++ -- ** PhysicalNetworkInterface+ physicalNetworkInterface_defaultGateway,+ physicalNetworkInterface_ipAddress,+ physicalNetworkInterface_ipAddressAssignment,+ physicalNetworkInterface_macAddress,+ physicalNetworkInterface_netmask,+ physicalNetworkInterface_physicalConnectorType,+ physicalNetworkInterface_physicalNetworkInterfaceId,++ -- ** Reboot++ -- ** ResourceSummary+ resourceSummary_arn,+ resourceSummary_id,+ resourceSummary_resourceType,++ -- ** SecurityGroupIdentifier+ securityGroupIdentifier_groupId,+ securityGroupIdentifier_groupName,++ -- ** SoftwareInformation+ softwareInformation_installState,+ softwareInformation_installedVersion,+ softwareInformation_installingVersion,++ -- ** TaskSummary+ taskSummary_state,+ taskSummary_tags,+ taskSummary_taskArn,+ taskSummary_taskId,++ -- ** Unlock+ )+where++import Amazonka.SnowDeviceManagement.CancelTask+import Amazonka.SnowDeviceManagement.CreateTask+import Amazonka.SnowDeviceManagement.DescribeDevice+import Amazonka.SnowDeviceManagement.DescribeDeviceEc2Instances+import Amazonka.SnowDeviceManagement.DescribeExecution+import Amazonka.SnowDeviceManagement.DescribeTask+import Amazonka.SnowDeviceManagement.ListDeviceResources+import Amazonka.SnowDeviceManagement.ListDevices+import Amazonka.SnowDeviceManagement.ListExecutions+import Amazonka.SnowDeviceManagement.ListTagsForResource+import Amazonka.SnowDeviceManagement.ListTasks+import Amazonka.SnowDeviceManagement.TagResource+import Amazonka.SnowDeviceManagement.Types.Capacity+import Amazonka.SnowDeviceManagement.Types.Command+import Amazonka.SnowDeviceManagement.Types.CpuOptions+import Amazonka.SnowDeviceManagement.Types.DeviceSummary+import Amazonka.SnowDeviceManagement.Types.EbsInstanceBlockDevice+import Amazonka.SnowDeviceManagement.Types.ExecutionSummary+import Amazonka.SnowDeviceManagement.Types.Instance+import Amazonka.SnowDeviceManagement.Types.InstanceBlockDeviceMapping+import Amazonka.SnowDeviceManagement.Types.InstanceState+import Amazonka.SnowDeviceManagement.Types.InstanceSummary+import Amazonka.SnowDeviceManagement.Types.PhysicalNetworkInterface+import Amazonka.SnowDeviceManagement.Types.Reboot+import Amazonka.SnowDeviceManagement.Types.ResourceSummary+import Amazonka.SnowDeviceManagement.Types.SecurityGroupIdentifier+import Amazonka.SnowDeviceManagement.Types.SoftwareInformation+import Amazonka.SnowDeviceManagement.Types.TaskSummary+import Amazonka.SnowDeviceManagement.Types.Unlock+import Amazonka.SnowDeviceManagement.UntagResource
+ gen/Amazonka/SnowDeviceManagement/ListDeviceResources.hs view
@@ -0,0 +1,248 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-binds #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.ListDeviceResources+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Returns a list of the Amazon Web Services resources available for a+-- device. Currently, Amazon EC2 instances are the only supported resource+-- type.+--+-- This operation returns paginated results.+module Amazonka.SnowDeviceManagement.ListDeviceResources+ ( -- * Creating a Request+ ListDeviceResources (..),+ newListDeviceResources,++ -- * Request Lenses+ listDeviceResources_maxResults,+ listDeviceResources_nextToken,+ listDeviceResources_type,+ listDeviceResources_managedDeviceId,++ -- * Destructuring the Response+ ListDeviceResourcesResponse (..),+ newListDeviceResourcesResponse,++ -- * Response Lenses+ listDeviceResourcesResponse_nextToken,+ listDeviceResourcesResponse_resources,+ listDeviceResourcesResponse_httpStatus,+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import qualified Amazonka.Request as Request+import qualified Amazonka.Response as Response+import Amazonka.SnowDeviceManagement.Types++-- | /See:/ 'newListDeviceResources' smart constructor.+data ListDeviceResources = ListDeviceResources'+ { -- | The maximum number of resources per page.+ maxResults :: Prelude.Maybe Prelude.Natural,+ -- | A pagination token to continue to the next page of results.+ nextToken :: Prelude.Maybe Prelude.Text,+ -- | A structure used to filter the results by type of resource.+ type' :: Prelude.Maybe Prelude.Text,+ -- | The ID of the managed device that you are listing the resources of.+ managedDeviceId :: Prelude.Text+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'ListDeviceResources' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'maxResults', 'listDeviceResources_maxResults' - The maximum number of resources per page.+--+-- 'nextToken', 'listDeviceResources_nextToken' - A pagination token to continue to the next page of results.+--+-- 'type'', 'listDeviceResources_type' - A structure used to filter the results by type of resource.+--+-- 'managedDeviceId', 'listDeviceResources_managedDeviceId' - The ID of the managed device that you are listing the resources of.+newListDeviceResources ::+ -- | 'managedDeviceId'+ Prelude.Text ->+ ListDeviceResources+newListDeviceResources pManagedDeviceId_ =+ ListDeviceResources'+ { maxResults = Prelude.Nothing,+ nextToken = Prelude.Nothing,+ type' = Prelude.Nothing,+ managedDeviceId = pManagedDeviceId_+ }++-- | The maximum number of resources per page.+listDeviceResources_maxResults :: Lens.Lens' ListDeviceResources (Prelude.Maybe Prelude.Natural)+listDeviceResources_maxResults = Lens.lens (\ListDeviceResources' {maxResults} -> maxResults) (\s@ListDeviceResources' {} a -> s {maxResults = a} :: ListDeviceResources)++-- | A pagination token to continue to the next page of results.+listDeviceResources_nextToken :: Lens.Lens' ListDeviceResources (Prelude.Maybe Prelude.Text)+listDeviceResources_nextToken = Lens.lens (\ListDeviceResources' {nextToken} -> nextToken) (\s@ListDeviceResources' {} a -> s {nextToken = a} :: ListDeviceResources)++-- | A structure used to filter the results by type of resource.+listDeviceResources_type :: Lens.Lens' ListDeviceResources (Prelude.Maybe Prelude.Text)+listDeviceResources_type = Lens.lens (\ListDeviceResources' {type'} -> type') (\s@ListDeviceResources' {} a -> s {type' = a} :: ListDeviceResources)++-- | The ID of the managed device that you are listing the resources of.+listDeviceResources_managedDeviceId :: Lens.Lens' ListDeviceResources Prelude.Text+listDeviceResources_managedDeviceId = Lens.lens (\ListDeviceResources' {managedDeviceId} -> managedDeviceId) (\s@ListDeviceResources' {} a -> s {managedDeviceId = a} :: ListDeviceResources)++instance Core.AWSPager ListDeviceResources where+ page rq rs+ | Core.stop+ ( rs+ Lens.^? listDeviceResourcesResponse_nextToken+ Prelude.. Lens._Just+ ) =+ Prelude.Nothing+ | Core.stop+ ( rs+ Lens.^? listDeviceResourcesResponse_resources+ Prelude.. Lens._Just+ ) =+ Prelude.Nothing+ | Prelude.otherwise =+ Prelude.Just+ Prelude.$ rq+ Prelude.& listDeviceResources_nextToken+ Lens..~ rs+ Lens.^? listDeviceResourcesResponse_nextToken+ Prelude.. Lens._Just++instance Core.AWSRequest ListDeviceResources where+ type+ AWSResponse ListDeviceResources =+ ListDeviceResourcesResponse+ request overrides =+ Request.get (overrides defaultService)+ response =+ Response.receiveJSON+ ( \s h x ->+ ListDeviceResourcesResponse'+ Prelude.<$> (x Data..?> "nextToken")+ Prelude.<*> (x Data..?> "resources" Core..!@ Prelude.mempty)+ Prelude.<*> (Prelude.pure (Prelude.fromEnum s))+ )++instance Prelude.Hashable ListDeviceResources where+ hashWithSalt _salt ListDeviceResources' {..} =+ _salt+ `Prelude.hashWithSalt` maxResults+ `Prelude.hashWithSalt` nextToken+ `Prelude.hashWithSalt` type'+ `Prelude.hashWithSalt` managedDeviceId++instance Prelude.NFData ListDeviceResources where+ rnf ListDeviceResources' {..} =+ Prelude.rnf maxResults+ `Prelude.seq` Prelude.rnf nextToken+ `Prelude.seq` Prelude.rnf type'+ `Prelude.seq` Prelude.rnf managedDeviceId++instance Data.ToHeaders ListDeviceResources where+ toHeaders =+ Prelude.const+ ( Prelude.mconcat+ [ "Content-Type"+ Data.=# ( "application/x-amz-json-1.1" ::+ Prelude.ByteString+ )+ ]+ )++instance Data.ToPath ListDeviceResources where+ toPath ListDeviceResources' {..} =+ Prelude.mconcat+ [ "/managed-device/",+ Data.toBS managedDeviceId,+ "/resources"+ ]++instance Data.ToQuery ListDeviceResources where+ toQuery ListDeviceResources' {..} =+ Prelude.mconcat+ [ "maxResults" Data.=: maxResults,+ "nextToken" Data.=: nextToken,+ "type" Data.=: type'+ ]++-- | /See:/ 'newListDeviceResourcesResponse' smart constructor.+data ListDeviceResourcesResponse = ListDeviceResourcesResponse'+ { -- | A pagination token to continue to the next page of results.+ nextToken :: Prelude.Maybe Prelude.Text,+ -- | A structure defining the resource\'s type, Amazon Resource Name (ARN),+ -- and ID.+ resources :: Prelude.Maybe [ResourceSummary],+ -- | The response's http status code.+ httpStatus :: Prelude.Int+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'ListDeviceResourcesResponse' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'nextToken', 'listDeviceResourcesResponse_nextToken' - A pagination token to continue to the next page of results.+--+-- 'resources', 'listDeviceResourcesResponse_resources' - A structure defining the resource\'s type, Amazon Resource Name (ARN),+-- and ID.+--+-- 'httpStatus', 'listDeviceResourcesResponse_httpStatus' - The response's http status code.+newListDeviceResourcesResponse ::+ -- | 'httpStatus'+ Prelude.Int ->+ ListDeviceResourcesResponse+newListDeviceResourcesResponse pHttpStatus_ =+ ListDeviceResourcesResponse'+ { nextToken =+ Prelude.Nothing,+ resources = Prelude.Nothing,+ httpStatus = pHttpStatus_+ }++-- | A pagination token to continue to the next page of results.+listDeviceResourcesResponse_nextToken :: Lens.Lens' ListDeviceResourcesResponse (Prelude.Maybe Prelude.Text)+listDeviceResourcesResponse_nextToken = Lens.lens (\ListDeviceResourcesResponse' {nextToken} -> nextToken) (\s@ListDeviceResourcesResponse' {} a -> s {nextToken = a} :: ListDeviceResourcesResponse)++-- | A structure defining the resource\'s type, Amazon Resource Name (ARN),+-- and ID.+listDeviceResourcesResponse_resources :: Lens.Lens' ListDeviceResourcesResponse (Prelude.Maybe [ResourceSummary])+listDeviceResourcesResponse_resources = Lens.lens (\ListDeviceResourcesResponse' {resources} -> resources) (\s@ListDeviceResourcesResponse' {} a -> s {resources = a} :: ListDeviceResourcesResponse) Prelude.. Lens.mapping Lens.coerced++-- | The response's http status code.+listDeviceResourcesResponse_httpStatus :: Lens.Lens' ListDeviceResourcesResponse Prelude.Int+listDeviceResourcesResponse_httpStatus = Lens.lens (\ListDeviceResourcesResponse' {httpStatus} -> httpStatus) (\s@ListDeviceResourcesResponse' {} a -> s {httpStatus = a} :: ListDeviceResourcesResponse)++instance Prelude.NFData ListDeviceResourcesResponse where+ rnf ListDeviceResourcesResponse' {..} =+ Prelude.rnf nextToken+ `Prelude.seq` Prelude.rnf resources+ `Prelude.seq` Prelude.rnf httpStatus
+ gen/Amazonka/SnowDeviceManagement/ListDevices.hs view
@@ -0,0 +1,223 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-binds #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.ListDevices+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Returns a list of all devices on your Amazon Web Services account that+-- have Amazon Web Services Snow Device Management enabled in the Amazon+-- Web Services Region where the command is run.+--+-- This operation returns paginated results.+module Amazonka.SnowDeviceManagement.ListDevices+ ( -- * Creating a Request+ ListDevices (..),+ newListDevices,++ -- * Request Lenses+ listDevices_jobId,+ listDevices_maxResults,+ listDevices_nextToken,++ -- * Destructuring the Response+ ListDevicesResponse (..),+ newListDevicesResponse,++ -- * Response Lenses+ listDevicesResponse_devices,+ listDevicesResponse_nextToken,+ listDevicesResponse_httpStatus,+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import qualified Amazonka.Request as Request+import qualified Amazonka.Response as Response+import Amazonka.SnowDeviceManagement.Types++-- | /See:/ 'newListDevices' smart constructor.+data ListDevices = ListDevices'+ { -- | The ID of the job used to order the device.+ jobId :: Prelude.Maybe Prelude.Text,+ -- | The maximum number of devices to list per page.+ maxResults :: Prelude.Maybe Prelude.Natural,+ -- | A pagination token to continue to the next page of results.+ nextToken :: Prelude.Maybe Prelude.Text+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'ListDevices' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'jobId', 'listDevices_jobId' - The ID of the job used to order the device.+--+-- 'maxResults', 'listDevices_maxResults' - The maximum number of devices to list per page.+--+-- 'nextToken', 'listDevices_nextToken' - A pagination token to continue to the next page of results.+newListDevices ::+ ListDevices+newListDevices =+ ListDevices'+ { jobId = Prelude.Nothing,+ maxResults = Prelude.Nothing,+ nextToken = Prelude.Nothing+ }++-- | The ID of the job used to order the device.+listDevices_jobId :: Lens.Lens' ListDevices (Prelude.Maybe Prelude.Text)+listDevices_jobId = Lens.lens (\ListDevices' {jobId} -> jobId) (\s@ListDevices' {} a -> s {jobId = a} :: ListDevices)++-- | The maximum number of devices to list per page.+listDevices_maxResults :: Lens.Lens' ListDevices (Prelude.Maybe Prelude.Natural)+listDevices_maxResults = Lens.lens (\ListDevices' {maxResults} -> maxResults) (\s@ListDevices' {} a -> s {maxResults = a} :: ListDevices)++-- | A pagination token to continue to the next page of results.+listDevices_nextToken :: Lens.Lens' ListDevices (Prelude.Maybe Prelude.Text)+listDevices_nextToken = Lens.lens (\ListDevices' {nextToken} -> nextToken) (\s@ListDevices' {} a -> s {nextToken = a} :: ListDevices)++instance Core.AWSPager ListDevices where+ page rq rs+ | Core.stop+ ( rs+ Lens.^? listDevicesResponse_nextToken+ Prelude.. Lens._Just+ ) =+ Prelude.Nothing+ | Core.stop+ ( rs+ Lens.^? listDevicesResponse_devices+ Prelude.. Lens._Just+ ) =+ Prelude.Nothing+ | Prelude.otherwise =+ Prelude.Just+ Prelude.$ rq+ Prelude.& listDevices_nextToken+ Lens..~ rs+ Lens.^? listDevicesResponse_nextToken+ Prelude.. Lens._Just++instance Core.AWSRequest ListDevices where+ type AWSResponse ListDevices = ListDevicesResponse+ request overrides =+ Request.get (overrides defaultService)+ response =+ Response.receiveJSON+ ( \s h x ->+ ListDevicesResponse'+ Prelude.<$> (x Data..?> "devices" Core..!@ Prelude.mempty)+ Prelude.<*> (x Data..?> "nextToken")+ Prelude.<*> (Prelude.pure (Prelude.fromEnum s))+ )++instance Prelude.Hashable ListDevices where+ hashWithSalt _salt ListDevices' {..} =+ _salt+ `Prelude.hashWithSalt` jobId+ `Prelude.hashWithSalt` maxResults+ `Prelude.hashWithSalt` nextToken++instance Prelude.NFData ListDevices where+ rnf ListDevices' {..} =+ Prelude.rnf jobId+ `Prelude.seq` Prelude.rnf maxResults+ `Prelude.seq` Prelude.rnf nextToken++instance Data.ToHeaders ListDevices where+ toHeaders =+ Prelude.const+ ( Prelude.mconcat+ [ "Content-Type"+ Data.=# ( "application/x-amz-json-1.1" ::+ Prelude.ByteString+ )+ ]+ )++instance Data.ToPath ListDevices where+ toPath = Prelude.const "/managed-devices"++instance Data.ToQuery ListDevices where+ toQuery ListDevices' {..} =+ Prelude.mconcat+ [ "jobId" Data.=: jobId,+ "maxResults" Data.=: maxResults,+ "nextToken" Data.=: nextToken+ ]++-- | /See:/ 'newListDevicesResponse' smart constructor.+data ListDevicesResponse = ListDevicesResponse'+ { -- | A list of device structures that contain information about the device.+ devices :: Prelude.Maybe [DeviceSummary],+ -- | A pagination token to continue to the next page of devices.+ nextToken :: Prelude.Maybe Prelude.Text,+ -- | The response's http status code.+ httpStatus :: Prelude.Int+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'ListDevicesResponse' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'devices', 'listDevicesResponse_devices' - A list of device structures that contain information about the device.+--+-- 'nextToken', 'listDevicesResponse_nextToken' - A pagination token to continue to the next page of devices.+--+-- 'httpStatus', 'listDevicesResponse_httpStatus' - The response's http status code.+newListDevicesResponse ::+ -- | 'httpStatus'+ Prelude.Int ->+ ListDevicesResponse+newListDevicesResponse pHttpStatus_ =+ ListDevicesResponse'+ { devices = Prelude.Nothing,+ nextToken = Prelude.Nothing,+ httpStatus = pHttpStatus_+ }++-- | A list of device structures that contain information about the device.+listDevicesResponse_devices :: Lens.Lens' ListDevicesResponse (Prelude.Maybe [DeviceSummary])+listDevicesResponse_devices = Lens.lens (\ListDevicesResponse' {devices} -> devices) (\s@ListDevicesResponse' {} a -> s {devices = a} :: ListDevicesResponse) Prelude.. Lens.mapping Lens.coerced++-- | A pagination token to continue to the next page of devices.+listDevicesResponse_nextToken :: Lens.Lens' ListDevicesResponse (Prelude.Maybe Prelude.Text)+listDevicesResponse_nextToken = Lens.lens (\ListDevicesResponse' {nextToken} -> nextToken) (\s@ListDevicesResponse' {} a -> s {nextToken = a} :: ListDevicesResponse)++-- | The response's http status code.+listDevicesResponse_httpStatus :: Lens.Lens' ListDevicesResponse Prelude.Int+listDevicesResponse_httpStatus = Lens.lens (\ListDevicesResponse' {httpStatus} -> httpStatus) (\s@ListDevicesResponse' {} a -> s {httpStatus = a} :: ListDevicesResponse)++instance Prelude.NFData ListDevicesResponse where+ rnf ListDevicesResponse' {..} =+ Prelude.rnf devices+ `Prelude.seq` Prelude.rnf nextToken+ `Prelude.seq` Prelude.rnf httpStatus
+ gen/Amazonka/SnowDeviceManagement/ListExecutions.hs view
@@ -0,0 +1,245 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-binds #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.ListExecutions+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Returns the status of tasks for one or more target devices.+--+-- This operation returns paginated results.+module Amazonka.SnowDeviceManagement.ListExecutions+ ( -- * Creating a Request+ ListExecutions (..),+ newListExecutions,++ -- * Request Lenses+ listExecutions_maxResults,+ listExecutions_nextToken,+ listExecutions_state,+ listExecutions_taskId,++ -- * Destructuring the Response+ ListExecutionsResponse (..),+ newListExecutionsResponse,++ -- * Response Lenses+ listExecutionsResponse_executions,+ listExecutionsResponse_nextToken,+ listExecutionsResponse_httpStatus,+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import qualified Amazonka.Request as Request+import qualified Amazonka.Response as Response+import Amazonka.SnowDeviceManagement.Types++-- | /See:/ 'newListExecutions' smart constructor.+data ListExecutions = ListExecutions'+ { -- | The maximum number of tasks to list per page.+ maxResults :: Prelude.Maybe Prelude.Natural,+ -- | A pagination token to continue to the next page of tasks.+ nextToken :: Prelude.Maybe Prelude.Text,+ -- | A structure used to filter the tasks by their current state.+ state :: Prelude.Maybe ExecutionState,+ -- | The ID of the task.+ taskId :: Prelude.Text+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'ListExecutions' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'maxResults', 'listExecutions_maxResults' - The maximum number of tasks to list per page.+--+-- 'nextToken', 'listExecutions_nextToken' - A pagination token to continue to the next page of tasks.+--+-- 'state', 'listExecutions_state' - A structure used to filter the tasks by their current state.+--+-- 'taskId', 'listExecutions_taskId' - The ID of the task.+newListExecutions ::+ -- | 'taskId'+ Prelude.Text ->+ ListExecutions+newListExecutions pTaskId_ =+ ListExecutions'+ { maxResults = Prelude.Nothing,+ nextToken = Prelude.Nothing,+ state = Prelude.Nothing,+ taskId = pTaskId_+ }++-- | The maximum number of tasks to list per page.+listExecutions_maxResults :: Lens.Lens' ListExecutions (Prelude.Maybe Prelude.Natural)+listExecutions_maxResults = Lens.lens (\ListExecutions' {maxResults} -> maxResults) (\s@ListExecutions' {} a -> s {maxResults = a} :: ListExecutions)++-- | A pagination token to continue to the next page of tasks.+listExecutions_nextToken :: Lens.Lens' ListExecutions (Prelude.Maybe Prelude.Text)+listExecutions_nextToken = Lens.lens (\ListExecutions' {nextToken} -> nextToken) (\s@ListExecutions' {} a -> s {nextToken = a} :: ListExecutions)++-- | A structure used to filter the tasks by their current state.+listExecutions_state :: Lens.Lens' ListExecutions (Prelude.Maybe ExecutionState)+listExecutions_state = Lens.lens (\ListExecutions' {state} -> state) (\s@ListExecutions' {} a -> s {state = a} :: ListExecutions)++-- | The ID of the task.+listExecutions_taskId :: Lens.Lens' ListExecutions Prelude.Text+listExecutions_taskId = Lens.lens (\ListExecutions' {taskId} -> taskId) (\s@ListExecutions' {} a -> s {taskId = a} :: ListExecutions)++instance Core.AWSPager ListExecutions where+ page rq rs+ | Core.stop+ ( rs+ Lens.^? listExecutionsResponse_nextToken+ Prelude.. Lens._Just+ ) =+ Prelude.Nothing+ | Core.stop+ ( rs+ Lens.^? listExecutionsResponse_executions+ Prelude.. Lens._Just+ ) =+ Prelude.Nothing+ | Prelude.otherwise =+ Prelude.Just+ Prelude.$ rq+ Prelude.& listExecutions_nextToken+ Lens..~ rs+ Lens.^? listExecutionsResponse_nextToken+ Prelude.. Lens._Just++instance Core.AWSRequest ListExecutions where+ type+ AWSResponse ListExecutions =+ ListExecutionsResponse+ request overrides =+ Request.get (overrides defaultService)+ response =+ Response.receiveJSON+ ( \s h x ->+ ListExecutionsResponse'+ Prelude.<$> (x Data..?> "executions" Core..!@ Prelude.mempty)+ Prelude.<*> (x Data..?> "nextToken")+ Prelude.<*> (Prelude.pure (Prelude.fromEnum s))+ )++instance Prelude.Hashable ListExecutions where+ hashWithSalt _salt ListExecutions' {..} =+ _salt+ `Prelude.hashWithSalt` maxResults+ `Prelude.hashWithSalt` nextToken+ `Prelude.hashWithSalt` state+ `Prelude.hashWithSalt` taskId++instance Prelude.NFData ListExecutions where+ rnf ListExecutions' {..} =+ Prelude.rnf maxResults+ `Prelude.seq` Prelude.rnf nextToken+ `Prelude.seq` Prelude.rnf state+ `Prelude.seq` Prelude.rnf taskId++instance Data.ToHeaders ListExecutions where+ toHeaders =+ Prelude.const+ ( Prelude.mconcat+ [ "Content-Type"+ Data.=# ( "application/x-amz-json-1.1" ::+ Prelude.ByteString+ )+ ]+ )++instance Data.ToPath ListExecutions where+ toPath = Prelude.const "/executions"++instance Data.ToQuery ListExecutions where+ toQuery ListExecutions' {..} =+ Prelude.mconcat+ [ "maxResults" Data.=: maxResults,+ "nextToken" Data.=: nextToken,+ "state" Data.=: state,+ "taskId" Data.=: taskId+ ]++-- | /See:/ 'newListExecutionsResponse' smart constructor.+data ListExecutionsResponse = ListExecutionsResponse'+ { -- | A list of executions. Each execution contains the task ID, the device+ -- that the task is executing on, the execution ID, and the status of the+ -- execution.+ executions :: Prelude.Maybe [ExecutionSummary],+ -- | A pagination token to continue to the next page of executions.+ nextToken :: Prelude.Maybe Prelude.Text,+ -- | The response's http status code.+ httpStatus :: Prelude.Int+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'ListExecutionsResponse' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'executions', 'listExecutionsResponse_executions' - A list of executions. Each execution contains the task ID, the device+-- that the task is executing on, the execution ID, and the status of the+-- execution.+--+-- 'nextToken', 'listExecutionsResponse_nextToken' - A pagination token to continue to the next page of executions.+--+-- 'httpStatus', 'listExecutionsResponse_httpStatus' - The response's http status code.+newListExecutionsResponse ::+ -- | 'httpStatus'+ Prelude.Int ->+ ListExecutionsResponse+newListExecutionsResponse pHttpStatus_ =+ ListExecutionsResponse'+ { executions =+ Prelude.Nothing,+ nextToken = Prelude.Nothing,+ httpStatus = pHttpStatus_+ }++-- | A list of executions. Each execution contains the task ID, the device+-- that the task is executing on, the execution ID, and the status of the+-- execution.+listExecutionsResponse_executions :: Lens.Lens' ListExecutionsResponse (Prelude.Maybe [ExecutionSummary])+listExecutionsResponse_executions = Lens.lens (\ListExecutionsResponse' {executions} -> executions) (\s@ListExecutionsResponse' {} a -> s {executions = a} :: ListExecutionsResponse) Prelude.. Lens.mapping Lens.coerced++-- | A pagination token to continue to the next page of executions.+listExecutionsResponse_nextToken :: Lens.Lens' ListExecutionsResponse (Prelude.Maybe Prelude.Text)+listExecutionsResponse_nextToken = Lens.lens (\ListExecutionsResponse' {nextToken} -> nextToken) (\s@ListExecutionsResponse' {} a -> s {nextToken = a} :: ListExecutionsResponse)++-- | The response's http status code.+listExecutionsResponse_httpStatus :: Lens.Lens' ListExecutionsResponse Prelude.Int+listExecutionsResponse_httpStatus = Lens.lens (\ListExecutionsResponse' {httpStatus} -> httpStatus) (\s@ListExecutionsResponse' {} a -> s {httpStatus = a} :: ListExecutionsResponse)++instance Prelude.NFData ListExecutionsResponse where+ rnf ListExecutionsResponse' {..} =+ Prelude.rnf executions+ `Prelude.seq` Prelude.rnf nextToken+ `Prelude.seq` Prelude.rnf httpStatus
+ gen/Amazonka/SnowDeviceManagement/ListTagsForResource.hs view
@@ -0,0 +1,159 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-binds #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.ListTagsForResource+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Returns a list of tags for a managed device or task.+module Amazonka.SnowDeviceManagement.ListTagsForResource+ ( -- * Creating a Request+ ListTagsForResource (..),+ newListTagsForResource,++ -- * Request Lenses+ listTagsForResource_resourceArn,++ -- * Destructuring the Response+ ListTagsForResourceResponse (..),+ newListTagsForResourceResponse,++ -- * Response Lenses+ listTagsForResourceResponse_tags,+ listTagsForResourceResponse_httpStatus,+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import qualified Amazonka.Request as Request+import qualified Amazonka.Response as Response+import Amazonka.SnowDeviceManagement.Types++-- | /See:/ 'newListTagsForResource' smart constructor.+data ListTagsForResource = ListTagsForResource'+ { -- | The Amazon Resource Name (ARN) of the device or task.+ resourceArn :: Prelude.Text+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'ListTagsForResource' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'resourceArn', 'listTagsForResource_resourceArn' - The Amazon Resource Name (ARN) of the device or task.+newListTagsForResource ::+ -- | 'resourceArn'+ Prelude.Text ->+ ListTagsForResource+newListTagsForResource pResourceArn_ =+ ListTagsForResource' {resourceArn = pResourceArn_}++-- | The Amazon Resource Name (ARN) of the device or task.+listTagsForResource_resourceArn :: Lens.Lens' ListTagsForResource Prelude.Text+listTagsForResource_resourceArn = Lens.lens (\ListTagsForResource' {resourceArn} -> resourceArn) (\s@ListTagsForResource' {} a -> s {resourceArn = a} :: ListTagsForResource)++instance Core.AWSRequest ListTagsForResource where+ type+ AWSResponse ListTagsForResource =+ ListTagsForResourceResponse+ request overrides =+ Request.get (overrides defaultService)+ response =+ Response.receiveJSON+ ( \s h x ->+ ListTagsForResourceResponse'+ Prelude.<$> (x Data..?> "tags" Core..!@ Prelude.mempty)+ Prelude.<*> (Prelude.pure (Prelude.fromEnum s))+ )++instance Prelude.Hashable ListTagsForResource where+ hashWithSalt _salt ListTagsForResource' {..} =+ _salt `Prelude.hashWithSalt` resourceArn++instance Prelude.NFData ListTagsForResource where+ rnf ListTagsForResource' {..} =+ Prelude.rnf resourceArn++instance Data.ToHeaders ListTagsForResource where+ toHeaders =+ Prelude.const+ ( Prelude.mconcat+ [ "Content-Type"+ Data.=# ( "application/x-amz-json-1.1" ::+ Prelude.ByteString+ )+ ]+ )++instance Data.ToPath ListTagsForResource where+ toPath ListTagsForResource' {..} =+ Prelude.mconcat ["/tags/", Data.toBS resourceArn]++instance Data.ToQuery ListTagsForResource where+ toQuery = Prelude.const Prelude.mempty++-- | /See:/ 'newListTagsForResourceResponse' smart constructor.+data ListTagsForResourceResponse = ListTagsForResourceResponse'+ { -- | The list of tags for the device or task.+ tags :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),+ -- | The response's http status code.+ httpStatus :: Prelude.Int+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'ListTagsForResourceResponse' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'tags', 'listTagsForResourceResponse_tags' - The list of tags for the device or task.+--+-- 'httpStatus', 'listTagsForResourceResponse_httpStatus' - The response's http status code.+newListTagsForResourceResponse ::+ -- | 'httpStatus'+ Prelude.Int ->+ ListTagsForResourceResponse+newListTagsForResourceResponse pHttpStatus_ =+ ListTagsForResourceResponse'+ { tags =+ Prelude.Nothing,+ httpStatus = pHttpStatus_+ }++-- | The list of tags for the device or task.+listTagsForResourceResponse_tags :: Lens.Lens' ListTagsForResourceResponse (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))+listTagsForResourceResponse_tags = Lens.lens (\ListTagsForResourceResponse' {tags} -> tags) (\s@ListTagsForResourceResponse' {} a -> s {tags = a} :: ListTagsForResourceResponse) Prelude.. Lens.mapping Lens.coerced++-- | The response's http status code.+listTagsForResourceResponse_httpStatus :: Lens.Lens' ListTagsForResourceResponse Prelude.Int+listTagsForResourceResponse_httpStatus = Lens.lens (\ListTagsForResourceResponse' {httpStatus} -> httpStatus) (\s@ListTagsForResourceResponse' {} a -> s {httpStatus = a} :: ListTagsForResourceResponse)++instance Prelude.NFData ListTagsForResourceResponse where+ rnf ListTagsForResourceResponse' {..} =+ Prelude.rnf tags+ `Prelude.seq` Prelude.rnf httpStatus
+ gen/Amazonka/SnowDeviceManagement/ListTasks.hs view
@@ -0,0 +1,221 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-binds #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.ListTasks+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Returns a list of tasks that can be filtered by state.+--+-- This operation returns paginated results.+module Amazonka.SnowDeviceManagement.ListTasks+ ( -- * Creating a Request+ ListTasks (..),+ newListTasks,++ -- * Request Lenses+ listTasks_maxResults,+ listTasks_nextToken,+ listTasks_state,++ -- * Destructuring the Response+ ListTasksResponse (..),+ newListTasksResponse,++ -- * Response Lenses+ listTasksResponse_nextToken,+ listTasksResponse_tasks,+ listTasksResponse_httpStatus,+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import qualified Amazonka.Request as Request+import qualified Amazonka.Response as Response+import Amazonka.SnowDeviceManagement.Types++-- | /See:/ 'newListTasks' smart constructor.+data ListTasks = ListTasks'+ { -- | The maximum number of tasks per page.+ maxResults :: Prelude.Maybe Prelude.Natural,+ -- | A pagination token to continue to the next page of tasks.+ nextToken :: Prelude.Maybe Prelude.Text,+ -- | A structure used to filter the list of tasks.+ state :: Prelude.Maybe TaskState+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'ListTasks' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'maxResults', 'listTasks_maxResults' - The maximum number of tasks per page.+--+-- 'nextToken', 'listTasks_nextToken' - A pagination token to continue to the next page of tasks.+--+-- 'state', 'listTasks_state' - A structure used to filter the list of tasks.+newListTasks ::+ ListTasks+newListTasks =+ ListTasks'+ { maxResults = Prelude.Nothing,+ nextToken = Prelude.Nothing,+ state = Prelude.Nothing+ }++-- | The maximum number of tasks per page.+listTasks_maxResults :: Lens.Lens' ListTasks (Prelude.Maybe Prelude.Natural)+listTasks_maxResults = Lens.lens (\ListTasks' {maxResults} -> maxResults) (\s@ListTasks' {} a -> s {maxResults = a} :: ListTasks)++-- | A pagination token to continue to the next page of tasks.+listTasks_nextToken :: Lens.Lens' ListTasks (Prelude.Maybe Prelude.Text)+listTasks_nextToken = Lens.lens (\ListTasks' {nextToken} -> nextToken) (\s@ListTasks' {} a -> s {nextToken = a} :: ListTasks)++-- | A structure used to filter the list of tasks.+listTasks_state :: Lens.Lens' ListTasks (Prelude.Maybe TaskState)+listTasks_state = Lens.lens (\ListTasks' {state} -> state) (\s@ListTasks' {} a -> s {state = a} :: ListTasks)++instance Core.AWSPager ListTasks where+ page rq rs+ | Core.stop+ ( rs+ Lens.^? listTasksResponse_nextToken+ Prelude.. Lens._Just+ ) =+ Prelude.Nothing+ | Core.stop+ ( rs+ Lens.^? listTasksResponse_tasks+ Prelude.. Lens._Just+ ) =+ Prelude.Nothing+ | Prelude.otherwise =+ Prelude.Just+ Prelude.$ rq+ Prelude.& listTasks_nextToken+ Lens..~ rs+ Lens.^? listTasksResponse_nextToken+ Prelude.. Lens._Just++instance Core.AWSRequest ListTasks where+ type AWSResponse ListTasks = ListTasksResponse+ request overrides =+ Request.get (overrides defaultService)+ response =+ Response.receiveJSON+ ( \s h x ->+ ListTasksResponse'+ Prelude.<$> (x Data..?> "nextToken")+ Prelude.<*> (x Data..?> "tasks" Core..!@ Prelude.mempty)+ Prelude.<*> (Prelude.pure (Prelude.fromEnum s))+ )++instance Prelude.Hashable ListTasks where+ hashWithSalt _salt ListTasks' {..} =+ _salt+ `Prelude.hashWithSalt` maxResults+ `Prelude.hashWithSalt` nextToken+ `Prelude.hashWithSalt` state++instance Prelude.NFData ListTasks where+ rnf ListTasks' {..} =+ Prelude.rnf maxResults+ `Prelude.seq` Prelude.rnf nextToken+ `Prelude.seq` Prelude.rnf state++instance Data.ToHeaders ListTasks where+ toHeaders =+ Prelude.const+ ( Prelude.mconcat+ [ "Content-Type"+ Data.=# ( "application/x-amz-json-1.1" ::+ Prelude.ByteString+ )+ ]+ )++instance Data.ToPath ListTasks where+ toPath = Prelude.const "/tasks"++instance Data.ToQuery ListTasks where+ toQuery ListTasks' {..} =+ Prelude.mconcat+ [ "maxResults" Data.=: maxResults,+ "nextToken" Data.=: nextToken,+ "state" Data.=: state+ ]++-- | /See:/ 'newListTasksResponse' smart constructor.+data ListTasksResponse = ListTasksResponse'+ { -- | A pagination token to continue to the next page of tasks.+ nextToken :: Prelude.Maybe Prelude.Text,+ -- | A list of task structures containing details about each task.+ tasks :: Prelude.Maybe [TaskSummary],+ -- | The response's http status code.+ httpStatus :: Prelude.Int+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'ListTasksResponse' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'nextToken', 'listTasksResponse_nextToken' - A pagination token to continue to the next page of tasks.+--+-- 'tasks', 'listTasksResponse_tasks' - A list of task structures containing details about each task.+--+-- 'httpStatus', 'listTasksResponse_httpStatus' - The response's http status code.+newListTasksResponse ::+ -- | 'httpStatus'+ Prelude.Int ->+ ListTasksResponse+newListTasksResponse pHttpStatus_ =+ ListTasksResponse'+ { nextToken = Prelude.Nothing,+ tasks = Prelude.Nothing,+ httpStatus = pHttpStatus_+ }++-- | A pagination token to continue to the next page of tasks.+listTasksResponse_nextToken :: Lens.Lens' ListTasksResponse (Prelude.Maybe Prelude.Text)+listTasksResponse_nextToken = Lens.lens (\ListTasksResponse' {nextToken} -> nextToken) (\s@ListTasksResponse' {} a -> s {nextToken = a} :: ListTasksResponse)++-- | A list of task structures containing details about each task.+listTasksResponse_tasks :: Lens.Lens' ListTasksResponse (Prelude.Maybe [TaskSummary])+listTasksResponse_tasks = Lens.lens (\ListTasksResponse' {tasks} -> tasks) (\s@ListTasksResponse' {} a -> s {tasks = a} :: ListTasksResponse) Prelude.. Lens.mapping Lens.coerced++-- | The response's http status code.+listTasksResponse_httpStatus :: Lens.Lens' ListTasksResponse Prelude.Int+listTasksResponse_httpStatus = Lens.lens (\ListTasksResponse' {httpStatus} -> httpStatus) (\s@ListTasksResponse' {} a -> s {httpStatus = a} :: ListTasksResponse)++instance Prelude.NFData ListTasksResponse where+ rnf ListTasksResponse' {..} =+ Prelude.rnf nextToken+ `Prelude.seq` Prelude.rnf tasks+ `Prelude.seq` Prelude.rnf httpStatus
+ gen/Amazonka/SnowDeviceManagement/TagResource.hs view
@@ -0,0 +1,148 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-binds #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.TagResource+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Adds or replaces tags on a device or task.+module Amazonka.SnowDeviceManagement.TagResource+ ( -- * Creating a Request+ TagResource (..),+ newTagResource,++ -- * Request Lenses+ tagResource_resourceArn,+ tagResource_tags,++ -- * Destructuring the Response+ TagResourceResponse (..),+ newTagResourceResponse,+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import qualified Amazonka.Request as Request+import qualified Amazonka.Response as Response+import Amazonka.SnowDeviceManagement.Types++-- | /See:/ 'newTagResource' smart constructor.+data TagResource = TagResource'+ { -- | The Amazon Resource Name (ARN) of the device or task.+ resourceArn :: Prelude.Text,+ -- | Optional metadata that you assign to a resource. You can use tags to+ -- categorize a resource in different ways, such as by purpose, owner, or+ -- environment.+ tags :: Prelude.HashMap Prelude.Text Prelude.Text+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'TagResource' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'resourceArn', 'tagResource_resourceArn' - The Amazon Resource Name (ARN) of the device or task.+--+-- 'tags', 'tagResource_tags' - Optional metadata that you assign to a resource. You can use tags to+-- categorize a resource in different ways, such as by purpose, owner, or+-- environment.+newTagResource ::+ -- | 'resourceArn'+ Prelude.Text ->+ TagResource+newTagResource pResourceArn_ =+ TagResource'+ { resourceArn = pResourceArn_,+ tags = Prelude.mempty+ }++-- | The Amazon Resource Name (ARN) of the device or task.+tagResource_resourceArn :: Lens.Lens' TagResource Prelude.Text+tagResource_resourceArn = Lens.lens (\TagResource' {resourceArn} -> resourceArn) (\s@TagResource' {} a -> s {resourceArn = a} :: TagResource)++-- | Optional metadata that you assign to a resource. You can use tags to+-- categorize a resource in different ways, such as by purpose, owner, or+-- environment.+tagResource_tags :: Lens.Lens' TagResource (Prelude.HashMap Prelude.Text Prelude.Text)+tagResource_tags = Lens.lens (\TagResource' {tags} -> tags) (\s@TagResource' {} a -> s {tags = a} :: TagResource) Prelude.. Lens.coerced++instance Core.AWSRequest TagResource where+ type AWSResponse TagResource = TagResourceResponse+ request overrides =+ Request.postJSON (overrides defaultService)+ response = Response.receiveNull TagResourceResponse'++instance Prelude.Hashable TagResource where+ hashWithSalt _salt TagResource' {..} =+ _salt+ `Prelude.hashWithSalt` resourceArn+ `Prelude.hashWithSalt` tags++instance Prelude.NFData TagResource where+ rnf TagResource' {..} =+ Prelude.rnf resourceArn+ `Prelude.seq` Prelude.rnf tags++instance Data.ToHeaders TagResource where+ toHeaders =+ Prelude.const+ ( Prelude.mconcat+ [ "Content-Type"+ Data.=# ( "application/x-amz-json-1.1" ::+ Prelude.ByteString+ )+ ]+ )++instance Data.ToJSON TagResource where+ toJSON TagResource' {..} =+ Data.object+ ( Prelude.catMaybes+ [Prelude.Just ("tags" Data..= tags)]+ )++instance Data.ToPath TagResource where+ toPath TagResource' {..} =+ Prelude.mconcat ["/tags/", Data.toBS resourceArn]++instance Data.ToQuery TagResource where+ toQuery = Prelude.const Prelude.mempty++-- | /See:/ 'newTagResourceResponse' smart constructor.+data TagResourceResponse = TagResourceResponse'+ {+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'TagResourceResponse' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+newTagResourceResponse ::+ TagResourceResponse+newTagResourceResponse = TagResourceResponse'++instance Prelude.NFData TagResourceResponse where+ rnf _ = ()
+ gen/Amazonka/SnowDeviceManagement/Types.hs view
@@ -0,0 +1,325 @@+{-# LANGUAGE DisambiguateRecordFields #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types+ ( -- * Service Configuration+ defaultService,++ -- * Errors+ _AccessDeniedException,+ _InternalServerException,+ _ResourceNotFoundException,+ _ServiceQuotaExceededException,+ _ThrottlingException,+ _ValidationException,++ -- * AttachmentStatus+ AttachmentStatus (..),++ -- * ExecutionState+ ExecutionState (..),++ -- * InstanceStateName+ InstanceStateName (..),++ -- * IpAddressAssignment+ IpAddressAssignment (..),++ -- * PhysicalConnectorType+ PhysicalConnectorType (..),++ -- * TaskState+ TaskState (..),++ -- * UnlockState+ UnlockState (..),++ -- * Capacity+ Capacity (..),+ newCapacity,+ capacity_available,+ capacity_name,+ capacity_total,+ capacity_unit,+ capacity_used,++ -- * Command+ Command (..),+ newCommand,+ command_reboot,+ command_unlock,++ -- * CpuOptions+ CpuOptions (..),+ newCpuOptions,+ cpuOptions_coreCount,+ cpuOptions_threadsPerCore,++ -- * DeviceSummary+ DeviceSummary (..),+ newDeviceSummary,+ deviceSummary_associatedWithJob,+ deviceSummary_managedDeviceArn,+ deviceSummary_managedDeviceId,+ deviceSummary_tags,++ -- * EbsInstanceBlockDevice+ EbsInstanceBlockDevice (..),+ newEbsInstanceBlockDevice,+ ebsInstanceBlockDevice_attachTime,+ ebsInstanceBlockDevice_deleteOnTermination,+ ebsInstanceBlockDevice_status,+ ebsInstanceBlockDevice_volumeId,++ -- * ExecutionSummary+ ExecutionSummary (..),+ newExecutionSummary,+ executionSummary_executionId,+ executionSummary_managedDeviceId,+ executionSummary_state,+ executionSummary_taskId,++ -- * Instance+ Instance (..),+ newInstance,+ instance_amiLaunchIndex,+ instance_blockDeviceMappings,+ instance_cpuOptions,+ instance_createdAt,+ instance_imageId,+ instance_instanceId,+ instance_instanceType,+ instance_privateIpAddress,+ instance_publicIpAddress,+ instance_rootDeviceName,+ instance_securityGroups,+ instance_state,+ instance_updatedAt,++ -- * InstanceBlockDeviceMapping+ InstanceBlockDeviceMapping (..),+ newInstanceBlockDeviceMapping,+ instanceBlockDeviceMapping_deviceName,+ instanceBlockDeviceMapping_ebs,++ -- * InstanceState+ InstanceState (..),+ newInstanceState,+ instanceState_code,+ instanceState_name,++ -- * InstanceSummary+ InstanceSummary (..),+ newInstanceSummary,+ instanceSummary_instance,+ instanceSummary_lastUpdatedAt,++ -- * PhysicalNetworkInterface+ PhysicalNetworkInterface (..),+ newPhysicalNetworkInterface,+ physicalNetworkInterface_defaultGateway,+ physicalNetworkInterface_ipAddress,+ physicalNetworkInterface_ipAddressAssignment,+ physicalNetworkInterface_macAddress,+ physicalNetworkInterface_netmask,+ physicalNetworkInterface_physicalConnectorType,+ physicalNetworkInterface_physicalNetworkInterfaceId,++ -- * Reboot+ Reboot (..),+ newReboot,++ -- * ResourceSummary+ ResourceSummary (..),+ newResourceSummary,+ resourceSummary_arn,+ resourceSummary_id,+ resourceSummary_resourceType,++ -- * SecurityGroupIdentifier+ SecurityGroupIdentifier (..),+ newSecurityGroupIdentifier,+ securityGroupIdentifier_groupId,+ securityGroupIdentifier_groupName,++ -- * SoftwareInformation+ SoftwareInformation (..),+ newSoftwareInformation,+ softwareInformation_installState,+ softwareInformation_installedVersion,+ softwareInformation_installingVersion,++ -- * TaskSummary+ TaskSummary (..),+ newTaskSummary,+ taskSummary_state,+ taskSummary_tags,+ taskSummary_taskArn,+ taskSummary_taskId,++ -- * Unlock+ Unlock (..),+ newUnlock,+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Prelude as Prelude+import qualified Amazonka.Sign.V4 as Sign+import Amazonka.SnowDeviceManagement.Types.AttachmentStatus+import Amazonka.SnowDeviceManagement.Types.Capacity+import Amazonka.SnowDeviceManagement.Types.Command+import Amazonka.SnowDeviceManagement.Types.CpuOptions+import Amazonka.SnowDeviceManagement.Types.DeviceSummary+import Amazonka.SnowDeviceManagement.Types.EbsInstanceBlockDevice+import Amazonka.SnowDeviceManagement.Types.ExecutionState+import Amazonka.SnowDeviceManagement.Types.ExecutionSummary+import Amazonka.SnowDeviceManagement.Types.Instance+import Amazonka.SnowDeviceManagement.Types.InstanceBlockDeviceMapping+import Amazonka.SnowDeviceManagement.Types.InstanceState+import Amazonka.SnowDeviceManagement.Types.InstanceStateName+import Amazonka.SnowDeviceManagement.Types.InstanceSummary+import Amazonka.SnowDeviceManagement.Types.IpAddressAssignment+import Amazonka.SnowDeviceManagement.Types.PhysicalConnectorType+import Amazonka.SnowDeviceManagement.Types.PhysicalNetworkInterface+import Amazonka.SnowDeviceManagement.Types.Reboot+import Amazonka.SnowDeviceManagement.Types.ResourceSummary+import Amazonka.SnowDeviceManagement.Types.SecurityGroupIdentifier+import Amazonka.SnowDeviceManagement.Types.SoftwareInformation+import Amazonka.SnowDeviceManagement.Types.TaskState+import Amazonka.SnowDeviceManagement.Types.TaskSummary+import Amazonka.SnowDeviceManagement.Types.Unlock+import Amazonka.SnowDeviceManagement.Types.UnlockState++-- | API version @2021-08-04@ of the Amazon Snow Device Management SDK configuration.+defaultService :: Core.Service+defaultService =+ Core.Service+ { Core.abbrev = "SnowDeviceManagement",+ Core.signer = Sign.v4,+ Core.endpointPrefix = "snow-device-management",+ Core.signingName = "snow-device-management",+ Core.version = "2021-08-04",+ Core.s3AddressingStyle = Core.S3AddressingStyleAuto,+ Core.endpoint = Core.defaultEndpoint defaultService,+ Core.timeout = Prelude.Just 70,+ Core.check = Core.statusSuccess,+ Core.error =+ Core.parseJSONError "SnowDeviceManagement",+ Core.retry = retry+ }+ where+ retry =+ Core.Exponential+ { Core.base = 5.0e-2,+ Core.growth = 2,+ Core.attempts = 5,+ Core.check = check+ }+ check e+ | Lens.has (Core.hasStatus 502) e =+ Prelude.Just "bad_gateway"+ | Lens.has (Core.hasStatus 504) e =+ Prelude.Just "gateway_timeout"+ | Lens.has (Core.hasStatus 500) e =+ Prelude.Just "general_server_error"+ | Lens.has (Core.hasStatus 509) e =+ Prelude.Just "limit_exceeded"+ | Lens.has+ ( Core.hasCode "RequestThrottledException"+ Prelude.. Core.hasStatus 400+ )+ e =+ Prelude.Just "request_throttled_exception"+ | Lens.has (Core.hasStatus 503) e =+ Prelude.Just "service_unavailable"+ | Lens.has+ ( Core.hasCode "ThrottledException"+ Prelude.. Core.hasStatus 400+ )+ e =+ Prelude.Just "throttled_exception"+ | Lens.has+ ( Core.hasCode "Throttling"+ Prelude.. Core.hasStatus 400+ )+ e =+ Prelude.Just "throttling"+ | Lens.has+ ( Core.hasCode "ThrottlingException"+ Prelude.. Core.hasStatus 400+ )+ e =+ Prelude.Just "throttling_exception"+ | Lens.has+ ( Core.hasCode+ "ProvisionedThroughputExceededException"+ Prelude.. Core.hasStatus 400+ )+ e =+ Prelude.Just "throughput_exceeded"+ | Lens.has (Core.hasStatus 429) e =+ Prelude.Just "too_many_requests"+ | Prelude.otherwise = Prelude.Nothing++-- | You don\'t have sufficient access to perform this action.+_AccessDeniedException :: (Core.AsError a) => Lens.Fold a Core.ServiceError+_AccessDeniedException =+ Core._MatchServiceError+ defaultService+ "AccessDeniedException"+ Prelude.. Core.hasStatus 403++-- | An unexpected error occurred while processing the request.+_InternalServerException :: (Core.AsError a) => Lens.Fold a Core.ServiceError+_InternalServerException =+ Core._MatchServiceError+ defaultService+ "InternalServerException"+ Prelude.. Core.hasStatus 500++-- | The request references a resource that doesn\'t exist.+_ResourceNotFoundException :: (Core.AsError a) => Lens.Fold a Core.ServiceError+_ResourceNotFoundException =+ Core._MatchServiceError+ defaultService+ "ResourceNotFoundException"+ Prelude.. Core.hasStatus 404++-- | The request would cause a service quota to be exceeded.+_ServiceQuotaExceededException :: (Core.AsError a) => Lens.Fold a Core.ServiceError+_ServiceQuotaExceededException =+ Core._MatchServiceError+ defaultService+ "ServiceQuotaExceededException"+ Prelude.. Core.hasStatus 402++-- | The request was denied due to request throttling.+_ThrottlingException :: (Core.AsError a) => Lens.Fold a Core.ServiceError+_ThrottlingException =+ Core._MatchServiceError+ defaultService+ "ThrottlingException"+ Prelude.. Core.hasStatus 429++-- | The input fails to satisfy the constraints specified by an Amazon Web+-- Services service.+_ValidationException :: (Core.AsError a) => Lens.Fold a Core.ServiceError+_ValidationException =+ Core._MatchServiceError+ defaultService+ "ValidationException"+ Prelude.. Core.hasStatus 400
+ gen/Amazonka/SnowDeviceManagement/Types/AttachmentStatus.hs view
@@ -0,0 +1,81 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DerivingStrategies #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE PatternSynonyms #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.AttachmentStatus+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.AttachmentStatus+ ( AttachmentStatus+ ( ..,+ AttachmentStatus_ATTACHED,+ AttachmentStatus_ATTACHING,+ AttachmentStatus_DETACHED,+ AttachmentStatus_DETACHING+ ),+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude++newtype AttachmentStatus = AttachmentStatus'+ { fromAttachmentStatus ::+ Data.Text+ }+ deriving stock+ ( Prelude.Show,+ Prelude.Read,+ Prelude.Eq,+ Prelude.Ord,+ Prelude.Generic+ )+ deriving newtype+ ( Prelude.Hashable,+ Prelude.NFData,+ Data.FromText,+ Data.ToText,+ Data.ToByteString,+ Data.ToLog,+ Data.ToHeader,+ Data.ToQuery,+ Data.FromJSON,+ Data.FromJSONKey,+ Data.ToJSON,+ Data.ToJSONKey,+ Data.FromXML,+ Data.ToXML+ )++pattern AttachmentStatus_ATTACHED :: AttachmentStatus+pattern AttachmentStatus_ATTACHED = AttachmentStatus' "ATTACHED"++pattern AttachmentStatus_ATTACHING :: AttachmentStatus+pattern AttachmentStatus_ATTACHING = AttachmentStatus' "ATTACHING"++pattern AttachmentStatus_DETACHED :: AttachmentStatus+pattern AttachmentStatus_DETACHED = AttachmentStatus' "DETACHED"++pattern AttachmentStatus_DETACHING :: AttachmentStatus+pattern AttachmentStatus_DETACHING = AttachmentStatus' "DETACHING"++{-# COMPLETE+ AttachmentStatus_ATTACHED,+ AttachmentStatus_ATTACHING,+ AttachmentStatus_DETACHED,+ AttachmentStatus_DETACHING,+ AttachmentStatus'+ #-}
+ gen/Amazonka/SnowDeviceManagement/Types/Capacity.hs view
@@ -0,0 +1,120 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.Capacity+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.Capacity where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude++-- | The physical capacity of the Amazon Web Services Snow Family device.+--+-- /See:/ 'newCapacity' smart constructor.+data Capacity = Capacity'+ { -- | The amount of capacity available for use on the device.+ available :: Prelude.Maybe Prelude.Integer,+ -- | The name of the type of capacity, such as memory.+ name :: Prelude.Maybe Prelude.Text,+ -- | The total capacity on the device.+ total :: Prelude.Maybe Prelude.Integer,+ -- | The unit of measure for the type of capacity.+ unit :: Prelude.Maybe Prelude.Text,+ -- | The amount of capacity used on the device.+ used :: Prelude.Maybe Prelude.Integer+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'Capacity' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'available', 'capacity_available' - The amount of capacity available for use on the device.+--+-- 'name', 'capacity_name' - The name of the type of capacity, such as memory.+--+-- 'total', 'capacity_total' - The total capacity on the device.+--+-- 'unit', 'capacity_unit' - The unit of measure for the type of capacity.+--+-- 'used', 'capacity_used' - The amount of capacity used on the device.+newCapacity ::+ Capacity+newCapacity =+ Capacity'+ { available = Prelude.Nothing,+ name = Prelude.Nothing,+ total = Prelude.Nothing,+ unit = Prelude.Nothing,+ used = Prelude.Nothing+ }++-- | The amount of capacity available for use on the device.+capacity_available :: Lens.Lens' Capacity (Prelude.Maybe Prelude.Integer)+capacity_available = Lens.lens (\Capacity' {available} -> available) (\s@Capacity' {} a -> s {available = a} :: Capacity)++-- | The name of the type of capacity, such as memory.+capacity_name :: Lens.Lens' Capacity (Prelude.Maybe Prelude.Text)+capacity_name = Lens.lens (\Capacity' {name} -> name) (\s@Capacity' {} a -> s {name = a} :: Capacity)++-- | The total capacity on the device.+capacity_total :: Lens.Lens' Capacity (Prelude.Maybe Prelude.Integer)+capacity_total = Lens.lens (\Capacity' {total} -> total) (\s@Capacity' {} a -> s {total = a} :: Capacity)++-- | The unit of measure for the type of capacity.+capacity_unit :: Lens.Lens' Capacity (Prelude.Maybe Prelude.Text)+capacity_unit = Lens.lens (\Capacity' {unit} -> unit) (\s@Capacity' {} a -> s {unit = a} :: Capacity)++-- | The amount of capacity used on the device.+capacity_used :: Lens.Lens' Capacity (Prelude.Maybe Prelude.Integer)+capacity_used = Lens.lens (\Capacity' {used} -> used) (\s@Capacity' {} a -> s {used = a} :: Capacity)++instance Data.FromJSON Capacity where+ parseJSON =+ Data.withObject+ "Capacity"+ ( \x ->+ Capacity'+ Prelude.<$> (x Data..:? "available")+ Prelude.<*> (x Data..:? "name")+ Prelude.<*> (x Data..:? "total")+ Prelude.<*> (x Data..:? "unit")+ Prelude.<*> (x Data..:? "used")+ )++instance Prelude.Hashable Capacity where+ hashWithSalt _salt Capacity' {..} =+ _salt+ `Prelude.hashWithSalt` available+ `Prelude.hashWithSalt` name+ `Prelude.hashWithSalt` total+ `Prelude.hashWithSalt` unit+ `Prelude.hashWithSalt` used++instance Prelude.NFData Capacity where+ rnf Capacity' {..} =+ Prelude.rnf available+ `Prelude.seq` Prelude.rnf name+ `Prelude.seq` Prelude.rnf total+ `Prelude.seq` Prelude.rnf unit+ `Prelude.seq` Prelude.rnf used
+ gen/Amazonka/SnowDeviceManagement/Types/Command.hs view
@@ -0,0 +1,84 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.Command+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.Command where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import Amazonka.SnowDeviceManagement.Types.Reboot+import Amazonka.SnowDeviceManagement.Types.Unlock++-- | The command given to the device to execute.+--+-- /See:/ 'newCommand' smart constructor.+data Command = Command'+ { -- | Reboots the device.+ reboot :: Prelude.Maybe Reboot,+ -- | Unlocks the device.+ unlock :: Prelude.Maybe Unlock+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'Command' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'reboot', 'command_reboot' - Reboots the device.+--+-- 'unlock', 'command_unlock' - Unlocks the device.+newCommand ::+ Command+newCommand =+ Command'+ { reboot = Prelude.Nothing,+ unlock = Prelude.Nothing+ }++-- | Reboots the device.+command_reboot :: Lens.Lens' Command (Prelude.Maybe Reboot)+command_reboot = Lens.lens (\Command' {reboot} -> reboot) (\s@Command' {} a -> s {reboot = a} :: Command)++-- | Unlocks the device.+command_unlock :: Lens.Lens' Command (Prelude.Maybe Unlock)+command_unlock = Lens.lens (\Command' {unlock} -> unlock) (\s@Command' {} a -> s {unlock = a} :: Command)++instance Prelude.Hashable Command where+ hashWithSalt _salt Command' {..} =+ _salt+ `Prelude.hashWithSalt` reboot+ `Prelude.hashWithSalt` unlock++instance Prelude.NFData Command where+ rnf Command' {..} =+ Prelude.rnf reboot `Prelude.seq` Prelude.rnf unlock++instance Data.ToJSON Command where+ toJSON Command' {..} =+ Data.object+ ( Prelude.catMaybes+ [ ("reboot" Data..=) Prelude.<$> reboot,+ ("unlock" Data..=) Prelude.<$> unlock+ ]+ )
+ gen/Amazonka/SnowDeviceManagement/Types/CpuOptions.hs view
@@ -0,0 +1,84 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.CpuOptions+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.CpuOptions where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude++-- | The options for how a device\'s CPU is configured.+--+-- /See:/ 'newCpuOptions' smart constructor.+data CpuOptions = CpuOptions'+ { -- | The number of cores that the CPU can use.+ coreCount :: Prelude.Maybe Prelude.Int,+ -- | The number of threads per core in the CPU.+ threadsPerCore :: Prelude.Maybe Prelude.Int+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'CpuOptions' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'coreCount', 'cpuOptions_coreCount' - The number of cores that the CPU can use.+--+-- 'threadsPerCore', 'cpuOptions_threadsPerCore' - The number of threads per core in the CPU.+newCpuOptions ::+ CpuOptions+newCpuOptions =+ CpuOptions'+ { coreCount = Prelude.Nothing,+ threadsPerCore = Prelude.Nothing+ }++-- | The number of cores that the CPU can use.+cpuOptions_coreCount :: Lens.Lens' CpuOptions (Prelude.Maybe Prelude.Int)+cpuOptions_coreCount = Lens.lens (\CpuOptions' {coreCount} -> coreCount) (\s@CpuOptions' {} a -> s {coreCount = a} :: CpuOptions)++-- | The number of threads per core in the CPU.+cpuOptions_threadsPerCore :: Lens.Lens' CpuOptions (Prelude.Maybe Prelude.Int)+cpuOptions_threadsPerCore = Lens.lens (\CpuOptions' {threadsPerCore} -> threadsPerCore) (\s@CpuOptions' {} a -> s {threadsPerCore = a} :: CpuOptions)++instance Data.FromJSON CpuOptions where+ parseJSON =+ Data.withObject+ "CpuOptions"+ ( \x ->+ CpuOptions'+ Prelude.<$> (x Data..:? "coreCount")+ Prelude.<*> (x Data..:? "threadsPerCore")+ )++instance Prelude.Hashable CpuOptions where+ hashWithSalt _salt CpuOptions' {..} =+ _salt+ `Prelude.hashWithSalt` coreCount+ `Prelude.hashWithSalt` threadsPerCore++instance Prelude.NFData CpuOptions where+ rnf CpuOptions' {..} =+ Prelude.rnf coreCount+ `Prelude.seq` Prelude.rnf threadsPerCore
+ gen/Amazonka/SnowDeviceManagement/Types/DeviceSummary.hs view
@@ -0,0 +1,114 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.DeviceSummary+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.DeviceSummary where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude++-- | Identifying information about the device.+--+-- /See:/ 'newDeviceSummary' smart constructor.+data DeviceSummary = DeviceSummary'+ { -- | The ID of the job used to order the device.+ associatedWithJob :: Prelude.Maybe Prelude.Text,+ -- | The Amazon Resource Name (ARN) of the device.+ managedDeviceArn :: Prelude.Maybe Prelude.Text,+ -- | The ID of the device.+ managedDeviceId :: Prelude.Maybe Prelude.Text,+ -- | Optional metadata that you assign to a resource. You can use tags to+ -- categorize a resource in different ways, such as by purpose, owner, or+ -- environment.+ tags :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text)+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'DeviceSummary' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'associatedWithJob', 'deviceSummary_associatedWithJob' - The ID of the job used to order the device.+--+-- 'managedDeviceArn', 'deviceSummary_managedDeviceArn' - The Amazon Resource Name (ARN) of the device.+--+-- 'managedDeviceId', 'deviceSummary_managedDeviceId' - The ID of the device.+--+-- 'tags', 'deviceSummary_tags' - Optional metadata that you assign to a resource. You can use tags to+-- categorize a resource in different ways, such as by purpose, owner, or+-- environment.+newDeviceSummary ::+ DeviceSummary+newDeviceSummary =+ DeviceSummary'+ { associatedWithJob = Prelude.Nothing,+ managedDeviceArn = Prelude.Nothing,+ managedDeviceId = Prelude.Nothing,+ tags = Prelude.Nothing+ }++-- | The ID of the job used to order the device.+deviceSummary_associatedWithJob :: Lens.Lens' DeviceSummary (Prelude.Maybe Prelude.Text)+deviceSummary_associatedWithJob = Lens.lens (\DeviceSummary' {associatedWithJob} -> associatedWithJob) (\s@DeviceSummary' {} a -> s {associatedWithJob = a} :: DeviceSummary)++-- | The Amazon Resource Name (ARN) of the device.+deviceSummary_managedDeviceArn :: Lens.Lens' DeviceSummary (Prelude.Maybe Prelude.Text)+deviceSummary_managedDeviceArn = Lens.lens (\DeviceSummary' {managedDeviceArn} -> managedDeviceArn) (\s@DeviceSummary' {} a -> s {managedDeviceArn = a} :: DeviceSummary)++-- | The ID of the device.+deviceSummary_managedDeviceId :: Lens.Lens' DeviceSummary (Prelude.Maybe Prelude.Text)+deviceSummary_managedDeviceId = Lens.lens (\DeviceSummary' {managedDeviceId} -> managedDeviceId) (\s@DeviceSummary' {} a -> s {managedDeviceId = a} :: DeviceSummary)++-- | Optional metadata that you assign to a resource. You can use tags to+-- categorize a resource in different ways, such as by purpose, owner, or+-- environment.+deviceSummary_tags :: Lens.Lens' DeviceSummary (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))+deviceSummary_tags = Lens.lens (\DeviceSummary' {tags} -> tags) (\s@DeviceSummary' {} a -> s {tags = a} :: DeviceSummary) Prelude.. Lens.mapping Lens.coerced++instance Data.FromJSON DeviceSummary where+ parseJSON =+ Data.withObject+ "DeviceSummary"+ ( \x ->+ DeviceSummary'+ Prelude.<$> (x Data..:? "associatedWithJob")+ Prelude.<*> (x Data..:? "managedDeviceArn")+ Prelude.<*> (x Data..:? "managedDeviceId")+ Prelude.<*> (x Data..:? "tags" Data..!= Prelude.mempty)+ )++instance Prelude.Hashable DeviceSummary where+ hashWithSalt _salt DeviceSummary' {..} =+ _salt+ `Prelude.hashWithSalt` associatedWithJob+ `Prelude.hashWithSalt` managedDeviceArn+ `Prelude.hashWithSalt` managedDeviceId+ `Prelude.hashWithSalt` tags++instance Prelude.NFData DeviceSummary where+ rnf DeviceSummary' {..} =+ Prelude.rnf associatedWithJob+ `Prelude.seq` Prelude.rnf managedDeviceArn+ `Prelude.seq` Prelude.rnf managedDeviceId+ `Prelude.seq` Prelude.rnf tags
+ gen/Amazonka/SnowDeviceManagement/Types/EbsInstanceBlockDevice.hs view
@@ -0,0 +1,114 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.EbsInstanceBlockDevice+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.EbsInstanceBlockDevice where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import Amazonka.SnowDeviceManagement.Types.AttachmentStatus++-- | Describes a parameter used to set up an Amazon Elastic Block Store+-- (Amazon EBS) volume in a block device mapping.+--+-- /See:/ 'newEbsInstanceBlockDevice' smart constructor.+data EbsInstanceBlockDevice = EbsInstanceBlockDevice'+ { -- | When the attachment was initiated.+ attachTime :: Prelude.Maybe Data.POSIX,+ -- | A value that indicates whether the volume is deleted on instance+ -- termination.+ deleteOnTermination :: Prelude.Maybe Prelude.Bool,+ -- | The attachment state.+ status :: Prelude.Maybe AttachmentStatus,+ -- | The ID of the Amazon EBS volume.+ volumeId :: Prelude.Maybe Prelude.Text+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'EbsInstanceBlockDevice' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'attachTime', 'ebsInstanceBlockDevice_attachTime' - When the attachment was initiated.+--+-- 'deleteOnTermination', 'ebsInstanceBlockDevice_deleteOnTermination' - A value that indicates whether the volume is deleted on instance+-- termination.+--+-- 'status', 'ebsInstanceBlockDevice_status' - The attachment state.+--+-- 'volumeId', 'ebsInstanceBlockDevice_volumeId' - The ID of the Amazon EBS volume.+newEbsInstanceBlockDevice ::+ EbsInstanceBlockDevice+newEbsInstanceBlockDevice =+ EbsInstanceBlockDevice'+ { attachTime =+ Prelude.Nothing,+ deleteOnTermination = Prelude.Nothing,+ status = Prelude.Nothing,+ volumeId = Prelude.Nothing+ }++-- | When the attachment was initiated.+ebsInstanceBlockDevice_attachTime :: Lens.Lens' EbsInstanceBlockDevice (Prelude.Maybe Prelude.UTCTime)+ebsInstanceBlockDevice_attachTime = Lens.lens (\EbsInstanceBlockDevice' {attachTime} -> attachTime) (\s@EbsInstanceBlockDevice' {} a -> s {attachTime = a} :: EbsInstanceBlockDevice) Prelude.. Lens.mapping Data._Time++-- | A value that indicates whether the volume is deleted on instance+-- termination.+ebsInstanceBlockDevice_deleteOnTermination :: Lens.Lens' EbsInstanceBlockDevice (Prelude.Maybe Prelude.Bool)+ebsInstanceBlockDevice_deleteOnTermination = Lens.lens (\EbsInstanceBlockDevice' {deleteOnTermination} -> deleteOnTermination) (\s@EbsInstanceBlockDevice' {} a -> s {deleteOnTermination = a} :: EbsInstanceBlockDevice)++-- | The attachment state.+ebsInstanceBlockDevice_status :: Lens.Lens' EbsInstanceBlockDevice (Prelude.Maybe AttachmentStatus)+ebsInstanceBlockDevice_status = Lens.lens (\EbsInstanceBlockDevice' {status} -> status) (\s@EbsInstanceBlockDevice' {} a -> s {status = a} :: EbsInstanceBlockDevice)++-- | The ID of the Amazon EBS volume.+ebsInstanceBlockDevice_volumeId :: Lens.Lens' EbsInstanceBlockDevice (Prelude.Maybe Prelude.Text)+ebsInstanceBlockDevice_volumeId = Lens.lens (\EbsInstanceBlockDevice' {volumeId} -> volumeId) (\s@EbsInstanceBlockDevice' {} a -> s {volumeId = a} :: EbsInstanceBlockDevice)++instance Data.FromJSON EbsInstanceBlockDevice where+ parseJSON =+ Data.withObject+ "EbsInstanceBlockDevice"+ ( \x ->+ EbsInstanceBlockDevice'+ Prelude.<$> (x Data..:? "attachTime")+ Prelude.<*> (x Data..:? "deleteOnTermination")+ Prelude.<*> (x Data..:? "status")+ Prelude.<*> (x Data..:? "volumeId")+ )++instance Prelude.Hashable EbsInstanceBlockDevice where+ hashWithSalt _salt EbsInstanceBlockDevice' {..} =+ _salt+ `Prelude.hashWithSalt` attachTime+ `Prelude.hashWithSalt` deleteOnTermination+ `Prelude.hashWithSalt` status+ `Prelude.hashWithSalt` volumeId++instance Prelude.NFData EbsInstanceBlockDevice where+ rnf EbsInstanceBlockDevice' {..} =+ Prelude.rnf attachTime+ `Prelude.seq` Prelude.rnf deleteOnTermination+ `Prelude.seq` Prelude.rnf status+ `Prelude.seq` Prelude.rnf volumeId
+ gen/Amazonka/SnowDeviceManagement/Types/ExecutionState.hs view
@@ -0,0 +1,96 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DerivingStrategies #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE PatternSynonyms #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.ExecutionState+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.ExecutionState+ ( ExecutionState+ ( ..,+ ExecutionState_CANCELED,+ ExecutionState_FAILED,+ ExecutionState_IN_PROGRESS,+ ExecutionState_QUEUED,+ ExecutionState_REJECTED,+ ExecutionState_SUCCEEDED,+ ExecutionState_TIMED_OUT+ ),+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude++newtype ExecutionState = ExecutionState'+ { fromExecutionState ::+ Data.Text+ }+ deriving stock+ ( Prelude.Show,+ Prelude.Read,+ Prelude.Eq,+ Prelude.Ord,+ Prelude.Generic+ )+ deriving newtype+ ( Prelude.Hashable,+ Prelude.NFData,+ Data.FromText,+ Data.ToText,+ Data.ToByteString,+ Data.ToLog,+ Data.ToHeader,+ Data.ToQuery,+ Data.FromJSON,+ Data.FromJSONKey,+ Data.ToJSON,+ Data.ToJSONKey,+ Data.FromXML,+ Data.ToXML+ )++pattern ExecutionState_CANCELED :: ExecutionState+pattern ExecutionState_CANCELED = ExecutionState' "CANCELED"++pattern ExecutionState_FAILED :: ExecutionState+pattern ExecutionState_FAILED = ExecutionState' "FAILED"++pattern ExecutionState_IN_PROGRESS :: ExecutionState+pattern ExecutionState_IN_PROGRESS = ExecutionState' "IN_PROGRESS"++pattern ExecutionState_QUEUED :: ExecutionState+pattern ExecutionState_QUEUED = ExecutionState' "QUEUED"++pattern ExecutionState_REJECTED :: ExecutionState+pattern ExecutionState_REJECTED = ExecutionState' "REJECTED"++pattern ExecutionState_SUCCEEDED :: ExecutionState+pattern ExecutionState_SUCCEEDED = ExecutionState' "SUCCEEDED"++pattern ExecutionState_TIMED_OUT :: ExecutionState+pattern ExecutionState_TIMED_OUT = ExecutionState' "TIMED_OUT"++{-# COMPLETE+ ExecutionState_CANCELED,+ ExecutionState_FAILED,+ ExecutionState_IN_PROGRESS,+ ExecutionState_QUEUED,+ ExecutionState_REJECTED,+ ExecutionState_SUCCEEDED,+ ExecutionState_TIMED_OUT,+ ExecutionState'+ #-}
+ gen/Amazonka/SnowDeviceManagement/Types/ExecutionSummary.hs view
@@ -0,0 +1,109 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.ExecutionSummary+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.ExecutionSummary where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import Amazonka.SnowDeviceManagement.Types.ExecutionState++-- | The summary of a task execution on a specified device.+--+-- /See:/ 'newExecutionSummary' smart constructor.+data ExecutionSummary = ExecutionSummary'+ { -- | The ID of the execution.+ executionId :: Prelude.Maybe Prelude.Text,+ -- | The ID of the managed device that the task is being executed on.+ managedDeviceId :: Prelude.Maybe Prelude.Text,+ -- | The state of the execution.+ state :: Prelude.Maybe ExecutionState,+ -- | The ID of the task.+ taskId :: Prelude.Maybe Prelude.Text+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'ExecutionSummary' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'executionId', 'executionSummary_executionId' - The ID of the execution.+--+-- 'managedDeviceId', 'executionSummary_managedDeviceId' - The ID of the managed device that the task is being executed on.+--+-- 'state', 'executionSummary_state' - The state of the execution.+--+-- 'taskId', 'executionSummary_taskId' - The ID of the task.+newExecutionSummary ::+ ExecutionSummary+newExecutionSummary =+ ExecutionSummary'+ { executionId = Prelude.Nothing,+ managedDeviceId = Prelude.Nothing,+ state = Prelude.Nothing,+ taskId = Prelude.Nothing+ }++-- | The ID of the execution.+executionSummary_executionId :: Lens.Lens' ExecutionSummary (Prelude.Maybe Prelude.Text)+executionSummary_executionId = Lens.lens (\ExecutionSummary' {executionId} -> executionId) (\s@ExecutionSummary' {} a -> s {executionId = a} :: ExecutionSummary)++-- | The ID of the managed device that the task is being executed on.+executionSummary_managedDeviceId :: Lens.Lens' ExecutionSummary (Prelude.Maybe Prelude.Text)+executionSummary_managedDeviceId = Lens.lens (\ExecutionSummary' {managedDeviceId} -> managedDeviceId) (\s@ExecutionSummary' {} a -> s {managedDeviceId = a} :: ExecutionSummary)++-- | The state of the execution.+executionSummary_state :: Lens.Lens' ExecutionSummary (Prelude.Maybe ExecutionState)+executionSummary_state = Lens.lens (\ExecutionSummary' {state} -> state) (\s@ExecutionSummary' {} a -> s {state = a} :: ExecutionSummary)++-- | The ID of the task.+executionSummary_taskId :: Lens.Lens' ExecutionSummary (Prelude.Maybe Prelude.Text)+executionSummary_taskId = Lens.lens (\ExecutionSummary' {taskId} -> taskId) (\s@ExecutionSummary' {} a -> s {taskId = a} :: ExecutionSummary)++instance Data.FromJSON ExecutionSummary where+ parseJSON =+ Data.withObject+ "ExecutionSummary"+ ( \x ->+ ExecutionSummary'+ Prelude.<$> (x Data..:? "executionId")+ Prelude.<*> (x Data..:? "managedDeviceId")+ Prelude.<*> (x Data..:? "state")+ Prelude.<*> (x Data..:? "taskId")+ )++instance Prelude.Hashable ExecutionSummary where+ hashWithSalt _salt ExecutionSummary' {..} =+ _salt+ `Prelude.hashWithSalt` executionId+ `Prelude.hashWithSalt` managedDeviceId+ `Prelude.hashWithSalt` state+ `Prelude.hashWithSalt` taskId++instance Prelude.NFData ExecutionSummary where+ rnf ExecutionSummary' {..} =+ Prelude.rnf executionId+ `Prelude.seq` Prelude.rnf managedDeviceId+ `Prelude.seq` Prelude.rnf state+ `Prelude.seq` Prelude.rnf taskId
+ gen/Amazonka/SnowDeviceManagement/Types/Instance.hs view
@@ -0,0 +1,226 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.Instance+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.Instance where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import Amazonka.SnowDeviceManagement.Types.CpuOptions+import Amazonka.SnowDeviceManagement.Types.InstanceBlockDeviceMapping+import Amazonka.SnowDeviceManagement.Types.InstanceState+import Amazonka.SnowDeviceManagement.Types.SecurityGroupIdentifier++-- | The description of an instance. Currently, Amazon EC2 instances are the+-- only supported instance type.+--+-- /See:/ 'newInstance' smart constructor.+data Instance = Instance'+ { -- | The Amazon Machine Image (AMI) launch index, which you can use to find+ -- this instance in the launch group.+ amiLaunchIndex :: Prelude.Maybe Prelude.Int,+ -- | Any block device mapping entries for the instance.+ blockDeviceMappings :: Prelude.Maybe [InstanceBlockDeviceMapping],+ -- | The CPU options for the instance.+ cpuOptions :: Prelude.Maybe CpuOptions,+ -- | When the instance was created.+ createdAt :: Prelude.Maybe Data.POSIX,+ -- | The ID of the AMI used to launch the instance.+ imageId :: Prelude.Maybe Prelude.Text,+ -- | The ID of the instance.+ instanceId :: Prelude.Maybe Prelude.Text,+ -- | The instance type.+ instanceType :: Prelude.Maybe Prelude.Text,+ -- | The private IPv4 address assigned to the instance.+ privateIpAddress :: Prelude.Maybe Prelude.Text,+ -- | The public IPv4 address assigned to the instance.+ publicIpAddress :: Prelude.Maybe Prelude.Text,+ -- | The device name of the root device volume (for example, @\/dev\/sda1@).+ rootDeviceName :: Prelude.Maybe Prelude.Text,+ -- | The security groups for the instance.+ securityGroups :: Prelude.Maybe [SecurityGroupIdentifier],+ state :: Prelude.Maybe InstanceState,+ -- | When the instance was last updated.+ updatedAt :: Prelude.Maybe Data.POSIX+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'Instance' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'amiLaunchIndex', 'instance_amiLaunchIndex' - The Amazon Machine Image (AMI) launch index, which you can use to find+-- this instance in the launch group.+--+-- 'blockDeviceMappings', 'instance_blockDeviceMappings' - Any block device mapping entries for the instance.+--+-- 'cpuOptions', 'instance_cpuOptions' - The CPU options for the instance.+--+-- 'createdAt', 'instance_createdAt' - When the instance was created.+--+-- 'imageId', 'instance_imageId' - The ID of the AMI used to launch the instance.+--+-- 'instanceId', 'instance_instanceId' - The ID of the instance.+--+-- 'instanceType', 'instance_instanceType' - The instance type.+--+-- 'privateIpAddress', 'instance_privateIpAddress' - The private IPv4 address assigned to the instance.+--+-- 'publicIpAddress', 'instance_publicIpAddress' - The public IPv4 address assigned to the instance.+--+-- 'rootDeviceName', 'instance_rootDeviceName' - The device name of the root device volume (for example, @\/dev\/sda1@).+--+-- 'securityGroups', 'instance_securityGroups' - The security groups for the instance.+--+-- 'state', 'instance_state' - Undocumented member.+--+-- 'updatedAt', 'instance_updatedAt' - When the instance was last updated.+newInstance ::+ Instance+newInstance =+ Instance'+ { amiLaunchIndex = Prelude.Nothing,+ blockDeviceMappings = Prelude.Nothing,+ cpuOptions = Prelude.Nothing,+ createdAt = Prelude.Nothing,+ imageId = Prelude.Nothing,+ instanceId = Prelude.Nothing,+ instanceType = Prelude.Nothing,+ privateIpAddress = Prelude.Nothing,+ publicIpAddress = Prelude.Nothing,+ rootDeviceName = Prelude.Nothing,+ securityGroups = Prelude.Nothing,+ state = Prelude.Nothing,+ updatedAt = Prelude.Nothing+ }++-- | The Amazon Machine Image (AMI) launch index, which you can use to find+-- this instance in the launch group.+instance_amiLaunchIndex :: Lens.Lens' Instance (Prelude.Maybe Prelude.Int)+instance_amiLaunchIndex = Lens.lens (\Instance' {amiLaunchIndex} -> amiLaunchIndex) (\s@Instance' {} a -> s {amiLaunchIndex = a} :: Instance)++-- | Any block device mapping entries for the instance.+instance_blockDeviceMappings :: Lens.Lens' Instance (Prelude.Maybe [InstanceBlockDeviceMapping])+instance_blockDeviceMappings = Lens.lens (\Instance' {blockDeviceMappings} -> blockDeviceMappings) (\s@Instance' {} a -> s {blockDeviceMappings = a} :: Instance) Prelude.. Lens.mapping Lens.coerced++-- | The CPU options for the instance.+instance_cpuOptions :: Lens.Lens' Instance (Prelude.Maybe CpuOptions)+instance_cpuOptions = Lens.lens (\Instance' {cpuOptions} -> cpuOptions) (\s@Instance' {} a -> s {cpuOptions = a} :: Instance)++-- | When the instance was created.+instance_createdAt :: Lens.Lens' Instance (Prelude.Maybe Prelude.UTCTime)+instance_createdAt = Lens.lens (\Instance' {createdAt} -> createdAt) (\s@Instance' {} a -> s {createdAt = a} :: Instance) Prelude.. Lens.mapping Data._Time++-- | The ID of the AMI used to launch the instance.+instance_imageId :: Lens.Lens' Instance (Prelude.Maybe Prelude.Text)+instance_imageId = Lens.lens (\Instance' {imageId} -> imageId) (\s@Instance' {} a -> s {imageId = a} :: Instance)++-- | The ID of the instance.+instance_instanceId :: Lens.Lens' Instance (Prelude.Maybe Prelude.Text)+instance_instanceId = Lens.lens (\Instance' {instanceId} -> instanceId) (\s@Instance' {} a -> s {instanceId = a} :: Instance)++-- | The instance type.+instance_instanceType :: Lens.Lens' Instance (Prelude.Maybe Prelude.Text)+instance_instanceType = Lens.lens (\Instance' {instanceType} -> instanceType) (\s@Instance' {} a -> s {instanceType = a} :: Instance)++-- | The private IPv4 address assigned to the instance.+instance_privateIpAddress :: Lens.Lens' Instance (Prelude.Maybe Prelude.Text)+instance_privateIpAddress = Lens.lens (\Instance' {privateIpAddress} -> privateIpAddress) (\s@Instance' {} a -> s {privateIpAddress = a} :: Instance)++-- | The public IPv4 address assigned to the instance.+instance_publicIpAddress :: Lens.Lens' Instance (Prelude.Maybe Prelude.Text)+instance_publicIpAddress = Lens.lens (\Instance' {publicIpAddress} -> publicIpAddress) (\s@Instance' {} a -> s {publicIpAddress = a} :: Instance)++-- | The device name of the root device volume (for example, @\/dev\/sda1@).+instance_rootDeviceName :: Lens.Lens' Instance (Prelude.Maybe Prelude.Text)+instance_rootDeviceName = Lens.lens (\Instance' {rootDeviceName} -> rootDeviceName) (\s@Instance' {} a -> s {rootDeviceName = a} :: Instance)++-- | The security groups for the instance.+instance_securityGroups :: Lens.Lens' Instance (Prelude.Maybe [SecurityGroupIdentifier])+instance_securityGroups = Lens.lens (\Instance' {securityGroups} -> securityGroups) (\s@Instance' {} a -> s {securityGroups = a} :: Instance) Prelude.. Lens.mapping Lens.coerced++-- | Undocumented member.+instance_state :: Lens.Lens' Instance (Prelude.Maybe InstanceState)+instance_state = Lens.lens (\Instance' {state} -> state) (\s@Instance' {} a -> s {state = a} :: Instance)++-- | When the instance was last updated.+instance_updatedAt :: Lens.Lens' Instance (Prelude.Maybe Prelude.UTCTime)+instance_updatedAt = Lens.lens (\Instance' {updatedAt} -> updatedAt) (\s@Instance' {} a -> s {updatedAt = a} :: Instance) Prelude.. Lens.mapping Data._Time++instance Data.FromJSON Instance where+ parseJSON =+ Data.withObject+ "Instance"+ ( \x ->+ Instance'+ Prelude.<$> (x Data..:? "amiLaunchIndex")+ Prelude.<*> ( x+ Data..:? "blockDeviceMappings"+ Data..!= Prelude.mempty+ )+ Prelude.<*> (x Data..:? "cpuOptions")+ Prelude.<*> (x Data..:? "createdAt")+ Prelude.<*> (x Data..:? "imageId")+ Prelude.<*> (x Data..:? "instanceId")+ Prelude.<*> (x Data..:? "instanceType")+ Prelude.<*> (x Data..:? "privateIpAddress")+ Prelude.<*> (x Data..:? "publicIpAddress")+ Prelude.<*> (x Data..:? "rootDeviceName")+ Prelude.<*> (x Data..:? "securityGroups" Data..!= Prelude.mempty)+ Prelude.<*> (x Data..:? "state")+ Prelude.<*> (x Data..:? "updatedAt")+ )++instance Prelude.Hashable Instance where+ hashWithSalt _salt Instance' {..} =+ _salt+ `Prelude.hashWithSalt` amiLaunchIndex+ `Prelude.hashWithSalt` blockDeviceMappings+ `Prelude.hashWithSalt` cpuOptions+ `Prelude.hashWithSalt` createdAt+ `Prelude.hashWithSalt` imageId+ `Prelude.hashWithSalt` instanceId+ `Prelude.hashWithSalt` instanceType+ `Prelude.hashWithSalt` privateIpAddress+ `Prelude.hashWithSalt` publicIpAddress+ `Prelude.hashWithSalt` rootDeviceName+ `Prelude.hashWithSalt` securityGroups+ `Prelude.hashWithSalt` state+ `Prelude.hashWithSalt` updatedAt++instance Prelude.NFData Instance where+ rnf Instance' {..} =+ Prelude.rnf amiLaunchIndex+ `Prelude.seq` Prelude.rnf blockDeviceMappings+ `Prelude.seq` Prelude.rnf cpuOptions+ `Prelude.seq` Prelude.rnf createdAt+ `Prelude.seq` Prelude.rnf imageId+ `Prelude.seq` Prelude.rnf instanceId+ `Prelude.seq` Prelude.rnf instanceType+ `Prelude.seq` Prelude.rnf privateIpAddress+ `Prelude.seq` Prelude.rnf publicIpAddress+ `Prelude.seq` Prelude.rnf rootDeviceName+ `Prelude.seq` Prelude.rnf securityGroups+ `Prelude.seq` Prelude.rnf state+ `Prelude.seq` Prelude.rnf updatedAt
+ gen/Amazonka/SnowDeviceManagement/Types/InstanceBlockDeviceMapping.hs view
@@ -0,0 +1,89 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.InstanceBlockDeviceMapping+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.InstanceBlockDeviceMapping where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import Amazonka.SnowDeviceManagement.Types.EbsInstanceBlockDevice++-- | The description of a block device mapping.+--+-- /See:/ 'newInstanceBlockDeviceMapping' smart constructor.+data InstanceBlockDeviceMapping = InstanceBlockDeviceMapping'+ { -- | The block device name.+ deviceName :: Prelude.Maybe Prelude.Text,+ -- | The parameters used to automatically set up Amazon Elastic Block Store+ -- (Amazon EBS) volumes when the instance is launched.+ ebs :: Prelude.Maybe EbsInstanceBlockDevice+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'InstanceBlockDeviceMapping' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'deviceName', 'instanceBlockDeviceMapping_deviceName' - The block device name.+--+-- 'ebs', 'instanceBlockDeviceMapping_ebs' - The parameters used to automatically set up Amazon Elastic Block Store+-- (Amazon EBS) volumes when the instance is launched.+newInstanceBlockDeviceMapping ::+ InstanceBlockDeviceMapping+newInstanceBlockDeviceMapping =+ InstanceBlockDeviceMapping'+ { deviceName =+ Prelude.Nothing,+ ebs = Prelude.Nothing+ }++-- | The block device name.+instanceBlockDeviceMapping_deviceName :: Lens.Lens' InstanceBlockDeviceMapping (Prelude.Maybe Prelude.Text)+instanceBlockDeviceMapping_deviceName = Lens.lens (\InstanceBlockDeviceMapping' {deviceName} -> deviceName) (\s@InstanceBlockDeviceMapping' {} a -> s {deviceName = a} :: InstanceBlockDeviceMapping)++-- | The parameters used to automatically set up Amazon Elastic Block Store+-- (Amazon EBS) volumes when the instance is launched.+instanceBlockDeviceMapping_ebs :: Lens.Lens' InstanceBlockDeviceMapping (Prelude.Maybe EbsInstanceBlockDevice)+instanceBlockDeviceMapping_ebs = Lens.lens (\InstanceBlockDeviceMapping' {ebs} -> ebs) (\s@InstanceBlockDeviceMapping' {} a -> s {ebs = a} :: InstanceBlockDeviceMapping)++instance Data.FromJSON InstanceBlockDeviceMapping where+ parseJSON =+ Data.withObject+ "InstanceBlockDeviceMapping"+ ( \x ->+ InstanceBlockDeviceMapping'+ Prelude.<$> (x Data..:? "deviceName")+ Prelude.<*> (x Data..:? "ebs")+ )++instance Prelude.Hashable InstanceBlockDeviceMapping where+ hashWithSalt _salt InstanceBlockDeviceMapping' {..} =+ _salt+ `Prelude.hashWithSalt` deviceName+ `Prelude.hashWithSalt` ebs++instance Prelude.NFData InstanceBlockDeviceMapping where+ rnf InstanceBlockDeviceMapping' {..} =+ Prelude.rnf deviceName+ `Prelude.seq` Prelude.rnf ebs
+ gen/Amazonka/SnowDeviceManagement/Types/InstanceState.hs view
@@ -0,0 +1,159 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.InstanceState+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.InstanceState where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import Amazonka.SnowDeviceManagement.Types.InstanceStateName++-- | The description of the current state of an instance.+--+-- /See:/ 'newInstanceState' smart constructor.+data InstanceState = InstanceState'+ { -- | The state of the instance as a 16-bit unsigned integer.+ --+ -- The high byte is all of the bits between 2^8 and (2^16)-1, which equals+ -- decimal values between 256 and 65,535. These numerical values are used+ -- for internal purposes and should be ignored.+ --+ -- The low byte is all of the bits between 2^0 and (2^8)-1, which equals+ -- decimal values between 0 and 255.+ --+ -- The valid values for the instance state code are all in the range of the+ -- low byte. These values are:+ --+ -- - @0@ : @pending@+ --+ -- - @16@ : @running@+ --+ -- - @32@ : @shutting-down@+ --+ -- - @48@ : @terminated@+ --+ -- - @64@ : @stopping@+ --+ -- - @80@ : @stopped@+ --+ -- You can ignore the high byte value by zeroing out all of the bits above+ -- 2^8 or 256 in decimal.+ code :: Prelude.Maybe Prelude.Int,+ -- | The current state of the instance.+ name :: Prelude.Maybe InstanceStateName+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'InstanceState' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'code', 'instanceState_code' - The state of the instance as a 16-bit unsigned integer.+--+-- The high byte is all of the bits between 2^8 and (2^16)-1, which equals+-- decimal values between 256 and 65,535. These numerical values are used+-- for internal purposes and should be ignored.+--+-- The low byte is all of the bits between 2^0 and (2^8)-1, which equals+-- decimal values between 0 and 255.+--+-- The valid values for the instance state code are all in the range of the+-- low byte. These values are:+--+-- - @0@ : @pending@+--+-- - @16@ : @running@+--+-- - @32@ : @shutting-down@+--+-- - @48@ : @terminated@+--+-- - @64@ : @stopping@+--+-- - @80@ : @stopped@+--+-- You can ignore the high byte value by zeroing out all of the bits above+-- 2^8 or 256 in decimal.+--+-- 'name', 'instanceState_name' - The current state of the instance.+newInstanceState ::+ InstanceState+newInstanceState =+ InstanceState'+ { code = Prelude.Nothing,+ name = Prelude.Nothing+ }++-- | The state of the instance as a 16-bit unsigned integer.+--+-- The high byte is all of the bits between 2^8 and (2^16)-1, which equals+-- decimal values between 256 and 65,535. These numerical values are used+-- for internal purposes and should be ignored.+--+-- The low byte is all of the bits between 2^0 and (2^8)-1, which equals+-- decimal values between 0 and 255.+--+-- The valid values for the instance state code are all in the range of the+-- low byte. These values are:+--+-- - @0@ : @pending@+--+-- - @16@ : @running@+--+-- - @32@ : @shutting-down@+--+-- - @48@ : @terminated@+--+-- - @64@ : @stopping@+--+-- - @80@ : @stopped@+--+-- You can ignore the high byte value by zeroing out all of the bits above+-- 2^8 or 256 in decimal.+instanceState_code :: Lens.Lens' InstanceState (Prelude.Maybe Prelude.Int)+instanceState_code = Lens.lens (\InstanceState' {code} -> code) (\s@InstanceState' {} a -> s {code = a} :: InstanceState)++-- | The current state of the instance.+instanceState_name :: Lens.Lens' InstanceState (Prelude.Maybe InstanceStateName)+instanceState_name = Lens.lens (\InstanceState' {name} -> name) (\s@InstanceState' {} a -> s {name = a} :: InstanceState)++instance Data.FromJSON InstanceState where+ parseJSON =+ Data.withObject+ "InstanceState"+ ( \x ->+ InstanceState'+ Prelude.<$> (x Data..:? "code")+ Prelude.<*> (x Data..:? "name")+ )++instance Prelude.Hashable InstanceState where+ hashWithSalt _salt InstanceState' {..} =+ _salt+ `Prelude.hashWithSalt` code+ `Prelude.hashWithSalt` name++instance Prelude.NFData InstanceState where+ rnf InstanceState' {..} =+ Prelude.rnf code `Prelude.seq` Prelude.rnf name
+ gen/Amazonka/SnowDeviceManagement/Types/InstanceStateName.hs view
@@ -0,0 +1,91 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DerivingStrategies #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE PatternSynonyms #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.InstanceStateName+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.InstanceStateName+ ( InstanceStateName+ ( ..,+ InstanceStateName_PENDING,+ InstanceStateName_RUNNING,+ InstanceStateName_SHUTTING_DOWN,+ InstanceStateName_STOPPED,+ InstanceStateName_STOPPING,+ InstanceStateName_TERMINATED+ ),+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude++newtype InstanceStateName = InstanceStateName'+ { fromInstanceStateName ::+ Data.Text+ }+ deriving stock+ ( Prelude.Show,+ Prelude.Read,+ Prelude.Eq,+ Prelude.Ord,+ Prelude.Generic+ )+ deriving newtype+ ( Prelude.Hashable,+ Prelude.NFData,+ Data.FromText,+ Data.ToText,+ Data.ToByteString,+ Data.ToLog,+ Data.ToHeader,+ Data.ToQuery,+ Data.FromJSON,+ Data.FromJSONKey,+ Data.ToJSON,+ Data.ToJSONKey,+ Data.FromXML,+ Data.ToXML+ )++pattern InstanceStateName_PENDING :: InstanceStateName+pattern InstanceStateName_PENDING = InstanceStateName' "PENDING"++pattern InstanceStateName_RUNNING :: InstanceStateName+pattern InstanceStateName_RUNNING = InstanceStateName' "RUNNING"++pattern InstanceStateName_SHUTTING_DOWN :: InstanceStateName+pattern InstanceStateName_SHUTTING_DOWN = InstanceStateName' "SHUTTING_DOWN"++pattern InstanceStateName_STOPPED :: InstanceStateName+pattern InstanceStateName_STOPPED = InstanceStateName' "STOPPED"++pattern InstanceStateName_STOPPING :: InstanceStateName+pattern InstanceStateName_STOPPING = InstanceStateName' "STOPPING"++pattern InstanceStateName_TERMINATED :: InstanceStateName+pattern InstanceStateName_TERMINATED = InstanceStateName' "TERMINATED"++{-# COMPLETE+ InstanceStateName_PENDING,+ InstanceStateName_RUNNING,+ InstanceStateName_SHUTTING_DOWN,+ InstanceStateName_STOPPED,+ InstanceStateName_STOPPING,+ InstanceStateName_TERMINATED,+ InstanceStateName'+ #-}
+ gen/Amazonka/SnowDeviceManagement/Types/InstanceSummary.hs view
@@ -0,0 +1,85 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.InstanceSummary+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.InstanceSummary where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import Amazonka.SnowDeviceManagement.Types.Instance++-- | The details about the instance.+--+-- /See:/ 'newInstanceSummary' smart constructor.+data InstanceSummary = InstanceSummary'+ { -- | A structure containing details about the instance.+ instance' :: Prelude.Maybe Instance,+ -- | When the instance summary was last updated.+ lastUpdatedAt :: Prelude.Maybe Data.POSIX+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'InstanceSummary' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'instance'', 'instanceSummary_instance' - A structure containing details about the instance.+--+-- 'lastUpdatedAt', 'instanceSummary_lastUpdatedAt' - When the instance summary was last updated.+newInstanceSummary ::+ InstanceSummary+newInstanceSummary =+ InstanceSummary'+ { instance' = Prelude.Nothing,+ lastUpdatedAt = Prelude.Nothing+ }++-- | A structure containing details about the instance.+instanceSummary_instance :: Lens.Lens' InstanceSummary (Prelude.Maybe Instance)+instanceSummary_instance = Lens.lens (\InstanceSummary' {instance'} -> instance') (\s@InstanceSummary' {} a -> s {instance' = a} :: InstanceSummary)++-- | When the instance summary was last updated.+instanceSummary_lastUpdatedAt :: Lens.Lens' InstanceSummary (Prelude.Maybe Prelude.UTCTime)+instanceSummary_lastUpdatedAt = Lens.lens (\InstanceSummary' {lastUpdatedAt} -> lastUpdatedAt) (\s@InstanceSummary' {} a -> s {lastUpdatedAt = a} :: InstanceSummary) Prelude.. Lens.mapping Data._Time++instance Data.FromJSON InstanceSummary where+ parseJSON =+ Data.withObject+ "InstanceSummary"+ ( \x ->+ InstanceSummary'+ Prelude.<$> (x Data..:? "instance")+ Prelude.<*> (x Data..:? "lastUpdatedAt")+ )++instance Prelude.Hashable InstanceSummary where+ hashWithSalt _salt InstanceSummary' {..} =+ _salt+ `Prelude.hashWithSalt` instance'+ `Prelude.hashWithSalt` lastUpdatedAt++instance Prelude.NFData InstanceSummary where+ rnf InstanceSummary' {..} =+ Prelude.rnf instance'+ `Prelude.seq` Prelude.rnf lastUpdatedAt
+ gen/Amazonka/SnowDeviceManagement/Types/IpAddressAssignment.hs view
@@ -0,0 +1,71 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DerivingStrategies #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE PatternSynonyms #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.IpAddressAssignment+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.IpAddressAssignment+ ( IpAddressAssignment+ ( ..,+ IpAddressAssignment_DHCP,+ IpAddressAssignment_STATIC+ ),+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude++newtype IpAddressAssignment = IpAddressAssignment'+ { fromIpAddressAssignment ::+ Data.Text+ }+ deriving stock+ ( Prelude.Show,+ Prelude.Read,+ Prelude.Eq,+ Prelude.Ord,+ Prelude.Generic+ )+ deriving newtype+ ( Prelude.Hashable,+ Prelude.NFData,+ Data.FromText,+ Data.ToText,+ Data.ToByteString,+ Data.ToLog,+ Data.ToHeader,+ Data.ToQuery,+ Data.FromJSON,+ Data.FromJSONKey,+ Data.ToJSON,+ Data.ToJSONKey,+ Data.FromXML,+ Data.ToXML+ )++pattern IpAddressAssignment_DHCP :: IpAddressAssignment+pattern IpAddressAssignment_DHCP = IpAddressAssignment' "DHCP"++pattern IpAddressAssignment_STATIC :: IpAddressAssignment+pattern IpAddressAssignment_STATIC = IpAddressAssignment' "STATIC"++{-# COMPLETE+ IpAddressAssignment_DHCP,+ IpAddressAssignment_STATIC,+ IpAddressAssignment'+ #-}
+ gen/Amazonka/SnowDeviceManagement/Types/PhysicalConnectorType.hs view
@@ -0,0 +1,86 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DerivingStrategies #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE PatternSynonyms #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.PhysicalConnectorType+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.PhysicalConnectorType+ ( PhysicalConnectorType+ ( ..,+ PhysicalConnectorType_QSFP,+ PhysicalConnectorType_RJ45,+ PhysicalConnectorType_RJ45_2,+ PhysicalConnectorType_SFP_PLUS,+ PhysicalConnectorType_WIFI+ ),+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude++newtype PhysicalConnectorType = PhysicalConnectorType'+ { fromPhysicalConnectorType ::+ Data.Text+ }+ deriving stock+ ( Prelude.Show,+ Prelude.Read,+ Prelude.Eq,+ Prelude.Ord,+ Prelude.Generic+ )+ deriving newtype+ ( Prelude.Hashable,+ Prelude.NFData,+ Data.FromText,+ Data.ToText,+ Data.ToByteString,+ Data.ToLog,+ Data.ToHeader,+ Data.ToQuery,+ Data.FromJSON,+ Data.FromJSONKey,+ Data.ToJSON,+ Data.ToJSONKey,+ Data.FromXML,+ Data.ToXML+ )++pattern PhysicalConnectorType_QSFP :: PhysicalConnectorType+pattern PhysicalConnectorType_QSFP = PhysicalConnectorType' "QSFP"++pattern PhysicalConnectorType_RJ45 :: PhysicalConnectorType+pattern PhysicalConnectorType_RJ45 = PhysicalConnectorType' "RJ45"++pattern PhysicalConnectorType_RJ45_2 :: PhysicalConnectorType+pattern PhysicalConnectorType_RJ45_2 = PhysicalConnectorType' "RJ45_2"++pattern PhysicalConnectorType_SFP_PLUS :: PhysicalConnectorType+pattern PhysicalConnectorType_SFP_PLUS = PhysicalConnectorType' "SFP_PLUS"++pattern PhysicalConnectorType_WIFI :: PhysicalConnectorType+pattern PhysicalConnectorType_WIFI = PhysicalConnectorType' "WIFI"++{-# COMPLETE+ PhysicalConnectorType_QSFP,+ PhysicalConnectorType_RJ45,+ PhysicalConnectorType_RJ45_2,+ PhysicalConnectorType_SFP_PLUS,+ PhysicalConnectorType_WIFI,+ PhysicalConnectorType'+ #-}
+ gen/Amazonka/SnowDeviceManagement/Types/PhysicalNetworkInterface.hs view
@@ -0,0 +1,147 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.PhysicalNetworkInterface+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.PhysicalNetworkInterface where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import Amazonka.SnowDeviceManagement.Types.IpAddressAssignment+import Amazonka.SnowDeviceManagement.Types.PhysicalConnectorType++-- | The details about the physical network interface for the device.+--+-- /See:/ 'newPhysicalNetworkInterface' smart constructor.+data PhysicalNetworkInterface = PhysicalNetworkInterface'+ { -- | The default gateway of the device.+ defaultGateway :: Prelude.Maybe Prelude.Text,+ -- | The IP address of the device.+ ipAddress :: Prelude.Maybe Prelude.Text,+ -- | A value that describes whether the IP address is dynamic or persistent.+ ipAddressAssignment :: Prelude.Maybe IpAddressAssignment,+ -- | The MAC address of the device.+ macAddress :: Prelude.Maybe Prelude.Text,+ -- | The netmask used to divide the IP address into subnets.+ netmask :: Prelude.Maybe Prelude.Text,+ -- | The physical connector type.+ physicalConnectorType :: Prelude.Maybe PhysicalConnectorType,+ -- | The physical network interface ID.+ physicalNetworkInterfaceId :: Prelude.Maybe Prelude.Text+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'PhysicalNetworkInterface' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'defaultGateway', 'physicalNetworkInterface_defaultGateway' - The default gateway of the device.+--+-- 'ipAddress', 'physicalNetworkInterface_ipAddress' - The IP address of the device.+--+-- 'ipAddressAssignment', 'physicalNetworkInterface_ipAddressAssignment' - A value that describes whether the IP address is dynamic or persistent.+--+-- 'macAddress', 'physicalNetworkInterface_macAddress' - The MAC address of the device.+--+-- 'netmask', 'physicalNetworkInterface_netmask' - The netmask used to divide the IP address into subnets.+--+-- 'physicalConnectorType', 'physicalNetworkInterface_physicalConnectorType' - The physical connector type.+--+-- 'physicalNetworkInterfaceId', 'physicalNetworkInterface_physicalNetworkInterfaceId' - The physical network interface ID.+newPhysicalNetworkInterface ::+ PhysicalNetworkInterface+newPhysicalNetworkInterface =+ PhysicalNetworkInterface'+ { defaultGateway =+ Prelude.Nothing,+ ipAddress = Prelude.Nothing,+ ipAddressAssignment = Prelude.Nothing,+ macAddress = Prelude.Nothing,+ netmask = Prelude.Nothing,+ physicalConnectorType = Prelude.Nothing,+ physicalNetworkInterfaceId = Prelude.Nothing+ }++-- | The default gateway of the device.+physicalNetworkInterface_defaultGateway :: Lens.Lens' PhysicalNetworkInterface (Prelude.Maybe Prelude.Text)+physicalNetworkInterface_defaultGateway = Lens.lens (\PhysicalNetworkInterface' {defaultGateway} -> defaultGateway) (\s@PhysicalNetworkInterface' {} a -> s {defaultGateway = a} :: PhysicalNetworkInterface)++-- | The IP address of the device.+physicalNetworkInterface_ipAddress :: Lens.Lens' PhysicalNetworkInterface (Prelude.Maybe Prelude.Text)+physicalNetworkInterface_ipAddress = Lens.lens (\PhysicalNetworkInterface' {ipAddress} -> ipAddress) (\s@PhysicalNetworkInterface' {} a -> s {ipAddress = a} :: PhysicalNetworkInterface)++-- | A value that describes whether the IP address is dynamic or persistent.+physicalNetworkInterface_ipAddressAssignment :: Lens.Lens' PhysicalNetworkInterface (Prelude.Maybe IpAddressAssignment)+physicalNetworkInterface_ipAddressAssignment = Lens.lens (\PhysicalNetworkInterface' {ipAddressAssignment} -> ipAddressAssignment) (\s@PhysicalNetworkInterface' {} a -> s {ipAddressAssignment = a} :: PhysicalNetworkInterface)++-- | The MAC address of the device.+physicalNetworkInterface_macAddress :: Lens.Lens' PhysicalNetworkInterface (Prelude.Maybe Prelude.Text)+physicalNetworkInterface_macAddress = Lens.lens (\PhysicalNetworkInterface' {macAddress} -> macAddress) (\s@PhysicalNetworkInterface' {} a -> s {macAddress = a} :: PhysicalNetworkInterface)++-- | The netmask used to divide the IP address into subnets.+physicalNetworkInterface_netmask :: Lens.Lens' PhysicalNetworkInterface (Prelude.Maybe Prelude.Text)+physicalNetworkInterface_netmask = Lens.lens (\PhysicalNetworkInterface' {netmask} -> netmask) (\s@PhysicalNetworkInterface' {} a -> s {netmask = a} :: PhysicalNetworkInterface)++-- | The physical connector type.+physicalNetworkInterface_physicalConnectorType :: Lens.Lens' PhysicalNetworkInterface (Prelude.Maybe PhysicalConnectorType)+physicalNetworkInterface_physicalConnectorType = Lens.lens (\PhysicalNetworkInterface' {physicalConnectorType} -> physicalConnectorType) (\s@PhysicalNetworkInterface' {} a -> s {physicalConnectorType = a} :: PhysicalNetworkInterface)++-- | The physical network interface ID.+physicalNetworkInterface_physicalNetworkInterfaceId :: Lens.Lens' PhysicalNetworkInterface (Prelude.Maybe Prelude.Text)+physicalNetworkInterface_physicalNetworkInterfaceId = Lens.lens (\PhysicalNetworkInterface' {physicalNetworkInterfaceId} -> physicalNetworkInterfaceId) (\s@PhysicalNetworkInterface' {} a -> s {physicalNetworkInterfaceId = a} :: PhysicalNetworkInterface)++instance Data.FromJSON PhysicalNetworkInterface where+ parseJSON =+ Data.withObject+ "PhysicalNetworkInterface"+ ( \x ->+ PhysicalNetworkInterface'+ Prelude.<$> (x Data..:? "defaultGateway")+ Prelude.<*> (x Data..:? "ipAddress")+ Prelude.<*> (x Data..:? "ipAddressAssignment")+ Prelude.<*> (x Data..:? "macAddress")+ Prelude.<*> (x Data..:? "netmask")+ Prelude.<*> (x Data..:? "physicalConnectorType")+ Prelude.<*> (x Data..:? "physicalNetworkInterfaceId")+ )++instance Prelude.Hashable PhysicalNetworkInterface where+ hashWithSalt _salt PhysicalNetworkInterface' {..} =+ _salt+ `Prelude.hashWithSalt` defaultGateway+ `Prelude.hashWithSalt` ipAddress+ `Prelude.hashWithSalt` ipAddressAssignment+ `Prelude.hashWithSalt` macAddress+ `Prelude.hashWithSalt` netmask+ `Prelude.hashWithSalt` physicalConnectorType+ `Prelude.hashWithSalt` physicalNetworkInterfaceId++instance Prelude.NFData PhysicalNetworkInterface where+ rnf PhysicalNetworkInterface' {..} =+ Prelude.rnf defaultGateway+ `Prelude.seq` Prelude.rnf ipAddress+ `Prelude.seq` Prelude.rnf ipAddressAssignment+ `Prelude.seq` Prelude.rnf macAddress+ `Prelude.seq` Prelude.rnf netmask+ `Prelude.seq` Prelude.rnf physicalConnectorType+ `Prelude.seq` Prelude.rnf physicalNetworkInterfaceId
+ gen/Amazonka/SnowDeviceManagement/Types/Reboot.hs view
@@ -0,0 +1,51 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.Reboot+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.Reboot where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude++-- | A structure used to reboot the device.+--+-- /See:/ 'newReboot' smart constructor.+data Reboot = Reboot'+ {+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'Reboot' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+newReboot ::+ Reboot+newReboot = Reboot'++instance Prelude.Hashable Reboot where+ hashWithSalt _salt _ =+ _salt `Prelude.hashWithSalt` ()++instance Prelude.NFData Reboot where+ rnf _ = ()++instance Data.ToJSON Reboot where+ toJSON = Prelude.const (Data.Object Prelude.mempty)
+ gen/Amazonka/SnowDeviceManagement/Types/ResourceSummary.hs view
@@ -0,0 +1,98 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.ResourceSummary+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.ResourceSummary where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude++-- | A summary of a resource available on the device.+--+-- /See:/ 'newResourceSummary' smart constructor.+data ResourceSummary = ResourceSummary'+ { -- | The Amazon Resource Name (ARN) of the resource.+ arn :: Prelude.Maybe Prelude.Text,+ -- | The ID of the resource.+ id :: Prelude.Maybe Prelude.Text,+ -- | The resource type.+ resourceType :: Prelude.Text+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'ResourceSummary' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'arn', 'resourceSummary_arn' - The Amazon Resource Name (ARN) of the resource.+--+-- 'id', 'resourceSummary_id' - The ID of the resource.+--+-- 'resourceType', 'resourceSummary_resourceType' - The resource type.+newResourceSummary ::+ -- | 'resourceType'+ Prelude.Text ->+ ResourceSummary+newResourceSummary pResourceType_ =+ ResourceSummary'+ { arn = Prelude.Nothing,+ id = Prelude.Nothing,+ resourceType = pResourceType_+ }++-- | The Amazon Resource Name (ARN) of the resource.+resourceSummary_arn :: Lens.Lens' ResourceSummary (Prelude.Maybe Prelude.Text)+resourceSummary_arn = Lens.lens (\ResourceSummary' {arn} -> arn) (\s@ResourceSummary' {} a -> s {arn = a} :: ResourceSummary)++-- | The ID of the resource.+resourceSummary_id :: Lens.Lens' ResourceSummary (Prelude.Maybe Prelude.Text)+resourceSummary_id = Lens.lens (\ResourceSummary' {id} -> id) (\s@ResourceSummary' {} a -> s {id = a} :: ResourceSummary)++-- | The resource type.+resourceSummary_resourceType :: Lens.Lens' ResourceSummary Prelude.Text+resourceSummary_resourceType = Lens.lens (\ResourceSummary' {resourceType} -> resourceType) (\s@ResourceSummary' {} a -> s {resourceType = a} :: ResourceSummary)++instance Data.FromJSON ResourceSummary where+ parseJSON =+ Data.withObject+ "ResourceSummary"+ ( \x ->+ ResourceSummary'+ Prelude.<$> (x Data..:? "arn")+ Prelude.<*> (x Data..:? "id")+ Prelude.<*> (x Data..: "resourceType")+ )++instance Prelude.Hashable ResourceSummary where+ hashWithSalt _salt ResourceSummary' {..} =+ _salt+ `Prelude.hashWithSalt` arn+ `Prelude.hashWithSalt` id+ `Prelude.hashWithSalt` resourceType++instance Prelude.NFData ResourceSummary where+ rnf ResourceSummary' {..} =+ Prelude.rnf arn+ `Prelude.seq` Prelude.rnf id+ `Prelude.seq` Prelude.rnf resourceType
+ gen/Amazonka/SnowDeviceManagement/Types/SecurityGroupIdentifier.hs view
@@ -0,0 +1,84 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.SecurityGroupIdentifier+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.SecurityGroupIdentifier where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude++-- | Information about the device\'s security group.+--+-- /See:/ 'newSecurityGroupIdentifier' smart constructor.+data SecurityGroupIdentifier = SecurityGroupIdentifier'+ { -- | The security group ID.+ groupId :: Prelude.Maybe Prelude.Text,+ -- | The security group name.+ groupName :: Prelude.Maybe Prelude.Text+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'SecurityGroupIdentifier' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'groupId', 'securityGroupIdentifier_groupId' - The security group ID.+--+-- 'groupName', 'securityGroupIdentifier_groupName' - The security group name.+newSecurityGroupIdentifier ::+ SecurityGroupIdentifier+newSecurityGroupIdentifier =+ SecurityGroupIdentifier'+ { groupId = Prelude.Nothing,+ groupName = Prelude.Nothing+ }++-- | The security group ID.+securityGroupIdentifier_groupId :: Lens.Lens' SecurityGroupIdentifier (Prelude.Maybe Prelude.Text)+securityGroupIdentifier_groupId = Lens.lens (\SecurityGroupIdentifier' {groupId} -> groupId) (\s@SecurityGroupIdentifier' {} a -> s {groupId = a} :: SecurityGroupIdentifier)++-- | The security group name.+securityGroupIdentifier_groupName :: Lens.Lens' SecurityGroupIdentifier (Prelude.Maybe Prelude.Text)+securityGroupIdentifier_groupName = Lens.lens (\SecurityGroupIdentifier' {groupName} -> groupName) (\s@SecurityGroupIdentifier' {} a -> s {groupName = a} :: SecurityGroupIdentifier)++instance Data.FromJSON SecurityGroupIdentifier where+ parseJSON =+ Data.withObject+ "SecurityGroupIdentifier"+ ( \x ->+ SecurityGroupIdentifier'+ Prelude.<$> (x Data..:? "groupId")+ Prelude.<*> (x Data..:? "groupName")+ )++instance Prelude.Hashable SecurityGroupIdentifier where+ hashWithSalt _salt SecurityGroupIdentifier' {..} =+ _salt+ `Prelude.hashWithSalt` groupId+ `Prelude.hashWithSalt` groupName++instance Prelude.NFData SecurityGroupIdentifier where+ rnf SecurityGroupIdentifier' {..} =+ Prelude.rnf groupId+ `Prelude.seq` Prelude.rnf groupName
+ gen/Amazonka/SnowDeviceManagement/Types/SoftwareInformation.hs view
@@ -0,0 +1,100 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.SoftwareInformation+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.SoftwareInformation where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude++-- | Information about the software on the device.+--+-- /See:/ 'newSoftwareInformation' smart constructor.+data SoftwareInformation = SoftwareInformation'+ { -- | The state of the software that is installed or that is being installed+ -- on the device.+ installState :: Prelude.Maybe Prelude.Text,+ -- | The version of the software currently installed on the device.+ installedVersion :: Prelude.Maybe Prelude.Text,+ -- | The version of the software being installed on the device.+ installingVersion :: Prelude.Maybe Prelude.Text+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'SoftwareInformation' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'installState', 'softwareInformation_installState' - The state of the software that is installed or that is being installed+-- on the device.+--+-- 'installedVersion', 'softwareInformation_installedVersion' - The version of the software currently installed on the device.+--+-- 'installingVersion', 'softwareInformation_installingVersion' - The version of the software being installed on the device.+newSoftwareInformation ::+ SoftwareInformation+newSoftwareInformation =+ SoftwareInformation'+ { installState =+ Prelude.Nothing,+ installedVersion = Prelude.Nothing,+ installingVersion = Prelude.Nothing+ }++-- | The state of the software that is installed or that is being installed+-- on the device.+softwareInformation_installState :: Lens.Lens' SoftwareInformation (Prelude.Maybe Prelude.Text)+softwareInformation_installState = Lens.lens (\SoftwareInformation' {installState} -> installState) (\s@SoftwareInformation' {} a -> s {installState = a} :: SoftwareInformation)++-- | The version of the software currently installed on the device.+softwareInformation_installedVersion :: Lens.Lens' SoftwareInformation (Prelude.Maybe Prelude.Text)+softwareInformation_installedVersion = Lens.lens (\SoftwareInformation' {installedVersion} -> installedVersion) (\s@SoftwareInformation' {} a -> s {installedVersion = a} :: SoftwareInformation)++-- | The version of the software being installed on the device.+softwareInformation_installingVersion :: Lens.Lens' SoftwareInformation (Prelude.Maybe Prelude.Text)+softwareInformation_installingVersion = Lens.lens (\SoftwareInformation' {installingVersion} -> installingVersion) (\s@SoftwareInformation' {} a -> s {installingVersion = a} :: SoftwareInformation)++instance Data.FromJSON SoftwareInformation where+ parseJSON =+ Data.withObject+ "SoftwareInformation"+ ( \x ->+ SoftwareInformation'+ Prelude.<$> (x Data..:? "installState")+ Prelude.<*> (x Data..:? "installedVersion")+ Prelude.<*> (x Data..:? "installingVersion")+ )++instance Prelude.Hashable SoftwareInformation where+ hashWithSalt _salt SoftwareInformation' {..} =+ _salt+ `Prelude.hashWithSalt` installState+ `Prelude.hashWithSalt` installedVersion+ `Prelude.hashWithSalt` installingVersion++instance Prelude.NFData SoftwareInformation where+ rnf SoftwareInformation' {..} =+ Prelude.rnf installState+ `Prelude.seq` Prelude.rnf installedVersion+ `Prelude.seq` Prelude.rnf installingVersion
+ gen/Amazonka/SnowDeviceManagement/Types/TaskState.hs view
@@ -0,0 +1,76 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DerivingStrategies #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE PatternSynonyms #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.TaskState+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.TaskState+ ( TaskState+ ( ..,+ TaskState_CANCELED,+ TaskState_COMPLETED,+ TaskState_IN_PROGRESS+ ),+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude++newtype TaskState = TaskState'+ { fromTaskState ::+ Data.Text+ }+ deriving stock+ ( Prelude.Show,+ Prelude.Read,+ Prelude.Eq,+ Prelude.Ord,+ Prelude.Generic+ )+ deriving newtype+ ( Prelude.Hashable,+ Prelude.NFData,+ Data.FromText,+ Data.ToText,+ Data.ToByteString,+ Data.ToLog,+ Data.ToHeader,+ Data.ToQuery,+ Data.FromJSON,+ Data.FromJSONKey,+ Data.ToJSON,+ Data.ToJSONKey,+ Data.FromXML,+ Data.ToXML+ )++pattern TaskState_CANCELED :: TaskState+pattern TaskState_CANCELED = TaskState' "CANCELED"++pattern TaskState_COMPLETED :: TaskState+pattern TaskState_COMPLETED = TaskState' "COMPLETED"++pattern TaskState_IN_PROGRESS :: TaskState+pattern TaskState_IN_PROGRESS = TaskState' "IN_PROGRESS"++{-# COMPLETE+ TaskState_CANCELED,+ TaskState_COMPLETED,+ TaskState_IN_PROGRESS,+ TaskState'+ #-}
+ gen/Amazonka/SnowDeviceManagement/Types/TaskSummary.hs view
@@ -0,0 +1,117 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.TaskSummary+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.TaskSummary where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import Amazonka.SnowDeviceManagement.Types.TaskState++-- | Information about the task assigned to one or many devices.+--+-- /See:/ 'newTaskSummary' smart constructor.+data TaskSummary = TaskSummary'+ { -- | The state of the task assigned to one or many devices.+ state :: Prelude.Maybe TaskState,+ -- | Optional metadata that you assign to a resource. You can use tags to+ -- categorize a resource in different ways, such as by purpose, owner, or+ -- environment.+ tags :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),+ -- | The Amazon Resource Name (ARN) of the task.+ taskArn :: Prelude.Maybe Prelude.Text,+ -- | The task ID.+ taskId :: Prelude.Text+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'TaskSummary' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'state', 'taskSummary_state' - The state of the task assigned to one or many devices.+--+-- 'tags', 'taskSummary_tags' - Optional metadata that you assign to a resource. You can use tags to+-- categorize a resource in different ways, such as by purpose, owner, or+-- environment.+--+-- 'taskArn', 'taskSummary_taskArn' - The Amazon Resource Name (ARN) of the task.+--+-- 'taskId', 'taskSummary_taskId' - The task ID.+newTaskSummary ::+ -- | 'taskId'+ Prelude.Text ->+ TaskSummary+newTaskSummary pTaskId_ =+ TaskSummary'+ { state = Prelude.Nothing,+ tags = Prelude.Nothing,+ taskArn = Prelude.Nothing,+ taskId = pTaskId_+ }++-- | The state of the task assigned to one or many devices.+taskSummary_state :: Lens.Lens' TaskSummary (Prelude.Maybe TaskState)+taskSummary_state = Lens.lens (\TaskSummary' {state} -> state) (\s@TaskSummary' {} a -> s {state = a} :: TaskSummary)++-- | Optional metadata that you assign to a resource. You can use tags to+-- categorize a resource in different ways, such as by purpose, owner, or+-- environment.+taskSummary_tags :: Lens.Lens' TaskSummary (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))+taskSummary_tags = Lens.lens (\TaskSummary' {tags} -> tags) (\s@TaskSummary' {} a -> s {tags = a} :: TaskSummary) Prelude.. Lens.mapping Lens.coerced++-- | The Amazon Resource Name (ARN) of the task.+taskSummary_taskArn :: Lens.Lens' TaskSummary (Prelude.Maybe Prelude.Text)+taskSummary_taskArn = Lens.lens (\TaskSummary' {taskArn} -> taskArn) (\s@TaskSummary' {} a -> s {taskArn = a} :: TaskSummary)++-- | The task ID.+taskSummary_taskId :: Lens.Lens' TaskSummary Prelude.Text+taskSummary_taskId = Lens.lens (\TaskSummary' {taskId} -> taskId) (\s@TaskSummary' {} a -> s {taskId = a} :: TaskSummary)++instance Data.FromJSON TaskSummary where+ parseJSON =+ Data.withObject+ "TaskSummary"+ ( \x ->+ TaskSummary'+ Prelude.<$> (x Data..:? "state")+ Prelude.<*> (x Data..:? "tags" Data..!= Prelude.mempty)+ Prelude.<*> (x Data..:? "taskArn")+ Prelude.<*> (x Data..: "taskId")+ )++instance Prelude.Hashable TaskSummary where+ hashWithSalt _salt TaskSummary' {..} =+ _salt+ `Prelude.hashWithSalt` state+ `Prelude.hashWithSalt` tags+ `Prelude.hashWithSalt` taskArn+ `Prelude.hashWithSalt` taskId++instance Prelude.NFData TaskSummary where+ rnf TaskSummary' {..} =+ Prelude.rnf state+ `Prelude.seq` Prelude.rnf tags+ `Prelude.seq` Prelude.rnf taskArn+ `Prelude.seq` Prelude.rnf taskId
+ gen/Amazonka/SnowDeviceManagement/Types/Unlock.hs view
@@ -0,0 +1,51 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.Unlock+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.Unlock where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude++-- | A structure used to unlock a device.+--+-- /See:/ 'newUnlock' smart constructor.+data Unlock = Unlock'+ {+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'Unlock' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+newUnlock ::+ Unlock+newUnlock = Unlock'++instance Prelude.Hashable Unlock where+ hashWithSalt _salt _ =+ _salt `Prelude.hashWithSalt` ()++instance Prelude.NFData Unlock where+ rnf _ = ()++instance Data.ToJSON Unlock where+ toJSON = Prelude.const (Data.Object Prelude.mempty)
+ gen/Amazonka/SnowDeviceManagement/Types/UnlockState.hs view
@@ -0,0 +1,76 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DerivingStrategies #-}+{-# LANGUAGE GeneralizedNewtypeDeriving #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE PatternSynonyms #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Types.UnlockState+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Types.UnlockState+ ( UnlockState+ ( ..,+ UnlockState_LOCKED,+ UnlockState_UNLOCKED,+ UnlockState_UNLOCKING+ ),+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude++newtype UnlockState = UnlockState'+ { fromUnlockState ::+ Data.Text+ }+ deriving stock+ ( Prelude.Show,+ Prelude.Read,+ Prelude.Eq,+ Prelude.Ord,+ Prelude.Generic+ )+ deriving newtype+ ( Prelude.Hashable,+ Prelude.NFData,+ Data.FromText,+ Data.ToText,+ Data.ToByteString,+ Data.ToLog,+ Data.ToHeader,+ Data.ToQuery,+ Data.FromJSON,+ Data.FromJSONKey,+ Data.ToJSON,+ Data.ToJSONKey,+ Data.FromXML,+ Data.ToXML+ )++pattern UnlockState_LOCKED :: UnlockState+pattern UnlockState_LOCKED = UnlockState' "LOCKED"++pattern UnlockState_UNLOCKED :: UnlockState+pattern UnlockState_UNLOCKED = UnlockState' "UNLOCKED"++pattern UnlockState_UNLOCKING :: UnlockState+pattern UnlockState_UNLOCKING = UnlockState' "UNLOCKING"++{-# COMPLETE+ UnlockState_LOCKED,+ UnlockState_UNLOCKED,+ UnlockState_UNLOCKING,+ UnlockState'+ #-}
+ gen/Amazonka/SnowDeviceManagement/UntagResource.hs view
@@ -0,0 +1,146 @@+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE NamedFieldPuns #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-binds #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.UntagResource+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Removes a tag from a device or task.+module Amazonka.SnowDeviceManagement.UntagResource+ ( -- * Creating a Request+ UntagResource (..),+ newUntagResource,++ -- * Request Lenses+ untagResource_resourceArn,+ untagResource_tagKeys,++ -- * Destructuring the Response+ UntagResourceResponse (..),+ newUntagResourceResponse,+ )+where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import qualified Amazonka.Request as Request+import qualified Amazonka.Response as Response+import Amazonka.SnowDeviceManagement.Types++-- | /See:/ 'newUntagResource' smart constructor.+data UntagResource = UntagResource'+ { -- | The Amazon Resource Name (ARN) of the device or task.+ resourceArn :: Prelude.Text,+ -- | Optional metadata that you assign to a resource. You can use tags to+ -- categorize a resource in different ways, such as by purpose, owner, or+ -- environment.+ tagKeys :: [Prelude.Text]+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'UntagResource' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+--+-- The following record fields are available, with the corresponding lenses provided+-- for backwards compatibility:+--+-- 'resourceArn', 'untagResource_resourceArn' - The Amazon Resource Name (ARN) of the device or task.+--+-- 'tagKeys', 'untagResource_tagKeys' - Optional metadata that you assign to a resource. You can use tags to+-- categorize a resource in different ways, such as by purpose, owner, or+-- environment.+newUntagResource ::+ -- | 'resourceArn'+ Prelude.Text ->+ UntagResource+newUntagResource pResourceArn_ =+ UntagResource'+ { resourceArn = pResourceArn_,+ tagKeys = Prelude.mempty+ }++-- | The Amazon Resource Name (ARN) of the device or task.+untagResource_resourceArn :: Lens.Lens' UntagResource Prelude.Text+untagResource_resourceArn = Lens.lens (\UntagResource' {resourceArn} -> resourceArn) (\s@UntagResource' {} a -> s {resourceArn = a} :: UntagResource)++-- | Optional metadata that you assign to a resource. You can use tags to+-- categorize a resource in different ways, such as by purpose, owner, or+-- environment.+untagResource_tagKeys :: Lens.Lens' UntagResource [Prelude.Text]+untagResource_tagKeys = Lens.lens (\UntagResource' {tagKeys} -> tagKeys) (\s@UntagResource' {} a -> s {tagKeys = a} :: UntagResource) Prelude.. Lens.coerced++instance Core.AWSRequest UntagResource where+ type+ AWSResponse UntagResource =+ UntagResourceResponse+ request overrides =+ Request.delete (overrides defaultService)+ response =+ Response.receiveNull UntagResourceResponse'++instance Prelude.Hashable UntagResource where+ hashWithSalt _salt UntagResource' {..} =+ _salt+ `Prelude.hashWithSalt` resourceArn+ `Prelude.hashWithSalt` tagKeys++instance Prelude.NFData UntagResource where+ rnf UntagResource' {..} =+ Prelude.rnf resourceArn+ `Prelude.seq` Prelude.rnf tagKeys++instance Data.ToHeaders UntagResource where+ toHeaders =+ Prelude.const+ ( Prelude.mconcat+ [ "Content-Type"+ Data.=# ( "application/x-amz-json-1.1" ::+ Prelude.ByteString+ )+ ]+ )++instance Data.ToPath UntagResource where+ toPath UntagResource' {..} =+ Prelude.mconcat ["/tags/", Data.toBS resourceArn]++instance Data.ToQuery UntagResource where+ toQuery UntagResource' {..} =+ Prelude.mconcat+ ["tagKeys" Data.=: Data.toQueryList "member" tagKeys]++-- | /See:/ 'newUntagResourceResponse' smart constructor.+data UntagResourceResponse = UntagResourceResponse'+ {+ }+ deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)++-- |+-- Create a value of 'UntagResourceResponse' with all optional fields omitted.+--+-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.+newUntagResourceResponse ::+ UntagResourceResponse+newUntagResourceResponse = UntagResourceResponse'++instance Prelude.NFData UntagResourceResponse where+ rnf _ = ()
+ gen/Amazonka/SnowDeviceManagement/Waiters.hs view
@@ -0,0 +1,24 @@+{-# LANGUAGE DisambiguateRecordFields #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Amazonka.SnowDeviceManagement.Waiters+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Amazonka.SnowDeviceManagement.Waiters where++import qualified Amazonka.Core as Core+import qualified Amazonka.Core.Lens.Internal as Lens+import qualified Amazonka.Data as Data+import qualified Amazonka.Prelude as Prelude+import Amazonka.SnowDeviceManagement.Lens+import Amazonka.SnowDeviceManagement.Types
+ src/.gitkeep view
+ test/Main.hs view
@@ -0,0 +1,23 @@+{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- |+-- Module : Main+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Main (main) where++import Test.Amazonka.SnowDeviceManagement+import Test.Amazonka.SnowDeviceManagement.Internal+import Test.Tasty++main :: IO ()+main =+ defaultMain $+ testGroup+ "SnowDeviceManagement"+ [ testGroup "tests" tests,+ testGroup "fixtures" fixtures+ ]
+ test/Test/Amazonka/Gen/SnowDeviceManagement.hs view
@@ -0,0 +1,298 @@+{-# OPTIONS_GHC -fno-warn-orphans #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module : Test.Amazonka.Gen.SnowDeviceManagement+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Test.Amazonka.Gen.SnowDeviceManagement where++import Amazonka.SnowDeviceManagement+import qualified Data.Proxy as Proxy+import Test.Amazonka.Fixture+import Test.Amazonka.Prelude+import Test.Amazonka.SnowDeviceManagement.Internal+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"+-- [ requestCancelTask $+-- newCancelTask+--+-- , requestCreateTask $+-- newCreateTask+--+-- , requestDescribeDevice $+-- newDescribeDevice+--+-- , requestDescribeDeviceEc2Instances $+-- newDescribeDeviceEc2Instances+--+-- , requestDescribeExecution $+-- newDescribeExecution+--+-- , requestDescribeTask $+-- newDescribeTask+--+-- , requestListDeviceResources $+-- newListDeviceResources+--+-- , requestListDevices $+-- newListDevices+--+-- , requestListExecutions $+-- newListExecutions+--+-- , requestListTagsForResource $+-- newListTagsForResource+--+-- , requestListTasks $+-- newListTasks+--+-- , requestTagResource $+-- newTagResource+--+-- , requestUntagResource $+-- newUntagResource+--+-- ]++-- , testGroup "response"+-- [ responseCancelTask $+-- newCancelTaskResponse+--+-- , responseCreateTask $+-- newCreateTaskResponse+--+-- , responseDescribeDevice $+-- newDescribeDeviceResponse+--+-- , responseDescribeDeviceEc2Instances $+-- newDescribeDeviceEc2InstancesResponse+--+-- , responseDescribeExecution $+-- newDescribeExecutionResponse+--+-- , responseDescribeTask $+-- newDescribeTaskResponse+--+-- , responseListDeviceResources $+-- newListDeviceResourcesResponse+--+-- , responseListDevices $+-- newListDevicesResponse+--+-- , responseListExecutions $+-- newListExecutionsResponse+--+-- , responseListTagsForResource $+-- newListTagsForResourceResponse+--+-- , responseListTasks $+-- newListTasksResponse+--+-- , responseTagResource $+-- newTagResourceResponse+--+-- , responseUntagResource $+-- newUntagResourceResponse+--+-- ]+-- ]++-- Requests++requestCancelTask :: CancelTask -> TestTree+requestCancelTask =+ req+ "CancelTask"+ "fixture/CancelTask.yaml"++requestCreateTask :: CreateTask -> TestTree+requestCreateTask =+ req+ "CreateTask"+ "fixture/CreateTask.yaml"++requestDescribeDevice :: DescribeDevice -> TestTree+requestDescribeDevice =+ req+ "DescribeDevice"+ "fixture/DescribeDevice.yaml"++requestDescribeDeviceEc2Instances :: DescribeDeviceEc2Instances -> TestTree+requestDescribeDeviceEc2Instances =+ req+ "DescribeDeviceEc2Instances"+ "fixture/DescribeDeviceEc2Instances.yaml"++requestDescribeExecution :: DescribeExecution -> TestTree+requestDescribeExecution =+ req+ "DescribeExecution"+ "fixture/DescribeExecution.yaml"++requestDescribeTask :: DescribeTask -> TestTree+requestDescribeTask =+ req+ "DescribeTask"+ "fixture/DescribeTask.yaml"++requestListDeviceResources :: ListDeviceResources -> TestTree+requestListDeviceResources =+ req+ "ListDeviceResources"+ "fixture/ListDeviceResources.yaml"++requestListDevices :: ListDevices -> TestTree+requestListDevices =+ req+ "ListDevices"+ "fixture/ListDevices.yaml"++requestListExecutions :: ListExecutions -> TestTree+requestListExecutions =+ req+ "ListExecutions"+ "fixture/ListExecutions.yaml"++requestListTagsForResource :: ListTagsForResource -> TestTree+requestListTagsForResource =+ req+ "ListTagsForResource"+ "fixture/ListTagsForResource.yaml"++requestListTasks :: ListTasks -> TestTree+requestListTasks =+ req+ "ListTasks"+ "fixture/ListTasks.yaml"++requestTagResource :: TagResource -> TestTree+requestTagResource =+ req+ "TagResource"+ "fixture/TagResource.yaml"++requestUntagResource :: UntagResource -> TestTree+requestUntagResource =+ req+ "UntagResource"+ "fixture/UntagResource.yaml"++-- Responses++responseCancelTask :: CancelTaskResponse -> TestTree+responseCancelTask =+ res+ "CancelTaskResponse"+ "fixture/CancelTaskResponse.proto"+ defaultService+ (Proxy.Proxy :: Proxy.Proxy CancelTask)++responseCreateTask :: CreateTaskResponse -> TestTree+responseCreateTask =+ res+ "CreateTaskResponse"+ "fixture/CreateTaskResponse.proto"+ defaultService+ (Proxy.Proxy :: Proxy.Proxy CreateTask)++responseDescribeDevice :: DescribeDeviceResponse -> TestTree+responseDescribeDevice =+ res+ "DescribeDeviceResponse"+ "fixture/DescribeDeviceResponse.proto"+ defaultService+ (Proxy.Proxy :: Proxy.Proxy DescribeDevice)++responseDescribeDeviceEc2Instances :: DescribeDeviceEc2InstancesResponse -> TestTree+responseDescribeDeviceEc2Instances =+ res+ "DescribeDeviceEc2InstancesResponse"+ "fixture/DescribeDeviceEc2InstancesResponse.proto"+ defaultService+ (Proxy.Proxy :: Proxy.Proxy DescribeDeviceEc2Instances)++responseDescribeExecution :: DescribeExecutionResponse -> TestTree+responseDescribeExecution =+ res+ "DescribeExecutionResponse"+ "fixture/DescribeExecutionResponse.proto"+ defaultService+ (Proxy.Proxy :: Proxy.Proxy DescribeExecution)++responseDescribeTask :: DescribeTaskResponse -> TestTree+responseDescribeTask =+ res+ "DescribeTaskResponse"+ "fixture/DescribeTaskResponse.proto"+ defaultService+ (Proxy.Proxy :: Proxy.Proxy DescribeTask)++responseListDeviceResources :: ListDeviceResourcesResponse -> TestTree+responseListDeviceResources =+ res+ "ListDeviceResourcesResponse"+ "fixture/ListDeviceResourcesResponse.proto"+ defaultService+ (Proxy.Proxy :: Proxy.Proxy ListDeviceResources)++responseListDevices :: ListDevicesResponse -> TestTree+responseListDevices =+ res+ "ListDevicesResponse"+ "fixture/ListDevicesResponse.proto"+ defaultService+ (Proxy.Proxy :: Proxy.Proxy ListDevices)++responseListExecutions :: ListExecutionsResponse -> TestTree+responseListExecutions =+ res+ "ListExecutionsResponse"+ "fixture/ListExecutionsResponse.proto"+ defaultService+ (Proxy.Proxy :: Proxy.Proxy ListExecutions)++responseListTagsForResource :: ListTagsForResourceResponse -> TestTree+responseListTagsForResource =+ res+ "ListTagsForResourceResponse"+ "fixture/ListTagsForResourceResponse.proto"+ defaultService+ (Proxy.Proxy :: Proxy.Proxy ListTagsForResource)++responseListTasks :: ListTasksResponse -> TestTree+responseListTasks =+ res+ "ListTasksResponse"+ "fixture/ListTasksResponse.proto"+ defaultService+ (Proxy.Proxy :: Proxy.Proxy ListTasks)++responseTagResource :: TagResourceResponse -> TestTree+responseTagResource =+ res+ "TagResourceResponse"+ "fixture/TagResourceResponse.proto"+ defaultService+ (Proxy.Proxy :: Proxy.Proxy TagResource)++responseUntagResource :: UntagResourceResponse -> TestTree+responseUntagResource =+ res+ "UntagResourceResponse"+ "fixture/UntagResourceResponse.proto"+ defaultService+ (Proxy.Proxy :: Proxy.Proxy UntagResource)
+ test/Test/Amazonka/SnowDeviceManagement.hs view
@@ -0,0 +1,20 @@+-- |+-- Module : Test.Amazonka.SnowDeviceManagement+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Test.Amazonka.SnowDeviceManagement+ ( tests,+ fixtures,+ )+where++import Test.Tasty (TestTree)++tests :: [TestTree]+tests = []++fixtures :: [TestTree]+fixtures = []
+ test/Test/Amazonka/SnowDeviceManagement/Internal.hs view
@@ -0,0 +1,8 @@+-- |+-- Module : Test.Amazonka.SnowDeviceManagement.Internal+-- Copyright : (c) 2013-2023 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Test.Amazonka.SnowDeviceManagement.Internal where