AWS SECRETS MANAGER EXTENSIONS
Every Swamp extension that covers AWS Secrets Manager, as published in the
registry. Install any of them with swamp extension pull.
Extensions
| Extension | Version | License | Contents |
|---|---|---|---|
| @swamp/aws-sm | 2026.10.13.1 | - | 1 vault types |
| @swamp/aws/secretsmanager | 2026.10.13.1 | - | 4 behavior types |
@swamp/aws-sm
swamp extension pull @swamp/aws-smVault type @swamp/aws-sm
AWS Secrets Manager vault provider. Authenticates via the default AWS credential chain, or a named profile when one is configured.
Configuration fields, passed to swamp vault create as --config JSON:
| Name | Type | Required | Description |
|---|---|---|---|
region |
string | yes | AWS region where the Secrets Manager secrets are stored e.g. us-east-1 |
profile |
string | no | Named AWS profile from ~/.aws/config or ~/.aws/credentials. When omitted, the default AWS credential chain is used. A configured profile takes precedence over environment-variable credentials. |
@swamp/aws/secretsmanager
swamp extension pull @swamp/aws/secretsmanagerBehavior type @swamp/aws/secretsmanager/resource-policy
Global arguments, set with --global-arg on swamp behavior create:
| Name | Type | Required | Description |
|---|---|---|---|
name |
string | yes | Instance name for this resource (used as the unique identifier in the factory pattern) |
accessKeyId |
string | no | AWS access key ID; overrides AWS_ACCESS_KEY_ID environment variable. Wire with a vault.get(...) expression to source it from a vault. |
secretAccessKey |
string | no | AWS secret access key; overrides AWS_SECRET_ACCESS_KEY environment variable. Wire with a vault.get(...) expression to source it from a vault. |
sessionToken |
string | no | AWS session token for temporary credentials; overrides AWS_SESSION_TOKEN environment variable. Wire with a vault.get(...) expression to source it from a vault. |
region |
string | no | AWS region; overrides AWS_REGION / AWS_DEFAULT_REGION environment variables and ~/.aws/config profile region. Defaults to us-east-1. |
SecretId |
string | yes | The ARN or name of the secret to attach the resource-based policy. |
ResourcePolicy |
object | yes | A JSON-formatted string for an AWS resource-based policy. |
BlockPublicPolicy |
boolean | no | Specifies whether to block resource-based policies that allow broad access to the secret. |
Methods, run with swamp behavior run:
| Method | Description | Arguments |
|---|---|---|
create |
Create a SecretsManager ResourcePolicy | - |
get |
Get a SecretsManager ResourcePolicy | identifier |
update |
Update a SecretsManager ResourcePolicy | - |
delete |
Delete a SecretsManager ResourcePolicy | identifier |
sync |
Sync SecretsManager ResourcePolicy state from AWS | - |
list |
List SecretsManager ResourcePolicy resources | maxPages (optional), resourceModel (optional) |
Data written:
| Resource | Description |
|---|---|
state |
SecretsManager ResourcePolicy resource state |
Behavior type @swamp/aws/secretsmanager/rotation-schedule
Global arguments, set with --global-arg on swamp behavior create:
| Name | Type | Required | Description |
|---|---|---|---|
name |
string | yes | Instance name for this resource (used as the unique identifier in the factory pattern) |
accessKeyId |
string | no | AWS access key ID; overrides AWS_ACCESS_KEY_ID environment variable. Wire with a vault.get(...) expression to source it from a vault. |
secretAccessKey |
string | no | AWS secret access key; overrides AWS_SECRET_ACCESS_KEY environment variable. Wire with a vault.get(...) expression to source it from a vault. |
sessionToken |
string | no | AWS session token for temporary credentials; overrides AWS_SESSION_TOKEN environment variable. Wire with a vault.get(...) expression to source it from a vault. |
region |
string | no | AWS region; overrides AWS_REGION / AWS_DEFAULT_REGION environment variables and ~/.aws/config profile region. Defaults to us-east-1. |
HostedRotationLambda |
object {Runtime?: string, KmsKeyArn?: string, MasterSecretArn?: string, RotationLambdaName?: string, RotationType: string, ExcludeCharacters?: string, VpcSecurityGroupIds?: string, MasterSecretKmsKeyArn?: string, SuperuserSecretArn?: string, SuperuserSecretKmsKeyArn?: string, VpcSubnetIds?: string} | no | Creates a new Lambda rotation function based on one of the Secrets Manager rotation function templates. To use a rotation function that already exists, specify RotationLambdaARN instead. |
SecretId |
string | yes | The ARN or name of the secret to rotate. |
ExternalSecretRotationMetadata |
array of object {Value: string, Key: string} | no | The list of metadata needed to successfully rotate a managed external secret. |
ExternalSecretRotationRoleArn |
string | no | The ARN of the IAM role that is used by Secrets Manager to rotate a managed external secret. |
RotateImmediatelyOnUpdate |
boolean | no | Specifies whether to rotate the secret immediately or wait until the next scheduled rotation window. |
RotationLambdaARN |
string | no | The ARN of an existing Lambda rotation function. To specify a rotation function that is also defined in this template, use the Ref function. |
RotationRules |
object {ScheduleExpression?: string, Duration?: string, AutomaticallyAfterDays?: integer} | no | A structure that defines the rotation configuration for this secret. |
Methods, run with swamp behavior run:
| Method | Description | Arguments |
|---|---|---|
create |
Create a SecretsManager RotationSchedule | - |
get |
Get a SecretsManager RotationSchedule | identifier |
update |
Update a SecretsManager RotationSchedule | - |
delete |
Delete a SecretsManager RotationSchedule | identifier |
sync |
Sync SecretsManager RotationSchedule state from AWS | - |
list |
List SecretsManager RotationSchedule resources | maxPages (optional), resourceModel (optional) |
Data written:
| Resource | Description |
|---|---|
state |
SecretsManager RotationSchedule resource state |
Behavior type @swamp/aws/secretsmanager/secret
Global arguments, set with --global-arg on swamp behavior create:
| Name | Type | Required | Description |
|---|---|---|---|
name |
string | yes | Instance name for this resource (used as the unique identifier in the factory pattern) |
accessKeyId |
string | no | AWS access key ID; overrides AWS_ACCESS_KEY_ID environment variable. Wire with a vault.get(...) expression to source it from a vault. |
secretAccessKey |
string | no | AWS secret access key; overrides AWS_SECRET_ACCESS_KEY environment variable. Wire with a vault.get(...) expression to source it from a vault. |
sessionToken |
string | no | AWS session token for temporary credentials; overrides AWS_SESSION_TOKEN environment variable. Wire with a vault.get(...) expression to source it from a vault. |
region |
string | no | AWS region; overrides AWS_REGION / AWS_DEFAULT_REGION environment variables and ~/.aws/config profile region. Defaults to us-east-1. |
Description |
string | no | The description of the secret. |
KmsKeyId |
string | no | The ARN, key ID, or alias of the KMS key that Secrets Manager uses to encrypt the secret value in the secret. An alias is always prefixed by alias/, for example alias/aws/secretsmanager. For more information, see About aliases. To use a KMS key in a different account, use the key ARN or the alias ARN. If you don't specify this value, then Secrets Manager uses the key aws/secretsmanager. If that key doesn't yet exist, then Secrets Manager creates it for you automatically the first time it encrypts the secret value. If the secret is in a different AWS account from the credentials calling the API, then you can't use aws/secretsmanager to encrypt the secret, and you must create and use a customer managed KMS key. |
SecretString |
string | no | The text to encrypt and store in the secret. We recommend you use a JSON structure of key/value pairs for your secret value. To generate a random password, use GenerateSecretString instead. If you omit both GenerateSecretString and SecretString, you create an empty secret. When you make a change to this property, a new secret version is created. |
GenerateSecretString |
object {ExcludeUppercase?: boolean, RequireEachIncludedType?: boolean, IncludeSpace?: boolean, ExcludeCharacters?: string, GenerateStringKey?: string, PasswordLength?: integer, ExcludePunctuation?: boolean, ExcludeLowercase?: boolean, SecretStringTemplate?: string, ExcludeNumbers?: boolean} | no | A structure that specifies how to generate a password to encrypt and store in the secret. To include a specific string in the secret, use SecretString instead. If you omit both GenerateSecretString and SecretString, you create an empty secret. When you make a change to this property, a new secret version is created. We recommend that you specify the maximum length and include every character type that the system you are generating a password for can support. |
ReplicaRegions |
array of object {KmsKeyId?: string, Region: string} | no | A custom type that specifies a Region and the KmsKeyId for a replica secret. |
Tags |
array of object {Value: string, Key: string} | no | A list of tags to attach to the secret. Each tag is a key and value pair of strings in a JSON text string, for example: [{"Key":"CostCenter","Value":"12345"},{"Key":"environment","Value":"production"}] Secrets Manager tag key names are case sensitive. A tag with the key "ABC" is a different tag from one with key "abc". Stack-level tags, tags you apply to the CloudFormation stack, are also attached to the secret. If you check tags in permissions policies as part of your security strategy, then adding or removing a tag can change permissions. If the completion of this operation would result in you losing your permissions for this secret, then Secrets Manager blocks the operation and returns an Access Denied error. For more information, see Control access to secrets using tags and Limit access to identities with tags that match secrets' tags. For information about how to format a JSON parameter for the various command line tool environments, see Using JSON for Parameters. If your command-line tool or SDK requires quotation marks around the parameter, you should use single quotes to avoid confusion with the double quotes required in the JSON text. The following restrictions apply to tags: Maximum number of tags per secret: 50 Maximum key length: 127 Unicode characters in UTF-8 Maximum value length: 255 Unicode characters in UTF-8 Tag keys and values are case sensitive. Do not use the aws: prefix in your tag names or values because AWS reserves it for AWS use. You can't edit or delete tag names or values with this prefix. Tags with this prefix do not count against your tags per secret limit. If you use your tagging schema across multiple services and resources, other services might have restrictions on allowed characters. Generally allowed characters: letters, spaces, and numbers representable in UTF-8, plus the following special characters: + - =. _: / @. |
Name |
string | no | The name of the new secret. The secret name can contain ASCII letters, numbers, and the following characters: /_+=.@- Do not end your secret name with a hyphen followed by six characters. If you do so, you risk confusion and unexpected results when searching for a secret by partial ARN. Secrets Manager automatically adds a hyphen and six random characters after the secret name at the end of the ARN. |
Type |
string | no | The exact string that identifies the third-party partner that holds the external secret. For more information, see Managed external secret partners. |
Methods, run with swamp behavior run:
| Method | Description | Arguments |
|---|---|---|
create |
Create a SecretsManager Secret | - |
get |
Get a SecretsManager Secret | identifier |
update |
Update a SecretsManager Secret | - |
delete |
Delete a SecretsManager Secret | identifier |
sync |
Sync SecretsManager Secret state from AWS | - |
list |
List SecretsManager Secret resources | maxPages (optional), resourceModel (optional) |
Data written:
| Resource | Description |
|---|---|
state |
SecretsManager Secret resource state |
Behavior type @swamp/aws/secretsmanager/secret-target-attachment
Global arguments, set with --global-arg on swamp behavior create:
| Name | Type | Required | Description |
|---|---|---|---|
name |
string | yes | Instance name for this resource (used as the unique identifier in the factory pattern) |
accessKeyId |
string | no | AWS access key ID; overrides AWS_ACCESS_KEY_ID environment variable. Wire with a vault.get(...) expression to source it from a vault. |
secretAccessKey |
string | no | AWS secret access key; overrides AWS_SECRET_ACCESS_KEY environment variable. Wire with a vault.get(...) expression to source it from a vault. |
sessionToken |
string | no | AWS session token for temporary credentials; overrides AWS_SESSION_TOKEN environment variable. Wire with a vault.get(...) expression to source it from a vault. |
region |
string | no | AWS region; overrides AWS_REGION / AWS_DEFAULT_REGION environment variables and ~/.aws/config profile region. Defaults to us-east-1. |
SecretId |
string | yes | - |
TargetType |
string | yes | - |
TargetId |
string | yes | - |
Methods, run with swamp behavior run:
| Method | Description | Arguments |
|---|---|---|
create |
Create a SecretsManager SecretTargetAttachment | - |
get |
Get a SecretsManager SecretTargetAttachment | identifier |
update |
Update a SecretsManager SecretTargetAttachment | - |
delete |
Delete a SecretsManager SecretTargetAttachment | identifier |
sync |
Sync SecretsManager SecretTargetAttachment state from AWS | - |
list |
List SecretsManager SecretTargetAttachment resources | maxPages (optional), resourceModel (optional) |
Data written:
| Resource | Description |
|---|---|
state |
SecretsManager SecretTargetAttachment resource state |