@Generated(value="jsii-pacmak/1.74.0 (build 6d08790)",
date="2023-03-28T21:34:23.801Z")
public interface SecretAttributes
One ARN format (secretArn
, secretCompleteArn
, secretPartialArn
) must be provided.
Example:
Key encryptionKey; ISecret secret = Secret.fromSecretAttributes(this, "ImportedSecret", SecretAttributes.builder() .secretArn("arn:aws:secretsmanager:<region>:<account-id-number>:secret:<secret-name>-<random-6-characters>") // If the secret is encrypted using a KMS-hosted CMK, either import or reference that key: .encryptionKey(encryptionKey) .build());
Modifier and Type | Interface and Description |
---|---|
static class |
SecretAttributes.Builder
A builder for
SecretAttributes |
static class |
SecretAttributes.Jsii$Proxy
An implementation for
SecretAttributes |
Modifier and Type | Method and Description |
---|---|
static SecretAttributes.Builder |
builder() |
default IKey |
getEncryptionKey()
The encryption key that is used to encrypt the secret, unless the default SecretsManager key is used.
|
default java.lang.String |
getSecretArn()
Deprecated.
use `secretCompleteArn` or `secretPartialArn` instead.
|
default java.lang.String |
getSecretCompleteArn()
The complete ARN of the secret in SecretsManager.
|
default java.lang.String |
getSecretPartialArn()
The partial ARN of the secret in SecretsManager.
|
default IKey getEncryptionKey()
@Deprecated default java.lang.String getSecretArn()
Cannot be used with secretCompleteArn
or secretPartialArn
.
default java.lang.String getSecretCompleteArn()
This is the ARN including the Secrets Manager 6-character suffix.
Cannot be used with secretArn
or secretPartialArn
.
default java.lang.String getSecretPartialArn()
This is the ARN without the Secrets Manager 6-character suffix.
Cannot be used with secretArn
or secretCompleteArn
.
static SecretAttributes.Builder builder()
SecretAttributes.Builder
of SecretAttributes