{-# 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.UpdateDashboardPermissions
(
UpdateDashboardPermissions (..),
newUpdateDashboardPermissions,
updateDashboardPermissions_revokePermissions,
updateDashboardPermissions_grantPermissions,
updateDashboardPermissions_awsAccountId,
updateDashboardPermissions_dashboardId,
UpdateDashboardPermissionsResponse (..),
newUpdateDashboardPermissionsResponse,
updateDashboardPermissionsResponse_requestId,
updateDashboardPermissionsResponse_dashboardId,
updateDashboardPermissionsResponse_permissions,
updateDashboardPermissionsResponse_dashboardArn,
updateDashboardPermissionsResponse_status,
)
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 UpdateDashboardPermissions = UpdateDashboardPermissions'
{
UpdateDashboardPermissions -> Maybe [ResourcePermission]
revokePermissions :: Prelude.Maybe [ResourcePermission],
UpdateDashboardPermissions -> Maybe [ResourcePermission]
grantPermissions :: Prelude.Maybe [ResourcePermission],
UpdateDashboardPermissions -> Text
awsAccountId :: Prelude.Text,
UpdateDashboardPermissions -> Text
dashboardId :: Prelude.Text
}
deriving (UpdateDashboardPermissions -> UpdateDashboardPermissions -> Bool
(UpdateDashboardPermissions -> UpdateDashboardPermissions -> Bool)
-> (UpdateDashboardPermissions
-> UpdateDashboardPermissions -> Bool)
-> Eq UpdateDashboardPermissions
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateDashboardPermissions -> UpdateDashboardPermissions -> Bool
$c/= :: UpdateDashboardPermissions -> UpdateDashboardPermissions -> Bool
== :: UpdateDashboardPermissions -> UpdateDashboardPermissions -> Bool
$c== :: UpdateDashboardPermissions -> UpdateDashboardPermissions -> Bool
Prelude.Eq, ReadPrec [UpdateDashboardPermissions]
ReadPrec UpdateDashboardPermissions
Int -> ReadS UpdateDashboardPermissions
ReadS [UpdateDashboardPermissions]
(Int -> ReadS UpdateDashboardPermissions)
-> ReadS [UpdateDashboardPermissions]
-> ReadPrec UpdateDashboardPermissions
-> ReadPrec [UpdateDashboardPermissions]
-> Read UpdateDashboardPermissions
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateDashboardPermissions]
$creadListPrec :: ReadPrec [UpdateDashboardPermissions]
readPrec :: ReadPrec UpdateDashboardPermissions
$creadPrec :: ReadPrec UpdateDashboardPermissions
readList :: ReadS [UpdateDashboardPermissions]
$creadList :: ReadS [UpdateDashboardPermissions]
readsPrec :: Int -> ReadS UpdateDashboardPermissions
$creadsPrec :: Int -> ReadS UpdateDashboardPermissions
Prelude.Read, Int -> UpdateDashboardPermissions -> ShowS
[UpdateDashboardPermissions] -> ShowS
UpdateDashboardPermissions -> String
(Int -> UpdateDashboardPermissions -> ShowS)
-> (UpdateDashboardPermissions -> String)
-> ([UpdateDashboardPermissions] -> ShowS)
-> Show UpdateDashboardPermissions
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateDashboardPermissions] -> ShowS
$cshowList :: [UpdateDashboardPermissions] -> ShowS
show :: UpdateDashboardPermissions -> String
$cshow :: UpdateDashboardPermissions -> String
showsPrec :: Int -> UpdateDashboardPermissions -> ShowS
$cshowsPrec :: Int -> UpdateDashboardPermissions -> ShowS
Prelude.Show, (forall x.
UpdateDashboardPermissions -> Rep UpdateDashboardPermissions x)
-> (forall x.
Rep UpdateDashboardPermissions x -> UpdateDashboardPermissions)
-> Generic UpdateDashboardPermissions
forall x.
Rep UpdateDashboardPermissions x -> UpdateDashboardPermissions
forall x.
UpdateDashboardPermissions -> Rep UpdateDashboardPermissions x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep UpdateDashboardPermissions x -> UpdateDashboardPermissions
$cfrom :: forall x.
UpdateDashboardPermissions -> Rep UpdateDashboardPermissions x
Prelude.Generic)
newUpdateDashboardPermissions ::
Prelude.Text ->
Prelude.Text ->
UpdateDashboardPermissions
newUpdateDashboardPermissions :: Text -> Text -> UpdateDashboardPermissions
newUpdateDashboardPermissions
Text
pAwsAccountId_
Text
pDashboardId_ =
UpdateDashboardPermissions' :: Maybe [ResourcePermission]
-> Maybe [ResourcePermission]
-> Text
-> Text
-> UpdateDashboardPermissions
UpdateDashboardPermissions'
{ $sel:revokePermissions:UpdateDashboardPermissions' :: Maybe [ResourcePermission]
revokePermissions =
Maybe [ResourcePermission]
forall a. Maybe a
Prelude.Nothing,
$sel:grantPermissions:UpdateDashboardPermissions' :: Maybe [ResourcePermission]
grantPermissions = Maybe [ResourcePermission]
forall a. Maybe a
Prelude.Nothing,
$sel:awsAccountId:UpdateDashboardPermissions' :: Text
awsAccountId = Text
pAwsAccountId_,
$sel:dashboardId:UpdateDashboardPermissions' :: Text
dashboardId = Text
pDashboardId_
}
updateDashboardPermissions_revokePermissions :: Lens.Lens' UpdateDashboardPermissions (Prelude.Maybe [ResourcePermission])
updateDashboardPermissions_revokePermissions :: (Maybe [ResourcePermission] -> f (Maybe [ResourcePermission]))
-> UpdateDashboardPermissions -> f UpdateDashboardPermissions
updateDashboardPermissions_revokePermissions = (UpdateDashboardPermissions -> Maybe [ResourcePermission])
-> (UpdateDashboardPermissions
-> Maybe [ResourcePermission] -> UpdateDashboardPermissions)
-> Lens
UpdateDashboardPermissions
UpdateDashboardPermissions
(Maybe [ResourcePermission])
(Maybe [ResourcePermission])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboardPermissions' {Maybe [ResourcePermission]
revokePermissions :: Maybe [ResourcePermission]
$sel:revokePermissions:UpdateDashboardPermissions' :: UpdateDashboardPermissions -> Maybe [ResourcePermission]
revokePermissions} -> Maybe [ResourcePermission]
revokePermissions) (\s :: UpdateDashboardPermissions
s@UpdateDashboardPermissions' {} Maybe [ResourcePermission]
a -> UpdateDashboardPermissions
s {$sel:revokePermissions:UpdateDashboardPermissions' :: Maybe [ResourcePermission]
revokePermissions = Maybe [ResourcePermission]
a} :: UpdateDashboardPermissions) ((Maybe [ResourcePermission] -> f (Maybe [ResourcePermission]))
-> UpdateDashboardPermissions -> f UpdateDashboardPermissions)
-> ((Maybe [ResourcePermission] -> f (Maybe [ResourcePermission]))
-> Maybe [ResourcePermission] -> f (Maybe [ResourcePermission]))
-> (Maybe [ResourcePermission] -> f (Maybe [ResourcePermission]))
-> UpdateDashboardPermissions
-> f UpdateDashboardPermissions
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
[ResourcePermission]
[ResourcePermission]
[ResourcePermission]
[ResourcePermission]
-> Iso
(Maybe [ResourcePermission])
(Maybe [ResourcePermission])
(Maybe [ResourcePermission])
(Maybe [ResourcePermission])
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
[ResourcePermission]
[ResourcePermission]
[ResourcePermission]
[ResourcePermission]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
updateDashboardPermissions_grantPermissions :: Lens.Lens' UpdateDashboardPermissions (Prelude.Maybe [ResourcePermission])
updateDashboardPermissions_grantPermissions :: (Maybe [ResourcePermission] -> f (Maybe [ResourcePermission]))
-> UpdateDashboardPermissions -> f UpdateDashboardPermissions
updateDashboardPermissions_grantPermissions = (UpdateDashboardPermissions -> Maybe [ResourcePermission])
-> (UpdateDashboardPermissions
-> Maybe [ResourcePermission] -> UpdateDashboardPermissions)
-> Lens
UpdateDashboardPermissions
UpdateDashboardPermissions
(Maybe [ResourcePermission])
(Maybe [ResourcePermission])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboardPermissions' {Maybe [ResourcePermission]
grantPermissions :: Maybe [ResourcePermission]
$sel:grantPermissions:UpdateDashboardPermissions' :: UpdateDashboardPermissions -> Maybe [ResourcePermission]
grantPermissions} -> Maybe [ResourcePermission]
grantPermissions) (\s :: UpdateDashboardPermissions
s@UpdateDashboardPermissions' {} Maybe [ResourcePermission]
a -> UpdateDashboardPermissions
s {$sel:grantPermissions:UpdateDashboardPermissions' :: Maybe [ResourcePermission]
grantPermissions = Maybe [ResourcePermission]
a} :: UpdateDashboardPermissions) ((Maybe [ResourcePermission] -> f (Maybe [ResourcePermission]))
-> UpdateDashboardPermissions -> f UpdateDashboardPermissions)
-> ((Maybe [ResourcePermission] -> f (Maybe [ResourcePermission]))
-> Maybe [ResourcePermission] -> f (Maybe [ResourcePermission]))
-> (Maybe [ResourcePermission] -> f (Maybe [ResourcePermission]))
-> UpdateDashboardPermissions
-> f UpdateDashboardPermissions
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
[ResourcePermission]
[ResourcePermission]
[ResourcePermission]
[ResourcePermission]
-> Iso
(Maybe [ResourcePermission])
(Maybe [ResourcePermission])
(Maybe [ResourcePermission])
(Maybe [ResourcePermission])
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
[ResourcePermission]
[ResourcePermission]
[ResourcePermission]
[ResourcePermission]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
updateDashboardPermissions_awsAccountId :: Lens.Lens' UpdateDashboardPermissions Prelude.Text
updateDashboardPermissions_awsAccountId :: (Text -> f Text)
-> UpdateDashboardPermissions -> f UpdateDashboardPermissions
updateDashboardPermissions_awsAccountId = (UpdateDashboardPermissions -> Text)
-> (UpdateDashboardPermissions
-> Text -> UpdateDashboardPermissions)
-> Lens
UpdateDashboardPermissions UpdateDashboardPermissions Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboardPermissions' {Text
awsAccountId :: Text
$sel:awsAccountId:UpdateDashboardPermissions' :: UpdateDashboardPermissions -> Text
awsAccountId} -> Text
awsAccountId) (\s :: UpdateDashboardPermissions
s@UpdateDashboardPermissions' {} Text
a -> UpdateDashboardPermissions
s {$sel:awsAccountId:UpdateDashboardPermissions' :: Text
awsAccountId = Text
a} :: UpdateDashboardPermissions)
updateDashboardPermissions_dashboardId :: Lens.Lens' UpdateDashboardPermissions Prelude.Text
updateDashboardPermissions_dashboardId :: (Text -> f Text)
-> UpdateDashboardPermissions -> f UpdateDashboardPermissions
updateDashboardPermissions_dashboardId = (UpdateDashboardPermissions -> Text)
-> (UpdateDashboardPermissions
-> Text -> UpdateDashboardPermissions)
-> Lens
UpdateDashboardPermissions UpdateDashboardPermissions Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboardPermissions' {Text
dashboardId :: Text
$sel:dashboardId:UpdateDashboardPermissions' :: UpdateDashboardPermissions -> Text
dashboardId} -> Text
dashboardId) (\s :: UpdateDashboardPermissions
s@UpdateDashboardPermissions' {} Text
a -> UpdateDashboardPermissions
s {$sel:dashboardId:UpdateDashboardPermissions' :: Text
dashboardId = Text
a} :: UpdateDashboardPermissions)
instance Core.AWSRequest UpdateDashboardPermissions where
type
AWSResponse UpdateDashboardPermissions =
UpdateDashboardPermissionsResponse
request :: UpdateDashboardPermissions -> Request UpdateDashboardPermissions
request = Service
-> UpdateDashboardPermissions -> Request UpdateDashboardPermissions
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.putJSON Service
defaultService
response :: Logger
-> Service
-> Proxy UpdateDashboardPermissions
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse UpdateDashboardPermissions)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse UpdateDashboardPermissions))
-> Logger
-> Service
-> Proxy UpdateDashboardPermissions
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse UpdateDashboardPermissions)))
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 Text
-> Maybe (NonEmpty ResourcePermission)
-> Maybe Text
-> Int
-> UpdateDashboardPermissionsResponse
UpdateDashboardPermissionsResponse'
(Maybe Text
-> Maybe Text
-> Maybe (NonEmpty ResourcePermission)
-> Maybe Text
-> Int
-> UpdateDashboardPermissionsResponse)
-> Either String (Maybe Text)
-> Either
String
(Maybe Text
-> Maybe (NonEmpty ResourcePermission)
-> Maybe Text
-> Int
-> UpdateDashboardPermissionsResponse)
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 Text
-> Maybe (NonEmpty ResourcePermission)
-> Maybe Text
-> Int
-> UpdateDashboardPermissionsResponse)
-> Either String (Maybe Text)
-> Either
String
(Maybe (NonEmpty ResourcePermission)
-> Maybe Text -> Int -> UpdateDashboardPermissionsResponse)
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 (NonEmpty ResourcePermission)
-> Maybe Text -> Int -> UpdateDashboardPermissionsResponse)
-> Either String (Maybe (NonEmpty ResourcePermission))
-> Either
String (Maybe Text -> Int -> UpdateDashboardPermissionsResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object
-> Text -> Either String (Maybe (NonEmpty ResourcePermission))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"Permissions")
Either
String (Maybe Text -> Int -> UpdateDashboardPermissionsResponse)
-> Either String (Maybe Text)
-> Either String (Int -> UpdateDashboardPermissionsResponse)
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
"DashboardArn")
Either String (Int -> UpdateDashboardPermissionsResponse)
-> Either String Int
-> Either String UpdateDashboardPermissionsResponse
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 UpdateDashboardPermissions
instance Prelude.NFData UpdateDashboardPermissions
instance Core.ToHeaders UpdateDashboardPermissions where
toHeaders :: UpdateDashboardPermissions -> ResponseHeaders
toHeaders =
ResponseHeaders -> UpdateDashboardPermissions -> 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 UpdateDashboardPermissions where
toJSON :: UpdateDashboardPermissions -> Value
toJSON UpdateDashboardPermissions' {Maybe [ResourcePermission]
Text
dashboardId :: Text
awsAccountId :: Text
grantPermissions :: Maybe [ResourcePermission]
revokePermissions :: Maybe [ResourcePermission]
$sel:dashboardId:UpdateDashboardPermissions' :: UpdateDashboardPermissions -> Text
$sel:awsAccountId:UpdateDashboardPermissions' :: UpdateDashboardPermissions -> Text
$sel:grantPermissions:UpdateDashboardPermissions' :: UpdateDashboardPermissions -> Maybe [ResourcePermission]
$sel:revokePermissions:UpdateDashboardPermissions' :: UpdateDashboardPermissions -> Maybe [ResourcePermission]
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"RevokePermissions" Text -> [ResourcePermission] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
([ResourcePermission] -> Pair)
-> Maybe [ResourcePermission] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [ResourcePermission]
revokePermissions,
(Text
"GrantPermissions" Text -> [ResourcePermission] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
([ResourcePermission] -> Pair)
-> Maybe [ResourcePermission] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [ResourcePermission]
grantPermissions
]
)
instance Core.ToPath UpdateDashboardPermissions where
toPath :: UpdateDashboardPermissions -> ByteString
toPath UpdateDashboardPermissions' {Maybe [ResourcePermission]
Text
dashboardId :: Text
awsAccountId :: Text
grantPermissions :: Maybe [ResourcePermission]
revokePermissions :: Maybe [ResourcePermission]
$sel:dashboardId:UpdateDashboardPermissions' :: UpdateDashboardPermissions -> Text
$sel:awsAccountId:UpdateDashboardPermissions' :: UpdateDashboardPermissions -> Text
$sel:grantPermissions:UpdateDashboardPermissions' :: UpdateDashboardPermissions -> Maybe [ResourcePermission]
$sel:revokePermissions:UpdateDashboardPermissions' :: UpdateDashboardPermissions -> Maybe [ResourcePermission]
..} =
[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,
ByteString
"/permissions"
]
instance Core.ToQuery UpdateDashboardPermissions where
toQuery :: UpdateDashboardPermissions -> QueryString
toQuery = QueryString -> UpdateDashboardPermissions -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data UpdateDashboardPermissionsResponse = UpdateDashboardPermissionsResponse'
{
UpdateDashboardPermissionsResponse -> Maybe Text
requestId :: Prelude.Maybe Prelude.Text,
UpdateDashboardPermissionsResponse -> Maybe Text
dashboardId :: Prelude.Maybe Prelude.Text,
UpdateDashboardPermissionsResponse
-> Maybe (NonEmpty ResourcePermission)
permissions :: Prelude.Maybe (Prelude.NonEmpty ResourcePermission),
UpdateDashboardPermissionsResponse -> Maybe Text
dashboardArn :: Prelude.Maybe Prelude.Text,
UpdateDashboardPermissionsResponse -> Int
status :: Prelude.Int
}
deriving (UpdateDashboardPermissionsResponse
-> UpdateDashboardPermissionsResponse -> Bool
(UpdateDashboardPermissionsResponse
-> UpdateDashboardPermissionsResponse -> Bool)
-> (UpdateDashboardPermissionsResponse
-> UpdateDashboardPermissionsResponse -> Bool)
-> Eq UpdateDashboardPermissionsResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateDashboardPermissionsResponse
-> UpdateDashboardPermissionsResponse -> Bool
$c/= :: UpdateDashboardPermissionsResponse
-> UpdateDashboardPermissionsResponse -> Bool
== :: UpdateDashboardPermissionsResponse
-> UpdateDashboardPermissionsResponse -> Bool
$c== :: UpdateDashboardPermissionsResponse
-> UpdateDashboardPermissionsResponse -> Bool
Prelude.Eq, ReadPrec [UpdateDashboardPermissionsResponse]
ReadPrec UpdateDashboardPermissionsResponse
Int -> ReadS UpdateDashboardPermissionsResponse
ReadS [UpdateDashboardPermissionsResponse]
(Int -> ReadS UpdateDashboardPermissionsResponse)
-> ReadS [UpdateDashboardPermissionsResponse]
-> ReadPrec UpdateDashboardPermissionsResponse
-> ReadPrec [UpdateDashboardPermissionsResponse]
-> Read UpdateDashboardPermissionsResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateDashboardPermissionsResponse]
$creadListPrec :: ReadPrec [UpdateDashboardPermissionsResponse]
readPrec :: ReadPrec UpdateDashboardPermissionsResponse
$creadPrec :: ReadPrec UpdateDashboardPermissionsResponse
readList :: ReadS [UpdateDashboardPermissionsResponse]
$creadList :: ReadS [UpdateDashboardPermissionsResponse]
readsPrec :: Int -> ReadS UpdateDashboardPermissionsResponse
$creadsPrec :: Int -> ReadS UpdateDashboardPermissionsResponse
Prelude.Read, Int -> UpdateDashboardPermissionsResponse -> ShowS
[UpdateDashboardPermissionsResponse] -> ShowS
UpdateDashboardPermissionsResponse -> String
(Int -> UpdateDashboardPermissionsResponse -> ShowS)
-> (UpdateDashboardPermissionsResponse -> String)
-> ([UpdateDashboardPermissionsResponse] -> ShowS)
-> Show UpdateDashboardPermissionsResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateDashboardPermissionsResponse] -> ShowS
$cshowList :: [UpdateDashboardPermissionsResponse] -> ShowS
show :: UpdateDashboardPermissionsResponse -> String
$cshow :: UpdateDashboardPermissionsResponse -> String
showsPrec :: Int -> UpdateDashboardPermissionsResponse -> ShowS
$cshowsPrec :: Int -> UpdateDashboardPermissionsResponse -> ShowS
Prelude.Show, (forall x.
UpdateDashboardPermissionsResponse
-> Rep UpdateDashboardPermissionsResponse x)
-> (forall x.
Rep UpdateDashboardPermissionsResponse x
-> UpdateDashboardPermissionsResponse)
-> Generic UpdateDashboardPermissionsResponse
forall x.
Rep UpdateDashboardPermissionsResponse x
-> UpdateDashboardPermissionsResponse
forall x.
UpdateDashboardPermissionsResponse
-> Rep UpdateDashboardPermissionsResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep UpdateDashboardPermissionsResponse x
-> UpdateDashboardPermissionsResponse
$cfrom :: forall x.
UpdateDashboardPermissionsResponse
-> Rep UpdateDashboardPermissionsResponse x
Prelude.Generic)
newUpdateDashboardPermissionsResponse ::
Prelude.Int ->
UpdateDashboardPermissionsResponse
newUpdateDashboardPermissionsResponse :: Int -> UpdateDashboardPermissionsResponse
newUpdateDashboardPermissionsResponse Int
pStatus_ =
UpdateDashboardPermissionsResponse' :: Maybe Text
-> Maybe Text
-> Maybe (NonEmpty ResourcePermission)
-> Maybe Text
-> Int
-> UpdateDashboardPermissionsResponse
UpdateDashboardPermissionsResponse'
{ $sel:requestId:UpdateDashboardPermissionsResponse' :: Maybe Text
requestId =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:dashboardId:UpdateDashboardPermissionsResponse' :: Maybe Text
dashboardId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:permissions:UpdateDashboardPermissionsResponse' :: Maybe (NonEmpty ResourcePermission)
permissions = Maybe (NonEmpty ResourcePermission)
forall a. Maybe a
Prelude.Nothing,
$sel:dashboardArn:UpdateDashboardPermissionsResponse' :: Maybe Text
dashboardArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:status:UpdateDashboardPermissionsResponse' :: Int
status = Int
pStatus_
}
updateDashboardPermissionsResponse_requestId :: Lens.Lens' UpdateDashboardPermissionsResponse (Prelude.Maybe Prelude.Text)
updateDashboardPermissionsResponse_requestId :: (Maybe Text -> f (Maybe Text))
-> UpdateDashboardPermissionsResponse
-> f UpdateDashboardPermissionsResponse
updateDashboardPermissionsResponse_requestId = (UpdateDashboardPermissionsResponse -> Maybe Text)
-> (UpdateDashboardPermissionsResponse
-> Maybe Text -> UpdateDashboardPermissionsResponse)
-> Lens
UpdateDashboardPermissionsResponse
UpdateDashboardPermissionsResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboardPermissionsResponse' {Maybe Text
requestId :: Maybe Text
$sel:requestId:UpdateDashboardPermissionsResponse' :: UpdateDashboardPermissionsResponse -> Maybe Text
requestId} -> Maybe Text
requestId) (\s :: UpdateDashboardPermissionsResponse
s@UpdateDashboardPermissionsResponse' {} Maybe Text
a -> UpdateDashboardPermissionsResponse
s {$sel:requestId:UpdateDashboardPermissionsResponse' :: Maybe Text
requestId = Maybe Text
a} :: UpdateDashboardPermissionsResponse)
updateDashboardPermissionsResponse_dashboardId :: Lens.Lens' UpdateDashboardPermissionsResponse (Prelude.Maybe Prelude.Text)
updateDashboardPermissionsResponse_dashboardId :: (Maybe Text -> f (Maybe Text))
-> UpdateDashboardPermissionsResponse
-> f UpdateDashboardPermissionsResponse
updateDashboardPermissionsResponse_dashboardId = (UpdateDashboardPermissionsResponse -> Maybe Text)
-> (UpdateDashboardPermissionsResponse
-> Maybe Text -> UpdateDashboardPermissionsResponse)
-> Lens
UpdateDashboardPermissionsResponse
UpdateDashboardPermissionsResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboardPermissionsResponse' {Maybe Text
dashboardId :: Maybe Text
$sel:dashboardId:UpdateDashboardPermissionsResponse' :: UpdateDashboardPermissionsResponse -> Maybe Text
dashboardId} -> Maybe Text
dashboardId) (\s :: UpdateDashboardPermissionsResponse
s@UpdateDashboardPermissionsResponse' {} Maybe Text
a -> UpdateDashboardPermissionsResponse
s {$sel:dashboardId:UpdateDashboardPermissionsResponse' :: Maybe Text
dashboardId = Maybe Text
a} :: UpdateDashboardPermissionsResponse)
updateDashboardPermissionsResponse_permissions :: Lens.Lens' UpdateDashboardPermissionsResponse (Prelude.Maybe (Prelude.NonEmpty ResourcePermission))
updateDashboardPermissionsResponse_permissions :: (Maybe (NonEmpty ResourcePermission)
-> f (Maybe (NonEmpty ResourcePermission)))
-> UpdateDashboardPermissionsResponse
-> f UpdateDashboardPermissionsResponse
updateDashboardPermissionsResponse_permissions = (UpdateDashboardPermissionsResponse
-> Maybe (NonEmpty ResourcePermission))
-> (UpdateDashboardPermissionsResponse
-> Maybe (NonEmpty ResourcePermission)
-> UpdateDashboardPermissionsResponse)
-> Lens
UpdateDashboardPermissionsResponse
UpdateDashboardPermissionsResponse
(Maybe (NonEmpty ResourcePermission))
(Maybe (NonEmpty ResourcePermission))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboardPermissionsResponse' {Maybe (NonEmpty ResourcePermission)
permissions :: Maybe (NonEmpty ResourcePermission)
$sel:permissions:UpdateDashboardPermissionsResponse' :: UpdateDashboardPermissionsResponse
-> Maybe (NonEmpty ResourcePermission)
permissions} -> Maybe (NonEmpty ResourcePermission)
permissions) (\s :: UpdateDashboardPermissionsResponse
s@UpdateDashboardPermissionsResponse' {} Maybe (NonEmpty ResourcePermission)
a -> UpdateDashboardPermissionsResponse
s {$sel:permissions:UpdateDashboardPermissionsResponse' :: Maybe (NonEmpty ResourcePermission)
permissions = Maybe (NonEmpty ResourcePermission)
a} :: UpdateDashboardPermissionsResponse) ((Maybe (NonEmpty ResourcePermission)
-> f (Maybe (NonEmpty ResourcePermission)))
-> UpdateDashboardPermissionsResponse
-> f UpdateDashboardPermissionsResponse)
-> ((Maybe (NonEmpty ResourcePermission)
-> f (Maybe (NonEmpty ResourcePermission)))
-> Maybe (NonEmpty ResourcePermission)
-> f (Maybe (NonEmpty ResourcePermission)))
-> (Maybe (NonEmpty ResourcePermission)
-> f (Maybe (NonEmpty ResourcePermission)))
-> UpdateDashboardPermissionsResponse
-> f UpdateDashboardPermissionsResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
(NonEmpty ResourcePermission)
(NonEmpty ResourcePermission)
(NonEmpty ResourcePermission)
(NonEmpty ResourcePermission)
-> Iso
(Maybe (NonEmpty ResourcePermission))
(Maybe (NonEmpty ResourcePermission))
(Maybe (NonEmpty ResourcePermission))
(Maybe (NonEmpty ResourcePermission))
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 ResourcePermission)
(NonEmpty ResourcePermission)
(NonEmpty ResourcePermission)
(NonEmpty ResourcePermission)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
updateDashboardPermissionsResponse_dashboardArn :: Lens.Lens' UpdateDashboardPermissionsResponse (Prelude.Maybe Prelude.Text)
updateDashboardPermissionsResponse_dashboardArn :: (Maybe Text -> f (Maybe Text))
-> UpdateDashboardPermissionsResponse
-> f UpdateDashboardPermissionsResponse
updateDashboardPermissionsResponse_dashboardArn = (UpdateDashboardPermissionsResponse -> Maybe Text)
-> (UpdateDashboardPermissionsResponse
-> Maybe Text -> UpdateDashboardPermissionsResponse)
-> Lens
UpdateDashboardPermissionsResponse
UpdateDashboardPermissionsResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboardPermissionsResponse' {Maybe Text
dashboardArn :: Maybe Text
$sel:dashboardArn:UpdateDashboardPermissionsResponse' :: UpdateDashboardPermissionsResponse -> Maybe Text
dashboardArn} -> Maybe Text
dashboardArn) (\s :: UpdateDashboardPermissionsResponse
s@UpdateDashboardPermissionsResponse' {} Maybe Text
a -> UpdateDashboardPermissionsResponse
s {$sel:dashboardArn:UpdateDashboardPermissionsResponse' :: Maybe Text
dashboardArn = Maybe Text
a} :: UpdateDashboardPermissionsResponse)
updateDashboardPermissionsResponse_status :: Lens.Lens' UpdateDashboardPermissionsResponse Prelude.Int
updateDashboardPermissionsResponse_status :: (Int -> f Int)
-> UpdateDashboardPermissionsResponse
-> f UpdateDashboardPermissionsResponse
updateDashboardPermissionsResponse_status = (UpdateDashboardPermissionsResponse -> Int)
-> (UpdateDashboardPermissionsResponse
-> Int -> UpdateDashboardPermissionsResponse)
-> Lens
UpdateDashboardPermissionsResponse
UpdateDashboardPermissionsResponse
Int
Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateDashboardPermissionsResponse' {Int
status :: Int
$sel:status:UpdateDashboardPermissionsResponse' :: UpdateDashboardPermissionsResponse -> Int
status} -> Int
status) (\s :: UpdateDashboardPermissionsResponse
s@UpdateDashboardPermissionsResponse' {} Int
a -> UpdateDashboardPermissionsResponse
s {$sel:status:UpdateDashboardPermissionsResponse' :: Int
status = Int
a} :: UpdateDashboardPermissionsResponse)
instance
Prelude.NFData
UpdateDashboardPermissionsResponse