{-# 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.UpdateProvisionedProduct
-- 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)
--
-- Requests updates to the configuration of the specified provisioned
-- product.
--
-- If there are tags associated with the object, they cannot be updated or
-- added. Depending on the specific updates requested, this operation can
-- update with no interruption, with some interruption, or replace the
-- provisioned product entirely.
--
-- You can check the status of this request using DescribeRecord.
module Amazonka.ServiceCatalog.UpdateProvisionedProduct
  ( -- * Creating a Request
    UpdateProvisionedProduct (..),
    newUpdateProvisionedProduct,

    -- * Request Lenses
    updateProvisionedProduct_productName,
    updateProvisionedProduct_provisionedProductName,
    updateProvisionedProduct_provisioningArtifactId,
    updateProvisionedProduct_provisioningArtifactName,
    updateProvisionedProduct_pathName,
    updateProvisionedProduct_acceptLanguage,
    updateProvisionedProduct_pathId,
    updateProvisionedProduct_provisioningParameters,
    updateProvisionedProduct_provisionedProductId,
    updateProvisionedProduct_productId,
    updateProvisionedProduct_tags,
    updateProvisionedProduct_provisioningPreferences,
    updateProvisionedProduct_updateToken,

    -- * Destructuring the Response
    UpdateProvisionedProductResponse (..),
    newUpdateProvisionedProductResponse,

    -- * Response Lenses
    updateProvisionedProductResponse_recordDetail,
    updateProvisionedProductResponse_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:/ 'newUpdateProvisionedProduct' smart constructor.
data UpdateProvisionedProduct = UpdateProvisionedProduct'
  { -- | The name of the product. You must provide the name or ID, but not both.
    UpdateProvisionedProduct -> Maybe Text
productName :: Prelude.Maybe Prelude.Text,
    -- | The name of the provisioned product. You cannot specify both
    -- @ProvisionedProductName@ and @ProvisionedProductId@.
    UpdateProvisionedProduct -> Maybe Text
provisionedProductName :: Prelude.Maybe Prelude.Text,
    -- | The identifier of the provisioning artifact.
    UpdateProvisionedProduct -> Maybe Text
provisioningArtifactId :: Prelude.Maybe Prelude.Text,
    -- | The name of the provisioning artifact. You must provide the name or ID,
    -- but not both.
    UpdateProvisionedProduct -> Maybe Text
provisioningArtifactName :: Prelude.Maybe Prelude.Text,
    -- | The name of the path. You must provide the name or ID, but not both.
    UpdateProvisionedProduct -> Maybe Text
pathName :: Prelude.Maybe Prelude.Text,
    -- | The language code.
    --
    -- -   @en@ - English (default)
    --
    -- -   @jp@ - Japanese
    --
    -- -   @zh@ - Chinese
    UpdateProvisionedProduct -> Maybe Text
acceptLanguage :: Prelude.Maybe Prelude.Text,
    -- | The path identifier. This value is optional if the product has a default
    -- path, and required if the product has more than one path. You must
    -- provide the name or ID, but not both.
    UpdateProvisionedProduct -> Maybe Text
pathId :: Prelude.Maybe Prelude.Text,
    -- | The new parameters.
    UpdateProvisionedProduct -> Maybe [UpdateProvisioningParameter]
provisioningParameters :: Prelude.Maybe [UpdateProvisioningParameter],
    -- | The identifier of the provisioned product. You must provide the name or
    -- ID, but not both.
    UpdateProvisionedProduct -> Maybe Text
provisionedProductId :: Prelude.Maybe Prelude.Text,
    -- | The identifier of the product. You must provide the name or ID, but not
    -- both.
    UpdateProvisionedProduct -> Maybe Text
productId :: Prelude.Maybe Prelude.Text,
    -- | One or more tags. Requires the product to have @RESOURCE_UPDATE@
    -- constraint with @TagUpdatesOnProvisionedProduct@ set to @ALLOWED@ to
    -- allow tag updates.
    UpdateProvisionedProduct -> Maybe [Tag]
tags :: Prelude.Maybe [Tag],
    -- | An object that contains information about the provisioning preferences
    -- for a stack set.
    UpdateProvisionedProduct -> Maybe UpdateProvisioningPreferences
provisioningPreferences :: Prelude.Maybe UpdateProvisioningPreferences,
    -- | The idempotency token that uniquely identifies the provisioning update
    -- request.
    UpdateProvisionedProduct -> Text
updateToken :: Prelude.Text
  }
  deriving (UpdateProvisionedProduct -> UpdateProvisionedProduct -> Bool
(UpdateProvisionedProduct -> UpdateProvisionedProduct -> Bool)
-> (UpdateProvisionedProduct -> UpdateProvisionedProduct -> Bool)
-> Eq UpdateProvisionedProduct
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateProvisionedProduct -> UpdateProvisionedProduct -> Bool
$c/= :: UpdateProvisionedProduct -> UpdateProvisionedProduct -> Bool
== :: UpdateProvisionedProduct -> UpdateProvisionedProduct -> Bool
$c== :: UpdateProvisionedProduct -> UpdateProvisionedProduct -> Bool
Prelude.Eq, ReadPrec [UpdateProvisionedProduct]
ReadPrec UpdateProvisionedProduct
Int -> ReadS UpdateProvisionedProduct
ReadS [UpdateProvisionedProduct]
(Int -> ReadS UpdateProvisionedProduct)
-> ReadS [UpdateProvisionedProduct]
-> ReadPrec UpdateProvisionedProduct
-> ReadPrec [UpdateProvisionedProduct]
-> Read UpdateProvisionedProduct
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateProvisionedProduct]
$creadListPrec :: ReadPrec [UpdateProvisionedProduct]
readPrec :: ReadPrec UpdateProvisionedProduct
$creadPrec :: ReadPrec UpdateProvisionedProduct
readList :: ReadS [UpdateProvisionedProduct]
$creadList :: ReadS [UpdateProvisionedProduct]
readsPrec :: Int -> ReadS UpdateProvisionedProduct
$creadsPrec :: Int -> ReadS UpdateProvisionedProduct
Prelude.Read, Int -> UpdateProvisionedProduct -> ShowS
[UpdateProvisionedProduct] -> ShowS
UpdateProvisionedProduct -> String
(Int -> UpdateProvisionedProduct -> ShowS)
-> (UpdateProvisionedProduct -> String)
-> ([UpdateProvisionedProduct] -> ShowS)
-> Show UpdateProvisionedProduct
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateProvisionedProduct] -> ShowS
$cshowList :: [UpdateProvisionedProduct] -> ShowS
show :: UpdateProvisionedProduct -> String
$cshow :: UpdateProvisionedProduct -> String
showsPrec :: Int -> UpdateProvisionedProduct -> ShowS
$cshowsPrec :: Int -> UpdateProvisionedProduct -> ShowS
Prelude.Show, (forall x.
 UpdateProvisionedProduct -> Rep UpdateProvisionedProduct x)
-> (forall x.
    Rep UpdateProvisionedProduct x -> UpdateProvisionedProduct)
-> Generic UpdateProvisionedProduct
forall x.
Rep UpdateProvisionedProduct x -> UpdateProvisionedProduct
forall x.
UpdateProvisionedProduct -> Rep UpdateProvisionedProduct x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep UpdateProvisionedProduct x -> UpdateProvisionedProduct
$cfrom :: forall x.
UpdateProvisionedProduct -> Rep UpdateProvisionedProduct x
Prelude.Generic)

-- |
-- Create a value of 'UpdateProvisionedProduct' 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:
--
-- 'productName', 'updateProvisionedProduct_productName' - The name of the product. You must provide the name or ID, but not both.
--
-- 'provisionedProductName', 'updateProvisionedProduct_provisionedProductName' - The name of the provisioned product. You cannot specify both
-- @ProvisionedProductName@ and @ProvisionedProductId@.
--
-- 'provisioningArtifactId', 'updateProvisionedProduct_provisioningArtifactId' - The identifier of the provisioning artifact.
--
-- 'provisioningArtifactName', 'updateProvisionedProduct_provisioningArtifactName' - The name of the provisioning artifact. You must provide the name or ID,
-- but not both.
--
-- 'pathName', 'updateProvisionedProduct_pathName' - The name of the path. You must provide the name or ID, but not both.
--
-- 'acceptLanguage', 'updateProvisionedProduct_acceptLanguage' - The language code.
--
-- -   @en@ - English (default)
--
-- -   @jp@ - Japanese
--
-- -   @zh@ - Chinese
--
-- 'pathId', 'updateProvisionedProduct_pathId' - The path identifier. This value is optional if the product has a default
-- path, and required if the product has more than one path. You must
-- provide the name or ID, but not both.
--
-- 'provisioningParameters', 'updateProvisionedProduct_provisioningParameters' - The new parameters.
--
-- 'provisionedProductId', 'updateProvisionedProduct_provisionedProductId' - The identifier of the provisioned product. You must provide the name or
-- ID, but not both.
--
-- 'productId', 'updateProvisionedProduct_productId' - The identifier of the product. You must provide the name or ID, but not
-- both.
--
-- 'tags', 'updateProvisionedProduct_tags' - One or more tags. Requires the product to have @RESOURCE_UPDATE@
-- constraint with @TagUpdatesOnProvisionedProduct@ set to @ALLOWED@ to
-- allow tag updates.
--
-- 'provisioningPreferences', 'updateProvisionedProduct_provisioningPreferences' - An object that contains information about the provisioning preferences
-- for a stack set.
--
-- 'updateToken', 'updateProvisionedProduct_updateToken' - The idempotency token that uniquely identifies the provisioning update
-- request.
newUpdateProvisionedProduct ::
  -- | 'updateToken'
  Prelude.Text ->
  UpdateProvisionedProduct
newUpdateProvisionedProduct :: Text -> UpdateProvisionedProduct
newUpdateProvisionedProduct Text
pUpdateToken_ =
  UpdateProvisionedProduct' :: Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe [UpdateProvisioningParameter]
-> Maybe Text
-> Maybe Text
-> Maybe [Tag]
-> Maybe UpdateProvisioningPreferences
-> Text
-> UpdateProvisionedProduct
UpdateProvisionedProduct'
    { $sel:productName:UpdateProvisionedProduct' :: Maybe Text
productName =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:provisionedProductName:UpdateProvisionedProduct' :: Maybe Text
provisionedProductName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:provisioningArtifactId:UpdateProvisionedProduct' :: Maybe Text
provisioningArtifactId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:provisioningArtifactName:UpdateProvisionedProduct' :: Maybe Text
provisioningArtifactName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:pathName:UpdateProvisionedProduct' :: Maybe Text
pathName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:acceptLanguage:UpdateProvisionedProduct' :: Maybe Text
acceptLanguage = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:pathId:UpdateProvisionedProduct' :: Maybe Text
pathId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:provisioningParameters:UpdateProvisionedProduct' :: Maybe [UpdateProvisioningParameter]
provisioningParameters = Maybe [UpdateProvisioningParameter]
forall a. Maybe a
Prelude.Nothing,
      $sel:provisionedProductId:UpdateProvisionedProduct' :: Maybe Text
provisionedProductId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:productId:UpdateProvisionedProduct' :: Maybe Text
productId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:tags:UpdateProvisionedProduct' :: Maybe [Tag]
tags = Maybe [Tag]
forall a. Maybe a
Prelude.Nothing,
      $sel:provisioningPreferences:UpdateProvisionedProduct' :: Maybe UpdateProvisioningPreferences
provisioningPreferences = Maybe UpdateProvisioningPreferences
forall a. Maybe a
Prelude.Nothing,
      $sel:updateToken:UpdateProvisionedProduct' :: Text
updateToken = Text
pUpdateToken_
    }

-- | The name of the product. You must provide the name or ID, but not both.
updateProvisionedProduct_productName :: Lens.Lens' UpdateProvisionedProduct (Prelude.Maybe Prelude.Text)
updateProvisionedProduct_productName :: (Maybe Text -> f (Maybe Text))
-> UpdateProvisionedProduct -> f UpdateProvisionedProduct
updateProvisionedProduct_productName = (UpdateProvisionedProduct -> Maybe Text)
-> (UpdateProvisionedProduct
    -> Maybe Text -> UpdateProvisionedProduct)
-> Lens
     UpdateProvisionedProduct
     UpdateProvisionedProduct
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateProvisionedProduct' {Maybe Text
productName :: Maybe Text
$sel:productName:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe Text
productName} -> Maybe Text
productName) (\s :: UpdateProvisionedProduct
s@UpdateProvisionedProduct' {} Maybe Text
a -> UpdateProvisionedProduct
s {$sel:productName:UpdateProvisionedProduct' :: Maybe Text
productName = Maybe Text
a} :: UpdateProvisionedProduct)

-- | The name of the provisioned product. You cannot specify both
-- @ProvisionedProductName@ and @ProvisionedProductId@.
updateProvisionedProduct_provisionedProductName :: Lens.Lens' UpdateProvisionedProduct (Prelude.Maybe Prelude.Text)
updateProvisionedProduct_provisionedProductName :: (Maybe Text -> f (Maybe Text))
-> UpdateProvisionedProduct -> f UpdateProvisionedProduct
updateProvisionedProduct_provisionedProductName = (UpdateProvisionedProduct -> Maybe Text)
-> (UpdateProvisionedProduct
    -> Maybe Text -> UpdateProvisionedProduct)
-> Lens
     UpdateProvisionedProduct
     UpdateProvisionedProduct
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateProvisionedProduct' {Maybe Text
provisionedProductName :: Maybe Text
$sel:provisionedProductName:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe Text
provisionedProductName} -> Maybe Text
provisionedProductName) (\s :: UpdateProvisionedProduct
s@UpdateProvisionedProduct' {} Maybe Text
a -> UpdateProvisionedProduct
s {$sel:provisionedProductName:UpdateProvisionedProduct' :: Maybe Text
provisionedProductName = Maybe Text
a} :: UpdateProvisionedProduct)

-- | The identifier of the provisioning artifact.
updateProvisionedProduct_provisioningArtifactId :: Lens.Lens' UpdateProvisionedProduct (Prelude.Maybe Prelude.Text)
updateProvisionedProduct_provisioningArtifactId :: (Maybe Text -> f (Maybe Text))
-> UpdateProvisionedProduct -> f UpdateProvisionedProduct
updateProvisionedProduct_provisioningArtifactId = (UpdateProvisionedProduct -> Maybe Text)
-> (UpdateProvisionedProduct
    -> Maybe Text -> UpdateProvisionedProduct)
-> Lens
     UpdateProvisionedProduct
     UpdateProvisionedProduct
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateProvisionedProduct' {Maybe Text
provisioningArtifactId :: Maybe Text
$sel:provisioningArtifactId:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe Text
provisioningArtifactId} -> Maybe Text
provisioningArtifactId) (\s :: UpdateProvisionedProduct
s@UpdateProvisionedProduct' {} Maybe Text
a -> UpdateProvisionedProduct
s {$sel:provisioningArtifactId:UpdateProvisionedProduct' :: Maybe Text
provisioningArtifactId = Maybe Text
a} :: UpdateProvisionedProduct)

-- | The name of the provisioning artifact. You must provide the name or ID,
-- but not both.
updateProvisionedProduct_provisioningArtifactName :: Lens.Lens' UpdateProvisionedProduct (Prelude.Maybe Prelude.Text)
updateProvisionedProduct_provisioningArtifactName :: (Maybe Text -> f (Maybe Text))
-> UpdateProvisionedProduct -> f UpdateProvisionedProduct
updateProvisionedProduct_provisioningArtifactName = (UpdateProvisionedProduct -> Maybe Text)
-> (UpdateProvisionedProduct
    -> Maybe Text -> UpdateProvisionedProduct)
-> Lens
     UpdateProvisionedProduct
     UpdateProvisionedProduct
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateProvisionedProduct' {Maybe Text
provisioningArtifactName :: Maybe Text
$sel:provisioningArtifactName:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe Text
provisioningArtifactName} -> Maybe Text
provisioningArtifactName) (\s :: UpdateProvisionedProduct
s@UpdateProvisionedProduct' {} Maybe Text
a -> UpdateProvisionedProduct
s {$sel:provisioningArtifactName:UpdateProvisionedProduct' :: Maybe Text
provisioningArtifactName = Maybe Text
a} :: UpdateProvisionedProduct)

-- | The name of the path. You must provide the name or ID, but not both.
updateProvisionedProduct_pathName :: Lens.Lens' UpdateProvisionedProduct (Prelude.Maybe Prelude.Text)
updateProvisionedProduct_pathName :: (Maybe Text -> f (Maybe Text))
-> UpdateProvisionedProduct -> f UpdateProvisionedProduct
updateProvisionedProduct_pathName = (UpdateProvisionedProduct -> Maybe Text)
-> (UpdateProvisionedProduct
    -> Maybe Text -> UpdateProvisionedProduct)
-> Lens
     UpdateProvisionedProduct
     UpdateProvisionedProduct
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateProvisionedProduct' {Maybe Text
pathName :: Maybe Text
$sel:pathName:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe Text
pathName} -> Maybe Text
pathName) (\s :: UpdateProvisionedProduct
s@UpdateProvisionedProduct' {} Maybe Text
a -> UpdateProvisionedProduct
s {$sel:pathName:UpdateProvisionedProduct' :: Maybe Text
pathName = Maybe Text
a} :: UpdateProvisionedProduct)

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

-- | The path identifier. This value is optional if the product has a default
-- path, and required if the product has more than one path. You must
-- provide the name or ID, but not both.
updateProvisionedProduct_pathId :: Lens.Lens' UpdateProvisionedProduct (Prelude.Maybe Prelude.Text)
updateProvisionedProduct_pathId :: (Maybe Text -> f (Maybe Text))
-> UpdateProvisionedProduct -> f UpdateProvisionedProduct
updateProvisionedProduct_pathId = (UpdateProvisionedProduct -> Maybe Text)
-> (UpdateProvisionedProduct
    -> Maybe Text -> UpdateProvisionedProduct)
-> Lens
     UpdateProvisionedProduct
     UpdateProvisionedProduct
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateProvisionedProduct' {Maybe Text
pathId :: Maybe Text
$sel:pathId:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe Text
pathId} -> Maybe Text
pathId) (\s :: UpdateProvisionedProduct
s@UpdateProvisionedProduct' {} Maybe Text
a -> UpdateProvisionedProduct
s {$sel:pathId:UpdateProvisionedProduct' :: Maybe Text
pathId = Maybe Text
a} :: UpdateProvisionedProduct)

-- | The new parameters.
updateProvisionedProduct_provisioningParameters :: Lens.Lens' UpdateProvisionedProduct (Prelude.Maybe [UpdateProvisioningParameter])
updateProvisionedProduct_provisioningParameters :: (Maybe [UpdateProvisioningParameter]
 -> f (Maybe [UpdateProvisioningParameter]))
-> UpdateProvisionedProduct -> f UpdateProvisionedProduct
updateProvisionedProduct_provisioningParameters = (UpdateProvisionedProduct -> Maybe [UpdateProvisioningParameter])
-> (UpdateProvisionedProduct
    -> Maybe [UpdateProvisioningParameter] -> UpdateProvisionedProduct)
-> Lens
     UpdateProvisionedProduct
     UpdateProvisionedProduct
     (Maybe [UpdateProvisioningParameter])
     (Maybe [UpdateProvisioningParameter])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateProvisionedProduct' {Maybe [UpdateProvisioningParameter]
provisioningParameters :: Maybe [UpdateProvisioningParameter]
$sel:provisioningParameters:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe [UpdateProvisioningParameter]
provisioningParameters} -> Maybe [UpdateProvisioningParameter]
provisioningParameters) (\s :: UpdateProvisionedProduct
s@UpdateProvisionedProduct' {} Maybe [UpdateProvisioningParameter]
a -> UpdateProvisionedProduct
s {$sel:provisioningParameters:UpdateProvisionedProduct' :: Maybe [UpdateProvisioningParameter]
provisioningParameters = Maybe [UpdateProvisioningParameter]
a} :: UpdateProvisionedProduct) ((Maybe [UpdateProvisioningParameter]
  -> f (Maybe [UpdateProvisioningParameter]))
 -> UpdateProvisionedProduct -> f UpdateProvisionedProduct)
-> ((Maybe [UpdateProvisioningParameter]
     -> f (Maybe [UpdateProvisioningParameter]))
    -> Maybe [UpdateProvisioningParameter]
    -> f (Maybe [UpdateProvisioningParameter]))
-> (Maybe [UpdateProvisioningParameter]
    -> f (Maybe [UpdateProvisioningParameter]))
-> UpdateProvisionedProduct
-> f UpdateProvisionedProduct
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [UpdateProvisioningParameter]
  [UpdateProvisioningParameter]
  [UpdateProvisioningParameter]
  [UpdateProvisioningParameter]
-> Iso
     (Maybe [UpdateProvisioningParameter])
     (Maybe [UpdateProvisioningParameter])
     (Maybe [UpdateProvisioningParameter])
     (Maybe [UpdateProvisioningParameter])
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
  [UpdateProvisioningParameter]
  [UpdateProvisioningParameter]
  [UpdateProvisioningParameter]
  [UpdateProvisioningParameter]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The identifier of the provisioned product. You must provide the name or
-- ID, but not both.
updateProvisionedProduct_provisionedProductId :: Lens.Lens' UpdateProvisionedProduct (Prelude.Maybe Prelude.Text)
updateProvisionedProduct_provisionedProductId :: (Maybe Text -> f (Maybe Text))
-> UpdateProvisionedProduct -> f UpdateProvisionedProduct
updateProvisionedProduct_provisionedProductId = (UpdateProvisionedProduct -> Maybe Text)
-> (UpdateProvisionedProduct
    -> Maybe Text -> UpdateProvisionedProduct)
-> Lens
     UpdateProvisionedProduct
     UpdateProvisionedProduct
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateProvisionedProduct' {Maybe Text
provisionedProductId :: Maybe Text
$sel:provisionedProductId:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe Text
provisionedProductId} -> Maybe Text
provisionedProductId) (\s :: UpdateProvisionedProduct
s@UpdateProvisionedProduct' {} Maybe Text
a -> UpdateProvisionedProduct
s {$sel:provisionedProductId:UpdateProvisionedProduct' :: Maybe Text
provisionedProductId = Maybe Text
a} :: UpdateProvisionedProduct)

-- | The identifier of the product. You must provide the name or ID, but not
-- both.
updateProvisionedProduct_productId :: Lens.Lens' UpdateProvisionedProduct (Prelude.Maybe Prelude.Text)
updateProvisionedProduct_productId :: (Maybe Text -> f (Maybe Text))
-> UpdateProvisionedProduct -> f UpdateProvisionedProduct
updateProvisionedProduct_productId = (UpdateProvisionedProduct -> Maybe Text)
-> (UpdateProvisionedProduct
    -> Maybe Text -> UpdateProvisionedProduct)
-> Lens
     UpdateProvisionedProduct
     UpdateProvisionedProduct
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateProvisionedProduct' {Maybe Text
productId :: Maybe Text
$sel:productId:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe Text
productId} -> Maybe Text
productId) (\s :: UpdateProvisionedProduct
s@UpdateProvisionedProduct' {} Maybe Text
a -> UpdateProvisionedProduct
s {$sel:productId:UpdateProvisionedProduct' :: Maybe Text
productId = Maybe Text
a} :: UpdateProvisionedProduct)

-- | One or more tags. Requires the product to have @RESOURCE_UPDATE@
-- constraint with @TagUpdatesOnProvisionedProduct@ set to @ALLOWED@ to
-- allow tag updates.
updateProvisionedProduct_tags :: Lens.Lens' UpdateProvisionedProduct (Prelude.Maybe [Tag])
updateProvisionedProduct_tags :: (Maybe [Tag] -> f (Maybe [Tag]))
-> UpdateProvisionedProduct -> f UpdateProvisionedProduct
updateProvisionedProduct_tags = (UpdateProvisionedProduct -> Maybe [Tag])
-> (UpdateProvisionedProduct
    -> Maybe [Tag] -> UpdateProvisionedProduct)
-> Lens
     UpdateProvisionedProduct
     UpdateProvisionedProduct
     (Maybe [Tag])
     (Maybe [Tag])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateProvisionedProduct' {Maybe [Tag]
tags :: Maybe [Tag]
$sel:tags:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe [Tag]
tags} -> Maybe [Tag]
tags) (\s :: UpdateProvisionedProduct
s@UpdateProvisionedProduct' {} Maybe [Tag]
a -> UpdateProvisionedProduct
s {$sel:tags:UpdateProvisionedProduct' :: Maybe [Tag]
tags = Maybe [Tag]
a} :: UpdateProvisionedProduct) ((Maybe [Tag] -> f (Maybe [Tag]))
 -> UpdateProvisionedProduct -> f UpdateProvisionedProduct)
-> ((Maybe [Tag] -> f (Maybe [Tag]))
    -> Maybe [Tag] -> f (Maybe [Tag]))
-> (Maybe [Tag] -> f (Maybe [Tag]))
-> UpdateProvisionedProduct
-> f UpdateProvisionedProduct
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Tag] [Tag] [Tag] [Tag]
-> Iso (Maybe [Tag]) (Maybe [Tag]) (Maybe [Tag]) (Maybe [Tag])
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 [Tag] [Tag] [Tag] [Tag]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | An object that contains information about the provisioning preferences
-- for a stack set.
updateProvisionedProduct_provisioningPreferences :: Lens.Lens' UpdateProvisionedProduct (Prelude.Maybe UpdateProvisioningPreferences)
updateProvisionedProduct_provisioningPreferences :: (Maybe UpdateProvisioningPreferences
 -> f (Maybe UpdateProvisioningPreferences))
-> UpdateProvisionedProduct -> f UpdateProvisionedProduct
updateProvisionedProduct_provisioningPreferences = (UpdateProvisionedProduct -> Maybe UpdateProvisioningPreferences)
-> (UpdateProvisionedProduct
    -> Maybe UpdateProvisioningPreferences -> UpdateProvisionedProduct)
-> Lens
     UpdateProvisionedProduct
     UpdateProvisionedProduct
     (Maybe UpdateProvisioningPreferences)
     (Maybe UpdateProvisioningPreferences)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateProvisionedProduct' {Maybe UpdateProvisioningPreferences
provisioningPreferences :: Maybe UpdateProvisioningPreferences
$sel:provisioningPreferences:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe UpdateProvisioningPreferences
provisioningPreferences} -> Maybe UpdateProvisioningPreferences
provisioningPreferences) (\s :: UpdateProvisionedProduct
s@UpdateProvisionedProduct' {} Maybe UpdateProvisioningPreferences
a -> UpdateProvisionedProduct
s {$sel:provisioningPreferences:UpdateProvisionedProduct' :: Maybe UpdateProvisioningPreferences
provisioningPreferences = Maybe UpdateProvisioningPreferences
a} :: UpdateProvisionedProduct)

-- | The idempotency token that uniquely identifies the provisioning update
-- request.
updateProvisionedProduct_updateToken :: Lens.Lens' UpdateProvisionedProduct Prelude.Text
updateProvisionedProduct_updateToken :: (Text -> f Text)
-> UpdateProvisionedProduct -> f UpdateProvisionedProduct
updateProvisionedProduct_updateToken = (UpdateProvisionedProduct -> Text)
-> (UpdateProvisionedProduct -> Text -> UpdateProvisionedProduct)
-> Lens UpdateProvisionedProduct UpdateProvisionedProduct Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateProvisionedProduct' {Text
updateToken :: Text
$sel:updateToken:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Text
updateToken} -> Text
updateToken) (\s :: UpdateProvisionedProduct
s@UpdateProvisionedProduct' {} Text
a -> UpdateProvisionedProduct
s {$sel:updateToken:UpdateProvisionedProduct' :: Text
updateToken = Text
a} :: UpdateProvisionedProduct)

instance Core.AWSRequest UpdateProvisionedProduct where
  type
    AWSResponse UpdateProvisionedProduct =
      UpdateProvisionedProductResponse
  request :: UpdateProvisionedProduct -> Request UpdateProvisionedProduct
request = Service
-> UpdateProvisionedProduct -> Request UpdateProvisionedProduct
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy UpdateProvisionedProduct
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse UpdateProvisionedProduct)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse UpdateProvisionedProduct))
-> Logger
-> Service
-> Proxy UpdateProvisionedProduct
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse UpdateProvisionedProduct)))
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 RecordDetail -> Int -> UpdateProvisionedProductResponse
UpdateProvisionedProductResponse'
            (Maybe RecordDetail -> Int -> UpdateProvisionedProductResponse)
-> Either String (Maybe RecordDetail)
-> Either String (Int -> UpdateProvisionedProductResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe RecordDetail)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"RecordDetail")
            Either String (Int -> UpdateProvisionedProductResponse)
-> Either String Int
-> Either String UpdateProvisionedProductResponse
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 UpdateProvisionedProduct

instance Prelude.NFData UpdateProvisionedProduct

instance Core.ToHeaders UpdateProvisionedProduct where
  toHeaders :: UpdateProvisionedProduct -> ResponseHeaders
toHeaders =
    ResponseHeaders -> UpdateProvisionedProduct -> 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.UpdateProvisionedProduct" ::
                          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 UpdateProvisionedProduct where
  toJSON :: UpdateProvisionedProduct -> Value
toJSON UpdateProvisionedProduct' {Maybe [Tag]
Maybe [UpdateProvisioningParameter]
Maybe Text
Maybe UpdateProvisioningPreferences
Text
updateToken :: Text
provisioningPreferences :: Maybe UpdateProvisioningPreferences
tags :: Maybe [Tag]
productId :: Maybe Text
provisionedProductId :: Maybe Text
provisioningParameters :: Maybe [UpdateProvisioningParameter]
pathId :: Maybe Text
acceptLanguage :: Maybe Text
pathName :: Maybe Text
provisioningArtifactName :: Maybe Text
provisioningArtifactId :: Maybe Text
provisionedProductName :: Maybe Text
productName :: Maybe Text
$sel:updateToken:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Text
$sel:provisioningPreferences:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe UpdateProvisioningPreferences
$sel:tags:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe [Tag]
$sel:productId:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe Text
$sel:provisionedProductId:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe Text
$sel:provisioningParameters:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe [UpdateProvisioningParameter]
$sel:pathId:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe Text
$sel:acceptLanguage:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe Text
$sel:pathName:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe Text
$sel:provisioningArtifactName:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe Text
$sel:provisioningArtifactId:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe Text
$sel:provisionedProductName:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe Text
$sel:productName:UpdateProvisionedProduct' :: UpdateProvisionedProduct -> Maybe Text
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Text
"ProductName" 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
productName,
            (Text
"ProvisionedProductName" 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
provisionedProductName,
            (Text
"ProvisioningArtifactId" 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
provisioningArtifactId,
            (Text
"ProvisioningArtifactName" 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
provisioningArtifactName,
            (Text
"PathName" 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
pathName,
            (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,
            (Text
"PathId" 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
pathId,
            (Text
"ProvisioningParameters" Text -> [UpdateProvisioningParameter] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              ([UpdateProvisioningParameter] -> Pair)
-> Maybe [UpdateProvisioningParameter] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [UpdateProvisioningParameter]
provisioningParameters,
            (Text
"ProvisionedProductId" 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
provisionedProductId,
            (Text
"ProductId" 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
productId,
            (Text
"Tags" Text -> [Tag] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) ([Tag] -> Pair) -> Maybe [Tag] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Tag]
tags,
            (Text
"ProvisioningPreferences" Text -> UpdateProvisioningPreferences -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (UpdateProvisioningPreferences -> Pair)
-> Maybe UpdateProvisioningPreferences -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe UpdateProvisioningPreferences
provisioningPreferences,
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"UpdateToken" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
updateToken)
          ]
      )

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

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

-- | /See:/ 'newUpdateProvisionedProductResponse' smart constructor.
data UpdateProvisionedProductResponse = UpdateProvisionedProductResponse'
  { -- | Information about the result of the request.
    UpdateProvisionedProductResponse -> Maybe RecordDetail
recordDetail :: Prelude.Maybe RecordDetail,
    -- | The response's http status code.
    UpdateProvisionedProductResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (UpdateProvisionedProductResponse
-> UpdateProvisionedProductResponse -> Bool
(UpdateProvisionedProductResponse
 -> UpdateProvisionedProductResponse -> Bool)
-> (UpdateProvisionedProductResponse
    -> UpdateProvisionedProductResponse -> Bool)
-> Eq UpdateProvisionedProductResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateProvisionedProductResponse
-> UpdateProvisionedProductResponse -> Bool
$c/= :: UpdateProvisionedProductResponse
-> UpdateProvisionedProductResponse -> Bool
== :: UpdateProvisionedProductResponse
-> UpdateProvisionedProductResponse -> Bool
$c== :: UpdateProvisionedProductResponse
-> UpdateProvisionedProductResponse -> Bool
Prelude.Eq, ReadPrec [UpdateProvisionedProductResponse]
ReadPrec UpdateProvisionedProductResponse
Int -> ReadS UpdateProvisionedProductResponse
ReadS [UpdateProvisionedProductResponse]
(Int -> ReadS UpdateProvisionedProductResponse)
-> ReadS [UpdateProvisionedProductResponse]
-> ReadPrec UpdateProvisionedProductResponse
-> ReadPrec [UpdateProvisionedProductResponse]
-> Read UpdateProvisionedProductResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateProvisionedProductResponse]
$creadListPrec :: ReadPrec [UpdateProvisionedProductResponse]
readPrec :: ReadPrec UpdateProvisionedProductResponse
$creadPrec :: ReadPrec UpdateProvisionedProductResponse
readList :: ReadS [UpdateProvisionedProductResponse]
$creadList :: ReadS [UpdateProvisionedProductResponse]
readsPrec :: Int -> ReadS UpdateProvisionedProductResponse
$creadsPrec :: Int -> ReadS UpdateProvisionedProductResponse
Prelude.Read, Int -> UpdateProvisionedProductResponse -> ShowS
[UpdateProvisionedProductResponse] -> ShowS
UpdateProvisionedProductResponse -> String
(Int -> UpdateProvisionedProductResponse -> ShowS)
-> (UpdateProvisionedProductResponse -> String)
-> ([UpdateProvisionedProductResponse] -> ShowS)
-> Show UpdateProvisionedProductResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateProvisionedProductResponse] -> ShowS
$cshowList :: [UpdateProvisionedProductResponse] -> ShowS
show :: UpdateProvisionedProductResponse -> String
$cshow :: UpdateProvisionedProductResponse -> String
showsPrec :: Int -> UpdateProvisionedProductResponse -> ShowS
$cshowsPrec :: Int -> UpdateProvisionedProductResponse -> ShowS
Prelude.Show, (forall x.
 UpdateProvisionedProductResponse
 -> Rep UpdateProvisionedProductResponse x)
-> (forall x.
    Rep UpdateProvisionedProductResponse x
    -> UpdateProvisionedProductResponse)
-> Generic UpdateProvisionedProductResponse
forall x.
Rep UpdateProvisionedProductResponse x
-> UpdateProvisionedProductResponse
forall x.
UpdateProvisionedProductResponse
-> Rep UpdateProvisionedProductResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep UpdateProvisionedProductResponse x
-> UpdateProvisionedProductResponse
$cfrom :: forall x.
UpdateProvisionedProductResponse
-> Rep UpdateProvisionedProductResponse x
Prelude.Generic)

-- |
-- Create a value of 'UpdateProvisionedProductResponse' 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:
--
-- 'recordDetail', 'updateProvisionedProductResponse_recordDetail' - Information about the result of the request.
--
-- 'httpStatus', 'updateProvisionedProductResponse_httpStatus' - The response's http status code.
newUpdateProvisionedProductResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  UpdateProvisionedProductResponse
newUpdateProvisionedProductResponse :: Int -> UpdateProvisionedProductResponse
newUpdateProvisionedProductResponse Int
pHttpStatus_ =
  UpdateProvisionedProductResponse' :: Maybe RecordDetail -> Int -> UpdateProvisionedProductResponse
UpdateProvisionedProductResponse'
    { $sel:recordDetail:UpdateProvisionedProductResponse' :: Maybe RecordDetail
recordDetail =
        Maybe RecordDetail
forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:UpdateProvisionedProductResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | Information about the result of the request.
updateProvisionedProductResponse_recordDetail :: Lens.Lens' UpdateProvisionedProductResponse (Prelude.Maybe RecordDetail)
updateProvisionedProductResponse_recordDetail :: (Maybe RecordDetail -> f (Maybe RecordDetail))
-> UpdateProvisionedProductResponse
-> f UpdateProvisionedProductResponse
updateProvisionedProductResponse_recordDetail = (UpdateProvisionedProductResponse -> Maybe RecordDetail)
-> (UpdateProvisionedProductResponse
    -> Maybe RecordDetail -> UpdateProvisionedProductResponse)
-> Lens
     UpdateProvisionedProductResponse
     UpdateProvisionedProductResponse
     (Maybe RecordDetail)
     (Maybe RecordDetail)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateProvisionedProductResponse' {Maybe RecordDetail
recordDetail :: Maybe RecordDetail
$sel:recordDetail:UpdateProvisionedProductResponse' :: UpdateProvisionedProductResponse -> Maybe RecordDetail
recordDetail} -> Maybe RecordDetail
recordDetail) (\s :: UpdateProvisionedProductResponse
s@UpdateProvisionedProductResponse' {} Maybe RecordDetail
a -> UpdateProvisionedProductResponse
s {$sel:recordDetail:UpdateProvisionedProductResponse' :: Maybe RecordDetail
recordDetail = Maybe RecordDetail
a} :: UpdateProvisionedProductResponse)

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

instance
  Prelude.NFData
    UpdateProvisionedProductResponse