{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

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

-- |
-- Module      : Amazonka.Chime.DeleteAppInstanceStreamingConfigurations
-- Copyright   : (c) 2013-2021 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 the streaming configurations of an @AppInstance@.
module Amazonka.Chime.DeleteAppInstanceStreamingConfigurations
  ( -- * Creating a Request
    DeleteAppInstanceStreamingConfigurations (..),
    newDeleteAppInstanceStreamingConfigurations,

    -- * Request Lenses
    deleteAppInstanceStreamingConfigurations_appInstanceArn,

    -- * Destructuring the Response
    DeleteAppInstanceStreamingConfigurationsResponse (..),
    newDeleteAppInstanceStreamingConfigurationsResponse,
  )
where

import Amazonka.Chime.Types
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response

-- | /See:/ 'newDeleteAppInstanceStreamingConfigurations' smart constructor.
data DeleteAppInstanceStreamingConfigurations = DeleteAppInstanceStreamingConfigurations'
  { -- | The ARN of the streaming configurations being deleted.
    DeleteAppInstanceStreamingConfigurations -> Text
appInstanceArn :: Prelude.Text
  }
  deriving (DeleteAppInstanceStreamingConfigurations
-> DeleteAppInstanceStreamingConfigurations -> Bool
(DeleteAppInstanceStreamingConfigurations
 -> DeleteAppInstanceStreamingConfigurations -> Bool)
-> (DeleteAppInstanceStreamingConfigurations
    -> DeleteAppInstanceStreamingConfigurations -> Bool)
-> Eq DeleteAppInstanceStreamingConfigurations
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteAppInstanceStreamingConfigurations
-> DeleteAppInstanceStreamingConfigurations -> Bool
$c/= :: DeleteAppInstanceStreamingConfigurations
-> DeleteAppInstanceStreamingConfigurations -> Bool
== :: DeleteAppInstanceStreamingConfigurations
-> DeleteAppInstanceStreamingConfigurations -> Bool
$c== :: DeleteAppInstanceStreamingConfigurations
-> DeleteAppInstanceStreamingConfigurations -> Bool
Prelude.Eq, ReadPrec [DeleteAppInstanceStreamingConfigurations]
ReadPrec DeleteAppInstanceStreamingConfigurations
Int -> ReadS DeleteAppInstanceStreamingConfigurations
ReadS [DeleteAppInstanceStreamingConfigurations]
(Int -> ReadS DeleteAppInstanceStreamingConfigurations)
-> ReadS [DeleteAppInstanceStreamingConfigurations]
-> ReadPrec DeleteAppInstanceStreamingConfigurations
-> ReadPrec [DeleteAppInstanceStreamingConfigurations]
-> Read DeleteAppInstanceStreamingConfigurations
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteAppInstanceStreamingConfigurations]
$creadListPrec :: ReadPrec [DeleteAppInstanceStreamingConfigurations]
readPrec :: ReadPrec DeleteAppInstanceStreamingConfigurations
$creadPrec :: ReadPrec DeleteAppInstanceStreamingConfigurations
readList :: ReadS [DeleteAppInstanceStreamingConfigurations]
$creadList :: ReadS [DeleteAppInstanceStreamingConfigurations]
readsPrec :: Int -> ReadS DeleteAppInstanceStreamingConfigurations
$creadsPrec :: Int -> ReadS DeleteAppInstanceStreamingConfigurations
Prelude.Read, Int -> DeleteAppInstanceStreamingConfigurations -> ShowS
[DeleteAppInstanceStreamingConfigurations] -> ShowS
DeleteAppInstanceStreamingConfigurations -> String
(Int -> DeleteAppInstanceStreamingConfigurations -> ShowS)
-> (DeleteAppInstanceStreamingConfigurations -> String)
-> ([DeleteAppInstanceStreamingConfigurations] -> ShowS)
-> Show DeleteAppInstanceStreamingConfigurations
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteAppInstanceStreamingConfigurations] -> ShowS
$cshowList :: [DeleteAppInstanceStreamingConfigurations] -> ShowS
show :: DeleteAppInstanceStreamingConfigurations -> String
$cshow :: DeleteAppInstanceStreamingConfigurations -> String
showsPrec :: Int -> DeleteAppInstanceStreamingConfigurations -> ShowS
$cshowsPrec :: Int -> DeleteAppInstanceStreamingConfigurations -> ShowS
Prelude.Show, (forall x.
 DeleteAppInstanceStreamingConfigurations
 -> Rep DeleteAppInstanceStreamingConfigurations x)
-> (forall x.
    Rep DeleteAppInstanceStreamingConfigurations x
    -> DeleteAppInstanceStreamingConfigurations)
-> Generic DeleteAppInstanceStreamingConfigurations
forall x.
Rep DeleteAppInstanceStreamingConfigurations x
-> DeleteAppInstanceStreamingConfigurations
forall x.
DeleteAppInstanceStreamingConfigurations
-> Rep DeleteAppInstanceStreamingConfigurations x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DeleteAppInstanceStreamingConfigurations x
-> DeleteAppInstanceStreamingConfigurations
$cfrom :: forall x.
DeleteAppInstanceStreamingConfigurations
-> Rep DeleteAppInstanceStreamingConfigurations x
Prelude.Generic)

-- |
-- Create a value of 'DeleteAppInstanceStreamingConfigurations' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'appInstanceArn', 'deleteAppInstanceStreamingConfigurations_appInstanceArn' - The ARN of the streaming configurations being deleted.
newDeleteAppInstanceStreamingConfigurations ::
  -- | 'appInstanceArn'
  Prelude.Text ->
  DeleteAppInstanceStreamingConfigurations
newDeleteAppInstanceStreamingConfigurations :: Text -> DeleteAppInstanceStreamingConfigurations
newDeleteAppInstanceStreamingConfigurations
  Text
pAppInstanceArn_ =
    DeleteAppInstanceStreamingConfigurations' :: Text -> DeleteAppInstanceStreamingConfigurations
DeleteAppInstanceStreamingConfigurations'
      { $sel:appInstanceArn:DeleteAppInstanceStreamingConfigurations' :: Text
appInstanceArn =
          Text
pAppInstanceArn_
      }

-- | The ARN of the streaming configurations being deleted.
deleteAppInstanceStreamingConfigurations_appInstanceArn :: Lens.Lens' DeleteAppInstanceStreamingConfigurations Prelude.Text
deleteAppInstanceStreamingConfigurations_appInstanceArn :: (Text -> f Text)
-> DeleteAppInstanceStreamingConfigurations
-> f DeleteAppInstanceStreamingConfigurations
deleteAppInstanceStreamingConfigurations_appInstanceArn = (DeleteAppInstanceStreamingConfigurations -> Text)
-> (DeleteAppInstanceStreamingConfigurations
    -> Text -> DeleteAppInstanceStreamingConfigurations)
-> Lens
     DeleteAppInstanceStreamingConfigurations
     DeleteAppInstanceStreamingConfigurations
     Text
     Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteAppInstanceStreamingConfigurations' {Text
appInstanceArn :: Text
$sel:appInstanceArn:DeleteAppInstanceStreamingConfigurations' :: DeleteAppInstanceStreamingConfigurations -> Text
appInstanceArn} -> Text
appInstanceArn) (\s :: DeleteAppInstanceStreamingConfigurations
s@DeleteAppInstanceStreamingConfigurations' {} Text
a -> DeleteAppInstanceStreamingConfigurations
s {$sel:appInstanceArn:DeleteAppInstanceStreamingConfigurations' :: Text
appInstanceArn = Text
a} :: DeleteAppInstanceStreamingConfigurations)

instance
  Core.AWSRequest
    DeleteAppInstanceStreamingConfigurations
  where
  type
    AWSResponse
      DeleteAppInstanceStreamingConfigurations =
      DeleteAppInstanceStreamingConfigurationsResponse
  request :: DeleteAppInstanceStreamingConfigurations
-> Request DeleteAppInstanceStreamingConfigurations
request = Service
-> DeleteAppInstanceStreamingConfigurations
-> Request DeleteAppInstanceStreamingConfigurations
forall a. ToRequest a => Service -> a -> Request a
Request.delete Service
defaultService
  response :: Logger
-> Service
-> Proxy DeleteAppInstanceStreamingConfigurations
-> ClientResponse ClientBody
-> m (Either
        Error
        (ClientResponse
           (AWSResponse DeleteAppInstanceStreamingConfigurations)))
response =
    AWSResponse DeleteAppInstanceStreamingConfigurations
-> Logger
-> Service
-> Proxy DeleteAppInstanceStreamingConfigurations
-> ClientResponse ClientBody
-> m (Either
        Error
        (ClientResponse
           (AWSResponse DeleteAppInstanceStreamingConfigurations)))
forall (m :: * -> *) a.
MonadResource m =>
AWSResponse a
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveNull
      AWSResponse DeleteAppInstanceStreamingConfigurations
DeleteAppInstanceStreamingConfigurationsResponse
DeleteAppInstanceStreamingConfigurationsResponse'

instance
  Prelude.Hashable
    DeleteAppInstanceStreamingConfigurations

instance
  Prelude.NFData
    DeleteAppInstanceStreamingConfigurations

instance
  Core.ToHeaders
    DeleteAppInstanceStreamingConfigurations
  where
  toHeaders :: DeleteAppInstanceStreamingConfigurations -> [Header]
toHeaders = [Header] -> DeleteAppInstanceStreamingConfigurations -> [Header]
forall a b. a -> b -> a
Prelude.const [Header]
forall a. Monoid a => a
Prelude.mempty

instance
  Core.ToPath
    DeleteAppInstanceStreamingConfigurations
  where
  toPath :: DeleteAppInstanceStreamingConfigurations -> ByteString
toPath DeleteAppInstanceStreamingConfigurations' {Text
appInstanceArn :: Text
$sel:appInstanceArn:DeleteAppInstanceStreamingConfigurations' :: DeleteAppInstanceStreamingConfigurations -> Text
..} =
    [ByteString] -> ByteString
forall a. Monoid a => [a] -> a
Prelude.mconcat
      [ ByteString
"/app-instances/",
        Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
appInstanceArn,
        ByteString
"/streaming-configurations"
      ]

instance
  Core.ToQuery
    DeleteAppInstanceStreamingConfigurations
  where
  toQuery :: DeleteAppInstanceStreamingConfigurations -> QueryString
toQuery = QueryString
-> DeleteAppInstanceStreamingConfigurations -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty

-- | /See:/ 'newDeleteAppInstanceStreamingConfigurationsResponse' smart constructor.
data DeleteAppInstanceStreamingConfigurationsResponse = DeleteAppInstanceStreamingConfigurationsResponse'
  {
  }
  deriving (DeleteAppInstanceStreamingConfigurationsResponse
-> DeleteAppInstanceStreamingConfigurationsResponse -> Bool
(DeleteAppInstanceStreamingConfigurationsResponse
 -> DeleteAppInstanceStreamingConfigurationsResponse -> Bool)
-> (DeleteAppInstanceStreamingConfigurationsResponse
    -> DeleteAppInstanceStreamingConfigurationsResponse -> Bool)
-> Eq DeleteAppInstanceStreamingConfigurationsResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteAppInstanceStreamingConfigurationsResponse
-> DeleteAppInstanceStreamingConfigurationsResponse -> Bool
$c/= :: DeleteAppInstanceStreamingConfigurationsResponse
-> DeleteAppInstanceStreamingConfigurationsResponse -> Bool
== :: DeleteAppInstanceStreamingConfigurationsResponse
-> DeleteAppInstanceStreamingConfigurationsResponse -> Bool
$c== :: DeleteAppInstanceStreamingConfigurationsResponse
-> DeleteAppInstanceStreamingConfigurationsResponse -> Bool
Prelude.Eq, ReadPrec [DeleteAppInstanceStreamingConfigurationsResponse]
ReadPrec DeleteAppInstanceStreamingConfigurationsResponse
Int -> ReadS DeleteAppInstanceStreamingConfigurationsResponse
ReadS [DeleteAppInstanceStreamingConfigurationsResponse]
(Int -> ReadS DeleteAppInstanceStreamingConfigurationsResponse)
-> ReadS [DeleteAppInstanceStreamingConfigurationsResponse]
-> ReadPrec DeleteAppInstanceStreamingConfigurationsResponse
-> ReadPrec [DeleteAppInstanceStreamingConfigurationsResponse]
-> Read DeleteAppInstanceStreamingConfigurationsResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteAppInstanceStreamingConfigurationsResponse]
$creadListPrec :: ReadPrec [DeleteAppInstanceStreamingConfigurationsResponse]
readPrec :: ReadPrec DeleteAppInstanceStreamingConfigurationsResponse
$creadPrec :: ReadPrec DeleteAppInstanceStreamingConfigurationsResponse
readList :: ReadS [DeleteAppInstanceStreamingConfigurationsResponse]
$creadList :: ReadS [DeleteAppInstanceStreamingConfigurationsResponse]
readsPrec :: Int -> ReadS DeleteAppInstanceStreamingConfigurationsResponse
$creadsPrec :: Int -> ReadS DeleteAppInstanceStreamingConfigurationsResponse
Prelude.Read, Int -> DeleteAppInstanceStreamingConfigurationsResponse -> ShowS
[DeleteAppInstanceStreamingConfigurationsResponse] -> ShowS
DeleteAppInstanceStreamingConfigurationsResponse -> String
(Int -> DeleteAppInstanceStreamingConfigurationsResponse -> ShowS)
-> (DeleteAppInstanceStreamingConfigurationsResponse -> String)
-> ([DeleteAppInstanceStreamingConfigurationsResponse] -> ShowS)
-> Show DeleteAppInstanceStreamingConfigurationsResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteAppInstanceStreamingConfigurationsResponse] -> ShowS
$cshowList :: [DeleteAppInstanceStreamingConfigurationsResponse] -> ShowS
show :: DeleteAppInstanceStreamingConfigurationsResponse -> String
$cshow :: DeleteAppInstanceStreamingConfigurationsResponse -> String
showsPrec :: Int -> DeleteAppInstanceStreamingConfigurationsResponse -> ShowS
$cshowsPrec :: Int -> DeleteAppInstanceStreamingConfigurationsResponse -> ShowS
Prelude.Show, (forall x.
 DeleteAppInstanceStreamingConfigurationsResponse
 -> Rep DeleteAppInstanceStreamingConfigurationsResponse x)
-> (forall x.
    Rep DeleteAppInstanceStreamingConfigurationsResponse x
    -> DeleteAppInstanceStreamingConfigurationsResponse)
-> Generic DeleteAppInstanceStreamingConfigurationsResponse
forall x.
Rep DeleteAppInstanceStreamingConfigurationsResponse x
-> DeleteAppInstanceStreamingConfigurationsResponse
forall x.
DeleteAppInstanceStreamingConfigurationsResponse
-> Rep DeleteAppInstanceStreamingConfigurationsResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DeleteAppInstanceStreamingConfigurationsResponse x
-> DeleteAppInstanceStreamingConfigurationsResponse
$cfrom :: forall x.
DeleteAppInstanceStreamingConfigurationsResponse
-> Rep DeleteAppInstanceStreamingConfigurationsResponse x
Prelude.Generic)

-- |
-- Create a value of 'DeleteAppInstanceStreamingConfigurationsResponse' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
newDeleteAppInstanceStreamingConfigurationsResponse ::
  DeleteAppInstanceStreamingConfigurationsResponse
newDeleteAppInstanceStreamingConfigurationsResponse :: DeleteAppInstanceStreamingConfigurationsResponse
newDeleteAppInstanceStreamingConfigurationsResponse =
  DeleteAppInstanceStreamingConfigurationsResponse
DeleteAppInstanceStreamingConfigurationsResponse'

instance
  Prelude.NFData
    DeleteAppInstanceStreamingConfigurationsResponse