Repository navigation
feat(messaging): add email headers and the enrollment invite input - #135
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Brings the shared messaging shapes level with
@seamless-auth/messaging, so fells-code/seamless-auth-messaging#17 can re-export them instead of keeping two local definitions.Changes
EmailMessageSchemagainsheaders: z.record(z.string(), z.string()).optional(). This matches the field added in feat(email): carry custom headers through to SES seamless-auth-messaging#14. The schema only checks the shape. Header name and value validation (no injected headers, no overriding From, To or Subject) stays in the messaging transports, which own the send.SendEnrollmentInviteEmailInputSchemaand its inferredSendEnrollmentInviteEmailInput, matching the messaging package's input for the passkey enrollment invite email.Both are additive, so this is a
minorchangeset. The inferredEmailMessagetype widens with an optional field, which is noted in the changeset.Tests
New cases in
src/schemas/messaging/schema.test.tscover a message with and without headers, a non-string header value, and an invite with and withoutsignInUrl.npm run typecheck,npm run lint,npm run format:checkandnpm test(515 passing) all pass locally.Rollout
Once this is published, the messaging package's
EmailMessageandSendEnrollmentInviteEmailInputbecome plain re-exports from@seamless-auth/types.