{-# 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.ServiceCatalog.BatchDisassociateServiceActionFromProvisioningArtifact
-- 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)
--
-- Disassociates a batch of self-service actions from the specified
-- provisioning artifact.
module Amazonka.ServiceCatalog.BatchDisassociateServiceActionFromProvisioningArtifact
  ( -- * Creating a Request
    BatchDisassociateServiceActionFromProvisioningArtifact (..),
    newBatchDisassociateServiceActionFromProvisioningArtifact,

    -- * Request Lenses
    batchDisassociateServiceActionFromProvisioningArtifact_acceptLanguage,
    batchDisassociateServiceActionFromProvisioningArtifact_serviceActionAssociations,

    -- * Destructuring the Response
    BatchDisassociateServiceActionFromProvisioningArtifactResponse (..),
    newBatchDisassociateServiceActionFromProvisioningArtifactResponse,

    -- * Response Lenses
    batchDisassociateServiceActionFromProvisioningArtifactResponse_failedServiceActionAssociations,
    batchDisassociateServiceActionFromProvisioningArtifactResponse_httpStatus,
  )
where

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
import Amazonka.ServiceCatalog.Types

-- | /See:/ 'newBatchDisassociateServiceActionFromProvisioningArtifact' smart constructor.
data BatchDisassociateServiceActionFromProvisioningArtifact = BatchDisassociateServiceActionFromProvisioningArtifact'
  { -- | The language code.
    --
    -- -   @en@ - English (default)
    --
    -- -   @jp@ - Japanese
    --
    -- -   @zh@ - Chinese
    BatchDisassociateServiceActionFromProvisioningArtifact
-> Maybe Text
acceptLanguage :: Prelude.Maybe Prelude.Text,
    -- | One or more associations, each consisting of the Action ID, the Product
    -- ID, and the Provisioning Artifact ID.
    BatchDisassociateServiceActionFromProvisioningArtifact
-> NonEmpty ServiceActionAssociation
serviceActionAssociations :: Prelude.NonEmpty ServiceActionAssociation
  }
  deriving (BatchDisassociateServiceActionFromProvisioningArtifact
-> BatchDisassociateServiceActionFromProvisioningArtifact -> Bool
(BatchDisassociateServiceActionFromProvisioningArtifact
 -> BatchDisassociateServiceActionFromProvisioningArtifact -> Bool)
-> (BatchDisassociateServiceActionFromProvisioningArtifact
    -> BatchDisassociateServiceActionFromProvisioningArtifact -> Bool)
-> Eq BatchDisassociateServiceActionFromProvisioningArtifact
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: BatchDisassociateServiceActionFromProvisioningArtifact
-> BatchDisassociateServiceActionFromProvisioningArtifact -> Bool
$c/= :: BatchDisassociateServiceActionFromProvisioningArtifact
-> BatchDisassociateServiceActionFromProvisioningArtifact -> Bool
== :: BatchDisassociateServiceActionFromProvisioningArtifact
-> BatchDisassociateServiceActionFromProvisioningArtifact -> Bool
$c== :: BatchDisassociateServiceActionFromProvisioningArtifact
-> BatchDisassociateServiceActionFromProvisioningArtifact -> Bool
Prelude.Eq, ReadPrec [BatchDisassociateServiceActionFromProvisioningArtifact]
ReadPrec BatchDisassociateServiceActionFromProvisioningArtifact
Int -> ReadS BatchDisassociateServiceActionFromProvisioningArtifact
ReadS [BatchDisassociateServiceActionFromProvisioningArtifact]
(Int
 -> ReadS BatchDisassociateServiceActionFromProvisioningArtifact)
-> ReadS [BatchDisassociateServiceActionFromProvisioningArtifact]
-> ReadPrec BatchDisassociateServiceActionFromProvisioningArtifact
-> ReadPrec
     [BatchDisassociateServiceActionFromProvisioningArtifact]
-> Read BatchDisassociateServiceActionFromProvisioningArtifact
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [BatchDisassociateServiceActionFromProvisioningArtifact]
$creadListPrec :: ReadPrec [BatchDisassociateServiceActionFromProvisioningArtifact]
readPrec :: ReadPrec BatchDisassociateServiceActionFromProvisioningArtifact
$creadPrec :: ReadPrec BatchDisassociateServiceActionFromProvisioningArtifact
readList :: ReadS [BatchDisassociateServiceActionFromProvisioningArtifact]
$creadList :: ReadS [BatchDisassociateServiceActionFromProvisioningArtifact]
readsPrec :: Int -> ReadS BatchDisassociateServiceActionFromProvisioningArtifact
$creadsPrec :: Int -> ReadS BatchDisassociateServiceActionFromProvisioningArtifact
Prelude.Read, Int
-> BatchDisassociateServiceActionFromProvisioningArtifact -> ShowS
[BatchDisassociateServiceActionFromProvisioningArtifact] -> ShowS
BatchDisassociateServiceActionFromProvisioningArtifact -> String
(Int
 -> BatchDisassociateServiceActionFromProvisioningArtifact -> ShowS)
-> (BatchDisassociateServiceActionFromProvisioningArtifact
    -> String)
-> ([BatchDisassociateServiceActionFromProvisioningArtifact]
    -> ShowS)
-> Show BatchDisassociateServiceActionFromProvisioningArtifact
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [BatchDisassociateServiceActionFromProvisioningArtifact] -> ShowS
$cshowList :: [BatchDisassociateServiceActionFromProvisioningArtifact] -> ShowS
show :: BatchDisassociateServiceActionFromProvisioningArtifact -> String
$cshow :: BatchDisassociateServiceActionFromProvisioningArtifact -> String
showsPrec :: Int
-> BatchDisassociateServiceActionFromProvisioningArtifact -> ShowS
$cshowsPrec :: Int
-> BatchDisassociateServiceActionFromProvisioningArtifact -> ShowS
Prelude.Show, (forall x.
 BatchDisassociateServiceActionFromProvisioningArtifact
 -> Rep BatchDisassociateServiceActionFromProvisioningArtifact x)
-> (forall x.
    Rep BatchDisassociateServiceActionFromProvisioningArtifact x
    -> BatchDisassociateServiceActionFromProvisioningArtifact)
-> Generic BatchDisassociateServiceActionFromProvisioningArtifact
forall x.
Rep BatchDisassociateServiceActionFromProvisioningArtifact x
-> BatchDisassociateServiceActionFromProvisioningArtifact
forall x.
BatchDisassociateServiceActionFromProvisioningArtifact
-> Rep BatchDisassociateServiceActionFromProvisioningArtifact x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep BatchDisassociateServiceActionFromProvisioningArtifact x
-> BatchDisassociateServiceActionFromProvisioningArtifact
$cfrom :: forall x.
BatchDisassociateServiceActionFromProvisioningArtifact
-> Rep BatchDisassociateServiceActionFromProvisioningArtifact x
Prelude.Generic)

-- |
-- Create a value of 'BatchDisassociateServiceActionFromProvisioningArtifact' 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:
--
-- 'acceptLanguage', 'batchDisassociateServiceActionFromProvisioningArtifact_acceptLanguage' - The language code.
--
-- -   @en@ - English (default)
--
-- -   @jp@ - Japanese
--
-- -   @zh@ - Chinese
--
-- 'serviceActionAssociations', 'batchDisassociateServiceActionFromProvisioningArtifact_serviceActionAssociations' - One or more associations, each consisting of the Action ID, the Product
-- ID, and the Provisioning Artifact ID.
newBatchDisassociateServiceActionFromProvisioningArtifact ::
  -- | 'serviceActionAssociations'
  Prelude.NonEmpty ServiceActionAssociation ->
  BatchDisassociateServiceActionFromProvisioningArtifact
newBatchDisassociateServiceActionFromProvisioningArtifact :: NonEmpty ServiceActionAssociation
-> BatchDisassociateServiceActionFromProvisioningArtifact
newBatchDisassociateServiceActionFromProvisioningArtifact
  NonEmpty ServiceActionAssociation
pServiceActionAssociations_ =
    BatchDisassociateServiceActionFromProvisioningArtifact' :: Maybe Text
-> NonEmpty ServiceActionAssociation
-> BatchDisassociateServiceActionFromProvisioningArtifact
BatchDisassociateServiceActionFromProvisioningArtifact'
      { $sel:acceptLanguage:BatchDisassociateServiceActionFromProvisioningArtifact' :: Maybe Text
acceptLanguage =
          Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:serviceActionAssociations:BatchDisassociateServiceActionFromProvisioningArtifact' :: NonEmpty ServiceActionAssociation
serviceActionAssociations =
          Tagged
  (NonEmpty ServiceActionAssociation)
  (Identity (NonEmpty ServiceActionAssociation))
-> Tagged
     (NonEmpty ServiceActionAssociation)
     (Identity (NonEmpty ServiceActionAssociation))
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
            (Tagged
   (NonEmpty ServiceActionAssociation)
   (Identity (NonEmpty ServiceActionAssociation))
 -> Tagged
      (NonEmpty ServiceActionAssociation)
      (Identity (NonEmpty ServiceActionAssociation)))
-> NonEmpty ServiceActionAssociation
-> NonEmpty ServiceActionAssociation
forall t b. AReview t b -> b -> t
Lens.# NonEmpty ServiceActionAssociation
pServiceActionAssociations_
      }

-- | The language code.
--
-- -   @en@ - English (default)
--
-- -   @jp@ - Japanese
--
-- -   @zh@ - Chinese
batchDisassociateServiceActionFromProvisioningArtifact_acceptLanguage :: Lens.Lens' BatchDisassociateServiceActionFromProvisioningArtifact (Prelude.Maybe Prelude.Text)
batchDisassociateServiceActionFromProvisioningArtifact_acceptLanguage :: (Maybe Text -> f (Maybe Text))
-> BatchDisassociateServiceActionFromProvisioningArtifact
-> f BatchDisassociateServiceActionFromProvisioningArtifact
batchDisassociateServiceActionFromProvisioningArtifact_acceptLanguage = (BatchDisassociateServiceActionFromProvisioningArtifact
 -> Maybe Text)
-> (BatchDisassociateServiceActionFromProvisioningArtifact
    -> Maybe Text
    -> BatchDisassociateServiceActionFromProvisioningArtifact)
-> Lens
     BatchDisassociateServiceActionFromProvisioningArtifact
     BatchDisassociateServiceActionFromProvisioningArtifact
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BatchDisassociateServiceActionFromProvisioningArtifact' {Maybe Text
acceptLanguage :: Maybe Text
$sel:acceptLanguage:BatchDisassociateServiceActionFromProvisioningArtifact' :: BatchDisassociateServiceActionFromProvisioningArtifact
-> Maybe Text
acceptLanguage} -> Maybe Text
acceptLanguage) (\s :: BatchDisassociateServiceActionFromProvisioningArtifact
s@BatchDisassociateServiceActionFromProvisioningArtifact' {} Maybe Text
a -> BatchDisassociateServiceActionFromProvisioningArtifact
s {$sel:acceptLanguage:BatchDisassociateServiceActionFromProvisioningArtifact' :: Maybe Text
acceptLanguage = Maybe Text
a} :: BatchDisassociateServiceActionFromProvisioningArtifact)

-- | One or more associations, each consisting of the Action ID, the Product
-- ID, and the Provisioning Artifact ID.
batchDisassociateServiceActionFromProvisioningArtifact_serviceActionAssociations :: Lens.Lens' BatchDisassociateServiceActionFromProvisioningArtifact (Prelude.NonEmpty ServiceActionAssociation)
batchDisassociateServiceActionFromProvisioningArtifact_serviceActionAssociations :: (NonEmpty ServiceActionAssociation
 -> f (NonEmpty ServiceActionAssociation))
-> BatchDisassociateServiceActionFromProvisioningArtifact
-> f BatchDisassociateServiceActionFromProvisioningArtifact
batchDisassociateServiceActionFromProvisioningArtifact_serviceActionAssociations = (BatchDisassociateServiceActionFromProvisioningArtifact
 -> NonEmpty ServiceActionAssociation)
-> (BatchDisassociateServiceActionFromProvisioningArtifact
    -> NonEmpty ServiceActionAssociation
    -> BatchDisassociateServiceActionFromProvisioningArtifact)
-> Lens
     BatchDisassociateServiceActionFromProvisioningArtifact
     BatchDisassociateServiceActionFromProvisioningArtifact
     (NonEmpty ServiceActionAssociation)
     (NonEmpty ServiceActionAssociation)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BatchDisassociateServiceActionFromProvisioningArtifact' {NonEmpty ServiceActionAssociation
serviceActionAssociations :: NonEmpty ServiceActionAssociation
$sel:serviceActionAssociations:BatchDisassociateServiceActionFromProvisioningArtifact' :: BatchDisassociateServiceActionFromProvisioningArtifact
-> NonEmpty ServiceActionAssociation
serviceActionAssociations} -> NonEmpty ServiceActionAssociation
serviceActionAssociations) (\s :: BatchDisassociateServiceActionFromProvisioningArtifact
s@BatchDisassociateServiceActionFromProvisioningArtifact' {} NonEmpty ServiceActionAssociation
a -> BatchDisassociateServiceActionFromProvisioningArtifact
s {$sel:serviceActionAssociations:BatchDisassociateServiceActionFromProvisioningArtifact' :: NonEmpty ServiceActionAssociation
serviceActionAssociations = NonEmpty ServiceActionAssociation
a} :: BatchDisassociateServiceActionFromProvisioningArtifact) ((NonEmpty ServiceActionAssociation
  -> f (NonEmpty ServiceActionAssociation))
 -> BatchDisassociateServiceActionFromProvisioningArtifact
 -> f BatchDisassociateServiceActionFromProvisioningArtifact)
-> ((NonEmpty ServiceActionAssociation
     -> f (NonEmpty ServiceActionAssociation))
    -> NonEmpty ServiceActionAssociation
    -> f (NonEmpty ServiceActionAssociation))
-> (NonEmpty ServiceActionAssociation
    -> f (NonEmpty ServiceActionAssociation))
-> BatchDisassociateServiceActionFromProvisioningArtifact
-> f BatchDisassociateServiceActionFromProvisioningArtifact
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (NonEmpty ServiceActionAssociation
 -> f (NonEmpty ServiceActionAssociation))
-> NonEmpty ServiceActionAssociation
-> f (NonEmpty ServiceActionAssociation)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

instance
  Core.AWSRequest
    BatchDisassociateServiceActionFromProvisioningArtifact
  where
  type
    AWSResponse
      BatchDisassociateServiceActionFromProvisioningArtifact =
      BatchDisassociateServiceActionFromProvisioningArtifactResponse
  request :: BatchDisassociateServiceActionFromProvisioningArtifact
-> Request BatchDisassociateServiceActionFromProvisioningArtifact
request = Service
-> BatchDisassociateServiceActionFromProvisioningArtifact
-> Request BatchDisassociateServiceActionFromProvisioningArtifact
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy BatchDisassociateServiceActionFromProvisioningArtifact
-> ClientResponse ClientBody
-> m (Either
        Error
        (ClientResponse
           (AWSResponse
              BatchDisassociateServiceActionFromProvisioningArtifact)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either
      String
      (AWSResponse
         BatchDisassociateServiceActionFromProvisioningArtifact))
-> Logger
-> Service
-> Proxy BatchDisassociateServiceActionFromProvisioningArtifact
-> ClientResponse ClientBody
-> m (Either
        Error
        (ClientResponse
           (AWSResponse
              BatchDisassociateServiceActionFromProvisioningArtifact)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
      ( \Int
s ResponseHeaders
h Object
x ->
          Maybe [FailedServiceActionAssociation]
-> Int
-> BatchDisassociateServiceActionFromProvisioningArtifactResponse
BatchDisassociateServiceActionFromProvisioningArtifactResponse'
            (Maybe [FailedServiceActionAssociation]
 -> Int
 -> BatchDisassociateServiceActionFromProvisioningArtifactResponse)
-> Either String (Maybe [FailedServiceActionAssociation])
-> Either
     String
     (Int
      -> BatchDisassociateServiceActionFromProvisioningArtifactResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ( Object
x Object
-> Text
-> Either String (Maybe (Maybe [FailedServiceActionAssociation]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"FailedServiceActionAssociations"
                            Either String (Maybe (Maybe [FailedServiceActionAssociation]))
-> Maybe [FailedServiceActionAssociation]
-> Either String (Maybe [FailedServiceActionAssociation])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [FailedServiceActionAssociation]
forall a. Monoid a => a
Prelude.mempty
                        )
              Either
  String
  (Int
   -> BatchDisassociateServiceActionFromProvisioningArtifactResponse)
-> Either String Int
-> Either
     String
     BatchDisassociateServiceActionFromProvisioningArtifactResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Int -> Either String Int
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (Int -> Int
forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
      )

instance
  Prelude.Hashable
    BatchDisassociateServiceActionFromProvisioningArtifact

instance
  Prelude.NFData
    BatchDisassociateServiceActionFromProvisioningArtifact

instance
  Core.ToHeaders
    BatchDisassociateServiceActionFromProvisioningArtifact
  where
  toHeaders :: BatchDisassociateServiceActionFromProvisioningArtifact
-> ResponseHeaders
toHeaders =
    ResponseHeaders
-> BatchDisassociateServiceActionFromProvisioningArtifact
-> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
      ( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
          [ HeaderName
"X-Amz-Target"
              HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"AWS242ServiceCatalogService.BatchDisassociateServiceActionFromProvisioningArtifact" ::
                          Prelude.ByteString
                      ),
            HeaderName
"Content-Type"
              HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"application/x-amz-json-1.1" ::
                          Prelude.ByteString
                      )
          ]
      )

instance
  Core.ToJSON
    BatchDisassociateServiceActionFromProvisioningArtifact
  where
  toJSON :: BatchDisassociateServiceActionFromProvisioningArtifact -> Value
toJSON
    BatchDisassociateServiceActionFromProvisioningArtifact' {Maybe Text
NonEmpty ServiceActionAssociation
serviceActionAssociations :: NonEmpty ServiceActionAssociation
acceptLanguage :: Maybe Text
$sel:serviceActionAssociations:BatchDisassociateServiceActionFromProvisioningArtifact' :: BatchDisassociateServiceActionFromProvisioningArtifact
-> NonEmpty ServiceActionAssociation
$sel:acceptLanguage:BatchDisassociateServiceActionFromProvisioningArtifact' :: BatchDisassociateServiceActionFromProvisioningArtifact
-> Maybe Text
..} =
      [Pair] -> Value
Core.object
        ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
            [ (Text
"AcceptLanguage" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
                (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
acceptLanguage,
              Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just
                ( Text
"ServiceActionAssociations"
                    Text -> NonEmpty ServiceActionAssociation -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= NonEmpty ServiceActionAssociation
serviceActionAssociations
                )
            ]
        )

instance
  Core.ToPath
    BatchDisassociateServiceActionFromProvisioningArtifact
  where
  toPath :: BatchDisassociateServiceActionFromProvisioningArtifact
-> ByteString
toPath = ByteString
-> BatchDisassociateServiceActionFromProvisioningArtifact
-> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"

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

-- | /See:/ 'newBatchDisassociateServiceActionFromProvisioningArtifactResponse' smart constructor.
data BatchDisassociateServiceActionFromProvisioningArtifactResponse = BatchDisassociateServiceActionFromProvisioningArtifactResponse'
  { -- | An object that contains a list of errors, along with information to help
    -- you identify the self-service action.
    BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> Maybe [FailedServiceActionAssociation]
failedServiceActionAssociations :: Prelude.Maybe [FailedServiceActionAssociation],
    -- | The response's http status code.
    BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> Int
httpStatus :: Prelude.Int
  }
  deriving (BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> Bool
(BatchDisassociateServiceActionFromProvisioningArtifactResponse
 -> BatchDisassociateServiceActionFromProvisioningArtifactResponse
 -> Bool)
-> (BatchDisassociateServiceActionFromProvisioningArtifactResponse
    -> BatchDisassociateServiceActionFromProvisioningArtifactResponse
    -> Bool)
-> Eq
     BatchDisassociateServiceActionFromProvisioningArtifactResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> Bool
$c/= :: BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> Bool
== :: BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> Bool
$c== :: BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> Bool
Prelude.Eq, ReadPrec
  [BatchDisassociateServiceActionFromProvisioningArtifactResponse]
ReadPrec
  BatchDisassociateServiceActionFromProvisioningArtifactResponse
Int
-> ReadS
     BatchDisassociateServiceActionFromProvisioningArtifactResponse
ReadS
  [BatchDisassociateServiceActionFromProvisioningArtifactResponse]
(Int
 -> ReadS
      BatchDisassociateServiceActionFromProvisioningArtifactResponse)
-> ReadS
     [BatchDisassociateServiceActionFromProvisioningArtifactResponse]
-> ReadPrec
     BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> ReadPrec
     [BatchDisassociateServiceActionFromProvisioningArtifactResponse]
-> Read
     BatchDisassociateServiceActionFromProvisioningArtifactResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec
  [BatchDisassociateServiceActionFromProvisioningArtifactResponse]
$creadListPrec :: ReadPrec
  [BatchDisassociateServiceActionFromProvisioningArtifactResponse]
readPrec :: ReadPrec
  BatchDisassociateServiceActionFromProvisioningArtifactResponse
$creadPrec :: ReadPrec
  BatchDisassociateServiceActionFromProvisioningArtifactResponse
readList :: ReadS
  [BatchDisassociateServiceActionFromProvisioningArtifactResponse]
$creadList :: ReadS
  [BatchDisassociateServiceActionFromProvisioningArtifactResponse]
readsPrec :: Int
-> ReadS
     BatchDisassociateServiceActionFromProvisioningArtifactResponse
$creadsPrec :: Int
-> ReadS
     BatchDisassociateServiceActionFromProvisioningArtifactResponse
Prelude.Read, Int
-> BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> ShowS
[BatchDisassociateServiceActionFromProvisioningArtifactResponse]
-> ShowS
BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> String
(Int
 -> BatchDisassociateServiceActionFromProvisioningArtifactResponse
 -> ShowS)
-> (BatchDisassociateServiceActionFromProvisioningArtifactResponse
    -> String)
-> ([BatchDisassociateServiceActionFromProvisioningArtifactResponse]
    -> ShowS)
-> Show
     BatchDisassociateServiceActionFromProvisioningArtifactResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [BatchDisassociateServiceActionFromProvisioningArtifactResponse]
-> ShowS
$cshowList :: [BatchDisassociateServiceActionFromProvisioningArtifactResponse]
-> ShowS
show :: BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> String
$cshow :: BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> String
showsPrec :: Int
-> BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> ShowS
$cshowsPrec :: Int
-> BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> ShowS
Prelude.Show, (forall x.
 BatchDisassociateServiceActionFromProvisioningArtifactResponse
 -> Rep
      BatchDisassociateServiceActionFromProvisioningArtifactResponse x)
-> (forall x.
    Rep
      BatchDisassociateServiceActionFromProvisioningArtifactResponse x
    -> BatchDisassociateServiceActionFromProvisioningArtifactResponse)
-> Generic
     BatchDisassociateServiceActionFromProvisioningArtifactResponse
forall x.
Rep
  BatchDisassociateServiceActionFromProvisioningArtifactResponse x
-> BatchDisassociateServiceActionFromProvisioningArtifactResponse
forall x.
BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> Rep
     BatchDisassociateServiceActionFromProvisioningArtifactResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep
  BatchDisassociateServiceActionFromProvisioningArtifactResponse x
-> BatchDisassociateServiceActionFromProvisioningArtifactResponse
$cfrom :: forall x.
BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> Rep
     BatchDisassociateServiceActionFromProvisioningArtifactResponse x
Prelude.Generic)

-- |
-- Create a value of 'BatchDisassociateServiceActionFromProvisioningArtifactResponse' 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:
--
-- 'failedServiceActionAssociations', 'batchDisassociateServiceActionFromProvisioningArtifactResponse_failedServiceActionAssociations' - An object that contains a list of errors, along with information to help
-- you identify the self-service action.
--
-- 'httpStatus', 'batchDisassociateServiceActionFromProvisioningArtifactResponse_httpStatus' - The response's http status code.
newBatchDisassociateServiceActionFromProvisioningArtifactResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  BatchDisassociateServiceActionFromProvisioningArtifactResponse
newBatchDisassociateServiceActionFromProvisioningArtifactResponse :: Int
-> BatchDisassociateServiceActionFromProvisioningArtifactResponse
newBatchDisassociateServiceActionFromProvisioningArtifactResponse
  Int
pHttpStatus_ =
    BatchDisassociateServiceActionFromProvisioningArtifactResponse' :: Maybe [FailedServiceActionAssociation]
-> Int
-> BatchDisassociateServiceActionFromProvisioningArtifactResponse
BatchDisassociateServiceActionFromProvisioningArtifactResponse'
      { $sel:failedServiceActionAssociations:BatchDisassociateServiceActionFromProvisioningArtifactResponse' :: Maybe [FailedServiceActionAssociation]
failedServiceActionAssociations =
          Maybe [FailedServiceActionAssociation]
forall a. Maybe a
Prelude.Nothing,
        $sel:httpStatus:BatchDisassociateServiceActionFromProvisioningArtifactResponse' :: Int
httpStatus =
          Int
pHttpStatus_
      }

-- | An object that contains a list of errors, along with information to help
-- you identify the self-service action.
batchDisassociateServiceActionFromProvisioningArtifactResponse_failedServiceActionAssociations :: Lens.Lens' BatchDisassociateServiceActionFromProvisioningArtifactResponse (Prelude.Maybe [FailedServiceActionAssociation])
batchDisassociateServiceActionFromProvisioningArtifactResponse_failedServiceActionAssociations :: (Maybe [FailedServiceActionAssociation]
 -> f (Maybe [FailedServiceActionAssociation]))
-> BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> f BatchDisassociateServiceActionFromProvisioningArtifactResponse
batchDisassociateServiceActionFromProvisioningArtifactResponse_failedServiceActionAssociations = (BatchDisassociateServiceActionFromProvisioningArtifactResponse
 -> Maybe [FailedServiceActionAssociation])
-> (BatchDisassociateServiceActionFromProvisioningArtifactResponse
    -> Maybe [FailedServiceActionAssociation]
    -> BatchDisassociateServiceActionFromProvisioningArtifactResponse)
-> Lens
     BatchDisassociateServiceActionFromProvisioningArtifactResponse
     BatchDisassociateServiceActionFromProvisioningArtifactResponse
     (Maybe [FailedServiceActionAssociation])
     (Maybe [FailedServiceActionAssociation])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BatchDisassociateServiceActionFromProvisioningArtifactResponse' {Maybe [FailedServiceActionAssociation]
failedServiceActionAssociations :: Maybe [FailedServiceActionAssociation]
$sel:failedServiceActionAssociations:BatchDisassociateServiceActionFromProvisioningArtifactResponse' :: BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> Maybe [FailedServiceActionAssociation]
failedServiceActionAssociations} -> Maybe [FailedServiceActionAssociation]
failedServiceActionAssociations) (\s :: BatchDisassociateServiceActionFromProvisioningArtifactResponse
s@BatchDisassociateServiceActionFromProvisioningArtifactResponse' {} Maybe [FailedServiceActionAssociation]
a -> BatchDisassociateServiceActionFromProvisioningArtifactResponse
s {$sel:failedServiceActionAssociations:BatchDisassociateServiceActionFromProvisioningArtifactResponse' :: Maybe [FailedServiceActionAssociation]
failedServiceActionAssociations = Maybe [FailedServiceActionAssociation]
a} :: BatchDisassociateServiceActionFromProvisioningArtifactResponse) ((Maybe [FailedServiceActionAssociation]
  -> f (Maybe [FailedServiceActionAssociation]))
 -> BatchDisassociateServiceActionFromProvisioningArtifactResponse
 -> f BatchDisassociateServiceActionFromProvisioningArtifactResponse)
-> ((Maybe [FailedServiceActionAssociation]
     -> f (Maybe [FailedServiceActionAssociation]))
    -> Maybe [FailedServiceActionAssociation]
    -> f (Maybe [FailedServiceActionAssociation]))
-> (Maybe [FailedServiceActionAssociation]
    -> f (Maybe [FailedServiceActionAssociation]))
-> BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> f BatchDisassociateServiceActionFromProvisioningArtifactResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [FailedServiceActionAssociation]
  [FailedServiceActionAssociation]
  [FailedServiceActionAssociation]
  [FailedServiceActionAssociation]
-> Iso
     (Maybe [FailedServiceActionAssociation])
     (Maybe [FailedServiceActionAssociation])
     (Maybe [FailedServiceActionAssociation])
     (Maybe [FailedServiceActionAssociation])
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso
  [FailedServiceActionAssociation]
  [FailedServiceActionAssociation]
  [FailedServiceActionAssociation]
  [FailedServiceActionAssociation]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The response's http status code.
batchDisassociateServiceActionFromProvisioningArtifactResponse_httpStatus :: Lens.Lens' BatchDisassociateServiceActionFromProvisioningArtifactResponse Prelude.Int
batchDisassociateServiceActionFromProvisioningArtifactResponse_httpStatus :: (Int -> f Int)
-> BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> f BatchDisassociateServiceActionFromProvisioningArtifactResponse
batchDisassociateServiceActionFromProvisioningArtifactResponse_httpStatus = (BatchDisassociateServiceActionFromProvisioningArtifactResponse
 -> Int)
-> (BatchDisassociateServiceActionFromProvisioningArtifactResponse
    -> Int
    -> BatchDisassociateServiceActionFromProvisioningArtifactResponse)
-> Lens
     BatchDisassociateServiceActionFromProvisioningArtifactResponse
     BatchDisassociateServiceActionFromProvisioningArtifactResponse
     Int
     Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BatchDisassociateServiceActionFromProvisioningArtifactResponse' {Int
httpStatus :: Int
$sel:httpStatus:BatchDisassociateServiceActionFromProvisioningArtifactResponse' :: BatchDisassociateServiceActionFromProvisioningArtifactResponse
-> Int
httpStatus} -> Int
httpStatus) (\s :: BatchDisassociateServiceActionFromProvisioningArtifactResponse
s@BatchDisassociateServiceActionFromProvisioningArtifactResponse' {} Int
a -> BatchDisassociateServiceActionFromProvisioningArtifactResponse
s {$sel:httpStatus:BatchDisassociateServiceActionFromProvisioningArtifactResponse' :: Int
httpStatus = Int
a} :: BatchDisassociateServiceActionFromProvisioningArtifactResponse)

instance
  Prelude.NFData
    BatchDisassociateServiceActionFromProvisioningArtifactResponse