{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.SSM.Types.AutomationExecutionMetadata
-- 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)
module Amazonka.SSM.Types.AutomationExecutionMetadata where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.SSM.Types.AutomationExecutionStatus
import Amazonka.SSM.Types.AutomationSubtype
import Amazonka.SSM.Types.AutomationType
import Amazonka.SSM.Types.ExecutionMode
import Amazonka.SSM.Types.ResolvedTargets
import Amazonka.SSM.Types.Runbook
import Amazonka.SSM.Types.Target

-- | Details about a specific Automation execution.
--
-- /See:/ 'newAutomationExecutionMetadata' smart constructor.
data AutomationExecutionMetadata = AutomationExecutionMetadata'
  { -- | The date and time the Automation operation is scheduled to start.
    AutomationExecutionMetadata -> Maybe POSIX
scheduledTime :: Prelude.Maybe Core.POSIX,
    -- | The ID of a State Manager association used in the Automation operation.
    AutomationExecutionMetadata -> Maybe Text
associationId :: Prelude.Maybe Prelude.Text,
    -- | The ID of an OpsItem that is created to represent a Change Manager
    -- change request.
    AutomationExecutionMetadata -> Maybe Text
opsItemId :: Prelude.Maybe Prelude.Text,
    -- | The name of the step that is currently running.
    AutomationExecutionMetadata -> Maybe Text
currentStepName :: Prelude.Maybe Prelude.Text,
    -- | The list of execution outputs as defined in the Automation runbook.
    AutomationExecutionMetadata -> Maybe Text
targetParameterName :: Prelude.Maybe Prelude.Text,
    -- | An S3 bucket where execution information is stored.
    AutomationExecutionMetadata -> Maybe Text
logFile :: Prelude.Maybe Prelude.Text,
    -- | The IAM role ARN of the user who ran the automation.
    AutomationExecutionMetadata -> Maybe Text
executedBy :: Prelude.Maybe Prelude.Text,
    -- | The name of the Automation runbook used during execution.
    AutomationExecutionMetadata -> Maybe Text
documentName :: Prelude.Maybe Prelude.Text,
    -- | The time the execution finished. This isn\'t populated if the execution
    -- is still in progress.
    AutomationExecutionMetadata -> Maybe POSIX
executionEndTime :: Prelude.Maybe Core.POSIX,
    -- | The list of execution outputs as defined in the Automation runbook.
    AutomationExecutionMetadata -> Maybe Text
failureMessage :: Prelude.Maybe Prelude.Text,
    -- | The subtype of the Automation operation. Currently, the only supported
    -- value is @ChangeRequest@.
    AutomationExecutionMetadata -> Maybe AutomationSubtype
automationSubtype :: Prelude.Maybe AutomationSubtype,
    -- | The Automation execution mode.
    AutomationExecutionMetadata -> Maybe ExecutionMode
mode :: Prelude.Maybe ExecutionMode,
    -- | The specified key-value mapping of document parameters to target
    -- resources.
    AutomationExecutionMetadata -> Maybe [HashMap Text [Text]]
targetMaps :: Prelude.Maybe [Prelude.HashMap Prelude.Text [Prelude.Text]],
    -- | The status of the execution.
    AutomationExecutionMetadata -> Maybe AutomationExecutionStatus
automationExecutionStatus :: Prelude.Maybe AutomationExecutionStatus,
    -- | The execution ID of the parent automation.
    AutomationExecutionMetadata -> Maybe Text
parentAutomationExecutionId :: Prelude.Maybe Prelude.Text,
    -- | The list of execution outputs as defined in the Automation runbook.
    AutomationExecutionMetadata -> Maybe (HashMap Text [Text])
outputs :: Prelude.Maybe (Prelude.HashMap Prelude.Text [Prelude.Text]),
    -- | The @MaxErrors@ value specified by the user when starting the
    -- automation.
    AutomationExecutionMetadata -> Maybe Text
maxErrors :: Prelude.Maybe Prelude.Text,
    -- | The time the execution started.
    AutomationExecutionMetadata -> Maybe POSIX
executionStartTime :: Prelude.Maybe Core.POSIX,
    -- | Use this filter with DescribeAutomationExecutions. Specify either Local
    -- or CrossAccount. CrossAccount is an Automation that runs in multiple
    -- Amazon Web Services Regions and Amazon Web Services accounts. For more
    -- information, see
    -- <https://docs.aws.amazon.com/systems-manager/latest/userguide/systems-manager-automation-multiple-accounts-and-regions.html Running Automation workflows in multiple Amazon Web Services Regions and accounts>
    -- in the /Amazon Web Services Systems Manager User Guide/.
    AutomationExecutionMetadata -> Maybe AutomationType
automationType :: Prelude.Maybe AutomationType,
    -- | The action of the step that is currently running.
    AutomationExecutionMetadata -> Maybe Text
currentAction :: Prelude.Maybe Prelude.Text,
    -- | The targets defined by the user when starting the automation.
    AutomationExecutionMetadata -> Maybe [Target]
targets :: Prelude.Maybe [Target],
    -- | A list of targets that resolved during the execution.
    AutomationExecutionMetadata -> Maybe ResolvedTargets
resolvedTargets :: Prelude.Maybe ResolvedTargets,
    -- | The document version used during the execution.
    AutomationExecutionMetadata -> Maybe Text
documentVersion :: Prelude.Maybe Prelude.Text,
    -- | The execution ID.
    AutomationExecutionMetadata -> Maybe Text
automationExecutionId :: Prelude.Maybe Prelude.Text,
    -- | The name of the Change Manager change request.
    AutomationExecutionMetadata -> Maybe Text
changeRequestName :: Prelude.Maybe Prelude.Text,
    -- | Information about the Automation runbooks that are run during a runbook
    -- workflow in Change Manager.
    --
    -- The Automation runbooks specified for the runbook workflow can\'t run
    -- until all required approvals for the change request have been received.
    AutomationExecutionMetadata -> Maybe (NonEmpty Runbook)
runbooks :: Prelude.Maybe (Prelude.NonEmpty Runbook),
    -- | The @MaxConcurrency@ value specified by the user when starting the
    -- automation.
    AutomationExecutionMetadata -> Maybe Text
maxConcurrency :: Prelude.Maybe Prelude.Text,
    -- | The list of execution outputs as defined in the Automation runbook.
    AutomationExecutionMetadata -> Maybe Text
target :: Prelude.Maybe Prelude.Text
  }
  deriving (AutomationExecutionMetadata -> AutomationExecutionMetadata -> Bool
(AutomationExecutionMetadata
 -> AutomationExecutionMetadata -> Bool)
-> (AutomationExecutionMetadata
    -> AutomationExecutionMetadata -> Bool)
-> Eq AutomationExecutionMetadata
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: AutomationExecutionMetadata -> AutomationExecutionMetadata -> Bool
$c/= :: AutomationExecutionMetadata -> AutomationExecutionMetadata -> Bool
== :: AutomationExecutionMetadata -> AutomationExecutionMetadata -> Bool
$c== :: AutomationExecutionMetadata -> AutomationExecutionMetadata -> Bool
Prelude.Eq, ReadPrec [AutomationExecutionMetadata]
ReadPrec AutomationExecutionMetadata
Int -> ReadS AutomationExecutionMetadata
ReadS [AutomationExecutionMetadata]
(Int -> ReadS AutomationExecutionMetadata)
-> ReadS [AutomationExecutionMetadata]
-> ReadPrec AutomationExecutionMetadata
-> ReadPrec [AutomationExecutionMetadata]
-> Read AutomationExecutionMetadata
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [AutomationExecutionMetadata]
$creadListPrec :: ReadPrec [AutomationExecutionMetadata]
readPrec :: ReadPrec AutomationExecutionMetadata
$creadPrec :: ReadPrec AutomationExecutionMetadata
readList :: ReadS [AutomationExecutionMetadata]
$creadList :: ReadS [AutomationExecutionMetadata]
readsPrec :: Int -> ReadS AutomationExecutionMetadata
$creadsPrec :: Int -> ReadS AutomationExecutionMetadata
Prelude.Read, Int -> AutomationExecutionMetadata -> ShowS
[AutomationExecutionMetadata] -> ShowS
AutomationExecutionMetadata -> String
(Int -> AutomationExecutionMetadata -> ShowS)
-> (AutomationExecutionMetadata -> String)
-> ([AutomationExecutionMetadata] -> ShowS)
-> Show AutomationExecutionMetadata
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [AutomationExecutionMetadata] -> ShowS
$cshowList :: [AutomationExecutionMetadata] -> ShowS
show :: AutomationExecutionMetadata -> String
$cshow :: AutomationExecutionMetadata -> String
showsPrec :: Int -> AutomationExecutionMetadata -> ShowS
$cshowsPrec :: Int -> AutomationExecutionMetadata -> ShowS
Prelude.Show, (forall x.
 AutomationExecutionMetadata -> Rep AutomationExecutionMetadata x)
-> (forall x.
    Rep AutomationExecutionMetadata x -> AutomationExecutionMetadata)
-> Generic AutomationExecutionMetadata
forall x.
Rep AutomationExecutionMetadata x -> AutomationExecutionMetadata
forall x.
AutomationExecutionMetadata -> Rep AutomationExecutionMetadata x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep AutomationExecutionMetadata x -> AutomationExecutionMetadata
$cfrom :: forall x.
AutomationExecutionMetadata -> Rep AutomationExecutionMetadata x
Prelude.Generic)

-- |
-- Create a value of 'AutomationExecutionMetadata' 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:
--
-- 'scheduledTime', 'automationExecutionMetadata_scheduledTime' - The date and time the Automation operation is scheduled to start.
--
-- 'associationId', 'automationExecutionMetadata_associationId' - The ID of a State Manager association used in the Automation operation.
--
-- 'opsItemId', 'automationExecutionMetadata_opsItemId' - The ID of an OpsItem that is created to represent a Change Manager
-- change request.
--
-- 'currentStepName', 'automationExecutionMetadata_currentStepName' - The name of the step that is currently running.
--
-- 'targetParameterName', 'automationExecutionMetadata_targetParameterName' - The list of execution outputs as defined in the Automation runbook.
--
-- 'logFile', 'automationExecutionMetadata_logFile' - An S3 bucket where execution information is stored.
--
-- 'executedBy', 'automationExecutionMetadata_executedBy' - The IAM role ARN of the user who ran the automation.
--
-- 'documentName', 'automationExecutionMetadata_documentName' - The name of the Automation runbook used during execution.
--
-- 'executionEndTime', 'automationExecutionMetadata_executionEndTime' - The time the execution finished. This isn\'t populated if the execution
-- is still in progress.
--
-- 'failureMessage', 'automationExecutionMetadata_failureMessage' - The list of execution outputs as defined in the Automation runbook.
--
-- 'automationSubtype', 'automationExecutionMetadata_automationSubtype' - The subtype of the Automation operation. Currently, the only supported
-- value is @ChangeRequest@.
--
-- 'mode', 'automationExecutionMetadata_mode' - The Automation execution mode.
--
-- 'targetMaps', 'automationExecutionMetadata_targetMaps' - The specified key-value mapping of document parameters to target
-- resources.
--
-- 'automationExecutionStatus', 'automationExecutionMetadata_automationExecutionStatus' - The status of the execution.
--
-- 'parentAutomationExecutionId', 'automationExecutionMetadata_parentAutomationExecutionId' - The execution ID of the parent automation.
--
-- 'outputs', 'automationExecutionMetadata_outputs' - The list of execution outputs as defined in the Automation runbook.
--
-- 'maxErrors', 'automationExecutionMetadata_maxErrors' - The @MaxErrors@ value specified by the user when starting the
-- automation.
--
-- 'executionStartTime', 'automationExecutionMetadata_executionStartTime' - The time the execution started.
--
-- 'automationType', 'automationExecutionMetadata_automationType' - Use this filter with DescribeAutomationExecutions. Specify either Local
-- or CrossAccount. CrossAccount is an Automation that runs in multiple
-- Amazon Web Services Regions and Amazon Web Services accounts. For more
-- information, see
-- <https://docs.aws.amazon.com/systems-manager/latest/userguide/systems-manager-automation-multiple-accounts-and-regions.html Running Automation workflows in multiple Amazon Web Services Regions and accounts>
-- in the /Amazon Web Services Systems Manager User Guide/.
--
-- 'currentAction', 'automationExecutionMetadata_currentAction' - The action of the step that is currently running.
--
-- 'targets', 'automationExecutionMetadata_targets' - The targets defined by the user when starting the automation.
--
-- 'resolvedTargets', 'automationExecutionMetadata_resolvedTargets' - A list of targets that resolved during the execution.
--
-- 'documentVersion', 'automationExecutionMetadata_documentVersion' - The document version used during the execution.
--
-- 'automationExecutionId', 'automationExecutionMetadata_automationExecutionId' - The execution ID.
--
-- 'changeRequestName', 'automationExecutionMetadata_changeRequestName' - The name of the Change Manager change request.
--
-- 'runbooks', 'automationExecutionMetadata_runbooks' - Information about the Automation runbooks that are run during a runbook
-- workflow in Change Manager.
--
-- The Automation runbooks specified for the runbook workflow can\'t run
-- until all required approvals for the change request have been received.
--
-- 'maxConcurrency', 'automationExecutionMetadata_maxConcurrency' - The @MaxConcurrency@ value specified by the user when starting the
-- automation.
--
-- 'target', 'automationExecutionMetadata_target' - The list of execution outputs as defined in the Automation runbook.
newAutomationExecutionMetadata ::
  AutomationExecutionMetadata
newAutomationExecutionMetadata :: AutomationExecutionMetadata
newAutomationExecutionMetadata =
  AutomationExecutionMetadata' :: Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe AutomationSubtype
-> Maybe ExecutionMode
-> Maybe [HashMap Text [Text]]
-> Maybe AutomationExecutionStatus
-> Maybe Text
-> Maybe (HashMap Text [Text])
-> Maybe Text
-> Maybe POSIX
-> Maybe AutomationType
-> Maybe Text
-> Maybe [Target]
-> Maybe ResolvedTargets
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe (NonEmpty Runbook)
-> Maybe Text
-> Maybe Text
-> AutomationExecutionMetadata
AutomationExecutionMetadata'
    { $sel:scheduledTime:AutomationExecutionMetadata' :: Maybe POSIX
scheduledTime =
        Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
      $sel:associationId:AutomationExecutionMetadata' :: Maybe Text
associationId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:opsItemId:AutomationExecutionMetadata' :: Maybe Text
opsItemId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:currentStepName:AutomationExecutionMetadata' :: Maybe Text
currentStepName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:targetParameterName:AutomationExecutionMetadata' :: Maybe Text
targetParameterName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:logFile:AutomationExecutionMetadata' :: Maybe Text
logFile = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:executedBy:AutomationExecutionMetadata' :: Maybe Text
executedBy = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:documentName:AutomationExecutionMetadata' :: Maybe Text
documentName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:executionEndTime:AutomationExecutionMetadata' :: Maybe POSIX
executionEndTime = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
      $sel:failureMessage:AutomationExecutionMetadata' :: Maybe Text
failureMessage = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:automationSubtype:AutomationExecutionMetadata' :: Maybe AutomationSubtype
automationSubtype = Maybe AutomationSubtype
forall a. Maybe a
Prelude.Nothing,
      $sel:mode:AutomationExecutionMetadata' :: Maybe ExecutionMode
mode = Maybe ExecutionMode
forall a. Maybe a
Prelude.Nothing,
      $sel:targetMaps:AutomationExecutionMetadata' :: Maybe [HashMap Text [Text]]
targetMaps = Maybe [HashMap Text [Text]]
forall a. Maybe a
Prelude.Nothing,
      $sel:automationExecutionStatus:AutomationExecutionMetadata' :: Maybe AutomationExecutionStatus
automationExecutionStatus = Maybe AutomationExecutionStatus
forall a. Maybe a
Prelude.Nothing,
      $sel:parentAutomationExecutionId:AutomationExecutionMetadata' :: Maybe Text
parentAutomationExecutionId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:outputs:AutomationExecutionMetadata' :: Maybe (HashMap Text [Text])
outputs = Maybe (HashMap Text [Text])
forall a. Maybe a
Prelude.Nothing,
      $sel:maxErrors:AutomationExecutionMetadata' :: Maybe Text
maxErrors = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:executionStartTime:AutomationExecutionMetadata' :: Maybe POSIX
executionStartTime = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
      $sel:automationType:AutomationExecutionMetadata' :: Maybe AutomationType
automationType = Maybe AutomationType
forall a. Maybe a
Prelude.Nothing,
      $sel:currentAction:AutomationExecutionMetadata' :: Maybe Text
currentAction = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:targets:AutomationExecutionMetadata' :: Maybe [Target]
targets = Maybe [Target]
forall a. Maybe a
Prelude.Nothing,
      $sel:resolvedTargets:AutomationExecutionMetadata' :: Maybe ResolvedTargets
resolvedTargets = Maybe ResolvedTargets
forall a. Maybe a
Prelude.Nothing,
      $sel:documentVersion:AutomationExecutionMetadata' :: Maybe Text
documentVersion = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:automationExecutionId:AutomationExecutionMetadata' :: Maybe Text
automationExecutionId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:changeRequestName:AutomationExecutionMetadata' :: Maybe Text
changeRequestName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:runbooks:AutomationExecutionMetadata' :: Maybe (NonEmpty Runbook)
runbooks = Maybe (NonEmpty Runbook)
forall a. Maybe a
Prelude.Nothing,
      $sel:maxConcurrency:AutomationExecutionMetadata' :: Maybe Text
maxConcurrency = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:target:AutomationExecutionMetadata' :: Maybe Text
target = Maybe Text
forall a. Maybe a
Prelude.Nothing
    }

-- | The date and time the Automation operation is scheduled to start.
automationExecutionMetadata_scheduledTime :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe Prelude.UTCTime)
automationExecutionMetadata_scheduledTime :: (Maybe UTCTime -> f (Maybe UTCTime))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_scheduledTime = (AutomationExecutionMetadata -> Maybe POSIX)
-> (AutomationExecutionMetadata
    -> Maybe POSIX -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe POSIX)
     (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe POSIX
scheduledTime :: Maybe POSIX
$sel:scheduledTime:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe POSIX
scheduledTime} -> Maybe POSIX
scheduledTime) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe POSIX
a -> AutomationExecutionMetadata
s {$sel:scheduledTime:AutomationExecutionMetadata' :: Maybe POSIX
scheduledTime = Maybe POSIX
a} :: AutomationExecutionMetadata) ((Maybe POSIX -> f (Maybe POSIX))
 -> AutomationExecutionMetadata -> f AutomationExecutionMetadata)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> AutomationExecutionMetadata
-> f AutomationExecutionMetadata
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 ID of a State Manager association used in the Automation operation.
automationExecutionMetadata_associationId :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe Prelude.Text)
automationExecutionMetadata_associationId :: (Maybe Text -> f (Maybe Text))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_associationId = (AutomationExecutionMetadata -> Maybe Text)
-> (AutomationExecutionMetadata
    -> Maybe Text -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe Text
associationId :: Maybe Text
$sel:associationId:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe Text
associationId} -> Maybe Text
associationId) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe Text
a -> AutomationExecutionMetadata
s {$sel:associationId:AutomationExecutionMetadata' :: Maybe Text
associationId = Maybe Text
a} :: AutomationExecutionMetadata)

-- | The ID of an OpsItem that is created to represent a Change Manager
-- change request.
automationExecutionMetadata_opsItemId :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe Prelude.Text)
automationExecutionMetadata_opsItemId :: (Maybe Text -> f (Maybe Text))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_opsItemId = (AutomationExecutionMetadata -> Maybe Text)
-> (AutomationExecutionMetadata
    -> Maybe Text -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe Text
opsItemId :: Maybe Text
$sel:opsItemId:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe Text
opsItemId} -> Maybe Text
opsItemId) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe Text
a -> AutomationExecutionMetadata
s {$sel:opsItemId:AutomationExecutionMetadata' :: Maybe Text
opsItemId = Maybe Text
a} :: AutomationExecutionMetadata)

-- | The name of the step that is currently running.
automationExecutionMetadata_currentStepName :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe Prelude.Text)
automationExecutionMetadata_currentStepName :: (Maybe Text -> f (Maybe Text))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_currentStepName = (AutomationExecutionMetadata -> Maybe Text)
-> (AutomationExecutionMetadata
    -> Maybe Text -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe Text
currentStepName :: Maybe Text
$sel:currentStepName:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe Text
currentStepName} -> Maybe Text
currentStepName) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe Text
a -> AutomationExecutionMetadata
s {$sel:currentStepName:AutomationExecutionMetadata' :: Maybe Text
currentStepName = Maybe Text
a} :: AutomationExecutionMetadata)

-- | The list of execution outputs as defined in the Automation runbook.
automationExecutionMetadata_targetParameterName :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe Prelude.Text)
automationExecutionMetadata_targetParameterName :: (Maybe Text -> f (Maybe Text))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_targetParameterName = (AutomationExecutionMetadata -> Maybe Text)
-> (AutomationExecutionMetadata
    -> Maybe Text -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe Text
targetParameterName :: Maybe Text
$sel:targetParameterName:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe Text
targetParameterName} -> Maybe Text
targetParameterName) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe Text
a -> AutomationExecutionMetadata
s {$sel:targetParameterName:AutomationExecutionMetadata' :: Maybe Text
targetParameterName = Maybe Text
a} :: AutomationExecutionMetadata)

-- | An S3 bucket where execution information is stored.
automationExecutionMetadata_logFile :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe Prelude.Text)
automationExecutionMetadata_logFile :: (Maybe Text -> f (Maybe Text))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_logFile = (AutomationExecutionMetadata -> Maybe Text)
-> (AutomationExecutionMetadata
    -> Maybe Text -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe Text
logFile :: Maybe Text
$sel:logFile:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe Text
logFile} -> Maybe Text
logFile) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe Text
a -> AutomationExecutionMetadata
s {$sel:logFile:AutomationExecutionMetadata' :: Maybe Text
logFile = Maybe Text
a} :: AutomationExecutionMetadata)

-- | The IAM role ARN of the user who ran the automation.
automationExecutionMetadata_executedBy :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe Prelude.Text)
automationExecutionMetadata_executedBy :: (Maybe Text -> f (Maybe Text))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_executedBy = (AutomationExecutionMetadata -> Maybe Text)
-> (AutomationExecutionMetadata
    -> Maybe Text -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe Text
executedBy :: Maybe Text
$sel:executedBy:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe Text
executedBy} -> Maybe Text
executedBy) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe Text
a -> AutomationExecutionMetadata
s {$sel:executedBy:AutomationExecutionMetadata' :: Maybe Text
executedBy = Maybe Text
a} :: AutomationExecutionMetadata)

-- | The name of the Automation runbook used during execution.
automationExecutionMetadata_documentName :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe Prelude.Text)
automationExecutionMetadata_documentName :: (Maybe Text -> f (Maybe Text))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_documentName = (AutomationExecutionMetadata -> Maybe Text)
-> (AutomationExecutionMetadata
    -> Maybe Text -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe Text
documentName :: Maybe Text
$sel:documentName:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe Text
documentName} -> Maybe Text
documentName) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe Text
a -> AutomationExecutionMetadata
s {$sel:documentName:AutomationExecutionMetadata' :: Maybe Text
documentName = Maybe Text
a} :: AutomationExecutionMetadata)

-- | The time the execution finished. This isn\'t populated if the execution
-- is still in progress.
automationExecutionMetadata_executionEndTime :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe Prelude.UTCTime)
automationExecutionMetadata_executionEndTime :: (Maybe UTCTime -> f (Maybe UTCTime))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_executionEndTime = (AutomationExecutionMetadata -> Maybe POSIX)
-> (AutomationExecutionMetadata
    -> Maybe POSIX -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe POSIX)
     (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe POSIX
executionEndTime :: Maybe POSIX
$sel:executionEndTime:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe POSIX
executionEndTime} -> Maybe POSIX
executionEndTime) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe POSIX
a -> AutomationExecutionMetadata
s {$sel:executionEndTime:AutomationExecutionMetadata' :: Maybe POSIX
executionEndTime = Maybe POSIX
a} :: AutomationExecutionMetadata) ((Maybe POSIX -> f (Maybe POSIX))
 -> AutomationExecutionMetadata -> f AutomationExecutionMetadata)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> AutomationExecutionMetadata
-> f AutomationExecutionMetadata
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 list of execution outputs as defined in the Automation runbook.
automationExecutionMetadata_failureMessage :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe Prelude.Text)
automationExecutionMetadata_failureMessage :: (Maybe Text -> f (Maybe Text))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_failureMessage = (AutomationExecutionMetadata -> Maybe Text)
-> (AutomationExecutionMetadata
    -> Maybe Text -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe Text
failureMessage :: Maybe Text
$sel:failureMessage:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe Text
failureMessage} -> Maybe Text
failureMessage) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe Text
a -> AutomationExecutionMetadata
s {$sel:failureMessage:AutomationExecutionMetadata' :: Maybe Text
failureMessage = Maybe Text
a} :: AutomationExecutionMetadata)

-- | The subtype of the Automation operation. Currently, the only supported
-- value is @ChangeRequest@.
automationExecutionMetadata_automationSubtype :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe AutomationSubtype)
automationExecutionMetadata_automationSubtype :: (Maybe AutomationSubtype -> f (Maybe AutomationSubtype))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_automationSubtype = (AutomationExecutionMetadata -> Maybe AutomationSubtype)
-> (AutomationExecutionMetadata
    -> Maybe AutomationSubtype -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe AutomationSubtype)
     (Maybe AutomationSubtype)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe AutomationSubtype
automationSubtype :: Maybe AutomationSubtype
$sel:automationSubtype:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe AutomationSubtype
automationSubtype} -> Maybe AutomationSubtype
automationSubtype) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe AutomationSubtype
a -> AutomationExecutionMetadata
s {$sel:automationSubtype:AutomationExecutionMetadata' :: Maybe AutomationSubtype
automationSubtype = Maybe AutomationSubtype
a} :: AutomationExecutionMetadata)

-- | The Automation execution mode.
automationExecutionMetadata_mode :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe ExecutionMode)
automationExecutionMetadata_mode :: (Maybe ExecutionMode -> f (Maybe ExecutionMode))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_mode = (AutomationExecutionMetadata -> Maybe ExecutionMode)
-> (AutomationExecutionMetadata
    -> Maybe ExecutionMode -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe ExecutionMode)
     (Maybe ExecutionMode)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe ExecutionMode
mode :: Maybe ExecutionMode
$sel:mode:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe ExecutionMode
mode} -> Maybe ExecutionMode
mode) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe ExecutionMode
a -> AutomationExecutionMetadata
s {$sel:mode:AutomationExecutionMetadata' :: Maybe ExecutionMode
mode = Maybe ExecutionMode
a} :: AutomationExecutionMetadata)

-- | The specified key-value mapping of document parameters to target
-- resources.
automationExecutionMetadata_targetMaps :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe [Prelude.HashMap Prelude.Text [Prelude.Text]])
automationExecutionMetadata_targetMaps :: (Maybe [HashMap Text [Text]] -> f (Maybe [HashMap Text [Text]]))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_targetMaps = (AutomationExecutionMetadata -> Maybe [HashMap Text [Text]])
-> (AutomationExecutionMetadata
    -> Maybe [HashMap Text [Text]] -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe [HashMap Text [Text]])
     (Maybe [HashMap Text [Text]])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe [HashMap Text [Text]]
targetMaps :: Maybe [HashMap Text [Text]]
$sel:targetMaps:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe [HashMap Text [Text]]
targetMaps} -> Maybe [HashMap Text [Text]]
targetMaps) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe [HashMap Text [Text]]
a -> AutomationExecutionMetadata
s {$sel:targetMaps:AutomationExecutionMetadata' :: Maybe [HashMap Text [Text]]
targetMaps = Maybe [HashMap Text [Text]]
a} :: AutomationExecutionMetadata) ((Maybe [HashMap Text [Text]] -> f (Maybe [HashMap Text [Text]]))
 -> AutomationExecutionMetadata -> f AutomationExecutionMetadata)
-> ((Maybe [HashMap Text [Text]]
     -> f (Maybe [HashMap Text [Text]]))
    -> Maybe [HashMap Text [Text]] -> f (Maybe [HashMap Text [Text]]))
-> (Maybe [HashMap Text [Text]] -> f (Maybe [HashMap Text [Text]]))
-> AutomationExecutionMetadata
-> f AutomationExecutionMetadata
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [HashMap Text [Text]]
  [HashMap Text [Text]]
  [HashMap Text [Text]]
  [HashMap Text [Text]]
-> Iso
     (Maybe [HashMap Text [Text]])
     (Maybe [HashMap Text [Text]])
     (Maybe [HashMap Text [Text]])
     (Maybe [HashMap Text [Text]])
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
  [HashMap Text [Text]]
  [HashMap Text [Text]]
  [HashMap Text [Text]]
  [HashMap Text [Text]]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The status of the execution.
automationExecutionMetadata_automationExecutionStatus :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe AutomationExecutionStatus)
automationExecutionMetadata_automationExecutionStatus :: (Maybe AutomationExecutionStatus
 -> f (Maybe AutomationExecutionStatus))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_automationExecutionStatus = (AutomationExecutionMetadata -> Maybe AutomationExecutionStatus)
-> (AutomationExecutionMetadata
    -> Maybe AutomationExecutionStatus -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe AutomationExecutionStatus)
     (Maybe AutomationExecutionStatus)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe AutomationExecutionStatus
automationExecutionStatus :: Maybe AutomationExecutionStatus
$sel:automationExecutionStatus:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe AutomationExecutionStatus
automationExecutionStatus} -> Maybe AutomationExecutionStatus
automationExecutionStatus) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe AutomationExecutionStatus
a -> AutomationExecutionMetadata
s {$sel:automationExecutionStatus:AutomationExecutionMetadata' :: Maybe AutomationExecutionStatus
automationExecutionStatus = Maybe AutomationExecutionStatus
a} :: AutomationExecutionMetadata)

-- | The execution ID of the parent automation.
automationExecutionMetadata_parentAutomationExecutionId :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe Prelude.Text)
automationExecutionMetadata_parentAutomationExecutionId :: (Maybe Text -> f (Maybe Text))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_parentAutomationExecutionId = (AutomationExecutionMetadata -> Maybe Text)
-> (AutomationExecutionMetadata
    -> Maybe Text -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe Text
parentAutomationExecutionId :: Maybe Text
$sel:parentAutomationExecutionId:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe Text
parentAutomationExecutionId} -> Maybe Text
parentAutomationExecutionId) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe Text
a -> AutomationExecutionMetadata
s {$sel:parentAutomationExecutionId:AutomationExecutionMetadata' :: Maybe Text
parentAutomationExecutionId = Maybe Text
a} :: AutomationExecutionMetadata)

-- | The list of execution outputs as defined in the Automation runbook.
automationExecutionMetadata_outputs :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe (Prelude.HashMap Prelude.Text [Prelude.Text]))
automationExecutionMetadata_outputs :: (Maybe (HashMap Text [Text]) -> f (Maybe (HashMap Text [Text])))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_outputs = (AutomationExecutionMetadata -> Maybe (HashMap Text [Text]))
-> (AutomationExecutionMetadata
    -> Maybe (HashMap Text [Text]) -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe (HashMap Text [Text]))
     (Maybe (HashMap Text [Text]))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe (HashMap Text [Text])
outputs :: Maybe (HashMap Text [Text])
$sel:outputs:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe (HashMap Text [Text])
outputs} -> Maybe (HashMap Text [Text])
outputs) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe (HashMap Text [Text])
a -> AutomationExecutionMetadata
s {$sel:outputs:AutomationExecutionMetadata' :: Maybe (HashMap Text [Text])
outputs = Maybe (HashMap Text [Text])
a} :: AutomationExecutionMetadata) ((Maybe (HashMap Text [Text]) -> f (Maybe (HashMap Text [Text])))
 -> AutomationExecutionMetadata -> f AutomationExecutionMetadata)
-> ((Maybe (HashMap Text [Text])
     -> f (Maybe (HashMap Text [Text])))
    -> Maybe (HashMap Text [Text]) -> f (Maybe (HashMap Text [Text])))
-> (Maybe (HashMap Text [Text]) -> f (Maybe (HashMap Text [Text])))
-> AutomationExecutionMetadata
-> f AutomationExecutionMetadata
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  (HashMap Text [Text])
  (HashMap Text [Text])
  (HashMap Text [Text])
  (HashMap Text [Text])
-> Iso
     (Maybe (HashMap Text [Text]))
     (Maybe (HashMap Text [Text]))
     (Maybe (HashMap Text [Text]))
     (Maybe (HashMap Text [Text]))
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
  (HashMap Text [Text])
  (HashMap Text [Text])
  (HashMap Text [Text])
  (HashMap Text [Text])
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The @MaxErrors@ value specified by the user when starting the
-- automation.
automationExecutionMetadata_maxErrors :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe Prelude.Text)
automationExecutionMetadata_maxErrors :: (Maybe Text -> f (Maybe Text))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_maxErrors = (AutomationExecutionMetadata -> Maybe Text)
-> (AutomationExecutionMetadata
    -> Maybe Text -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe Text
maxErrors :: Maybe Text
$sel:maxErrors:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe Text
maxErrors} -> Maybe Text
maxErrors) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe Text
a -> AutomationExecutionMetadata
s {$sel:maxErrors:AutomationExecutionMetadata' :: Maybe Text
maxErrors = Maybe Text
a} :: AutomationExecutionMetadata)

-- | The time the execution started.
automationExecutionMetadata_executionStartTime :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe Prelude.UTCTime)
automationExecutionMetadata_executionStartTime :: (Maybe UTCTime -> f (Maybe UTCTime))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_executionStartTime = (AutomationExecutionMetadata -> Maybe POSIX)
-> (AutomationExecutionMetadata
    -> Maybe POSIX -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe POSIX)
     (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe POSIX
executionStartTime :: Maybe POSIX
$sel:executionStartTime:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe POSIX
executionStartTime} -> Maybe POSIX
executionStartTime) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe POSIX
a -> AutomationExecutionMetadata
s {$sel:executionStartTime:AutomationExecutionMetadata' :: Maybe POSIX
executionStartTime = Maybe POSIX
a} :: AutomationExecutionMetadata) ((Maybe POSIX -> f (Maybe POSIX))
 -> AutomationExecutionMetadata -> f AutomationExecutionMetadata)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> AutomationExecutionMetadata
-> f AutomationExecutionMetadata
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

-- | Use this filter with DescribeAutomationExecutions. Specify either Local
-- or CrossAccount. CrossAccount is an Automation that runs in multiple
-- Amazon Web Services Regions and Amazon Web Services accounts. For more
-- information, see
-- <https://docs.aws.amazon.com/systems-manager/latest/userguide/systems-manager-automation-multiple-accounts-and-regions.html Running Automation workflows in multiple Amazon Web Services Regions and accounts>
-- in the /Amazon Web Services Systems Manager User Guide/.
automationExecutionMetadata_automationType :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe AutomationType)
automationExecutionMetadata_automationType :: (Maybe AutomationType -> f (Maybe AutomationType))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_automationType = (AutomationExecutionMetadata -> Maybe AutomationType)
-> (AutomationExecutionMetadata
    -> Maybe AutomationType -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe AutomationType)
     (Maybe AutomationType)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe AutomationType
automationType :: Maybe AutomationType
$sel:automationType:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe AutomationType
automationType} -> Maybe AutomationType
automationType) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe AutomationType
a -> AutomationExecutionMetadata
s {$sel:automationType:AutomationExecutionMetadata' :: Maybe AutomationType
automationType = Maybe AutomationType
a} :: AutomationExecutionMetadata)

-- | The action of the step that is currently running.
automationExecutionMetadata_currentAction :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe Prelude.Text)
automationExecutionMetadata_currentAction :: (Maybe Text -> f (Maybe Text))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_currentAction = (AutomationExecutionMetadata -> Maybe Text)
-> (AutomationExecutionMetadata
    -> Maybe Text -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe Text
currentAction :: Maybe Text
$sel:currentAction:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe Text
currentAction} -> Maybe Text
currentAction) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe Text
a -> AutomationExecutionMetadata
s {$sel:currentAction:AutomationExecutionMetadata' :: Maybe Text
currentAction = Maybe Text
a} :: AutomationExecutionMetadata)

-- | The targets defined by the user when starting the automation.
automationExecutionMetadata_targets :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe [Target])
automationExecutionMetadata_targets :: (Maybe [Target] -> f (Maybe [Target]))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_targets = (AutomationExecutionMetadata -> Maybe [Target])
-> (AutomationExecutionMetadata
    -> Maybe [Target] -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe [Target])
     (Maybe [Target])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe [Target]
targets :: Maybe [Target]
$sel:targets:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe [Target]
targets} -> Maybe [Target]
targets) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe [Target]
a -> AutomationExecutionMetadata
s {$sel:targets:AutomationExecutionMetadata' :: Maybe [Target]
targets = Maybe [Target]
a} :: AutomationExecutionMetadata) ((Maybe [Target] -> f (Maybe [Target]))
 -> AutomationExecutionMetadata -> f AutomationExecutionMetadata)
-> ((Maybe [Target] -> f (Maybe [Target]))
    -> Maybe [Target] -> f (Maybe [Target]))
-> (Maybe [Target] -> f (Maybe [Target]))
-> AutomationExecutionMetadata
-> f AutomationExecutionMetadata
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Target] [Target] [Target] [Target]
-> Iso
     (Maybe [Target]) (Maybe [Target]) (Maybe [Target]) (Maybe [Target])
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 [Target] [Target] [Target] [Target]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A list of targets that resolved during the execution.
automationExecutionMetadata_resolvedTargets :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe ResolvedTargets)
automationExecutionMetadata_resolvedTargets :: (Maybe ResolvedTargets -> f (Maybe ResolvedTargets))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_resolvedTargets = (AutomationExecutionMetadata -> Maybe ResolvedTargets)
-> (AutomationExecutionMetadata
    -> Maybe ResolvedTargets -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe ResolvedTargets)
     (Maybe ResolvedTargets)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe ResolvedTargets
resolvedTargets :: Maybe ResolvedTargets
$sel:resolvedTargets:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe ResolvedTargets
resolvedTargets} -> Maybe ResolvedTargets
resolvedTargets) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe ResolvedTargets
a -> AutomationExecutionMetadata
s {$sel:resolvedTargets:AutomationExecutionMetadata' :: Maybe ResolvedTargets
resolvedTargets = Maybe ResolvedTargets
a} :: AutomationExecutionMetadata)

-- | The document version used during the execution.
automationExecutionMetadata_documentVersion :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe Prelude.Text)
automationExecutionMetadata_documentVersion :: (Maybe Text -> f (Maybe Text))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_documentVersion = (AutomationExecutionMetadata -> Maybe Text)
-> (AutomationExecutionMetadata
    -> Maybe Text -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe Text
documentVersion :: Maybe Text
$sel:documentVersion:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe Text
documentVersion} -> Maybe Text
documentVersion) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe Text
a -> AutomationExecutionMetadata
s {$sel:documentVersion:AutomationExecutionMetadata' :: Maybe Text
documentVersion = Maybe Text
a} :: AutomationExecutionMetadata)

-- | The execution ID.
automationExecutionMetadata_automationExecutionId :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe Prelude.Text)
automationExecutionMetadata_automationExecutionId :: (Maybe Text -> f (Maybe Text))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_automationExecutionId = (AutomationExecutionMetadata -> Maybe Text)
-> (AutomationExecutionMetadata
    -> Maybe Text -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe Text
automationExecutionId :: Maybe Text
$sel:automationExecutionId:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe Text
automationExecutionId} -> Maybe Text
automationExecutionId) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe Text
a -> AutomationExecutionMetadata
s {$sel:automationExecutionId:AutomationExecutionMetadata' :: Maybe Text
automationExecutionId = Maybe Text
a} :: AutomationExecutionMetadata)

-- | The name of the Change Manager change request.
automationExecutionMetadata_changeRequestName :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe Prelude.Text)
automationExecutionMetadata_changeRequestName :: (Maybe Text -> f (Maybe Text))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_changeRequestName = (AutomationExecutionMetadata -> Maybe Text)
-> (AutomationExecutionMetadata
    -> Maybe Text -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe Text
changeRequestName :: Maybe Text
$sel:changeRequestName:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe Text
changeRequestName} -> Maybe Text
changeRequestName) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe Text
a -> AutomationExecutionMetadata
s {$sel:changeRequestName:AutomationExecutionMetadata' :: Maybe Text
changeRequestName = Maybe Text
a} :: AutomationExecutionMetadata)

-- | Information about the Automation runbooks that are run during a runbook
-- workflow in Change Manager.
--
-- The Automation runbooks specified for the runbook workflow can\'t run
-- until all required approvals for the change request have been received.
automationExecutionMetadata_runbooks :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe (Prelude.NonEmpty Runbook))
automationExecutionMetadata_runbooks :: (Maybe (NonEmpty Runbook) -> f (Maybe (NonEmpty Runbook)))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_runbooks = (AutomationExecutionMetadata -> Maybe (NonEmpty Runbook))
-> (AutomationExecutionMetadata
    -> Maybe (NonEmpty Runbook) -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe (NonEmpty Runbook))
     (Maybe (NonEmpty Runbook))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe (NonEmpty Runbook)
runbooks :: Maybe (NonEmpty Runbook)
$sel:runbooks:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe (NonEmpty Runbook)
runbooks} -> Maybe (NonEmpty Runbook)
runbooks) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe (NonEmpty Runbook)
a -> AutomationExecutionMetadata
s {$sel:runbooks:AutomationExecutionMetadata' :: Maybe (NonEmpty Runbook)
runbooks = Maybe (NonEmpty Runbook)
a} :: AutomationExecutionMetadata) ((Maybe (NonEmpty Runbook) -> f (Maybe (NonEmpty Runbook)))
 -> AutomationExecutionMetadata -> f AutomationExecutionMetadata)
-> ((Maybe (NonEmpty Runbook) -> f (Maybe (NonEmpty Runbook)))
    -> Maybe (NonEmpty Runbook) -> f (Maybe (NonEmpty Runbook)))
-> (Maybe (NonEmpty Runbook) -> f (Maybe (NonEmpty Runbook)))
-> AutomationExecutionMetadata
-> f AutomationExecutionMetadata
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  (NonEmpty Runbook)
  (NonEmpty Runbook)
  (NonEmpty Runbook)
  (NonEmpty Runbook)
-> Iso
     (Maybe (NonEmpty Runbook))
     (Maybe (NonEmpty Runbook))
     (Maybe (NonEmpty Runbook))
     (Maybe (NonEmpty Runbook))
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
  (NonEmpty Runbook)
  (NonEmpty Runbook)
  (NonEmpty Runbook)
  (NonEmpty Runbook)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The @MaxConcurrency@ value specified by the user when starting the
-- automation.
automationExecutionMetadata_maxConcurrency :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe Prelude.Text)
automationExecutionMetadata_maxConcurrency :: (Maybe Text -> f (Maybe Text))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_maxConcurrency = (AutomationExecutionMetadata -> Maybe Text)
-> (AutomationExecutionMetadata
    -> Maybe Text -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe Text
maxConcurrency :: Maybe Text
$sel:maxConcurrency:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe Text
maxConcurrency} -> Maybe Text
maxConcurrency) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe Text
a -> AutomationExecutionMetadata
s {$sel:maxConcurrency:AutomationExecutionMetadata' :: Maybe Text
maxConcurrency = Maybe Text
a} :: AutomationExecutionMetadata)

-- | The list of execution outputs as defined in the Automation runbook.
automationExecutionMetadata_target :: Lens.Lens' AutomationExecutionMetadata (Prelude.Maybe Prelude.Text)
automationExecutionMetadata_target :: (Maybe Text -> f (Maybe Text))
-> AutomationExecutionMetadata -> f AutomationExecutionMetadata
automationExecutionMetadata_target = (AutomationExecutionMetadata -> Maybe Text)
-> (AutomationExecutionMetadata
    -> Maybe Text -> AutomationExecutionMetadata)
-> Lens
     AutomationExecutionMetadata
     AutomationExecutionMetadata
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AutomationExecutionMetadata' {Maybe Text
target :: Maybe Text
$sel:target:AutomationExecutionMetadata' :: AutomationExecutionMetadata -> Maybe Text
target} -> Maybe Text
target) (\s :: AutomationExecutionMetadata
s@AutomationExecutionMetadata' {} Maybe Text
a -> AutomationExecutionMetadata
s {$sel:target:AutomationExecutionMetadata' :: Maybe Text
target = Maybe Text
a} :: AutomationExecutionMetadata)

instance Core.FromJSON AutomationExecutionMetadata where
  parseJSON :: Value -> Parser AutomationExecutionMetadata
parseJSON =
    String
-> (Object -> Parser AutomationExecutionMetadata)
-> Value
-> Parser AutomationExecutionMetadata
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
      String
"AutomationExecutionMetadata"
      ( \Object
x ->
          Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe AutomationSubtype
-> Maybe ExecutionMode
-> Maybe [HashMap Text [Text]]
-> Maybe AutomationExecutionStatus
-> Maybe Text
-> Maybe (HashMap Text [Text])
-> Maybe Text
-> Maybe POSIX
-> Maybe AutomationType
-> Maybe Text
-> Maybe [Target]
-> Maybe ResolvedTargets
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe (NonEmpty Runbook)
-> Maybe Text
-> Maybe Text
-> AutomationExecutionMetadata
AutomationExecutionMetadata'
            (Maybe POSIX
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe POSIX
 -> Maybe Text
 -> Maybe AutomationSubtype
 -> Maybe ExecutionMode
 -> Maybe [HashMap Text [Text]]
 -> Maybe AutomationExecutionStatus
 -> Maybe Text
 -> Maybe (HashMap Text [Text])
 -> Maybe Text
 -> Maybe POSIX
 -> Maybe AutomationType
 -> Maybe Text
 -> Maybe [Target]
 -> Maybe ResolvedTargets
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe (NonEmpty Runbook)
 -> Maybe Text
 -> Maybe Text
 -> AutomationExecutionMetadata)
-> Parser (Maybe POSIX)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe AutomationSubtype
      -> Maybe ExecutionMode
      -> Maybe [HashMap Text [Text]]
      -> Maybe AutomationExecutionStatus
      -> Maybe Text
      -> Maybe (HashMap Text [Text])
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe AutomationType
      -> Maybe Text
      -> Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ScheduledTime")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe AutomationSubtype
   -> Maybe ExecutionMode
   -> Maybe [HashMap Text [Text]]
   -> Maybe AutomationExecutionStatus
   -> Maybe Text
   -> Maybe (HashMap Text [Text])
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe AutomationType
   -> Maybe Text
   -> Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe AutomationSubtype
      -> Maybe ExecutionMode
      -> Maybe [HashMap Text [Text]]
      -> Maybe AutomationExecutionStatus
      -> Maybe Text
      -> Maybe (HashMap Text [Text])
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe AutomationType
      -> Maybe Text
      -> Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"AssociationId")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe AutomationSubtype
   -> Maybe ExecutionMode
   -> Maybe [HashMap Text [Text]]
   -> Maybe AutomationExecutionStatus
   -> Maybe Text
   -> Maybe (HashMap Text [Text])
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe AutomationType
   -> Maybe Text
   -> Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe AutomationSubtype
      -> Maybe ExecutionMode
      -> Maybe [HashMap Text [Text]]
      -> Maybe AutomationExecutionStatus
      -> Maybe Text
      -> Maybe (HashMap Text [Text])
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe AutomationType
      -> Maybe Text
      -> Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"OpsItemId")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe AutomationSubtype
   -> Maybe ExecutionMode
   -> Maybe [HashMap Text [Text]]
   -> Maybe AutomationExecutionStatus
   -> Maybe Text
   -> Maybe (HashMap Text [Text])
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe AutomationType
   -> Maybe Text
   -> Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe AutomationSubtype
      -> Maybe ExecutionMode
      -> Maybe [HashMap Text [Text]]
      -> Maybe AutomationExecutionStatus
      -> Maybe Text
      -> Maybe (HashMap Text [Text])
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe AutomationType
      -> Maybe Text
      -> Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CurrentStepName")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe AutomationSubtype
   -> Maybe ExecutionMode
   -> Maybe [HashMap Text [Text]]
   -> Maybe AutomationExecutionStatus
   -> Maybe Text
   -> Maybe (HashMap Text [Text])
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe AutomationType
   -> Maybe Text
   -> Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe AutomationSubtype
      -> Maybe ExecutionMode
      -> Maybe [HashMap Text [Text]]
      -> Maybe AutomationExecutionStatus
      -> Maybe Text
      -> Maybe (HashMap Text [Text])
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe AutomationType
      -> Maybe Text
      -> Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"TargetParameterName")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe AutomationSubtype
   -> Maybe ExecutionMode
   -> Maybe [HashMap Text [Text]]
   -> Maybe AutomationExecutionStatus
   -> Maybe Text
   -> Maybe (HashMap Text [Text])
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe AutomationType
   -> Maybe Text
   -> Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe AutomationSubtype
      -> Maybe ExecutionMode
      -> Maybe [HashMap Text [Text]]
      -> Maybe AutomationExecutionStatus
      -> Maybe Text
      -> Maybe (HashMap Text [Text])
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe AutomationType
      -> Maybe Text
      -> Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"LogFile")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe AutomationSubtype
   -> Maybe ExecutionMode
   -> Maybe [HashMap Text [Text]]
   -> Maybe AutomationExecutionStatus
   -> Maybe Text
   -> Maybe (HashMap Text [Text])
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe AutomationType
   -> Maybe Text
   -> Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe AutomationSubtype
      -> Maybe ExecutionMode
      -> Maybe [HashMap Text [Text]]
      -> Maybe AutomationExecutionStatus
      -> Maybe Text
      -> Maybe (HashMap Text [Text])
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe AutomationType
      -> Maybe Text
      -> Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ExecutedBy")
            Parser
  (Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe AutomationSubtype
   -> Maybe ExecutionMode
   -> Maybe [HashMap Text [Text]]
   -> Maybe AutomationExecutionStatus
   -> Maybe Text
   -> Maybe (HashMap Text [Text])
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe AutomationType
   -> Maybe Text
   -> Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe Text)
-> Parser
     (Maybe POSIX
      -> Maybe Text
      -> Maybe AutomationSubtype
      -> Maybe ExecutionMode
      -> Maybe [HashMap Text [Text]]
      -> Maybe AutomationExecutionStatus
      -> Maybe Text
      -> Maybe (HashMap Text [Text])
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe AutomationType
      -> Maybe Text
      -> Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"DocumentName")
            Parser
  (Maybe POSIX
   -> Maybe Text
   -> Maybe AutomationSubtype
   -> Maybe ExecutionMode
   -> Maybe [HashMap Text [Text]]
   -> Maybe AutomationExecutionStatus
   -> Maybe Text
   -> Maybe (HashMap Text [Text])
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe AutomationType
   -> Maybe Text
   -> Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe POSIX)
-> Parser
     (Maybe Text
      -> Maybe AutomationSubtype
      -> Maybe ExecutionMode
      -> Maybe [HashMap Text [Text]]
      -> Maybe AutomationExecutionStatus
      -> Maybe Text
      -> Maybe (HashMap Text [Text])
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe AutomationType
      -> Maybe Text
      -> Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ExecutionEndTime")
            Parser
  (Maybe Text
   -> Maybe AutomationSubtype
   -> Maybe ExecutionMode
   -> Maybe [HashMap Text [Text]]
   -> Maybe AutomationExecutionStatus
   -> Maybe Text
   -> Maybe (HashMap Text [Text])
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe AutomationType
   -> Maybe Text
   -> Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe Text)
-> Parser
     (Maybe AutomationSubtype
      -> Maybe ExecutionMode
      -> Maybe [HashMap Text [Text]]
      -> Maybe AutomationExecutionStatus
      -> Maybe Text
      -> Maybe (HashMap Text [Text])
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe AutomationType
      -> Maybe Text
      -> Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"FailureMessage")
            Parser
  (Maybe AutomationSubtype
   -> Maybe ExecutionMode
   -> Maybe [HashMap Text [Text]]
   -> Maybe AutomationExecutionStatus
   -> Maybe Text
   -> Maybe (HashMap Text [Text])
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe AutomationType
   -> Maybe Text
   -> Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe AutomationSubtype)
-> Parser
     (Maybe ExecutionMode
      -> Maybe [HashMap Text [Text]]
      -> Maybe AutomationExecutionStatus
      -> Maybe Text
      -> Maybe (HashMap Text [Text])
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe AutomationType
      -> Maybe Text
      -> Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe AutomationSubtype)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"AutomationSubtype")
            Parser
  (Maybe ExecutionMode
   -> Maybe [HashMap Text [Text]]
   -> Maybe AutomationExecutionStatus
   -> Maybe Text
   -> Maybe (HashMap Text [Text])
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe AutomationType
   -> Maybe Text
   -> Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe ExecutionMode)
-> Parser
     (Maybe [HashMap Text [Text]]
      -> Maybe AutomationExecutionStatus
      -> Maybe Text
      -> Maybe (HashMap Text [Text])
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe AutomationType
      -> Maybe Text
      -> Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe ExecutionMode)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Mode")
            Parser
  (Maybe [HashMap Text [Text]]
   -> Maybe AutomationExecutionStatus
   -> Maybe Text
   -> Maybe (HashMap Text [Text])
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe AutomationType
   -> Maybe Text
   -> Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe [HashMap Text [Text]])
-> Parser
     (Maybe AutomationExecutionStatus
      -> Maybe Text
      -> Maybe (HashMap Text [Text])
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe AutomationType
      -> Maybe Text
      -> Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe [HashMap Text [Text]]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"TargetMaps" Parser (Maybe (Maybe [HashMap Text [Text]]))
-> Maybe [HashMap Text [Text]]
-> Parser (Maybe [HashMap Text [Text]])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [HashMap Text [Text]]
forall a. Monoid a => a
Prelude.mempty)
            Parser
  (Maybe AutomationExecutionStatus
   -> Maybe Text
   -> Maybe (HashMap Text [Text])
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe AutomationType
   -> Maybe Text
   -> Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe AutomationExecutionStatus)
-> Parser
     (Maybe Text
      -> Maybe (HashMap Text [Text])
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe AutomationType
      -> Maybe Text
      -> Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe AutomationExecutionStatus)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"AutomationExecutionStatus")
            Parser
  (Maybe Text
   -> Maybe (HashMap Text [Text])
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe AutomationType
   -> Maybe Text
   -> Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe Text)
-> Parser
     (Maybe (HashMap Text [Text])
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe AutomationType
      -> Maybe Text
      -> Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ParentAutomationExecutionId")
            Parser
  (Maybe (HashMap Text [Text])
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe AutomationType
   -> Maybe Text
   -> Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe (HashMap Text [Text]))
-> Parser
     (Maybe Text
      -> Maybe POSIX
      -> Maybe AutomationType
      -> Maybe Text
      -> Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe (HashMap Text [Text])))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Outputs" Parser (Maybe (Maybe (HashMap Text [Text])))
-> Maybe (HashMap Text [Text])
-> Parser (Maybe (HashMap Text [Text]))
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe (HashMap Text [Text])
forall a. Monoid a => a
Prelude.mempty)
            Parser
  (Maybe Text
   -> Maybe POSIX
   -> Maybe AutomationType
   -> Maybe Text
   -> Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe Text)
-> Parser
     (Maybe POSIX
      -> Maybe AutomationType
      -> Maybe Text
      -> Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"MaxErrors")
            Parser
  (Maybe POSIX
   -> Maybe AutomationType
   -> Maybe Text
   -> Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe POSIX)
-> Parser
     (Maybe AutomationType
      -> Maybe Text
      -> Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ExecutionStartTime")
            Parser
  (Maybe AutomationType
   -> Maybe Text
   -> Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe AutomationType)
-> Parser
     (Maybe Text
      -> Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe AutomationType)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"AutomationType")
            Parser
  (Maybe Text
   -> Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe Text)
-> Parser
     (Maybe [Target]
      -> Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CurrentAction")
            Parser
  (Maybe [Target]
   -> Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe [Target])
-> Parser
     (Maybe ResolvedTargets
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe [Target]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Targets" Parser (Maybe (Maybe [Target]))
-> Maybe [Target] -> Parser (Maybe [Target])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [Target]
forall a. Monoid a => a
Prelude.mempty)
            Parser
  (Maybe ResolvedTargets
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe ResolvedTargets)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe ResolvedTargets)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ResolvedTargets")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"DocumentVersion")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe (NonEmpty Runbook)
      -> Maybe Text
      -> Maybe Text
      -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"AutomationExecutionId")
            Parser
  (Maybe Text
   -> Maybe (NonEmpty Runbook)
   -> Maybe Text
   -> Maybe Text
   -> AutomationExecutionMetadata)
-> Parser (Maybe Text)
-> Parser
     (Maybe (NonEmpty Runbook)
      -> Maybe Text -> Maybe Text -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ChangeRequestName")
            Parser
  (Maybe (NonEmpty Runbook)
   -> Maybe Text -> Maybe Text -> AutomationExecutionMetadata)
-> Parser (Maybe (NonEmpty Runbook))
-> Parser (Maybe Text -> Maybe Text -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (NonEmpty Runbook))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Runbooks")
            Parser (Maybe Text -> Maybe Text -> AutomationExecutionMetadata)
-> Parser (Maybe Text)
-> Parser (Maybe Text -> AutomationExecutionMetadata)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"MaxConcurrency")
            Parser (Maybe Text -> AutomationExecutionMetadata)
-> Parser (Maybe Text) -> Parser AutomationExecutionMetadata
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Target")
      )

instance Prelude.Hashable AutomationExecutionMetadata

instance Prelude.NFData AutomationExecutionMetadata