IAM / Client / deactivate_mfa_device
deactivate_mfa_device#
- IAM.Client.deactivate_mfa_device(**kwargs)#
Deactivates the specified MFA device and removes it from association with the user name for which it was originally enabled.
For more information about creating and working with virtual MFA devices, see Enabling a virtual multi-factor authentication (MFA) device in the IAM User Guide.
See also: AWS API Documentation
Request Syntax
response = client.deactivate_mfa_device( UserName='string', SerialNumber='string' )
- Parameters:
UserName (string) –
[REQUIRED]
The name of the user whose MFA device you want to deactivate.
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: _+=,.@-
SerialNumber (string) –
[REQUIRED]
The serial number that uniquely identifies the MFA device. For virtual MFA devices, the serial number is the device ARN.
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: =,.@:/-
- Returns:
None
Exceptions
IAM.Client.exceptions.EntityTemporarilyUnmodifiableException
IAM.Client.exceptions.NoSuchEntityException
IAM.Client.exceptions.LimitExceededException
IAM.Client.exceptions.ServiceFailureException