{-# 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.SecretsManager.ListSecrets
(
ListSecrets (..),
newListSecrets,
listSecrets_filters,
listSecrets_nextToken,
listSecrets_sortOrder,
listSecrets_maxResults,
ListSecretsResponse (..),
newListSecretsResponse,
listSecretsResponse_nextToken,
listSecretsResponse_secretList,
listSecretsResponse_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.SecretsManager.Types
data ListSecrets = ListSecrets'
{
ListSecrets -> Maybe [Filter]
filters :: Prelude.Maybe [Filter],
ListSecrets -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
ListSecrets -> Maybe SortOrderType
sortOrder :: Prelude.Maybe SortOrderType,
ListSecrets -> Maybe Natural
maxResults :: Prelude.Maybe Prelude.Natural
}
deriving (ListSecrets -> ListSecrets -> Bool
(ListSecrets -> ListSecrets -> Bool)
-> (ListSecrets -> ListSecrets -> Bool) -> Eq ListSecrets
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListSecrets -> ListSecrets -> Bool
$c/= :: ListSecrets -> ListSecrets -> Bool
== :: ListSecrets -> ListSecrets -> Bool
$c== :: ListSecrets -> ListSecrets -> Bool
Prelude.Eq, ReadPrec [ListSecrets]
ReadPrec ListSecrets
Int -> ReadS ListSecrets
ReadS [ListSecrets]
(Int -> ReadS ListSecrets)
-> ReadS [ListSecrets]
-> ReadPrec ListSecrets
-> ReadPrec [ListSecrets]
-> Read ListSecrets
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListSecrets]
$creadListPrec :: ReadPrec [ListSecrets]
readPrec :: ReadPrec ListSecrets
$creadPrec :: ReadPrec ListSecrets
readList :: ReadS [ListSecrets]
$creadList :: ReadS [ListSecrets]
readsPrec :: Int -> ReadS ListSecrets
$creadsPrec :: Int -> ReadS ListSecrets
Prelude.Read, Int -> ListSecrets -> ShowS
[ListSecrets] -> ShowS
ListSecrets -> String
(Int -> ListSecrets -> ShowS)
-> (ListSecrets -> String)
-> ([ListSecrets] -> ShowS)
-> Show ListSecrets
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListSecrets] -> ShowS
$cshowList :: [ListSecrets] -> ShowS
show :: ListSecrets -> String
$cshow :: ListSecrets -> String
showsPrec :: Int -> ListSecrets -> ShowS
$cshowsPrec :: Int -> ListSecrets -> ShowS
Prelude.Show, (forall x. ListSecrets -> Rep ListSecrets x)
-> (forall x. Rep ListSecrets x -> ListSecrets)
-> Generic ListSecrets
forall x. Rep ListSecrets x -> ListSecrets
forall x. ListSecrets -> Rep ListSecrets x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListSecrets x -> ListSecrets
$cfrom :: forall x. ListSecrets -> Rep ListSecrets x
Prelude.Generic)
newListSecrets ::
ListSecrets
newListSecrets :: ListSecrets
newListSecrets =
ListSecrets' :: Maybe [Filter]
-> Maybe Text
-> Maybe SortOrderType
-> Maybe Natural
-> ListSecrets
ListSecrets'
{ $sel:filters:ListSecrets' :: Maybe [Filter]
filters = Maybe [Filter]
forall a. Maybe a
Prelude.Nothing,
$sel:nextToken:ListSecrets' :: Maybe Text
nextToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:sortOrder:ListSecrets' :: Maybe SortOrderType
sortOrder = Maybe SortOrderType
forall a. Maybe a
Prelude.Nothing,
$sel:maxResults:ListSecrets' :: Maybe Natural
maxResults = Maybe Natural
forall a. Maybe a
Prelude.Nothing
}
listSecrets_filters :: Lens.Lens' ListSecrets (Prelude.Maybe [Filter])
listSecrets_filters :: (Maybe [Filter] -> f (Maybe [Filter]))
-> ListSecrets -> f ListSecrets
listSecrets_filters = (ListSecrets -> Maybe [Filter])
-> (ListSecrets -> Maybe [Filter] -> ListSecrets)
-> Lens ListSecrets ListSecrets (Maybe [Filter]) (Maybe [Filter])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListSecrets' {Maybe [Filter]
filters :: Maybe [Filter]
$sel:filters:ListSecrets' :: ListSecrets -> Maybe [Filter]
filters} -> Maybe [Filter]
filters) (\s :: ListSecrets
s@ListSecrets' {} Maybe [Filter]
a -> ListSecrets
s {$sel:filters:ListSecrets' :: Maybe [Filter]
filters = Maybe [Filter]
a} :: ListSecrets) ((Maybe [Filter] -> f (Maybe [Filter]))
-> ListSecrets -> f ListSecrets)
-> ((Maybe [Filter] -> f (Maybe [Filter]))
-> Maybe [Filter] -> f (Maybe [Filter]))
-> (Maybe [Filter] -> f (Maybe [Filter]))
-> ListSecrets
-> f ListSecrets
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Filter] [Filter] [Filter] [Filter]
-> Iso
(Maybe [Filter]) (Maybe [Filter]) (Maybe [Filter]) (Maybe [Filter])
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 [Filter] [Filter] [Filter] [Filter]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
listSecrets_nextToken :: Lens.Lens' ListSecrets (Prelude.Maybe Prelude.Text)
listSecrets_nextToken :: (Maybe Text -> f (Maybe Text)) -> ListSecrets -> f ListSecrets
listSecrets_nextToken = (ListSecrets -> Maybe Text)
-> (ListSecrets -> Maybe Text -> ListSecrets)
-> Lens ListSecrets ListSecrets (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListSecrets' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListSecrets' :: ListSecrets -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListSecrets
s@ListSecrets' {} Maybe Text
a -> ListSecrets
s {$sel:nextToken:ListSecrets' :: Maybe Text
nextToken = Maybe Text
a} :: ListSecrets)
listSecrets_sortOrder :: Lens.Lens' ListSecrets (Prelude.Maybe SortOrderType)
listSecrets_sortOrder :: (Maybe SortOrderType -> f (Maybe SortOrderType))
-> ListSecrets -> f ListSecrets
listSecrets_sortOrder = (ListSecrets -> Maybe SortOrderType)
-> (ListSecrets -> Maybe SortOrderType -> ListSecrets)
-> Lens
ListSecrets ListSecrets (Maybe SortOrderType) (Maybe SortOrderType)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListSecrets' {Maybe SortOrderType
sortOrder :: Maybe SortOrderType
$sel:sortOrder:ListSecrets' :: ListSecrets -> Maybe SortOrderType
sortOrder} -> Maybe SortOrderType
sortOrder) (\s :: ListSecrets
s@ListSecrets' {} Maybe SortOrderType
a -> ListSecrets
s {$sel:sortOrder:ListSecrets' :: Maybe SortOrderType
sortOrder = Maybe SortOrderType
a} :: ListSecrets)
listSecrets_maxResults :: Lens.Lens' ListSecrets (Prelude.Maybe Prelude.Natural)
listSecrets_maxResults :: (Maybe Natural -> f (Maybe Natural))
-> ListSecrets -> f ListSecrets
listSecrets_maxResults = (ListSecrets -> Maybe Natural)
-> (ListSecrets -> Maybe Natural -> ListSecrets)
-> Lens ListSecrets ListSecrets (Maybe Natural) (Maybe Natural)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListSecrets' {Maybe Natural
maxResults :: Maybe Natural
$sel:maxResults:ListSecrets' :: ListSecrets -> Maybe Natural
maxResults} -> Maybe Natural
maxResults) (\s :: ListSecrets
s@ListSecrets' {} Maybe Natural
a -> ListSecrets
s {$sel:maxResults:ListSecrets' :: Maybe Natural
maxResults = Maybe Natural
a} :: ListSecrets)
instance Core.AWSPager ListSecrets where
page :: ListSecrets -> AWSResponse ListSecrets -> Maybe ListSecrets
page ListSecrets
rq AWSResponse ListSecrets
rs
| Maybe Text -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
( AWSResponse ListSecrets
ListSecretsResponse
rs
ListSecretsResponse
-> Getting (First Text) ListSecretsResponse Text -> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> ListSecretsResponse -> Const (First Text) ListSecretsResponse
Lens' ListSecretsResponse (Maybe Text)
listSecretsResponse_nextToken ((Maybe Text -> Const (First Text) (Maybe Text))
-> ListSecretsResponse -> Const (First Text) ListSecretsResponse)
-> ((Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) ListSecretsResponse Text
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text)
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
) =
Maybe ListSecrets
forall a. Maybe a
Prelude.Nothing
| Maybe [SecretListEntry] -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
( AWSResponse ListSecrets
ListSecretsResponse
rs
ListSecretsResponse
-> Getting
(First [SecretListEntry]) ListSecretsResponse [SecretListEntry]
-> Maybe [SecretListEntry]
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe [SecretListEntry]
-> Const (First [SecretListEntry]) (Maybe [SecretListEntry]))
-> ListSecretsResponse
-> Const (First [SecretListEntry]) ListSecretsResponse
Lens' ListSecretsResponse (Maybe [SecretListEntry])
listSecretsResponse_secretList ((Maybe [SecretListEntry]
-> Const (First [SecretListEntry]) (Maybe [SecretListEntry]))
-> ListSecretsResponse
-> Const (First [SecretListEntry]) ListSecretsResponse)
-> (([SecretListEntry]
-> Const (First [SecretListEntry]) [SecretListEntry])
-> Maybe [SecretListEntry]
-> Const (First [SecretListEntry]) (Maybe [SecretListEntry]))
-> Getting
(First [SecretListEntry]) ListSecretsResponse [SecretListEntry]
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. ([SecretListEntry]
-> Const (First [SecretListEntry]) [SecretListEntry])
-> Maybe [SecretListEntry]
-> Const (First [SecretListEntry]) (Maybe [SecretListEntry])
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
) =
Maybe ListSecrets
forall a. Maybe a
Prelude.Nothing
| Bool
Prelude.otherwise =
ListSecrets -> Maybe ListSecrets
forall a. a -> Maybe a
Prelude.Just (ListSecrets -> Maybe ListSecrets)
-> ListSecrets -> Maybe ListSecrets
forall a b. (a -> b) -> a -> b
Prelude.$
ListSecrets
rq
ListSecrets -> (ListSecrets -> ListSecrets) -> ListSecrets
forall a b. a -> (a -> b) -> b
Prelude.& (Maybe Text -> Identity (Maybe Text))
-> ListSecrets -> Identity ListSecrets
Lens ListSecrets ListSecrets (Maybe Text) (Maybe Text)
listSecrets_nextToken
((Maybe Text -> Identity (Maybe Text))
-> ListSecrets -> Identity ListSecrets)
-> Maybe Text -> ListSecrets -> ListSecrets
forall s t a b. ASetter s t a b -> b -> s -> t
Lens..~ AWSResponse ListSecrets
ListSecretsResponse
rs
ListSecretsResponse
-> Getting (First Text) ListSecretsResponse Text -> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> ListSecretsResponse -> Const (First Text) ListSecretsResponse
Lens' ListSecretsResponse (Maybe Text)
listSecretsResponse_nextToken ((Maybe Text -> Const (First Text) (Maybe Text))
-> ListSecretsResponse -> Const (First Text) ListSecretsResponse)
-> ((Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) ListSecretsResponse Text
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text)
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
instance Core.AWSRequest ListSecrets where
type AWSResponse ListSecrets = ListSecretsResponse
request :: ListSecrets -> Request ListSecrets
request = Service -> ListSecrets -> Request ListSecrets
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy ListSecrets
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse ListSecrets)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse ListSecrets))
-> Logger
-> Service
-> Proxy ListSecrets
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse ListSecrets)))
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 [SecretListEntry] -> Int -> ListSecretsResponse
ListSecretsResponse'
(Maybe Text
-> Maybe [SecretListEntry] -> Int -> ListSecretsResponse)
-> Either String (Maybe Text)
-> Either
String (Maybe [SecretListEntry] -> Int -> ListSecretsResponse)
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
"NextToken")
Either
String (Maybe [SecretListEntry] -> Int -> ListSecretsResponse)
-> Either String (Maybe [SecretListEntry])
-> Either String (Int -> ListSecretsResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe (Maybe [SecretListEntry]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"SecretList" Either String (Maybe (Maybe [SecretListEntry]))
-> Maybe [SecretListEntry]
-> Either String (Maybe [SecretListEntry])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [SecretListEntry]
forall a. Monoid a => a
Prelude.mempty)
Either String (Int -> ListSecretsResponse)
-> Either String Int -> Either String ListSecretsResponse
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 ListSecrets
instance Prelude.NFData ListSecrets
instance Core.ToHeaders ListSecrets where
toHeaders :: ListSecrets -> ResponseHeaders
toHeaders =
ResponseHeaders -> ListSecrets -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"X-Amz-Target"
HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# (ByteString
"secretsmanager.ListSecrets" :: Prelude.ByteString),
HeaderName
"Content-Type"
HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"application/x-amz-json-1.1" ::
Prelude.ByteString
)
]
)
instance Core.ToJSON ListSecrets where
toJSON :: ListSecrets -> Value
toJSON ListSecrets' {Maybe Natural
Maybe [Filter]
Maybe Text
Maybe SortOrderType
maxResults :: Maybe Natural
sortOrder :: Maybe SortOrderType
nextToken :: Maybe Text
filters :: Maybe [Filter]
$sel:maxResults:ListSecrets' :: ListSecrets -> Maybe Natural
$sel:sortOrder:ListSecrets' :: ListSecrets -> Maybe SortOrderType
$sel:nextToken:ListSecrets' :: ListSecrets -> Maybe Text
$sel:filters:ListSecrets' :: ListSecrets -> Maybe [Filter]
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"Filters" Text -> [Filter] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) ([Filter] -> Pair) -> Maybe [Filter] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Filter]
filters,
(Text
"NextToken" 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
nextToken,
(Text
"SortOrder" Text -> SortOrderType -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (SortOrderType -> Pair) -> Maybe SortOrderType -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe SortOrderType
sortOrder,
(Text
"MaxResults" Text -> Natural -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Natural -> Pair) -> Maybe Natural -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Natural
maxResults
]
)
instance Core.ToPath ListSecrets where
toPath :: ListSecrets -> ByteString
toPath = ByteString -> ListSecrets -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery ListSecrets where
toQuery :: ListSecrets -> QueryString
toQuery = QueryString -> ListSecrets -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data ListSecretsResponse = ListSecretsResponse'
{
ListSecretsResponse -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
ListSecretsResponse -> Maybe [SecretListEntry]
secretList :: Prelude.Maybe [SecretListEntry],
ListSecretsResponse -> Int
httpStatus :: Prelude.Int
}
deriving (ListSecretsResponse -> ListSecretsResponse -> Bool
(ListSecretsResponse -> ListSecretsResponse -> Bool)
-> (ListSecretsResponse -> ListSecretsResponse -> Bool)
-> Eq ListSecretsResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListSecretsResponse -> ListSecretsResponse -> Bool
$c/= :: ListSecretsResponse -> ListSecretsResponse -> Bool
== :: ListSecretsResponse -> ListSecretsResponse -> Bool
$c== :: ListSecretsResponse -> ListSecretsResponse -> Bool
Prelude.Eq, ReadPrec [ListSecretsResponse]
ReadPrec ListSecretsResponse
Int -> ReadS ListSecretsResponse
ReadS [ListSecretsResponse]
(Int -> ReadS ListSecretsResponse)
-> ReadS [ListSecretsResponse]
-> ReadPrec ListSecretsResponse
-> ReadPrec [ListSecretsResponse]
-> Read ListSecretsResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListSecretsResponse]
$creadListPrec :: ReadPrec [ListSecretsResponse]
readPrec :: ReadPrec ListSecretsResponse
$creadPrec :: ReadPrec ListSecretsResponse
readList :: ReadS [ListSecretsResponse]
$creadList :: ReadS [ListSecretsResponse]
readsPrec :: Int -> ReadS ListSecretsResponse
$creadsPrec :: Int -> ReadS ListSecretsResponse
Prelude.Read, Int -> ListSecretsResponse -> ShowS
[ListSecretsResponse] -> ShowS
ListSecretsResponse -> String
(Int -> ListSecretsResponse -> ShowS)
-> (ListSecretsResponse -> String)
-> ([ListSecretsResponse] -> ShowS)
-> Show ListSecretsResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListSecretsResponse] -> ShowS
$cshowList :: [ListSecretsResponse] -> ShowS
show :: ListSecretsResponse -> String
$cshow :: ListSecretsResponse -> String
showsPrec :: Int -> ListSecretsResponse -> ShowS
$cshowsPrec :: Int -> ListSecretsResponse -> ShowS
Prelude.Show, (forall x. ListSecretsResponse -> Rep ListSecretsResponse x)
-> (forall x. Rep ListSecretsResponse x -> ListSecretsResponse)
-> Generic ListSecretsResponse
forall x. Rep ListSecretsResponse x -> ListSecretsResponse
forall x. ListSecretsResponse -> Rep ListSecretsResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListSecretsResponse x -> ListSecretsResponse
$cfrom :: forall x. ListSecretsResponse -> Rep ListSecretsResponse x
Prelude.Generic)
newListSecretsResponse ::
Prelude.Int ->
ListSecretsResponse
newListSecretsResponse :: Int -> ListSecretsResponse
newListSecretsResponse Int
pHttpStatus_ =
ListSecretsResponse' :: Maybe Text -> Maybe [SecretListEntry] -> Int -> ListSecretsResponse
ListSecretsResponse'
{ $sel:nextToken:ListSecretsResponse' :: Maybe Text
nextToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:secretList:ListSecretsResponse' :: Maybe [SecretListEntry]
secretList = Maybe [SecretListEntry]
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:ListSecretsResponse' :: Int
httpStatus = Int
pHttpStatus_
}
listSecretsResponse_nextToken :: Lens.Lens' ListSecretsResponse (Prelude.Maybe Prelude.Text)
listSecretsResponse_nextToken :: (Maybe Text -> f (Maybe Text))
-> ListSecretsResponse -> f ListSecretsResponse
listSecretsResponse_nextToken = (ListSecretsResponse -> Maybe Text)
-> (ListSecretsResponse -> Maybe Text -> ListSecretsResponse)
-> Lens' ListSecretsResponse (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListSecretsResponse' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListSecretsResponse' :: ListSecretsResponse -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListSecretsResponse
s@ListSecretsResponse' {} Maybe Text
a -> ListSecretsResponse
s {$sel:nextToken:ListSecretsResponse' :: Maybe Text
nextToken = Maybe Text
a} :: ListSecretsResponse)
listSecretsResponse_secretList :: Lens.Lens' ListSecretsResponse (Prelude.Maybe [SecretListEntry])
listSecretsResponse_secretList :: (Maybe [SecretListEntry] -> f (Maybe [SecretListEntry]))
-> ListSecretsResponse -> f ListSecretsResponse
listSecretsResponse_secretList = (ListSecretsResponse -> Maybe [SecretListEntry])
-> (ListSecretsResponse
-> Maybe [SecretListEntry] -> ListSecretsResponse)
-> Lens' ListSecretsResponse (Maybe [SecretListEntry])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListSecretsResponse' {Maybe [SecretListEntry]
secretList :: Maybe [SecretListEntry]
$sel:secretList:ListSecretsResponse' :: ListSecretsResponse -> Maybe [SecretListEntry]
secretList} -> Maybe [SecretListEntry]
secretList) (\s :: ListSecretsResponse
s@ListSecretsResponse' {} Maybe [SecretListEntry]
a -> ListSecretsResponse
s {$sel:secretList:ListSecretsResponse' :: Maybe [SecretListEntry]
secretList = Maybe [SecretListEntry]
a} :: ListSecretsResponse) ((Maybe [SecretListEntry] -> f (Maybe [SecretListEntry]))
-> ListSecretsResponse -> f ListSecretsResponse)
-> ((Maybe [SecretListEntry] -> f (Maybe [SecretListEntry]))
-> Maybe [SecretListEntry] -> f (Maybe [SecretListEntry]))
-> (Maybe [SecretListEntry] -> f (Maybe [SecretListEntry]))
-> ListSecretsResponse
-> f ListSecretsResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
[SecretListEntry]
[SecretListEntry]
[SecretListEntry]
[SecretListEntry]
-> Iso
(Maybe [SecretListEntry])
(Maybe [SecretListEntry])
(Maybe [SecretListEntry])
(Maybe [SecretListEntry])
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
[SecretListEntry]
[SecretListEntry]
[SecretListEntry]
[SecretListEntry]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
listSecretsResponse_httpStatus :: Lens.Lens' ListSecretsResponse Prelude.Int
listSecretsResponse_httpStatus :: (Int -> f Int) -> ListSecretsResponse -> f ListSecretsResponse
listSecretsResponse_httpStatus = (ListSecretsResponse -> Int)
-> (ListSecretsResponse -> Int -> ListSecretsResponse)
-> Lens ListSecretsResponse ListSecretsResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListSecretsResponse' {Int
httpStatus :: Int
$sel:httpStatus:ListSecretsResponse' :: ListSecretsResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: ListSecretsResponse
s@ListSecretsResponse' {} Int
a -> ListSecretsResponse
s {$sel:httpStatus:ListSecretsResponse' :: Int
httpStatus = Int
a} :: ListSecretsResponse)
instance Prelude.NFData ListSecretsResponse