0

I have a requirement where i have to refresh the page automatically when a record changes, i'm doing this using platform events whenever an event is published the VF page that has subscribed to the streaming API will execute a script to change DOM element, this functionality works well for the vf page in the org but when the vf page is appended with the site(external site user) the functionality fails to subscribe to the platform event.Does anyone have a solution for this?

2
  • guest user or authenticated user?
    – cropredy
    Mar 23 '20 at 17:40
  • For a guest user Mar 24 '20 at 21:08
0

Streaming-api subscription requires that the User have access to the Push Topic. Normally this access is granted through the Profile or PermissionSet.

https://developer.salesforce.com/docs/atlas.en-us.api_streaming.meta/api_streaming/working_with_pushtopics.htm

As @cropredy commented, is this an unauthenticated use case?

1
  • It'll be a guest user who will interact with the vf page.... Basically what I want to build is a chat box where two different guest users can converse on this page(we cannot use web chat or chatter on sites I guess) so if I refresh the Dom through streaming api subscription I may be able to create a flow..... Any better idea to create a chat functionality would be much appreciated as I think this idea in itself seems crazy Mar 24 '20 at 21:09

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.