amazonka-iam-2.0: Amazon Identity and Access Management SDK.
Copyright(c) 2013-2023 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellSafe-Inferred
LanguageHaskell2010

Amazonka.IAM.ListMFADevices

Description

Lists the MFA devices for an IAM user. If the request includes a IAM user name, then this operation lists all the MFA devices associated with the specified user. If you do not specify a user name, IAM determines the user name implicitly based on the Amazon Web Services access key ID signing the request for this operation.

You can paginate the results using the MaxItems and Marker parameters.

This operation returns paginated results.

Synopsis

Creating a Request

data ListMFADevices Source #

See: newListMFADevices smart constructor.

Constructors

ListMFADevices' 

Fields

  • marker :: Maybe Text

    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 :: Maybe Natural

    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.

  • userName :: Maybe Text

    The name of the user whose MFA devices you want to list.

    This parameter allows (through its 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: _+=,.@-

Instances

Instances details
ToHeaders ListMFADevices Source # 
Instance details

Defined in Amazonka.IAM.ListMFADevices

ToPath ListMFADevices Source # 
Instance details

Defined in Amazonka.IAM.ListMFADevices

ToQuery ListMFADevices Source # 
Instance details

Defined in Amazonka.IAM.ListMFADevices

AWSPager ListMFADevices Source # 
Instance details

Defined in Amazonka.IAM.ListMFADevices

AWSRequest ListMFADevices Source # 
Instance details

Defined in Amazonka.IAM.ListMFADevices

Associated Types

type AWSResponse ListMFADevices #

Generic ListMFADevices Source # 
Instance details

Defined in Amazonka.IAM.ListMFADevices

Associated Types

type Rep ListMFADevices :: Type -> Type #

Read ListMFADevices Source # 
Instance details

Defined in Amazonka.IAM.ListMFADevices

Show ListMFADevices Source # 
Instance details

Defined in Amazonka.IAM.ListMFADevices

NFData ListMFADevices Source # 
Instance details

Defined in Amazonka.IAM.ListMFADevices

Methods

rnf :: ListMFADevices -> () #

Eq ListMFADevices Source # 
Instance details

Defined in Amazonka.IAM.ListMFADevices

Hashable ListMFADevices Source # 
Instance details

Defined in Amazonka.IAM.ListMFADevices

type AWSResponse ListMFADevices Source # 
Instance details

Defined in Amazonka.IAM.ListMFADevices

type Rep ListMFADevices Source # 
Instance details

Defined in Amazonka.IAM.ListMFADevices

type Rep ListMFADevices = D1 ('MetaData "ListMFADevices" "Amazonka.IAM.ListMFADevices" "amazonka-iam-2.0-5DxkArXx9sD3CCYYGFyGET" 'False) (C1 ('MetaCons "ListMFADevices'" 'PrefixI 'True) (S1 ('MetaSel ('Just "marker") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: (S1 ('MetaSel ('Just "maxItems") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Natural)) :*: S1 ('MetaSel ('Just "userName") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)))))

newListMFADevices :: ListMFADevices Source #

Create a value of ListMFADevices with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

ListMFADevices, listMFADevices_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.

$sel:maxItems:ListMFADevices', listMFADevices_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.

ListMFADevices, listMFADevices_userName - The name of the user whose MFA devices you want to list.

This parameter allows (through its 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: _+=,.@-

Request Lenses

listMFADevices_marker :: Lens' ListMFADevices (Maybe Text) Source #

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.

listMFADevices_maxItems :: Lens' ListMFADevices (Maybe Natural) Source #

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.

listMFADevices_userName :: Lens' ListMFADevices (Maybe Text) Source #

The name of the user whose MFA devices you want to list.

This parameter allows (through its 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: _+=,.@-

Destructuring the Response

data ListMFADevicesResponse Source #

Contains the response to a successful ListMFADevices request.

See: newListMFADevicesResponse smart constructor.

Constructors

ListMFADevicesResponse' 

Fields

  • isTruncated :: Maybe Bool

    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 :: Maybe Text

    When IsTruncated is true, this element is present and contains the value to use for the Marker parameter in a subsequent pagination request.

  • httpStatus :: Int

    The response's http status code.

  • mfaDevices :: [MFADevice]

    A list of MFA devices.

Instances

Instances details
Generic ListMFADevicesResponse Source # 
Instance details

Defined in Amazonka.IAM.ListMFADevices

Associated Types

type Rep ListMFADevicesResponse :: Type -> Type #

Read ListMFADevicesResponse Source # 
Instance details

Defined in Amazonka.IAM.ListMFADevices

Show ListMFADevicesResponse Source # 
Instance details

Defined in Amazonka.IAM.ListMFADevices

NFData ListMFADevicesResponse Source # 
Instance details

Defined in Amazonka.IAM.ListMFADevices

Methods

rnf :: ListMFADevicesResponse -> () #

Eq ListMFADevicesResponse Source # 
Instance details

Defined in Amazonka.IAM.ListMFADevices

type Rep ListMFADevicesResponse Source # 
Instance details

Defined in Amazonka.IAM.ListMFADevices

type Rep ListMFADevicesResponse = D1 ('MetaData "ListMFADevicesResponse" "Amazonka.IAM.ListMFADevices" "amazonka-iam-2.0-5DxkArXx9sD3CCYYGFyGET" 'False) (C1 ('MetaCons "ListMFADevicesResponse'" 'PrefixI 'True) ((S1 ('MetaSel ('Just "isTruncated") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Bool)) :*: S1 ('MetaSel ('Just "marker") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text))) :*: (S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int) :*: S1 ('MetaSel ('Just "mfaDevices") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 [MFADevice]))))

newListMFADevicesResponse Source #

Create a value of ListMFADevicesResponse with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

ListMFADevicesResponse, listMFADevicesResponse_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.

ListMFADevices, listMFADevicesResponse_marker - When IsTruncated is true, this element is present and contains the value to use for the Marker parameter in a subsequent pagination request.

$sel:httpStatus:ListMFADevicesResponse', listMFADevicesResponse_httpStatus - The response's http status code.

$sel:mfaDevices:ListMFADevicesResponse', listMFADevicesResponse_mfaDevices - A list of MFA devices.

Response Lenses

listMFADevicesResponse_isTruncated :: Lens' ListMFADevicesResponse (Maybe Bool) Source #

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.

listMFADevicesResponse_marker :: Lens' ListMFADevicesResponse (Maybe Text) Source #

When IsTruncated is true, this element is present and contains the value to use for the Marker parameter in a subsequent pagination request.