Skip to main content
1 of 2
Keith C
  • 137.3k
  • 29
  • 218
  • 458

I tried the "comm__namedPage" approach shown in the question with names of:

  • cvcp__event-details
  • c__event-details
  • event-details

and none of those worked.

What did work, and with the benefit of being able to inject query parameters (that I would have preferred to use "state" for but the API does not allow that) was:

Map<String, Object> pageRef = new Map<String, Object>{
    'type' => 'standard__webPage',
    'attributes' => new Map<String, Object> {
        'url' => '/portal/s/event-details?eventId=a0756000005VLI3AAO'
    }
};
notification.setTargetPageRef(JSON.serialize(pageRef));

So I will be using his approach for now. (The CSP error shown in the question is output but the navigation works.)

Keith C
  • 137.3k
  • 29
  • 218
  • 458