{-# 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.MechanicalTurk.CreateHITWithHITType
-- 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)
--
-- The @CreateHITWithHITType@ operation creates a new Human Intelligence
-- Task (HIT) using an existing HITTypeID generated by the @CreateHITType@
-- operation.
--
-- This is an alternative way to create HITs from the @CreateHIT@
-- operation. This is the recommended best practice for Requesters who are
-- creating large numbers of HITs.
--
-- CreateHITWithHITType also supports several ways to provide question
-- data: by providing a value for the @Question@ parameter that fully
-- specifies the contents of the HIT, or by providing a @HitLayoutId@ and
-- associated @HitLayoutParameters@.
--
-- If a HIT is created with 10 or more maximum assignments, there is an
-- additional fee. For more information, see
-- <https://requester.mturk.com/pricing Amazon Mechanical Turk Pricing>.
module Amazonka.MechanicalTurk.CreateHITWithHITType
  ( -- * Creating a Request
    CreateHITWithHITType (..),
    newCreateHITWithHITType,

    -- * Request Lenses
    createHITWithHITType_hITReviewPolicy,
    createHITWithHITType_uniqueRequestToken,
    createHITWithHITType_requesterAnnotation,
    createHITWithHITType_maxAssignments,
    createHITWithHITType_hITLayoutId,
    createHITWithHITType_hITLayoutParameters,
    createHITWithHITType_question,
    createHITWithHITType_assignmentReviewPolicy,
    createHITWithHITType_hITTypeId,
    createHITWithHITType_lifetimeInSeconds,

    -- * Destructuring the Response
    CreateHITWithHITTypeResponse (..),
    newCreateHITWithHITTypeResponse,

    -- * Response Lenses
    createHITWithHITTypeResponse_hit,
    createHITWithHITTypeResponse_httpStatus,
  )
where

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

-- | /See:/ 'newCreateHITWithHITType' smart constructor.
data CreateHITWithHITType = CreateHITWithHITType'
  { -- | The HIT-level Review Policy applies to the HIT. You can specify for
    -- Mechanical Turk to take various actions based on the policy.
    CreateHITWithHITType -> Maybe ReviewPolicy
hITReviewPolicy :: Prelude.Maybe ReviewPolicy,
    -- | A unique identifier for this request which allows you to retry the call
    -- on error without creating duplicate HITs. This is useful in cases such
    -- as network timeouts where it is unclear whether or not the call
    -- succeeded on the server. If the HIT already exists in the system from a
    -- previous call using the same UniqueRequestToken, subsequent calls will
    -- return a AWS.MechanicalTurk.HitAlreadyExists error with a message
    -- containing the HITId.
    --
    -- Note: It is your responsibility to ensure uniqueness of the token. The
    -- unique token expires after 24 hours. Subsequent calls using the same
    -- UniqueRequestToken made after the 24 hour limit could create duplicate
    -- HITs.
    CreateHITWithHITType -> Maybe Text
uniqueRequestToken :: Prelude.Maybe Prelude.Text,
    -- | An arbitrary data field. The RequesterAnnotation parameter lets your
    -- application attach arbitrary data to the HIT for tracking purposes. For
    -- example, this parameter could be an identifier internal to the
    -- Requester\'s application that corresponds with the HIT.
    --
    -- The RequesterAnnotation parameter for a HIT is only visible to the
    -- Requester who created the HIT. It is not shown to the Worker, or any
    -- other Requester.
    --
    -- The RequesterAnnotation parameter may be different for each HIT you
    -- submit. It does not affect how your HITs are grouped.
    CreateHITWithHITType -> Maybe Text
requesterAnnotation :: Prelude.Maybe Prelude.Text,
    -- | The number of times the HIT can be accepted and completed before the HIT
    -- becomes unavailable.
    CreateHITWithHITType -> Maybe Int
maxAssignments :: Prelude.Maybe Prelude.Int,
    -- | The HITLayoutId allows you to use a pre-existing HIT design with
    -- placeholder values and create an additional HIT by providing those
    -- values as HITLayoutParameters.
    --
    -- Constraints: Either a Question parameter or a HITLayoutId parameter must
    -- be provided.
    CreateHITWithHITType -> Maybe Text
hITLayoutId :: Prelude.Maybe Prelude.Text,
    -- | If the HITLayoutId is provided, any placeholder values must be filled in
    -- with values using the HITLayoutParameter structure. For more
    -- information, see HITLayout.
    CreateHITWithHITType -> Maybe [HITLayoutParameter]
hITLayoutParameters :: Prelude.Maybe [HITLayoutParameter],
    -- | The data the person completing the HIT uses to produce the results.
    --
    -- Constraints: Must be a QuestionForm data structure, an ExternalQuestion
    -- data structure, or an HTMLQuestion data structure. The XML question data
    -- must not be larger than 64 kilobytes (65,535 bytes) in size, including
    -- whitespace.
    --
    -- Either a Question parameter or a HITLayoutId parameter must be provided.
    CreateHITWithHITType -> Maybe Text
question :: Prelude.Maybe Prelude.Text,
    -- | The Assignment-level Review Policy applies to the assignments under the
    -- HIT. You can specify for Mechanical Turk to take various actions based
    -- on the policy.
    CreateHITWithHITType -> Maybe ReviewPolicy
assignmentReviewPolicy :: Prelude.Maybe ReviewPolicy,
    -- | The HIT type ID you want to create this HIT with.
    CreateHITWithHITType -> Text
hITTypeId :: Prelude.Text,
    -- | An amount of time, in seconds, after which the HIT is no longer
    -- available for users to accept. After the lifetime of the HIT elapses,
    -- the HIT no longer appears in HIT searches, even if not all of the
    -- assignments for the HIT have been accepted.
    CreateHITWithHITType -> Integer
lifetimeInSeconds :: Prelude.Integer
  }
  deriving (CreateHITWithHITType -> CreateHITWithHITType -> Bool
(CreateHITWithHITType -> CreateHITWithHITType -> Bool)
-> (CreateHITWithHITType -> CreateHITWithHITType -> Bool)
-> Eq CreateHITWithHITType
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateHITWithHITType -> CreateHITWithHITType -> Bool
$c/= :: CreateHITWithHITType -> CreateHITWithHITType -> Bool
== :: CreateHITWithHITType -> CreateHITWithHITType -> Bool
$c== :: CreateHITWithHITType -> CreateHITWithHITType -> Bool
Prelude.Eq, ReadPrec [CreateHITWithHITType]
ReadPrec CreateHITWithHITType
Int -> ReadS CreateHITWithHITType
ReadS [CreateHITWithHITType]
(Int -> ReadS CreateHITWithHITType)
-> ReadS [CreateHITWithHITType]
-> ReadPrec CreateHITWithHITType
-> ReadPrec [CreateHITWithHITType]
-> Read CreateHITWithHITType
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateHITWithHITType]
$creadListPrec :: ReadPrec [CreateHITWithHITType]
readPrec :: ReadPrec CreateHITWithHITType
$creadPrec :: ReadPrec CreateHITWithHITType
readList :: ReadS [CreateHITWithHITType]
$creadList :: ReadS [CreateHITWithHITType]
readsPrec :: Int -> ReadS CreateHITWithHITType
$creadsPrec :: Int -> ReadS CreateHITWithHITType
Prelude.Read, Int -> CreateHITWithHITType -> ShowS
[CreateHITWithHITType] -> ShowS
CreateHITWithHITType -> String
(Int -> CreateHITWithHITType -> ShowS)
-> (CreateHITWithHITType -> String)
-> ([CreateHITWithHITType] -> ShowS)
-> Show CreateHITWithHITType
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateHITWithHITType] -> ShowS
$cshowList :: [CreateHITWithHITType] -> ShowS
show :: CreateHITWithHITType -> String
$cshow :: CreateHITWithHITType -> String
showsPrec :: Int -> CreateHITWithHITType -> ShowS
$cshowsPrec :: Int -> CreateHITWithHITType -> ShowS
Prelude.Show, (forall x. CreateHITWithHITType -> Rep CreateHITWithHITType x)
-> (forall x. Rep CreateHITWithHITType x -> CreateHITWithHITType)
-> Generic CreateHITWithHITType
forall x. Rep CreateHITWithHITType x -> CreateHITWithHITType
forall x. CreateHITWithHITType -> Rep CreateHITWithHITType x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CreateHITWithHITType x -> CreateHITWithHITType
$cfrom :: forall x. CreateHITWithHITType -> Rep CreateHITWithHITType x
Prelude.Generic)

-- |
-- Create a value of 'CreateHITWithHITType' 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:
--
-- 'hITReviewPolicy', 'createHITWithHITType_hITReviewPolicy' - The HIT-level Review Policy applies to the HIT. You can specify for
-- Mechanical Turk to take various actions based on the policy.
--
-- 'uniqueRequestToken', 'createHITWithHITType_uniqueRequestToken' - A unique identifier for this request which allows you to retry the call
-- on error without creating duplicate HITs. This is useful in cases such
-- as network timeouts where it is unclear whether or not the call
-- succeeded on the server. If the HIT already exists in the system from a
-- previous call using the same UniqueRequestToken, subsequent calls will
-- return a AWS.MechanicalTurk.HitAlreadyExists error with a message
-- containing the HITId.
--
-- Note: It is your responsibility to ensure uniqueness of the token. The
-- unique token expires after 24 hours. Subsequent calls using the same
-- UniqueRequestToken made after the 24 hour limit could create duplicate
-- HITs.
--
-- 'requesterAnnotation', 'createHITWithHITType_requesterAnnotation' - An arbitrary data field. The RequesterAnnotation parameter lets your
-- application attach arbitrary data to the HIT for tracking purposes. For
-- example, this parameter could be an identifier internal to the
-- Requester\'s application that corresponds with the HIT.
--
-- The RequesterAnnotation parameter for a HIT is only visible to the
-- Requester who created the HIT. It is not shown to the Worker, or any
-- other Requester.
--
-- The RequesterAnnotation parameter may be different for each HIT you
-- submit. It does not affect how your HITs are grouped.
--
-- 'maxAssignments', 'createHITWithHITType_maxAssignments' - The number of times the HIT can be accepted and completed before the HIT
-- becomes unavailable.
--
-- 'hITLayoutId', 'createHITWithHITType_hITLayoutId' - The HITLayoutId allows you to use a pre-existing HIT design with
-- placeholder values and create an additional HIT by providing those
-- values as HITLayoutParameters.
--
-- Constraints: Either a Question parameter or a HITLayoutId parameter must
-- be provided.
--
-- 'hITLayoutParameters', 'createHITWithHITType_hITLayoutParameters' - If the HITLayoutId is provided, any placeholder values must be filled in
-- with values using the HITLayoutParameter structure. For more
-- information, see HITLayout.
--
-- 'question', 'createHITWithHITType_question' - The data the person completing the HIT uses to produce the results.
--
-- Constraints: Must be a QuestionForm data structure, an ExternalQuestion
-- data structure, or an HTMLQuestion data structure. The XML question data
-- must not be larger than 64 kilobytes (65,535 bytes) in size, including
-- whitespace.
--
-- Either a Question parameter or a HITLayoutId parameter must be provided.
--
-- 'assignmentReviewPolicy', 'createHITWithHITType_assignmentReviewPolicy' - The Assignment-level Review Policy applies to the assignments under the
-- HIT. You can specify for Mechanical Turk to take various actions based
-- on the policy.
--
-- 'hITTypeId', 'createHITWithHITType_hITTypeId' - The HIT type ID you want to create this HIT with.
--
-- 'lifetimeInSeconds', 'createHITWithHITType_lifetimeInSeconds' - An amount of time, in seconds, after which the HIT is no longer
-- available for users to accept. After the lifetime of the HIT elapses,
-- the HIT no longer appears in HIT searches, even if not all of the
-- assignments for the HIT have been accepted.
newCreateHITWithHITType ::
  -- | 'hITTypeId'
  Prelude.Text ->
  -- | 'lifetimeInSeconds'
  Prelude.Integer ->
  CreateHITWithHITType
newCreateHITWithHITType :: Text -> Integer -> CreateHITWithHITType
newCreateHITWithHITType
  Text
pHITTypeId_
  Integer
pLifetimeInSeconds_ =
    CreateHITWithHITType' :: Maybe ReviewPolicy
-> Maybe Text
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe [HITLayoutParameter]
-> Maybe Text
-> Maybe ReviewPolicy
-> Text
-> Integer
-> CreateHITWithHITType
CreateHITWithHITType'
      { $sel:hITReviewPolicy:CreateHITWithHITType' :: Maybe ReviewPolicy
hITReviewPolicy =
          Maybe ReviewPolicy
forall a. Maybe a
Prelude.Nothing,
        $sel:uniqueRequestToken:CreateHITWithHITType' :: Maybe Text
uniqueRequestToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:requesterAnnotation:CreateHITWithHITType' :: Maybe Text
requesterAnnotation = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:maxAssignments:CreateHITWithHITType' :: Maybe Int
maxAssignments = Maybe Int
forall a. Maybe a
Prelude.Nothing,
        $sel:hITLayoutId:CreateHITWithHITType' :: Maybe Text
hITLayoutId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:hITLayoutParameters:CreateHITWithHITType' :: Maybe [HITLayoutParameter]
hITLayoutParameters = Maybe [HITLayoutParameter]
forall a. Maybe a
Prelude.Nothing,
        $sel:question:CreateHITWithHITType' :: Maybe Text
question = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:assignmentReviewPolicy:CreateHITWithHITType' :: Maybe ReviewPolicy
assignmentReviewPolicy = Maybe ReviewPolicy
forall a. Maybe a
Prelude.Nothing,
        $sel:hITTypeId:CreateHITWithHITType' :: Text
hITTypeId = Text
pHITTypeId_,
        $sel:lifetimeInSeconds:CreateHITWithHITType' :: Integer
lifetimeInSeconds = Integer
pLifetimeInSeconds_
      }

-- | The HIT-level Review Policy applies to the HIT. You can specify for
-- Mechanical Turk to take various actions based on the policy.
createHITWithHITType_hITReviewPolicy :: Lens.Lens' CreateHITWithHITType (Prelude.Maybe ReviewPolicy)
createHITWithHITType_hITReviewPolicy :: (Maybe ReviewPolicy -> f (Maybe ReviewPolicy))
-> CreateHITWithHITType -> f CreateHITWithHITType
createHITWithHITType_hITReviewPolicy = (CreateHITWithHITType -> Maybe ReviewPolicy)
-> (CreateHITWithHITType
    -> Maybe ReviewPolicy -> CreateHITWithHITType)
-> Lens
     CreateHITWithHITType
     CreateHITWithHITType
     (Maybe ReviewPolicy)
     (Maybe ReviewPolicy)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateHITWithHITType' {Maybe ReviewPolicy
hITReviewPolicy :: Maybe ReviewPolicy
$sel:hITReviewPolicy:CreateHITWithHITType' :: CreateHITWithHITType -> Maybe ReviewPolicy
hITReviewPolicy} -> Maybe ReviewPolicy
hITReviewPolicy) (\s :: CreateHITWithHITType
s@CreateHITWithHITType' {} Maybe ReviewPolicy
a -> CreateHITWithHITType
s {$sel:hITReviewPolicy:CreateHITWithHITType' :: Maybe ReviewPolicy
hITReviewPolicy = Maybe ReviewPolicy
a} :: CreateHITWithHITType)

-- | A unique identifier for this request which allows you to retry the call
-- on error without creating duplicate HITs. This is useful in cases such
-- as network timeouts where it is unclear whether or not the call
-- succeeded on the server. If the HIT already exists in the system from a
-- previous call using the same UniqueRequestToken, subsequent calls will
-- return a AWS.MechanicalTurk.HitAlreadyExists error with a message
-- containing the HITId.
--
-- Note: It is your responsibility to ensure uniqueness of the token. The
-- unique token expires after 24 hours. Subsequent calls using the same
-- UniqueRequestToken made after the 24 hour limit could create duplicate
-- HITs.
createHITWithHITType_uniqueRequestToken :: Lens.Lens' CreateHITWithHITType (Prelude.Maybe Prelude.Text)
createHITWithHITType_uniqueRequestToken :: (Maybe Text -> f (Maybe Text))
-> CreateHITWithHITType -> f CreateHITWithHITType
createHITWithHITType_uniqueRequestToken = (CreateHITWithHITType -> Maybe Text)
-> (CreateHITWithHITType -> Maybe Text -> CreateHITWithHITType)
-> Lens
     CreateHITWithHITType CreateHITWithHITType (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateHITWithHITType' {Maybe Text
uniqueRequestToken :: Maybe Text
$sel:uniqueRequestToken:CreateHITWithHITType' :: CreateHITWithHITType -> Maybe Text
uniqueRequestToken} -> Maybe Text
uniqueRequestToken) (\s :: CreateHITWithHITType
s@CreateHITWithHITType' {} Maybe Text
a -> CreateHITWithHITType
s {$sel:uniqueRequestToken:CreateHITWithHITType' :: Maybe Text
uniqueRequestToken = Maybe Text
a} :: CreateHITWithHITType)

-- | An arbitrary data field. The RequesterAnnotation parameter lets your
-- application attach arbitrary data to the HIT for tracking purposes. For
-- example, this parameter could be an identifier internal to the
-- Requester\'s application that corresponds with the HIT.
--
-- The RequesterAnnotation parameter for a HIT is only visible to the
-- Requester who created the HIT. It is not shown to the Worker, or any
-- other Requester.
--
-- The RequesterAnnotation parameter may be different for each HIT you
-- submit. It does not affect how your HITs are grouped.
createHITWithHITType_requesterAnnotation :: Lens.Lens' CreateHITWithHITType (Prelude.Maybe Prelude.Text)
createHITWithHITType_requesterAnnotation :: (Maybe Text -> f (Maybe Text))
-> CreateHITWithHITType -> f CreateHITWithHITType
createHITWithHITType_requesterAnnotation = (CreateHITWithHITType -> Maybe Text)
-> (CreateHITWithHITType -> Maybe Text -> CreateHITWithHITType)
-> Lens
     CreateHITWithHITType CreateHITWithHITType (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateHITWithHITType' {Maybe Text
requesterAnnotation :: Maybe Text
$sel:requesterAnnotation:CreateHITWithHITType' :: CreateHITWithHITType -> Maybe Text
requesterAnnotation} -> Maybe Text
requesterAnnotation) (\s :: CreateHITWithHITType
s@CreateHITWithHITType' {} Maybe Text
a -> CreateHITWithHITType
s {$sel:requesterAnnotation:CreateHITWithHITType' :: Maybe Text
requesterAnnotation = Maybe Text
a} :: CreateHITWithHITType)

-- | The number of times the HIT can be accepted and completed before the HIT
-- becomes unavailable.
createHITWithHITType_maxAssignments :: Lens.Lens' CreateHITWithHITType (Prelude.Maybe Prelude.Int)
createHITWithHITType_maxAssignments :: (Maybe Int -> f (Maybe Int))
-> CreateHITWithHITType -> f CreateHITWithHITType
createHITWithHITType_maxAssignments = (CreateHITWithHITType -> Maybe Int)
-> (CreateHITWithHITType -> Maybe Int -> CreateHITWithHITType)
-> Lens
     CreateHITWithHITType CreateHITWithHITType (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateHITWithHITType' {Maybe Int
maxAssignments :: Maybe Int
$sel:maxAssignments:CreateHITWithHITType' :: CreateHITWithHITType -> Maybe Int
maxAssignments} -> Maybe Int
maxAssignments) (\s :: CreateHITWithHITType
s@CreateHITWithHITType' {} Maybe Int
a -> CreateHITWithHITType
s {$sel:maxAssignments:CreateHITWithHITType' :: Maybe Int
maxAssignments = Maybe Int
a} :: CreateHITWithHITType)

-- | The HITLayoutId allows you to use a pre-existing HIT design with
-- placeholder values and create an additional HIT by providing those
-- values as HITLayoutParameters.
--
-- Constraints: Either a Question parameter or a HITLayoutId parameter must
-- be provided.
createHITWithHITType_hITLayoutId :: Lens.Lens' CreateHITWithHITType (Prelude.Maybe Prelude.Text)
createHITWithHITType_hITLayoutId :: (Maybe Text -> f (Maybe Text))
-> CreateHITWithHITType -> f CreateHITWithHITType
createHITWithHITType_hITLayoutId = (CreateHITWithHITType -> Maybe Text)
-> (CreateHITWithHITType -> Maybe Text -> CreateHITWithHITType)
-> Lens
     CreateHITWithHITType CreateHITWithHITType (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateHITWithHITType' {Maybe Text
hITLayoutId :: Maybe Text
$sel:hITLayoutId:CreateHITWithHITType' :: CreateHITWithHITType -> Maybe Text
hITLayoutId} -> Maybe Text
hITLayoutId) (\s :: CreateHITWithHITType
s@CreateHITWithHITType' {} Maybe Text
a -> CreateHITWithHITType
s {$sel:hITLayoutId:CreateHITWithHITType' :: Maybe Text
hITLayoutId = Maybe Text
a} :: CreateHITWithHITType)

-- | If the HITLayoutId is provided, any placeholder values must be filled in
-- with values using the HITLayoutParameter structure. For more
-- information, see HITLayout.
createHITWithHITType_hITLayoutParameters :: Lens.Lens' CreateHITWithHITType (Prelude.Maybe [HITLayoutParameter])
createHITWithHITType_hITLayoutParameters :: (Maybe [HITLayoutParameter] -> f (Maybe [HITLayoutParameter]))
-> CreateHITWithHITType -> f CreateHITWithHITType
createHITWithHITType_hITLayoutParameters = (CreateHITWithHITType -> Maybe [HITLayoutParameter])
-> (CreateHITWithHITType
    -> Maybe [HITLayoutParameter] -> CreateHITWithHITType)
-> Lens
     CreateHITWithHITType
     CreateHITWithHITType
     (Maybe [HITLayoutParameter])
     (Maybe [HITLayoutParameter])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateHITWithHITType' {Maybe [HITLayoutParameter]
hITLayoutParameters :: Maybe [HITLayoutParameter]
$sel:hITLayoutParameters:CreateHITWithHITType' :: CreateHITWithHITType -> Maybe [HITLayoutParameter]
hITLayoutParameters} -> Maybe [HITLayoutParameter]
hITLayoutParameters) (\s :: CreateHITWithHITType
s@CreateHITWithHITType' {} Maybe [HITLayoutParameter]
a -> CreateHITWithHITType
s {$sel:hITLayoutParameters:CreateHITWithHITType' :: Maybe [HITLayoutParameter]
hITLayoutParameters = Maybe [HITLayoutParameter]
a} :: CreateHITWithHITType) ((Maybe [HITLayoutParameter] -> f (Maybe [HITLayoutParameter]))
 -> CreateHITWithHITType -> f CreateHITWithHITType)
-> ((Maybe [HITLayoutParameter] -> f (Maybe [HITLayoutParameter]))
    -> Maybe [HITLayoutParameter] -> f (Maybe [HITLayoutParameter]))
-> (Maybe [HITLayoutParameter] -> f (Maybe [HITLayoutParameter]))
-> CreateHITWithHITType
-> f CreateHITWithHITType
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [HITLayoutParameter]
  [HITLayoutParameter]
  [HITLayoutParameter]
  [HITLayoutParameter]
-> Iso
     (Maybe [HITLayoutParameter])
     (Maybe [HITLayoutParameter])
     (Maybe [HITLayoutParameter])
     (Maybe [HITLayoutParameter])
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
  [HITLayoutParameter]
  [HITLayoutParameter]
  [HITLayoutParameter]
  [HITLayoutParameter]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The data the person completing the HIT uses to produce the results.
--
-- Constraints: Must be a QuestionForm data structure, an ExternalQuestion
-- data structure, or an HTMLQuestion data structure. The XML question data
-- must not be larger than 64 kilobytes (65,535 bytes) in size, including
-- whitespace.
--
-- Either a Question parameter or a HITLayoutId parameter must be provided.
createHITWithHITType_question :: Lens.Lens' CreateHITWithHITType (Prelude.Maybe Prelude.Text)
createHITWithHITType_question :: (Maybe Text -> f (Maybe Text))
-> CreateHITWithHITType -> f CreateHITWithHITType
createHITWithHITType_question = (CreateHITWithHITType -> Maybe Text)
-> (CreateHITWithHITType -> Maybe Text -> CreateHITWithHITType)
-> Lens
     CreateHITWithHITType CreateHITWithHITType (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateHITWithHITType' {Maybe Text
question :: Maybe Text
$sel:question:CreateHITWithHITType' :: CreateHITWithHITType -> Maybe Text
question} -> Maybe Text
question) (\s :: CreateHITWithHITType
s@CreateHITWithHITType' {} Maybe Text
a -> CreateHITWithHITType
s {$sel:question:CreateHITWithHITType' :: Maybe Text
question = Maybe Text
a} :: CreateHITWithHITType)

-- | The Assignment-level Review Policy applies to the assignments under the
-- HIT. You can specify for Mechanical Turk to take various actions based
-- on the policy.
createHITWithHITType_assignmentReviewPolicy :: Lens.Lens' CreateHITWithHITType (Prelude.Maybe ReviewPolicy)
createHITWithHITType_assignmentReviewPolicy :: (Maybe ReviewPolicy -> f (Maybe ReviewPolicy))
-> CreateHITWithHITType -> f CreateHITWithHITType
createHITWithHITType_assignmentReviewPolicy = (CreateHITWithHITType -> Maybe ReviewPolicy)
-> (CreateHITWithHITType
    -> Maybe ReviewPolicy -> CreateHITWithHITType)
-> Lens
     CreateHITWithHITType
     CreateHITWithHITType
     (Maybe ReviewPolicy)
     (Maybe ReviewPolicy)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateHITWithHITType' {Maybe ReviewPolicy
assignmentReviewPolicy :: Maybe ReviewPolicy
$sel:assignmentReviewPolicy:CreateHITWithHITType' :: CreateHITWithHITType -> Maybe ReviewPolicy
assignmentReviewPolicy} -> Maybe ReviewPolicy
assignmentReviewPolicy) (\s :: CreateHITWithHITType
s@CreateHITWithHITType' {} Maybe ReviewPolicy
a -> CreateHITWithHITType
s {$sel:assignmentReviewPolicy:CreateHITWithHITType' :: Maybe ReviewPolicy
assignmentReviewPolicy = Maybe ReviewPolicy
a} :: CreateHITWithHITType)

-- | The HIT type ID you want to create this HIT with.
createHITWithHITType_hITTypeId :: Lens.Lens' CreateHITWithHITType Prelude.Text
createHITWithHITType_hITTypeId :: (Text -> f Text) -> CreateHITWithHITType -> f CreateHITWithHITType
createHITWithHITType_hITTypeId = (CreateHITWithHITType -> Text)
-> (CreateHITWithHITType -> Text -> CreateHITWithHITType)
-> Lens CreateHITWithHITType CreateHITWithHITType Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateHITWithHITType' {Text
hITTypeId :: Text
$sel:hITTypeId:CreateHITWithHITType' :: CreateHITWithHITType -> Text
hITTypeId} -> Text
hITTypeId) (\s :: CreateHITWithHITType
s@CreateHITWithHITType' {} Text
a -> CreateHITWithHITType
s {$sel:hITTypeId:CreateHITWithHITType' :: Text
hITTypeId = Text
a} :: CreateHITWithHITType)

-- | An amount of time, in seconds, after which the HIT is no longer
-- available for users to accept. After the lifetime of the HIT elapses,
-- the HIT no longer appears in HIT searches, even if not all of the
-- assignments for the HIT have been accepted.
createHITWithHITType_lifetimeInSeconds :: Lens.Lens' CreateHITWithHITType Prelude.Integer
createHITWithHITType_lifetimeInSeconds :: (Integer -> f Integer)
-> CreateHITWithHITType -> f CreateHITWithHITType
createHITWithHITType_lifetimeInSeconds = (CreateHITWithHITType -> Integer)
-> (CreateHITWithHITType -> Integer -> CreateHITWithHITType)
-> Lens CreateHITWithHITType CreateHITWithHITType Integer Integer
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateHITWithHITType' {Integer
lifetimeInSeconds :: Integer
$sel:lifetimeInSeconds:CreateHITWithHITType' :: CreateHITWithHITType -> Integer
lifetimeInSeconds} -> Integer
lifetimeInSeconds) (\s :: CreateHITWithHITType
s@CreateHITWithHITType' {} Integer
a -> CreateHITWithHITType
s {$sel:lifetimeInSeconds:CreateHITWithHITType' :: Integer
lifetimeInSeconds = Integer
a} :: CreateHITWithHITType)

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

instance Prelude.NFData CreateHITWithHITType

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

instance Core.ToJSON CreateHITWithHITType where
  toJSON :: CreateHITWithHITType -> Value
toJSON CreateHITWithHITType' {Integer
Maybe Int
Maybe [HITLayoutParameter]
Maybe Text
Maybe ReviewPolicy
Text
lifetimeInSeconds :: Integer
hITTypeId :: Text
assignmentReviewPolicy :: Maybe ReviewPolicy
question :: Maybe Text
hITLayoutParameters :: Maybe [HITLayoutParameter]
hITLayoutId :: Maybe Text
maxAssignments :: Maybe Int
requesterAnnotation :: Maybe Text
uniqueRequestToken :: Maybe Text
hITReviewPolicy :: Maybe ReviewPolicy
$sel:lifetimeInSeconds:CreateHITWithHITType' :: CreateHITWithHITType -> Integer
$sel:hITTypeId:CreateHITWithHITType' :: CreateHITWithHITType -> Text
$sel:assignmentReviewPolicy:CreateHITWithHITType' :: CreateHITWithHITType -> Maybe ReviewPolicy
$sel:question:CreateHITWithHITType' :: CreateHITWithHITType -> Maybe Text
$sel:hITLayoutParameters:CreateHITWithHITType' :: CreateHITWithHITType -> Maybe [HITLayoutParameter]
$sel:hITLayoutId:CreateHITWithHITType' :: CreateHITWithHITType -> Maybe Text
$sel:maxAssignments:CreateHITWithHITType' :: CreateHITWithHITType -> Maybe Int
$sel:requesterAnnotation:CreateHITWithHITType' :: CreateHITWithHITType -> Maybe Text
$sel:uniqueRequestToken:CreateHITWithHITType' :: CreateHITWithHITType -> Maybe Text
$sel:hITReviewPolicy:CreateHITWithHITType' :: CreateHITWithHITType -> Maybe ReviewPolicy
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Text
"HITReviewPolicy" Text -> ReviewPolicy -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (ReviewPolicy -> Pair) -> Maybe ReviewPolicy -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ReviewPolicy
hITReviewPolicy,
            (Text
"UniqueRequestToken" 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
uniqueRequestToken,
            (Text
"RequesterAnnotation" 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
requesterAnnotation,
            (Text
"MaxAssignments" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
maxAssignments,
            (Text
"HITLayoutId" 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
hITLayoutId,
            (Text
"HITLayoutParameters" Text -> [HITLayoutParameter] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              ([HITLayoutParameter] -> Pair)
-> Maybe [HITLayoutParameter] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [HITLayoutParameter]
hITLayoutParameters,
            (Text
"Question" 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
question,
            (Text
"AssignmentReviewPolicy" Text -> ReviewPolicy -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (ReviewPolicy -> Pair) -> Maybe ReviewPolicy -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ReviewPolicy
assignmentReviewPolicy,
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"HITTypeId" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
hITTypeId),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just
              (Text
"LifetimeInSeconds" Text -> Integer -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Integer
lifetimeInSeconds)
          ]
      )

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

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

-- | /See:/ 'newCreateHITWithHITTypeResponse' smart constructor.
data CreateHITWithHITTypeResponse = CreateHITWithHITTypeResponse'
  { -- | Contains the newly created HIT data. For a description of the HIT data
    -- structure as it appears in responses, see the HIT Data Structure
    -- documentation.
    CreateHITWithHITTypeResponse -> Maybe HIT
hit :: Prelude.Maybe HIT,
    -- | The response's http status code.
    CreateHITWithHITTypeResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (CreateHITWithHITTypeResponse
-> CreateHITWithHITTypeResponse -> Bool
(CreateHITWithHITTypeResponse
 -> CreateHITWithHITTypeResponse -> Bool)
-> (CreateHITWithHITTypeResponse
    -> CreateHITWithHITTypeResponse -> Bool)
-> Eq CreateHITWithHITTypeResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateHITWithHITTypeResponse
-> CreateHITWithHITTypeResponse -> Bool
$c/= :: CreateHITWithHITTypeResponse
-> CreateHITWithHITTypeResponse -> Bool
== :: CreateHITWithHITTypeResponse
-> CreateHITWithHITTypeResponse -> Bool
$c== :: CreateHITWithHITTypeResponse
-> CreateHITWithHITTypeResponse -> Bool
Prelude.Eq, ReadPrec [CreateHITWithHITTypeResponse]
ReadPrec CreateHITWithHITTypeResponse
Int -> ReadS CreateHITWithHITTypeResponse
ReadS [CreateHITWithHITTypeResponse]
(Int -> ReadS CreateHITWithHITTypeResponse)
-> ReadS [CreateHITWithHITTypeResponse]
-> ReadPrec CreateHITWithHITTypeResponse
-> ReadPrec [CreateHITWithHITTypeResponse]
-> Read CreateHITWithHITTypeResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateHITWithHITTypeResponse]
$creadListPrec :: ReadPrec [CreateHITWithHITTypeResponse]
readPrec :: ReadPrec CreateHITWithHITTypeResponse
$creadPrec :: ReadPrec CreateHITWithHITTypeResponse
readList :: ReadS [CreateHITWithHITTypeResponse]
$creadList :: ReadS [CreateHITWithHITTypeResponse]
readsPrec :: Int -> ReadS CreateHITWithHITTypeResponse
$creadsPrec :: Int -> ReadS CreateHITWithHITTypeResponse
Prelude.Read, Int -> CreateHITWithHITTypeResponse -> ShowS
[CreateHITWithHITTypeResponse] -> ShowS
CreateHITWithHITTypeResponse -> String
(Int -> CreateHITWithHITTypeResponse -> ShowS)
-> (CreateHITWithHITTypeResponse -> String)
-> ([CreateHITWithHITTypeResponse] -> ShowS)
-> Show CreateHITWithHITTypeResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateHITWithHITTypeResponse] -> ShowS
$cshowList :: [CreateHITWithHITTypeResponse] -> ShowS
show :: CreateHITWithHITTypeResponse -> String
$cshow :: CreateHITWithHITTypeResponse -> String
showsPrec :: Int -> CreateHITWithHITTypeResponse -> ShowS
$cshowsPrec :: Int -> CreateHITWithHITTypeResponse -> ShowS
Prelude.Show, (forall x.
 CreateHITWithHITTypeResponse -> Rep CreateHITWithHITTypeResponse x)
-> (forall x.
    Rep CreateHITWithHITTypeResponse x -> CreateHITWithHITTypeResponse)
-> Generic CreateHITWithHITTypeResponse
forall x.
Rep CreateHITWithHITTypeResponse x -> CreateHITWithHITTypeResponse
forall x.
CreateHITWithHITTypeResponse -> Rep CreateHITWithHITTypeResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep CreateHITWithHITTypeResponse x -> CreateHITWithHITTypeResponse
$cfrom :: forall x.
CreateHITWithHITTypeResponse -> Rep CreateHITWithHITTypeResponse x
Prelude.Generic)

-- |
-- Create a value of 'CreateHITWithHITTypeResponse' 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:
--
-- 'hit', 'createHITWithHITTypeResponse_hit' - Contains the newly created HIT data. For a description of the HIT data
-- structure as it appears in responses, see the HIT Data Structure
-- documentation.
--
-- 'httpStatus', 'createHITWithHITTypeResponse_httpStatus' - The response's http status code.
newCreateHITWithHITTypeResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  CreateHITWithHITTypeResponse
newCreateHITWithHITTypeResponse :: Int -> CreateHITWithHITTypeResponse
newCreateHITWithHITTypeResponse Int
pHttpStatus_ =
  CreateHITWithHITTypeResponse' :: Maybe HIT -> Int -> CreateHITWithHITTypeResponse
CreateHITWithHITTypeResponse'
    { $sel:hit:CreateHITWithHITTypeResponse' :: Maybe HIT
hit =
        Maybe HIT
forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:CreateHITWithHITTypeResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | Contains the newly created HIT data. For a description of the HIT data
-- structure as it appears in responses, see the HIT Data Structure
-- documentation.
createHITWithHITTypeResponse_hit :: Lens.Lens' CreateHITWithHITTypeResponse (Prelude.Maybe HIT)
createHITWithHITTypeResponse_hit :: (Maybe HIT -> f (Maybe HIT))
-> CreateHITWithHITTypeResponse -> f CreateHITWithHITTypeResponse
createHITWithHITTypeResponse_hit = (CreateHITWithHITTypeResponse -> Maybe HIT)
-> (CreateHITWithHITTypeResponse
    -> Maybe HIT -> CreateHITWithHITTypeResponse)
-> Lens
     CreateHITWithHITTypeResponse
     CreateHITWithHITTypeResponse
     (Maybe HIT)
     (Maybe HIT)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateHITWithHITTypeResponse' {Maybe HIT
hit :: Maybe HIT
$sel:hit:CreateHITWithHITTypeResponse' :: CreateHITWithHITTypeResponse -> Maybe HIT
hit} -> Maybe HIT
hit) (\s :: CreateHITWithHITTypeResponse
s@CreateHITWithHITTypeResponse' {} Maybe HIT
a -> CreateHITWithHITTypeResponse
s {$sel:hit:CreateHITWithHITTypeResponse' :: Maybe HIT
hit = Maybe HIT
a} :: CreateHITWithHITTypeResponse)

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

instance Prelude.NFData CreateHITWithHITTypeResponse