{-# 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.DeleteMediaCapturePipeline
-- 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 media capture pipeline.
module Amazonka.Chime.DeleteMediaCapturePipeline
  ( -- * Creating a Request
    DeleteMediaCapturePipeline (..),
    newDeleteMediaCapturePipeline,

    -- * Request Lenses
    deleteMediaCapturePipeline_mediaPipelineId,

    -- * Destructuring the Response
    DeleteMediaCapturePipelineResponse (..),
    newDeleteMediaCapturePipelineResponse,
  )
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:/ 'newDeleteMediaCapturePipeline' smart constructor.
data DeleteMediaCapturePipeline = DeleteMediaCapturePipeline'
  { -- | The ID of the media capture pipeline being deleted.
    DeleteMediaCapturePipeline -> Text
mediaPipelineId :: Prelude.Text
  }
  deriving (DeleteMediaCapturePipeline -> DeleteMediaCapturePipeline -> Bool
(DeleteMediaCapturePipeline -> DeleteMediaCapturePipeline -> Bool)
-> (DeleteMediaCapturePipeline
    -> DeleteMediaCapturePipeline -> Bool)
-> Eq DeleteMediaCapturePipeline
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteMediaCapturePipeline -> DeleteMediaCapturePipeline -> Bool
$c/= :: DeleteMediaCapturePipeline -> DeleteMediaCapturePipeline -> Bool
== :: DeleteMediaCapturePipeline -> DeleteMediaCapturePipeline -> Bool
$c== :: DeleteMediaCapturePipeline -> DeleteMediaCapturePipeline -> Bool
Prelude.Eq, ReadPrec [DeleteMediaCapturePipeline]
ReadPrec DeleteMediaCapturePipeline
Int -> ReadS DeleteMediaCapturePipeline
ReadS [DeleteMediaCapturePipeline]
(Int -> ReadS DeleteMediaCapturePipeline)
-> ReadS [DeleteMediaCapturePipeline]
-> ReadPrec DeleteMediaCapturePipeline
-> ReadPrec [DeleteMediaCapturePipeline]
-> Read DeleteMediaCapturePipeline
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteMediaCapturePipeline]
$creadListPrec :: ReadPrec [DeleteMediaCapturePipeline]
readPrec :: ReadPrec DeleteMediaCapturePipeline
$creadPrec :: ReadPrec DeleteMediaCapturePipeline
readList :: ReadS [DeleteMediaCapturePipeline]
$creadList :: ReadS [DeleteMediaCapturePipeline]
readsPrec :: Int -> ReadS DeleteMediaCapturePipeline
$creadsPrec :: Int -> ReadS DeleteMediaCapturePipeline
Prelude.Read, Int -> DeleteMediaCapturePipeline -> ShowS
[DeleteMediaCapturePipeline] -> ShowS
DeleteMediaCapturePipeline -> String
(Int -> DeleteMediaCapturePipeline -> ShowS)
-> (DeleteMediaCapturePipeline -> String)
-> ([DeleteMediaCapturePipeline] -> ShowS)
-> Show DeleteMediaCapturePipeline
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteMediaCapturePipeline] -> ShowS
$cshowList :: [DeleteMediaCapturePipeline] -> ShowS
show :: DeleteMediaCapturePipeline -> String
$cshow :: DeleteMediaCapturePipeline -> String
showsPrec :: Int -> DeleteMediaCapturePipeline -> ShowS
$cshowsPrec :: Int -> DeleteMediaCapturePipeline -> ShowS
Prelude.Show, (forall x.
 DeleteMediaCapturePipeline -> Rep DeleteMediaCapturePipeline x)
-> (forall x.
    Rep DeleteMediaCapturePipeline x -> DeleteMediaCapturePipeline)
-> Generic DeleteMediaCapturePipeline
forall x.
Rep DeleteMediaCapturePipeline x -> DeleteMediaCapturePipeline
forall x.
DeleteMediaCapturePipeline -> Rep DeleteMediaCapturePipeline x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DeleteMediaCapturePipeline x -> DeleteMediaCapturePipeline
$cfrom :: forall x.
DeleteMediaCapturePipeline -> Rep DeleteMediaCapturePipeline x
Prelude.Generic)

-- |
-- Create a value of 'DeleteMediaCapturePipeline' 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:
--
-- 'mediaPipelineId', 'deleteMediaCapturePipeline_mediaPipelineId' - The ID of the media capture pipeline being deleted.
newDeleteMediaCapturePipeline ::
  -- | 'mediaPipelineId'
  Prelude.Text ->
  DeleteMediaCapturePipeline
newDeleteMediaCapturePipeline :: Text -> DeleteMediaCapturePipeline
newDeleteMediaCapturePipeline Text
pMediaPipelineId_ =
  DeleteMediaCapturePipeline' :: Text -> DeleteMediaCapturePipeline
DeleteMediaCapturePipeline'
    { $sel:mediaPipelineId:DeleteMediaCapturePipeline' :: Text
mediaPipelineId =
        Text
pMediaPipelineId_
    }

-- | The ID of the media capture pipeline being deleted.
deleteMediaCapturePipeline_mediaPipelineId :: Lens.Lens' DeleteMediaCapturePipeline Prelude.Text
deleteMediaCapturePipeline_mediaPipelineId :: (Text -> f Text)
-> DeleteMediaCapturePipeline -> f DeleteMediaCapturePipeline
deleteMediaCapturePipeline_mediaPipelineId = (DeleteMediaCapturePipeline -> Text)
-> (DeleteMediaCapturePipeline
    -> Text -> DeleteMediaCapturePipeline)
-> Lens
     DeleteMediaCapturePipeline DeleteMediaCapturePipeline Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteMediaCapturePipeline' {Text
mediaPipelineId :: Text
$sel:mediaPipelineId:DeleteMediaCapturePipeline' :: DeleteMediaCapturePipeline -> Text
mediaPipelineId} -> Text
mediaPipelineId) (\s :: DeleteMediaCapturePipeline
s@DeleteMediaCapturePipeline' {} Text
a -> DeleteMediaCapturePipeline
s {$sel:mediaPipelineId:DeleteMediaCapturePipeline' :: Text
mediaPipelineId = Text
a} :: DeleteMediaCapturePipeline)

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

instance Prelude.Hashable DeleteMediaCapturePipeline

instance Prelude.NFData DeleteMediaCapturePipeline

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

instance Core.ToPath DeleteMediaCapturePipeline where
  toPath :: DeleteMediaCapturePipeline -> ByteString
toPath DeleteMediaCapturePipeline' {Text
mediaPipelineId :: Text
$sel:mediaPipelineId:DeleteMediaCapturePipeline' :: DeleteMediaCapturePipeline -> Text
..} =
    [ByteString] -> ByteString
forall a. Monoid a => [a] -> a
Prelude.mconcat
      [ ByteString
"/media-capture-pipelines/",
        Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
mediaPipelineId
      ]

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

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

-- |
-- Create a value of 'DeleteMediaCapturePipelineResponse' 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.
newDeleteMediaCapturePipelineResponse ::
  DeleteMediaCapturePipelineResponse
newDeleteMediaCapturePipelineResponse :: DeleteMediaCapturePipelineResponse
newDeleteMediaCapturePipelineResponse =
  DeleteMediaCapturePipelineResponse
DeleteMediaCapturePipelineResponse'

instance
  Prelude.NFData
    DeleteMediaCapturePipelineResponse