Skip to content
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

[Bug]: ContentCard Subscription issue #163

Closed
CorentinRobertSmood opened this issue Dec 26, 2024 · 6 comments
Closed

[Bug]: ContentCard Subscription issue #163

CorentinRobertSmood opened this issue Dec 26, 2024 · 6 comments
Labels

Comments

@CorentinRobertSmood
Copy link

Braze Web SDK Version

5.5.0 5.6.0 5.6.1

Integration Method

CDN

Browser

Chrome

Steps To Reproduce

create a file with all braze initialisation (service worker etc ...), create methode with subscription update content card (subscribeToContentCardsUpdates).
create UI listing and display all content card when subscription trigger
send content card from dashboard
I receive push web notifications but never content card

Braze: Service worker 5.6.1 received push
service-worker.js:7 Braze: Displaying push notification!

I tried to waiting few second in initialize sdk and after that subscribe.
I tried to waiting Braze.isInitialised with listener but doesn't works.

Expected Behavior

Like react native sdk when i subscribe to this listener i would receive all content cards

Actual Incorrect Behavior

Get content card on Braze.subscribeToContentCardsUpdates() methods

Verbose Logs

No response

Additional Information

No response

@wesleyorbin
Copy link
Collaborator

Hi @CorentinRobertSmood. In order to display your test content card, you must click on the push notification that you received. Please let me know if this does not work.

@CorentinRobertSmood
Copy link
Author

Hello,

Is this behavior intended?

Subscription by the listener should not depend on push notifications tap ?

should this be done without user action?

@wesleyorbin
Copy link
Collaborator

It is expected behavior. Since this is only for test sends, it does not affect the end-user functionality of the SDK. However, browser support for postMessage is probably sufficient at this point for us to consider switching to that. I'll file a ticket internally to research that and implement it if there are no blockers. Since this is expected behavior, I'm going to close out this issue, but feel free to re-open if you do not receive the test card upon clicking the push notification.

@CorentinRobertSmood
Copy link
Author

@wesleyorbin Another question if i'm in app and subscribe with listener, i must click on notification to receive content card ? Because for instance i didn't receive any content card when i send test content card like i explain in the ticket.

@CorentinRobertSmood
Copy link
Author

@wesleyorbin Another question if i'm in app and subscribe with listener, i must click on notification to receive content card ? Because for instance i didn't receive any content card when i send test content card like i explain in the ticket.

Don't have permission to reopen ticket

@wesleyorbin
Copy link
Collaborator

@CorentinRobertSmood Yes, you do need to click on the notification to receive the content card. This is only the case for test sends.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants