{-# 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.LexV2Models.UpdateSlotType
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Updates the configuration of an existing slot type.
module Amazonka.LexV2Models.UpdateSlotType
  ( -- * Creating a Request
    UpdateSlotType (..),
    newUpdateSlotType,

    -- * Request Lenses
    updateSlotType_compositeSlotTypeSetting,
    updateSlotType_description,
    updateSlotType_externalSourceSetting,
    updateSlotType_parentSlotTypeSignature,
    updateSlotType_slotTypeValues,
    updateSlotType_valueSelectionSetting,
    updateSlotType_slotTypeId,
    updateSlotType_slotTypeName,
    updateSlotType_botId,
    updateSlotType_botVersion,
    updateSlotType_localeId,

    -- * Destructuring the Response
    UpdateSlotTypeResponse (..),
    newUpdateSlotTypeResponse,

    -- * Response Lenses
    updateSlotTypeResponse_botId,
    updateSlotTypeResponse_botVersion,
    updateSlotTypeResponse_compositeSlotTypeSetting,
    updateSlotTypeResponse_creationDateTime,
    updateSlotTypeResponse_description,
    updateSlotTypeResponse_externalSourceSetting,
    updateSlotTypeResponse_lastUpdatedDateTime,
    updateSlotTypeResponse_localeId,
    updateSlotTypeResponse_parentSlotTypeSignature,
    updateSlotTypeResponse_slotTypeId,
    updateSlotTypeResponse_slotTypeName,
    updateSlotTypeResponse_slotTypeValues,
    updateSlotTypeResponse_valueSelectionSetting,
    updateSlotTypeResponse_httpStatus,
  )
where

import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.LexV2Models.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response

-- | /See:/ 'newUpdateSlotType' smart constructor.
data UpdateSlotType = UpdateSlotType'
  { -- | Specifications for a composite slot type.
    UpdateSlotType -> Maybe CompositeSlotTypeSetting
compositeSlotTypeSetting :: Prelude.Maybe CompositeSlotTypeSetting,
    -- | The new description of the slot type.
    UpdateSlotType -> Maybe Text
description :: Prelude.Maybe Prelude.Text,
    UpdateSlotType -> Maybe ExternalSourceSetting
externalSourceSetting :: Prelude.Maybe ExternalSourceSetting,
    -- | The new built-in slot type that should be used as the parent of this
    -- slot type.
    UpdateSlotType -> Maybe Text
parentSlotTypeSignature :: Prelude.Maybe Prelude.Text,
    -- | A new list of values and their optional synonyms that define the values
    -- that the slot type can take.
    UpdateSlotType -> Maybe (NonEmpty SlotTypeValue)
slotTypeValues :: Prelude.Maybe (Prelude.NonEmpty SlotTypeValue),
    -- | The strategy that Amazon Lex should use when deciding on a value from
    -- the list of slot type values.
    UpdateSlotType -> Maybe SlotValueSelectionSetting
valueSelectionSetting :: Prelude.Maybe SlotValueSelectionSetting,
    -- | The unique identifier of the slot type to update.
    UpdateSlotType -> Text
slotTypeId :: Prelude.Text,
    -- | The new name of the slot type.
    UpdateSlotType -> Text
slotTypeName :: Prelude.Text,
    -- | The identifier of the bot that contains the slot type.
    UpdateSlotType -> Text
botId :: Prelude.Text,
    -- | The version of the bot that contains the slot type. Must be @DRAFT@.
    UpdateSlotType -> Text
botVersion :: Prelude.Text,
    -- | The identifier of the language and locale that contains the slot type.
    -- The string must match one of the supported locales. For more
    -- information, see
    -- <https://docs.aws.amazon.com/lexv2/latest/dg/how-languages.html Supported languages>.
    UpdateSlotType -> Text
localeId :: Prelude.Text
  }
  deriving (UpdateSlotType -> UpdateSlotType -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateSlotType -> UpdateSlotType -> Bool
$c/= :: UpdateSlotType -> UpdateSlotType -> Bool
== :: UpdateSlotType -> UpdateSlotType -> Bool
$c== :: UpdateSlotType -> UpdateSlotType -> Bool
Prelude.Eq, ReadPrec [UpdateSlotType]
ReadPrec UpdateSlotType
Int -> ReadS UpdateSlotType
ReadS [UpdateSlotType]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateSlotType]
$creadListPrec :: ReadPrec [UpdateSlotType]
readPrec :: ReadPrec UpdateSlotType
$creadPrec :: ReadPrec UpdateSlotType
readList :: ReadS [UpdateSlotType]
$creadList :: ReadS [UpdateSlotType]
readsPrec :: Int -> ReadS UpdateSlotType
$creadsPrec :: Int -> ReadS UpdateSlotType
Prelude.Read, Int -> UpdateSlotType -> ShowS
[UpdateSlotType] -> ShowS
UpdateSlotType -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateSlotType] -> ShowS
$cshowList :: [UpdateSlotType] -> ShowS
show :: UpdateSlotType -> String
$cshow :: UpdateSlotType -> String
showsPrec :: Int -> UpdateSlotType -> ShowS
$cshowsPrec :: Int -> UpdateSlotType -> ShowS
Prelude.Show, forall x. Rep UpdateSlotType x -> UpdateSlotType
forall x. UpdateSlotType -> Rep UpdateSlotType x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UpdateSlotType x -> UpdateSlotType
$cfrom :: forall x. UpdateSlotType -> Rep UpdateSlotType x
Prelude.Generic)

-- |
-- Create a value of 'UpdateSlotType' 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:
--
-- 'compositeSlotTypeSetting', 'updateSlotType_compositeSlotTypeSetting' - Specifications for a composite slot type.
--
-- 'description', 'updateSlotType_description' - The new description of the slot type.
--
-- 'externalSourceSetting', 'updateSlotType_externalSourceSetting' - Undocumented member.
--
-- 'parentSlotTypeSignature', 'updateSlotType_parentSlotTypeSignature' - The new built-in slot type that should be used as the parent of this
-- slot type.
--
-- 'slotTypeValues', 'updateSlotType_slotTypeValues' - A new list of values and their optional synonyms that define the values
-- that the slot type can take.
--
-- 'valueSelectionSetting', 'updateSlotType_valueSelectionSetting' - The strategy that Amazon Lex should use when deciding on a value from
-- the list of slot type values.
--
-- 'slotTypeId', 'updateSlotType_slotTypeId' - The unique identifier of the slot type to update.
--
-- 'slotTypeName', 'updateSlotType_slotTypeName' - The new name of the slot type.
--
-- 'botId', 'updateSlotType_botId' - The identifier of the bot that contains the slot type.
--
-- 'botVersion', 'updateSlotType_botVersion' - The version of the bot that contains the slot type. Must be @DRAFT@.
--
-- 'localeId', 'updateSlotType_localeId' - The identifier of the language and locale that contains the slot type.
-- The string must match one of the supported locales. For more
-- information, see
-- <https://docs.aws.amazon.com/lexv2/latest/dg/how-languages.html Supported languages>.
newUpdateSlotType ::
  -- | 'slotTypeId'
  Prelude.Text ->
  -- | 'slotTypeName'
  Prelude.Text ->
  -- | 'botId'
  Prelude.Text ->
  -- | 'botVersion'
  Prelude.Text ->
  -- | 'localeId'
  Prelude.Text ->
  UpdateSlotType
newUpdateSlotType :: Text -> Text -> Text -> Text -> Text -> UpdateSlotType
newUpdateSlotType
  Text
pSlotTypeId_
  Text
pSlotTypeName_
  Text
pBotId_
  Text
pBotVersion_
  Text
pLocaleId_ =
    UpdateSlotType'
      { $sel:compositeSlotTypeSetting:UpdateSlotType' :: Maybe CompositeSlotTypeSetting
compositeSlotTypeSetting =
          forall a. Maybe a
Prelude.Nothing,
        $sel:description:UpdateSlotType' :: Maybe Text
description = forall a. Maybe a
Prelude.Nothing,
        $sel:externalSourceSetting:UpdateSlotType' :: Maybe ExternalSourceSetting
externalSourceSetting = forall a. Maybe a
Prelude.Nothing,
        $sel:parentSlotTypeSignature:UpdateSlotType' :: Maybe Text
parentSlotTypeSignature = forall a. Maybe a
Prelude.Nothing,
        $sel:slotTypeValues:UpdateSlotType' :: Maybe (NonEmpty SlotTypeValue)
slotTypeValues = forall a. Maybe a
Prelude.Nothing,
        $sel:valueSelectionSetting:UpdateSlotType' :: Maybe SlotValueSelectionSetting
valueSelectionSetting = forall a. Maybe a
Prelude.Nothing,
        $sel:slotTypeId:UpdateSlotType' :: Text
slotTypeId = Text
pSlotTypeId_,
        $sel:slotTypeName:UpdateSlotType' :: Text
slotTypeName = Text
pSlotTypeName_,
        $sel:botId:UpdateSlotType' :: Text
botId = Text
pBotId_,
        $sel:botVersion:UpdateSlotType' :: Text
botVersion = Text
pBotVersion_,
        $sel:localeId:UpdateSlotType' :: Text
localeId = Text
pLocaleId_
      }

-- | Specifications for a composite slot type.
updateSlotType_compositeSlotTypeSetting :: Lens.Lens' UpdateSlotType (Prelude.Maybe CompositeSlotTypeSetting)
updateSlotType_compositeSlotTypeSetting :: Lens' UpdateSlotType (Maybe CompositeSlotTypeSetting)
updateSlotType_compositeSlotTypeSetting = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotType' {Maybe CompositeSlotTypeSetting
compositeSlotTypeSetting :: Maybe CompositeSlotTypeSetting
$sel:compositeSlotTypeSetting:UpdateSlotType' :: UpdateSlotType -> Maybe CompositeSlotTypeSetting
compositeSlotTypeSetting} -> Maybe CompositeSlotTypeSetting
compositeSlotTypeSetting) (\s :: UpdateSlotType
s@UpdateSlotType' {} Maybe CompositeSlotTypeSetting
a -> UpdateSlotType
s {$sel:compositeSlotTypeSetting:UpdateSlotType' :: Maybe CompositeSlotTypeSetting
compositeSlotTypeSetting = Maybe CompositeSlotTypeSetting
a} :: UpdateSlotType)

-- | The new description of the slot type.
updateSlotType_description :: Lens.Lens' UpdateSlotType (Prelude.Maybe Prelude.Text)
updateSlotType_description :: Lens' UpdateSlotType (Maybe Text)
updateSlotType_description = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotType' {Maybe Text
description :: Maybe Text
$sel:description:UpdateSlotType' :: UpdateSlotType -> Maybe Text
description} -> Maybe Text
description) (\s :: UpdateSlotType
s@UpdateSlotType' {} Maybe Text
a -> UpdateSlotType
s {$sel:description:UpdateSlotType' :: Maybe Text
description = Maybe Text
a} :: UpdateSlotType)

-- | Undocumented member.
updateSlotType_externalSourceSetting :: Lens.Lens' UpdateSlotType (Prelude.Maybe ExternalSourceSetting)
updateSlotType_externalSourceSetting :: Lens' UpdateSlotType (Maybe ExternalSourceSetting)
updateSlotType_externalSourceSetting = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotType' {Maybe ExternalSourceSetting
externalSourceSetting :: Maybe ExternalSourceSetting
$sel:externalSourceSetting:UpdateSlotType' :: UpdateSlotType -> Maybe ExternalSourceSetting
externalSourceSetting} -> Maybe ExternalSourceSetting
externalSourceSetting) (\s :: UpdateSlotType
s@UpdateSlotType' {} Maybe ExternalSourceSetting
a -> UpdateSlotType
s {$sel:externalSourceSetting:UpdateSlotType' :: Maybe ExternalSourceSetting
externalSourceSetting = Maybe ExternalSourceSetting
a} :: UpdateSlotType)

-- | The new built-in slot type that should be used as the parent of this
-- slot type.
updateSlotType_parentSlotTypeSignature :: Lens.Lens' UpdateSlotType (Prelude.Maybe Prelude.Text)
updateSlotType_parentSlotTypeSignature :: Lens' UpdateSlotType (Maybe Text)
updateSlotType_parentSlotTypeSignature = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotType' {Maybe Text
parentSlotTypeSignature :: Maybe Text
$sel:parentSlotTypeSignature:UpdateSlotType' :: UpdateSlotType -> Maybe Text
parentSlotTypeSignature} -> Maybe Text
parentSlotTypeSignature) (\s :: UpdateSlotType
s@UpdateSlotType' {} Maybe Text
a -> UpdateSlotType
s {$sel:parentSlotTypeSignature:UpdateSlotType' :: Maybe Text
parentSlotTypeSignature = Maybe Text
a} :: UpdateSlotType)

-- | A new list of values and their optional synonyms that define the values
-- that the slot type can take.
updateSlotType_slotTypeValues :: Lens.Lens' UpdateSlotType (Prelude.Maybe (Prelude.NonEmpty SlotTypeValue))
updateSlotType_slotTypeValues :: Lens' UpdateSlotType (Maybe (NonEmpty SlotTypeValue))
updateSlotType_slotTypeValues = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotType' {Maybe (NonEmpty SlotTypeValue)
slotTypeValues :: Maybe (NonEmpty SlotTypeValue)
$sel:slotTypeValues:UpdateSlotType' :: UpdateSlotType -> Maybe (NonEmpty SlotTypeValue)
slotTypeValues} -> Maybe (NonEmpty SlotTypeValue)
slotTypeValues) (\s :: UpdateSlotType
s@UpdateSlotType' {} Maybe (NonEmpty SlotTypeValue)
a -> UpdateSlotType
s {$sel:slotTypeValues:UpdateSlotType' :: Maybe (NonEmpty SlotTypeValue)
slotTypeValues = Maybe (NonEmpty SlotTypeValue)
a} :: UpdateSlotType) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The strategy that Amazon Lex should use when deciding on a value from
-- the list of slot type values.
updateSlotType_valueSelectionSetting :: Lens.Lens' UpdateSlotType (Prelude.Maybe SlotValueSelectionSetting)
updateSlotType_valueSelectionSetting :: Lens' UpdateSlotType (Maybe SlotValueSelectionSetting)
updateSlotType_valueSelectionSetting = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotType' {Maybe SlotValueSelectionSetting
valueSelectionSetting :: Maybe SlotValueSelectionSetting
$sel:valueSelectionSetting:UpdateSlotType' :: UpdateSlotType -> Maybe SlotValueSelectionSetting
valueSelectionSetting} -> Maybe SlotValueSelectionSetting
valueSelectionSetting) (\s :: UpdateSlotType
s@UpdateSlotType' {} Maybe SlotValueSelectionSetting
a -> UpdateSlotType
s {$sel:valueSelectionSetting:UpdateSlotType' :: Maybe SlotValueSelectionSetting
valueSelectionSetting = Maybe SlotValueSelectionSetting
a} :: UpdateSlotType)

-- | The unique identifier of the slot type to update.
updateSlotType_slotTypeId :: Lens.Lens' UpdateSlotType Prelude.Text
updateSlotType_slotTypeId :: Lens' UpdateSlotType Text
updateSlotType_slotTypeId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotType' {Text
slotTypeId :: Text
$sel:slotTypeId:UpdateSlotType' :: UpdateSlotType -> Text
slotTypeId} -> Text
slotTypeId) (\s :: UpdateSlotType
s@UpdateSlotType' {} Text
a -> UpdateSlotType
s {$sel:slotTypeId:UpdateSlotType' :: Text
slotTypeId = Text
a} :: UpdateSlotType)

-- | The new name of the slot type.
updateSlotType_slotTypeName :: Lens.Lens' UpdateSlotType Prelude.Text
updateSlotType_slotTypeName :: Lens' UpdateSlotType Text
updateSlotType_slotTypeName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotType' {Text
slotTypeName :: Text
$sel:slotTypeName:UpdateSlotType' :: UpdateSlotType -> Text
slotTypeName} -> Text
slotTypeName) (\s :: UpdateSlotType
s@UpdateSlotType' {} Text
a -> UpdateSlotType
s {$sel:slotTypeName:UpdateSlotType' :: Text
slotTypeName = Text
a} :: UpdateSlotType)

-- | The identifier of the bot that contains the slot type.
updateSlotType_botId :: Lens.Lens' UpdateSlotType Prelude.Text
updateSlotType_botId :: Lens' UpdateSlotType Text
updateSlotType_botId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotType' {Text
botId :: Text
$sel:botId:UpdateSlotType' :: UpdateSlotType -> Text
botId} -> Text
botId) (\s :: UpdateSlotType
s@UpdateSlotType' {} Text
a -> UpdateSlotType
s {$sel:botId:UpdateSlotType' :: Text
botId = Text
a} :: UpdateSlotType)

-- | The version of the bot that contains the slot type. Must be @DRAFT@.
updateSlotType_botVersion :: Lens.Lens' UpdateSlotType Prelude.Text
updateSlotType_botVersion :: Lens' UpdateSlotType Text
updateSlotType_botVersion = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotType' {Text
botVersion :: Text
$sel:botVersion:UpdateSlotType' :: UpdateSlotType -> Text
botVersion} -> Text
botVersion) (\s :: UpdateSlotType
s@UpdateSlotType' {} Text
a -> UpdateSlotType
s {$sel:botVersion:UpdateSlotType' :: Text
botVersion = Text
a} :: UpdateSlotType)

-- | The identifier of the language and locale that contains the slot type.
-- The string must match one of the supported locales. For more
-- information, see
-- <https://docs.aws.amazon.com/lexv2/latest/dg/how-languages.html Supported languages>.
updateSlotType_localeId :: Lens.Lens' UpdateSlotType Prelude.Text
updateSlotType_localeId :: Lens' UpdateSlotType Text
updateSlotType_localeId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotType' {Text
localeId :: Text
$sel:localeId:UpdateSlotType' :: UpdateSlotType -> Text
localeId} -> Text
localeId) (\s :: UpdateSlotType
s@UpdateSlotType' {} Text
a -> UpdateSlotType
s {$sel:localeId:UpdateSlotType' :: Text
localeId = Text
a} :: UpdateSlotType)

instance Core.AWSRequest UpdateSlotType where
  type
    AWSResponse UpdateSlotType =
      UpdateSlotTypeResponse
  request :: (Service -> Service) -> UpdateSlotType -> Request UpdateSlotType
request Service -> Service
overrides =
    forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.putJSON (Service -> Service
overrides Service
defaultService)
  response :: forall (m :: * -> *).
MonadResource m =>
(ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy UpdateSlotType
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse UpdateSlotType)))
response =
    forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
      ( \Int
s ResponseHeaders
h Object
x ->
          Maybe Text
-> Maybe Text
-> Maybe CompositeSlotTypeSetting
-> Maybe POSIX
-> Maybe Text
-> Maybe ExternalSourceSetting
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe (NonEmpty SlotTypeValue)
-> Maybe SlotValueSelectionSetting
-> Int
-> UpdateSlotTypeResponse
UpdateSlotTypeResponse'
            forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"botId")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"botVersion")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"compositeSlotTypeSetting")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"creationDateTime")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"description")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"externalSourceSetting")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"lastUpdatedDateTime")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"localeId")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"parentSlotTypeSignature")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"slotTypeId")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"slotTypeName")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"slotTypeValues")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"valueSelectionSetting")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
      )

instance Prelude.Hashable UpdateSlotType where
  hashWithSalt :: Int -> UpdateSlotType -> Int
hashWithSalt Int
_salt UpdateSlotType' {Maybe (NonEmpty SlotTypeValue)
Maybe Text
Maybe ExternalSourceSetting
Maybe SlotValueSelectionSetting
Maybe CompositeSlotTypeSetting
Text
localeId :: Text
botVersion :: Text
botId :: Text
slotTypeName :: Text
slotTypeId :: Text
valueSelectionSetting :: Maybe SlotValueSelectionSetting
slotTypeValues :: Maybe (NonEmpty SlotTypeValue)
parentSlotTypeSignature :: Maybe Text
externalSourceSetting :: Maybe ExternalSourceSetting
description :: Maybe Text
compositeSlotTypeSetting :: Maybe CompositeSlotTypeSetting
$sel:localeId:UpdateSlotType' :: UpdateSlotType -> Text
$sel:botVersion:UpdateSlotType' :: UpdateSlotType -> Text
$sel:botId:UpdateSlotType' :: UpdateSlotType -> Text
$sel:slotTypeName:UpdateSlotType' :: UpdateSlotType -> Text
$sel:slotTypeId:UpdateSlotType' :: UpdateSlotType -> Text
$sel:valueSelectionSetting:UpdateSlotType' :: UpdateSlotType -> Maybe SlotValueSelectionSetting
$sel:slotTypeValues:UpdateSlotType' :: UpdateSlotType -> Maybe (NonEmpty SlotTypeValue)
$sel:parentSlotTypeSignature:UpdateSlotType' :: UpdateSlotType -> Maybe Text
$sel:externalSourceSetting:UpdateSlotType' :: UpdateSlotType -> Maybe ExternalSourceSetting
$sel:description:UpdateSlotType' :: UpdateSlotType -> Maybe Text
$sel:compositeSlotTypeSetting:UpdateSlotType' :: UpdateSlotType -> Maybe CompositeSlotTypeSetting
..} =
    Int
_salt
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe CompositeSlotTypeSetting
compositeSlotTypeSetting
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
description
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ExternalSourceSetting
externalSourceSetting
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
parentSlotTypeSignature
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (NonEmpty SlotTypeValue)
slotTypeValues
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe SlotValueSelectionSetting
valueSelectionSetting
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
slotTypeId
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
slotTypeName
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
botId
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
botVersion
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
localeId

instance Prelude.NFData UpdateSlotType where
  rnf :: UpdateSlotType -> ()
rnf UpdateSlotType' {Maybe (NonEmpty SlotTypeValue)
Maybe Text
Maybe ExternalSourceSetting
Maybe SlotValueSelectionSetting
Maybe CompositeSlotTypeSetting
Text
localeId :: Text
botVersion :: Text
botId :: Text
slotTypeName :: Text
slotTypeId :: Text
valueSelectionSetting :: Maybe SlotValueSelectionSetting
slotTypeValues :: Maybe (NonEmpty SlotTypeValue)
parentSlotTypeSignature :: Maybe Text
externalSourceSetting :: Maybe ExternalSourceSetting
description :: Maybe Text
compositeSlotTypeSetting :: Maybe CompositeSlotTypeSetting
$sel:localeId:UpdateSlotType' :: UpdateSlotType -> Text
$sel:botVersion:UpdateSlotType' :: UpdateSlotType -> Text
$sel:botId:UpdateSlotType' :: UpdateSlotType -> Text
$sel:slotTypeName:UpdateSlotType' :: UpdateSlotType -> Text
$sel:slotTypeId:UpdateSlotType' :: UpdateSlotType -> Text
$sel:valueSelectionSetting:UpdateSlotType' :: UpdateSlotType -> Maybe SlotValueSelectionSetting
$sel:slotTypeValues:UpdateSlotType' :: UpdateSlotType -> Maybe (NonEmpty SlotTypeValue)
$sel:parentSlotTypeSignature:UpdateSlotType' :: UpdateSlotType -> Maybe Text
$sel:externalSourceSetting:UpdateSlotType' :: UpdateSlotType -> Maybe ExternalSourceSetting
$sel:description:UpdateSlotType' :: UpdateSlotType -> Maybe Text
$sel:compositeSlotTypeSetting:UpdateSlotType' :: UpdateSlotType -> Maybe CompositeSlotTypeSetting
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe CompositeSlotTypeSetting
compositeSlotTypeSetting
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
description
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe ExternalSourceSetting
externalSourceSetting
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
parentSlotTypeSignature
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe (NonEmpty SlotTypeValue)
slotTypeValues
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe SlotValueSelectionSetting
valueSelectionSetting
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
slotTypeId
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
slotTypeName
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
botId
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
botVersion
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
localeId

instance Data.ToHeaders UpdateSlotType where
  toHeaders :: UpdateSlotType -> ResponseHeaders
toHeaders =
    forall a b. a -> b -> a
Prelude.const
      ( forall a. Monoid a => [a] -> a
Prelude.mconcat
          [ HeaderName
"Content-Type"
              forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Data.=# ( ByteString
"application/x-amz-json-1.1" ::
                          Prelude.ByteString
                      )
          ]
      )

instance Data.ToJSON UpdateSlotType where
  toJSON :: UpdateSlotType -> Value
toJSON UpdateSlotType' {Maybe (NonEmpty SlotTypeValue)
Maybe Text
Maybe ExternalSourceSetting
Maybe SlotValueSelectionSetting
Maybe CompositeSlotTypeSetting
Text
localeId :: Text
botVersion :: Text
botId :: Text
slotTypeName :: Text
slotTypeId :: Text
valueSelectionSetting :: Maybe SlotValueSelectionSetting
slotTypeValues :: Maybe (NonEmpty SlotTypeValue)
parentSlotTypeSignature :: Maybe Text
externalSourceSetting :: Maybe ExternalSourceSetting
description :: Maybe Text
compositeSlotTypeSetting :: Maybe CompositeSlotTypeSetting
$sel:localeId:UpdateSlotType' :: UpdateSlotType -> Text
$sel:botVersion:UpdateSlotType' :: UpdateSlotType -> Text
$sel:botId:UpdateSlotType' :: UpdateSlotType -> Text
$sel:slotTypeName:UpdateSlotType' :: UpdateSlotType -> Text
$sel:slotTypeId:UpdateSlotType' :: UpdateSlotType -> Text
$sel:valueSelectionSetting:UpdateSlotType' :: UpdateSlotType -> Maybe SlotValueSelectionSetting
$sel:slotTypeValues:UpdateSlotType' :: UpdateSlotType -> Maybe (NonEmpty SlotTypeValue)
$sel:parentSlotTypeSignature:UpdateSlotType' :: UpdateSlotType -> Maybe Text
$sel:externalSourceSetting:UpdateSlotType' :: UpdateSlotType -> Maybe ExternalSourceSetting
$sel:description:UpdateSlotType' :: UpdateSlotType -> Maybe Text
$sel:compositeSlotTypeSetting:UpdateSlotType' :: UpdateSlotType -> Maybe CompositeSlotTypeSetting
..} =
    [Pair] -> Value
Data.object
      ( forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Key
"compositeSlotTypeSetting" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe CompositeSlotTypeSetting
compositeSlotTypeSetting,
            (Key
"description" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
description,
            (Key
"externalSourceSetting" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ExternalSourceSetting
externalSourceSetting,
            (Key
"parentSlotTypeSignature" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
parentSlotTypeSignature,
            (Key
"slotTypeValues" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (NonEmpty SlotTypeValue)
slotTypeValues,
            (Key
"valueSelectionSetting" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
              forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe SlotValueSelectionSetting
valueSelectionSetting,
            forall a. a -> Maybe a
Prelude.Just (Key
"slotTypeName" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
slotTypeName)
          ]
      )

instance Data.ToPath UpdateSlotType where
  toPath :: UpdateSlotType -> ByteString
toPath UpdateSlotType' {Maybe (NonEmpty SlotTypeValue)
Maybe Text
Maybe ExternalSourceSetting
Maybe SlotValueSelectionSetting
Maybe CompositeSlotTypeSetting
Text
localeId :: Text
botVersion :: Text
botId :: Text
slotTypeName :: Text
slotTypeId :: Text
valueSelectionSetting :: Maybe SlotValueSelectionSetting
slotTypeValues :: Maybe (NonEmpty SlotTypeValue)
parentSlotTypeSignature :: Maybe Text
externalSourceSetting :: Maybe ExternalSourceSetting
description :: Maybe Text
compositeSlotTypeSetting :: Maybe CompositeSlotTypeSetting
$sel:localeId:UpdateSlotType' :: UpdateSlotType -> Text
$sel:botVersion:UpdateSlotType' :: UpdateSlotType -> Text
$sel:botId:UpdateSlotType' :: UpdateSlotType -> Text
$sel:slotTypeName:UpdateSlotType' :: UpdateSlotType -> Text
$sel:slotTypeId:UpdateSlotType' :: UpdateSlotType -> Text
$sel:valueSelectionSetting:UpdateSlotType' :: UpdateSlotType -> Maybe SlotValueSelectionSetting
$sel:slotTypeValues:UpdateSlotType' :: UpdateSlotType -> Maybe (NonEmpty SlotTypeValue)
$sel:parentSlotTypeSignature:UpdateSlotType' :: UpdateSlotType -> Maybe Text
$sel:externalSourceSetting:UpdateSlotType' :: UpdateSlotType -> Maybe ExternalSourceSetting
$sel:description:UpdateSlotType' :: UpdateSlotType -> Maybe Text
$sel:compositeSlotTypeSetting:UpdateSlotType' :: UpdateSlotType -> Maybe CompositeSlotTypeSetting
..} =
    forall a. Monoid a => [a] -> a
Prelude.mconcat
      [ ByteString
"/bots/",
        forall a. ToByteString a => a -> ByteString
Data.toBS Text
botId,
        ByteString
"/botversions/",
        forall a. ToByteString a => a -> ByteString
Data.toBS Text
botVersion,
        ByteString
"/botlocales/",
        forall a. ToByteString a => a -> ByteString
Data.toBS Text
localeId,
        ByteString
"/slottypes/",
        forall a. ToByteString a => a -> ByteString
Data.toBS Text
slotTypeId,
        ByteString
"/"
      ]

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

-- | /See:/ 'newUpdateSlotTypeResponse' smart constructor.
data UpdateSlotTypeResponse = UpdateSlotTypeResponse'
  { -- | The identifier of the bot that contains the slot type.
    UpdateSlotTypeResponse -> Maybe Text
botId :: Prelude.Maybe Prelude.Text,
    -- | The version of the bot that contains the slot type. This is always
    -- @DRAFT@.
    UpdateSlotTypeResponse -> Maybe Text
botVersion :: Prelude.Maybe Prelude.Text,
    -- | Specifications for a composite slot type.
    UpdateSlotTypeResponse -> Maybe CompositeSlotTypeSetting
compositeSlotTypeSetting :: Prelude.Maybe CompositeSlotTypeSetting,
    -- | The timestamp of the date and time that the slot type was created.
    UpdateSlotTypeResponse -> Maybe POSIX
creationDateTime :: Prelude.Maybe Data.POSIX,
    -- | The updated description of the slot type.
    UpdateSlotTypeResponse -> Maybe Text
description :: Prelude.Maybe Prelude.Text,
    UpdateSlotTypeResponse -> Maybe ExternalSourceSetting
externalSourceSetting :: Prelude.Maybe ExternalSourceSetting,
    -- | A timestamp of the date and time that the slot type was last updated.
    UpdateSlotTypeResponse -> Maybe POSIX
lastUpdatedDateTime :: Prelude.Maybe Data.POSIX,
    -- | The language and locale of the updated slot type.
    UpdateSlotTypeResponse -> Maybe Text
localeId :: Prelude.Maybe Prelude.Text,
    -- | The updated signature of the built-in slot type that is the parent of
    -- this slot type.
    UpdateSlotTypeResponse -> Maybe Text
parentSlotTypeSignature :: Prelude.Maybe Prelude.Text,
    -- | The unique identifier of the updated slot type.
    UpdateSlotTypeResponse -> Maybe Text
slotTypeId :: Prelude.Maybe Prelude.Text,
    -- | The updated name of the slot type.
    UpdateSlotTypeResponse -> Maybe Text
slotTypeName :: Prelude.Maybe Prelude.Text,
    -- | The updated values that the slot type provides.
    UpdateSlotTypeResponse -> Maybe (NonEmpty SlotTypeValue)
slotTypeValues :: Prelude.Maybe (Prelude.NonEmpty SlotTypeValue),
    -- | The updated strategy that Amazon Lex uses to determine which value to
    -- select from the slot type.
    UpdateSlotTypeResponse -> Maybe SlotValueSelectionSetting
valueSelectionSetting :: Prelude.Maybe SlotValueSelectionSetting,
    -- | The response's http status code.
    UpdateSlotTypeResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (UpdateSlotTypeResponse -> UpdateSlotTypeResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateSlotTypeResponse -> UpdateSlotTypeResponse -> Bool
$c/= :: UpdateSlotTypeResponse -> UpdateSlotTypeResponse -> Bool
== :: UpdateSlotTypeResponse -> UpdateSlotTypeResponse -> Bool
$c== :: UpdateSlotTypeResponse -> UpdateSlotTypeResponse -> Bool
Prelude.Eq, ReadPrec [UpdateSlotTypeResponse]
ReadPrec UpdateSlotTypeResponse
Int -> ReadS UpdateSlotTypeResponse
ReadS [UpdateSlotTypeResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateSlotTypeResponse]
$creadListPrec :: ReadPrec [UpdateSlotTypeResponse]
readPrec :: ReadPrec UpdateSlotTypeResponse
$creadPrec :: ReadPrec UpdateSlotTypeResponse
readList :: ReadS [UpdateSlotTypeResponse]
$creadList :: ReadS [UpdateSlotTypeResponse]
readsPrec :: Int -> ReadS UpdateSlotTypeResponse
$creadsPrec :: Int -> ReadS UpdateSlotTypeResponse
Prelude.Read, Int -> UpdateSlotTypeResponse -> ShowS
[UpdateSlotTypeResponse] -> ShowS
UpdateSlotTypeResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateSlotTypeResponse] -> ShowS
$cshowList :: [UpdateSlotTypeResponse] -> ShowS
show :: UpdateSlotTypeResponse -> String
$cshow :: UpdateSlotTypeResponse -> String
showsPrec :: Int -> UpdateSlotTypeResponse -> ShowS
$cshowsPrec :: Int -> UpdateSlotTypeResponse -> ShowS
Prelude.Show, forall x. Rep UpdateSlotTypeResponse x -> UpdateSlotTypeResponse
forall x. UpdateSlotTypeResponse -> Rep UpdateSlotTypeResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UpdateSlotTypeResponse x -> UpdateSlotTypeResponse
$cfrom :: forall x. UpdateSlotTypeResponse -> Rep UpdateSlotTypeResponse x
Prelude.Generic)

-- |
-- Create a value of 'UpdateSlotTypeResponse' 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:
--
-- 'botId', 'updateSlotTypeResponse_botId' - The identifier of the bot that contains the slot type.
--
-- 'botVersion', 'updateSlotTypeResponse_botVersion' - The version of the bot that contains the slot type. This is always
-- @DRAFT@.
--
-- 'compositeSlotTypeSetting', 'updateSlotTypeResponse_compositeSlotTypeSetting' - Specifications for a composite slot type.
--
-- 'creationDateTime', 'updateSlotTypeResponse_creationDateTime' - The timestamp of the date and time that the slot type was created.
--
-- 'description', 'updateSlotTypeResponse_description' - The updated description of the slot type.
--
-- 'externalSourceSetting', 'updateSlotTypeResponse_externalSourceSetting' - Undocumented member.
--
-- 'lastUpdatedDateTime', 'updateSlotTypeResponse_lastUpdatedDateTime' - A timestamp of the date and time that the slot type was last updated.
--
-- 'localeId', 'updateSlotTypeResponse_localeId' - The language and locale of the updated slot type.
--
-- 'parentSlotTypeSignature', 'updateSlotTypeResponse_parentSlotTypeSignature' - The updated signature of the built-in slot type that is the parent of
-- this slot type.
--
-- 'slotTypeId', 'updateSlotTypeResponse_slotTypeId' - The unique identifier of the updated slot type.
--
-- 'slotTypeName', 'updateSlotTypeResponse_slotTypeName' - The updated name of the slot type.
--
-- 'slotTypeValues', 'updateSlotTypeResponse_slotTypeValues' - The updated values that the slot type provides.
--
-- 'valueSelectionSetting', 'updateSlotTypeResponse_valueSelectionSetting' - The updated strategy that Amazon Lex uses to determine which value to
-- select from the slot type.
--
-- 'httpStatus', 'updateSlotTypeResponse_httpStatus' - The response's http status code.
newUpdateSlotTypeResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  UpdateSlotTypeResponse
newUpdateSlotTypeResponse :: Int -> UpdateSlotTypeResponse
newUpdateSlotTypeResponse Int
pHttpStatus_ =
  UpdateSlotTypeResponse'
    { $sel:botId:UpdateSlotTypeResponse' :: Maybe Text
botId = forall a. Maybe a
Prelude.Nothing,
      $sel:botVersion:UpdateSlotTypeResponse' :: Maybe Text
botVersion = forall a. Maybe a
Prelude.Nothing,
      $sel:compositeSlotTypeSetting:UpdateSlotTypeResponse' :: Maybe CompositeSlotTypeSetting
compositeSlotTypeSetting = forall a. Maybe a
Prelude.Nothing,
      $sel:creationDateTime:UpdateSlotTypeResponse' :: Maybe POSIX
creationDateTime = forall a. Maybe a
Prelude.Nothing,
      $sel:description:UpdateSlotTypeResponse' :: Maybe Text
description = forall a. Maybe a
Prelude.Nothing,
      $sel:externalSourceSetting:UpdateSlotTypeResponse' :: Maybe ExternalSourceSetting
externalSourceSetting = forall a. Maybe a
Prelude.Nothing,
      $sel:lastUpdatedDateTime:UpdateSlotTypeResponse' :: Maybe POSIX
lastUpdatedDateTime = forall a. Maybe a
Prelude.Nothing,
      $sel:localeId:UpdateSlotTypeResponse' :: Maybe Text
localeId = forall a. Maybe a
Prelude.Nothing,
      $sel:parentSlotTypeSignature:UpdateSlotTypeResponse' :: Maybe Text
parentSlotTypeSignature = forall a. Maybe a
Prelude.Nothing,
      $sel:slotTypeId:UpdateSlotTypeResponse' :: Maybe Text
slotTypeId = forall a. Maybe a
Prelude.Nothing,
      $sel:slotTypeName:UpdateSlotTypeResponse' :: Maybe Text
slotTypeName = forall a. Maybe a
Prelude.Nothing,
      $sel:slotTypeValues:UpdateSlotTypeResponse' :: Maybe (NonEmpty SlotTypeValue)
slotTypeValues = forall a. Maybe a
Prelude.Nothing,
      $sel:valueSelectionSetting:UpdateSlotTypeResponse' :: Maybe SlotValueSelectionSetting
valueSelectionSetting = forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:UpdateSlotTypeResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | The identifier of the bot that contains the slot type.
updateSlotTypeResponse_botId :: Lens.Lens' UpdateSlotTypeResponse (Prelude.Maybe Prelude.Text)
updateSlotTypeResponse_botId :: Lens' UpdateSlotTypeResponse (Maybe Text)
updateSlotTypeResponse_botId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotTypeResponse' {Maybe Text
botId :: Maybe Text
$sel:botId:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe Text
botId} -> Maybe Text
botId) (\s :: UpdateSlotTypeResponse
s@UpdateSlotTypeResponse' {} Maybe Text
a -> UpdateSlotTypeResponse
s {$sel:botId:UpdateSlotTypeResponse' :: Maybe Text
botId = Maybe Text
a} :: UpdateSlotTypeResponse)

-- | The version of the bot that contains the slot type. This is always
-- @DRAFT@.
updateSlotTypeResponse_botVersion :: Lens.Lens' UpdateSlotTypeResponse (Prelude.Maybe Prelude.Text)
updateSlotTypeResponse_botVersion :: Lens' UpdateSlotTypeResponse (Maybe Text)
updateSlotTypeResponse_botVersion = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotTypeResponse' {Maybe Text
botVersion :: Maybe Text
$sel:botVersion:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe Text
botVersion} -> Maybe Text
botVersion) (\s :: UpdateSlotTypeResponse
s@UpdateSlotTypeResponse' {} Maybe Text
a -> UpdateSlotTypeResponse
s {$sel:botVersion:UpdateSlotTypeResponse' :: Maybe Text
botVersion = Maybe Text
a} :: UpdateSlotTypeResponse)

-- | Specifications for a composite slot type.
updateSlotTypeResponse_compositeSlotTypeSetting :: Lens.Lens' UpdateSlotTypeResponse (Prelude.Maybe CompositeSlotTypeSetting)
updateSlotTypeResponse_compositeSlotTypeSetting :: Lens' UpdateSlotTypeResponse (Maybe CompositeSlotTypeSetting)
updateSlotTypeResponse_compositeSlotTypeSetting = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotTypeResponse' {Maybe CompositeSlotTypeSetting
compositeSlotTypeSetting :: Maybe CompositeSlotTypeSetting
$sel:compositeSlotTypeSetting:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe CompositeSlotTypeSetting
compositeSlotTypeSetting} -> Maybe CompositeSlotTypeSetting
compositeSlotTypeSetting) (\s :: UpdateSlotTypeResponse
s@UpdateSlotTypeResponse' {} Maybe CompositeSlotTypeSetting
a -> UpdateSlotTypeResponse
s {$sel:compositeSlotTypeSetting:UpdateSlotTypeResponse' :: Maybe CompositeSlotTypeSetting
compositeSlotTypeSetting = Maybe CompositeSlotTypeSetting
a} :: UpdateSlotTypeResponse)

-- | The timestamp of the date and time that the slot type was created.
updateSlotTypeResponse_creationDateTime :: Lens.Lens' UpdateSlotTypeResponse (Prelude.Maybe Prelude.UTCTime)
updateSlotTypeResponse_creationDateTime :: Lens' UpdateSlotTypeResponse (Maybe UTCTime)
updateSlotTypeResponse_creationDateTime = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotTypeResponse' {Maybe POSIX
creationDateTime :: Maybe POSIX
$sel:creationDateTime:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe POSIX
creationDateTime} -> Maybe POSIX
creationDateTime) (\s :: UpdateSlotTypeResponse
s@UpdateSlotTypeResponse' {} Maybe POSIX
a -> UpdateSlotTypeResponse
s {$sel:creationDateTime:UpdateSlotTypeResponse' :: Maybe POSIX
creationDateTime = Maybe POSIX
a} :: UpdateSlotTypeResponse) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall (a :: Format). Iso' (Time a) UTCTime
Data._Time

-- | The updated description of the slot type.
updateSlotTypeResponse_description :: Lens.Lens' UpdateSlotTypeResponse (Prelude.Maybe Prelude.Text)
updateSlotTypeResponse_description :: Lens' UpdateSlotTypeResponse (Maybe Text)
updateSlotTypeResponse_description = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotTypeResponse' {Maybe Text
description :: Maybe Text
$sel:description:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe Text
description} -> Maybe Text
description) (\s :: UpdateSlotTypeResponse
s@UpdateSlotTypeResponse' {} Maybe Text
a -> UpdateSlotTypeResponse
s {$sel:description:UpdateSlotTypeResponse' :: Maybe Text
description = Maybe Text
a} :: UpdateSlotTypeResponse)

-- | Undocumented member.
updateSlotTypeResponse_externalSourceSetting :: Lens.Lens' UpdateSlotTypeResponse (Prelude.Maybe ExternalSourceSetting)
updateSlotTypeResponse_externalSourceSetting :: Lens' UpdateSlotTypeResponse (Maybe ExternalSourceSetting)
updateSlotTypeResponse_externalSourceSetting = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotTypeResponse' {Maybe ExternalSourceSetting
externalSourceSetting :: Maybe ExternalSourceSetting
$sel:externalSourceSetting:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe ExternalSourceSetting
externalSourceSetting} -> Maybe ExternalSourceSetting
externalSourceSetting) (\s :: UpdateSlotTypeResponse
s@UpdateSlotTypeResponse' {} Maybe ExternalSourceSetting
a -> UpdateSlotTypeResponse
s {$sel:externalSourceSetting:UpdateSlotTypeResponse' :: Maybe ExternalSourceSetting
externalSourceSetting = Maybe ExternalSourceSetting
a} :: UpdateSlotTypeResponse)

-- | A timestamp of the date and time that the slot type was last updated.
updateSlotTypeResponse_lastUpdatedDateTime :: Lens.Lens' UpdateSlotTypeResponse (Prelude.Maybe Prelude.UTCTime)
updateSlotTypeResponse_lastUpdatedDateTime :: Lens' UpdateSlotTypeResponse (Maybe UTCTime)
updateSlotTypeResponse_lastUpdatedDateTime = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotTypeResponse' {Maybe POSIX
lastUpdatedDateTime :: Maybe POSIX
$sel:lastUpdatedDateTime:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe POSIX
lastUpdatedDateTime} -> Maybe POSIX
lastUpdatedDateTime) (\s :: UpdateSlotTypeResponse
s@UpdateSlotTypeResponse' {} Maybe POSIX
a -> UpdateSlotTypeResponse
s {$sel:lastUpdatedDateTime:UpdateSlotTypeResponse' :: Maybe POSIX
lastUpdatedDateTime = Maybe POSIX
a} :: UpdateSlotTypeResponse) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall (a :: Format). Iso' (Time a) UTCTime
Data._Time

-- | The language and locale of the updated slot type.
updateSlotTypeResponse_localeId :: Lens.Lens' UpdateSlotTypeResponse (Prelude.Maybe Prelude.Text)
updateSlotTypeResponse_localeId :: Lens' UpdateSlotTypeResponse (Maybe Text)
updateSlotTypeResponse_localeId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotTypeResponse' {Maybe Text
localeId :: Maybe Text
$sel:localeId:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe Text
localeId} -> Maybe Text
localeId) (\s :: UpdateSlotTypeResponse
s@UpdateSlotTypeResponse' {} Maybe Text
a -> UpdateSlotTypeResponse
s {$sel:localeId:UpdateSlotTypeResponse' :: Maybe Text
localeId = Maybe Text
a} :: UpdateSlotTypeResponse)

-- | The updated signature of the built-in slot type that is the parent of
-- this slot type.
updateSlotTypeResponse_parentSlotTypeSignature :: Lens.Lens' UpdateSlotTypeResponse (Prelude.Maybe Prelude.Text)
updateSlotTypeResponse_parentSlotTypeSignature :: Lens' UpdateSlotTypeResponse (Maybe Text)
updateSlotTypeResponse_parentSlotTypeSignature = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotTypeResponse' {Maybe Text
parentSlotTypeSignature :: Maybe Text
$sel:parentSlotTypeSignature:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe Text
parentSlotTypeSignature} -> Maybe Text
parentSlotTypeSignature) (\s :: UpdateSlotTypeResponse
s@UpdateSlotTypeResponse' {} Maybe Text
a -> UpdateSlotTypeResponse
s {$sel:parentSlotTypeSignature:UpdateSlotTypeResponse' :: Maybe Text
parentSlotTypeSignature = Maybe Text
a} :: UpdateSlotTypeResponse)

-- | The unique identifier of the updated slot type.
updateSlotTypeResponse_slotTypeId :: Lens.Lens' UpdateSlotTypeResponse (Prelude.Maybe Prelude.Text)
updateSlotTypeResponse_slotTypeId :: Lens' UpdateSlotTypeResponse (Maybe Text)
updateSlotTypeResponse_slotTypeId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotTypeResponse' {Maybe Text
slotTypeId :: Maybe Text
$sel:slotTypeId:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe Text
slotTypeId} -> Maybe Text
slotTypeId) (\s :: UpdateSlotTypeResponse
s@UpdateSlotTypeResponse' {} Maybe Text
a -> UpdateSlotTypeResponse
s {$sel:slotTypeId:UpdateSlotTypeResponse' :: Maybe Text
slotTypeId = Maybe Text
a} :: UpdateSlotTypeResponse)

-- | The updated name of the slot type.
updateSlotTypeResponse_slotTypeName :: Lens.Lens' UpdateSlotTypeResponse (Prelude.Maybe Prelude.Text)
updateSlotTypeResponse_slotTypeName :: Lens' UpdateSlotTypeResponse (Maybe Text)
updateSlotTypeResponse_slotTypeName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotTypeResponse' {Maybe Text
slotTypeName :: Maybe Text
$sel:slotTypeName:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe Text
slotTypeName} -> Maybe Text
slotTypeName) (\s :: UpdateSlotTypeResponse
s@UpdateSlotTypeResponse' {} Maybe Text
a -> UpdateSlotTypeResponse
s {$sel:slotTypeName:UpdateSlotTypeResponse' :: Maybe Text
slotTypeName = Maybe Text
a} :: UpdateSlotTypeResponse)

-- | The updated values that the slot type provides.
updateSlotTypeResponse_slotTypeValues :: Lens.Lens' UpdateSlotTypeResponse (Prelude.Maybe (Prelude.NonEmpty SlotTypeValue))
updateSlotTypeResponse_slotTypeValues :: Lens' UpdateSlotTypeResponse (Maybe (NonEmpty SlotTypeValue))
updateSlotTypeResponse_slotTypeValues = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotTypeResponse' {Maybe (NonEmpty SlotTypeValue)
slotTypeValues :: Maybe (NonEmpty SlotTypeValue)
$sel:slotTypeValues:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe (NonEmpty SlotTypeValue)
slotTypeValues} -> Maybe (NonEmpty SlotTypeValue)
slotTypeValues) (\s :: UpdateSlotTypeResponse
s@UpdateSlotTypeResponse' {} Maybe (NonEmpty SlotTypeValue)
a -> UpdateSlotTypeResponse
s {$sel:slotTypeValues:UpdateSlotTypeResponse' :: Maybe (NonEmpty SlotTypeValue)
slotTypeValues = Maybe (NonEmpty SlotTypeValue)
a} :: UpdateSlotTypeResponse) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The updated strategy that Amazon Lex uses to determine which value to
-- select from the slot type.
updateSlotTypeResponse_valueSelectionSetting :: Lens.Lens' UpdateSlotTypeResponse (Prelude.Maybe SlotValueSelectionSetting)
updateSlotTypeResponse_valueSelectionSetting :: Lens' UpdateSlotTypeResponse (Maybe SlotValueSelectionSetting)
updateSlotTypeResponse_valueSelectionSetting = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateSlotTypeResponse' {Maybe SlotValueSelectionSetting
valueSelectionSetting :: Maybe SlotValueSelectionSetting
$sel:valueSelectionSetting:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe SlotValueSelectionSetting
valueSelectionSetting} -> Maybe SlotValueSelectionSetting
valueSelectionSetting) (\s :: UpdateSlotTypeResponse
s@UpdateSlotTypeResponse' {} Maybe SlotValueSelectionSetting
a -> UpdateSlotTypeResponse
s {$sel:valueSelectionSetting:UpdateSlotTypeResponse' :: Maybe SlotValueSelectionSetting
valueSelectionSetting = Maybe SlotValueSelectionSetting
a} :: UpdateSlotTypeResponse)

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

instance Prelude.NFData UpdateSlotTypeResponse where
  rnf :: UpdateSlotTypeResponse -> ()
rnf UpdateSlotTypeResponse' {Int
Maybe (NonEmpty SlotTypeValue)
Maybe Text
Maybe POSIX
Maybe ExternalSourceSetting
Maybe SlotValueSelectionSetting
Maybe CompositeSlotTypeSetting
httpStatus :: Int
valueSelectionSetting :: Maybe SlotValueSelectionSetting
slotTypeValues :: Maybe (NonEmpty SlotTypeValue)
slotTypeName :: Maybe Text
slotTypeId :: Maybe Text
parentSlotTypeSignature :: Maybe Text
localeId :: Maybe Text
lastUpdatedDateTime :: Maybe POSIX
externalSourceSetting :: Maybe ExternalSourceSetting
description :: Maybe Text
creationDateTime :: Maybe POSIX
compositeSlotTypeSetting :: Maybe CompositeSlotTypeSetting
botVersion :: Maybe Text
botId :: Maybe Text
$sel:httpStatus:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Int
$sel:valueSelectionSetting:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe SlotValueSelectionSetting
$sel:slotTypeValues:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe (NonEmpty SlotTypeValue)
$sel:slotTypeName:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe Text
$sel:slotTypeId:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe Text
$sel:parentSlotTypeSignature:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe Text
$sel:localeId:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe Text
$sel:lastUpdatedDateTime:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe POSIX
$sel:externalSourceSetting:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe ExternalSourceSetting
$sel:description:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe Text
$sel:creationDateTime:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe POSIX
$sel:compositeSlotTypeSetting:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe CompositeSlotTypeSetting
$sel:botVersion:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe Text
$sel:botId:UpdateSlotTypeResponse' :: UpdateSlotTypeResponse -> Maybe Text
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
botId
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
botVersion
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe CompositeSlotTypeSetting
compositeSlotTypeSetting
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe POSIX
creationDateTime
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
description
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe ExternalSourceSetting
externalSourceSetting
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe POSIX
lastUpdatedDateTime
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
localeId
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
parentSlotTypeSignature
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
slotTypeId
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
slotTypeName
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe (NonEmpty SlotTypeValue)
slotTypeValues
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe SlotValueSelectionSetting
valueSelectionSetting
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Int
httpStatus