Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EventsSDK: Add originalEventName to EventPayload #138

Merged
merged 9 commits into from
Feb 28, 2024
Prev Previous commit
Next Next commit
fix merge conflct
fix merge conflct
ejaffee01 authored Feb 28, 2024
commit f4c66a1961a02efca6ad65c2547cedd55d48ffad
23 changes: 7 additions & 16 deletions src/EventPayload.ts
Original file line number Diff line number Diff line change
@@ -106,20 +106,22 @@ export interface EventPayload {
* or the value of the `ip` property if specified.
*/
location?: Coordinates | string;
/** The URL of the page where the event occurred.
*
* If not specified the system will automatically
* use the `Referrer` header from the autogenerated request headers.
*/
/** Fields specific to reporting Yext Pages Analytics Events */
pages?: {
/** The scope of an action. Applies to Pages events. */
scope?: string;
/** The Event name as it was used in previous analytics implementations. */
originalEventName?: string;
/* The UID of the site an event was tied to. */
siteUid?: number;
/* The ID of the template from which a site was generated. */
template?: string;
};
/** The URL of the page where the event occurred.
*
* If not specified the system will automatically
* use the `Referrer` header from the autogenerated request headers.
*/
pageUrl?: string;
/** The URL of the page which the visitor came from prior to the event.
*
@@ -148,17 +150,6 @@ export interface EventPayload {
searchTerm?: string;
/** Unique identifier to tie together events in a single browsing session */
sessionId?: string | null;
/** Fields specific to reporting Yext Pages Analytics Events */
pages?: {
/** The scope of an action. Applies to Pages events. */
scope?: string;
/** The Event name as it was used in previous analytics implementations. */
originalEventName?: string;
/* The UID of the site an event was tied to. */
siteUid?: number;
/* The ID of the template from which a site was generated. */
template?: string;
};
/** The timestamp at which the event occurred, in ISO format.
* For example, September 27, 2022 at 6 p.m. is represented as
* 2022-09-27 18:00:00.000.