Skip to content

Commit

Permalink
EventsSDK: create AnalyticsConfig interface
Browse files Browse the repository at this point in the history
Create AnalyticsConfig interface.

J=FUS-5867
TEST=none
  • Loading branch information
swong1213 committed Aug 21, 2023
1 parent 768b4ca commit b5c6ad0
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions src/AnalyticsConfig.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
import {Environment} from './models';
import {Region} from './models';

/**
* The main configuration options for Analytics Events.
*
* @public
*/
export interface AnalyticsConfig {
key?: string;
bearer?: string;
/** The Yext environment to send requests to. Defaults to 'PRODUCTION'. */
env?: Environment;
/** The region to send requests to. Defaults to 'US'. */
region?: Region;
/**
* Whether to enable session tracking for analytics events.
* Defaults to true for both environments
* @remarks
* This generates a ULID to tie together events in a single browsing session.
*/
sessionTrackingEnabled?: boolean;
}

0 comments on commit b5c6ad0

Please sign in to comment.