{-# 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.IAM.ListMFADeviceTags
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Lists the tags that are attached to the specified IAM virtual
-- multi-factor authentication (MFA) device. The returned list of tags is
-- sorted by tag key. For more information about tagging, see
-- <https://docs.aws.amazon.com/IAM/latest/UserGuide/id_tags.html Tagging IAM resources>
-- in the /IAM User Guide/.
module Amazonka.IAM.ListMFADeviceTags
  ( -- * Creating a Request
    ListMFADeviceTags (..),
    newListMFADeviceTags,

    -- * Request Lenses
    listMFADeviceTags_marker,
    listMFADeviceTags_maxItems,
    listMFADeviceTags_serialNumber,

    -- * Destructuring the Response
    ListMFADeviceTagsResponse (..),
    newListMFADeviceTagsResponse,

    -- * Response Lenses
    listMFADeviceTagsResponse_isTruncated,
    listMFADeviceTagsResponse_marker,
    listMFADeviceTagsResponse_httpStatus,
    listMFADeviceTagsResponse_tags,
  )
where

import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.IAM.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response

-- | /See:/ 'newListMFADeviceTags' smart constructor.
data ListMFADeviceTags = ListMFADeviceTags'
  { -- | Use this parameter only when paginating results and only after you
    -- receive a response indicating that the results are truncated. Set it to
    -- the value of the @Marker@ element in the response that you received to
    -- indicate where the next call should start.
    ListMFADeviceTags -> Maybe Text
marker :: Prelude.Maybe Prelude.Text,
    -- | Use this only when paginating results to indicate the maximum number of
    -- items you want in the response. If additional items exist beyond the
    -- maximum you specify, the @IsTruncated@ response element is @true@.
    --
    -- If you do not include this parameter, the number of items defaults to
    -- 100. Note that IAM might return fewer results, even when there are more
    -- results available. In that case, the @IsTruncated@ response element
    -- returns @true@, and @Marker@ contains a value to include in the
    -- subsequent call that tells the service where to continue from.
    ListMFADeviceTags -> Maybe Natural
maxItems :: Prelude.Maybe Prelude.Natural,
    -- | The unique identifier for the IAM virtual MFA device whose tags you want
    -- to see. For virtual MFA devices, the serial number is the same as the
    -- ARN.
    --
    -- This parameter allows (through its
    -- <http://wikipedia.org/wiki/regex regex pattern>) a string of characters
    -- consisting of upper and lowercase alphanumeric characters with no
    -- spaces. You can also include any of the following characters: _+=,.\@-
    ListMFADeviceTags -> Text
serialNumber :: Prelude.Text
  }
  deriving (ListMFADeviceTags -> ListMFADeviceTags -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListMFADeviceTags -> ListMFADeviceTags -> Bool
$c/= :: ListMFADeviceTags -> ListMFADeviceTags -> Bool
== :: ListMFADeviceTags -> ListMFADeviceTags -> Bool
$c== :: ListMFADeviceTags -> ListMFADeviceTags -> Bool
Prelude.Eq, ReadPrec [ListMFADeviceTags]
ReadPrec ListMFADeviceTags
Int -> ReadS ListMFADeviceTags
ReadS [ListMFADeviceTags]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListMFADeviceTags]
$creadListPrec :: ReadPrec [ListMFADeviceTags]
readPrec :: ReadPrec ListMFADeviceTags
$creadPrec :: ReadPrec ListMFADeviceTags
readList :: ReadS [ListMFADeviceTags]
$creadList :: ReadS [ListMFADeviceTags]
readsPrec :: Int -> ReadS ListMFADeviceTags
$creadsPrec :: Int -> ReadS ListMFADeviceTags
Prelude.Read, Int -> ListMFADeviceTags -> ShowS
[ListMFADeviceTags] -> ShowS
ListMFADeviceTags -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListMFADeviceTags] -> ShowS
$cshowList :: [ListMFADeviceTags] -> ShowS
show :: ListMFADeviceTags -> String
$cshow :: ListMFADeviceTags -> String
showsPrec :: Int -> ListMFADeviceTags -> ShowS
$cshowsPrec :: Int -> ListMFADeviceTags -> ShowS
Prelude.Show, forall x. Rep ListMFADeviceTags x -> ListMFADeviceTags
forall x. ListMFADeviceTags -> Rep ListMFADeviceTags x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListMFADeviceTags x -> ListMFADeviceTags
$cfrom :: forall x. ListMFADeviceTags -> Rep ListMFADeviceTags x
Prelude.Generic)

-- |
-- Create a value of 'ListMFADeviceTags' 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:
--
-- 'marker', 'listMFADeviceTags_marker' - Use this parameter only when paginating results and only after you
-- receive a response indicating that the results are truncated. Set it to
-- the value of the @Marker@ element in the response that you received to
-- indicate where the next call should start.
--
-- 'maxItems', 'listMFADeviceTags_maxItems' - Use this only when paginating results to indicate the maximum number of
-- items you want in the response. If additional items exist beyond the
-- maximum you specify, the @IsTruncated@ response element is @true@.
--
-- If you do not include this parameter, the number of items defaults to
-- 100. Note that IAM might return fewer results, even when there are more
-- results available. In that case, the @IsTruncated@ response element
-- returns @true@, and @Marker@ contains a value to include in the
-- subsequent call that tells the service where to continue from.
--
-- 'serialNumber', 'listMFADeviceTags_serialNumber' - The unique identifier for the IAM virtual MFA device whose tags you want
-- to see. For virtual MFA devices, the serial number is the same as the
-- ARN.
--
-- This parameter allows (through its
-- <http://wikipedia.org/wiki/regex regex pattern>) a string of characters
-- consisting of upper and lowercase alphanumeric characters with no
-- spaces. You can also include any of the following characters: _+=,.\@-
newListMFADeviceTags ::
  -- | 'serialNumber'
  Prelude.Text ->
  ListMFADeviceTags
newListMFADeviceTags :: Text -> ListMFADeviceTags
newListMFADeviceTags Text
pSerialNumber_ =
  ListMFADeviceTags'
    { $sel:marker:ListMFADeviceTags' :: Maybe Text
marker = forall a. Maybe a
Prelude.Nothing,
      $sel:maxItems:ListMFADeviceTags' :: Maybe Natural
maxItems = forall a. Maybe a
Prelude.Nothing,
      $sel:serialNumber:ListMFADeviceTags' :: Text
serialNumber = Text
pSerialNumber_
    }

-- | Use this parameter only when paginating results and only after you
-- receive a response indicating that the results are truncated. Set it to
-- the value of the @Marker@ element in the response that you received to
-- indicate where the next call should start.
listMFADeviceTags_marker :: Lens.Lens' ListMFADeviceTags (Prelude.Maybe Prelude.Text)
listMFADeviceTags_marker :: Lens' ListMFADeviceTags (Maybe Text)
listMFADeviceTags_marker = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListMFADeviceTags' {Maybe Text
marker :: Maybe Text
$sel:marker:ListMFADeviceTags' :: ListMFADeviceTags -> Maybe Text
marker} -> Maybe Text
marker) (\s :: ListMFADeviceTags
s@ListMFADeviceTags' {} Maybe Text
a -> ListMFADeviceTags
s {$sel:marker:ListMFADeviceTags' :: Maybe Text
marker = Maybe Text
a} :: ListMFADeviceTags)

-- | Use this only when paginating results to indicate the maximum number of
-- items you want in the response. If additional items exist beyond the
-- maximum you specify, the @IsTruncated@ response element is @true@.
--
-- If you do not include this parameter, the number of items defaults to
-- 100. Note that IAM might return fewer results, even when there are more
-- results available. In that case, the @IsTruncated@ response element
-- returns @true@, and @Marker@ contains a value to include in the
-- subsequent call that tells the service where to continue from.
listMFADeviceTags_maxItems :: Lens.Lens' ListMFADeviceTags (Prelude.Maybe Prelude.Natural)
listMFADeviceTags_maxItems :: Lens' ListMFADeviceTags (Maybe Natural)
listMFADeviceTags_maxItems = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListMFADeviceTags' {Maybe Natural
maxItems :: Maybe Natural
$sel:maxItems:ListMFADeviceTags' :: ListMFADeviceTags -> Maybe Natural
maxItems} -> Maybe Natural
maxItems) (\s :: ListMFADeviceTags
s@ListMFADeviceTags' {} Maybe Natural
a -> ListMFADeviceTags
s {$sel:maxItems:ListMFADeviceTags' :: Maybe Natural
maxItems = Maybe Natural
a} :: ListMFADeviceTags)

-- | The unique identifier for the IAM virtual MFA device whose tags you want
-- to see. For virtual MFA devices, the serial number is the same as the
-- ARN.
--
-- This parameter allows (through its
-- <http://wikipedia.org/wiki/regex regex pattern>) a string of characters
-- consisting of upper and lowercase alphanumeric characters with no
-- spaces. You can also include any of the following characters: _+=,.\@-
listMFADeviceTags_serialNumber :: Lens.Lens' ListMFADeviceTags Prelude.Text
listMFADeviceTags_serialNumber :: Lens' ListMFADeviceTags Text
listMFADeviceTags_serialNumber = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListMFADeviceTags' {Text
serialNumber :: Text
$sel:serialNumber:ListMFADeviceTags' :: ListMFADeviceTags -> Text
serialNumber} -> Text
serialNumber) (\s :: ListMFADeviceTags
s@ListMFADeviceTags' {} Text
a -> ListMFADeviceTags
s {$sel:serialNumber:ListMFADeviceTags' :: Text
serialNumber = Text
a} :: ListMFADeviceTags)

instance Core.AWSRequest ListMFADeviceTags where
  type
    AWSResponse ListMFADeviceTags =
      ListMFADeviceTagsResponse
  request :: (Service -> Service)
-> ListMFADeviceTags -> Request ListMFADeviceTags
request Service -> Service
overrides =
    forall a. ToRequest a => Service -> a -> Request a
Request.postQuery (Service -> Service
overrides Service
defaultService)
  response :: forall (m :: * -> *).
MonadResource m =>
(ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy ListMFADeviceTags
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse ListMFADeviceTags)))
response =
    forall (m :: * -> *) a.
MonadResource m =>
Text
-> (Int
    -> ResponseHeaders -> [Node] -> Either String (AWSResponse a))
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveXMLWrapper
      Text
"ListMFADeviceTagsResult"
      ( \Int
s ResponseHeaders
h [Node]
x ->
          Maybe Bool
-> Maybe Text -> Int -> [Tag] -> ListMFADeviceTagsResponse
ListMFADeviceTagsResponse'
            forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Data..@? Text
"IsTruncated")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Data..@? Text
"Marker")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x
                            forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Data..@? Text
"Tags"
                            forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ forall a. Monoid a => a
Prelude.mempty
                            forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= forall a. FromXML a => Text -> [Node] -> Either String [a]
Data.parseXMLList Text
"member"
                        )
      )

instance Prelude.Hashable ListMFADeviceTags where
  hashWithSalt :: Int -> ListMFADeviceTags -> Int
hashWithSalt Int
_salt ListMFADeviceTags' {Maybe Natural
Maybe Text
Text
serialNumber :: Text
maxItems :: Maybe Natural
marker :: Maybe Text
$sel:serialNumber:ListMFADeviceTags' :: ListMFADeviceTags -> Text
$sel:maxItems:ListMFADeviceTags' :: ListMFADeviceTags -> Maybe Natural
$sel:marker:ListMFADeviceTags' :: ListMFADeviceTags -> Maybe Text
..} =
    Int
_salt
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
marker
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Natural
maxItems
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
serialNumber

instance Prelude.NFData ListMFADeviceTags where
  rnf :: ListMFADeviceTags -> ()
rnf ListMFADeviceTags' {Maybe Natural
Maybe Text
Text
serialNumber :: Text
maxItems :: Maybe Natural
marker :: Maybe Text
$sel:serialNumber:ListMFADeviceTags' :: ListMFADeviceTags -> Text
$sel:maxItems:ListMFADeviceTags' :: ListMFADeviceTags -> Maybe Natural
$sel:marker:ListMFADeviceTags' :: ListMFADeviceTags -> Maybe Text
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
marker
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Natural
maxItems
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
serialNumber

instance Data.ToHeaders ListMFADeviceTags where
  toHeaders :: ListMFADeviceTags -> ResponseHeaders
toHeaders = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty

instance Data.ToPath ListMFADeviceTags where
  toPath :: ListMFADeviceTags -> ByteString
toPath = forall a b. a -> b -> a
Prelude.const ByteString
"/"

instance Data.ToQuery ListMFADeviceTags where
  toQuery :: ListMFADeviceTags -> QueryString
toQuery ListMFADeviceTags' {Maybe Natural
Maybe Text
Text
serialNumber :: Text
maxItems :: Maybe Natural
marker :: Maybe Text
$sel:serialNumber:ListMFADeviceTags' :: ListMFADeviceTags -> Text
$sel:maxItems:ListMFADeviceTags' :: ListMFADeviceTags -> Maybe Natural
$sel:marker:ListMFADeviceTags' :: ListMFADeviceTags -> Maybe Text
..} =
    forall a. Monoid a => [a] -> a
Prelude.mconcat
      [ ByteString
"Action"
          forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: (ByteString
"ListMFADeviceTags" :: Prelude.ByteString),
        ByteString
"Version"
          forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: (ByteString
"2010-05-08" :: Prelude.ByteString),
        ByteString
"Marker" forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: Maybe Text
marker,
        ByteString
"MaxItems" forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: Maybe Natural
maxItems,
        ByteString
"SerialNumber" forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: Text
serialNumber
      ]

-- | /See:/ 'newListMFADeviceTagsResponse' smart constructor.
data ListMFADeviceTagsResponse = ListMFADeviceTagsResponse'
  { -- | A flag that indicates whether there are more items to return. If your
    -- results were truncated, you can make a subsequent pagination request
    -- using the @Marker@ request parameter to retrieve more items. Note that
    -- IAM might return fewer than the @MaxItems@ number of results even when
    -- there are more results available. We recommend that you check
    -- @IsTruncated@ after every call to ensure that you receive all your
    -- results.
    ListMFADeviceTagsResponse -> Maybe Bool
isTruncated :: Prelude.Maybe Prelude.Bool,
    -- | When @IsTruncated@ is @true@, this element is present and contains the
    -- value to use for the @Marker@ parameter in a subsequent pagination
    -- request.
    ListMFADeviceTagsResponse -> Maybe Text
marker :: Prelude.Maybe Prelude.Text,
    -- | The response's http status code.
    ListMFADeviceTagsResponse -> Int
httpStatus :: Prelude.Int,
    -- | The list of tags that are currently attached to the virtual MFA device.
    -- Each tag consists of a key name and an associated value. If no tags are
    -- attached to the specified resource, the response contains an empty list.
    ListMFADeviceTagsResponse -> [Tag]
tags :: [Tag]
  }
  deriving (ListMFADeviceTagsResponse -> ListMFADeviceTagsResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListMFADeviceTagsResponse -> ListMFADeviceTagsResponse -> Bool
$c/= :: ListMFADeviceTagsResponse -> ListMFADeviceTagsResponse -> Bool
== :: ListMFADeviceTagsResponse -> ListMFADeviceTagsResponse -> Bool
$c== :: ListMFADeviceTagsResponse -> ListMFADeviceTagsResponse -> Bool
Prelude.Eq, ReadPrec [ListMFADeviceTagsResponse]
ReadPrec ListMFADeviceTagsResponse
Int -> ReadS ListMFADeviceTagsResponse
ReadS [ListMFADeviceTagsResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListMFADeviceTagsResponse]
$creadListPrec :: ReadPrec [ListMFADeviceTagsResponse]
readPrec :: ReadPrec ListMFADeviceTagsResponse
$creadPrec :: ReadPrec ListMFADeviceTagsResponse
readList :: ReadS [ListMFADeviceTagsResponse]
$creadList :: ReadS [ListMFADeviceTagsResponse]
readsPrec :: Int -> ReadS ListMFADeviceTagsResponse
$creadsPrec :: Int -> ReadS ListMFADeviceTagsResponse
Prelude.Read, Int -> ListMFADeviceTagsResponse -> ShowS
[ListMFADeviceTagsResponse] -> ShowS
ListMFADeviceTagsResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListMFADeviceTagsResponse] -> ShowS
$cshowList :: [ListMFADeviceTagsResponse] -> ShowS
show :: ListMFADeviceTagsResponse -> String
$cshow :: ListMFADeviceTagsResponse -> String
showsPrec :: Int -> ListMFADeviceTagsResponse -> ShowS
$cshowsPrec :: Int -> ListMFADeviceTagsResponse -> ShowS
Prelude.Show, forall x.
Rep ListMFADeviceTagsResponse x -> ListMFADeviceTagsResponse
forall x.
ListMFADeviceTagsResponse -> Rep ListMFADeviceTagsResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListMFADeviceTagsResponse x -> ListMFADeviceTagsResponse
$cfrom :: forall x.
ListMFADeviceTagsResponse -> Rep ListMFADeviceTagsResponse x
Prelude.Generic)

-- |
-- Create a value of 'ListMFADeviceTagsResponse' 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:
--
-- 'isTruncated', 'listMFADeviceTagsResponse_isTruncated' - A flag that indicates whether there are more items to return. If your
-- results were truncated, you can make a subsequent pagination request
-- using the @Marker@ request parameter to retrieve more items. Note that
-- IAM might return fewer than the @MaxItems@ number of results even when
-- there are more results available. We recommend that you check
-- @IsTruncated@ after every call to ensure that you receive all your
-- results.
--
-- 'marker', 'listMFADeviceTagsResponse_marker' - When @IsTruncated@ is @true@, this element is present and contains the
-- value to use for the @Marker@ parameter in a subsequent pagination
-- request.
--
-- 'httpStatus', 'listMFADeviceTagsResponse_httpStatus' - The response's http status code.
--
-- 'tags', 'listMFADeviceTagsResponse_tags' - The list of tags that are currently attached to the virtual MFA device.
-- Each tag consists of a key name and an associated value. If no tags are
-- attached to the specified resource, the response contains an empty list.
newListMFADeviceTagsResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  ListMFADeviceTagsResponse
newListMFADeviceTagsResponse :: Int -> ListMFADeviceTagsResponse
newListMFADeviceTagsResponse Int
pHttpStatus_ =
  ListMFADeviceTagsResponse'
    { $sel:isTruncated:ListMFADeviceTagsResponse' :: Maybe Bool
isTruncated =
        forall a. Maybe a
Prelude.Nothing,
      $sel:marker:ListMFADeviceTagsResponse' :: Maybe Text
marker = forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:ListMFADeviceTagsResponse' :: Int
httpStatus = Int
pHttpStatus_,
      $sel:tags:ListMFADeviceTagsResponse' :: [Tag]
tags = forall a. Monoid a => a
Prelude.mempty
    }

-- | A flag that indicates whether there are more items to return. If your
-- results were truncated, you can make a subsequent pagination request
-- using the @Marker@ request parameter to retrieve more items. Note that
-- IAM might return fewer than the @MaxItems@ number of results even when
-- there are more results available. We recommend that you check
-- @IsTruncated@ after every call to ensure that you receive all your
-- results.
listMFADeviceTagsResponse_isTruncated :: Lens.Lens' ListMFADeviceTagsResponse (Prelude.Maybe Prelude.Bool)
listMFADeviceTagsResponse_isTruncated :: Lens' ListMFADeviceTagsResponse (Maybe Bool)
listMFADeviceTagsResponse_isTruncated = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListMFADeviceTagsResponse' {Maybe Bool
isTruncated :: Maybe Bool
$sel:isTruncated:ListMFADeviceTagsResponse' :: ListMFADeviceTagsResponse -> Maybe Bool
isTruncated} -> Maybe Bool
isTruncated) (\s :: ListMFADeviceTagsResponse
s@ListMFADeviceTagsResponse' {} Maybe Bool
a -> ListMFADeviceTagsResponse
s {$sel:isTruncated:ListMFADeviceTagsResponse' :: Maybe Bool
isTruncated = Maybe Bool
a} :: ListMFADeviceTagsResponse)

-- | When @IsTruncated@ is @true@, this element is present and contains the
-- value to use for the @Marker@ parameter in a subsequent pagination
-- request.
listMFADeviceTagsResponse_marker :: Lens.Lens' ListMFADeviceTagsResponse (Prelude.Maybe Prelude.Text)
listMFADeviceTagsResponse_marker :: Lens' ListMFADeviceTagsResponse (Maybe Text)
listMFADeviceTagsResponse_marker = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListMFADeviceTagsResponse' {Maybe Text
marker :: Maybe Text
$sel:marker:ListMFADeviceTagsResponse' :: ListMFADeviceTagsResponse -> Maybe Text
marker} -> Maybe Text
marker) (\s :: ListMFADeviceTagsResponse
s@ListMFADeviceTagsResponse' {} Maybe Text
a -> ListMFADeviceTagsResponse
s {$sel:marker:ListMFADeviceTagsResponse' :: Maybe Text
marker = Maybe Text
a} :: ListMFADeviceTagsResponse)

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

-- | The list of tags that are currently attached to the virtual MFA device.
-- Each tag consists of a key name and an associated value. If no tags are
-- attached to the specified resource, the response contains an empty list.
listMFADeviceTagsResponse_tags :: Lens.Lens' ListMFADeviceTagsResponse [Tag]
listMFADeviceTagsResponse_tags :: Lens' ListMFADeviceTagsResponse [Tag]
listMFADeviceTagsResponse_tags = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListMFADeviceTagsResponse' {[Tag]
tags :: [Tag]
$sel:tags:ListMFADeviceTagsResponse' :: ListMFADeviceTagsResponse -> [Tag]
tags} -> [Tag]
tags) (\s :: ListMFADeviceTagsResponse
s@ListMFADeviceTagsResponse' {} [Tag]
a -> ListMFADeviceTagsResponse
s {$sel:tags:ListMFADeviceTagsResponse' :: [Tag]
tags = [Tag]
a} :: ListMFADeviceTagsResponse) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

instance Prelude.NFData ListMFADeviceTagsResponse where
  rnf :: ListMFADeviceTagsResponse -> ()
rnf ListMFADeviceTagsResponse' {Int
[Tag]
Maybe Bool
Maybe Text
tags :: [Tag]
httpStatus :: Int
marker :: Maybe Text
isTruncated :: Maybe Bool
$sel:tags:ListMFADeviceTagsResponse' :: ListMFADeviceTagsResponse -> [Tag]
$sel:httpStatus:ListMFADeviceTagsResponse' :: ListMFADeviceTagsResponse -> Int
$sel:marker:ListMFADeviceTagsResponse' :: ListMFADeviceTagsResponse -> Maybe Text
$sel:isTruncated:ListMFADeviceTagsResponse' :: ListMFADeviceTagsResponse -> Maybe Bool
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
isTruncated
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
marker
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Int
httpStatus
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf [Tag]
tags