feat: allow custom key names for AWS SES SMTP credentials in Secrets Manager #1478
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description of Changes
This PR introduces the ability to specify custom key names when storing the AWS SES SMTP server username and password in AWS Secrets Manager. Previously, the library defaulted to using
Credentials.USERNAME
andCredentials.PASSWORD
as the keys. With this update:New Properties:
userNameSecretKey
andpasswordSecretKey
properties to theSesSmtpCredentialsProps
interface.Handler Changes:
credentials-handler.lambda.ts
to utilize the custom key names if provided.Credentials.USERNAME
andCredentials.PASSWORD
) when the custom keys are not specified.Documentation:
Why These Changes?
These enhancements provide greater flexibility when integrating the library into projects with specific naming conventions or requirements for secret storage (specifically the .Net NuGet library I am using to read AWS secrets into configuration). This reduces potential conflicts and aligns with best practices for customizability.
Breaking Changes
No breaking changes. The library retains its default behavior if the new properties are not specified.
Testing
(Please note: This is my first ever PR :) While I had help from AI with this PR template, the code itself is definitely not AI generated! I also would be happy to implement the "update" functionality in the custom resource handler after this PR is complete. Thanks, CI)