node_v3.5_sdk
To get up and running:
- Clone the repo:
git clone https://github.com/michal-optimizely/node_v3.5_sdk.git
- Enter the new folder:
cd node_v3.5_sdk
- Install dependencies:
npm install
- Execute the app code:
node app.js
Usage notes
- Line 10: (Un)comment this line if you want to enable SDK logs. Select the log level.
- Line 12: Provide the SDK key you want to use with the app.
- Line 30: If you need multiple user IDs, enter a number of users you need.
- Line 39: Provide any attributes you might need for passiing audience targeting of your experiments/rollouts.
- Line 57: Option to keep/remove the notification listener.
- Lines 70, 72, 74: If using, enter valid experiment and variation keys.
- Lines 87-99: Enter valid keys, comment-out the lines you don't need.
- Line 108: Choose whether or not the app should auto-exit after executing.
Supported features
- Option to enable Logger.
- Asynchronous initialization.
- Configurable options upon initialization:
- Automatic datafile updates
- Customizable event dispatcher props (max event batch size, flush interval)
- Auto-creation of uuid. Option to generate any number of users.
- Notification listener for notification types 'DECISION' (with option to remove it) & 'CONFIG_UPDATE'.
- Examples of all available client API calls.
- Option to show the content of the Optimizely environment 'config'.
- Termination of the Optimizely client before exiting the app.