What is the reason that ContextAccountId in an embedded OmniScript is not set when previewing through the parent OmniScript?

Prepare for the OmniStudio Developer Test. Dive into a wealth of flashcards and multiple-choice questions, featuring hints and explanations for every scenario. Ace your exam with ease!

Multiple Choice

What is the reason that ContextAccountId in an embedded OmniScript is not set when previewing through the parent OmniScript?

Explanation:
The main idea is that data can be shared from a parent OmniScript to an embedded one using the LWC PubSub messaging system. When you want the embedded script to receive values set in the parent, you must enable the LWC PubSub Message option on the Set Values action in the parent. If that flag isn’t turned on, the parent won’t publish the values to the embedded OmniScript, so ContextAccountId isn’t populated during preview. ContextAccountId is typically provided by this PubSub message. Without publishing, the embedded script sees no context data and keeps that value unset. Other choices don’t explain the behavior because PubSub is the mechanism that actually passes data between embedded scripts; merely naming elements, adding a Navigation Element, or stating that data can’t be passed wouldn’t account for the missing ContextAccountId.

The main idea is that data can be shared from a parent OmniScript to an embedded one using the LWC PubSub messaging system. When you want the embedded script to receive values set in the parent, you must enable the LWC PubSub Message option on the Set Values action in the parent. If that flag isn’t turned on, the parent won’t publish the values to the embedded OmniScript, so ContextAccountId isn’t populated during preview.

ContextAccountId is typically provided by this PubSub message. Without publishing, the embedded script sees no context data and keeps that value unset. Other choices don’t explain the behavior because PubSub is the mechanism that actually passes data between embedded scripts; merely naming elements, adding a Navigation Element, or stating that data can’t be passed wouldn’t account for the missing ContextAccountId.

Subscribe

Get the latest from Examzify

You can unsubscribe at any time. Read our privacy policy