For the managed package runtime, the Messaging Framework of the Script Setup stores the master list of product impressions sent to Google Analytics Ecommerce.
This information is for Omnistudio for Managed Packages. For Omnistudio on standard runtime, see Omnistudio Help.
- In the Vlocity Omniscript Designer tab, expand Documentation/OmniAnalytics and click E-commerce Buyflow Omniscript (Version 1).
-
Open the general properties of the Omniscript.
-
In the old Omniscript Designer, click Script Configuration.
-
In the new Omniscript Designer, click Setup in the Properties pane.
-
-
Create a new version.
-
In the old Omniscript Designer, click Create Version.
-
In the new Omniscript Designer, click New Version.
-
- Scroll to the Messaging Framework section and expand it.
- Make sure the Window postMessage, Pub/Sub, and Session Storage boxes are checked.
-
Add the following Message Key/Value pairs:
Key
Value
account
Omni-Analytics
impressions
(leave blank)
-
Edit the general properties as JSON code:
-
In the old Omniscript Designer, scroll to the top and click Edit as JSON.
-
In the new Omniscript Designer, scroll to the bottom and click Edit Properties as JSON.
-
-
Replace the
nullvalue or empty quotes after theimpressionsnode with the following JSON array. Make sure a colon precedes the opening bracket and a comma follows the closing bracket.[ { "name": "Apple iPhone 7", "price": 699, "brand": "Apple", "category": "Mobile", "variant": "Black", "list": "Search Results", "position": 1, "quantity": 1, "shipping": 19.9, "tax": 17.35, "revenue": 736.25 }, { "name": "Apple iPhone 8", "price": 699, "brand": "Apple", "category": "Mobile", "variant": "White", "list": "Search Results", "position": 2, "quantity": 1, "shipping": 19.9, "tax": 17.35, "revenue": 736.25 }, { "name": "Apple iPhone X", "price": 699, "brand": "Apple", "category": "Mobile", "variant": "Black", "list": "Search Results", "position": 3, "quantity": 1, "shipping": 19.9, "tax": 17.35, "revenue": 736.25 }, { "name": "Apple iPhone 11", "price": 699, "brand": "Apple", "category": "Mobile", "variant": "Black", "list": "Search Results", "position": 4, "quantity": 1, "shipping": 19.9, "tax": 17.35, "revenue": 736.25 }, { "name": "Apple iPhone XR", "price": 699, "brand": "Apple", "category": "Mobile", "variant": "Black", "list": "Search Results", "position": 5, "quantity": 1, "shipping": 19.9, "tax": 17.35, "revenue": 736.25 } ] -
Exit the JSON editor.
-
In the old Omniscript Designer, scroll to the top and click Edit as Properties.
-
In the new Omniscript Designer, scroll to the bottom and click Close JSON Editor.
-
What’s next: Add Data to the Select Device Step (Managed Package).