@adtrackify/at-tracking-event-types 1.1.0-alpha → 1.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +87 -54
- package/dist/index.js +1 -1
- package/dist/index.js.map +4 -4
- package/package.json +1 -1
- package/src/types/adtrackify-event-bus-event.ts +1 -1
- package/src/types/common/address.ts +16 -0
- package/src/types/common/index.ts +1 -0
- package/src/types/index.ts +4 -2
- package/src/types/tracking-events/index.ts +4 -0
- package/src/types/tracking-events/tracking-event-context.ts +46 -0
- package/src/types/tracking-events/tracking-event-identity.ts +21 -0
- package/src/types/{tracking-event-type.ts → tracking-events/tracking-event-type.ts} +7 -78
package/dist/index.d.ts
CHANGED
|
@@ -3,7 +3,7 @@ declare module '@adtrackify/at-tracking-event-types/index' {
|
|
|
3
3
|
|
|
4
4
|
}
|
|
5
5
|
declare module '@adtrackify/at-tracking-event-types/types/adtrackify-event-bus-event' {
|
|
6
|
-
import { TrackingEvent } from '@adtrackify/at-tracking-event-types/types/tracking-event-type';
|
|
6
|
+
import { TrackingEvent } from '@adtrackify/at-tracking-event-types/types/tracking-events/tracking-event-type';
|
|
7
7
|
export interface AdtrackifyEventBusEvent {
|
|
8
8
|
eventId: string;
|
|
9
9
|
eventType: string;
|
|
@@ -340,13 +340,37 @@ declare module '@adtrackify/at-tracking-event-types/types/api/user' {
|
|
|
340
340
|
family_name: string;
|
|
341
341
|
}
|
|
342
342
|
|
|
343
|
+
}
|
|
344
|
+
declare module '@adtrackify/at-tracking-event-types/types/common/address' {
|
|
345
|
+
export interface AddressInfo {
|
|
346
|
+
email?: string;
|
|
347
|
+
phone?: string;
|
|
348
|
+
firstName?: string;
|
|
349
|
+
lastName?: string;
|
|
350
|
+
company?: string;
|
|
351
|
+
address1?: string;
|
|
352
|
+
address2?: string;
|
|
353
|
+
city?: string;
|
|
354
|
+
province?: string;
|
|
355
|
+
provinceCode?: string;
|
|
356
|
+
country?: string;
|
|
357
|
+
countryCode?: string;
|
|
358
|
+
zip?: string;
|
|
359
|
+
}
|
|
360
|
+
|
|
361
|
+
}
|
|
362
|
+
declare module '@adtrackify/at-tracking-event-types/types/common/index' {
|
|
363
|
+
export * from '@adtrackify/at-tracking-event-types/types/common/address';
|
|
364
|
+
|
|
343
365
|
}
|
|
344
366
|
declare module '@adtrackify/at-tracking-event-types/types/index' {
|
|
367
|
+
export * from '@adtrackify/at-tracking-event-types/types/api/index';
|
|
368
|
+
export * from '@adtrackify/at-tracking-event-types/types/common/index';
|
|
345
369
|
export * from '@adtrackify/at-tracking-event-types/types/adtrackify-standard-events';
|
|
346
370
|
export * from '@adtrackify/at-tracking-event-types/types/third-party-event-configuration-types';
|
|
347
|
-
export * from '@adtrackify/at-tracking-event-types/types/tracking-event-type';
|
|
371
|
+
export * from '@adtrackify/at-tracking-event-types/types/tracking-events/tracking-event-type';
|
|
348
372
|
export * from '@adtrackify/at-tracking-event-types/types/adtrackify-event-bus-event';
|
|
349
|
-
export * from '@adtrackify/at-tracking-event-types/types/
|
|
373
|
+
export * from '@adtrackify/at-tracking-event-types/types/tracking-events/index';
|
|
350
374
|
|
|
351
375
|
}
|
|
352
376
|
declare module '@adtrackify/at-tracking-event-types/types/third-party-event-configuration-types' {
|
|
@@ -361,23 +385,20 @@ declare module '@adtrackify/at-tracking-event-types/types/third-party-event-conf
|
|
|
361
385
|
}
|
|
362
386
|
|
|
363
387
|
}
|
|
364
|
-
declare module '@adtrackify/at-tracking-event-types/types/tracking-
|
|
388
|
+
declare module '@adtrackify/at-tracking-event-types/types/tracking-events/index' {
|
|
389
|
+
export * from '@adtrackify/at-tracking-event-types/types/tracking-events/tracking-event-type';
|
|
390
|
+
export * from '@adtrackify/at-tracking-event-types/types/tracking-events/tracking-event-context';
|
|
391
|
+
export * from '@adtrackify/at-tracking-event-types/types/tracking-events/tracking-event-identity';
|
|
392
|
+
|
|
393
|
+
}
|
|
394
|
+
declare module '@adtrackify/at-tracking-event-types/types/tracking-events/tracking-event-context' {
|
|
395
|
+
import { TrackingEventIdentity } from '@adtrackify/at-tracking-event-types/types/tracking-events/tracking-event-identity';
|
|
365
396
|
import { IResult } from 'ua-parser-js';
|
|
366
|
-
import { ADTRACKIFY_STANDARD_EVENT } from '@adtrackify/at-tracking-event-types/types/adtrackify-standard-events';
|
|
367
|
-
export interface TrackingEvent {
|
|
368
|
-
id: string;
|
|
369
|
-
type: string;
|
|
370
|
-
name: ADTRACKIFY_STANDARD_EVENT;
|
|
371
|
-
pixelId: string;
|
|
372
|
-
context: TrackingEventContext;
|
|
373
|
-
data: TrackingEventData;
|
|
374
|
-
testCode?: string;
|
|
375
|
-
sentAtEpoch?: number;
|
|
376
|
-
collectedAt?: string;
|
|
377
|
-
version: string;
|
|
378
|
-
}
|
|
379
397
|
export interface TrackingEventContext {
|
|
380
398
|
identity: TrackingEventIdentity;
|
|
399
|
+
properties?: TrackingEventContextProperties;
|
|
400
|
+
}
|
|
401
|
+
export interface TrackingEventContextProperties {
|
|
381
402
|
click?: AdClickInfo;
|
|
382
403
|
campaign?: CampaignInfo;
|
|
383
404
|
page?: PageInfo;
|
|
@@ -389,10 +410,39 @@ declare module '@adtrackify/at-tracking-event-types/types/tracking-event-type' {
|
|
|
389
410
|
ipv6Address?: string;
|
|
390
411
|
sessionId?: string;
|
|
391
412
|
}
|
|
413
|
+
export interface AdClickInfo {
|
|
414
|
+
fbp?: string;
|
|
415
|
+
fbc?: string;
|
|
416
|
+
fbclid?: string;
|
|
417
|
+
gclid?: string;
|
|
418
|
+
}
|
|
419
|
+
export interface CampaignInfo {
|
|
420
|
+
name?: string;
|
|
421
|
+
source?: string;
|
|
422
|
+
medium?: string;
|
|
423
|
+
term?: string;
|
|
424
|
+
content?: string;
|
|
425
|
+
}
|
|
426
|
+
export interface PageInfo {
|
|
427
|
+
path?: string;
|
|
428
|
+
referrer?: string;
|
|
429
|
+
search?: string;
|
|
430
|
+
title?: string;
|
|
431
|
+
url?: string;
|
|
432
|
+
qsp?: any;
|
|
433
|
+
}
|
|
434
|
+
export type DeviceInfo = IResult;
|
|
435
|
+
|
|
436
|
+
}
|
|
437
|
+
declare module '@adtrackify/at-tracking-event-types/types/tracking-events/tracking-event-identity' {
|
|
438
|
+
import { AddressInfo } from '@adtrackify/at-tracking-event-types/types/common/address';
|
|
392
439
|
export interface TrackingEventIdentity {
|
|
393
|
-
[key: string]: any;
|
|
394
440
|
identityId?: string;
|
|
395
441
|
anonymousId?: string;
|
|
442
|
+
traits?: TrackingEventIdentityTraits;
|
|
443
|
+
}
|
|
444
|
+
export interface TrackingEventIdentityTraits {
|
|
445
|
+
[key: string]: any;
|
|
396
446
|
userId?: string;
|
|
397
447
|
gender?: string;
|
|
398
448
|
dob?: string;
|
|
@@ -404,11 +454,25 @@ declare module '@adtrackify/at-tracking-event-types/types/tracking-event-type' {
|
|
|
404
454
|
address?: AddressInfo;
|
|
405
455
|
addresses?: AddressInfo[];
|
|
406
456
|
}
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
457
|
+
|
|
458
|
+
}
|
|
459
|
+
declare module '@adtrackify/at-tracking-event-types/types/tracking-events/tracking-event-type' {
|
|
460
|
+
import { ADTRACKIFY_STANDARD_EVENT } from '@adtrackify/at-tracking-event-types/types/adtrackify-standard-events';
|
|
461
|
+
import { AddressInfo } from '@adtrackify/at-tracking-event-types/types/common/address';
|
|
462
|
+
import { TrackingEventContext } from '@adtrackify/at-tracking-event-types/types/tracking-events/tracking-event-context';
|
|
463
|
+
import { TrackingEventIdentity } from '@adtrackify/at-tracking-event-types/types/tracking-events/tracking-event-identity';
|
|
464
|
+
export interface TrackingEvent {
|
|
465
|
+
id: string;
|
|
466
|
+
type: string;
|
|
467
|
+
name: ADTRACKIFY_STANDARD_EVENT;
|
|
468
|
+
pixelId: string;
|
|
469
|
+
context?: TrackingEventContext;
|
|
470
|
+
identity?: TrackingEventIdentity;
|
|
471
|
+
data?: TrackingEventData;
|
|
472
|
+
testCode?: string;
|
|
473
|
+
sentAtEpoch?: number;
|
|
474
|
+
collectedAt?: string;
|
|
475
|
+
version: string;
|
|
412
476
|
}
|
|
413
477
|
export interface TrackingEventData {
|
|
414
478
|
[key: string]: any;
|
|
@@ -460,37 +524,6 @@ declare module '@adtrackify/at-tracking-event-types/types/tracking-event-type' {
|
|
|
460
524
|
category4?: string;
|
|
461
525
|
category5?: string;
|
|
462
526
|
}
|
|
463
|
-
export interface AddressInfo {
|
|
464
|
-
email?: string;
|
|
465
|
-
phone?: string;
|
|
466
|
-
firstName?: string;
|
|
467
|
-
lastName?: string;
|
|
468
|
-
company?: string;
|
|
469
|
-
address1?: string;
|
|
470
|
-
address2?: string;
|
|
471
|
-
city?: string;
|
|
472
|
-
province?: string;
|
|
473
|
-
provinceCode?: string;
|
|
474
|
-
country?: string;
|
|
475
|
-
countryCode?: string;
|
|
476
|
-
zip?: string;
|
|
477
|
-
}
|
|
478
|
-
export interface CampaignInfo {
|
|
479
|
-
name?: string;
|
|
480
|
-
source?: string;
|
|
481
|
-
medium?: string;
|
|
482
|
-
term?: string;
|
|
483
|
-
content?: string;
|
|
484
|
-
}
|
|
485
|
-
export interface PageInfo {
|
|
486
|
-
path?: string;
|
|
487
|
-
referrer?: string;
|
|
488
|
-
search?: string;
|
|
489
|
-
title?: string;
|
|
490
|
-
url?: string;
|
|
491
|
-
qsp?: any;
|
|
492
|
-
}
|
|
493
|
-
export type DeviceInfo = IResult;
|
|
494
527
|
export const Currencies: string[];
|
|
495
528
|
|
|
496
529
|
}
|
package/dist/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
var a=(
|
|
1
|
+
var a=(n=>(n.PENDING="pending",n.ACTIVE="active",n.INACTIVE="inactive",n))(a||{});var g=(r=>(r.FACEBOOK="facebook",r.TIKTOK="tiktok",r.GOOGLE_ADS="googleAds",r.GOOGLE_ANALYTICS_4="googleAnalytics4",r.HUBSPOT="hubspot",r.WEBHOOK="webhook",r.CUSTOM_HTML="customHTML",r.CUSTOM_JS="customJS",r.SNAPCHAT="snapchat",r.TWITTER="twitter",r.REDDIT="reddit",r))(g||{});var c=(n=>(n.HEADER="header",n.FOOTER="footer",n.BODY="body",n))(c||{});var p=(i=>(i.STARTED="started",i.COMPLETED="completed",i.UNINSTALLED="uninstalled",i.FAILED="failed",i.NONE="none",i))(p||{}),d=(e=>(e.ACTIVE="active",e.CANCELLED="cancelled",e.DECLINED="declined",e.EXPIRED="expired",e.FROZEN="frozen",e.PENDING="pending",e.NOT_SUBMITTED="na",e))(d||{});var m=(s=>(s.MONTHLY="monthly",s.YEARLY="yearly",s))(m||{}),l=(o=>(o.CURRENT="current",o.PAST_DUE="past_due",o.CANCELLED="cancelled",o.FAILED="failed",o))(l||{}),f=(e=>(e.ACTIVE="active",e.CANCELLED="cancelled",e.DECLINED="declined",e.EXPIRED="expired",e.FROZEN="frozen",e.PENDING="pending",e.NOT_SUBMITTED="na",e))(f||{}),u=(n=>(n.STRIPE="stripe",n.PAYPAL="paypal",n.SHOPIFY="shopify",n))(u||{});var x=(t=>(t.ADD_PAYMENT_INFO="add_payment_info",t.ADD_SHIPPING_INFO="add_shipping_info",t.ADD_TO_CART="add_to_cart",t.ADD_TO_WISHLIST="add_to_wishlist",t.INITIATE_CHECKOUT="initiate_checkout",t.LEAD="lead",t.LOGIN="login",t.PAGE_VIEW="page_view",t.PURCHASE="purchase",t.REFUND="refund",t.SEARCH="search",t.SIGN_UP="sign_up",t.VIEW_CART="view_cart",t.VIEW_CONTENT="view_content",t.SELECT_SHIPPING_METHOD="select_shipping_method",t.VIRTUALIZED_VIEWED_PAYMENT_FORM="virtualized_viewd_payment_form",t))(x||{});var M=["AED","ARS","AUD","BDT","BIF","BOB","BRL","CAD","CHF","CLP","CNY","COP","CRC","CZK","DKK","DZD","EGP","EUR","GBP","GTQ","HKD","HNL","HUF","IDR","ILS","INR","ISK","JPY","KES","KRW","KWD","KZT","MAD","MOP","MXN","MYR","NGN","NIO","NOK","NZD","PEN","PHP","PKR","PLN","PYG","QAR","RON","RUB","SAR","SEK","SGD","THB","TRY","TWD","USD","VES","VND","ZAR"];export{a as ACCOUNT_STATUS,x as ADTRACKIFY_STANDARD_EVENT,M as Currencies,c as CustomHTMLLocation,g as DESTINATIONS,u as PAYMENT_GATEWAY,l as PAYMENT_STATUS,m as PLAN_BILLING_FREQUENCY,f as SUBSCRIPTION_STATUS,p as ShopifyAppInstallStatus,d as ShopifyAppSubscriptionStatus};
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
|
-
"sources": ["../src/types/
|
|
4
|
-
"sourcesContent": ["export enum ADTRACKIFY_STANDARD_EVENT {\n ADD_PAYMENT_INFO = 'add_payment_info',\n ADD_SHIPPING_INFO = 'add_shipping_info',\n ADD_TO_CART = 'add_to_cart',\n ADD_TO_WISHLIST = 'add_to_wishlist',\n // COMPLETE_REGISTRATION: 'complete_registration',\n // CONTACT: 'contact',\n INITIATE_CHECKOUT = 'initiate_checkout',\n LEAD = 'lead',\n LOGIN = 'login',\n PAGE_VIEW = 'page_view',\n PURCHASE = 'purchase',\n REFUND = 'refund',\n SEARCH = 'search',\n // START_TRIAL: 'start_trial',\n // SUBMIT_APPLICATION: 'submit_application',\n // SUBSCRIBE: 'subscribe',\n SIGN_UP = 'sign_up',\n VIEW_CART = 'view_cart',\n VIEW_CONTENT = 'view_content',\n\n\n //\n SELECT_SHIPPING_METHOD = 'select_shipping_method',\n VIRTUALIZED_VIEWED_PAYMENT_FORM = 'virtualized_viewd_payment_form'\n}", "import { IResult } from 'ua-parser-js';\nimport { ADTRACKIFY_STANDARD_EVENT } from './adtrackify-standard-events';\n\n\nexport interface TrackingEvent {\n id: string;\n type: string;\n name: ADTRACKIFY_STANDARD_EVENT;\n pixelId: string;\n context: TrackingEventContext;\n data: TrackingEventData;\n testCode?: string;\n sentAtEpoch?: number;\n collectedAt?: string;\n version: string;\n}\n\nexport interface TrackingEventContext {\n identity: TrackingEventIdentity;\n click?: AdClickInfo;\n campaign?: CampaignInfo;\n page?: PageInfo;\n device?: DeviceInfo;\n locale?: string;\n timezone?: string;\n userAgent?: string;\n ipAddress?: string;\n ipv6Address?: string;\n sessionId?: string;\n}\n\nexport interface TrackingEventIdentity {\n [ key: string ]: any;\n identityId?: string;\n anonymousId?: string;\n userId?: string;\n gender?: string;\n dob?: string;\n phone?: string;\n id?: string;\n firstName?: string;\n lastName?: string;\n email?: string;\n address?: AddressInfo;\n addresses?: AddressInfo[];\n}\n\nexport interface AdClickInfo {\n fbp?: string;\n fbc?: string;\n fbclid?: string;\n gclid?: string;\n}\n\nexport interface TrackingEventData {\n [ key: string ]: any;\n firstName?: string;\n lastName?: string;\n email?: string;\n phone?: string;\n addresses?: AddressInfo[];\n cartId?: string;\n transactionId?: string;\n affiliation?: string;\n currency?: string;\n price?: number;\n subtotalPrice?: number;\n value?: number;\n tax?: number;\n shipping?: number;\n coupon?: string;\n paymentType?: string;\n shippingTier?: string;\n creativeName?: string;\n creativeSlot?: string;\n locationId?: string;\n promotionId?: string;\n promotionName?: string;\n items?: GenericContent[];\n}\n\nexport interface GenericContent {\n [ key: string ]: any;\n content_type?: string;\n id?: string;\n name?: string;\n sku?: string;\n brand?: string;\n variant?: string;\n coupon?: string;\n currency?: string;\n discount?: number;\n index?: number;\n value?: number;\n price?: number;\n quantity?: number;\n url?: string;\n locationId?: string;\n imageUrl?: string;\n category?: string;\n category2?: string;\n category3?: string;\n category4?: string;\n category5?: string;\n}\n\nexport interface AddressInfo {\n email?: string;\n phone?: string;\n firstName?: string;\n lastName?: string;\n company?: string;\n address1?: string;\n address2?: string;\n city?: string;\n province?: string;\n provinceCode?: string;\n country?: string;\n countryCode?: string;\n zip?: string;\n}\n\nexport interface CampaignInfo {\n name?: string;\n source?: string;\n medium?: string;\n term?: string;\n content?: string;\n}\n\nexport interface PageInfo {\n path?: string;\n referrer?: string;\n search?: string;\n title?: string;\n url?: string;\n qsp?: any;\n}\n\nexport type DeviceInfo = IResult;\n\n\nexport const Currencies: string[] = [ 'AED', 'ARS', 'AUD', 'BDT', 'BIF', 'BOB', 'BRL', 'CAD', 'CHF', 'CLP', 'CNY', 'COP', 'CRC', 'CZK', 'DKK', 'DZD', 'EGP', 'EUR', 'GBP', 'GTQ', 'HKD', 'HNL', 'HUF', 'IDR', 'ILS', 'INR', 'ISK', 'JPY', 'KES', 'KRW', 'KWD', 'KZT', 'MAD', 'MOP', 'MXN', 'MYR', 'NGN', 'NIO', 'NOK', 'NZD', 'PEN', 'PHP', 'PKR', 'PLN', 'PYG', 'QAR', 'RON', 'RUB', 'SAR', 'SEK', 'SGD', 'THB', 'TRY', 'TWD', 'USD', 'VES', 'VND', 'ZAR' ];\n\n", "import { Subscription } from './subscription';\n\nexport interface Account {\n id: string,\n accountName: string,\n companyName?: string,\n accountStatus: ACCOUNT_STATUS,\n primaryEmail: string,\n publicApiKey?: string,\n subscriptionId?: string,\n pixels?: Pixel[],\n subscription?: Subscription;\n ownerId?: string,\n createdAt: string,\n updatedAt: string;\n}\n\n\nexport interface Pixel {\n id: string;\n accountId: string;\n name: string;\n createdAt: string,\n updatedAt: string;\n}\n\nexport enum ACCOUNT_STATUS {\n PENDING = 'pending',\n ACTIVE = 'active',\n INACTIVE = 'inactive'\n}", "\r\nexport interface Destination {\r\n id: string,\r\n accountId: string,\r\n pixelId: string,\r\n destination: string;\r\n displayName?: string,\r\n enabled: boolean;\r\n configuration?: UserDestinationConfiguration,\r\n createdAt: string,\r\n updatedAt: string;\r\n}\r\n\r\nexport enum DESTINATIONS {\r\n FACEBOOK = 'facebook',\r\n TIKTOK = 'tiktok',\r\n GOOGLE_ADS = 'googleAds',\r\n GOOGLE_ANALYTICS_4 = 'googleAnalytics4',\r\n HUBSPOT = 'hubspot',\r\n WEBHOOK = 'webhook',\r\n CUSTOM_HTML = 'customHTML',\r\n CUSTOM_JS = 'customJS',\r\n SNAPCHAT = 'snapchat',\r\n TWITTER = 'twitter',\r\n REDDIT = 'reddit'\r\n}\r\n\r\nexport interface UserDestinationConfiguration {\r\n [ key: string ]: any;\r\n eventBlacklist?: string[];\r\n events?: EventConfiguration[];\r\n trigger?: DestinationTriggerConfiguration;\r\n}\r\n\r\nexport interface DestinationTriggerConfiguration {\r\n shopify?: ShopifyTriggerConfiguration;\r\n exludeDomains?: string[];\r\n excludePages?: string[];\r\n domains?: string[];\r\n pages?: string[];\r\n}\r\n\r\nexport interface ShopifyTriggerConfiguration {\r\n enabled: boolean;\r\n collections?: string[];\r\n tags?: string[];\r\n}\r\n\r\n\r\nexport interface EventConfiguration {\r\n sourceEventName: string;\r\n exclude?: boolean;\r\n sample: EventSampleConfiguration;\r\n transformations?: EventTransformation[];\r\n}\r\n\r\nexport interface EventTransformation {\r\n transformationEventName: string;\r\n enabled: boolean;\r\n}\r\n\r\nexport interface EventSampleConfiguration {\r\n enabled: boolean;\r\n rate: number;\r\n}\r\n\r\n", "import { Destination, UserDestinationConfiguration } from './destinations';\n\nexport interface AdTrackifyFacebookDestination extends Destination {\n configuration: FacebookPixelConfiguration;\n}\n\n// Destination Specific configurations below\nexport interface FacebookPixelConfiguration extends UserDestinationConfiguration {\n apiAccessToken?: string;\n enableConversionAPI: boolean;\n pixelId: string;\n}\n\nexport interface TiktokPixelConfiguration {\n pixelId: string;\n}\n\nexport interface GoogleAnalytics4Configuration {\n measurementId: string;\n}\n\nexport interface GoogleAdsConfiguration {\n pixelId: string;\n conversionID: string;\n}\n\nexport interface HubspotPixelConfiguration {\n hubspotId: string;\n}\n\nexport interface SnapchatPixelConfiguration {\n snapchatPixelId: string;\n}\n\nexport interface TwitterPixelConfiguration {\n twitterPixelId: string;\n}\n\nexport interface WebhookConfiguration {\n webhookUrl: string;\n}\n\nexport interface CustomHTMLConfiguration {\n html: string;\n location: CustomHTMLLocation;\n}\n\nexport interface CustomJSConfiguration {\n script: string;\n async: boolean;\n defer: boolean;\n location: CustomHTMLLocation;\n}\n\nexport enum CustomHTMLLocation {\n HEADER = 'header',\n FOOTER = 'footer',\n BODY = 'body'\n}\n\n", "export interface ShopifyAppInstall {\n shopifyAppInstallId: string;\n shop: string;\n accessToken?: string;\n appStatus?: string;\n appSubscriptionStatus?: ShopifyAppSubscriptionStatus;\n code?: string;\n hmac?: string;\n host?: string;\n installRequest?: ShopifyInstallRequest;\n isAppEnabled?: boolean;\n pixelId?: string;\n shopInfo?: any;\n state?: string;\n timestamp?: number;\n createdAt: string;\n updatedAt: string;\n}\n\nexport enum ShopifyAppInstallStatus {\n STARTED = 'started',\n COMPLETED = 'completed',\n UNINSTALLED = 'uninstalled',\n FAILED = 'failed',\n NONE = 'none'\n}\nexport enum ShopifyAppSubscriptionStatus {\n ACTIVE = 'active', // approved and billed to shop\n CANCELLED = 'cancelled', // cancelled, uninstalled or cancellation\n DECLINED = 'declined', // subscription declined by merchant\n EXPIRED = 'expired', //wasn't approved within two days of being created\n FROZEN = 'frozen', //on hold due to not payment\n PENDING = 'pending', // pending approval\n NOT_SUBMITTED = 'na' // billing has not yet been attempted\n}\n\nexport interface ShopifyInstallRequest {\n shop?: string;\n session?: string;\n hmac?: string;\n host?: string;\n nonce?: string;\n timestamp?: string;\n status?: string;\n}\n\nexport interface ShopifyStoreInfo {\n // TBD based on shopify api\n [ key: string ]: any;\n}", "\nexport interface Subscription {\n id: string,\n accountId?: string,\n shopifyAppInstallId?: string,\n shopifyDomain?: string,\n stripeCustomerId?: string,\n stripeSubscriptionId?: string,\n stripeCompletedCheckoutSession?: any;\n shopifyChargeId?: string;\n subscriptionPlan?: SubscriptionPlan,\n status?: SUBSCRIPTION_STATUS,\n paymentStatus?: PAYMENT_STATUS,\n paymentGateway?: PAYMENT_GATEWAY,\n createdAt: string,\n updatedAt: string,\n\n}\nexport interface SubscriptionPlan {\n id: number;\n planName: string;\n displayName: string;\n description: string;\n sku: string;\n price: string;\n displayPrice: string;\n billingFrequency: PLAN_BILLING_FREQUENCY;\n trialLengthDays?: number;\n trialRequiresCreditCard?: boolean;\n planDesc?: string[];\n unitPriceText?: string;\n isHighlighted?: boolean;\n isBanner?: boolean;\n bannerText?: string;\n bannerColor?: string;\n stripePriceId?: string;\n stripeProductId?: string;\n}\n\nexport enum PLAN_BILLING_FREQUENCY {\n MONTHLY = 'monthly',\n YEARLY = 'yearly'\n}\n\nexport enum PAYMENT_STATUS {\n CURRENT = 'current',\n PAST_DUE = 'past_due',\n CANCELLED = 'cancelled',\n FAILED = 'failed'\n}\n\nexport enum SUBSCRIPTION_STATUS {\n ACTIVE = 'active', // approved and billed to shop\n CANCELLED = 'cancelled', // cancelled, uninstalled or cancellation\n DECLINED = 'declined', // subscription declined by merchant\n EXPIRED = 'expired', //wasn't approved within two days of being created\n FROZEN = 'frozen', //on hold due to not payment\n PENDING = 'pending', // pending approval\n NOT_SUBMITTED = 'na' // billing has not yet been attempted\n}\nexport enum PAYMENT_GATEWAY {\n STRIPE = 'stripe',\n PAYPAL = 'paypal',\n SHOPIFY = 'shopify'\n}\n"],
|
|
5
|
-
"mappings": "
|
|
6
|
-
"names": ["
|
|
3
|
+
"sources": ["../src/types/api/account.ts", "../src/types/api/destinations/destinations.ts", "../src/types/api/destinations/third-party-destination-configs.ts", "../src/types/api/shopify-app-install.ts", "../src/types/api/subscription.ts", "../src/types/adtrackify-standard-events.ts", "../src/types/tracking-events/tracking-event-type.ts"],
|
|
4
|
+
"sourcesContent": ["import { Subscription } from './subscription';\n\nexport interface Account {\n id: string,\n accountName: string,\n companyName?: string,\n accountStatus: ACCOUNT_STATUS,\n primaryEmail: string,\n publicApiKey?: string,\n subscriptionId?: string,\n pixels?: Pixel[],\n subscription?: Subscription;\n ownerId?: string,\n createdAt: string,\n updatedAt: string;\n}\n\n\nexport interface Pixel {\n id: string;\n accountId: string;\n name: string;\n createdAt: string,\n updatedAt: string;\n}\n\nexport enum ACCOUNT_STATUS {\n PENDING = 'pending',\n ACTIVE = 'active',\n INACTIVE = 'inactive'\n}", "\r\nexport interface Destination {\r\n id: string,\r\n accountId: string,\r\n pixelId: string,\r\n destination: string;\r\n displayName?: string,\r\n enabled: boolean;\r\n configuration?: UserDestinationConfiguration,\r\n createdAt: string,\r\n updatedAt: string;\r\n}\r\n\r\nexport enum DESTINATIONS {\r\n FACEBOOK = 'facebook',\r\n TIKTOK = 'tiktok',\r\n GOOGLE_ADS = 'googleAds',\r\n GOOGLE_ANALYTICS_4 = 'googleAnalytics4',\r\n HUBSPOT = 'hubspot',\r\n WEBHOOK = 'webhook',\r\n CUSTOM_HTML = 'customHTML',\r\n CUSTOM_JS = 'customJS',\r\n SNAPCHAT = 'snapchat',\r\n TWITTER = 'twitter',\r\n REDDIT = 'reddit'\r\n}\r\n\r\nexport interface UserDestinationConfiguration {\r\n [ key: string ]: any;\r\n eventBlacklist?: string[];\r\n events?: EventConfiguration[];\r\n trigger?: DestinationTriggerConfiguration;\r\n}\r\n\r\nexport interface DestinationTriggerConfiguration {\r\n shopify?: ShopifyTriggerConfiguration;\r\n exludeDomains?: string[];\r\n excludePages?: string[];\r\n domains?: string[];\r\n pages?: string[];\r\n}\r\n\r\nexport interface ShopifyTriggerConfiguration {\r\n enabled: boolean;\r\n collections?: string[];\r\n tags?: string[];\r\n}\r\n\r\n\r\nexport interface EventConfiguration {\r\n sourceEventName: string;\r\n exclude?: boolean;\r\n sample: EventSampleConfiguration;\r\n transformations?: EventTransformation[];\r\n}\r\n\r\nexport interface EventTransformation {\r\n transformationEventName: string;\r\n enabled: boolean;\r\n}\r\n\r\nexport interface EventSampleConfiguration {\r\n enabled: boolean;\r\n rate: number;\r\n}\r\n\r\n", "import { Destination, UserDestinationConfiguration } from './destinations';\n\nexport interface AdTrackifyFacebookDestination extends Destination {\n configuration: FacebookPixelConfiguration;\n}\n\n// Destination Specific configurations below\nexport interface FacebookPixelConfiguration extends UserDestinationConfiguration {\n apiAccessToken?: string;\n enableConversionAPI: boolean;\n pixelId: string;\n}\n\nexport interface TiktokPixelConfiguration {\n pixelId: string;\n}\n\nexport interface GoogleAnalytics4Configuration {\n measurementId: string;\n}\n\nexport interface GoogleAdsConfiguration {\n pixelId: string;\n conversionID: string;\n}\n\nexport interface HubspotPixelConfiguration {\n hubspotId: string;\n}\n\nexport interface SnapchatPixelConfiguration {\n snapchatPixelId: string;\n}\n\nexport interface TwitterPixelConfiguration {\n twitterPixelId: string;\n}\n\nexport interface WebhookConfiguration {\n webhookUrl: string;\n}\n\nexport interface CustomHTMLConfiguration {\n html: string;\n location: CustomHTMLLocation;\n}\n\nexport interface CustomJSConfiguration {\n script: string;\n async: boolean;\n defer: boolean;\n location: CustomHTMLLocation;\n}\n\nexport enum CustomHTMLLocation {\n HEADER = 'header',\n FOOTER = 'footer',\n BODY = 'body'\n}\n\n", "export interface ShopifyAppInstall {\n shopifyAppInstallId: string;\n shop: string;\n accessToken?: string;\n appStatus?: string;\n appSubscriptionStatus?: ShopifyAppSubscriptionStatus;\n code?: string;\n hmac?: string;\n host?: string;\n installRequest?: ShopifyInstallRequest;\n isAppEnabled?: boolean;\n pixelId?: string;\n shopInfo?: any;\n state?: string;\n timestamp?: number;\n createdAt: string;\n updatedAt: string;\n}\n\nexport enum ShopifyAppInstallStatus {\n STARTED = 'started',\n COMPLETED = 'completed',\n UNINSTALLED = 'uninstalled',\n FAILED = 'failed',\n NONE = 'none'\n}\nexport enum ShopifyAppSubscriptionStatus {\n ACTIVE = 'active', // approved and billed to shop\n CANCELLED = 'cancelled', // cancelled, uninstalled or cancellation\n DECLINED = 'declined', // subscription declined by merchant\n EXPIRED = 'expired', //wasn't approved within two days of being created\n FROZEN = 'frozen', //on hold due to not payment\n PENDING = 'pending', // pending approval\n NOT_SUBMITTED = 'na' // billing has not yet been attempted\n}\n\nexport interface ShopifyInstallRequest {\n shop?: string;\n session?: string;\n hmac?: string;\n host?: string;\n nonce?: string;\n timestamp?: string;\n status?: string;\n}\n\nexport interface ShopifyStoreInfo {\n // TBD based on shopify api\n [ key: string ]: any;\n}", "\nexport interface Subscription {\n id: string,\n accountId?: string,\n shopifyAppInstallId?: string,\n shopifyDomain?: string,\n stripeCustomerId?: string,\n stripeSubscriptionId?: string,\n stripeCompletedCheckoutSession?: any;\n shopifyChargeId?: string;\n subscriptionPlan?: SubscriptionPlan,\n status?: SUBSCRIPTION_STATUS,\n paymentStatus?: PAYMENT_STATUS,\n paymentGateway?: PAYMENT_GATEWAY,\n createdAt: string,\n updatedAt: string,\n\n}\nexport interface SubscriptionPlan {\n id: number;\n planName: string;\n displayName: string;\n description: string;\n sku: string;\n price: string;\n displayPrice: string;\n billingFrequency: PLAN_BILLING_FREQUENCY;\n trialLengthDays?: number;\n trialRequiresCreditCard?: boolean;\n planDesc?: string[];\n unitPriceText?: string;\n isHighlighted?: boolean;\n isBanner?: boolean;\n bannerText?: string;\n bannerColor?: string;\n stripePriceId?: string;\n stripeProductId?: string;\n}\n\nexport enum PLAN_BILLING_FREQUENCY {\n MONTHLY = 'monthly',\n YEARLY = 'yearly'\n}\n\nexport enum PAYMENT_STATUS {\n CURRENT = 'current',\n PAST_DUE = 'past_due',\n CANCELLED = 'cancelled',\n FAILED = 'failed'\n}\n\nexport enum SUBSCRIPTION_STATUS {\n ACTIVE = 'active', // approved and billed to shop\n CANCELLED = 'cancelled', // cancelled, uninstalled or cancellation\n DECLINED = 'declined', // subscription declined by merchant\n EXPIRED = 'expired', //wasn't approved within two days of being created\n FROZEN = 'frozen', //on hold due to not payment\n PENDING = 'pending', // pending approval\n NOT_SUBMITTED = 'na' // billing has not yet been attempted\n}\nexport enum PAYMENT_GATEWAY {\n STRIPE = 'stripe',\n PAYPAL = 'paypal',\n SHOPIFY = 'shopify'\n}\n", "export enum ADTRACKIFY_STANDARD_EVENT {\n ADD_PAYMENT_INFO = 'add_payment_info',\n ADD_SHIPPING_INFO = 'add_shipping_info',\n ADD_TO_CART = 'add_to_cart',\n ADD_TO_WISHLIST = 'add_to_wishlist',\n // COMPLETE_REGISTRATION: 'complete_registration',\n // CONTACT: 'contact',\n INITIATE_CHECKOUT = 'initiate_checkout',\n LEAD = 'lead',\n LOGIN = 'login',\n PAGE_VIEW = 'page_view',\n PURCHASE = 'purchase',\n REFUND = 'refund',\n SEARCH = 'search',\n // START_TRIAL: 'start_trial',\n // SUBMIT_APPLICATION: 'submit_application',\n // SUBSCRIBE: 'subscribe',\n SIGN_UP = 'sign_up',\n VIEW_CART = 'view_cart',\n VIEW_CONTENT = 'view_content',\n\n\n //\n SELECT_SHIPPING_METHOD = 'select_shipping_method',\n VIRTUALIZED_VIEWED_PAYMENT_FORM = 'virtualized_viewd_payment_form'\n}", "import { ADTRACKIFY_STANDARD_EVENT } from '../adtrackify-standard-events';\nimport { AddressInfo } from '../common/address';\nimport { TrackingEventContext } from './tracking-event-context';\nimport { TrackingEventIdentity } from './tracking-event-identity';\n\nexport interface TrackingEvent {\n id: string;\n type: string;\n name: ADTRACKIFY_STANDARD_EVENT;\n pixelId: string;\n context?: TrackingEventContext;\n identity?: TrackingEventIdentity;\n data?: TrackingEventData;\n testCode?: string;\n sentAtEpoch?: number;\n collectedAt?: string;\n version: string;\n}\n\nexport interface TrackingEventData {\n [ key: string ]: any;\n firstName?: string;\n lastName?: string;\n email?: string;\n phone?: string;\n addresses?: AddressInfo[];\n cartId?: string;\n transactionId?: string;\n affiliation?: string;\n currency?: string;\n price?: number;\n subtotalPrice?: number;\n value?: number;\n tax?: number;\n shipping?: number;\n coupon?: string;\n paymentType?: string;\n shippingTier?: string;\n creativeName?: string;\n creativeSlot?: string;\n locationId?: string;\n promotionId?: string;\n promotionName?: string;\n items?: GenericContent[];\n}\n\nexport interface GenericContent {\n [ key: string ]: any;\n content_type?: string;\n id?: string;\n name?: string;\n sku?: string;\n brand?: string;\n variant?: string;\n coupon?: string;\n currency?: string;\n discount?: number;\n index?: number;\n value?: number;\n price?: number;\n quantity?: number;\n url?: string;\n locationId?: string;\n imageUrl?: string;\n category?: string;\n category2?: string;\n category3?: string;\n category4?: string;\n category5?: string;\n}\n\nexport const Currencies: string[] = [ 'AED', 'ARS', 'AUD', 'BDT', 'BIF', 'BOB', 'BRL', 'CAD', 'CHF', 'CLP', 'CNY', 'COP', 'CRC', 'CZK', 'DKK', 'DZD', 'EGP', 'EUR', 'GBP', 'GTQ', 'HKD', 'HNL', 'HUF', 'IDR', 'ILS', 'INR', 'ISK', 'JPY', 'KES', 'KRW', 'KWD', 'KZT', 'MAD', 'MOP', 'MXN', 'MYR', 'NGN', 'NIO', 'NOK', 'NZD', 'PEN', 'PHP', 'PKR', 'PLN', 'PYG', 'QAR', 'RON', 'RUB', 'SAR', 'SEK', 'SGD', 'THB', 'TRY', 'TWD', 'USD', 'VES', 'VND', 'ZAR' ];\n\n"],
|
|
5
|
+
"mappings": "AA0BO,IAAKA,OACVA,EAAA,QAAU,UACVA,EAAA,OAAS,SACTA,EAAA,SAAW,WAHDA,OAAA,ICbL,IAAKC,OACVA,EAAA,SAAW,WACXA,EAAA,OAAS,SACTA,EAAA,WAAa,YACbA,EAAA,mBAAqB,mBACrBA,EAAA,QAAU,UACVA,EAAA,QAAU,UACVA,EAAA,YAAc,aACdA,EAAA,UAAY,WACZA,EAAA,SAAW,WACXA,EAAA,QAAU,UACVA,EAAA,OAAS,SAXCA,OAAA,ICyCL,IAAKC,OACVA,EAAA,OAAS,SACTA,EAAA,OAAS,SACTA,EAAA,KAAO,OAHGA,OAAA,ICnCL,IAAKC,OACVA,EAAA,QAAU,UACVA,EAAA,UAAY,YACZA,EAAA,YAAc,cACdA,EAAA,OAAS,SACTA,EAAA,KAAO,OALGA,OAAA,IAOAC,OACVA,EAAA,OAAS,SACTA,EAAA,UAAY,YACZA,EAAA,SAAW,WACXA,EAAA,QAAU,UACVA,EAAA,OAAS,SACTA,EAAA,QAAU,UACVA,EAAA,cAAgB,KAPNA,OAAA,ICaL,IAAKC,OACVA,EAAA,QAAU,UACVA,EAAA,OAAS,SAFCA,OAAA,IAKAC,OACVA,EAAA,QAAU,UACVA,EAAA,SAAW,WACXA,EAAA,UAAY,YACZA,EAAA,OAAS,SAJCA,OAAA,IAOAC,OACVA,EAAA,OAAS,SACTA,EAAA,UAAY,YACZA,EAAA,SAAW,WACXA,EAAA,QAAU,UACVA,EAAA,OAAS,SACTA,EAAA,QAAU,UACVA,EAAA,cAAgB,KAPNA,OAAA,IASAC,OACVA,EAAA,OAAS,SACTA,EAAA,OAAS,SACTA,EAAA,QAAU,UAHAA,OAAA,IC5DL,IAAKC,OACVA,EAAA,iBAAmB,mBACnBA,EAAA,kBAAoB,oBACpBA,EAAA,YAAc,cACdA,EAAA,gBAAkB,kBAGlBA,EAAA,kBAAoB,oBACpBA,EAAA,KAAO,OACPA,EAAA,MAAQ,QACRA,EAAA,UAAY,YACZA,EAAA,SAAW,WACXA,EAAA,OAAS,SACTA,EAAA,OAAS,SAITA,EAAA,QAAU,UACVA,EAAA,UAAY,YACZA,EAAA,aAAe,eAIfA,EAAA,uBAAyB,yBACzBA,EAAA,gCAAkC,iCAxBxBA,OAAA,ICuEL,IAAMC,EAAuB,CAAE,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,MAAO,KAAM",
|
|
6
|
+
"names": ["ACCOUNT_STATUS", "DESTINATIONS", "CustomHTMLLocation", "ShopifyAppInstallStatus", "ShopifyAppSubscriptionStatus", "PLAN_BILLING_FREQUENCY", "PAYMENT_STATUS", "SUBSCRIPTION_STATUS", "PAYMENT_GATEWAY", "ADTRACKIFY_STANDARD_EVENT", "Currencies"]
|
|
7
7
|
}
|
package/package.json
CHANGED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
|
|
2
|
+
export interface AddressInfo {
|
|
3
|
+
email?: string;
|
|
4
|
+
phone?: string;
|
|
5
|
+
firstName?: string;
|
|
6
|
+
lastName?: string;
|
|
7
|
+
company?: string;
|
|
8
|
+
address1?: string;
|
|
9
|
+
address2?: string;
|
|
10
|
+
city?: string;
|
|
11
|
+
province?: string;
|
|
12
|
+
provinceCode?: string;
|
|
13
|
+
country?: string;
|
|
14
|
+
countryCode?: string;
|
|
15
|
+
zip?: string;
|
|
16
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './address';
|
package/src/types/index.ts
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
|
+
export * from './api';
|
|
2
|
+
export * from './common';
|
|
1
3
|
export * from './adtrackify-standard-events';
|
|
2
4
|
export * from './third-party-event-configuration-types';
|
|
3
|
-
export * from './tracking-event-type';
|
|
5
|
+
export * from './tracking-events/tracking-event-type';
|
|
4
6
|
export * from './adtrackify-event-bus-event';
|
|
5
|
-
export * from './
|
|
7
|
+
export * from './tracking-events';
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { TrackingEventIdentity } from './tracking-event-identity';
|
|
2
|
+
import { IResult } from 'ua-parser-js';
|
|
3
|
+
|
|
4
|
+
export interface TrackingEventContext {
|
|
5
|
+
identity: TrackingEventIdentity;
|
|
6
|
+
properties?: TrackingEventContextProperties;
|
|
7
|
+
}
|
|
8
|
+
export interface TrackingEventContextProperties {
|
|
9
|
+
click?: AdClickInfo;
|
|
10
|
+
campaign?: CampaignInfo;
|
|
11
|
+
page?: PageInfo;
|
|
12
|
+
device?: DeviceInfo;
|
|
13
|
+
locale?: string;
|
|
14
|
+
timezone?: string;
|
|
15
|
+
userAgent?: string;
|
|
16
|
+
ipAddress?: string;
|
|
17
|
+
ipv6Address?: string;
|
|
18
|
+
sessionId?: string;
|
|
19
|
+
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
export interface AdClickInfo {
|
|
23
|
+
fbp?: string;
|
|
24
|
+
fbc?: string;
|
|
25
|
+
fbclid?: string;
|
|
26
|
+
gclid?: string;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export interface CampaignInfo {
|
|
30
|
+
name?: string;
|
|
31
|
+
source?: string;
|
|
32
|
+
medium?: string;
|
|
33
|
+
term?: string;
|
|
34
|
+
content?: string;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
export interface PageInfo {
|
|
38
|
+
path?: string;
|
|
39
|
+
referrer?: string;
|
|
40
|
+
search?: string;
|
|
41
|
+
title?: string;
|
|
42
|
+
url?: string;
|
|
43
|
+
qsp?: any;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
export type DeviceInfo = IResult;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { AddressInfo } from '../common/address';
|
|
2
|
+
|
|
3
|
+
export interface TrackingEventIdentity {
|
|
4
|
+
identityId?: string;
|
|
5
|
+
anonymousId?: string;
|
|
6
|
+
traits?: TrackingEventIdentityTraits;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
export interface TrackingEventIdentityTraits {
|
|
10
|
+
[ key: string ]: any;
|
|
11
|
+
userId?: string;
|
|
12
|
+
gender?: string;
|
|
13
|
+
dob?: string;
|
|
14
|
+
phone?: string;
|
|
15
|
+
id?: string;
|
|
16
|
+
firstName?: string;
|
|
17
|
+
lastName?: string;
|
|
18
|
+
email?: string;
|
|
19
|
+
address?: AddressInfo;
|
|
20
|
+
addresses?: AddressInfo[];
|
|
21
|
+
}
|
|
@@ -1,57 +1,22 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
|
|
1
|
+
import { ADTRACKIFY_STANDARD_EVENT } from '../adtrackify-standard-events';
|
|
2
|
+
import { AddressInfo } from '../common/address';
|
|
3
|
+
import { TrackingEventContext } from './tracking-event-context';
|
|
4
|
+
import { TrackingEventIdentity } from './tracking-event-identity';
|
|
4
5
|
|
|
5
6
|
export interface TrackingEvent {
|
|
6
7
|
id: string;
|
|
7
8
|
type: string;
|
|
8
9
|
name: ADTRACKIFY_STANDARD_EVENT;
|
|
9
10
|
pixelId: string;
|
|
10
|
-
context
|
|
11
|
-
|
|
11
|
+
context?: TrackingEventContext;
|
|
12
|
+
identity?: TrackingEventIdentity;
|
|
13
|
+
data?: TrackingEventData;
|
|
12
14
|
testCode?: string;
|
|
13
15
|
sentAtEpoch?: number;
|
|
14
16
|
collectedAt?: string;
|
|
15
17
|
version: string;
|
|
16
18
|
}
|
|
17
19
|
|
|
18
|
-
export interface TrackingEventContext {
|
|
19
|
-
identity: TrackingEventIdentity;
|
|
20
|
-
click?: AdClickInfo;
|
|
21
|
-
campaign?: CampaignInfo;
|
|
22
|
-
page?: PageInfo;
|
|
23
|
-
device?: DeviceInfo;
|
|
24
|
-
locale?: string;
|
|
25
|
-
timezone?: string;
|
|
26
|
-
userAgent?: string;
|
|
27
|
-
ipAddress?: string;
|
|
28
|
-
ipv6Address?: string;
|
|
29
|
-
sessionId?: string;
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
export interface TrackingEventIdentity {
|
|
33
|
-
[ key: string ]: any;
|
|
34
|
-
identityId?: string;
|
|
35
|
-
anonymousId?: string;
|
|
36
|
-
userId?: string;
|
|
37
|
-
gender?: string;
|
|
38
|
-
dob?: string;
|
|
39
|
-
phone?: string;
|
|
40
|
-
id?: string;
|
|
41
|
-
firstName?: string;
|
|
42
|
-
lastName?: string;
|
|
43
|
-
email?: string;
|
|
44
|
-
address?: AddressInfo;
|
|
45
|
-
addresses?: AddressInfo[];
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
export interface AdClickInfo {
|
|
49
|
-
fbp?: string;
|
|
50
|
-
fbc?: string;
|
|
51
|
-
fbclid?: string;
|
|
52
|
-
gclid?: string;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
20
|
export interface TrackingEventData {
|
|
56
21
|
[ key: string ]: any;
|
|
57
22
|
firstName?: string;
|
|
@@ -104,41 +69,5 @@ export interface GenericContent {
|
|
|
104
69
|
category5?: string;
|
|
105
70
|
}
|
|
106
71
|
|
|
107
|
-
export interface AddressInfo {
|
|
108
|
-
email?: string;
|
|
109
|
-
phone?: string;
|
|
110
|
-
firstName?: string;
|
|
111
|
-
lastName?: string;
|
|
112
|
-
company?: string;
|
|
113
|
-
address1?: string;
|
|
114
|
-
address2?: string;
|
|
115
|
-
city?: string;
|
|
116
|
-
province?: string;
|
|
117
|
-
provinceCode?: string;
|
|
118
|
-
country?: string;
|
|
119
|
-
countryCode?: string;
|
|
120
|
-
zip?: string;
|
|
121
|
-
}
|
|
122
|
-
|
|
123
|
-
export interface CampaignInfo {
|
|
124
|
-
name?: string;
|
|
125
|
-
source?: string;
|
|
126
|
-
medium?: string;
|
|
127
|
-
term?: string;
|
|
128
|
-
content?: string;
|
|
129
|
-
}
|
|
130
|
-
|
|
131
|
-
export interface PageInfo {
|
|
132
|
-
path?: string;
|
|
133
|
-
referrer?: string;
|
|
134
|
-
search?: string;
|
|
135
|
-
title?: string;
|
|
136
|
-
url?: string;
|
|
137
|
-
qsp?: any;
|
|
138
|
-
}
|
|
139
|
-
|
|
140
|
-
export type DeviceInfo = IResult;
|
|
141
|
-
|
|
142
|
-
|
|
143
72
|
export const Currencies: string[] = [ 'AED', 'ARS', 'AUD', 'BDT', 'BIF', 'BOB', 'BRL', 'CAD', 'CHF', 'CLP', 'CNY', 'COP', 'CRC', 'CZK', 'DKK', 'DZD', 'EGP', 'EUR', 'GBP', 'GTQ', 'HKD', 'HNL', 'HUF', 'IDR', 'ILS', 'INR', 'ISK', 'JPY', 'KES', 'KRW', 'KWD', 'KZT', 'MAD', 'MOP', 'MXN', 'MYR', 'NGN', 'NIO', 'NOK', 'NZD', 'PEN', 'PHP', 'PKR', 'PLN', 'PYG', 'QAR', 'RON', 'RUB', 'SAR', 'SEK', 'SGD', 'THB', 'TRY', 'TWD', 'USD', 'VES', 'VND', 'ZAR' ];
|
|
144
73
|
|