Interface CredentialsBaseOptions
- All Superinterfaces:
software.amazon.jsii.JsiiSerializable
- All Known Subinterfaces:
CredentialsFromUsernameOptions
- All Known Implementing Classes:
CredentialsBaseOptions.Jsii$Proxy,CredentialsFromUsernameOptions.Jsii$Proxy
@Generated(value="jsii-pacmak/1.120.0 (build 192dc88)",
date="2025-12-05T22:26:43.787Z")
@Stability(Stable)
public interface CredentialsBaseOptions
extends software.amazon.jsii.JsiiSerializable
Base options for creating Credentials.
Example:
Vpc vpc;
IInstanceEngine engine = DatabaseInstanceEngine.postgres(PostgresInstanceEngineProps.builder().version(PostgresEngineVersion.VER_16_3).build());
Key myKey = new Key(this, "MyKey");
DatabaseInstance.Builder.create(this, "InstanceWithCustomizedSecret")
.engine(engine)
.vpc(vpc)
.credentials(Credentials.fromGeneratedSecret("postgres", CredentialsBaseOptions.builder()
.secretName("my-cool-name")
.encryptionKey(myKey)
.excludeCharacters("!&*^#@()")
.replicaRegions(List.of(ReplicaRegion.builder().region("eu-west-1").build(), ReplicaRegion.builder().region("eu-west-2").build()))
.build()))
.build();
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classA builder forCredentialsBaseOptionsstatic final classAn implementation forCredentialsBaseOptions -
Method Summary
Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getEncryptionKey
KMS encryption key to encrypt the generated secret.Default: - default master key
-
getExcludeCharacters
The characters to exclude from the generated password.Has no effect if
passwordhas been provided.Default: - the DatabaseSecret default exclude character set (" %+~`#$invalid input: '&'*()|[]{}:;invalid input: '<'>?!'/@\"\\")
-
getReplicaRegions
A list of regions where to replicate this secret.Default: - Secret is not replicated
-
getSecretName
The name of the secret.Default: - A name is generated by CloudFormation.
-
builder
- Returns:
- a
CredentialsBaseOptions.BuilderofCredentialsBaseOptions
-