amazonka-omics-2.0: gen/Amazonka/Omics/DeleteWorkflow.hs
{-# 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.Omics.DeleteWorkflow
-- Copyright : (c) 2013-2023 Brendan Hay
-- License : Mozilla Public License, v. 2.0.
-- Maintainer : Brendan Hay
-- Stability : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Deletes a workflow.
module Amazonka.Omics.DeleteWorkflow
( -- * Creating a Request
DeleteWorkflow (..),
newDeleteWorkflow,
-- * Request Lenses
deleteWorkflow_id,
-- * Destructuring the Response
DeleteWorkflowResponse (..),
newDeleteWorkflowResponse,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.Omics.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
-- | /See:/ 'newDeleteWorkflow' smart constructor.
data DeleteWorkflow = DeleteWorkflow'
{ -- | The workflow\'s ID.
id :: Prelude.Text
}
deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)
-- |
-- Create a value of 'DeleteWorkflow' 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:
--
-- 'id', 'deleteWorkflow_id' - The workflow\'s ID.
newDeleteWorkflow ::
-- | 'id'
Prelude.Text ->
DeleteWorkflow
newDeleteWorkflow pId_ = DeleteWorkflow' {id = pId_}
-- | The workflow\'s ID.
deleteWorkflow_id :: Lens.Lens' DeleteWorkflow Prelude.Text
deleteWorkflow_id = Lens.lens (\DeleteWorkflow' {id} -> id) (\s@DeleteWorkflow' {} a -> s {id = a} :: DeleteWorkflow)
instance Core.AWSRequest DeleteWorkflow where
type
AWSResponse DeleteWorkflow =
DeleteWorkflowResponse
request overrides =
Request.delete (overrides defaultService)
response =
Response.receiveNull DeleteWorkflowResponse'
instance Prelude.Hashable DeleteWorkflow where
hashWithSalt _salt DeleteWorkflow' {..} =
_salt `Prelude.hashWithSalt` id
instance Prelude.NFData DeleteWorkflow where
rnf DeleteWorkflow' {..} = Prelude.rnf id
instance Data.ToHeaders DeleteWorkflow where
toHeaders =
Prelude.const
( Prelude.mconcat
[ "Content-Type"
Data.=# ( "application/x-amz-json-1.1" ::
Prelude.ByteString
)
]
)
instance Data.ToPath DeleteWorkflow where
toPath DeleteWorkflow' {..} =
Prelude.mconcat ["/workflow/", Data.toBS id]
instance Data.ToQuery DeleteWorkflow where
toQuery = Prelude.const Prelude.mempty
-- | /See:/ 'newDeleteWorkflowResponse' smart constructor.
data DeleteWorkflowResponse = DeleteWorkflowResponse'
{
}
deriving (Prelude.Eq, Prelude.Read, Prelude.Show, Prelude.Generic)
-- |
-- Create a value of 'DeleteWorkflowResponse' 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.
newDeleteWorkflowResponse ::
DeleteWorkflowResponse
newDeleteWorkflowResponse = DeleteWorkflowResponse'
instance Prelude.NFData DeleteWorkflowResponse where
rnf _ = ()