@adtrackify/at-tracking-event-types 1.0.5-8.1 → 1.0.6

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.
Files changed (43) hide show
  1. package/.husky/pre-push +1 -1
  2. package/bitbucket-pipelines.yml +2 -2
  3. package/build.js +4 -9
  4. package/dist/index.d.ts +1 -500
  5. package/dist/index.js +18 -2
  6. package/dist/index.js.map +1 -7
  7. package/dist/types/adtrackify-event-bus-event.d.ts +13 -0
  8. package/dist/types/adtrackify-event-bus-event.js +3 -0
  9. package/dist/types/adtrackify-event-bus-event.js.map +1 -0
  10. package/dist/types/adtrackify-standard-events.d.ts +18 -0
  11. package/dist/types/adtrackify-standard-events.js +23 -0
  12. package/dist/types/adtrackify-standard-events.js.map +1 -0
  13. package/dist/types/api/destination.d.ts +28 -0
  14. package/dist/types/api/destination.js +9 -0
  15. package/dist/types/api/destination.js.map +1 -0
  16. package/dist/types/api/index.d.ts +1 -0
  17. package/dist/types/api/index.js +18 -0
  18. package/dist/types/api/index.js.map +1 -0
  19. package/dist/types/index.d.ts +5 -0
  20. package/dist/types/index.js +22 -0
  21. package/dist/types/index.js.map +1 -0
  22. package/dist/types/third-party-event-configuration-types.d.ts +8 -0
  23. package/dist/types/third-party-event-configuration-types.js +3 -0
  24. package/dist/types/third-party-event-configuration-types.js.map +1 -0
  25. package/dist/types/tracking-event-type.d.ts +124 -0
  26. package/dist/types/tracking-event-type.js +5 -0
  27. package/dist/types/tracking-event-type.js.map +1 -0
  28. package/jest.config.js +39 -0
  29. package/package.json +20 -19
  30. package/prettier.config.js +9 -0
  31. package/src/types/api/destination.ts +33 -0
  32. package/src/types/api/index.ts +1 -7
  33. package/src/types/third-party-event-configuration-types.ts +2 -3
  34. package/src/types/tracking-event-type.ts +7 -13
  35. package/tsconfig.json +7 -4
  36. package/README.md +0 -13
  37. package/src/types/api/account.ts +0 -31
  38. package/src/types/api/destinations/destination-catalog.ts +0 -24
  39. package/src/types/api/destinations/destinations.ts +0 -66
  40. package/src/types/api/destinations/third-party-destination-configs.ts +0 -60
  41. package/src/types/api/shopify-app-install.ts +0 -50
  42. package/src/types/api/subscription.ts +0 -65
  43. package/src/types/api/user.ts +0 -14
@@ -1,66 +0,0 @@
1
-
2
- export interface Destination {
3
- id: string,
4
- accountId: string,
5
- pixelId: string,
6
- destination: string;
7
- displayName?: string,
8
- enabled: boolean;
9
- configuration?: UserDestinationConfiguration,
10
- createdAt: string,
11
- updatedAt: string;
12
- }
13
-
14
- export enum DESTINATIONS {
15
- FACEBOOK = 'facebook',
16
- TIKTOK = 'tiktok',
17
- GOOGLE_ADS = 'googleAds',
18
- GOOGLE_ANALYTICS_4 = 'googleAnalytics4',
19
- HUBSPOT = 'hubspot',
20
- WEBHOOK = 'webhook',
21
- CUSTOM_HTML = 'customHTML',
22
- CUSTOM_JS = 'customJS',
23
- SNAPCHAT = 'snapchat',
24
- TWITTER = 'twitter',
25
- REDDIT = 'reddit'
26
- }
27
-
28
- export interface UserDestinationConfiguration {
29
- [ key: string ]: any;
30
- eventBlacklist?: string[];
31
- events?: EventConfiguration[];
32
- trigger?: DestinationTriggerConfiguration;
33
- }
34
-
35
- export interface DestinationTriggerConfiguration {
36
- shopify?: ShopifyTriggerConfiguration;
37
- exludeDomains?: string[];
38
- excludePages?: string[];
39
- domains?: string[];
40
- pages?: string[];
41
- }
42
-
43
- export interface ShopifyTriggerConfiguration {
44
- enabled: boolean;
45
- collections?: string[];
46
- tags?: string[];
47
- }
48
-
49
-
50
- export interface EventConfiguration {
51
- sourceEventName: string;
52
- exclude?: boolean;
53
- sample: EventSampleConfiguration;
54
- transformations?: EventTransformation[];
55
- }
56
-
57
- export interface EventTransformation {
58
- transformationEventName: string;
59
- enabled: boolean;
60
- }
61
-
62
- export interface EventSampleConfiguration {
63
- enabled: boolean;
64
- rate: number;
65
- }
66
-
@@ -1,60 +0,0 @@
1
- import { Destination, UserDestinationConfiguration } from './destinations';
2
-
3
- export interface AdTrackifyFacebookDestination extends Destination {
4
- configuration: FacebookPixelConfiguration;
5
- }
6
-
7
- // Destination Specific configurations below
8
- export interface FacebookPixelConfiguration extends UserDestinationConfiguration {
9
- apiAccessToken?: string;
10
- enableConversionAPI: boolean;
11
- pixelId: string;
12
- }
13
-
14
- export interface TiktokPixelConfiguration {
15
- pixelId: string;
16
- }
17
-
18
- export interface GoogleAnalytics4Configuration {
19
- measurementId: string;
20
- }
21
-
22
- export interface GoogleAdsConfiguration {
23
- pixelId: string;
24
- conversionID: string;
25
- }
26
-
27
- export interface HubspotPixelConfiguration {
28
- hubspotId: string;
29
- }
30
-
31
- export interface SnapchatPixelConfiguration {
32
- snapchatPixelId: string;
33
- }
34
-
35
- export interface TwitterPixelConfiguration {
36
- twitterPixelId: string;
37
- }
38
-
39
- export interface WebhookConfiguration {
40
- webhookUrl: string;
41
- }
42
-
43
- export interface CustomHTMLConfiguration {
44
- html: string;
45
- location: CustomHTMLLocation;
46
- }
47
-
48
- export interface CustomJSConfiguration {
49
- script: string;
50
- async: boolean;
51
- defer: boolean;
52
- location: CustomHTMLLocation;
53
- }
54
-
55
- export enum CustomHTMLLocation {
56
- HEADER = 'header',
57
- FOOTER = 'footer',
58
- BODY = 'body'
59
- }
60
-
@@ -1,50 +0,0 @@
1
- export interface ShopifyAppInstall {
2
- shopifyAppInstallId: string;
3
- shop: string;
4
- accessToken?: string;
5
- appStatus?: string;
6
- appSubscriptionStatus?: ShopifyAppSubscriptionStatus;
7
- code?: string;
8
- hmac?: string;
9
- host?: string;
10
- installRequest?: ShopifyInstallRequest;
11
- isAppEnabled?: boolean;
12
- pixelId?: string;
13
- shopInfo?: any;
14
- state?: string;
15
- timestamp?: number;
16
- createdAt: string;
17
- updatedAt: string;
18
- }
19
-
20
- export enum ShopifyAppInstallStatus {
21
- STARTED = 'started',
22
- COMPLETED = 'completed',
23
- UNINSTALLED = 'uninstalled',
24
- FAILED = 'failed',
25
- NONE = 'none'
26
- }
27
- export enum ShopifyAppSubscriptionStatus {
28
- ACTIVE = 'active', // approved and billed to shop
29
- CANCELLED = 'cancelled', // cancelled, uninstalled or cancellation
30
- DECLINED = 'declined', // subscription declined by merchant
31
- EXPIRED = 'expired', //wasn't approved within two days of being created
32
- FROZEN = 'frozen', //on hold due to not payment
33
- PENDING = 'pending', // pending approval
34
- NOT_SUBMITTED = 'na' // billing has not yet been attempted
35
- }
36
-
37
- export interface ShopifyInstallRequest {
38
- shop?: string;
39
- session?: string;
40
- hmac?: string;
41
- host?: string;
42
- nonce?: string;
43
- timestamp?: string;
44
- status?: string;
45
- }
46
-
47
- export interface ShopifyStoreInfo {
48
- // TBD based on shopify api
49
- [ key: string ]: any;
50
- }
@@ -1,65 +0,0 @@
1
-
2
- export interface Subscription {
3
- id: string,
4
- accountId?: string,
5
- shopifyAppInstallId?: string,
6
- shopifyDomain?: string,
7
- stripeCustomerId?: string,
8
- stripeSubscriptionId?: string,
9
- stripeCompletedCheckoutSession?: any;
10
- shopifyChargeId?: string;
11
- subscriptionPlan?: SubscriptionPlan,
12
- status?: SUBSCRIPTION_STATUS,
13
- paymentStatus?: PAYMENT_STATUS,
14
- paymentGateway?: PAYMENT_GATEWAY,
15
- createdAt: string,
16
- updatedAt: string,
17
-
18
- }
19
- export interface SubscriptionPlan {
20
- id: number;
21
- planName: string;
22
- displayName: string;
23
- description: string;
24
- sku: string;
25
- price: string;
26
- displayPrice: string;
27
- billingFrequency: PLAN_BILLING_FREQUENCY;
28
- trialLengthDays?: number;
29
- trialRequiresCreditCard?: boolean;
30
- planDesc?: string[];
31
- unitPriceText?: string;
32
- isHighlighted?: boolean;
33
- isBanner?: boolean;
34
- bannerText?: string;
35
- bannerColor?: string;
36
- stripePriceId?: string;
37
- stripeProductId?: string;
38
- }
39
-
40
- export enum PLAN_BILLING_FREQUENCY {
41
- MONTHLY = 'monthly',
42
- YEARLY = 'yearly'
43
- }
44
-
45
- export enum PAYMENT_STATUS {
46
- CURRENT = 'current',
47
- PAST_DUE = 'past_due',
48
- CANCELLED = 'cancelled',
49
- FAILED = 'failed'
50
- }
51
-
52
- export enum SUBSCRIPTION_STATUS {
53
- ACTIVE = 'active', // approved and billed to shop
54
- CANCELLED = 'cancelled', // cancelled, uninstalled or cancellation
55
- DECLINED = 'declined', // subscription declined by merchant
56
- EXPIRED = 'expired', //wasn't approved within two days of being created
57
- FROZEN = 'frozen', //on hold due to not payment
58
- PENDING = 'pending', // pending approval
59
- NOT_SUBMITTED = 'na' // billing has not yet been attempted
60
- }
61
- export enum PAYMENT_GATEWAY {
62
- STRIPE = 'stripe',
63
- PAYPAL = 'paypal',
64
- SHOPIFY = 'shopify'
65
- }
@@ -1,14 +0,0 @@
1
-
2
- export interface User {
3
- id: string;
4
- sub: string,
5
- userId: string;
6
- Username: string,
7
- UserLastModifiedDate: string,
8
- Enabled: boolean,
9
- UserStatus: string,
10
- email: string,
11
- email_verified: string,
12
- name: string,
13
- family_name: string,
14
- }