amazonka-secretsmanager-2.0: Amazon Secrets Manager 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.SecretsManager.GetRandomPassword

Description

Generates a random password. We recommend that you specify the maximum length and include every character type that the system you are generating a password for can support.

Secrets Manager generates a CloudTrail log entry when you call this action. Do not include sensitive information in request parameters because it might be logged. For more information, see Logging Secrets Manager events with CloudTrail.

Required permissions: secretsmanager:GetRandomPassword. For more information, see IAM policy actions for Secrets Manager and Authentication and access control in Secrets Manager.

Synopsis

Creating a Request

data GetRandomPassword Source #

See: newGetRandomPassword smart constructor.

Constructors

GetRandomPassword' 

Fields

  • excludeCharacters :: Maybe Text

    A string of the characters that you don't want in the password.

  • excludeLowercase :: Maybe Bool

    Specifies whether to exclude lowercase letters from the password. If you don't include this switch, the password can contain lowercase letters.

  • excludeNumbers :: Maybe Bool

    Specifies whether to exclude numbers from the password. If you don't include this switch, the password can contain numbers.

  • excludePunctuation :: Maybe Bool

    Specifies whether to exclude the following punctuation characters from the password: ! " # $ % & ' ( ) * + , - . / : ; < = > ? @ [ \ ] ^ _ ` { | } ~. If you don't include this switch, the password can contain punctuation.

  • excludeUppercase :: Maybe Bool

    Specifies whether to exclude uppercase letters from the password. If you don't include this switch, the password can contain uppercase letters.

  • includeSpace :: Maybe Bool

    Specifies whether to include the space character. If you include this switch, the password can contain space characters.

  • passwordLength :: Maybe Natural

    The length of the password. If you don't include this parameter, the default length is 32 characters.

  • requireEachIncludedType :: Maybe Bool

    Specifies whether to include at least one upper and lowercase letter, one number, and one punctuation. If you don't include this switch, the password contains at least one of every character type.

Instances

Instances details
ToJSON GetRandomPassword Source # 
Instance details

Defined in Amazonka.SecretsManager.GetRandomPassword

ToHeaders GetRandomPassword Source # 
Instance details

Defined in Amazonka.SecretsManager.GetRandomPassword

ToPath GetRandomPassword Source # 
Instance details

Defined in Amazonka.SecretsManager.GetRandomPassword

ToQuery GetRandomPassword Source # 
Instance details

Defined in Amazonka.SecretsManager.GetRandomPassword

AWSRequest GetRandomPassword Source # 
Instance details

Defined in Amazonka.SecretsManager.GetRandomPassword

Associated Types

type AWSResponse GetRandomPassword #

Generic GetRandomPassword Source # 
Instance details

Defined in Amazonka.SecretsManager.GetRandomPassword

Associated Types

type Rep GetRandomPassword :: Type -> Type #

Read GetRandomPassword Source # 
Instance details

Defined in Amazonka.SecretsManager.GetRandomPassword

Show GetRandomPassword Source # 
Instance details

Defined in Amazonka.SecretsManager.GetRandomPassword

NFData GetRandomPassword Source # 
Instance details

Defined in Amazonka.SecretsManager.GetRandomPassword

Methods

rnf :: GetRandomPassword -> () #

Eq GetRandomPassword Source # 
Instance details

Defined in Amazonka.SecretsManager.GetRandomPassword

Hashable GetRandomPassword Source # 
Instance details

Defined in Amazonka.SecretsManager.GetRandomPassword

type AWSResponse GetRandomPassword Source # 
Instance details

Defined in Amazonka.SecretsManager.GetRandomPassword

type Rep GetRandomPassword Source # 
Instance details

Defined in Amazonka.SecretsManager.GetRandomPassword

type Rep GetRandomPassword = D1 ('MetaData "GetRandomPassword" "Amazonka.SecretsManager.GetRandomPassword" "amazonka-secretsmanager-2.0-8tljeZ4CwL92E7JavkDb0o" 'False) (C1 ('MetaCons "GetRandomPassword'" 'PrefixI 'True) (((S1 ('MetaSel ('Just "excludeCharacters") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "excludeLowercase") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Bool))) :*: (S1 ('MetaSel ('Just "excludeNumbers") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Bool)) :*: S1 ('MetaSel ('Just "excludePunctuation") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Bool)))) :*: ((S1 ('MetaSel ('Just "excludeUppercase") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Bool)) :*: S1 ('MetaSel ('Just "includeSpace") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Bool))) :*: (S1 ('MetaSel ('Just "passwordLength") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Natural)) :*: S1 ('MetaSel ('Just "requireEachIncludedType") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Bool))))))

newGetRandomPassword :: GetRandomPassword Source #

Create a value of GetRandomPassword 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:

$sel:excludeCharacters:GetRandomPassword', getRandomPassword_excludeCharacters - A string of the characters that you don't want in the password.

$sel:excludeLowercase:GetRandomPassword', getRandomPassword_excludeLowercase - Specifies whether to exclude lowercase letters from the password. If you don't include this switch, the password can contain lowercase letters.

$sel:excludeNumbers:GetRandomPassword', getRandomPassword_excludeNumbers - Specifies whether to exclude numbers from the password. If you don't include this switch, the password can contain numbers.

$sel:excludePunctuation:GetRandomPassword', getRandomPassword_excludePunctuation - Specifies whether to exclude the following punctuation characters from the password: ! " # $ % & ' ( ) * + , - . / : ; < = > ? @ [ \ ] ^ _ ` { | } ~. If you don't include this switch, the password can contain punctuation.

$sel:excludeUppercase:GetRandomPassword', getRandomPassword_excludeUppercase - Specifies whether to exclude uppercase letters from the password. If you don't include this switch, the password can contain uppercase letters.

$sel:includeSpace:GetRandomPassword', getRandomPassword_includeSpace - Specifies whether to include the space character. If you include this switch, the password can contain space characters.

$sel:passwordLength:GetRandomPassword', getRandomPassword_passwordLength - The length of the password. If you don't include this parameter, the default length is 32 characters.

$sel:requireEachIncludedType:GetRandomPassword', getRandomPassword_requireEachIncludedType - Specifies whether to include at least one upper and lowercase letter, one number, and one punctuation. If you don't include this switch, the password contains at least one of every character type.

Request Lenses

getRandomPassword_excludeCharacters :: Lens' GetRandomPassword (Maybe Text) Source #

A string of the characters that you don't want in the password.

getRandomPassword_excludeLowercase :: Lens' GetRandomPassword (Maybe Bool) Source #

Specifies whether to exclude lowercase letters from the password. If you don't include this switch, the password can contain lowercase letters.

getRandomPassword_excludeNumbers :: Lens' GetRandomPassword (Maybe Bool) Source #

Specifies whether to exclude numbers from the password. If you don't include this switch, the password can contain numbers.

getRandomPassword_excludePunctuation :: Lens' GetRandomPassword (Maybe Bool) Source #

Specifies whether to exclude the following punctuation characters from the password: ! " # $ % & ' ( ) * + , - . / : ; < = > ? @ [ \ ] ^ _ ` { | } ~. If you don't include this switch, the password can contain punctuation.

getRandomPassword_excludeUppercase :: Lens' GetRandomPassword (Maybe Bool) Source #

Specifies whether to exclude uppercase letters from the password. If you don't include this switch, the password can contain uppercase letters.

getRandomPassword_includeSpace :: Lens' GetRandomPassword (Maybe Bool) Source #

Specifies whether to include the space character. If you include this switch, the password can contain space characters.

getRandomPassword_passwordLength :: Lens' GetRandomPassword (Maybe Natural) Source #

The length of the password. If you don't include this parameter, the default length is 32 characters.

getRandomPassword_requireEachIncludedType :: Lens' GetRandomPassword (Maybe Bool) Source #

Specifies whether to include at least one upper and lowercase letter, one number, and one punctuation. If you don't include this switch, the password contains at least one of every character type.

Destructuring the Response

data GetRandomPasswordResponse Source #

See: newGetRandomPasswordResponse smart constructor.

Constructors

GetRandomPasswordResponse' 

Fields

Instances

Instances details
Generic GetRandomPasswordResponse Source # 
Instance details

Defined in Amazonka.SecretsManager.GetRandomPassword

Associated Types

type Rep GetRandomPasswordResponse :: Type -> Type #

Show GetRandomPasswordResponse Source # 
Instance details

Defined in Amazonka.SecretsManager.GetRandomPassword

NFData GetRandomPasswordResponse Source # 
Instance details

Defined in Amazonka.SecretsManager.GetRandomPassword

Eq GetRandomPasswordResponse Source # 
Instance details

Defined in Amazonka.SecretsManager.GetRandomPassword

type Rep GetRandomPasswordResponse Source # 
Instance details

Defined in Amazonka.SecretsManager.GetRandomPassword

type Rep GetRandomPasswordResponse = D1 ('MetaData "GetRandomPasswordResponse" "Amazonka.SecretsManager.GetRandomPassword" "amazonka-secretsmanager-2.0-8tljeZ4CwL92E7JavkDb0o" 'False) (C1 ('MetaCons "GetRandomPasswordResponse'" 'PrefixI 'True) (S1 ('MetaSel ('Just "randomPassword") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe (Sensitive Text))) :*: S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int)))

newGetRandomPasswordResponse Source #

Create a value of GetRandomPasswordResponse 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:

$sel:randomPassword:GetRandomPasswordResponse', getRandomPasswordResponse_randomPassword - A string with the password.

$sel:httpStatus:GetRandomPasswordResponse', getRandomPasswordResponse_httpStatus - The response's http status code.

Response Lenses