packages feed

amazonka-kinesis-video (empty) → 1.6.0

raw patch · 44 files changed

+3117/−0 lines, 44 filesdep +amazonka-coredep +amazonka-kinesis-videodep +amazonka-testsetup-changed

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

Files

+ LICENSE view
@@ -0,0 +1,367 @@+Mozilla Public License Version 2.0+==================================++1. Definitions+--------------++1.1. "Contributor"+    means each individual or legal entity that creates, contributes to+    the creation of, or owns Covered Software.++1.2. "Contributor Version"+    means the combination of the Contributions of others (if any) used+    by a Contributor and that particular Contributor's Contribution.++1.3. "Contribution"+    means Covered Software of a particular Contributor.++1.4. "Covered Software"+    means Source Code Form to which the initial Contributor has attached+    the notice in Exhibit A, the Executable Form of such Source Code+    Form, and Modifications of such Source Code Form, in each case+    including portions thereof.++1.5. "Incompatible With Secondary Licenses"+    means++    (a) that the initial Contributor has attached the notice described+        in Exhibit B to the Covered Software; or++    (b) that the Covered Software was made available under the terms of+        version 1.1 or earlier of the License, but not also under the+        terms of a Secondary License.++1.6. "Executable Form"+    means any form of the work other than Source Code Form.++1.7. "Larger Work"+    means a work that combines Covered Software with other material, in+    a separate file or files, that is not Covered Software.++1.8. "License"+    means this document.++1.9. "Licensable"+    means having the right to grant, to the maximum extent possible,+    whether at the time of the initial grant or subsequently, any and+    all of the rights conveyed by this License.++1.10. "Modifications"+    means any of the following:++    (a) any file in Source Code Form that results from an addition to,+        deletion from, or modification of the contents of Covered+        Software; or++    (b) any new file in Source Code Form that contains any Covered+        Software.++1.11. "Patent Claims" of a Contributor+    means any patent claim(s), including without limitation, method,+    process, and apparatus claims, in any patent Licensable by such+    Contributor that would be infringed, but for the grant of the+    License, by the making, using, selling, offering for sale, having+    made, import, or transfer of either its Contributions or its+    Contributor Version.++1.12. "Secondary License"+    means either the GNU General Public License, Version 2.0, the GNU+    Lesser General Public License, Version 2.1, the GNU Affero General+    Public License, Version 3.0, or any later versions of those+    licenses.++1.13. "Source Code Form"+    means the form of the work preferred for making modifications.++1.14. "You" (or "Your")+    means an individual or a legal entity exercising rights under this+    License. For legal entities, "You" includes any entity that+    controls, is controlled by, or is under common control with You. For+    purposes of this definition, "control" means (a) the power, direct+    or indirect, to cause the direction or management of such entity,+    whether by contract or otherwise, or (b) ownership of more than+    fifty percent (50%) of the outstanding shares or beneficial+    ownership of such entity.++2. License Grants and Conditions+--------------------------------++2.1. Grants++Each Contributor hereby grants You a world-wide, royalty-free,+non-exclusive license:++(a) under intellectual property rights (other than patent or trademark)+    Licensable by such Contributor to use, reproduce, make available,+    modify, display, perform, distribute, and otherwise exploit its+    Contributions, either on an unmodified basis, with Modifications, or+    as part of a Larger Work; and++(b) under Patent Claims of such Contributor to make, use, sell, offer+    for sale, have made, import, and otherwise transfer either its+    Contributions or its Contributor Version.++2.2. Effective Date++The licenses granted in Section 2.1 with respect to any Contribution+become effective for each Contribution on the date the Contributor first+distributes such Contribution.++2.3. Limitations on Grant Scope++The licenses granted in this Section 2 are the only rights granted under+this License. No additional rights or licenses will be implied from the+distribution or licensing of Covered Software under this License.+Notwithstanding Section 2.1(b) above, no patent license is granted by a+Contributor:++(a) for any code that a Contributor has removed from Covered Software;+    or++(b) for infringements caused by: (i) Your and any other third party's+    modifications of Covered Software, or (ii) the combination of its+    Contributions with other software (except as part of its Contributor+    Version); or++(c) under Patent Claims infringed by Covered Software in the absence of+    its Contributions.++This License does not grant any rights in the trademarks, service marks,+or logos of any Contributor (except as may be necessary to comply with+the notice requirements in Section 3.4).++2.4. Subsequent Licenses++No Contributor makes additional grants as a result of Your choice to+distribute the Covered Software under a subsequent version of this+License (see Section 10.2) or under the terms of a Secondary License (if+permitted under the terms of Section 3.3).++2.5. Representation++Each Contributor represents that the Contributor believes its+Contributions are its original creation(s) or it has sufficient rights+to grant the rights to its Contributions conveyed by this License.++2.6. Fair Use++This License is not intended to limit any rights You have under+applicable copyright doctrines of fair use, fair dealing, or other+equivalents.++2.7. Conditions++Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted+in Section 2.1.++3. Responsibilities+-------------------++3.1. Distribution of Source Form++All distribution of Covered Software in Source Code Form, including any+Modifications that You create or to which You contribute, must be under+the terms of this License. You must inform recipients that the Source+Code Form of the Covered Software is governed by the terms of this+License, and how they can obtain a copy of this License. You may not+attempt to alter or restrict the recipients' rights in the Source Code+Form.++3.2. Distribution of Executable Form++If You distribute Covered Software in Executable Form then:++(a) such Covered Software must also be made available in Source Code+    Form, as described in Section 3.1, and You must inform recipients of+    the Executable Form how they can obtain a copy of such Source Code+    Form by reasonable means in a timely manner, at a charge no more+    than the cost of distribution to the recipient; and++(b) You may distribute such Executable Form under the terms of this+    License, or sublicense it under different terms, provided that the+    license for the Executable Form does not attempt to limit or alter+    the recipients' rights in the Source Code Form under this License.++3.3. Distribution of a Larger Work++You may create and distribute a Larger Work under terms of Your choice,+provided that You also comply with the requirements of this License for+the Covered Software. If the Larger Work is a combination of Covered+Software with a work governed by one or more Secondary Licenses, and the+Covered Software is not Incompatible With Secondary Licenses, this+License permits You to additionally distribute such Covered Software+under the terms of such Secondary License(s), so that the recipient of+the Larger Work may, at their option, further distribute the Covered+Software under the terms of either this License or such Secondary+License(s).++3.4. Notices++You may not remove or alter the substance of any license notices+(including copyright notices, patent notices, disclaimers of warranty,+or limitations of liability) contained within the Source Code Form of+the Covered Software, except that You may alter any license notices to+the extent required to remedy known factual inaccuracies.++3.5. Application of Additional Terms++You may choose to offer, and to charge a fee for, warranty, support,+indemnity or liability obligations to one or more recipients of Covered+Software. However, You may do so only on Your own behalf, and not on+behalf of any Contributor. You must make it absolutely clear that any+such warranty, support, indemnity, or liability obligation is offered by+You alone, and You hereby agree to indemnify every Contributor for any+liability incurred by such Contributor as a result of warranty, support,+indemnity or liability terms You offer. You may include additional+disclaimers of warranty and limitations of liability specific to any+jurisdiction.++4. Inability to Comply Due to Statute or Regulation+---------------------------------------------------++If it is impossible for You to comply with any of the terms of this+License with respect to some or all of the Covered Software due to+statute, judicial order, or regulation then You must: (a) comply with+the terms of this License to the maximum extent possible; and (b)+describe the limitations and the code they affect. Such description must+be placed in a text file included with all distributions of the Covered+Software under this License. Except to the extent prohibited by statute+or regulation, such description must be sufficiently detailed for a+recipient of ordinary skill to be able to understand it.++5. Termination+--------------++5.1. The rights granted under this License will terminate automatically+if You fail to comply with any of its terms. However, if You become+compliant, then the rights granted under this License from a particular+Contributor are reinstated (a) provisionally, unless and until such+Contributor explicitly and finally terminates Your grants, and (b) on an+ongoing basis, if such Contributor fails to notify You of the+non-compliance by some reasonable means prior to 60 days after You have+come back into compliance. Moreover, Your grants from a particular+Contributor are reinstated on an ongoing basis if such Contributor+notifies You of the non-compliance by some reasonable means, this is the+first time You have received notice of non-compliance with this License+from such Contributor, and You become compliant prior to 30 days after+Your receipt of the notice.++5.2. If You initiate litigation against any entity by asserting a patent+infringement claim (excluding declaratory judgment actions,+counter-claims, and cross-claims) alleging that a Contributor Version+directly or indirectly infringes any patent, then the rights granted to+You by any and all Contributors for the Covered Software under Section+2.1 of this License shall terminate.++5.3. In the event of termination under Sections 5.1 or 5.2 above, all+end user license agreements (excluding distributors and resellers) which+have been validly granted by You or Your distributors under this License+prior to termination shall survive termination.++************************************************************************+*                                                                      *+*  6. Disclaimer of Warranty                                           *+*  -------------------------                                           *+*                                                                      *+*  Covered Software is provided under this License on an "as is"       *+*  basis, without warranty of any kind, either expressed, implied, or  *+*  statutory, including, without limitation, warranties that the       *+*  Covered Software is free of defects, merchantable, fit for a        *+*  particular purpose or non-infringing. The entire risk as to the     *+*  quality and performance of the Covered Software is with You.        *+*  Should any Covered Software prove defective in any respect, You     *+*  (not any Contributor) assume the cost of any necessary servicing,   *+*  repair, or correction. This disclaimer of warranty constitutes an   *+*  essential part of this License. No use of any Covered Software is   *+*  authorized under this License except under this disclaimer.         *+*                                                                      *+************************************************************************++************************************************************************+*                                                                      *+*  7. Limitation of Liability                                          *+*  --------------------------                                          *+*                                                                      *+*  Under no circumstances and under no legal theory, whether tort      *+*  (including negligence), contract, or otherwise, shall any           *+*  Contributor, or anyone who distributes Covered Software as          *+*  permitted above, be liable to You for any direct, indirect,         *+*  special, incidental, or consequential damages of any character      *+*  including, without limitation, damages for lost profits, loss of    *+*  goodwill, work stoppage, computer failure or malfunction, or any    *+*  and all other commercial damages or losses, even if such party      *+*  shall have been informed of the possibility of such damages. This   *+*  limitation of liability shall not apply to liability for death or   *+*  personal injury resulting from such party's negligence to the       *+*  extent applicable law prohibits such limitation. Some               *+*  jurisdictions do not allow the exclusion or limitation of           *+*  incidental or consequential damages, so this exclusion and          *+*  limitation may not apply to You.                                    *+*                                                                      *+************************************************************************++8. Litigation+-------------++Any litigation relating to this License may be brought only in the+courts of a jurisdiction where the defendant maintains its principal+place of business and such litigation shall be governed by laws of that+jurisdiction, without reference to its conflict-of-law provisions.+Nothing in this Section shall prevent a party's ability to bring+cross-claims or counter-claims.++9. Miscellaneous+----------------++This License represents the complete agreement concerning the subject+matter hereof. If any provision of this License is held to be+unenforceable, such provision shall be reformed only to the extent+necessary to make it enforceable. Any law or regulation which provides+that the language of a contract shall be construed against the drafter+shall not be used to construe this License against a Contributor.++10. Versions of the License+---------------------------++10.1. New Versions++Mozilla Foundation is the license steward. Except as provided in Section+10.3, no one other than the license steward has the right to modify or+publish new versions of this License. Each version will be given a+distinguishing version number.++10.2. Effect of New Versions++You may distribute the Covered Software under the terms of the version+of the License under which You originally received the Covered Software,+or under the terms of any subsequent version published by the license+steward.++10.3. Modified Versions++If you create software not governed by this License, and you want to+create a new license for such software, you may create and use a+modified version of this License if you rename the license and remove+any references to the name of the license steward (except to note that+such modified license differs from this License).++10.4. Distributing Source Code Form that is Incompatible With Secondary+Licenses++If You choose to distribute Source Code Form that is Incompatible With+Secondary Licenses under the terms of this version of the License, the+notice described in Exhibit B of this License must be attached.++Exhibit A - Source Code Form License Notice+-------------------------------------------++  This Source Code Form is subject to the terms of the Mozilla Public+  License, v. 2.0. If a copy of the MPL was not distributed with this+  file, You can obtain one at http://mozilla.org/MPL/2.0/.++If it is not possible or desirable to put the notice in a particular+file, then You may include the notice in a location (such as a LICENSE+file in a relevant directory) where a recipient would be likely to look+for such a notice.++You may add additional accurate notices of copyright ownership.
+ README.md view
@@ -0,0 +1,45 @@+# Amazon Kinesis Video Streams SDK++* [Version](#version)+* [Description](#description)+* [Contribute](#contribute)+* [Licence](#licence)+++## Version++`1.6.0`+++## Description++Documentation is available via [Hackage](http://hackage.haskell.org/package/amazonka-kinesis-video)+and the [AWS API Reference](https://aws.amazon.com/documentation/).++The types from this library are intended to be used with [amazonka](http://hackage.haskell.org/package/amazonka),+which provides mechanisms for specifying AuthN/AuthZ information, sending requests,+and receiving responses.++Lenses are used for constructing and manipulating types,+due to the depth of nesting of AWS types and transparency regarding+de/serialisation into more palatable Haskell values.+The provided lenses should be compatible with any of the major lens libraries+[lens](http://hackage.haskell.org/package/lens) or [lens-family-core](http://hackage.haskell.org/package/lens-family-core).++See [Network.AWS.KinesisVideo](http://hackage.haskell.org/package/amazonka-kinesis-video/docs/Network-AWS-KinesisVideo.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-kinesis-video` is released under the [Mozilla Public License Version 2.0](http://www.mozilla.org/MPL/).++Parts of the code are derived from AWS service descriptions, licensed under Apache 2.0.+Source files subject to this contain an additional licensing clause in their header.
+ Setup.hs view
@@ -0,0 +1,2 @@+import           Distribution.Simple+main = defaultMain
+ amazonka-kinesis-video.cabal view
@@ -0,0 +1,95 @@+name:                  amazonka-kinesis-video+version:               1.6.0+synopsis:              Amazon Kinesis Video Streams SDK.+homepage:              https://github.com/brendanhay/amazonka+bug-reports:           https://github.com/brendanhay/amazonka/issues+license:               MPL-2.0+license-file:          LICENSE+author:                Brendan Hay+maintainer:            Brendan Hay <brendan.g.hay+amazonka@gmail.com>+copyright:             Copyright (c) 2013-2018 Brendan Hay+category:              Network, AWS, Cloud, Distributed Computing+build-type:            Simple+cabal-version:         >= 1.10+extra-source-files:    README.md fixture/*.yaml fixture/*.proto src/.gitkeep+description:+    The types from this library are intended to be used with+    <http://hackage.haskell.org/package/amazonka amazonka>, which provides+    mechanisms for specifying AuthN/AuthZ information, sending requests,+    and receiving responses.+    .+    Lenses are used for constructing and manipulating types,+    due to the depth of nesting of AWS types and transparency regarding+    de/serialisation into more palatable Haskell values.+    The provided lenses should be compatible with any of the major lens libraries+    such as <http://hackage.haskell.org/package/lens lens> or+    <http://hackage.haskell.org/package/lens-family-core lens-family-core>.+    .+    See "Network.AWS.KinesisVideo" or <https://aws.amazon.com/documentation/ the AWS documentation>+    to get started.++source-repository head+    type:              git+    location:          git://github.com/brendanhay/amazonka.git+    subdir:            amazonka-kinesis-video++library+    default-language:  Haskell2010+    hs-source-dirs:    src gen++    ghc-options:+        -Wall+        -fwarn-incomplete-uni-patterns+        -fwarn-incomplete-record-updates+        -funbox-strict-fields++    exposed-modules:+          Network.AWS.KinesisVideo+        , Network.AWS.KinesisVideo.CreateStream+        , Network.AWS.KinesisVideo.DeleteStream+        , Network.AWS.KinesisVideo.DescribeStream+        , Network.AWS.KinesisVideo.GetDataEndpoint+        , Network.AWS.KinesisVideo.ListStreams+        , Network.AWS.KinesisVideo.ListTagsForStream+        , Network.AWS.KinesisVideo.TagStream+        , Network.AWS.KinesisVideo.Types+        , Network.AWS.KinesisVideo.UntagStream+        , Network.AWS.KinesisVideo.UpdateDataRetention+        , Network.AWS.KinesisVideo.UpdateStream+        , Network.AWS.KinesisVideo.Waiters++    other-modules:+          Network.AWS.KinesisVideo.Types.Product+        , Network.AWS.KinesisVideo.Types.Sum++    build-depends:+          amazonka-core == 1.6.0.*+        , base          >= 4.7     && < 5++test-suite amazonka-kinesis-video-test+    type:              exitcode-stdio-1.0+    default-language:  Haskell2010+    hs-source-dirs:    test+    main-is:           Main.hs++    ghc-options:       -Wall -threaded++    -- This section is encoded by the template and any modules added by+    -- hand outside these namespaces will not correctly be added to the+    -- distribution package.+    other-modules:+          Test.AWS.KinesisVideo+        , Test.AWS.Gen.KinesisVideo+        , Test.AWS.KinesisVideo.Internal++    build-depends:+          amazonka-core == 1.6.0.*+        , amazonka-test == 1.6.0.*+        , amazonka-kinesis-video+        , base+        , bytestring+        , tasty+        , tasty-hunit+        , text+        , time+        , unordered-containers
+ fixture/CreateStream.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/kinesisvideo/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  kinesisvideo.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/CreateStreamResponse.proto view
+ fixture/DeleteStream.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/kinesisvideo/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  kinesisvideo.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/DeleteStreamResponse.proto view
+ fixture/DescribeStream.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/kinesisvideo/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  kinesisvideo.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/DescribeStreamResponse.proto view
+ fixture/GetDataEndpoint.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/kinesisvideo/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  kinesisvideo.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/GetDataEndpointResponse.proto view
+ fixture/ListStreams.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/kinesisvideo/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  kinesisvideo.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/ListStreamsResponse.proto view
+ fixture/ListTagsForStream.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/kinesisvideo/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  kinesisvideo.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/ListTagsForStreamResponse.proto view
+ fixture/TagStream.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/kinesisvideo/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  kinesisvideo.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/TagStreamResponse.proto view
+ fixture/UntagStream.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/kinesisvideo/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  kinesisvideo.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/UntagStreamResponse.proto view
+ fixture/UpdateDataRetention.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/kinesisvideo/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  kinesisvideo.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/UpdateDataRetentionResponse.proto view
+ fixture/UpdateStream.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/kinesisvideo/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  kinesisvideo.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/UpdateStreamResponse.proto view
+ gen/Network/AWS/KinesisVideo.hs view
@@ -0,0 +1,169 @@+{-# OPTIONS_GHC -fno-warn-unused-imports    #-}+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.KinesisVideo+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+--+--+--+module Network.AWS.KinesisVideo+    (+    -- * Service Configuration+      kinesisVideo++    -- * Errors+    -- $errors++    -- ** InvalidArgumentException+    , _InvalidArgumentException++    -- ** TagsPerResourceExceededLimitException+    , _TagsPerResourceExceededLimitException++    -- ** NotAuthorizedException+    , _NotAuthorizedException++    -- ** ClientLimitExceededException+    , _ClientLimitExceededException++    -- ** InvalidDeviceException+    , _InvalidDeviceException++    -- ** VersionMismatchException+    , _VersionMismatchException++    -- ** AccountStreamLimitExceededException+    , _AccountStreamLimitExceededException++    -- ** InvalidResourceFormatException+    , _InvalidResourceFormatException++    -- ** DeviceStreamLimitExceededException+    , _DeviceStreamLimitExceededException++    -- ** ResourceNotFoundException+    , _ResourceNotFoundException++    -- ** ResourceInUseException+    , _ResourceInUseException++    -- * Waiters+    -- $waiters++    -- * Operations+    -- $operations++    -- ** UntagStream+    , module Network.AWS.KinesisVideo.UntagStream++    -- ** UpdateDataRetention+    , module Network.AWS.KinesisVideo.UpdateDataRetention++    -- ** GetDataEndpoint+    , module Network.AWS.KinesisVideo.GetDataEndpoint++    -- ** ListTagsForStream+    , module Network.AWS.KinesisVideo.ListTagsForStream++    -- ** UpdateStream+    , module Network.AWS.KinesisVideo.UpdateStream++    -- ** DeleteStream+    , module Network.AWS.KinesisVideo.DeleteStream++    -- ** ListStreams+    , module Network.AWS.KinesisVideo.ListStreams++    -- ** CreateStream+    , module Network.AWS.KinesisVideo.CreateStream++    -- ** TagStream+    , module Network.AWS.KinesisVideo.TagStream++    -- ** DescribeStream+    , module Network.AWS.KinesisVideo.DescribeStream++    -- * Types++    -- ** APIName+    , APIName (..)++    -- ** ComparisonOperator+    , ComparisonOperator (..)++    -- ** StreamStatus+    , StreamStatus (..)++    -- ** UpdateDataRetentionOperation+    , UpdateDataRetentionOperation (..)++    -- ** StreamInfo+    , StreamInfo+    , streamInfo+    , siCreationTime+    , siStatus+    , siMediaType+    , siDataRetentionInHours+    , siStreamARN+    , siKMSKeyId+    , siDeviceName+    , siVersion+    , siStreamName++    -- ** StreamNameCondition+    , StreamNameCondition+    , streamNameCondition+    , sncComparisonOperator+    , sncComparisonValue+    ) where++import Network.AWS.KinesisVideo.CreateStream+import Network.AWS.KinesisVideo.DeleteStream+import Network.AWS.KinesisVideo.DescribeStream+import Network.AWS.KinesisVideo.GetDataEndpoint+import Network.AWS.KinesisVideo.ListStreams+import Network.AWS.KinesisVideo.ListTagsForStream+import Network.AWS.KinesisVideo.TagStream+import Network.AWS.KinesisVideo.Types+import Network.AWS.KinesisVideo.UntagStream+import Network.AWS.KinesisVideo.UpdateDataRetention+import Network.AWS.KinesisVideo.UpdateStream+import Network.AWS.KinesisVideo.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 'KinesisVideo'.+-}++{- $operations+Some AWS operations return results that are incomplete and require subsequent+requests in order to obtain the entire result set. The process of sending+subsequent requests to continue where a previous request left off is called+pagination. For example, the 'ListObjects' operation of Amazon S3 returns up to+1000 objects at a time, and you must send subsequent requests with the+appropriate Marker in order to retrieve the next page of results.++Operations that have an 'AWSPager' instance can transparently perform subsequent+requests, correctly setting Markers and other request facets to iterate through+the entire result set of a truncated API operation. Operations which support+this have an additional note in the documentation.++Many operations have the ability to filter results on the server side. See the+individual operation parameters for details.+-}++{- $waiters+Waiters poll by repeatedly sending a request until some remote success condition+configured by the 'Wait' specification is fulfilled. The 'Wait' specification+determines how many attempts should be made, in addition to delay and retry strategies.+-}
+ gen/Network/AWS/KinesisVideo/CreateStream.hs view
@@ -0,0 +1,178 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.KinesisVideo.CreateStream+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Creates a new Kinesis video stream.+--+--+-- When you create a new stream, Kinesis Video Streams assigns it a version number. When you change the stream's metadata, Kinesis Video Streams updates the version.+--+-- @CreateStream@ is an asynchronous operation.+--+-- For information about how the service works, see <http://docs.aws.amazon.com/kinesisvideostreams/latest/dg/how-it-works.html How it Works> .+--+-- You must have permissions for the @KinesisVideo:CreateStream@ action.+--+module Network.AWS.KinesisVideo.CreateStream+    (+    -- * Creating a Request+      createStream+    , CreateStream+    -- * Request Lenses+    , csMediaType+    , csDataRetentionInHours+    , csKMSKeyId+    , csDeviceName+    , csStreamName++    -- * Destructuring the Response+    , createStreamResponse+    , CreateStreamResponse+    -- * Response Lenses+    , csrsStreamARN+    , csrsResponseStatus+    ) where++import Network.AWS.KinesisVideo.Types+import Network.AWS.KinesisVideo.Types.Product+import Network.AWS.Lens+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'createStream' smart constructor.+data CreateStream = CreateStream'+  { _csMediaType            :: !(Maybe Text)+  , _csDataRetentionInHours :: !(Maybe Nat)+  , _csKMSKeyId             :: !(Maybe Text)+  , _csDeviceName           :: !(Maybe Text)+  , _csStreamName           :: !Text+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'CreateStream' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'csMediaType' - The media type of the stream. Consumers of the stream can use this information when processing the stream. For more information about media types, see <http://www.iana.org/assignments/media-types/media-types.xhtml Media Types> . If you choose to specify the @MediaType@ , see <https://tools.ietf.org/html/rfc6838#section-4.2 Naming Requirements> for guidelines. To play video on the console, the media must be H.264 encoded, and you need to specify this video type in this parameter as @video/h264@ .  This parameter is optional; the default value is @null@ (or empty in JSON).+--+-- * 'csDataRetentionInHours' - The number of hours that you want to retain the data in the stream. Kinesis Video Streams retains the data in a data store that is associated with the stream. The default value is 0, indicating that the stream does not persist data.+--+-- * 'csKMSKeyId' - The ID of the AWS Key Management Service (AWS KMS) key that you want Kinesis Video Streams to use to encrypt stream data. If no key ID is specified, the default, Kinesis Video-managed key (@aws/kinesisvideo@ ) is used. For more information, see <http://docs.aws.amazon.com/kms/latest/APIReference/API_DescribeKey.html#API_DescribeKey_RequestParameters DescribeKey> .+--+-- * 'csDeviceName' - The name of the device that is writing to the stream.+--+-- * 'csStreamName' - A name for the stream that you are creating. The stream name is an identifier for the stream, and must be unique for each account and region.+createStream+    :: Text -- ^ 'csStreamName'+    -> CreateStream+createStream pStreamName_ =+  CreateStream'+    { _csMediaType = Nothing+    , _csDataRetentionInHours = Nothing+    , _csKMSKeyId = Nothing+    , _csDeviceName = Nothing+    , _csStreamName = pStreamName_+    }+++-- | The media type of the stream. Consumers of the stream can use this information when processing the stream. For more information about media types, see <http://www.iana.org/assignments/media-types/media-types.xhtml Media Types> . If you choose to specify the @MediaType@ , see <https://tools.ietf.org/html/rfc6838#section-4.2 Naming Requirements> for guidelines. To play video on the console, the media must be H.264 encoded, and you need to specify this video type in this parameter as @video/h264@ .  This parameter is optional; the default value is @null@ (or empty in JSON).+csMediaType :: Lens' CreateStream (Maybe Text)+csMediaType = lens _csMediaType (\ s a -> s{_csMediaType = a})++-- | The number of hours that you want to retain the data in the stream. Kinesis Video Streams retains the data in a data store that is associated with the stream. The default value is 0, indicating that the stream does not persist data.+csDataRetentionInHours :: Lens' CreateStream (Maybe Natural)+csDataRetentionInHours = lens _csDataRetentionInHours (\ s a -> s{_csDataRetentionInHours = a}) . mapping _Nat++-- | The ID of the AWS Key Management Service (AWS KMS) key that you want Kinesis Video Streams to use to encrypt stream data. If no key ID is specified, the default, Kinesis Video-managed key (@aws/kinesisvideo@ ) is used. For more information, see <http://docs.aws.amazon.com/kms/latest/APIReference/API_DescribeKey.html#API_DescribeKey_RequestParameters DescribeKey> .+csKMSKeyId :: Lens' CreateStream (Maybe Text)+csKMSKeyId = lens _csKMSKeyId (\ s a -> s{_csKMSKeyId = a})++-- | The name of the device that is writing to the stream.+csDeviceName :: Lens' CreateStream (Maybe Text)+csDeviceName = lens _csDeviceName (\ s a -> s{_csDeviceName = a})++-- | A name for the stream that you are creating. The stream name is an identifier for the stream, and must be unique for each account and region.+csStreamName :: Lens' CreateStream Text+csStreamName = lens _csStreamName (\ s a -> s{_csStreamName = a})++instance AWSRequest CreateStream where+        type Rs CreateStream = CreateStreamResponse+        request = postJSON kinesisVideo+        response+          = receiveJSON+              (\ s h x ->+                 CreateStreamResponse' <$>+                   (x .?> "StreamARN") <*> (pure (fromEnum s)))++instance Hashable CreateStream where++instance NFData CreateStream where++instance ToHeaders CreateStream where+        toHeaders = const mempty++instance ToJSON CreateStream where+        toJSON CreateStream'{..}+          = object+              (catMaybes+                 [("MediaType" .=) <$> _csMediaType,+                  ("DataRetentionInHours" .=) <$>+                    _csDataRetentionInHours,+                  ("KmsKeyId" .=) <$> _csKMSKeyId,+                  ("DeviceName" .=) <$> _csDeviceName,+                  Just ("StreamName" .= _csStreamName)])++instance ToPath CreateStream where+        toPath = const "/createStream"++instance ToQuery CreateStream where+        toQuery = const mempty++-- | /See:/ 'createStreamResponse' smart constructor.+data CreateStreamResponse = CreateStreamResponse'+  { _csrsStreamARN      :: !(Maybe Text)+  , _csrsResponseStatus :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'CreateStreamResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'csrsStreamARN' - The Amazon Resource Name (ARN) of the stream.+--+-- * 'csrsResponseStatus' - -- | The response status code.+createStreamResponse+    :: Int -- ^ 'csrsResponseStatus'+    -> CreateStreamResponse+createStreamResponse pResponseStatus_ =+  CreateStreamResponse'+    {_csrsStreamARN = Nothing, _csrsResponseStatus = pResponseStatus_}+++-- | The Amazon Resource Name (ARN) of the stream.+csrsStreamARN :: Lens' CreateStreamResponse (Maybe Text)+csrsStreamARN = lens _csrsStreamARN (\ s a -> s{_csrsStreamARN = a})++-- | -- | The response status code.+csrsResponseStatus :: Lens' CreateStreamResponse Int+csrsResponseStatus = lens _csrsResponseStatus (\ s a -> s{_csrsResponseStatus = a})++instance NFData CreateStreamResponse where
+ gen/Network/AWS/KinesisVideo/DeleteStream.hs view
@@ -0,0 +1,134 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.KinesisVideo.DeleteStream+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Deletes a Kinesis video stream and the data contained in the stream.+--+--+-- This method marks the stream for deletion, and makes the data in the stream inaccessible immediately.+--+--+--+-- To ensure that you have the latest version of the stream before deleting it, you can specify the stream version. Kinesis Video Streams assigns a version to each stream. When you update a stream, Kinesis Video Streams assigns a new version number. To get the latest stream version, use the @DescribeStream@ API.+--+-- This operation requires permission for the @KinesisVideo:DeleteStream@ action.+--+module Network.AWS.KinesisVideo.DeleteStream+    (+    -- * Creating a Request+      deleteStream+    , DeleteStream+    -- * Request Lenses+    , dsCurrentVersion+    , dsStreamARN++    -- * Destructuring the Response+    , deleteStreamResponse+    , DeleteStreamResponse+    -- * Response Lenses+    , dsrsResponseStatus+    ) where++import Network.AWS.KinesisVideo.Types+import Network.AWS.KinesisVideo.Types.Product+import Network.AWS.Lens+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'deleteStream' smart constructor.+data DeleteStream = DeleteStream'+  { _dsCurrentVersion :: !(Maybe Text)+  , _dsStreamARN      :: !Text+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DeleteStream' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'dsCurrentVersion' - Optional: The version of the stream that you want to delete.  Specify the version as a safeguard to ensure that your are deleting the correct stream. To get the stream version, use the @DescribeStream@ API. If not specified, only the @CreationTime@ is checked before deleting the stream.+--+-- * 'dsStreamARN' - The Amazon Resource Name (ARN) of the stream that you want to delete.+deleteStream+    :: Text -- ^ 'dsStreamARN'+    -> DeleteStream+deleteStream pStreamARN_ =+  DeleteStream' {_dsCurrentVersion = Nothing, _dsStreamARN = pStreamARN_}+++-- | Optional: The version of the stream that you want to delete.  Specify the version as a safeguard to ensure that your are deleting the correct stream. To get the stream version, use the @DescribeStream@ API. If not specified, only the @CreationTime@ is checked before deleting the stream.+dsCurrentVersion :: Lens' DeleteStream (Maybe Text)+dsCurrentVersion = lens _dsCurrentVersion (\ s a -> s{_dsCurrentVersion = a})++-- | The Amazon Resource Name (ARN) of the stream that you want to delete.+dsStreamARN :: Lens' DeleteStream Text+dsStreamARN = lens _dsStreamARN (\ s a -> s{_dsStreamARN = a})++instance AWSRequest DeleteStream where+        type Rs DeleteStream = DeleteStreamResponse+        request = postJSON kinesisVideo+        response+          = receiveEmpty+              (\ s h x ->+                 DeleteStreamResponse' <$> (pure (fromEnum s)))++instance Hashable DeleteStream where++instance NFData DeleteStream where++instance ToHeaders DeleteStream where+        toHeaders = const mempty++instance ToJSON DeleteStream where+        toJSON DeleteStream'{..}+          = object+              (catMaybes+                 [("CurrentVersion" .=) <$> _dsCurrentVersion,+                  Just ("StreamARN" .= _dsStreamARN)])++instance ToPath DeleteStream where+        toPath = const "/deleteStream"++instance ToQuery DeleteStream where+        toQuery = const mempty++-- | /See:/ 'deleteStreamResponse' smart constructor.+newtype DeleteStreamResponse = DeleteStreamResponse'+  { _dsrsResponseStatus :: Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DeleteStreamResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'dsrsResponseStatus' - -- | The response status code.+deleteStreamResponse+    :: Int -- ^ 'dsrsResponseStatus'+    -> DeleteStreamResponse+deleteStreamResponse pResponseStatus_ =+  DeleteStreamResponse' {_dsrsResponseStatus = pResponseStatus_}+++-- | -- | The response status code.+dsrsResponseStatus :: Lens' DeleteStreamResponse Int+dsrsResponseStatus = lens _dsrsResponseStatus (\ s a -> s{_dsrsResponseStatus = a})++instance NFData DeleteStreamResponse where
+ gen/Network/AWS/KinesisVideo/DescribeStream.hs view
@@ -0,0 +1,134 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.KinesisVideo.DescribeStream+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Returns the most current information about the specified stream. You must specify either the @StreamName@ or the @StreamARN@ .+--+--+module Network.AWS.KinesisVideo.DescribeStream+    (+    -- * Creating a Request+      describeStream+    , DescribeStream+    -- * Request Lenses+    , dStreamARN+    , dStreamName++    -- * Destructuring the Response+    , describeStreamResponse+    , DescribeStreamResponse+    -- * Response Lenses+    , drsStreamInfo+    , drsResponseStatus+    ) where++import Network.AWS.KinesisVideo.Types+import Network.AWS.KinesisVideo.Types.Product+import Network.AWS.Lens+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'describeStream' smart constructor.+data DescribeStream = DescribeStream'+  { _dStreamARN  :: !(Maybe Text)+  , _dStreamName :: !(Maybe Text)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DescribeStream' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'dStreamARN' - The Amazon Resource Name (ARN) of the stream.+--+-- * 'dStreamName' - The name of the stream.+describeStream+    :: DescribeStream+describeStream = DescribeStream' {_dStreamARN = Nothing, _dStreamName = Nothing}+++-- | The Amazon Resource Name (ARN) of the stream.+dStreamARN :: Lens' DescribeStream (Maybe Text)+dStreamARN = lens _dStreamARN (\ s a -> s{_dStreamARN = a})++-- | The name of the stream.+dStreamName :: Lens' DescribeStream (Maybe Text)+dStreamName = lens _dStreamName (\ s a -> s{_dStreamName = a})++instance AWSRequest DescribeStream where+        type Rs DescribeStream = DescribeStreamResponse+        request = postJSON kinesisVideo+        response+          = receiveJSON+              (\ s h x ->+                 DescribeStreamResponse' <$>+                   (x .?> "StreamInfo") <*> (pure (fromEnum s)))++instance Hashable DescribeStream where++instance NFData DescribeStream where++instance ToHeaders DescribeStream where+        toHeaders = const mempty++instance ToJSON DescribeStream where+        toJSON DescribeStream'{..}+          = object+              (catMaybes+                 [("StreamARN" .=) <$> _dStreamARN,+                  ("StreamName" .=) <$> _dStreamName])++instance ToPath DescribeStream where+        toPath = const "/describeStream"++instance ToQuery DescribeStream where+        toQuery = const mempty++-- | /See:/ 'describeStreamResponse' smart constructor.+data DescribeStreamResponse = DescribeStreamResponse'+  { _drsStreamInfo     :: !(Maybe StreamInfo)+  , _drsResponseStatus :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DescribeStreamResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'drsStreamInfo' - An object that describes the stream.+--+-- * 'drsResponseStatus' - -- | The response status code.+describeStreamResponse+    :: Int -- ^ 'drsResponseStatus'+    -> DescribeStreamResponse+describeStreamResponse pResponseStatus_ =+  DescribeStreamResponse'+    {_drsStreamInfo = Nothing, _drsResponseStatus = pResponseStatus_}+++-- | An object that describes the stream.+drsStreamInfo :: Lens' DescribeStreamResponse (Maybe StreamInfo)+drsStreamInfo = lens _drsStreamInfo (\ s a -> s{_drsStreamInfo = a})++-- | -- | The response status code.+drsResponseStatus :: Lens' DescribeStreamResponse Int+drsResponseStatus = lens _drsResponseStatus (\ s a -> s{_drsResponseStatus = a})++instance NFData DescribeStreamResponse where
+ gen/Network/AWS/KinesisVideo/GetDataEndpoint.hs view
@@ -0,0 +1,148 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.KinesisVideo.GetDataEndpoint+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Gets an endpoint for a specified stream for either reading or writing. Use this endpoint in your application to read from the specified stream (using the @GetMedia@ or @GetMediaForFragmentList@ operations) or write to it (using the @PutMedia@ operation).+--+--+-- In the request, specify the stream either by @StreamName@ or @StreamARN@ .+--+module Network.AWS.KinesisVideo.GetDataEndpoint+    (+    -- * Creating a Request+      getDataEndpoint+    , GetDataEndpoint+    -- * Request Lenses+    , gdeStreamARN+    , gdeStreamName+    , gdeAPIName++    -- * Destructuring the Response+    , getDataEndpointResponse+    , GetDataEndpointResponse+    -- * Response Lenses+    , gdersDataEndpoint+    , gdersResponseStatus+    ) where++import Network.AWS.KinesisVideo.Types+import Network.AWS.KinesisVideo.Types.Product+import Network.AWS.Lens+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'getDataEndpoint' smart constructor.+data GetDataEndpoint = GetDataEndpoint'+  { _gdeStreamARN  :: !(Maybe Text)+  , _gdeStreamName :: !(Maybe Text)+  , _gdeAPIName    :: !APIName+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'GetDataEndpoint' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'gdeStreamARN' - The Amazon Resource Name (ARN) of the stream that you want to get the endpoint for. You must specify either this parameter or a @StreamName@ in the request.+--+-- * 'gdeStreamName' - The name of the stream that you want to get the endpoint for. You must specify either this parameter or a @StreamARN@ in the request.+--+-- * 'gdeAPIName' - The name of the API action for which to get an endpoint.+getDataEndpoint+    :: APIName -- ^ 'gdeAPIName'+    -> GetDataEndpoint+getDataEndpoint pAPIName_ =+  GetDataEndpoint'+    {_gdeStreamARN = Nothing, _gdeStreamName = Nothing, _gdeAPIName = pAPIName_}+++-- | The Amazon Resource Name (ARN) of the stream that you want to get the endpoint for. You must specify either this parameter or a @StreamName@ in the request.+gdeStreamARN :: Lens' GetDataEndpoint (Maybe Text)+gdeStreamARN = lens _gdeStreamARN (\ s a -> s{_gdeStreamARN = a})++-- | The name of the stream that you want to get the endpoint for. You must specify either this parameter or a @StreamARN@ in the request.+gdeStreamName :: Lens' GetDataEndpoint (Maybe Text)+gdeStreamName = lens _gdeStreamName (\ s a -> s{_gdeStreamName = a})++-- | The name of the API action for which to get an endpoint.+gdeAPIName :: Lens' GetDataEndpoint APIName+gdeAPIName = lens _gdeAPIName (\ s a -> s{_gdeAPIName = a})++instance AWSRequest GetDataEndpoint where+        type Rs GetDataEndpoint = GetDataEndpointResponse+        request = postJSON kinesisVideo+        response+          = receiveJSON+              (\ s h x ->+                 GetDataEndpointResponse' <$>+                   (x .?> "DataEndpoint") <*> (pure (fromEnum s)))++instance Hashable GetDataEndpoint where++instance NFData GetDataEndpoint where++instance ToHeaders GetDataEndpoint where+        toHeaders = const mempty++instance ToJSON GetDataEndpoint where+        toJSON GetDataEndpoint'{..}+          = object+              (catMaybes+                 [("StreamARN" .=) <$> _gdeStreamARN,+                  ("StreamName" .=) <$> _gdeStreamName,+                  Just ("APIName" .= _gdeAPIName)])++instance ToPath GetDataEndpoint where+        toPath = const "/getDataEndpoint"++instance ToQuery GetDataEndpoint where+        toQuery = const mempty++-- | /See:/ 'getDataEndpointResponse' smart constructor.+data GetDataEndpointResponse = GetDataEndpointResponse'+  { _gdersDataEndpoint   :: !(Maybe Text)+  , _gdersResponseStatus :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'GetDataEndpointResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'gdersDataEndpoint' - The endpoint value. To read data from the stream or to write data to it, specify this endpoint in your application.+--+-- * 'gdersResponseStatus' - -- | The response status code.+getDataEndpointResponse+    :: Int -- ^ 'gdersResponseStatus'+    -> GetDataEndpointResponse+getDataEndpointResponse pResponseStatus_ =+  GetDataEndpointResponse'+    {_gdersDataEndpoint = Nothing, _gdersResponseStatus = pResponseStatus_}+++-- | The endpoint value. To read data from the stream or to write data to it, specify this endpoint in your application.+gdersDataEndpoint :: Lens' GetDataEndpointResponse (Maybe Text)+gdersDataEndpoint = lens _gdersDataEndpoint (\ s a -> s{_gdersDataEndpoint = a})++-- | -- | The response status code.+gdersResponseStatus :: Lens' GetDataEndpointResponse Int+gdersResponseStatus = lens _gdersResponseStatus (\ s a -> s{_gdersResponseStatus = a})++instance NFData GetDataEndpointResponse where
+ gen/Network/AWS/KinesisVideo/ListStreams.hs view
@@ -0,0 +1,162 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.KinesisVideo.ListStreams+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Returns an array of @StreamInfo@ objects. Each object describes a stream. To retrieve only streams that satisfy a specific condition, you can specify a @StreamNameCondition@ .+--+--+module Network.AWS.KinesisVideo.ListStreams+    (+    -- * Creating a Request+      listStreams+    , ListStreams+    -- * Request Lenses+    , lsNextToken+    , lsStreamNameCondition+    , lsMaxResults++    -- * Destructuring the Response+    , listStreamsResponse+    , ListStreamsResponse+    -- * Response Lenses+    , lsrsStreamInfoList+    , lsrsNextToken+    , lsrsResponseStatus+    ) where++import Network.AWS.KinesisVideo.Types+import Network.AWS.KinesisVideo.Types.Product+import Network.AWS.Lens+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'listStreams' smart constructor.+data ListStreams = ListStreams'+  { _lsNextToken           :: !(Maybe Text)+  , _lsStreamNameCondition :: !(Maybe StreamNameCondition)+  , _lsMaxResults          :: !(Maybe Nat)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'ListStreams' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'lsNextToken' - If you specify this parameter, when the result of a @ListStreams@ operation is truncated, the call returns the @NextToken@ in the response. To get another batch of streams, provide this token in your next request.+--+-- * 'lsStreamNameCondition' - Optional: Returns only streams that satisfy a specific condition. Currently, you can specify only the prefix of a stream name as a condition.+--+-- * 'lsMaxResults' - The maximum number of streams to return in the response. The default is 10,000.+listStreams+    :: ListStreams+listStreams =+  ListStreams'+    { _lsNextToken = Nothing+    , _lsStreamNameCondition = Nothing+    , _lsMaxResults = Nothing+    }+++-- | If you specify this parameter, when the result of a @ListStreams@ operation is truncated, the call returns the @NextToken@ in the response. To get another batch of streams, provide this token in your next request.+lsNextToken :: Lens' ListStreams (Maybe Text)+lsNextToken = lens _lsNextToken (\ s a -> s{_lsNextToken = a})++-- | Optional: Returns only streams that satisfy a specific condition. Currently, you can specify only the prefix of a stream name as a condition.+lsStreamNameCondition :: Lens' ListStreams (Maybe StreamNameCondition)+lsStreamNameCondition = lens _lsStreamNameCondition (\ s a -> s{_lsStreamNameCondition = a})++-- | The maximum number of streams to return in the response. The default is 10,000.+lsMaxResults :: Lens' ListStreams (Maybe Natural)+lsMaxResults = lens _lsMaxResults (\ s a -> s{_lsMaxResults = a}) . mapping _Nat++instance AWSRequest ListStreams where+        type Rs ListStreams = ListStreamsResponse+        request = postJSON kinesisVideo+        response+          = receiveJSON+              (\ s h x ->+                 ListStreamsResponse' <$>+                   (x .?> "StreamInfoList" .!@ mempty) <*>+                     (x .?> "NextToken")+                     <*> (pure (fromEnum s)))++instance Hashable ListStreams where++instance NFData ListStreams where++instance ToHeaders ListStreams where+        toHeaders = const mempty++instance ToJSON ListStreams where+        toJSON ListStreams'{..}+          = object+              (catMaybes+                 [("NextToken" .=) <$> _lsNextToken,+                  ("StreamNameCondition" .=) <$>+                    _lsStreamNameCondition,+                  ("MaxResults" .=) <$> _lsMaxResults])++instance ToPath ListStreams where+        toPath = const "/listStreams"++instance ToQuery ListStreams where+        toQuery = const mempty++-- | /See:/ 'listStreamsResponse' smart constructor.+data ListStreamsResponse = ListStreamsResponse'+  { _lsrsStreamInfoList :: !(Maybe [StreamInfo])+  , _lsrsNextToken      :: !(Maybe Text)+  , _lsrsResponseStatus :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'ListStreamsResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'lsrsStreamInfoList' - An array of @StreamInfo@ objects.+--+-- * 'lsrsNextToken' - If the response is truncated, the call returns this element with a token. To get the next batch of streams, use this token in your next request.+--+-- * 'lsrsResponseStatus' - -- | The response status code.+listStreamsResponse+    :: Int -- ^ 'lsrsResponseStatus'+    -> ListStreamsResponse+listStreamsResponse pResponseStatus_ =+  ListStreamsResponse'+    { _lsrsStreamInfoList = Nothing+    , _lsrsNextToken = Nothing+    , _lsrsResponseStatus = pResponseStatus_+    }+++-- | An array of @StreamInfo@ objects.+lsrsStreamInfoList :: Lens' ListStreamsResponse [StreamInfo]+lsrsStreamInfoList = lens _lsrsStreamInfoList (\ s a -> s{_lsrsStreamInfoList = a}) . _Default . _Coerce++-- | If the response is truncated, the call returns this element with a token. To get the next batch of streams, use this token in your next request.+lsrsNextToken :: Lens' ListStreamsResponse (Maybe Text)+lsrsNextToken = lens _lsrsNextToken (\ s a -> s{_lsrsNextToken = a})++-- | -- | The response status code.+lsrsResponseStatus :: Lens' ListStreamsResponse Int+lsrsResponseStatus = lens _lsrsResponseStatus (\ s a -> s{_lsrsResponseStatus = a})++instance NFData ListStreamsResponse where
+ gen/Network/AWS/KinesisVideo/ListTagsForStream.hs view
@@ -0,0 +1,162 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.KinesisVideo.ListTagsForStream+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Returns a list of tags associated with the specified stream.+--+--+-- In the request, you must specify either the @StreamName@ or the @StreamARN@ .+--+module Network.AWS.KinesisVideo.ListTagsForStream+    (+    -- * Creating a Request+      listTagsForStream+    , ListTagsForStream+    -- * Request Lenses+    , ltfsStreamARN+    , ltfsNextToken+    , ltfsStreamName++    -- * Destructuring the Response+    , listTagsForStreamResponse+    , ListTagsForStreamResponse+    -- * Response Lenses+    , ltfsrsNextToken+    , ltfsrsTags+    , ltfsrsResponseStatus+    ) where++import Network.AWS.KinesisVideo.Types+import Network.AWS.KinesisVideo.Types.Product+import Network.AWS.Lens+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'listTagsForStream' smart constructor.+data ListTagsForStream = ListTagsForStream'+  { _ltfsStreamARN  :: !(Maybe Text)+  , _ltfsNextToken  :: !(Maybe Text)+  , _ltfsStreamName :: !(Maybe Text)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'ListTagsForStream' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'ltfsStreamARN' - The Amazon Resource Name (ARN) of the stream that you want to list tags for.+--+-- * 'ltfsNextToken' - If you specify this parameter and the result of a @ListTagsForStream@ call is truncated, the response includes a token that you can use in the next request to fetch the next batch of tags.+--+-- * 'ltfsStreamName' - The name of the stream that you want to list tags for.+listTagsForStream+    :: ListTagsForStream+listTagsForStream =+  ListTagsForStream'+    { _ltfsStreamARN = Nothing+    , _ltfsNextToken = Nothing+    , _ltfsStreamName = Nothing+    }+++-- | The Amazon Resource Name (ARN) of the stream that you want to list tags for.+ltfsStreamARN :: Lens' ListTagsForStream (Maybe Text)+ltfsStreamARN = lens _ltfsStreamARN (\ s a -> s{_ltfsStreamARN = a})++-- | If you specify this parameter and the result of a @ListTagsForStream@ call is truncated, the response includes a token that you can use in the next request to fetch the next batch of tags.+ltfsNextToken :: Lens' ListTagsForStream (Maybe Text)+ltfsNextToken = lens _ltfsNextToken (\ s a -> s{_ltfsNextToken = a})++-- | The name of the stream that you want to list tags for.+ltfsStreamName :: Lens' ListTagsForStream (Maybe Text)+ltfsStreamName = lens _ltfsStreamName (\ s a -> s{_ltfsStreamName = a})++instance AWSRequest ListTagsForStream where+        type Rs ListTagsForStream = ListTagsForStreamResponse+        request = postJSON kinesisVideo+        response+          = receiveJSON+              (\ s h x ->+                 ListTagsForStreamResponse' <$>+                   (x .?> "NextToken") <*> (x .?> "Tags" .!@ mempty) <*>+                     (pure (fromEnum s)))++instance Hashable ListTagsForStream where++instance NFData ListTagsForStream where++instance ToHeaders ListTagsForStream where+        toHeaders = const mempty++instance ToJSON ListTagsForStream where+        toJSON ListTagsForStream'{..}+          = object+              (catMaybes+                 [("StreamARN" .=) <$> _ltfsStreamARN,+                  ("NextToken" .=) <$> _ltfsNextToken,+                  ("StreamName" .=) <$> _ltfsStreamName])++instance ToPath ListTagsForStream where+        toPath = const "/listTagsForStream"++instance ToQuery ListTagsForStream where+        toQuery = const mempty++-- | /See:/ 'listTagsForStreamResponse' smart constructor.+data ListTagsForStreamResponse = ListTagsForStreamResponse'+  { _ltfsrsNextToken      :: !(Maybe Text)+  , _ltfsrsTags           :: !(Maybe (Map Text Text))+  , _ltfsrsResponseStatus :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'ListTagsForStreamResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'ltfsrsNextToken' - If you specify this parameter and the result of a @ListTags@ call is truncated, the response includes a token that you can use in the next request to fetch the next set of tags.+--+-- * 'ltfsrsTags' - A map of tag keys and values associated with the specified stream.+--+-- * 'ltfsrsResponseStatus' - -- | The response status code.+listTagsForStreamResponse+    :: Int -- ^ 'ltfsrsResponseStatus'+    -> ListTagsForStreamResponse+listTagsForStreamResponse pResponseStatus_ =+  ListTagsForStreamResponse'+    { _ltfsrsNextToken = Nothing+    , _ltfsrsTags = Nothing+    , _ltfsrsResponseStatus = pResponseStatus_+    }+++-- | If you specify this parameter and the result of a @ListTags@ call is truncated, the response includes a token that you can use in the next request to fetch the next set of tags.+ltfsrsNextToken :: Lens' ListTagsForStreamResponse (Maybe Text)+ltfsrsNextToken = lens _ltfsrsNextToken (\ s a -> s{_ltfsrsNextToken = a})++-- | A map of tag keys and values associated with the specified stream.+ltfsrsTags :: Lens' ListTagsForStreamResponse (HashMap Text Text)+ltfsrsTags = lens _ltfsrsTags (\ s a -> s{_ltfsrsTags = a}) . _Default . _Map++-- | -- | The response status code.+ltfsrsResponseStatus :: Lens' ListTagsForStreamResponse Int+ltfsrsResponseStatus = lens _ltfsrsResponseStatus (\ s a -> s{_ltfsrsResponseStatus = a})++instance NFData ListTagsForStreamResponse where
+ gen/Network/AWS/KinesisVideo/TagStream.hs view
@@ -0,0 +1,140 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.KinesisVideo.TagStream+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Adds one or more tags to a stream. A /tag/ is a key-value pair (the value is optional) that you can define and assign to AWS resources. If you specify a tag that already exists, the tag value is replaced with the value that you specify in the request. For more information, see <http://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/cost-alloc-tags.html Using Cost Allocation Tags> in the /AWS Billing and Cost Management User Guide/ .+--+--+-- You must provide either the @StreamName@ or the @StreamARN@ .+--+-- This operation requires permission for the @KinesisVideo:TagStream@ action.+--+-- Kinesis video streams support up to 50 tags.+--+module Network.AWS.KinesisVideo.TagStream+    (+    -- * Creating a Request+      tagStream+    , TagStream+    -- * Request Lenses+    , tsStreamARN+    , tsStreamName+    , tsTags++    -- * Destructuring the Response+    , tagStreamResponse+    , TagStreamResponse+    -- * Response Lenses+    , tsrsResponseStatus+    ) where++import Network.AWS.KinesisVideo.Types+import Network.AWS.KinesisVideo.Types.Product+import Network.AWS.Lens+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'tagStream' smart constructor.+data TagStream = TagStream'+  { _tsStreamARN  :: !(Maybe Text)+  , _tsStreamName :: !(Maybe Text)+  , _tsTags       :: !(Map Text Text)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'TagStream' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'tsStreamARN' - The Amazon Resource Name (ARN) of the resource that you want to add the tag or tags to.+--+-- * 'tsStreamName' - The name of the stream that you want to add the tag or tags to.+--+-- * 'tsTags' - A list of tags to associate with the specified stream. Each tag is a key-value pair (the value is optional).+tagStream+    :: TagStream+tagStream =+  TagStream' {_tsStreamARN = Nothing, _tsStreamName = Nothing, _tsTags = mempty}+++-- | The Amazon Resource Name (ARN) of the resource that you want to add the tag or tags to.+tsStreamARN :: Lens' TagStream (Maybe Text)+tsStreamARN = lens _tsStreamARN (\ s a -> s{_tsStreamARN = a})++-- | The name of the stream that you want to add the tag or tags to.+tsStreamName :: Lens' TagStream (Maybe Text)+tsStreamName = lens _tsStreamName (\ s a -> s{_tsStreamName = a})++-- | A list of tags to associate with the specified stream. Each tag is a key-value pair (the value is optional).+tsTags :: Lens' TagStream (HashMap Text Text)+tsTags = lens _tsTags (\ s a -> s{_tsTags = a}) . _Map++instance AWSRequest TagStream where+        type Rs TagStream = TagStreamResponse+        request = postJSON kinesisVideo+        response+          = receiveEmpty+              (\ s h x ->+                 TagStreamResponse' <$> (pure (fromEnum s)))++instance Hashable TagStream where++instance NFData TagStream where++instance ToHeaders TagStream where+        toHeaders = const mempty++instance ToJSON TagStream where+        toJSON TagStream'{..}+          = object+              (catMaybes+                 [("StreamARN" .=) <$> _tsStreamARN,+                  ("StreamName" .=) <$> _tsStreamName,+                  Just ("Tags" .= _tsTags)])++instance ToPath TagStream where+        toPath = const "/tagStream"++instance ToQuery TagStream where+        toQuery = const mempty++-- | /See:/ 'tagStreamResponse' smart constructor.+newtype TagStreamResponse = TagStreamResponse'+  { _tsrsResponseStatus :: Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'TagStreamResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'tsrsResponseStatus' - -- | The response status code.+tagStreamResponse+    :: Int -- ^ 'tsrsResponseStatus'+    -> TagStreamResponse+tagStreamResponse pResponseStatus_ =+  TagStreamResponse' {_tsrsResponseStatus = pResponseStatus_}+++-- | -- | The response status code.+tsrsResponseStatus :: Lens' TagStreamResponse Int+tsrsResponseStatus = lens _tsrsResponseStatus (\ s a -> s{_tsrsResponseStatus = a})++instance NFData TagStreamResponse where
+ gen/Network/AWS/KinesisVideo/Types.hs view
@@ -0,0 +1,198 @@+{-# LANGUAGE OverloadedStrings #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.KinesisVideo.Types+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+module Network.AWS.KinesisVideo.Types+    (+    -- * Service Configuration+      kinesisVideo++    -- * Errors+    , _InvalidArgumentException+    , _TagsPerResourceExceededLimitException+    , _NotAuthorizedException+    , _ClientLimitExceededException+    , _InvalidDeviceException+    , _VersionMismatchException+    , _AccountStreamLimitExceededException+    , _InvalidResourceFormatException+    , _DeviceStreamLimitExceededException+    , _ResourceNotFoundException+    , _ResourceInUseException++    -- * APIName+    , APIName (..)++    -- * ComparisonOperator+    , ComparisonOperator (..)++    -- * StreamStatus+    , StreamStatus (..)++    -- * UpdateDataRetentionOperation+    , UpdateDataRetentionOperation (..)++    -- * StreamInfo+    , StreamInfo+    , streamInfo+    , siCreationTime+    , siStatus+    , siMediaType+    , siDataRetentionInHours+    , siStreamARN+    , siKMSKeyId+    , siDeviceName+    , siVersion+    , siStreamName++    -- * StreamNameCondition+    , StreamNameCondition+    , streamNameCondition+    , sncComparisonOperator+    , sncComparisonValue+    ) where++import Network.AWS.KinesisVideo.Types.Product+import Network.AWS.KinesisVideo.Types.Sum+import Network.AWS.Lens+import Network.AWS.Prelude+import Network.AWS.Sign.V4++-- | API version @2017-09-30@ of the Amazon Kinesis Video Streams SDK configuration.+kinesisVideo :: Service+kinesisVideo =+  Service+    { _svcAbbrev = "KinesisVideo"+    , _svcSigner = v4+    , _svcPrefix = "kinesisvideo"+    , _svcVersion = "2017-09-30"+    , _svcEndpoint = defaultEndpoint kinesisVideo+    , _svcTimeout = Just 70+    , _svcCheck = statusSuccess+    , _svcError = parseJSONError "KinesisVideo"+    , _svcRetry = retry+    }+  where+    retry =+      Exponential+        { _retryBase = 5.0e-2+        , _retryGrowth = 2+        , _retryAttempts = 5+        , _retryCheck = check+        }+    check e+      | has (hasCode "ThrottledException" . hasStatus 400) e =+        Just "throttled_exception"+      | has (hasStatus 429) e = Just "too_many_requests"+      | has (hasCode "ThrottlingException" . hasStatus 400) e =+        Just "throttling_exception"+      | has (hasCode "Throttling" . hasStatus 400) e = Just "throttling"+      | has (hasStatus 504) e = Just "gateway_timeout"+      | has (hasCode "RequestThrottledException" . hasStatus 400) e =+        Just "request_throttled_exception"+      | has (hasStatus 502) e = Just "bad_gateway"+      | has (hasStatus 503) e = Just "service_unavailable"+      | has (hasStatus 500) e = Just "general_server_error"+      | has (hasStatus 509) e = Just "limit_exceeded"+      | otherwise = Nothing+++-- | The value for this input parameter is invalid.+--+--+_InvalidArgumentException :: AsError a => Getting (First ServiceError) a ServiceError+_InvalidArgumentException =+  _MatchServiceError kinesisVideo "InvalidArgumentException" . hasStatus 400+++-- | You have exceeded the limit of tags that you can associate with the resource. Kinesis video streams support up to 50 tags.+--+--+_TagsPerResourceExceededLimitException :: AsError a => Getting (First ServiceError) a ServiceError+_TagsPerResourceExceededLimitException =+  _MatchServiceError kinesisVideo "TagsPerResourceExceededLimitException" .+  hasStatus 400+++-- | The caller is not authorized to perform this operation.+--+--+_NotAuthorizedException :: AsError a => Getting (First ServiceError) a ServiceError+_NotAuthorizedException =+  _MatchServiceError kinesisVideo "NotAuthorizedException" . hasStatus 401+++-- | Kinesis Video Streams has throttled the request because you have exceeded the limit of allowed client calls. Try making the call later.+--+--+_ClientLimitExceededException :: AsError a => Getting (First ServiceError) a ServiceError+_ClientLimitExceededException =+  _MatchServiceError kinesisVideo "ClientLimitExceededException" . hasStatus 400+++-- | Not implemented.+--+--+_InvalidDeviceException :: AsError a => Getting (First ServiceError) a ServiceError+_InvalidDeviceException =+  _MatchServiceError kinesisVideo "InvalidDeviceException" . hasStatus 400+++-- | The stream version that you specified is not the latest version. To get the latest version, use the <http://docs.aws.amazon.com/kinesisvideo/latest/dg/API_DescribeStream.html DescribeStream> API.+--+--+_VersionMismatchException :: AsError a => Getting (First ServiceError) a ServiceError+_VersionMismatchException =+  _MatchServiceError kinesisVideo "VersionMismatchException" . hasStatus 400+++-- | The number of streams created for the account is too high.+--+--+_AccountStreamLimitExceededException :: AsError a => Getting (First ServiceError) a ServiceError+_AccountStreamLimitExceededException =+  _MatchServiceError kinesisVideo "AccountStreamLimitExceededException" .+  hasStatus 400+++-- | The format of the @StreamARN@ is invalid.+--+--+_InvalidResourceFormatException :: AsError a => Getting (First ServiceError) a ServiceError+_InvalidResourceFormatException =+  _MatchServiceError kinesisVideo "InvalidResourceFormatException" .+  hasStatus 400+++-- | Not implemented.+--+--+_DeviceStreamLimitExceededException :: AsError a => Getting (First ServiceError) a ServiceError+_DeviceStreamLimitExceededException =+  _MatchServiceError kinesisVideo "DeviceStreamLimitExceededException" .+  hasStatus 400+++-- | Amazon Kinesis Video Streams can't find the stream that you specified.+--+--+_ResourceNotFoundException :: AsError a => Getting (First ServiceError) a ServiceError+_ResourceNotFoundException =+  _MatchServiceError kinesisVideo "ResourceNotFoundException" . hasStatus 404+++-- | The stream is currently not available for this operation.+--+--+_ResourceInUseException :: AsError a => Getting (First ServiceError) a ServiceError+_ResourceInUseException =+  _MatchServiceError kinesisVideo "ResourceInUseException" . hasStatus 400+
+ gen/Network/AWS/KinesisVideo/Types/Product.hs view
@@ -0,0 +1,176 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.KinesisVideo.Types.Product+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+module Network.AWS.KinesisVideo.Types.Product where++import Network.AWS.KinesisVideo.Types.Sum+import Network.AWS.Lens+import Network.AWS.Prelude++-- | An object describing a Kinesis video stream.+--+--+--+-- /See:/ 'streamInfo' smart constructor.+data StreamInfo = StreamInfo'+  { _siCreationTime         :: !(Maybe POSIX)+  , _siStatus               :: !(Maybe StreamStatus)+  , _siMediaType            :: !(Maybe Text)+  , _siDataRetentionInHours :: !(Maybe Nat)+  , _siStreamARN            :: !(Maybe Text)+  , _siKMSKeyId             :: !(Maybe Text)+  , _siDeviceName           :: !(Maybe Text)+  , _siVersion              :: !(Maybe Text)+  , _siStreamName           :: !(Maybe Text)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'StreamInfo' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'siCreationTime' - A time stamp that indicates when the stream was created.+--+-- * 'siStatus' - The status of the stream.+--+-- * 'siMediaType' - The @MediaType@ of the stream.+--+-- * 'siDataRetentionInHours' - How long the stream retains data, in hours.+--+-- * 'siStreamARN' - The Amazon Resource Name (ARN) of the stream.+--+-- * 'siKMSKeyId' - The ID of the AWS Key Management Service (AWS KMS) key that Kinesis Video Streams uses to encrypt data on the stream.+--+-- * 'siDeviceName' - The name of the device that is associated with the stream.+--+-- * 'siVersion' - The version of the stream.+--+-- * 'siStreamName' - The name of the stream.+streamInfo+    :: StreamInfo+streamInfo =+  StreamInfo'+    { _siCreationTime = Nothing+    , _siStatus = Nothing+    , _siMediaType = Nothing+    , _siDataRetentionInHours = Nothing+    , _siStreamARN = Nothing+    , _siKMSKeyId = Nothing+    , _siDeviceName = Nothing+    , _siVersion = Nothing+    , _siStreamName = Nothing+    }+++-- | A time stamp that indicates when the stream was created.+siCreationTime :: Lens' StreamInfo (Maybe UTCTime)+siCreationTime = lens _siCreationTime (\ s a -> s{_siCreationTime = a}) . mapping _Time++-- | The status of the stream.+siStatus :: Lens' StreamInfo (Maybe StreamStatus)+siStatus = lens _siStatus (\ s a -> s{_siStatus = a})++-- | The @MediaType@ of the stream.+siMediaType :: Lens' StreamInfo (Maybe Text)+siMediaType = lens _siMediaType (\ s a -> s{_siMediaType = a})++-- | How long the stream retains data, in hours.+siDataRetentionInHours :: Lens' StreamInfo (Maybe Natural)+siDataRetentionInHours = lens _siDataRetentionInHours (\ s a -> s{_siDataRetentionInHours = a}) . mapping _Nat++-- | The Amazon Resource Name (ARN) of the stream.+siStreamARN :: Lens' StreamInfo (Maybe Text)+siStreamARN = lens _siStreamARN (\ s a -> s{_siStreamARN = a})++-- | The ID of the AWS Key Management Service (AWS KMS) key that Kinesis Video Streams uses to encrypt data on the stream.+siKMSKeyId :: Lens' StreamInfo (Maybe Text)+siKMSKeyId = lens _siKMSKeyId (\ s a -> s{_siKMSKeyId = a})++-- | The name of the device that is associated with the stream.+siDeviceName :: Lens' StreamInfo (Maybe Text)+siDeviceName = lens _siDeviceName (\ s a -> s{_siDeviceName = a})++-- | The version of the stream.+siVersion :: Lens' StreamInfo (Maybe Text)+siVersion = lens _siVersion (\ s a -> s{_siVersion = a})++-- | The name of the stream.+siStreamName :: Lens' StreamInfo (Maybe Text)+siStreamName = lens _siStreamName (\ s a -> s{_siStreamName = a})++instance FromJSON StreamInfo where+        parseJSON+          = withObject "StreamInfo"+              (\ x ->+                 StreamInfo' <$>+                   (x .:? "CreationTime") <*> (x .:? "Status") <*>+                     (x .:? "MediaType")+                     <*> (x .:? "DataRetentionInHours")+                     <*> (x .:? "StreamARN")+                     <*> (x .:? "KmsKeyId")+                     <*> (x .:? "DeviceName")+                     <*> (x .:? "Version")+                     <*> (x .:? "StreamName"))++instance Hashable StreamInfo where++instance NFData StreamInfo where++-- | Specifies the condition that streams must satisfy to be returned when you list streams (see the @ListStreams@ API). A condition has a comparison operation and a value. Currently, you can specify only the @BEGINS_WITH@ operator, which finds streams whose names start with a given prefix.+--+--+--+-- /See:/ 'streamNameCondition' smart constructor.+data StreamNameCondition = StreamNameCondition'+  { _sncComparisonOperator :: !(Maybe ComparisonOperator)+  , _sncComparisonValue    :: !(Maybe Text)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'StreamNameCondition' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'sncComparisonOperator' - A comparison operator. Currently, you can specify only the @BEGINS_WITH@ operator, which finds streams whose names start with a given prefix.+--+-- * 'sncComparisonValue' - A value to compare.+streamNameCondition+    :: StreamNameCondition+streamNameCondition =+  StreamNameCondition'+    {_sncComparisonOperator = Nothing, _sncComparisonValue = Nothing}+++-- | A comparison operator. Currently, you can specify only the @BEGINS_WITH@ operator, which finds streams whose names start with a given prefix.+sncComparisonOperator :: Lens' StreamNameCondition (Maybe ComparisonOperator)+sncComparisonOperator = lens _sncComparisonOperator (\ s a -> s{_sncComparisonOperator = a})++-- | A value to compare.+sncComparisonValue :: Lens' StreamNameCondition (Maybe Text)+sncComparisonValue = lens _sncComparisonValue (\ s a -> s{_sncComparisonValue = a})++instance Hashable StreamNameCondition where++instance NFData StreamNameCondition where++instance ToJSON StreamNameCondition where+        toJSON StreamNameCondition'{..}+          = object+              (catMaybes+                 [("ComparisonOperator" .=) <$>+                    _sncComparisonOperator,+                  ("ComparisonValue" .=) <$> _sncComparisonValue])
+ gen/Network/AWS/KinesisVideo/Types/Sum.hs view
@@ -0,0 +1,137 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE LambdaCase         #-}+{-# LANGUAGE OverloadedStrings  #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.KinesisVideo.Types.Sum+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+module Network.AWS.KinesisVideo.Types.Sum where++import Network.AWS.Prelude++data APIName+  = GetMedia+  | GetMediaForFragmentList+  | ListFragments+  | PutMedia+  deriving (Eq, Ord, Read, Show, Enum, Bounded, Data, Typeable, Generic)+++instance FromText APIName where+    parser = takeLowerText >>= \case+        "get_media" -> pure GetMedia+        "get_media_for_fragment_list" -> pure GetMediaForFragmentList+        "list_fragments" -> pure ListFragments+        "put_media" -> pure PutMedia+        e -> fromTextError $ "Failure parsing APIName from value: '" <> e+           <> "'. Accepted values: get_media, get_media_for_fragment_list, list_fragments, put_media"++instance ToText APIName where+    toText = \case+        GetMedia -> "GET_MEDIA"+        GetMediaForFragmentList -> "GET_MEDIA_FOR_FRAGMENT_LIST"+        ListFragments -> "LIST_FRAGMENTS"+        PutMedia -> "PUT_MEDIA"++instance Hashable     APIName+instance NFData       APIName+instance ToByteString APIName+instance ToQuery      APIName+instance ToHeader     APIName++instance ToJSON APIName where+    toJSON = toJSONText++data ComparisonOperator =+  BeginsWith+  deriving (Eq, Ord, Read, Show, Enum, Bounded, Data, Typeable, Generic)+++instance FromText ComparisonOperator where+    parser = takeLowerText >>= \case+        "begins_with" -> pure BeginsWith+        e -> fromTextError $ "Failure parsing ComparisonOperator from value: '" <> e+           <> "'. Accepted values: begins_with"++instance ToText ComparisonOperator where+    toText = \case+        BeginsWith -> "BEGINS_WITH"++instance Hashable     ComparisonOperator+instance NFData       ComparisonOperator+instance ToByteString ComparisonOperator+instance ToQuery      ComparisonOperator+instance ToHeader     ComparisonOperator++instance ToJSON ComparisonOperator where+    toJSON = toJSONText++data StreamStatus+  = Active+  | Creating+  | Deleting+  | Updating+  deriving (Eq, Ord, Read, Show, Enum, Bounded, Data, Typeable, Generic)+++instance FromText StreamStatus where+    parser = takeLowerText >>= \case+        "active" -> pure Active+        "creating" -> pure Creating+        "deleting" -> pure Deleting+        "updating" -> pure Updating+        e -> fromTextError $ "Failure parsing StreamStatus from value: '" <> e+           <> "'. Accepted values: active, creating, deleting, updating"++instance ToText StreamStatus where+    toText = \case+        Active -> "ACTIVE"+        Creating -> "CREATING"+        Deleting -> "DELETING"+        Updating -> "UPDATING"++instance Hashable     StreamStatus+instance NFData       StreamStatus+instance ToByteString StreamStatus+instance ToQuery      StreamStatus+instance ToHeader     StreamStatus++instance FromJSON StreamStatus where+    parseJSON = parseJSONText "StreamStatus"++data UpdateDataRetentionOperation+  = DecreaseDataRetention+  | IncreaseDataRetention+  deriving (Eq, Ord, Read, Show, Enum, Bounded, Data, Typeable, Generic)+++instance FromText UpdateDataRetentionOperation where+    parser = takeLowerText >>= \case+        "decrease_data_retention" -> pure DecreaseDataRetention+        "increase_data_retention" -> pure IncreaseDataRetention+        e -> fromTextError $ "Failure parsing UpdateDataRetentionOperation from value: '" <> e+           <> "'. Accepted values: decrease_data_retention, increase_data_retention"++instance ToText UpdateDataRetentionOperation where+    toText = \case+        DecreaseDataRetention -> "DECREASE_DATA_RETENTION"+        IncreaseDataRetention -> "INCREASE_DATA_RETENTION"++instance Hashable     UpdateDataRetentionOperation+instance NFData       UpdateDataRetentionOperation+instance ToByteString UpdateDataRetentionOperation+instance ToQuery      UpdateDataRetentionOperation+instance ToHeader     UpdateDataRetentionOperation++instance ToJSON UpdateDataRetentionOperation where+    toJSON = toJSONText
+ gen/Network/AWS/KinesisVideo/UntagStream.hs view
@@ -0,0 +1,141 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.KinesisVideo.UntagStream+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Removes one or more tags from a stream. In the request, specify only a tag key or keys; don't specify the value. If you specify a tag key that does not exist, it's ignored.+--+--+-- In the request, you must provide the @StreamName@ or @StreamARN@ .+--+module Network.AWS.KinesisVideo.UntagStream+    (+    -- * Creating a Request+      untagStream+    , UntagStream+    -- * Request Lenses+    , usStreamARN+    , usStreamName+    , usTagKeyList++    -- * Destructuring the Response+    , untagStreamResponse+    , UntagStreamResponse+    -- * Response Lenses+    , ursResponseStatus+    ) where++import Network.AWS.KinesisVideo.Types+import Network.AWS.KinesisVideo.Types.Product+import Network.AWS.Lens+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'untagStream' smart constructor.+data UntagStream = UntagStream'+  { _usStreamARN  :: !(Maybe Text)+  , _usStreamName :: !(Maybe Text)+  , _usTagKeyList :: !(List1 Text)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'UntagStream' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'usStreamARN' - The Amazon Resource Name (ARN) of the stream that you want to remove tags from.+--+-- * 'usStreamName' - The name of the stream that you want to remove tags from.+--+-- * 'usTagKeyList' - A list of the keys of the tags that you want to remove.+untagStream+    :: NonEmpty Text -- ^ 'usTagKeyList'+    -> UntagStream+untagStream pTagKeyList_ =+  UntagStream'+    { _usStreamARN = Nothing+    , _usStreamName = Nothing+    , _usTagKeyList = _List1 # pTagKeyList_+    }+++-- | The Amazon Resource Name (ARN) of the stream that you want to remove tags from.+usStreamARN :: Lens' UntagStream (Maybe Text)+usStreamARN = lens _usStreamARN (\ s a -> s{_usStreamARN = a})++-- | The name of the stream that you want to remove tags from.+usStreamName :: Lens' UntagStream (Maybe Text)+usStreamName = lens _usStreamName (\ s a -> s{_usStreamName = a})++-- | A list of the keys of the tags that you want to remove.+usTagKeyList :: Lens' UntagStream (NonEmpty Text)+usTagKeyList = lens _usTagKeyList (\ s a -> s{_usTagKeyList = a}) . _List1++instance AWSRequest UntagStream where+        type Rs UntagStream = UntagStreamResponse+        request = postJSON kinesisVideo+        response+          = receiveEmpty+              (\ s h x ->+                 UntagStreamResponse' <$> (pure (fromEnum s)))++instance Hashable UntagStream where++instance NFData UntagStream where++instance ToHeaders UntagStream where+        toHeaders = const mempty++instance ToJSON UntagStream where+        toJSON UntagStream'{..}+          = object+              (catMaybes+                 [("StreamARN" .=) <$> _usStreamARN,+                  ("StreamName" .=) <$> _usStreamName,+                  Just ("TagKeyList" .= _usTagKeyList)])++instance ToPath UntagStream where+        toPath = const "/untagStream"++instance ToQuery UntagStream where+        toQuery = const mempty++-- | /See:/ 'untagStreamResponse' smart constructor.+newtype UntagStreamResponse = UntagStreamResponse'+  { _ursResponseStatus :: Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'UntagStreamResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'ursResponseStatus' - -- | The response status code.+untagStreamResponse+    :: Int -- ^ 'ursResponseStatus'+    -> UntagStreamResponse+untagStreamResponse pResponseStatus_ =+  UntagStreamResponse' {_ursResponseStatus = pResponseStatus_}+++-- | -- | The response status code.+ursResponseStatus :: Lens' UntagStreamResponse Int+ursResponseStatus = lens _ursResponseStatus (\ s a -> s{_ursResponseStatus = a})++instance NFData UntagStreamResponse where
+ gen/Network/AWS/KinesisVideo/UpdateDataRetention.hs view
@@ -0,0 +1,174 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.KinesisVideo.UpdateDataRetention+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Increases or decreases the stream's data retention period by the value that you specify. To indicate whether you want to increase or decrease the data retention period, specify the @Operation@ parameter in the request body. In the request, you must specify either the @StreamName@ or the @StreamARN@ .+--+--+-- This operation requires permission for the @KinesisVideo:UpdateDataRetention@ action.+--+-- Changing the data retention period affects the data in the stream as follows:+--+--     * If the data retention period is increased, existing data is retained for the new retention period. For example, if the data retention period is increased from one hour to seven hours, all existing data is retained for seven hours.+--+--     * If the data retention period is decreased, existing data is retained for the new retention period. For example, if the data retention period is decreased from seven hours to one hour, all existing data is retained for one hour, and any data older than one hour is deleted immediately.+--+--+--+module Network.AWS.KinesisVideo.UpdateDataRetention+    (+    -- * Creating a Request+      updateDataRetention+    , UpdateDataRetention+    -- * Request Lenses+    , udrStreamARN+    , udrStreamName+    , udrCurrentVersion+    , udrOperation+    , udrDataRetentionChangeInHours++    -- * Destructuring the Response+    , updateDataRetentionResponse+    , UpdateDataRetentionResponse+    -- * Response Lenses+    , udrrsResponseStatus+    ) where++import Network.AWS.KinesisVideo.Types+import Network.AWS.KinesisVideo.Types.Product+import Network.AWS.Lens+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'updateDataRetention' smart constructor.+data UpdateDataRetention = UpdateDataRetention'+  { _udrStreamARN                  :: !(Maybe Text)+  , _udrStreamName                 :: !(Maybe Text)+  , _udrCurrentVersion             :: !Text+  , _udrOperation                  :: !UpdateDataRetentionOperation+  , _udrDataRetentionChangeInHours :: !Nat+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'UpdateDataRetention' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'udrStreamARN' - The Amazon Resource Name (ARN) of the stream whose retention period you want to change.+--+-- * 'udrStreamName' - The name of the stream whose retention period you want to change.+--+-- * 'udrCurrentVersion' - The version of the stream whose retention period you want to change. To get the version, call either the @DescribeStream@ or the @ListStreams@ API.+--+-- * 'udrOperation' - Indicates whether you want to increase or decrease the retention period.+--+-- * 'udrDataRetentionChangeInHours' - The retention period, in hours. The value you specify replaces the current value.+updateDataRetention+    :: Text -- ^ 'udrCurrentVersion'+    -> UpdateDataRetentionOperation -- ^ 'udrOperation'+    -> Natural -- ^ 'udrDataRetentionChangeInHours'+    -> UpdateDataRetention+updateDataRetention pCurrentVersion_ pOperation_ pDataRetentionChangeInHours_ =+  UpdateDataRetention'+    { _udrStreamARN = Nothing+    , _udrStreamName = Nothing+    , _udrCurrentVersion = pCurrentVersion_+    , _udrOperation = pOperation_+    , _udrDataRetentionChangeInHours = _Nat # pDataRetentionChangeInHours_+    }+++-- | The Amazon Resource Name (ARN) of the stream whose retention period you want to change.+udrStreamARN :: Lens' UpdateDataRetention (Maybe Text)+udrStreamARN = lens _udrStreamARN (\ s a -> s{_udrStreamARN = a})++-- | The name of the stream whose retention period you want to change.+udrStreamName :: Lens' UpdateDataRetention (Maybe Text)+udrStreamName = lens _udrStreamName (\ s a -> s{_udrStreamName = a})++-- | The version of the stream whose retention period you want to change. To get the version, call either the @DescribeStream@ or the @ListStreams@ API.+udrCurrentVersion :: Lens' UpdateDataRetention Text+udrCurrentVersion = lens _udrCurrentVersion (\ s a -> s{_udrCurrentVersion = a})++-- | Indicates whether you want to increase or decrease the retention period.+udrOperation :: Lens' UpdateDataRetention UpdateDataRetentionOperation+udrOperation = lens _udrOperation (\ s a -> s{_udrOperation = a})++-- | The retention period, in hours. The value you specify replaces the current value.+udrDataRetentionChangeInHours :: Lens' UpdateDataRetention Natural+udrDataRetentionChangeInHours = lens _udrDataRetentionChangeInHours (\ s a -> s{_udrDataRetentionChangeInHours = a}) . _Nat++instance AWSRequest UpdateDataRetention where+        type Rs UpdateDataRetention =+             UpdateDataRetentionResponse+        request = postJSON kinesisVideo+        response+          = receiveEmpty+              (\ s h x ->+                 UpdateDataRetentionResponse' <$> (pure (fromEnum s)))++instance Hashable UpdateDataRetention where++instance NFData UpdateDataRetention where++instance ToHeaders UpdateDataRetention where+        toHeaders = const mempty++instance ToJSON UpdateDataRetention where+        toJSON UpdateDataRetention'{..}+          = object+              (catMaybes+                 [("StreamARN" .=) <$> _udrStreamARN,+                  ("StreamName" .=) <$> _udrStreamName,+                  Just ("CurrentVersion" .= _udrCurrentVersion),+                  Just ("Operation" .= _udrOperation),+                  Just+                    ("DataRetentionChangeInHours" .=+                       _udrDataRetentionChangeInHours)])++instance ToPath UpdateDataRetention where+        toPath = const "/updateDataRetention"++instance ToQuery UpdateDataRetention where+        toQuery = const mempty++-- | /See:/ 'updateDataRetentionResponse' smart constructor.+newtype UpdateDataRetentionResponse = UpdateDataRetentionResponse'+  { _udrrsResponseStatus :: Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'UpdateDataRetentionResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'udrrsResponseStatus' - -- | The response status code.+updateDataRetentionResponse+    :: Int -- ^ 'udrrsResponseStatus'+    -> UpdateDataRetentionResponse+updateDataRetentionResponse pResponseStatus_ =+  UpdateDataRetentionResponse' {_udrrsResponseStatus = pResponseStatus_}+++-- | -- | The response status code.+udrrsResponseStatus :: Lens' UpdateDataRetentionResponse Int+udrrsResponseStatus = lens _udrrsResponseStatus (\ s a -> s{_udrrsResponseStatus = a})++instance NFData UpdateDataRetentionResponse where
+ gen/Network/AWS/KinesisVideo/UpdateStream.hs view
@@ -0,0 +1,165 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.KinesisVideo.UpdateStream+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Updates stream metadata, such as the device name and media type.+--+--+-- You must provide the stream name or the Amazon Resource Name (ARN) of the stream.+--+-- To make sure that you have the latest version of the stream before updating it, you can specify the stream version. Kinesis Video Streams assigns a version to each stream. When you update a stream, Kinesis Video Streams assigns a new version number. To get the latest stream version, use the @DescribeStream@ API.+--+-- @UpdateStream@ is an asynchronous operation, and takes time to complete.+--+module Network.AWS.KinesisVideo.UpdateStream+    (+    -- * Creating a Request+      updateStream+    , UpdateStream+    -- * Request Lenses+    , uMediaType+    , uStreamARN+    , uDeviceName+    , uStreamName+    , uCurrentVersion++    -- * Destructuring the Response+    , updateStreamResponse+    , UpdateStreamResponse+    -- * Response Lenses+    , usrsResponseStatus+    ) where++import Network.AWS.KinesisVideo.Types+import Network.AWS.KinesisVideo.Types.Product+import Network.AWS.Lens+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'updateStream' smart constructor.+data UpdateStream = UpdateStream'+  { _uMediaType      :: !(Maybe Text)+  , _uStreamARN      :: !(Maybe Text)+  , _uDeviceName     :: !(Maybe Text)+  , _uStreamName     :: !(Maybe Text)+  , _uCurrentVersion :: !Text+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'UpdateStream' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'uMediaType' - The stream's media type. Use @MediaType@ to specify the type of content that the stream contains to the consumers of the stream. For more information about media types, see <http://www.iana.org/assignments/media-types/media-types.xhtml Media Types> . If you choose to specify the @MediaType@ , see <https://tools.sietf.org/html/rfc6838#section-4.2 Naming Requirements> . To play video on the console, you must specify the correct video type. For example, if the video in the stream is H.264, specify @video/h264@ as the @MediaType@ .+--+-- * 'uStreamARN' - The ARN of the stream whose metadata you want to update.+--+-- * 'uDeviceName' - The name of the device that is writing to the stream.+--+-- * 'uStreamName' - The name of the stream whose metadata you want to update. The stream name is an identifier for the stream, and must be unique for each account and region.+--+-- * 'uCurrentVersion' - The version of the stream whose metadata you want to update.+updateStream+    :: Text -- ^ 'uCurrentVersion'+    -> UpdateStream+updateStream pCurrentVersion_ =+  UpdateStream'+    { _uMediaType = Nothing+    , _uStreamARN = Nothing+    , _uDeviceName = Nothing+    , _uStreamName = Nothing+    , _uCurrentVersion = pCurrentVersion_+    }+++-- | The stream's media type. Use @MediaType@ to specify the type of content that the stream contains to the consumers of the stream. For more information about media types, see <http://www.iana.org/assignments/media-types/media-types.xhtml Media Types> . If you choose to specify the @MediaType@ , see <https://tools.sietf.org/html/rfc6838#section-4.2 Naming Requirements> . To play video on the console, you must specify the correct video type. For example, if the video in the stream is H.264, specify @video/h264@ as the @MediaType@ .+uMediaType :: Lens' UpdateStream (Maybe Text)+uMediaType = lens _uMediaType (\ s a -> s{_uMediaType = a})++-- | The ARN of the stream whose metadata you want to update.+uStreamARN :: Lens' UpdateStream (Maybe Text)+uStreamARN = lens _uStreamARN (\ s a -> s{_uStreamARN = a})++-- | The name of the device that is writing to the stream.+uDeviceName :: Lens' UpdateStream (Maybe Text)+uDeviceName = lens _uDeviceName (\ s a -> s{_uDeviceName = a})++-- | The name of the stream whose metadata you want to update. The stream name is an identifier for the stream, and must be unique for each account and region.+uStreamName :: Lens' UpdateStream (Maybe Text)+uStreamName = lens _uStreamName (\ s a -> s{_uStreamName = a})++-- | The version of the stream whose metadata you want to update.+uCurrentVersion :: Lens' UpdateStream Text+uCurrentVersion = lens _uCurrentVersion (\ s a -> s{_uCurrentVersion = a})++instance AWSRequest UpdateStream where+        type Rs UpdateStream = UpdateStreamResponse+        request = postJSON kinesisVideo+        response+          = receiveEmpty+              (\ s h x ->+                 UpdateStreamResponse' <$> (pure (fromEnum s)))++instance Hashable UpdateStream where++instance NFData UpdateStream where++instance ToHeaders UpdateStream where+        toHeaders = const mempty++instance ToJSON UpdateStream where+        toJSON UpdateStream'{..}+          = object+              (catMaybes+                 [("MediaType" .=) <$> _uMediaType,+                  ("StreamARN" .=) <$> _uStreamARN,+                  ("DeviceName" .=) <$> _uDeviceName,+                  ("StreamName" .=) <$> _uStreamName,+                  Just ("CurrentVersion" .= _uCurrentVersion)])++instance ToPath UpdateStream where+        toPath = const "/updateStream"++instance ToQuery UpdateStream where+        toQuery = const mempty++-- | /See:/ 'updateStreamResponse' smart constructor.+newtype UpdateStreamResponse = UpdateStreamResponse'+  { _usrsResponseStatus :: Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'UpdateStreamResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'usrsResponseStatus' - -- | The response status code.+updateStreamResponse+    :: Int -- ^ 'usrsResponseStatus'+    -> UpdateStreamResponse+updateStreamResponse pResponseStatus_ =+  UpdateStreamResponse' {_usrsResponseStatus = pResponseStatus_}+++-- | -- | The response status code.+usrsResponseStatus :: Lens' UpdateStreamResponse Int+usrsResponseStatus = lens _usrsResponseStatus (\ s a -> s{_usrsResponseStatus = a})++instance NFData UpdateStreamResponse where
+ gen/Network/AWS/KinesisVideo/Waiters.hs view
@@ -0,0 +1,21 @@+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE TypeFamilies      #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.KinesisVideo.Waiters+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+module Network.AWS.KinesisVideo.Waiters where++import Network.AWS.KinesisVideo.Types+import Network.AWS.Lens+import Network.AWS.Prelude+import Network.AWS.Waiter
+ src/.gitkeep view
+ test/Main.hs view
@@ -0,0 +1,21 @@+{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- |+-- Module      : Main+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+module Main (main) where++import Test.Tasty+import Test.AWS.KinesisVideo+import Test.AWS.KinesisVideo.Internal++main :: IO ()+main = defaultMain $ testGroup "KinesisVideo"+    [ testGroup "tests"    tests+    , testGroup "fixtures" fixtures+    ]
+ test/Test/AWS/Gen/KinesisVideo.hs view
@@ -0,0 +1,219 @@+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-orphans        #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Test.AWS.Gen.KinesisVideo+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+module Test.AWS.Gen.KinesisVideo where++import Data.Proxy+import Network.AWS.KinesisVideo+import Test.AWS.Fixture+import Test.AWS.KinesisVideo.Internal+import Test.AWS.Prelude+import Test.Tasty++-- Auto-generated: the actual test selection needs to be manually placed into+-- the top-level so that real test data can be incrementally added.+--+-- This commented snippet is what the entire set should look like:++-- fixtures :: TestTree+-- fixtures =+--     [ testGroup "request"+--         [ requestUntagStream $+--             untagStream+--+--         , requestUpdateDataRetention $+--             updateDataRetention+--+--         , requestGetDataEndpoint $+--             getDataEndpoint+--+--         , requestListTagsForStream $+--             listTagsForStream+--+--         , requestUpdateStream $+--             updateStream+--+--         , requestDeleteStream $+--             deleteStream+--+--         , requestListStreams $+--             listStreams+--+--         , requestCreateStream $+--             createStream+--+--         , requestTagStream $+--             tagStream+--+--         , requestDescribeStream $+--             describeStream+--+--           ]++--     , testGroup "response"+--         [ responseUntagStream $+--             untagStreamResponse+--+--         , responseUpdateDataRetention $+--             updateDataRetentionResponse+--+--         , responseGetDataEndpoint $+--             getDataEndpointResponse+--+--         , responseListTagsForStream $+--             listTagsForStreamResponse+--+--         , responseUpdateStream $+--             updateStreamResponse+--+--         , responseDeleteStream $+--             deleteStreamResponse+--+--         , responseListStreams $+--             listStreamsResponse+--+--         , responseCreateStream $+--             createStreamResponse+--+--         , responseTagStream $+--             tagStreamResponse+--+--         , responseDescribeStream $+--             describeStreamResponse+--+--           ]+--     ]++-- Requests++requestUntagStream :: UntagStream -> TestTree+requestUntagStream = req+    "UntagStream"+    "fixture/UntagStream.yaml"++requestUpdateDataRetention :: UpdateDataRetention -> TestTree+requestUpdateDataRetention = req+    "UpdateDataRetention"+    "fixture/UpdateDataRetention.yaml"++requestGetDataEndpoint :: GetDataEndpoint -> TestTree+requestGetDataEndpoint = req+    "GetDataEndpoint"+    "fixture/GetDataEndpoint.yaml"++requestListTagsForStream :: ListTagsForStream -> TestTree+requestListTagsForStream = req+    "ListTagsForStream"+    "fixture/ListTagsForStream.yaml"++requestUpdateStream :: UpdateStream -> TestTree+requestUpdateStream = req+    "UpdateStream"+    "fixture/UpdateStream.yaml"++requestDeleteStream :: DeleteStream -> TestTree+requestDeleteStream = req+    "DeleteStream"+    "fixture/DeleteStream.yaml"++requestListStreams :: ListStreams -> TestTree+requestListStreams = req+    "ListStreams"+    "fixture/ListStreams.yaml"++requestCreateStream :: CreateStream -> TestTree+requestCreateStream = req+    "CreateStream"+    "fixture/CreateStream.yaml"++requestTagStream :: TagStream -> TestTree+requestTagStream = req+    "TagStream"+    "fixture/TagStream.yaml"++requestDescribeStream :: DescribeStream -> TestTree+requestDescribeStream = req+    "DescribeStream"+    "fixture/DescribeStream.yaml"++-- Responses++responseUntagStream :: UntagStreamResponse -> TestTree+responseUntagStream = res+    "UntagStreamResponse"+    "fixture/UntagStreamResponse.proto"+    kinesisVideo+    (Proxy :: Proxy UntagStream)++responseUpdateDataRetention :: UpdateDataRetentionResponse -> TestTree+responseUpdateDataRetention = res+    "UpdateDataRetentionResponse"+    "fixture/UpdateDataRetentionResponse.proto"+    kinesisVideo+    (Proxy :: Proxy UpdateDataRetention)++responseGetDataEndpoint :: GetDataEndpointResponse -> TestTree+responseGetDataEndpoint = res+    "GetDataEndpointResponse"+    "fixture/GetDataEndpointResponse.proto"+    kinesisVideo+    (Proxy :: Proxy GetDataEndpoint)++responseListTagsForStream :: ListTagsForStreamResponse -> TestTree+responseListTagsForStream = res+    "ListTagsForStreamResponse"+    "fixture/ListTagsForStreamResponse.proto"+    kinesisVideo+    (Proxy :: Proxy ListTagsForStream)++responseUpdateStream :: UpdateStreamResponse -> TestTree+responseUpdateStream = res+    "UpdateStreamResponse"+    "fixture/UpdateStreamResponse.proto"+    kinesisVideo+    (Proxy :: Proxy UpdateStream)++responseDeleteStream :: DeleteStreamResponse -> TestTree+responseDeleteStream = res+    "DeleteStreamResponse"+    "fixture/DeleteStreamResponse.proto"+    kinesisVideo+    (Proxy :: Proxy DeleteStream)++responseListStreams :: ListStreamsResponse -> TestTree+responseListStreams = res+    "ListStreamsResponse"+    "fixture/ListStreamsResponse.proto"+    kinesisVideo+    (Proxy :: Proxy ListStreams)++responseCreateStream :: CreateStreamResponse -> TestTree+responseCreateStream = res+    "CreateStreamResponse"+    "fixture/CreateStreamResponse.proto"+    kinesisVideo+    (Proxy :: Proxy CreateStream)++responseTagStream :: TagStreamResponse -> TestTree+responseTagStream = res+    "TagStreamResponse"+    "fixture/TagStreamResponse.proto"+    kinesisVideo+    (Proxy :: Proxy TagStream)++responseDescribeStream :: DescribeStreamResponse -> TestTree+responseDescribeStream = res+    "DescribeStreamResponse"+    "fixture/DescribeStreamResponse.proto"+    kinesisVideo+    (Proxy :: Proxy DescribeStream)
+ test/Test/AWS/KinesisVideo.hs view
@@ -0,0 +1,20 @@+-- |+-- Module      : Test.AWS.KinesisVideo+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+module Test.AWS.KinesisVideo+    ( tests+    , fixtures+    ) where++import Test.Tasty (TestTree)++tests :: [TestTree]+tests = []++fixtures :: [TestTree]+fixtures = []
+ test/Test/AWS/KinesisVideo/Internal.hs view
@@ -0,0 +1,9 @@+-- |+-- Module      : Test.AWS.KinesisVideo.Internal+-- Copyright   : (c) 2013-2018 Brendan Hay+-- License     : Mozilla Public License, v. 2.0.+-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>+-- Stability   : auto-generated+-- Portability : non-portable (GHC extensions)+--+module Test.AWS.KinesisVideo.Internal where