[MKT-737]:feat/integrate Klaviyo subscription when creating Send links#945
Open
jaaaaavier wants to merge 3 commits intomasterfrom
Open
[MKT-737]:feat/integrate Klaviyo subscription when creating Send links#945jaaaaavier wants to merge 3 commits intomasterfrom
jaaaaavier wants to merge 3 commits intomasterfrom
Conversation
|
src/modules/send/send.usecase.spec.ts
Dismissed
| title: 'title', | ||
| subject: 'subject', | ||
| expirationAt: new Date(), | ||
| hashedPassword: 'hashed', |
Check failure
Code scanning / SonarCloud
Credentials should not be hard-coded High test
Contributor
Author
There was a problem hiding this comment.
Thats a false positive
|
This PR is stale because it has been open for more than 15 days with no activity. |
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.

This PR introduces the integration with Klaviyo for the Send feature. It ensures that whenever a user creates a Send link, the sender's email is automatically subscribed to a specific Klaviyo list.
Key Changes:
NewsletterService: Modified the subscribe method to accept an optional listId parameter, making it reusable to subscribe users to different Klaviyo lists using the newly assigned resolvedListId.
Configuration updates: Added klaviyo.sendListId to the configuration, retrieving the list ID dynamically from the .env
(using the variable KLAVIYO_SEND_LIST_ID).
SendUseCases tracking integration: Integrated the NewsletterService into the createSendLinks use case. The subscription call is executed as a fire-and-forget background task (with .catch), ensuring it does not block the link creation process or affect performance if Klaviyo is unreachable.