-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
feat: marketing opt in API #19653
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: marketing opt in API #19653
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
api integration to fetch existing marketing opt in status is missing
Added get API. |
himanshuchawla009
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
|
| const fetchMarketingStatus = async () => { | ||
| try { | ||
| const data = await OAuthService.getMarketingOptInStatus(); | ||
| dispatch(setDataCollectionForMarketing(data.is_opt_in)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it possible to get false but the client have stored already a truly value?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We are syncing data both time at the time of updating switch state via update API and at the time of opening page.
| oauthLoginError: null, | ||
| }); | ||
| }; | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You might want to create a new service for this?
I dont see these function require data from OauthService class or viceversa.
| dispatch(setDataCollectionForMarketing(value)); | ||
|
|
||
| if (isSeedlessOnboardingLoginFlow) { | ||
| OAuthService.updateMarketingOptInStatus(value).catch((error) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You should update the Marketing Status to the server during the submission.
user could tick then untick the check box



Description
Changelog
CHANGELOG entry: MarketingOptIn API added: https://consensyssoftware.atlassian.net/browse/SL-154
Related issues
Fixes:
Manual testing steps
Screenshots/Recordings
Before
After
marketing_api.mp4
Pre-merge author checklist
Pre-merge reviewer checklist