ElastiCache / Client / modify_user

modify_user#

ElastiCache.Client.modify_user(**kwargs)#

Changes user password(s) and/or access string.

See also: AWS API Documentation

Request Syntax

response = client.modify_user(
    UserId='string',
    AccessString='string',
    AppendAccessString='string',
    Passwords=[
        'string',
    ],
    NoPasswordRequired=True|False,
    AuthenticationMode={
        'Type': 'password'|'no-password-required'|'iam',
        'Passwords': [
            'string',
        ]
    }
)
Parameters:
  • UserId (string) –

    [REQUIRED]

    The ID of the user.

  • AccessString (string) – Access permissions string used for this user.

  • AppendAccessString (string) – Adds additional user permissions to the access string.

  • Passwords (list) –

    The passwords belonging to the user. You are allowed up to two.

    • (string) –

  • NoPasswordRequired (boolean) – Indicates no password is required for the user.

  • AuthenticationMode (dict) –

    Specifies how to authenticate the user.

    • Type (string) –

      Specifies the authentication type. Possible options are IAM authentication, password and no password.

    • Passwords (list) –

      Specifies the passwords to use for authentication if Type is set to password.

      • (string) –

Return type:

dict

Returns:

Response Syntax

{
    'UserId': 'string',
    'UserName': 'string',
    'Status': 'string',
    'Engine': 'string',
    'MinimumEngineVersion': 'string',
    'AccessString': 'string',
    'UserGroupIds': [
        'string',
    ],
    'Authentication': {
        'Type': 'password'|'no-password'|'iam',
        'PasswordCount': 123
    },
    'ARN': 'string'
}

Response Structure

  • (dict) –

    • UserId (string) –

      The ID of the user.

    • UserName (string) –

      The username of the user.

    • Status (string) –

      Indicates the user status. Can be “active”, “modifying” or “deleting”.

    • Engine (string) –

      The current supported value is Redis.

    • MinimumEngineVersion (string) –

      The minimum engine version required, which is Redis OSS 6.0

    • AccessString (string) –

      Access permissions string used for this user.

    • UserGroupIds (list) –

      Returns a list of the user group IDs the user belongs to.

      • (string) –

    • Authentication (dict) –

      Denotes whether the user requires a password to authenticate.

      • Type (string) –

        Indicates whether the user requires a password to authenticate.

      • PasswordCount (integer) –

        The number of passwords belonging to the user. The maximum is two.

    • ARN (string) –

      The Amazon Resource Name (ARN) of the user.

Exceptions

  • ElastiCache.Client.exceptions.UserNotFoundFault

  • ElastiCache.Client.exceptions.InvalidUserStateFault

  • ElastiCache.Client.exceptions.ServiceLinkedRoleNotFoundFault

  • ElastiCache.Client.exceptions.InvalidParameterValueException

  • ElastiCache.Client.exceptions.InvalidParameterCombinationException