const xg = new XGenClient({
key: '<your_api_key>',
secret: '<your_api_secret>',
clientId: '<your_client_id>',
trackerId: '<your_tracker_id>',
getEnv: () => 'stage', // optional: function that returns the environment (`stage` or `prod`) - defaults to 'prod'
authStore: new LocalCookieAuthStore() // optional - can pass in a custom auth store instance - defaults to LocalCookieAuthStore
});
Creating new client instance
- Published on Apr 28, 2025
- 1 minute(s) read