{-# 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.LexModels.CreateSlotTypeVersion
-- 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)
--
-- Creates a new version of a slot type based on the @$LATEST@ version of
-- the specified slot type. If the @$LATEST@ version of this resource has
-- not changed since the last version that you created, Amazon Lex doesn\'t
-- create a new version. It returns the last version that you created.
--
-- You can update only the @$LATEST@ version of a slot type. You can\'t
-- update the numbered versions that you create with the
-- @CreateSlotTypeVersion@ operation.
--
-- When you create a version of a slot type, Amazon Lex sets the version to
-- 1. Subsequent versions increment by 1. For more information, see
-- versioning-intro.
--
-- This operation requires permissions for the @lex:CreateSlotTypeVersion@
-- action.
module Amazonka.LexModels.CreateSlotTypeVersion
  ( -- * Creating a Request
    CreateSlotTypeVersion (..),
    newCreateSlotTypeVersion,

    -- * Request Lenses
    createSlotTypeVersion_checksum,
    createSlotTypeVersion_name,

    -- * Destructuring the Response
    CreateSlotTypeVersionResponse (..),
    newCreateSlotTypeVersionResponse,

    -- * Response Lenses
    createSlotTypeVersionResponse_parentSlotTypeSignature,
    createSlotTypeVersionResponse_slotTypeConfigurations,
    createSlotTypeVersionResponse_checksum,
    createSlotTypeVersionResponse_valueSelectionStrategy,
    createSlotTypeVersionResponse_createdDate,
    createSlotTypeVersionResponse_name,
    createSlotTypeVersionResponse_version,
    createSlotTypeVersionResponse_lastUpdatedDate,
    createSlotTypeVersionResponse_description,
    createSlotTypeVersionResponse_enumerationValues,
    createSlotTypeVersionResponse_httpStatus,
  )
where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.LexModels.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response

-- | /See:/ 'newCreateSlotTypeVersion' smart constructor.
data CreateSlotTypeVersion = CreateSlotTypeVersion'
  { -- | Checksum for the @$LATEST@ version of the slot type that you want to
    -- publish. If you specify a checksum and the @$LATEST@ version of the slot
    -- type has a different checksum, Amazon Lex returns a
    -- @PreconditionFailedException@ exception and doesn\'t publish the new
    -- version. If you don\'t specify a checksum, Amazon Lex publishes the
    -- @$LATEST@ version.
    CreateSlotTypeVersion -> Maybe Text
checksum :: Prelude.Maybe Prelude.Text,
    -- | The name of the slot type that you want to create a new version for. The
    -- name is case sensitive.
    CreateSlotTypeVersion -> Text
name :: Prelude.Text
  }
  deriving (CreateSlotTypeVersion -> CreateSlotTypeVersion -> Bool
(CreateSlotTypeVersion -> CreateSlotTypeVersion -> Bool)
-> (CreateSlotTypeVersion -> CreateSlotTypeVersion -> Bool)
-> Eq CreateSlotTypeVersion
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateSlotTypeVersion -> CreateSlotTypeVersion -> Bool
$c/= :: CreateSlotTypeVersion -> CreateSlotTypeVersion -> Bool
== :: CreateSlotTypeVersion -> CreateSlotTypeVersion -> Bool
$c== :: CreateSlotTypeVersion -> CreateSlotTypeVersion -> Bool
Prelude.Eq, ReadPrec [CreateSlotTypeVersion]
ReadPrec CreateSlotTypeVersion
Int -> ReadS CreateSlotTypeVersion
ReadS [CreateSlotTypeVersion]
(Int -> ReadS CreateSlotTypeVersion)
-> ReadS [CreateSlotTypeVersion]
-> ReadPrec CreateSlotTypeVersion
-> ReadPrec [CreateSlotTypeVersion]
-> Read CreateSlotTypeVersion
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateSlotTypeVersion]
$creadListPrec :: ReadPrec [CreateSlotTypeVersion]
readPrec :: ReadPrec CreateSlotTypeVersion
$creadPrec :: ReadPrec CreateSlotTypeVersion
readList :: ReadS [CreateSlotTypeVersion]
$creadList :: ReadS [CreateSlotTypeVersion]
readsPrec :: Int -> ReadS CreateSlotTypeVersion
$creadsPrec :: Int -> ReadS CreateSlotTypeVersion
Prelude.Read, Int -> CreateSlotTypeVersion -> ShowS
[CreateSlotTypeVersion] -> ShowS
CreateSlotTypeVersion -> String
(Int -> CreateSlotTypeVersion -> ShowS)
-> (CreateSlotTypeVersion -> String)
-> ([CreateSlotTypeVersion] -> ShowS)
-> Show CreateSlotTypeVersion
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateSlotTypeVersion] -> ShowS
$cshowList :: [CreateSlotTypeVersion] -> ShowS
show :: CreateSlotTypeVersion -> String
$cshow :: CreateSlotTypeVersion -> String
showsPrec :: Int -> CreateSlotTypeVersion -> ShowS
$cshowsPrec :: Int -> CreateSlotTypeVersion -> ShowS
Prelude.Show, (forall x. CreateSlotTypeVersion -> Rep CreateSlotTypeVersion x)
-> (forall x. Rep CreateSlotTypeVersion x -> CreateSlotTypeVersion)
-> Generic CreateSlotTypeVersion
forall x. Rep CreateSlotTypeVersion x -> CreateSlotTypeVersion
forall x. CreateSlotTypeVersion -> Rep CreateSlotTypeVersion x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CreateSlotTypeVersion x -> CreateSlotTypeVersion
$cfrom :: forall x. CreateSlotTypeVersion -> Rep CreateSlotTypeVersion x
Prelude.Generic)

-- |
-- Create a value of 'CreateSlotTypeVersion' 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:
--
-- 'checksum', 'createSlotTypeVersion_checksum' - Checksum for the @$LATEST@ version of the slot type that you want to
-- publish. If you specify a checksum and the @$LATEST@ version of the slot
-- type has a different checksum, Amazon Lex returns a
-- @PreconditionFailedException@ exception and doesn\'t publish the new
-- version. If you don\'t specify a checksum, Amazon Lex publishes the
-- @$LATEST@ version.
--
-- 'name', 'createSlotTypeVersion_name' - The name of the slot type that you want to create a new version for. The
-- name is case sensitive.
newCreateSlotTypeVersion ::
  -- | 'name'
  Prelude.Text ->
  CreateSlotTypeVersion
newCreateSlotTypeVersion :: Text -> CreateSlotTypeVersion
newCreateSlotTypeVersion Text
pName_ =
  CreateSlotTypeVersion' :: Maybe Text -> Text -> CreateSlotTypeVersion
CreateSlotTypeVersion'
    { $sel:checksum:CreateSlotTypeVersion' :: Maybe Text
checksum = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:name:CreateSlotTypeVersion' :: Text
name = Text
pName_
    }

-- | Checksum for the @$LATEST@ version of the slot type that you want to
-- publish. If you specify a checksum and the @$LATEST@ version of the slot
-- type has a different checksum, Amazon Lex returns a
-- @PreconditionFailedException@ exception and doesn\'t publish the new
-- version. If you don\'t specify a checksum, Amazon Lex publishes the
-- @$LATEST@ version.
createSlotTypeVersion_checksum :: Lens.Lens' CreateSlotTypeVersion (Prelude.Maybe Prelude.Text)
createSlotTypeVersion_checksum :: (Maybe Text -> f (Maybe Text))
-> CreateSlotTypeVersion -> f CreateSlotTypeVersion
createSlotTypeVersion_checksum = (CreateSlotTypeVersion -> Maybe Text)
-> (CreateSlotTypeVersion -> Maybe Text -> CreateSlotTypeVersion)
-> Lens
     CreateSlotTypeVersion
     CreateSlotTypeVersion
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateSlotTypeVersion' {Maybe Text
checksum :: Maybe Text
$sel:checksum:CreateSlotTypeVersion' :: CreateSlotTypeVersion -> Maybe Text
checksum} -> Maybe Text
checksum) (\s :: CreateSlotTypeVersion
s@CreateSlotTypeVersion' {} Maybe Text
a -> CreateSlotTypeVersion
s {$sel:checksum:CreateSlotTypeVersion' :: Maybe Text
checksum = Maybe Text
a} :: CreateSlotTypeVersion)

-- | The name of the slot type that you want to create a new version for. The
-- name is case sensitive.
createSlotTypeVersion_name :: Lens.Lens' CreateSlotTypeVersion Prelude.Text
createSlotTypeVersion_name :: (Text -> f Text)
-> CreateSlotTypeVersion -> f CreateSlotTypeVersion
createSlotTypeVersion_name = (CreateSlotTypeVersion -> Text)
-> (CreateSlotTypeVersion -> Text -> CreateSlotTypeVersion)
-> Lens CreateSlotTypeVersion CreateSlotTypeVersion Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateSlotTypeVersion' {Text
name :: Text
$sel:name:CreateSlotTypeVersion' :: CreateSlotTypeVersion -> Text
name} -> Text
name) (\s :: CreateSlotTypeVersion
s@CreateSlotTypeVersion' {} Text
a -> CreateSlotTypeVersion
s {$sel:name:CreateSlotTypeVersion' :: Text
name = Text
a} :: CreateSlotTypeVersion)

instance Core.AWSRequest CreateSlotTypeVersion where
  type
    AWSResponse CreateSlotTypeVersion =
      CreateSlotTypeVersionResponse
  request :: CreateSlotTypeVersion -> Request CreateSlotTypeVersion
request = Service -> CreateSlotTypeVersion -> Request CreateSlotTypeVersion
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy CreateSlotTypeVersion
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse CreateSlotTypeVersion)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse CreateSlotTypeVersion))
-> Logger
-> Service
-> Proxy CreateSlotTypeVersion
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse CreateSlotTypeVersion)))
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 Text
-> Maybe [SlotTypeConfiguration]
-> Maybe Text
-> Maybe SlotValueSelectionStrategy
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe [EnumerationValue]
-> Int
-> CreateSlotTypeVersionResponse
CreateSlotTypeVersionResponse'
            (Maybe Text
 -> Maybe [SlotTypeConfiguration]
 -> Maybe Text
 -> Maybe SlotValueSelectionStrategy
 -> Maybe POSIX
 -> Maybe Text
 -> Maybe Text
 -> Maybe POSIX
 -> Maybe Text
 -> Maybe [EnumerationValue]
 -> Int
 -> CreateSlotTypeVersionResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe [SlotTypeConfiguration]
      -> Maybe Text
      -> Maybe SlotValueSelectionStrategy
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe [EnumerationValue]
      -> Int
      -> CreateSlotTypeVersionResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"parentSlotTypeSignature")
            Either
  String
  (Maybe [SlotTypeConfiguration]
   -> Maybe Text
   -> Maybe SlotValueSelectionStrategy
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe [EnumerationValue]
   -> Int
   -> CreateSlotTypeVersionResponse)
-> Either String (Maybe [SlotTypeConfiguration])
-> Either
     String
     (Maybe Text
      -> Maybe SlotValueSelectionStrategy
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe [EnumerationValue]
      -> Int
      -> CreateSlotTypeVersionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object
-> Text -> Either String (Maybe (Maybe [SlotTypeConfiguration]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"slotTypeConfigurations"
                            Either String (Maybe (Maybe [SlotTypeConfiguration]))
-> Maybe [SlotTypeConfiguration]
-> Either String (Maybe [SlotTypeConfiguration])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [SlotTypeConfiguration]
forall a. Monoid a => a
Prelude.mempty
                        )
            Either
  String
  (Maybe Text
   -> Maybe SlotValueSelectionStrategy
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe [EnumerationValue]
   -> Int
   -> CreateSlotTypeVersionResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe SlotValueSelectionStrategy
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe [EnumerationValue]
      -> Int
      -> CreateSlotTypeVersionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"checksum")
            Either
  String
  (Maybe SlotValueSelectionStrategy
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe [EnumerationValue]
   -> Int
   -> CreateSlotTypeVersionResponse)
-> Either String (Maybe SlotValueSelectionStrategy)
-> Either
     String
     (Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe [EnumerationValue]
      -> Int
      -> CreateSlotTypeVersionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe SlotValueSelectionStrategy)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"valueSelectionStrategy")
            Either
  String
  (Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe [EnumerationValue]
   -> Int
   -> CreateSlotTypeVersionResponse)
-> Either String (Maybe POSIX)
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe [EnumerationValue]
      -> Int
      -> CreateSlotTypeVersionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"createdDate")
            Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe [EnumerationValue]
   -> Int
   -> CreateSlotTypeVersionResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe [EnumerationValue]
      -> Int
      -> CreateSlotTypeVersionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"name")
            Either
  String
  (Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe [EnumerationValue]
   -> Int
   -> CreateSlotTypeVersionResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe POSIX
      -> Maybe Text
      -> Maybe [EnumerationValue]
      -> Int
      -> CreateSlotTypeVersionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"version")
            Either
  String
  (Maybe POSIX
   -> Maybe Text
   -> Maybe [EnumerationValue]
   -> Int
   -> CreateSlotTypeVersionResponse)
-> Either String (Maybe POSIX)
-> Either
     String
     (Maybe Text
      -> Maybe [EnumerationValue]
      -> Int
      -> CreateSlotTypeVersionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"lastUpdatedDate")
            Either
  String
  (Maybe Text
   -> Maybe [EnumerationValue]
   -> Int
   -> CreateSlotTypeVersionResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe [EnumerationValue] -> Int -> CreateSlotTypeVersionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"description")
            Either
  String
  (Maybe [EnumerationValue] -> Int -> CreateSlotTypeVersionResponse)
-> Either String (Maybe [EnumerationValue])
-> Either String (Int -> CreateSlotTypeVersionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object -> Text -> Either String (Maybe (Maybe [EnumerationValue]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"enumerationValues"
                            Either String (Maybe (Maybe [EnumerationValue]))
-> Maybe [EnumerationValue]
-> Either String (Maybe [EnumerationValue])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [EnumerationValue]
forall a. Monoid a => a
Prelude.mempty
                        )
            Either String (Int -> CreateSlotTypeVersionResponse)
-> Either String Int -> Either String CreateSlotTypeVersionResponse
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 CreateSlotTypeVersion

instance Prelude.NFData CreateSlotTypeVersion

instance Core.ToHeaders CreateSlotTypeVersion where
  toHeaders :: CreateSlotTypeVersion -> ResponseHeaders
toHeaders =
    ResponseHeaders -> CreateSlotTypeVersion -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
      ( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
          [ 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 CreateSlotTypeVersion where
  toJSON :: CreateSlotTypeVersion -> Value
toJSON CreateSlotTypeVersion' {Maybe Text
Text
name :: Text
checksum :: Maybe Text
$sel:name:CreateSlotTypeVersion' :: CreateSlotTypeVersion -> Text
$sel:checksum:CreateSlotTypeVersion' :: CreateSlotTypeVersion -> Maybe Text
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [(Text
"checksum" 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
checksum]
      )

instance Core.ToPath CreateSlotTypeVersion where
  toPath :: CreateSlotTypeVersion -> ByteString
toPath CreateSlotTypeVersion' {Maybe Text
Text
name :: Text
checksum :: Maybe Text
$sel:name:CreateSlotTypeVersion' :: CreateSlotTypeVersion -> Text
$sel:checksum:CreateSlotTypeVersion' :: CreateSlotTypeVersion -> Maybe Text
..} =
    [ByteString] -> ByteString
forall a. Monoid a => [a] -> a
Prelude.mconcat
      [ByteString
"/slottypes/", Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
name, ByteString
"/versions"]

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

-- | /See:/ 'newCreateSlotTypeVersionResponse' smart constructor.
data CreateSlotTypeVersionResponse = CreateSlotTypeVersionResponse'
  { -- | The built-in slot type used a the parent of the slot type.
    CreateSlotTypeVersionResponse -> Maybe Text
parentSlotTypeSignature :: Prelude.Maybe Prelude.Text,
    -- | Configuration information that extends the parent built-in slot type.
    CreateSlotTypeVersionResponse -> Maybe [SlotTypeConfiguration]
slotTypeConfigurations :: Prelude.Maybe [SlotTypeConfiguration],
    -- | Checksum of the @$LATEST@ version of the slot type.
    CreateSlotTypeVersionResponse -> Maybe Text
checksum :: Prelude.Maybe Prelude.Text,
    -- | The strategy that Amazon Lex uses to determine the value of the slot.
    -- For more information, see PutSlotType.
    CreateSlotTypeVersionResponse -> Maybe SlotValueSelectionStrategy
valueSelectionStrategy :: Prelude.Maybe SlotValueSelectionStrategy,
    -- | The date that the slot type was created.
    CreateSlotTypeVersionResponse -> Maybe POSIX
createdDate :: Prelude.Maybe Core.POSIX,
    -- | The name of the slot type.
    CreateSlotTypeVersionResponse -> Maybe Text
name :: Prelude.Maybe Prelude.Text,
    -- | The version assigned to the new slot type version.
    CreateSlotTypeVersionResponse -> Maybe Text
version :: Prelude.Maybe Prelude.Text,
    -- | The date that the slot type was updated. When you create a resource, the
    -- creation date and last update date are the same.
    CreateSlotTypeVersionResponse -> Maybe POSIX
lastUpdatedDate :: Prelude.Maybe Core.POSIX,
    -- | A description of the slot type.
    CreateSlotTypeVersionResponse -> Maybe Text
description :: Prelude.Maybe Prelude.Text,
    -- | A list of @EnumerationValue@ objects that defines the values that the
    -- slot type can take.
    CreateSlotTypeVersionResponse -> Maybe [EnumerationValue]
enumerationValues :: Prelude.Maybe [EnumerationValue],
    -- | The response's http status code.
    CreateSlotTypeVersionResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (CreateSlotTypeVersionResponse
-> CreateSlotTypeVersionResponse -> Bool
(CreateSlotTypeVersionResponse
 -> CreateSlotTypeVersionResponse -> Bool)
-> (CreateSlotTypeVersionResponse
    -> CreateSlotTypeVersionResponse -> Bool)
-> Eq CreateSlotTypeVersionResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateSlotTypeVersionResponse
-> CreateSlotTypeVersionResponse -> Bool
$c/= :: CreateSlotTypeVersionResponse
-> CreateSlotTypeVersionResponse -> Bool
== :: CreateSlotTypeVersionResponse
-> CreateSlotTypeVersionResponse -> Bool
$c== :: CreateSlotTypeVersionResponse
-> CreateSlotTypeVersionResponse -> Bool
Prelude.Eq, ReadPrec [CreateSlotTypeVersionResponse]
ReadPrec CreateSlotTypeVersionResponse
Int -> ReadS CreateSlotTypeVersionResponse
ReadS [CreateSlotTypeVersionResponse]
(Int -> ReadS CreateSlotTypeVersionResponse)
-> ReadS [CreateSlotTypeVersionResponse]
-> ReadPrec CreateSlotTypeVersionResponse
-> ReadPrec [CreateSlotTypeVersionResponse]
-> Read CreateSlotTypeVersionResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateSlotTypeVersionResponse]
$creadListPrec :: ReadPrec [CreateSlotTypeVersionResponse]
readPrec :: ReadPrec CreateSlotTypeVersionResponse
$creadPrec :: ReadPrec CreateSlotTypeVersionResponse
readList :: ReadS [CreateSlotTypeVersionResponse]
$creadList :: ReadS [CreateSlotTypeVersionResponse]
readsPrec :: Int -> ReadS CreateSlotTypeVersionResponse
$creadsPrec :: Int -> ReadS CreateSlotTypeVersionResponse
Prelude.Read, Int -> CreateSlotTypeVersionResponse -> ShowS
[CreateSlotTypeVersionResponse] -> ShowS
CreateSlotTypeVersionResponse -> String
(Int -> CreateSlotTypeVersionResponse -> ShowS)
-> (CreateSlotTypeVersionResponse -> String)
-> ([CreateSlotTypeVersionResponse] -> ShowS)
-> Show CreateSlotTypeVersionResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateSlotTypeVersionResponse] -> ShowS
$cshowList :: [CreateSlotTypeVersionResponse] -> ShowS
show :: CreateSlotTypeVersionResponse -> String
$cshow :: CreateSlotTypeVersionResponse -> String
showsPrec :: Int -> CreateSlotTypeVersionResponse -> ShowS
$cshowsPrec :: Int -> CreateSlotTypeVersionResponse -> ShowS
Prelude.Show, (forall x.
 CreateSlotTypeVersionResponse
 -> Rep CreateSlotTypeVersionResponse x)
-> (forall x.
    Rep CreateSlotTypeVersionResponse x
    -> CreateSlotTypeVersionResponse)
-> Generic CreateSlotTypeVersionResponse
forall x.
Rep CreateSlotTypeVersionResponse x
-> CreateSlotTypeVersionResponse
forall x.
CreateSlotTypeVersionResponse
-> Rep CreateSlotTypeVersionResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep CreateSlotTypeVersionResponse x
-> CreateSlotTypeVersionResponse
$cfrom :: forall x.
CreateSlotTypeVersionResponse
-> Rep CreateSlotTypeVersionResponse x
Prelude.Generic)

-- |
-- Create a value of 'CreateSlotTypeVersionResponse' 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:
--
-- 'parentSlotTypeSignature', 'createSlotTypeVersionResponse_parentSlotTypeSignature' - The built-in slot type used a the parent of the slot type.
--
-- 'slotTypeConfigurations', 'createSlotTypeVersionResponse_slotTypeConfigurations' - Configuration information that extends the parent built-in slot type.
--
-- 'checksum', 'createSlotTypeVersionResponse_checksum' - Checksum of the @$LATEST@ version of the slot type.
--
-- 'valueSelectionStrategy', 'createSlotTypeVersionResponse_valueSelectionStrategy' - The strategy that Amazon Lex uses to determine the value of the slot.
-- For more information, see PutSlotType.
--
-- 'createdDate', 'createSlotTypeVersionResponse_createdDate' - The date that the slot type was created.
--
-- 'name', 'createSlotTypeVersionResponse_name' - The name of the slot type.
--
-- 'version', 'createSlotTypeVersionResponse_version' - The version assigned to the new slot type version.
--
-- 'lastUpdatedDate', 'createSlotTypeVersionResponse_lastUpdatedDate' - The date that the slot type was updated. When you create a resource, the
-- creation date and last update date are the same.
--
-- 'description', 'createSlotTypeVersionResponse_description' - A description of the slot type.
--
-- 'enumerationValues', 'createSlotTypeVersionResponse_enumerationValues' - A list of @EnumerationValue@ objects that defines the values that the
-- slot type can take.
--
-- 'httpStatus', 'createSlotTypeVersionResponse_httpStatus' - The response's http status code.
newCreateSlotTypeVersionResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  CreateSlotTypeVersionResponse
newCreateSlotTypeVersionResponse :: Int -> CreateSlotTypeVersionResponse
newCreateSlotTypeVersionResponse Int
pHttpStatus_ =
  CreateSlotTypeVersionResponse' :: Maybe Text
-> Maybe [SlotTypeConfiguration]
-> Maybe Text
-> Maybe SlotValueSelectionStrategy
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe [EnumerationValue]
-> Int
-> CreateSlotTypeVersionResponse
CreateSlotTypeVersionResponse'
    { $sel:parentSlotTypeSignature:CreateSlotTypeVersionResponse' :: Maybe Text
parentSlotTypeSignature =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:slotTypeConfigurations:CreateSlotTypeVersionResponse' :: Maybe [SlotTypeConfiguration]
slotTypeConfigurations = Maybe [SlotTypeConfiguration]
forall a. Maybe a
Prelude.Nothing,
      $sel:checksum:CreateSlotTypeVersionResponse' :: Maybe Text
checksum = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:valueSelectionStrategy:CreateSlotTypeVersionResponse' :: Maybe SlotValueSelectionStrategy
valueSelectionStrategy = Maybe SlotValueSelectionStrategy
forall a. Maybe a
Prelude.Nothing,
      $sel:createdDate:CreateSlotTypeVersionResponse' :: Maybe POSIX
createdDate = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
      $sel:name:CreateSlotTypeVersionResponse' :: Maybe Text
name = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:version:CreateSlotTypeVersionResponse' :: Maybe Text
version = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:lastUpdatedDate:CreateSlotTypeVersionResponse' :: Maybe POSIX
lastUpdatedDate = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
      $sel:description:CreateSlotTypeVersionResponse' :: Maybe Text
description = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:enumerationValues:CreateSlotTypeVersionResponse' :: Maybe [EnumerationValue]
enumerationValues = Maybe [EnumerationValue]
forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:CreateSlotTypeVersionResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | The built-in slot type used a the parent of the slot type.
createSlotTypeVersionResponse_parentSlotTypeSignature :: Lens.Lens' CreateSlotTypeVersionResponse (Prelude.Maybe Prelude.Text)
createSlotTypeVersionResponse_parentSlotTypeSignature :: (Maybe Text -> f (Maybe Text))
-> CreateSlotTypeVersionResponse -> f CreateSlotTypeVersionResponse
createSlotTypeVersionResponse_parentSlotTypeSignature = (CreateSlotTypeVersionResponse -> Maybe Text)
-> (CreateSlotTypeVersionResponse
    -> Maybe Text -> CreateSlotTypeVersionResponse)
-> Lens
     CreateSlotTypeVersionResponse
     CreateSlotTypeVersionResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateSlotTypeVersionResponse' {Maybe Text
parentSlotTypeSignature :: Maybe Text
$sel:parentSlotTypeSignature:CreateSlotTypeVersionResponse' :: CreateSlotTypeVersionResponse -> Maybe Text
parentSlotTypeSignature} -> Maybe Text
parentSlotTypeSignature) (\s :: CreateSlotTypeVersionResponse
s@CreateSlotTypeVersionResponse' {} Maybe Text
a -> CreateSlotTypeVersionResponse
s {$sel:parentSlotTypeSignature:CreateSlotTypeVersionResponse' :: Maybe Text
parentSlotTypeSignature = Maybe Text
a} :: CreateSlotTypeVersionResponse)

-- | Configuration information that extends the parent built-in slot type.
createSlotTypeVersionResponse_slotTypeConfigurations :: Lens.Lens' CreateSlotTypeVersionResponse (Prelude.Maybe [SlotTypeConfiguration])
createSlotTypeVersionResponse_slotTypeConfigurations :: (Maybe [SlotTypeConfiguration]
 -> f (Maybe [SlotTypeConfiguration]))
-> CreateSlotTypeVersionResponse -> f CreateSlotTypeVersionResponse
createSlotTypeVersionResponse_slotTypeConfigurations = (CreateSlotTypeVersionResponse -> Maybe [SlotTypeConfiguration])
-> (CreateSlotTypeVersionResponse
    -> Maybe [SlotTypeConfiguration] -> CreateSlotTypeVersionResponse)
-> Lens
     CreateSlotTypeVersionResponse
     CreateSlotTypeVersionResponse
     (Maybe [SlotTypeConfiguration])
     (Maybe [SlotTypeConfiguration])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateSlotTypeVersionResponse' {Maybe [SlotTypeConfiguration]
slotTypeConfigurations :: Maybe [SlotTypeConfiguration]
$sel:slotTypeConfigurations:CreateSlotTypeVersionResponse' :: CreateSlotTypeVersionResponse -> Maybe [SlotTypeConfiguration]
slotTypeConfigurations} -> Maybe [SlotTypeConfiguration]
slotTypeConfigurations) (\s :: CreateSlotTypeVersionResponse
s@CreateSlotTypeVersionResponse' {} Maybe [SlotTypeConfiguration]
a -> CreateSlotTypeVersionResponse
s {$sel:slotTypeConfigurations:CreateSlotTypeVersionResponse' :: Maybe [SlotTypeConfiguration]
slotTypeConfigurations = Maybe [SlotTypeConfiguration]
a} :: CreateSlotTypeVersionResponse) ((Maybe [SlotTypeConfiguration]
  -> f (Maybe [SlotTypeConfiguration]))
 -> CreateSlotTypeVersionResponse
 -> f CreateSlotTypeVersionResponse)
-> ((Maybe [SlotTypeConfiguration]
     -> f (Maybe [SlotTypeConfiguration]))
    -> Maybe [SlotTypeConfiguration]
    -> f (Maybe [SlotTypeConfiguration]))
-> (Maybe [SlotTypeConfiguration]
    -> f (Maybe [SlotTypeConfiguration]))
-> CreateSlotTypeVersionResponse
-> f CreateSlotTypeVersionResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [SlotTypeConfiguration]
  [SlotTypeConfiguration]
  [SlotTypeConfiguration]
  [SlotTypeConfiguration]
-> Iso
     (Maybe [SlotTypeConfiguration])
     (Maybe [SlotTypeConfiguration])
     (Maybe [SlotTypeConfiguration])
     (Maybe [SlotTypeConfiguration])
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
  [SlotTypeConfiguration]
  [SlotTypeConfiguration]
  [SlotTypeConfiguration]
  [SlotTypeConfiguration]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | Checksum of the @$LATEST@ version of the slot type.
createSlotTypeVersionResponse_checksum :: Lens.Lens' CreateSlotTypeVersionResponse (Prelude.Maybe Prelude.Text)
createSlotTypeVersionResponse_checksum :: (Maybe Text -> f (Maybe Text))
-> CreateSlotTypeVersionResponse -> f CreateSlotTypeVersionResponse
createSlotTypeVersionResponse_checksum = (CreateSlotTypeVersionResponse -> Maybe Text)
-> (CreateSlotTypeVersionResponse
    -> Maybe Text -> CreateSlotTypeVersionResponse)
-> Lens
     CreateSlotTypeVersionResponse
     CreateSlotTypeVersionResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateSlotTypeVersionResponse' {Maybe Text
checksum :: Maybe Text
$sel:checksum:CreateSlotTypeVersionResponse' :: CreateSlotTypeVersionResponse -> Maybe Text
checksum} -> Maybe Text
checksum) (\s :: CreateSlotTypeVersionResponse
s@CreateSlotTypeVersionResponse' {} Maybe Text
a -> CreateSlotTypeVersionResponse
s {$sel:checksum:CreateSlotTypeVersionResponse' :: Maybe Text
checksum = Maybe Text
a} :: CreateSlotTypeVersionResponse)

-- | The strategy that Amazon Lex uses to determine the value of the slot.
-- For more information, see PutSlotType.
createSlotTypeVersionResponse_valueSelectionStrategy :: Lens.Lens' CreateSlotTypeVersionResponse (Prelude.Maybe SlotValueSelectionStrategy)
createSlotTypeVersionResponse_valueSelectionStrategy :: (Maybe SlotValueSelectionStrategy
 -> f (Maybe SlotValueSelectionStrategy))
-> CreateSlotTypeVersionResponse -> f CreateSlotTypeVersionResponse
createSlotTypeVersionResponse_valueSelectionStrategy = (CreateSlotTypeVersionResponse -> Maybe SlotValueSelectionStrategy)
-> (CreateSlotTypeVersionResponse
    -> Maybe SlotValueSelectionStrategy
    -> CreateSlotTypeVersionResponse)
-> Lens
     CreateSlotTypeVersionResponse
     CreateSlotTypeVersionResponse
     (Maybe SlotValueSelectionStrategy)
     (Maybe SlotValueSelectionStrategy)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateSlotTypeVersionResponse' {Maybe SlotValueSelectionStrategy
valueSelectionStrategy :: Maybe SlotValueSelectionStrategy
$sel:valueSelectionStrategy:CreateSlotTypeVersionResponse' :: CreateSlotTypeVersionResponse -> Maybe SlotValueSelectionStrategy
valueSelectionStrategy} -> Maybe SlotValueSelectionStrategy
valueSelectionStrategy) (\s :: CreateSlotTypeVersionResponse
s@CreateSlotTypeVersionResponse' {} Maybe SlotValueSelectionStrategy
a -> CreateSlotTypeVersionResponse
s {$sel:valueSelectionStrategy:CreateSlotTypeVersionResponse' :: Maybe SlotValueSelectionStrategy
valueSelectionStrategy = Maybe SlotValueSelectionStrategy
a} :: CreateSlotTypeVersionResponse)

-- | The date that the slot type was created.
createSlotTypeVersionResponse_createdDate :: Lens.Lens' CreateSlotTypeVersionResponse (Prelude.Maybe Prelude.UTCTime)
createSlotTypeVersionResponse_createdDate :: (Maybe UTCTime -> f (Maybe UTCTime))
-> CreateSlotTypeVersionResponse -> f CreateSlotTypeVersionResponse
createSlotTypeVersionResponse_createdDate = (CreateSlotTypeVersionResponse -> Maybe POSIX)
-> (CreateSlotTypeVersionResponse
    -> Maybe POSIX -> CreateSlotTypeVersionResponse)
-> Lens
     CreateSlotTypeVersionResponse
     CreateSlotTypeVersionResponse
     (Maybe POSIX)
     (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateSlotTypeVersionResponse' {Maybe POSIX
createdDate :: Maybe POSIX
$sel:createdDate:CreateSlotTypeVersionResponse' :: CreateSlotTypeVersionResponse -> Maybe POSIX
createdDate} -> Maybe POSIX
createdDate) (\s :: CreateSlotTypeVersionResponse
s@CreateSlotTypeVersionResponse' {} Maybe POSIX
a -> CreateSlotTypeVersionResponse
s {$sel:createdDate:CreateSlotTypeVersionResponse' :: Maybe POSIX
createdDate = Maybe POSIX
a} :: CreateSlotTypeVersionResponse) ((Maybe POSIX -> f (Maybe POSIX))
 -> CreateSlotTypeVersionResponse
 -> f CreateSlotTypeVersionResponse)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> CreateSlotTypeVersionResponse
-> f CreateSlotTypeVersionResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso POSIX POSIX UTCTime UTCTime
-> Iso (Maybe POSIX) (Maybe POSIX) (Maybe UTCTime) (Maybe UTCTime)
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 POSIX POSIX UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time

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

-- | The version assigned to the new slot type version.
createSlotTypeVersionResponse_version :: Lens.Lens' CreateSlotTypeVersionResponse (Prelude.Maybe Prelude.Text)
createSlotTypeVersionResponse_version :: (Maybe Text -> f (Maybe Text))
-> CreateSlotTypeVersionResponse -> f CreateSlotTypeVersionResponse
createSlotTypeVersionResponse_version = (CreateSlotTypeVersionResponse -> Maybe Text)
-> (CreateSlotTypeVersionResponse
    -> Maybe Text -> CreateSlotTypeVersionResponse)
-> Lens
     CreateSlotTypeVersionResponse
     CreateSlotTypeVersionResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateSlotTypeVersionResponse' {Maybe Text
version :: Maybe Text
$sel:version:CreateSlotTypeVersionResponse' :: CreateSlotTypeVersionResponse -> Maybe Text
version} -> Maybe Text
version) (\s :: CreateSlotTypeVersionResponse
s@CreateSlotTypeVersionResponse' {} Maybe Text
a -> CreateSlotTypeVersionResponse
s {$sel:version:CreateSlotTypeVersionResponse' :: Maybe Text
version = Maybe Text
a} :: CreateSlotTypeVersionResponse)

-- | The date that the slot type was updated. When you create a resource, the
-- creation date and last update date are the same.
createSlotTypeVersionResponse_lastUpdatedDate :: Lens.Lens' CreateSlotTypeVersionResponse (Prelude.Maybe Prelude.UTCTime)
createSlotTypeVersionResponse_lastUpdatedDate :: (Maybe UTCTime -> f (Maybe UTCTime))
-> CreateSlotTypeVersionResponse -> f CreateSlotTypeVersionResponse
createSlotTypeVersionResponse_lastUpdatedDate = (CreateSlotTypeVersionResponse -> Maybe POSIX)
-> (CreateSlotTypeVersionResponse
    -> Maybe POSIX -> CreateSlotTypeVersionResponse)
-> Lens
     CreateSlotTypeVersionResponse
     CreateSlotTypeVersionResponse
     (Maybe POSIX)
     (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateSlotTypeVersionResponse' {Maybe POSIX
lastUpdatedDate :: Maybe POSIX
$sel:lastUpdatedDate:CreateSlotTypeVersionResponse' :: CreateSlotTypeVersionResponse -> Maybe POSIX
lastUpdatedDate} -> Maybe POSIX
lastUpdatedDate) (\s :: CreateSlotTypeVersionResponse
s@CreateSlotTypeVersionResponse' {} Maybe POSIX
a -> CreateSlotTypeVersionResponse
s {$sel:lastUpdatedDate:CreateSlotTypeVersionResponse' :: Maybe POSIX
lastUpdatedDate = Maybe POSIX
a} :: CreateSlotTypeVersionResponse) ((Maybe POSIX -> f (Maybe POSIX))
 -> CreateSlotTypeVersionResponse
 -> f CreateSlotTypeVersionResponse)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> CreateSlotTypeVersionResponse
-> f CreateSlotTypeVersionResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso POSIX POSIX UTCTime UTCTime
-> Iso (Maybe POSIX) (Maybe POSIX) (Maybe UTCTime) (Maybe UTCTime)
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 POSIX POSIX UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time

-- | A description of the slot type.
createSlotTypeVersionResponse_description :: Lens.Lens' CreateSlotTypeVersionResponse (Prelude.Maybe Prelude.Text)
createSlotTypeVersionResponse_description :: (Maybe Text -> f (Maybe Text))
-> CreateSlotTypeVersionResponse -> f CreateSlotTypeVersionResponse
createSlotTypeVersionResponse_description = (CreateSlotTypeVersionResponse -> Maybe Text)
-> (CreateSlotTypeVersionResponse
    -> Maybe Text -> CreateSlotTypeVersionResponse)
-> Lens
     CreateSlotTypeVersionResponse
     CreateSlotTypeVersionResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateSlotTypeVersionResponse' {Maybe Text
description :: Maybe Text
$sel:description:CreateSlotTypeVersionResponse' :: CreateSlotTypeVersionResponse -> Maybe Text
description} -> Maybe Text
description) (\s :: CreateSlotTypeVersionResponse
s@CreateSlotTypeVersionResponse' {} Maybe Text
a -> CreateSlotTypeVersionResponse
s {$sel:description:CreateSlotTypeVersionResponse' :: Maybe Text
description = Maybe Text
a} :: CreateSlotTypeVersionResponse)

-- | A list of @EnumerationValue@ objects that defines the values that the
-- slot type can take.
createSlotTypeVersionResponse_enumerationValues :: Lens.Lens' CreateSlotTypeVersionResponse (Prelude.Maybe [EnumerationValue])
createSlotTypeVersionResponse_enumerationValues :: (Maybe [EnumerationValue] -> f (Maybe [EnumerationValue]))
-> CreateSlotTypeVersionResponse -> f CreateSlotTypeVersionResponse
createSlotTypeVersionResponse_enumerationValues = (CreateSlotTypeVersionResponse -> Maybe [EnumerationValue])
-> (CreateSlotTypeVersionResponse
    -> Maybe [EnumerationValue] -> CreateSlotTypeVersionResponse)
-> Lens
     CreateSlotTypeVersionResponse
     CreateSlotTypeVersionResponse
     (Maybe [EnumerationValue])
     (Maybe [EnumerationValue])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateSlotTypeVersionResponse' {Maybe [EnumerationValue]
enumerationValues :: Maybe [EnumerationValue]
$sel:enumerationValues:CreateSlotTypeVersionResponse' :: CreateSlotTypeVersionResponse -> Maybe [EnumerationValue]
enumerationValues} -> Maybe [EnumerationValue]
enumerationValues) (\s :: CreateSlotTypeVersionResponse
s@CreateSlotTypeVersionResponse' {} Maybe [EnumerationValue]
a -> CreateSlotTypeVersionResponse
s {$sel:enumerationValues:CreateSlotTypeVersionResponse' :: Maybe [EnumerationValue]
enumerationValues = Maybe [EnumerationValue]
a} :: CreateSlotTypeVersionResponse) ((Maybe [EnumerationValue] -> f (Maybe [EnumerationValue]))
 -> CreateSlotTypeVersionResponse
 -> f CreateSlotTypeVersionResponse)
-> ((Maybe [EnumerationValue] -> f (Maybe [EnumerationValue]))
    -> Maybe [EnumerationValue] -> f (Maybe [EnumerationValue]))
-> (Maybe [EnumerationValue] -> f (Maybe [EnumerationValue]))
-> CreateSlotTypeVersionResponse
-> f CreateSlotTypeVersionResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [EnumerationValue]
  [EnumerationValue]
  [EnumerationValue]
  [EnumerationValue]
-> Iso
     (Maybe [EnumerationValue])
     (Maybe [EnumerationValue])
     (Maybe [EnumerationValue])
     (Maybe [EnumerationValue])
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
  [EnumerationValue]
  [EnumerationValue]
  [EnumerationValue]
  [EnumerationValue]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

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

instance Prelude.NFData CreateSlotTypeVersionResponse