I am interested in adding the Answers overlay to my site. I would love to be able to customize the prompts based on the url that someone is on. For example, if someone is looking at a particular hotel accommodation, I want the prompts in the overlay to be specific to that hotel name which is in the url. Could this be accomplished via query rules or via a different method?
For example:
If I’m on this page, can I customize the prompts to be specific to the hyatt-place-new-york-city-times-square?
brand.com would be responsible for building this logic and customization. The prompts (and how they are set) are entirely owned by them.
In short, yes, but the brand’s frontend development team would need to customize the overlay JS. They’d pull information on the location, then they could likely use that variable as conditionals in the overlay’s JS to set the prompts and the panel subtitle. They’d need to be mindful that the information is ready at the right time (before the overlay script executes).
The logic itself would also not come from Yext – the overlay itself doesn’t have knowledge of the knowledge graph (no pun intended). In other words, the brand would need to know, "if this is a page for hyatt NY, it will have a good breakfast, so the prompt should be “what should be in the good breakfast offering”', independently.
You can use query rules to adjust the content being searched (the referrer URL is the page on which the overlay is placed, so could work nicely here), but these do not impact the prompts.