Config API for Switching Products in a Single Page Application(SPA)
This article explains how to configure API for Switching Products in a Single Page Application(SPA).
Overview
Gainsight PX provides the feature JS SDK Reset Method to have the PX tag loaded in a multi-product environment under the same wrapping iframe/shell. In such an environment, PX requires the ability to switch product keys since users are switching between applications without a full page reload (relevant to Single Page Application). The reset method provides a function in the SDK that allows you to reset the SDK and pass in the relevant product key.
Syntax
The syntax of the API is:
window.aptrinsic('config','tagKey',productKey);
In the above syntax, tagKey refers to the Gainsight PX tag that you obtain from Administration > Products page.