{-# 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 #-}
module Amazonka.QuickSight.UpdateDashboard
(
UpdateDashboard (..),
newUpdateDashboard,
updateDashboard_themeArn,
updateDashboard_dashboardPublishOptions,
updateDashboard_versionDescription,
updateDashboard_parameters,
updateDashboard_awsAccountId,
updateDashboard_dashboardId,
updateDashboard_name,
updateDashboard_sourceEntity,
UpdateDashboardResponse (..),
newUpdateDashboardResponse,
updateDashboardResponse_requestId,
updateDashboardResponse_status,
updateDashboardResponse_arn,
updateDashboardResponse_creationStatus,
updateDashboardResponse_dashboardId,
updateDashboardResponse_versionArn,
updateDashboardResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.QuickSight.Types
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data UpdateDashboard = UpdateDashboard'
{
UpdateDashboard -> Maybe Text
themeArn :: Prelude.Maybe Prelude.Text,
UpdateDashboard -> Maybe DashboardPublishOptions
dashboardPublishOptions :: Prelude.Maybe DashboardPublishOptions,
UpdateDashboard -> Maybe Text
versionDescription :: Prelude.Maybe Prelude.Text,
UpdateDashboard -> Maybe Parameters
parameters :: Prelude.Maybe Parameters,
UpdateDashboard -> Text
awsAccountId :: Prelude.Text,
UpdateDashboard -> Text
dashboardId :: Prelude.Text,
UpdateDashboard -> Text
name :: Prelude.Text,
UpdateDashboard -> DashboardSourceEntity
sourceEntity :: DashboardSourceEntity
}
deriving (UpdateDashboard -> UpdateDashboard -> Bool
(UpdateDashboard -> UpdateDashboard -> Bool)
-> (UpdateDashboard -> UpdateDashboard -> Bool)
-> Eq UpdateDashboard
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateDashboard -> UpdateDashboard -> Bool
$c/= :: UpdateDashboard -> UpdateDashboard -> Bool
== :: UpdateDashboard -> UpdateDashboard -> Bool
$c== :: UpdateDashboard -> UpdateDashboard -> Bool
Prelude.Eq, ReadPrec [UpdateDashboard]
ReadPrec UpdateDashboard
Int -> ReadS UpdateDashboard
ReadS [UpdateDashboard]
(Int -> ReadS UpdateDashboard)
-> ReadS [UpdateDashboard]
-> ReadPrec UpdateDashboard
-> ReadPrec [UpdateDashboard]
-> Read UpdateDashboard
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateDashboard]
$creadListPrec :: ReadPrec [UpdateDashboard]
readPrec :: ReadPrec UpdateDashboard
$creadPrec :: ReadPrec UpdateDashboard
readList :: ReadS [UpdateDashboard]
$creadList :: ReadS [UpdateDashboard]
readsPrec :: Int -> ReadS UpdateDashboard
$creadsPrec :: Int -> ReadS UpdateDashboard
Prelude.Read, Int -> UpdateDashboard -> ShowS
[UpdateDashboard] -> ShowS
UpdateDashboard -> String
(Int -> UpdateDashboard -> ShowS)
-> (UpdateDashboard -> String)
-> ([UpdateDashboard] -> ShowS)
-> Show UpdateDashboard
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateDashboard] -> ShowS
$cshowList :: [UpdateDashboard] -> ShowS
show :: UpdateDashboard -> String
$cshow :: UpdateDashboard -> String
showsPrec :: Int -> UpdateDashboard -> ShowS
$cshowsPrec :: Int -> UpdateDashboard -> ShowS
Prelude.Show, (forall x. UpdateDashboard -> Rep UpdateDashboard x)
-> (forall x. Rep UpdateDashboard x -> UpdateDashboard)
-> Generic UpdateDashboard
forall x. Rep UpdateDashboard x -> UpdateDashboard
forall x. UpdateDashboard -> Rep UpdateDashboard x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UpdateDashboard x -> UpdateDashboard
$cfrom :: forall x. UpdateDashboard -> Rep UpdateDashboard x
Prelude.Generic)
newUpdateDashboard ::
Prelude.Text ->
Prelude.Text ->
Prelude.Text ->
DashboardSourceEntity ->
UpdateDashboard
newUpdateDashboard :: Text -> Text -> Text -> DashboardSourceEntity -> UpdateDashboard
newUpdateDashboard
Text
pAwsAccountId_
Text
pDashboardId_
Text
pName_
DashboardSourceEntity
pSourceEntity_ =
UpdateDashboard' :: Maybe Text
-> Maybe DashboardPublishOptions
-> Maybe Text
-> Maybe Parameters
-> Text
-> Text
-> Text
-> DashboardSourceEntity
-> UpdateDashboard
UpdateDashboard'
{ $sel:themeArn:UpdateDashboard' :: Maybe Text
themeArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:dashboardPublishOptions:UpdateDashboard' :: Maybe DashboardPublishOptions
dashboardPublishOptions = Maybe DashboardPublishOptions
forall a. Maybe a
Prelude.Nothing,
$sel:versionDescription:UpdateDashboard' :: Maybe Text
versionDescription = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:parameters:UpdateDashboard' :: Maybe Parameters
parameters = Maybe Parameters
forall a. Maybe a
Prelude.Nothing,
$sel:awsAccountId:UpdateDashboard' :: Text
awsAccountId = Text
pAwsAccountId_,
$sel:dashboardId:UpdateDashboard' :: Text
dashboardId = Text
pDashboardId_,
$sel:name:UpdateDashboard' :: Text
name = Text
pName_,
$sel:sourceEntity:UpdateDashboard' :: DashboardSourceEntity
sourceEntity = DashboardSourceEntity
pSourceEntity_
}
updateDashboard_themeArn :: Lens.Lens' UpdateDashboard (Prelude.Maybe Prelude.Text)
updateDashboard_themeArn :: (Maybe Text -> f (Maybe Text))
-> UpdateDashboard -> f UpdateDashboard
updateDashboard_themeArn = (UpdateDashboard -> Maybe Text)
-> (UpdateDashboard -> Maybe Text -> UpdateDashboard)
-> Lens UpdateDashboard UpdateDashboard (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboard' {Maybe Text
themeArn :: Maybe Text
$sel:themeArn:UpdateDashboard' :: UpdateDashboard -> Maybe Text
themeArn} -> Maybe Text
themeArn) (\s :: UpdateDashboard
s@UpdateDashboard' {} Maybe Text
a -> UpdateDashboard
s {$sel:themeArn:UpdateDashboard' :: Maybe Text
themeArn = Maybe Text
a} :: UpdateDashboard)
updateDashboard_dashboardPublishOptions :: Lens.Lens' UpdateDashboard (Prelude.Maybe DashboardPublishOptions)
updateDashboard_dashboardPublishOptions :: (Maybe DashboardPublishOptions
-> f (Maybe DashboardPublishOptions))
-> UpdateDashboard -> f UpdateDashboard
updateDashboard_dashboardPublishOptions = (UpdateDashboard -> Maybe DashboardPublishOptions)
-> (UpdateDashboard
-> Maybe DashboardPublishOptions -> UpdateDashboard)
-> Lens
UpdateDashboard
UpdateDashboard
(Maybe DashboardPublishOptions)
(Maybe DashboardPublishOptions)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboard' {Maybe DashboardPublishOptions
dashboardPublishOptions :: Maybe DashboardPublishOptions
$sel:dashboardPublishOptions:UpdateDashboard' :: UpdateDashboard -> Maybe DashboardPublishOptions
dashboardPublishOptions} -> Maybe DashboardPublishOptions
dashboardPublishOptions) (\s :: UpdateDashboard
s@UpdateDashboard' {} Maybe DashboardPublishOptions
a -> UpdateDashboard
s {$sel:dashboardPublishOptions:UpdateDashboard' :: Maybe DashboardPublishOptions
dashboardPublishOptions = Maybe DashboardPublishOptions
a} :: UpdateDashboard)
updateDashboard_versionDescription :: Lens.Lens' UpdateDashboard (Prelude.Maybe Prelude.Text)
updateDashboard_versionDescription :: (Maybe Text -> f (Maybe Text))
-> UpdateDashboard -> f UpdateDashboard
updateDashboard_versionDescription = (UpdateDashboard -> Maybe Text)
-> (UpdateDashboard -> Maybe Text -> UpdateDashboard)
-> Lens UpdateDashboard UpdateDashboard (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboard' {Maybe Text
versionDescription :: Maybe Text
$sel:versionDescription:UpdateDashboard' :: UpdateDashboard -> Maybe Text
versionDescription} -> Maybe Text
versionDescription) (\s :: UpdateDashboard
s@UpdateDashboard' {} Maybe Text
a -> UpdateDashboard
s {$sel:versionDescription:UpdateDashboard' :: Maybe Text
versionDescription = Maybe Text
a} :: UpdateDashboard)
updateDashboard_parameters :: Lens.Lens' UpdateDashboard (Prelude.Maybe Parameters)
updateDashboard_parameters :: (Maybe Parameters -> f (Maybe Parameters))
-> UpdateDashboard -> f UpdateDashboard
updateDashboard_parameters = (UpdateDashboard -> Maybe Parameters)
-> (UpdateDashboard -> Maybe Parameters -> UpdateDashboard)
-> Lens
UpdateDashboard
UpdateDashboard
(Maybe Parameters)
(Maybe Parameters)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboard' {Maybe Parameters
parameters :: Maybe Parameters
$sel:parameters:UpdateDashboard' :: UpdateDashboard -> Maybe Parameters
parameters} -> Maybe Parameters
parameters) (\s :: UpdateDashboard
s@UpdateDashboard' {} Maybe Parameters
a -> UpdateDashboard
s {$sel:parameters:UpdateDashboard' :: Maybe Parameters
parameters = Maybe Parameters
a} :: UpdateDashboard)
updateDashboard_awsAccountId :: Lens.Lens' UpdateDashboard Prelude.Text
updateDashboard_awsAccountId :: (Text -> f Text) -> UpdateDashboard -> f UpdateDashboard
updateDashboard_awsAccountId = (UpdateDashboard -> Text)
-> (UpdateDashboard -> Text -> UpdateDashboard)
-> Lens UpdateDashboard UpdateDashboard Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboard' {Text
awsAccountId :: Text
$sel:awsAccountId:UpdateDashboard' :: UpdateDashboard -> Text
awsAccountId} -> Text
awsAccountId) (\s :: UpdateDashboard
s@UpdateDashboard' {} Text
a -> UpdateDashboard
s {$sel:awsAccountId:UpdateDashboard' :: Text
awsAccountId = Text
a} :: UpdateDashboard)
updateDashboard_dashboardId :: Lens.Lens' UpdateDashboard Prelude.Text
updateDashboard_dashboardId :: (Text -> f Text) -> UpdateDashboard -> f UpdateDashboard
updateDashboard_dashboardId = (UpdateDashboard -> Text)
-> (UpdateDashboard -> Text -> UpdateDashboard)
-> Lens UpdateDashboard UpdateDashboard Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboard' {Text
dashboardId :: Text
$sel:dashboardId:UpdateDashboard' :: UpdateDashboard -> Text
dashboardId} -> Text
dashboardId) (\s :: UpdateDashboard
s@UpdateDashboard' {} Text
a -> UpdateDashboard
s {$sel:dashboardId:UpdateDashboard' :: Text
dashboardId = Text
a} :: UpdateDashboard)
updateDashboard_name :: Lens.Lens' UpdateDashboard Prelude.Text
updateDashboard_name :: (Text -> f Text) -> UpdateDashboard -> f UpdateDashboard
updateDashboard_name = (UpdateDashboard -> Text)
-> (UpdateDashboard -> Text -> UpdateDashboard)
-> Lens UpdateDashboard UpdateDashboard Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboard' {Text
name :: Text
$sel:name:UpdateDashboard' :: UpdateDashboard -> Text
name} -> Text
name) (\s :: UpdateDashboard
s@UpdateDashboard' {} Text
a -> UpdateDashboard
s {$sel:name:UpdateDashboard' :: Text
name = Text
a} :: UpdateDashboard)
updateDashboard_sourceEntity :: Lens.Lens' UpdateDashboard DashboardSourceEntity
updateDashboard_sourceEntity :: (DashboardSourceEntity -> f DashboardSourceEntity)
-> UpdateDashboard -> f UpdateDashboard
updateDashboard_sourceEntity = (UpdateDashboard -> DashboardSourceEntity)
-> (UpdateDashboard -> DashboardSourceEntity -> UpdateDashboard)
-> Lens
UpdateDashboard
UpdateDashboard
DashboardSourceEntity
DashboardSourceEntity
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboard' {DashboardSourceEntity
sourceEntity :: DashboardSourceEntity
$sel:sourceEntity:UpdateDashboard' :: UpdateDashboard -> DashboardSourceEntity
sourceEntity} -> DashboardSourceEntity
sourceEntity) (\s :: UpdateDashboard
s@UpdateDashboard' {} DashboardSourceEntity
a -> UpdateDashboard
s {$sel:sourceEntity:UpdateDashboard' :: DashboardSourceEntity
sourceEntity = DashboardSourceEntity
a} :: UpdateDashboard)
instance Core.AWSRequest UpdateDashboard where
type
AWSResponse UpdateDashboard =
UpdateDashboardResponse
request :: UpdateDashboard -> Request UpdateDashboard
request = Service -> UpdateDashboard -> Request UpdateDashboard
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.putJSON Service
defaultService
response :: Logger
-> Service
-> Proxy UpdateDashboard
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse UpdateDashboard)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse UpdateDashboard))
-> Logger
-> Service
-> Proxy UpdateDashboard
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse UpdateDashboard)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
( \Int
s ResponseHeaders
h Object
x ->
Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe ResourceStatus
-> Maybe Text
-> Maybe Text
-> Int
-> UpdateDashboardResponse
UpdateDashboardResponse'
(Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe ResourceStatus
-> Maybe Text
-> Maybe Text
-> Int
-> UpdateDashboardResponse)
-> Either String (Maybe Text)
-> Either
String
(Maybe Int
-> Maybe Text
-> Maybe ResourceStatus
-> Maybe Text
-> Maybe Text
-> Int
-> UpdateDashboardResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"RequestId")
Either
String
(Maybe Int
-> Maybe Text
-> Maybe ResourceStatus
-> Maybe Text
-> Maybe Text
-> Int
-> UpdateDashboardResponse)
-> Either String (Maybe Int)
-> Either
String
(Maybe Text
-> Maybe ResourceStatus
-> Maybe Text
-> Maybe Text
-> Int
-> UpdateDashboardResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Int)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"Status")
Either
String
(Maybe Text
-> Maybe ResourceStatus
-> Maybe Text
-> Maybe Text
-> Int
-> UpdateDashboardResponse)
-> Either String (Maybe Text)
-> Either
String
(Maybe ResourceStatus
-> Maybe Text -> Maybe Text -> Int -> UpdateDashboardResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"Arn")
Either
String
(Maybe ResourceStatus
-> Maybe Text -> Maybe Text -> Int -> UpdateDashboardResponse)
-> Either String (Maybe ResourceStatus)
-> Either
String (Maybe Text -> Maybe Text -> Int -> UpdateDashboardResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe ResourceStatus)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"CreationStatus")
Either
String (Maybe Text -> Maybe Text -> Int -> UpdateDashboardResponse)
-> Either String (Maybe Text)
-> Either String (Maybe Text -> Int -> UpdateDashboardResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"DashboardId")
Either String (Maybe Text -> Int -> UpdateDashboardResponse)
-> Either String (Maybe Text)
-> Either String (Int -> UpdateDashboardResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"VersionArn")
Either String (Int -> UpdateDashboardResponse)
-> Either String Int -> Either String UpdateDashboardResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Int -> Either String Int
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (Int -> Int
forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
)
instance Prelude.Hashable UpdateDashboard
instance Prelude.NFData UpdateDashboard
instance Core.ToHeaders UpdateDashboard where
toHeaders :: UpdateDashboard -> ResponseHeaders
toHeaders =
ResponseHeaders -> UpdateDashboard -> 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.0" ::
Prelude.ByteString
)
]
)
instance Core.ToJSON UpdateDashboard where
toJSON :: UpdateDashboard -> Value
toJSON UpdateDashboard' {Maybe Text
Maybe DashboardPublishOptions
Maybe Parameters
Text
DashboardSourceEntity
sourceEntity :: DashboardSourceEntity
name :: Text
dashboardId :: Text
awsAccountId :: Text
parameters :: Maybe Parameters
versionDescription :: Maybe Text
dashboardPublishOptions :: Maybe DashboardPublishOptions
themeArn :: Maybe Text
$sel:sourceEntity:UpdateDashboard' :: UpdateDashboard -> DashboardSourceEntity
$sel:name:UpdateDashboard' :: UpdateDashboard -> Text
$sel:dashboardId:UpdateDashboard' :: UpdateDashboard -> Text
$sel:awsAccountId:UpdateDashboard' :: UpdateDashboard -> Text
$sel:parameters:UpdateDashboard' :: UpdateDashboard -> Maybe Parameters
$sel:versionDescription:UpdateDashboard' :: UpdateDashboard -> Maybe Text
$sel:dashboardPublishOptions:UpdateDashboard' :: UpdateDashboard -> Maybe DashboardPublishOptions
$sel:themeArn:UpdateDashboard' :: UpdateDashboard -> Maybe Text
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"ThemeArn" 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
themeArn,
(Text
"DashboardPublishOptions" Text -> DashboardPublishOptions -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(DashboardPublishOptions -> Pair)
-> Maybe DashboardPublishOptions -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe DashboardPublishOptions
dashboardPublishOptions,
(Text
"VersionDescription" 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
versionDescription,
(Text
"Parameters" Text -> Parameters -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Parameters -> Pair) -> Maybe Parameters -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Parameters
parameters,
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"Name" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
name),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"SourceEntity" Text -> DashboardSourceEntity -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= DashboardSourceEntity
sourceEntity)
]
)
instance Core.ToPath UpdateDashboard where
toPath :: UpdateDashboard -> ByteString
toPath UpdateDashboard' {Maybe Text
Maybe DashboardPublishOptions
Maybe Parameters
Text
DashboardSourceEntity
sourceEntity :: DashboardSourceEntity
name :: Text
dashboardId :: Text
awsAccountId :: Text
parameters :: Maybe Parameters
versionDescription :: Maybe Text
dashboardPublishOptions :: Maybe DashboardPublishOptions
themeArn :: Maybe Text
$sel:sourceEntity:UpdateDashboard' :: UpdateDashboard -> DashboardSourceEntity
$sel:name:UpdateDashboard' :: UpdateDashboard -> Text
$sel:dashboardId:UpdateDashboard' :: UpdateDashboard -> Text
$sel:awsAccountId:UpdateDashboard' :: UpdateDashboard -> Text
$sel:parameters:UpdateDashboard' :: UpdateDashboard -> Maybe Parameters
$sel:versionDescription:UpdateDashboard' :: UpdateDashboard -> Maybe Text
$sel:dashboardPublishOptions:UpdateDashboard' :: UpdateDashboard -> Maybe DashboardPublishOptions
$sel:themeArn:UpdateDashboard' :: UpdateDashboard -> Maybe Text
..} =
[ByteString] -> ByteString
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"/accounts/",
Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
awsAccountId,
ByteString
"/dashboards/",
Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
dashboardId
]
instance Core.ToQuery UpdateDashboard where
toQuery :: UpdateDashboard -> QueryString
toQuery = QueryString -> UpdateDashboard -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data UpdateDashboardResponse = UpdateDashboardResponse'
{
UpdateDashboardResponse -> Maybe Text
requestId :: Prelude.Maybe Prelude.Text,
UpdateDashboardResponse -> Maybe Int
status :: Prelude.Maybe Prelude.Int,
UpdateDashboardResponse -> Maybe Text
arn :: Prelude.Maybe Prelude.Text,
UpdateDashboardResponse -> Maybe ResourceStatus
creationStatus :: Prelude.Maybe ResourceStatus,
UpdateDashboardResponse -> Maybe Text
dashboardId :: Prelude.Maybe Prelude.Text,
UpdateDashboardResponse -> Maybe Text
versionArn :: Prelude.Maybe Prelude.Text,
UpdateDashboardResponse -> Int
httpStatus :: Prelude.Int
}
deriving (UpdateDashboardResponse -> UpdateDashboardResponse -> Bool
(UpdateDashboardResponse -> UpdateDashboardResponse -> Bool)
-> (UpdateDashboardResponse -> UpdateDashboardResponse -> Bool)
-> Eq UpdateDashboardResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateDashboardResponse -> UpdateDashboardResponse -> Bool
$c/= :: UpdateDashboardResponse -> UpdateDashboardResponse -> Bool
== :: UpdateDashboardResponse -> UpdateDashboardResponse -> Bool
$c== :: UpdateDashboardResponse -> UpdateDashboardResponse -> Bool
Prelude.Eq, ReadPrec [UpdateDashboardResponse]
ReadPrec UpdateDashboardResponse
Int -> ReadS UpdateDashboardResponse
ReadS [UpdateDashboardResponse]
(Int -> ReadS UpdateDashboardResponse)
-> ReadS [UpdateDashboardResponse]
-> ReadPrec UpdateDashboardResponse
-> ReadPrec [UpdateDashboardResponse]
-> Read UpdateDashboardResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateDashboardResponse]
$creadListPrec :: ReadPrec [UpdateDashboardResponse]
readPrec :: ReadPrec UpdateDashboardResponse
$creadPrec :: ReadPrec UpdateDashboardResponse
readList :: ReadS [UpdateDashboardResponse]
$creadList :: ReadS [UpdateDashboardResponse]
readsPrec :: Int -> ReadS UpdateDashboardResponse
$creadsPrec :: Int -> ReadS UpdateDashboardResponse
Prelude.Read, Int -> UpdateDashboardResponse -> ShowS
[UpdateDashboardResponse] -> ShowS
UpdateDashboardResponse -> String
(Int -> UpdateDashboardResponse -> ShowS)
-> (UpdateDashboardResponse -> String)
-> ([UpdateDashboardResponse] -> ShowS)
-> Show UpdateDashboardResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateDashboardResponse] -> ShowS
$cshowList :: [UpdateDashboardResponse] -> ShowS
show :: UpdateDashboardResponse -> String
$cshow :: UpdateDashboardResponse -> String
showsPrec :: Int -> UpdateDashboardResponse -> ShowS
$cshowsPrec :: Int -> UpdateDashboardResponse -> ShowS
Prelude.Show, (forall x.
UpdateDashboardResponse -> Rep UpdateDashboardResponse x)
-> (forall x.
Rep UpdateDashboardResponse x -> UpdateDashboardResponse)
-> Generic UpdateDashboardResponse
forall x. Rep UpdateDashboardResponse x -> UpdateDashboardResponse
forall x. UpdateDashboardResponse -> Rep UpdateDashboardResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UpdateDashboardResponse x -> UpdateDashboardResponse
$cfrom :: forall x. UpdateDashboardResponse -> Rep UpdateDashboardResponse x
Prelude.Generic)
newUpdateDashboardResponse ::
Prelude.Int ->
UpdateDashboardResponse
newUpdateDashboardResponse :: Int -> UpdateDashboardResponse
newUpdateDashboardResponse Int
pHttpStatus_ =
UpdateDashboardResponse' :: Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe ResourceStatus
-> Maybe Text
-> Maybe Text
-> Int
-> UpdateDashboardResponse
UpdateDashboardResponse'
{ $sel:requestId:UpdateDashboardResponse' :: Maybe Text
requestId =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:status:UpdateDashboardResponse' :: Maybe Int
status = Maybe Int
forall a. Maybe a
Prelude.Nothing,
$sel:arn:UpdateDashboardResponse' :: Maybe Text
arn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:creationStatus:UpdateDashboardResponse' :: Maybe ResourceStatus
creationStatus = Maybe ResourceStatus
forall a. Maybe a
Prelude.Nothing,
$sel:dashboardId:UpdateDashboardResponse' :: Maybe Text
dashboardId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:versionArn:UpdateDashboardResponse' :: Maybe Text
versionArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:UpdateDashboardResponse' :: Int
httpStatus = Int
pHttpStatus_
}
updateDashboardResponse_requestId :: Lens.Lens' UpdateDashboardResponse (Prelude.Maybe Prelude.Text)
updateDashboardResponse_requestId :: (Maybe Text -> f (Maybe Text))
-> UpdateDashboardResponse -> f UpdateDashboardResponse
updateDashboardResponse_requestId = (UpdateDashboardResponse -> Maybe Text)
-> (UpdateDashboardResponse
-> Maybe Text -> UpdateDashboardResponse)
-> Lens
UpdateDashboardResponse
UpdateDashboardResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboardResponse' {Maybe Text
requestId :: Maybe Text
$sel:requestId:UpdateDashboardResponse' :: UpdateDashboardResponse -> Maybe Text
requestId} -> Maybe Text
requestId) (\s :: UpdateDashboardResponse
s@UpdateDashboardResponse' {} Maybe Text
a -> UpdateDashboardResponse
s {$sel:requestId:UpdateDashboardResponse' :: Maybe Text
requestId = Maybe Text
a} :: UpdateDashboardResponse)
updateDashboardResponse_status :: Lens.Lens' UpdateDashboardResponse (Prelude.Maybe Prelude.Int)
updateDashboardResponse_status :: (Maybe Int -> f (Maybe Int))
-> UpdateDashboardResponse -> f UpdateDashboardResponse
updateDashboardResponse_status = (UpdateDashboardResponse -> Maybe Int)
-> (UpdateDashboardResponse
-> Maybe Int -> UpdateDashboardResponse)
-> Lens
UpdateDashboardResponse
UpdateDashboardResponse
(Maybe Int)
(Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboardResponse' {Maybe Int
status :: Maybe Int
$sel:status:UpdateDashboardResponse' :: UpdateDashboardResponse -> Maybe Int
status} -> Maybe Int
status) (\s :: UpdateDashboardResponse
s@UpdateDashboardResponse' {} Maybe Int
a -> UpdateDashboardResponse
s {$sel:status:UpdateDashboardResponse' :: Maybe Int
status = Maybe Int
a} :: UpdateDashboardResponse)
updateDashboardResponse_arn :: Lens.Lens' UpdateDashboardResponse (Prelude.Maybe Prelude.Text)
updateDashboardResponse_arn :: (Maybe Text -> f (Maybe Text))
-> UpdateDashboardResponse -> f UpdateDashboardResponse
updateDashboardResponse_arn = (UpdateDashboardResponse -> Maybe Text)
-> (UpdateDashboardResponse
-> Maybe Text -> UpdateDashboardResponse)
-> Lens
UpdateDashboardResponse
UpdateDashboardResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboardResponse' {Maybe Text
arn :: Maybe Text
$sel:arn:UpdateDashboardResponse' :: UpdateDashboardResponse -> Maybe Text
arn} -> Maybe Text
arn) (\s :: UpdateDashboardResponse
s@UpdateDashboardResponse' {} Maybe Text
a -> UpdateDashboardResponse
s {$sel:arn:UpdateDashboardResponse' :: Maybe Text
arn = Maybe Text
a} :: UpdateDashboardResponse)
updateDashboardResponse_creationStatus :: Lens.Lens' UpdateDashboardResponse (Prelude.Maybe ResourceStatus)
updateDashboardResponse_creationStatus :: (Maybe ResourceStatus -> f (Maybe ResourceStatus))
-> UpdateDashboardResponse -> f UpdateDashboardResponse
updateDashboardResponse_creationStatus = (UpdateDashboardResponse -> Maybe ResourceStatus)
-> (UpdateDashboardResponse
-> Maybe ResourceStatus -> UpdateDashboardResponse)
-> Lens
UpdateDashboardResponse
UpdateDashboardResponse
(Maybe ResourceStatus)
(Maybe ResourceStatus)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboardResponse' {Maybe ResourceStatus
creationStatus :: Maybe ResourceStatus
$sel:creationStatus:UpdateDashboardResponse' :: UpdateDashboardResponse -> Maybe ResourceStatus
creationStatus} -> Maybe ResourceStatus
creationStatus) (\s :: UpdateDashboardResponse
s@UpdateDashboardResponse' {} Maybe ResourceStatus
a -> UpdateDashboardResponse
s {$sel:creationStatus:UpdateDashboardResponse' :: Maybe ResourceStatus
creationStatus = Maybe ResourceStatus
a} :: UpdateDashboardResponse)
updateDashboardResponse_dashboardId :: Lens.Lens' UpdateDashboardResponse (Prelude.Maybe Prelude.Text)
updateDashboardResponse_dashboardId :: (Maybe Text -> f (Maybe Text))
-> UpdateDashboardResponse -> f UpdateDashboardResponse
updateDashboardResponse_dashboardId = (UpdateDashboardResponse -> Maybe Text)
-> (UpdateDashboardResponse
-> Maybe Text -> UpdateDashboardResponse)
-> Lens
UpdateDashboardResponse
UpdateDashboardResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboardResponse' {Maybe Text
dashboardId :: Maybe Text
$sel:dashboardId:UpdateDashboardResponse' :: UpdateDashboardResponse -> Maybe Text
dashboardId} -> Maybe Text
dashboardId) (\s :: UpdateDashboardResponse
s@UpdateDashboardResponse' {} Maybe Text
a -> UpdateDashboardResponse
s {$sel:dashboardId:UpdateDashboardResponse' :: Maybe Text
dashboardId = Maybe Text
a} :: UpdateDashboardResponse)
updateDashboardResponse_versionArn :: Lens.Lens' UpdateDashboardResponse (Prelude.Maybe Prelude.Text)
updateDashboardResponse_versionArn :: (Maybe Text -> f (Maybe Text))
-> UpdateDashboardResponse -> f UpdateDashboardResponse
updateDashboardResponse_versionArn = (UpdateDashboardResponse -> Maybe Text)
-> (UpdateDashboardResponse
-> Maybe Text -> UpdateDashboardResponse)
-> Lens
UpdateDashboardResponse
UpdateDashboardResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboardResponse' {Maybe Text
versionArn :: Maybe Text
$sel:versionArn:UpdateDashboardResponse' :: UpdateDashboardResponse -> Maybe Text
versionArn} -> Maybe Text
versionArn) (\s :: UpdateDashboardResponse
s@UpdateDashboardResponse' {} Maybe Text
a -> UpdateDashboardResponse
s {$sel:versionArn:UpdateDashboardResponse' :: Maybe Text
versionArn = Maybe Text
a} :: UpdateDashboardResponse)
updateDashboardResponse_httpStatus :: Lens.Lens' UpdateDashboardResponse Prelude.Int
updateDashboardResponse_httpStatus :: (Int -> f Int)
-> UpdateDashboardResponse -> f UpdateDashboardResponse
updateDashboardResponse_httpStatus = (UpdateDashboardResponse -> Int)
-> (UpdateDashboardResponse -> Int -> UpdateDashboardResponse)
-> Lens UpdateDashboardResponse UpdateDashboardResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboardResponse' {Int
httpStatus :: Int
$sel:httpStatus:UpdateDashboardResponse' :: UpdateDashboardResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: UpdateDashboardResponse
s@UpdateDashboardResponse' {} Int
a -> UpdateDashboardResponse
s {$sel:httpStatus:UpdateDashboardResponse' :: Int
httpStatus = Int
a} :: UpdateDashboardResponse)
instance Prelude.NFData UpdateDashboardResponse