{-# 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.SSMIncidents.UpdateTimelineEvent
-- 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)
--
-- Updates a timeline event. You can update events of type @Custom Event@.
module Amazonka.SSMIncidents.UpdateTimelineEvent
  ( -- * Creating a Request
    UpdateTimelineEvent (..),
    newUpdateTimelineEvent,

    -- * Request Lenses
    updateTimelineEvent_eventData,
    updateTimelineEvent_clientToken,
    updateTimelineEvent_eventTime,
    updateTimelineEvent_eventType,
    updateTimelineEvent_eventId,
    updateTimelineEvent_incidentRecordArn,

    -- * Destructuring the Response
    UpdateTimelineEventResponse (..),
    newUpdateTimelineEventResponse,

    -- * Response Lenses
    updateTimelineEventResponse_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.SSMIncidents.Types

-- | /See:/ 'newUpdateTimelineEvent' smart constructor.
data UpdateTimelineEvent = UpdateTimelineEvent'
  { -- | A short description of the event.
    UpdateTimelineEvent -> Maybe Text
eventData :: Prelude.Maybe Prelude.Text,
    -- | A token ensuring that the action is called only once with the specified
    -- details.
    UpdateTimelineEvent -> Maybe Text
clientToken :: Prelude.Maybe Prelude.Text,
    -- | The time that the event occurred.
    UpdateTimelineEvent -> Maybe POSIX
eventTime :: Prelude.Maybe Core.POSIX,
    -- | The type of the event. You can update events of type @Custom Event@.
    UpdateTimelineEvent -> Maybe Text
eventType :: Prelude.Maybe Prelude.Text,
    -- | The ID of the event you are updating. You can find this by using
    -- @ListTimelineEvents@.
    UpdateTimelineEvent -> Text
eventId :: Prelude.Text,
    -- | The Amazon Resource Name (ARN) of the incident that the timeline event
    -- is part of.
    UpdateTimelineEvent -> Text
incidentRecordArn :: Prelude.Text
  }
  deriving (UpdateTimelineEvent -> UpdateTimelineEvent -> Bool
(UpdateTimelineEvent -> UpdateTimelineEvent -> Bool)
-> (UpdateTimelineEvent -> UpdateTimelineEvent -> Bool)
-> Eq UpdateTimelineEvent
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateTimelineEvent -> UpdateTimelineEvent -> Bool
$c/= :: UpdateTimelineEvent -> UpdateTimelineEvent -> Bool
== :: UpdateTimelineEvent -> UpdateTimelineEvent -> Bool
$c== :: UpdateTimelineEvent -> UpdateTimelineEvent -> Bool
Prelude.Eq, ReadPrec [UpdateTimelineEvent]
ReadPrec UpdateTimelineEvent
Int -> ReadS UpdateTimelineEvent
ReadS [UpdateTimelineEvent]
(Int -> ReadS UpdateTimelineEvent)
-> ReadS [UpdateTimelineEvent]
-> ReadPrec UpdateTimelineEvent
-> ReadPrec [UpdateTimelineEvent]
-> Read UpdateTimelineEvent
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateTimelineEvent]
$creadListPrec :: ReadPrec [UpdateTimelineEvent]
readPrec :: ReadPrec UpdateTimelineEvent
$creadPrec :: ReadPrec UpdateTimelineEvent
readList :: ReadS [UpdateTimelineEvent]
$creadList :: ReadS [UpdateTimelineEvent]
readsPrec :: Int -> ReadS UpdateTimelineEvent
$creadsPrec :: Int -> ReadS UpdateTimelineEvent
Prelude.Read, Int -> UpdateTimelineEvent -> ShowS
[UpdateTimelineEvent] -> ShowS
UpdateTimelineEvent -> String
(Int -> UpdateTimelineEvent -> ShowS)
-> (UpdateTimelineEvent -> String)
-> ([UpdateTimelineEvent] -> ShowS)
-> Show UpdateTimelineEvent
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateTimelineEvent] -> ShowS
$cshowList :: [UpdateTimelineEvent] -> ShowS
show :: UpdateTimelineEvent -> String
$cshow :: UpdateTimelineEvent -> String
showsPrec :: Int -> UpdateTimelineEvent -> ShowS
$cshowsPrec :: Int -> UpdateTimelineEvent -> ShowS
Prelude.Show, (forall x. UpdateTimelineEvent -> Rep UpdateTimelineEvent x)
-> (forall x. Rep UpdateTimelineEvent x -> UpdateTimelineEvent)
-> Generic UpdateTimelineEvent
forall x. Rep UpdateTimelineEvent x -> UpdateTimelineEvent
forall x. UpdateTimelineEvent -> Rep UpdateTimelineEvent x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UpdateTimelineEvent x -> UpdateTimelineEvent
$cfrom :: forall x. UpdateTimelineEvent -> Rep UpdateTimelineEvent x
Prelude.Generic)

-- |
-- Create a value of 'UpdateTimelineEvent' 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:
--
-- 'eventData', 'updateTimelineEvent_eventData' - A short description of the event.
--
-- 'clientToken', 'updateTimelineEvent_clientToken' - A token ensuring that the action is called only once with the specified
-- details.
--
-- 'eventTime', 'updateTimelineEvent_eventTime' - The time that the event occurred.
--
-- 'eventType', 'updateTimelineEvent_eventType' - The type of the event. You can update events of type @Custom Event@.
--
-- 'eventId', 'updateTimelineEvent_eventId' - The ID of the event you are updating. You can find this by using
-- @ListTimelineEvents@.
--
-- 'incidentRecordArn', 'updateTimelineEvent_incidentRecordArn' - The Amazon Resource Name (ARN) of the incident that the timeline event
-- is part of.
newUpdateTimelineEvent ::
  -- | 'eventId'
  Prelude.Text ->
  -- | 'incidentRecordArn'
  Prelude.Text ->
  UpdateTimelineEvent
newUpdateTimelineEvent :: Text -> Text -> UpdateTimelineEvent
newUpdateTimelineEvent Text
pEventId_ Text
pIncidentRecordArn_ =
  UpdateTimelineEvent' :: Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Text
-> Text
-> UpdateTimelineEvent
UpdateTimelineEvent'
    { $sel:eventData:UpdateTimelineEvent' :: Maybe Text
eventData = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:clientToken:UpdateTimelineEvent' :: Maybe Text
clientToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:eventTime:UpdateTimelineEvent' :: Maybe POSIX
eventTime = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
      $sel:eventType:UpdateTimelineEvent' :: Maybe Text
eventType = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:eventId:UpdateTimelineEvent' :: Text
eventId = Text
pEventId_,
      $sel:incidentRecordArn:UpdateTimelineEvent' :: Text
incidentRecordArn = Text
pIncidentRecordArn_
    }

-- | A short description of the event.
updateTimelineEvent_eventData :: Lens.Lens' UpdateTimelineEvent (Prelude.Maybe Prelude.Text)
updateTimelineEvent_eventData :: (Maybe Text -> f (Maybe Text))
-> UpdateTimelineEvent -> f UpdateTimelineEvent
updateTimelineEvent_eventData = (UpdateTimelineEvent -> Maybe Text)
-> (UpdateTimelineEvent -> Maybe Text -> UpdateTimelineEvent)
-> Lens
     UpdateTimelineEvent UpdateTimelineEvent (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateTimelineEvent' {Maybe Text
eventData :: Maybe Text
$sel:eventData:UpdateTimelineEvent' :: UpdateTimelineEvent -> Maybe Text
eventData} -> Maybe Text
eventData) (\s :: UpdateTimelineEvent
s@UpdateTimelineEvent' {} Maybe Text
a -> UpdateTimelineEvent
s {$sel:eventData:UpdateTimelineEvent' :: Maybe Text
eventData = Maybe Text
a} :: UpdateTimelineEvent)

-- | A token ensuring that the action is called only once with the specified
-- details.
updateTimelineEvent_clientToken :: Lens.Lens' UpdateTimelineEvent (Prelude.Maybe Prelude.Text)
updateTimelineEvent_clientToken :: (Maybe Text -> f (Maybe Text))
-> UpdateTimelineEvent -> f UpdateTimelineEvent
updateTimelineEvent_clientToken = (UpdateTimelineEvent -> Maybe Text)
-> (UpdateTimelineEvent -> Maybe Text -> UpdateTimelineEvent)
-> Lens
     UpdateTimelineEvent UpdateTimelineEvent (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateTimelineEvent' {Maybe Text
clientToken :: Maybe Text
$sel:clientToken:UpdateTimelineEvent' :: UpdateTimelineEvent -> Maybe Text
clientToken} -> Maybe Text
clientToken) (\s :: UpdateTimelineEvent
s@UpdateTimelineEvent' {} Maybe Text
a -> UpdateTimelineEvent
s {$sel:clientToken:UpdateTimelineEvent' :: Maybe Text
clientToken = Maybe Text
a} :: UpdateTimelineEvent)

-- | The time that the event occurred.
updateTimelineEvent_eventTime :: Lens.Lens' UpdateTimelineEvent (Prelude.Maybe Prelude.UTCTime)
updateTimelineEvent_eventTime :: (Maybe UTCTime -> f (Maybe UTCTime))
-> UpdateTimelineEvent -> f UpdateTimelineEvent
updateTimelineEvent_eventTime = (UpdateTimelineEvent -> Maybe POSIX)
-> (UpdateTimelineEvent -> Maybe POSIX -> UpdateTimelineEvent)
-> Lens
     UpdateTimelineEvent UpdateTimelineEvent (Maybe POSIX) (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateTimelineEvent' {Maybe POSIX
eventTime :: Maybe POSIX
$sel:eventTime:UpdateTimelineEvent' :: UpdateTimelineEvent -> Maybe POSIX
eventTime} -> Maybe POSIX
eventTime) (\s :: UpdateTimelineEvent
s@UpdateTimelineEvent' {} Maybe POSIX
a -> UpdateTimelineEvent
s {$sel:eventTime:UpdateTimelineEvent' :: Maybe POSIX
eventTime = Maybe POSIX
a} :: UpdateTimelineEvent) ((Maybe POSIX -> f (Maybe POSIX))
 -> UpdateTimelineEvent -> f UpdateTimelineEvent)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> UpdateTimelineEvent
-> f UpdateTimelineEvent
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 type of the event. You can update events of type @Custom Event@.
updateTimelineEvent_eventType :: Lens.Lens' UpdateTimelineEvent (Prelude.Maybe Prelude.Text)
updateTimelineEvent_eventType :: (Maybe Text -> f (Maybe Text))
-> UpdateTimelineEvent -> f UpdateTimelineEvent
updateTimelineEvent_eventType = (UpdateTimelineEvent -> Maybe Text)
-> (UpdateTimelineEvent -> Maybe Text -> UpdateTimelineEvent)
-> Lens
     UpdateTimelineEvent UpdateTimelineEvent (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateTimelineEvent' {Maybe Text
eventType :: Maybe Text
$sel:eventType:UpdateTimelineEvent' :: UpdateTimelineEvent -> Maybe Text
eventType} -> Maybe Text
eventType) (\s :: UpdateTimelineEvent
s@UpdateTimelineEvent' {} Maybe Text
a -> UpdateTimelineEvent
s {$sel:eventType:UpdateTimelineEvent' :: Maybe Text
eventType = Maybe Text
a} :: UpdateTimelineEvent)

-- | The ID of the event you are updating. You can find this by using
-- @ListTimelineEvents@.
updateTimelineEvent_eventId :: Lens.Lens' UpdateTimelineEvent Prelude.Text
updateTimelineEvent_eventId :: (Text -> f Text) -> UpdateTimelineEvent -> f UpdateTimelineEvent
updateTimelineEvent_eventId = (UpdateTimelineEvent -> Text)
-> (UpdateTimelineEvent -> Text -> UpdateTimelineEvent)
-> Lens UpdateTimelineEvent UpdateTimelineEvent Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateTimelineEvent' {Text
eventId :: Text
$sel:eventId:UpdateTimelineEvent' :: UpdateTimelineEvent -> Text
eventId} -> Text
eventId) (\s :: UpdateTimelineEvent
s@UpdateTimelineEvent' {} Text
a -> UpdateTimelineEvent
s {$sel:eventId:UpdateTimelineEvent' :: Text
eventId = Text
a} :: UpdateTimelineEvent)

-- | The Amazon Resource Name (ARN) of the incident that the timeline event
-- is part of.
updateTimelineEvent_incidentRecordArn :: Lens.Lens' UpdateTimelineEvent Prelude.Text
updateTimelineEvent_incidentRecordArn :: (Text -> f Text) -> UpdateTimelineEvent -> f UpdateTimelineEvent
updateTimelineEvent_incidentRecordArn = (UpdateTimelineEvent -> Text)
-> (UpdateTimelineEvent -> Text -> UpdateTimelineEvent)
-> Lens UpdateTimelineEvent UpdateTimelineEvent Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateTimelineEvent' {Text
incidentRecordArn :: Text
$sel:incidentRecordArn:UpdateTimelineEvent' :: UpdateTimelineEvent -> Text
incidentRecordArn} -> Text
incidentRecordArn) (\s :: UpdateTimelineEvent
s@UpdateTimelineEvent' {} Text
a -> UpdateTimelineEvent
s {$sel:incidentRecordArn:UpdateTimelineEvent' :: Text
incidentRecordArn = Text
a} :: UpdateTimelineEvent)

instance Core.AWSRequest UpdateTimelineEvent where
  type
    AWSResponse UpdateTimelineEvent =
      UpdateTimelineEventResponse
  request :: UpdateTimelineEvent -> Request UpdateTimelineEvent
request = Service -> UpdateTimelineEvent -> Request UpdateTimelineEvent
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy UpdateTimelineEvent
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse UpdateTimelineEvent)))
response =
    (Int
 -> ResponseHeaders
 -> ()
 -> Either String (AWSResponse UpdateTimelineEvent))
-> Logger
-> Service
-> Proxy UpdateTimelineEvent
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse UpdateTimelineEvent)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> () -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveEmpty
      ( \Int
s ResponseHeaders
h ()
x ->
          Int -> UpdateTimelineEventResponse
UpdateTimelineEventResponse'
            (Int -> UpdateTimelineEventResponse)
-> Either String Int -> Either String UpdateTimelineEventResponse
forall (f :: * -> *) a b. Functor 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 UpdateTimelineEvent

instance Prelude.NFData UpdateTimelineEvent

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

instance Core.ToJSON UpdateTimelineEvent where
  toJSON :: UpdateTimelineEvent -> Value
toJSON UpdateTimelineEvent' {Maybe Text
Maybe POSIX
Text
incidentRecordArn :: Text
eventId :: Text
eventType :: Maybe Text
eventTime :: Maybe POSIX
clientToken :: Maybe Text
eventData :: Maybe Text
$sel:incidentRecordArn:UpdateTimelineEvent' :: UpdateTimelineEvent -> Text
$sel:eventId:UpdateTimelineEvent' :: UpdateTimelineEvent -> Text
$sel:eventType:UpdateTimelineEvent' :: UpdateTimelineEvent -> Maybe Text
$sel:eventTime:UpdateTimelineEvent' :: UpdateTimelineEvent -> Maybe POSIX
$sel:clientToken:UpdateTimelineEvent' :: UpdateTimelineEvent -> Maybe Text
$sel:eventData:UpdateTimelineEvent' :: UpdateTimelineEvent -> Maybe Text
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Text
"eventData" 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
eventData,
            (Text
"clientToken" 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
clientToken,
            (Text
"eventTime" Text -> POSIX -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (POSIX -> Pair) -> Maybe POSIX -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe POSIX
eventTime,
            (Text
"eventType" 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
eventType,
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"eventId" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
eventId),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just
              (Text
"incidentRecordArn" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
incidentRecordArn)
          ]
      )

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

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

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

-- |
-- Create a value of 'UpdateTimelineEventResponse' 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:
--
-- 'httpStatus', 'updateTimelineEventResponse_httpStatus' - The response's http status code.
newUpdateTimelineEventResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  UpdateTimelineEventResponse
newUpdateTimelineEventResponse :: Int -> UpdateTimelineEventResponse
newUpdateTimelineEventResponse Int
pHttpStatus_ =
  UpdateTimelineEventResponse' :: Int -> UpdateTimelineEventResponse
UpdateTimelineEventResponse'
    { $sel:httpStatus:UpdateTimelineEventResponse' :: Int
httpStatus =
        Int
pHttpStatus_
    }

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

instance Prelude.NFData UpdateTimelineEventResponse