Conversation

US
Last activity: 19 Aug 2025 11:33 EDT
Web Embed to render a list page: How to pass a param into web embed to use as input to list's data page?
Hello!
Would like to use Constellation's Web Embed in an Angular app to render a Constellation List page driven by a Data Page, but need to pass the DP a parameter (the passed parameter controls what results are returned in the List)
What is the best way to pass a parameter (i.e. customerID) from the Angular app into the web embed, and use the passed parameter as an input into the Data Page bound to the List? Here's the exploration I've done so far:
First, the Web Embed channel, configured to "Display a page".
Exploration 1:
The web embed documentation says you can add additionalHeaders attribute to the web embed snippet to send key/val pairs as JSON. However, if I set a parameter that way, I'm not immediately clear on best way to retrieve it on the server side in order to pass it into the Data Page as an input. ( Maybe a Data Page that calls a wrapper Activity that uses Java to pull it off the requestor and pass it to the Data Page? That feels convoluted.)
Exploration 2:
The Web Embed JS API doc for setEmbedData says it can be used not only for an Assignment, but also for a page. So, in Angular app I could call setEmbedData("customerID", "123456") before loading the web embed.
However, I'm not clear on how setEmbedData can be used with a page. I do not immediately see a way to "plumb" the passed value into the data page.
Here's the view configuration for List page that will render in the web embed. Notice the DP takes a parameter. For the the parameter, I can only choose "constant" or "Field on operator." There's not an on option for retrieving it from a page property set with setEmbedData() api.
Thanks!