{-# 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.SageMaker.CreateExperiment
-- 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 an SageMaker /experiment/. An experiment is a collection of
-- /trials/ that are observed, compared and evaluated as a group. A trial
-- is a set of steps, called /trial components/, that produce a machine
-- learning model.
--
-- The goal of an experiment is to determine the components that produce
-- the best model. Multiple trials are performed, each one isolating and
-- measuring the impact of a change to one or more inputs, while keeping
-- the remaining inputs constant.
--
-- When you use SageMaker Studio or the SageMaker Python SDK, all
-- experiments, trials, and trial components are automatically tracked,
-- logged, and indexed. When you use the Amazon Web Services SDK for Python
-- (Boto), you must use the logging APIs provided by the SDK.
--
-- You can add tags to experiments, trials, trial components and then use
-- the Search API to search for the tags.
--
-- To add a description to an experiment, specify the optional
-- @Description@ parameter. To add a description later, or to change the
-- description, call the UpdateExperiment API.
--
-- To get a list of all your experiments, call the ListExperiments API. To
-- view an experiment\'s properties, call the DescribeExperiment API. To
-- get a list of all the trials associated with an experiment, call the
-- ListTrials API. To create a trial call the CreateTrial API.
module Amazonka.SageMaker.CreateExperiment
  ( -- * Creating a Request
    CreateExperiment (..),
    newCreateExperiment,

    -- * Request Lenses
    createExperiment_displayName,
    createExperiment_description,
    createExperiment_tags,
    createExperiment_experimentName,

    -- * Destructuring the Response
    CreateExperimentResponse (..),
    newCreateExperimentResponse,

    -- * Response Lenses
    createExperimentResponse_experimentArn,
    createExperimentResponse_httpStatus,
  )
where

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

-- | /See:/ 'newCreateExperiment' smart constructor.
data CreateExperiment = CreateExperiment'
  { -- | The name of the experiment as displayed. The name doesn\'t need to be
    -- unique. If you don\'t specify @DisplayName@, the value in
    -- @ExperimentName@ is displayed.
    CreateExperiment -> Maybe Text
displayName :: Prelude.Maybe Prelude.Text,
    -- | The description of the experiment.
    CreateExperiment -> Maybe Text
description :: Prelude.Maybe Prelude.Text,
    -- | A list of tags to associate with the experiment. You can use Search API
    -- to search on the tags.
    CreateExperiment -> Maybe [Tag]
tags :: Prelude.Maybe [Tag],
    -- | The name of the experiment. The name must be unique in your Amazon Web
    -- Services account and is not case-sensitive.
    CreateExperiment -> Text
experimentName :: Prelude.Text
  }
  deriving (CreateExperiment -> CreateExperiment -> Bool
(CreateExperiment -> CreateExperiment -> Bool)
-> (CreateExperiment -> CreateExperiment -> Bool)
-> Eq CreateExperiment
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateExperiment -> CreateExperiment -> Bool
$c/= :: CreateExperiment -> CreateExperiment -> Bool
== :: CreateExperiment -> CreateExperiment -> Bool
$c== :: CreateExperiment -> CreateExperiment -> Bool
Prelude.Eq, ReadPrec [CreateExperiment]
ReadPrec CreateExperiment
Int -> ReadS CreateExperiment
ReadS [CreateExperiment]
(Int -> ReadS CreateExperiment)
-> ReadS [CreateExperiment]
-> ReadPrec CreateExperiment
-> ReadPrec [CreateExperiment]
-> Read CreateExperiment
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateExperiment]
$creadListPrec :: ReadPrec [CreateExperiment]
readPrec :: ReadPrec CreateExperiment
$creadPrec :: ReadPrec CreateExperiment
readList :: ReadS [CreateExperiment]
$creadList :: ReadS [CreateExperiment]
readsPrec :: Int -> ReadS CreateExperiment
$creadsPrec :: Int -> ReadS CreateExperiment
Prelude.Read, Int -> CreateExperiment -> ShowS
[CreateExperiment] -> ShowS
CreateExperiment -> String
(Int -> CreateExperiment -> ShowS)
-> (CreateExperiment -> String)
-> ([CreateExperiment] -> ShowS)
-> Show CreateExperiment
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateExperiment] -> ShowS
$cshowList :: [CreateExperiment] -> ShowS
show :: CreateExperiment -> String
$cshow :: CreateExperiment -> String
showsPrec :: Int -> CreateExperiment -> ShowS
$cshowsPrec :: Int -> CreateExperiment -> ShowS
Prelude.Show, (forall x. CreateExperiment -> Rep CreateExperiment x)
-> (forall x. Rep CreateExperiment x -> CreateExperiment)
-> Generic CreateExperiment
forall x. Rep CreateExperiment x -> CreateExperiment
forall x. CreateExperiment -> Rep CreateExperiment x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CreateExperiment x -> CreateExperiment
$cfrom :: forall x. CreateExperiment -> Rep CreateExperiment x
Prelude.Generic)

-- |
-- Create a value of 'CreateExperiment' 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:
--
-- 'displayName', 'createExperiment_displayName' - The name of the experiment as displayed. The name doesn\'t need to be
-- unique. If you don\'t specify @DisplayName@, the value in
-- @ExperimentName@ is displayed.
--
-- 'description', 'createExperiment_description' - The description of the experiment.
--
-- 'tags', 'createExperiment_tags' - A list of tags to associate with the experiment. You can use Search API
-- to search on the tags.
--
-- 'experimentName', 'createExperiment_experimentName' - The name of the experiment. The name must be unique in your Amazon Web
-- Services account and is not case-sensitive.
newCreateExperiment ::
  -- | 'experimentName'
  Prelude.Text ->
  CreateExperiment
newCreateExperiment :: Text -> CreateExperiment
newCreateExperiment Text
pExperimentName_ =
  CreateExperiment' :: Maybe Text -> Maybe Text -> Maybe [Tag] -> Text -> CreateExperiment
CreateExperiment'
    { $sel:displayName:CreateExperiment' :: Maybe Text
displayName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:description:CreateExperiment' :: Maybe Text
description = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:tags:CreateExperiment' :: Maybe [Tag]
tags = Maybe [Tag]
forall a. Maybe a
Prelude.Nothing,
      $sel:experimentName:CreateExperiment' :: Text
experimentName = Text
pExperimentName_
    }

-- | The name of the experiment as displayed. The name doesn\'t need to be
-- unique. If you don\'t specify @DisplayName@, the value in
-- @ExperimentName@ is displayed.
createExperiment_displayName :: Lens.Lens' CreateExperiment (Prelude.Maybe Prelude.Text)
createExperiment_displayName :: (Maybe Text -> f (Maybe Text))
-> CreateExperiment -> f CreateExperiment
createExperiment_displayName = (CreateExperiment -> Maybe Text)
-> (CreateExperiment -> Maybe Text -> CreateExperiment)
-> Lens CreateExperiment CreateExperiment (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateExperiment' {Maybe Text
displayName :: Maybe Text
$sel:displayName:CreateExperiment' :: CreateExperiment -> Maybe Text
displayName} -> Maybe Text
displayName) (\s :: CreateExperiment
s@CreateExperiment' {} Maybe Text
a -> CreateExperiment
s {$sel:displayName:CreateExperiment' :: Maybe Text
displayName = Maybe Text
a} :: CreateExperiment)

-- | The description of the experiment.
createExperiment_description :: Lens.Lens' CreateExperiment (Prelude.Maybe Prelude.Text)
createExperiment_description :: (Maybe Text -> f (Maybe Text))
-> CreateExperiment -> f CreateExperiment
createExperiment_description = (CreateExperiment -> Maybe Text)
-> (CreateExperiment -> Maybe Text -> CreateExperiment)
-> Lens CreateExperiment CreateExperiment (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateExperiment' {Maybe Text
description :: Maybe Text
$sel:description:CreateExperiment' :: CreateExperiment -> Maybe Text
description} -> Maybe Text
description) (\s :: CreateExperiment
s@CreateExperiment' {} Maybe Text
a -> CreateExperiment
s {$sel:description:CreateExperiment' :: Maybe Text
description = Maybe Text
a} :: CreateExperiment)

-- | A list of tags to associate with the experiment. You can use Search API
-- to search on the tags.
createExperiment_tags :: Lens.Lens' CreateExperiment (Prelude.Maybe [Tag])
createExperiment_tags :: (Maybe [Tag] -> f (Maybe [Tag]))
-> CreateExperiment -> f CreateExperiment
createExperiment_tags = (CreateExperiment -> Maybe [Tag])
-> (CreateExperiment -> Maybe [Tag] -> CreateExperiment)
-> Lens
     CreateExperiment CreateExperiment (Maybe [Tag]) (Maybe [Tag])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateExperiment' {Maybe [Tag]
tags :: Maybe [Tag]
$sel:tags:CreateExperiment' :: CreateExperiment -> Maybe [Tag]
tags} -> Maybe [Tag]
tags) (\s :: CreateExperiment
s@CreateExperiment' {} Maybe [Tag]
a -> CreateExperiment
s {$sel:tags:CreateExperiment' :: Maybe [Tag]
tags = Maybe [Tag]
a} :: CreateExperiment) ((Maybe [Tag] -> f (Maybe [Tag]))
 -> CreateExperiment -> f CreateExperiment)
-> ((Maybe [Tag] -> f (Maybe [Tag]))
    -> Maybe [Tag] -> f (Maybe [Tag]))
-> (Maybe [Tag] -> f (Maybe [Tag]))
-> CreateExperiment
-> f CreateExperiment
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Tag] [Tag] [Tag] [Tag]
-> Iso (Maybe [Tag]) (Maybe [Tag]) (Maybe [Tag]) (Maybe [Tag])
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso [Tag] [Tag] [Tag] [Tag]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The name of the experiment. The name must be unique in your Amazon Web
-- Services account and is not case-sensitive.
createExperiment_experimentName :: Lens.Lens' CreateExperiment Prelude.Text
createExperiment_experimentName :: (Text -> f Text) -> CreateExperiment -> f CreateExperiment
createExperiment_experimentName = (CreateExperiment -> Text)
-> (CreateExperiment -> Text -> CreateExperiment)
-> Lens CreateExperiment CreateExperiment Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateExperiment' {Text
experimentName :: Text
$sel:experimentName:CreateExperiment' :: CreateExperiment -> Text
experimentName} -> Text
experimentName) (\s :: CreateExperiment
s@CreateExperiment' {} Text
a -> CreateExperiment
s {$sel:experimentName:CreateExperiment' :: Text
experimentName = Text
a} :: CreateExperiment)

instance Core.AWSRequest CreateExperiment where
  type
    AWSResponse CreateExperiment =
      CreateExperimentResponse
  request :: CreateExperiment -> Request CreateExperiment
request = Service -> CreateExperiment -> Request CreateExperiment
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy CreateExperiment
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse CreateExperiment)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse CreateExperiment))
-> Logger
-> Service
-> Proxy CreateExperiment
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse CreateExperiment)))
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 -> Int -> CreateExperimentResponse
CreateExperimentResponse'
            (Maybe Text -> Int -> CreateExperimentResponse)
-> Either String (Maybe Text)
-> Either String (Int -> CreateExperimentResponse)
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
"ExperimentArn")
            Either String (Int -> CreateExperimentResponse)
-> Either String Int -> Either String CreateExperimentResponse
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 CreateExperiment

instance Prelude.NFData CreateExperiment

instance Core.ToHeaders CreateExperiment where
  toHeaders :: CreateExperiment -> ResponseHeaders
toHeaders =
    ResponseHeaders -> CreateExperiment -> 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
"SageMaker.CreateExperiment" :: 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 CreateExperiment where
  toJSON :: CreateExperiment -> Value
toJSON CreateExperiment' {Maybe [Tag]
Maybe Text
Text
experimentName :: Text
tags :: Maybe [Tag]
description :: Maybe Text
displayName :: Maybe Text
$sel:experimentName:CreateExperiment' :: CreateExperiment -> Text
$sel:tags:CreateExperiment' :: CreateExperiment -> Maybe [Tag]
$sel:description:CreateExperiment' :: CreateExperiment -> Maybe Text
$sel:displayName:CreateExperiment' :: CreateExperiment -> Maybe Text
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Text
"DisplayName" 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
displayName,
            (Text
"Description" 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
description,
            (Text
"Tags" Text -> [Tag] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) ([Tag] -> Pair) -> Maybe [Tag] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Tag]
tags,
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just
              (Text
"ExperimentName" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
experimentName)
          ]
      )

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

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

-- | /See:/ 'newCreateExperimentResponse' smart constructor.
data CreateExperimentResponse = CreateExperimentResponse'
  { -- | The Amazon Resource Name (ARN) of the experiment.
    CreateExperimentResponse -> Maybe Text
experimentArn :: Prelude.Maybe Prelude.Text,
    -- | The response's http status code.
    CreateExperimentResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (CreateExperimentResponse -> CreateExperimentResponse -> Bool
(CreateExperimentResponse -> CreateExperimentResponse -> Bool)
-> (CreateExperimentResponse -> CreateExperimentResponse -> Bool)
-> Eq CreateExperimentResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateExperimentResponse -> CreateExperimentResponse -> Bool
$c/= :: CreateExperimentResponse -> CreateExperimentResponse -> Bool
== :: CreateExperimentResponse -> CreateExperimentResponse -> Bool
$c== :: CreateExperimentResponse -> CreateExperimentResponse -> Bool
Prelude.Eq, ReadPrec [CreateExperimentResponse]
ReadPrec CreateExperimentResponse
Int -> ReadS CreateExperimentResponse
ReadS [CreateExperimentResponse]
(Int -> ReadS CreateExperimentResponse)
-> ReadS [CreateExperimentResponse]
-> ReadPrec CreateExperimentResponse
-> ReadPrec [CreateExperimentResponse]
-> Read CreateExperimentResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateExperimentResponse]
$creadListPrec :: ReadPrec [CreateExperimentResponse]
readPrec :: ReadPrec CreateExperimentResponse
$creadPrec :: ReadPrec CreateExperimentResponse
readList :: ReadS [CreateExperimentResponse]
$creadList :: ReadS [CreateExperimentResponse]
readsPrec :: Int -> ReadS CreateExperimentResponse
$creadsPrec :: Int -> ReadS CreateExperimentResponse
Prelude.Read, Int -> CreateExperimentResponse -> ShowS
[CreateExperimentResponse] -> ShowS
CreateExperimentResponse -> String
(Int -> CreateExperimentResponse -> ShowS)
-> (CreateExperimentResponse -> String)
-> ([CreateExperimentResponse] -> ShowS)
-> Show CreateExperimentResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateExperimentResponse] -> ShowS
$cshowList :: [CreateExperimentResponse] -> ShowS
show :: CreateExperimentResponse -> String
$cshow :: CreateExperimentResponse -> String
showsPrec :: Int -> CreateExperimentResponse -> ShowS
$cshowsPrec :: Int -> CreateExperimentResponse -> ShowS
Prelude.Show, (forall x.
 CreateExperimentResponse -> Rep CreateExperimentResponse x)
-> (forall x.
    Rep CreateExperimentResponse x -> CreateExperimentResponse)
-> Generic CreateExperimentResponse
forall x.
Rep CreateExperimentResponse x -> CreateExperimentResponse
forall x.
CreateExperimentResponse -> Rep CreateExperimentResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep CreateExperimentResponse x -> CreateExperimentResponse
$cfrom :: forall x.
CreateExperimentResponse -> Rep CreateExperimentResponse x
Prelude.Generic)

-- |
-- Create a value of 'CreateExperimentResponse' 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:
--
-- 'experimentArn', 'createExperimentResponse_experimentArn' - The Amazon Resource Name (ARN) of the experiment.
--
-- 'httpStatus', 'createExperimentResponse_httpStatus' - The response's http status code.
newCreateExperimentResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  CreateExperimentResponse
newCreateExperimentResponse :: Int -> CreateExperimentResponse
newCreateExperimentResponse Int
pHttpStatus_ =
  CreateExperimentResponse' :: Maybe Text -> Int -> CreateExperimentResponse
CreateExperimentResponse'
    { $sel:experimentArn:CreateExperimentResponse' :: Maybe Text
experimentArn =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:CreateExperimentResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | The Amazon Resource Name (ARN) of the experiment.
createExperimentResponse_experimentArn :: Lens.Lens' CreateExperimentResponse (Prelude.Maybe Prelude.Text)
createExperimentResponse_experimentArn :: (Maybe Text -> f (Maybe Text))
-> CreateExperimentResponse -> f CreateExperimentResponse
createExperimentResponse_experimentArn = (CreateExperimentResponse -> Maybe Text)
-> (CreateExperimentResponse
    -> Maybe Text -> CreateExperimentResponse)
-> Lens
     CreateExperimentResponse
     CreateExperimentResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateExperimentResponse' {Maybe Text
experimentArn :: Maybe Text
$sel:experimentArn:CreateExperimentResponse' :: CreateExperimentResponse -> Maybe Text
experimentArn} -> Maybe Text
experimentArn) (\s :: CreateExperimentResponse
s@CreateExperimentResponse' {} Maybe Text
a -> CreateExperimentResponse
s {$sel:experimentArn:CreateExperimentResponse' :: Maybe Text
experimentArn = Maybe Text
a} :: CreateExperimentResponse)

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

instance Prelude.NFData CreateExperimentResponse