@metarouter/ajs-starter-kit 1.0.66 → 1.0.68

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 (38) hide show
  1. package/.dist/actioniq/kit.etag.json +1 -1
  2. package/.dist/actioniq/playbook.etag.json +1 -1
  3. package/.dist/actioniq/playbook.json +1 -1
  4. package/.dist/amperity/connection.etag.json +1 -0
  5. package/.dist/amperity/connection.json +38 -0
  6. package/.dist/amperity/kit.etag.json +1 -0
  7. package/.dist/amperity/metadata.json +20 -0
  8. package/.dist/amperity/playbook.etag.json +1 -0
  9. package/.dist/amperity/playbook.json +51 -0
  10. package/.dist/google-ad-words/kit.etag.json +1 -1
  11. package/.dist/google-ad-words/metadata.json +5 -1
  12. package/.dist/google-ads/connection.etag.json +1 -0
  13. package/.dist/google-ads/connection.json +72 -0
  14. package/.dist/google-ads/kit.etag.json +1 -0
  15. package/.dist/google-ads/metadata.json +20 -0
  16. package/.dist/google-ads/playbook.etag.json +1 -0
  17. package/.dist/google-ads/playbook.json +148 -0
  18. package/.dist/google-analytics-4/connection.etag.json +1 -1
  19. package/.dist/google-analytics-4/connection.json +5 -1
  20. package/.dist/google-analytics-4/kit.etag.json +1 -1
  21. package/.dist/google-analytics-4/playbook.etag.json +1 -1
  22. package/.dist/google-analytics-4/playbook.json +233 -45
  23. package/.dist/kafka/kit.etag.json +1 -1
  24. package/.dist/kafka/metadata.json +1 -1
  25. package/.dist/kochava/connection.etag.json +1 -0
  26. package/.dist/kochava/connection.json +12 -0
  27. package/.dist/kochava/kit.etag.json +1 -0
  28. package/.dist/kochava/metadata.json +20 -0
  29. package/.dist/kochava/playbook.etag.json +1 -0
  30. package/.dist/kochava/playbook.json +487 -0
  31. package/.dist/pinterest-capi/kit.etag.json +1 -1
  32. package/.dist/pinterest-capi/playbook.etag.json +1 -1
  33. package/.dist/pinterest-capi/playbook.json +179 -2
  34. package/.dist/roomvo/connection.etag.json +1 -1
  35. package/.dist/roomvo/connection.json +21 -4
  36. package/.dist/roomvo/kit.etag.json +1 -1
  37. package/index.js +24 -0
  38. package/package.json +1 -1
@@ -1 +1 @@
1
- "f8667d47e7c87fcfe6e97b371ce5eb2d"
1
+ "3c438ef311690dbc4757b07d2399312a"
@@ -1 +1 @@
1
- "2d91ab698f70628a0dd1315050a37f46"
1
+ "e74c6dc1800f44708c6bd7344c6ddb58"
@@ -128,7 +128,7 @@
128
128
  "expressions": [
129
129
  {
130
130
  "lang": "lua",
131
- "body": "local eventName = REPLACE(LOWER(input.event), \" \", \"_\")\nlocal results = {}\n\nlocal flatten = FLATTEN(input.properties, \"\", \"_\", 2, { array_start_index = 1 })\nresults[eventName] = flatten\n\nreturn { properties = results }"
131
+ "body": "if input.event then\n local eventName = REPLACE(LOWER(input.event), \" \", \"_\")\n local results = {}\n local flatten = FLATTEN(input.properties, \"\", \"_\", 2, { array_start_index = 1 })\n results[eventName] = flatten\n return { properties = results }\nend"
132
132
  }
133
133
  ]
134
134
  }
@@ -0,0 +1 @@
1
+ "6d0279d8db032deebc6bd9c4407dc5f6"
@@ -0,0 +1,38 @@
1
+ {
2
+ "params": [
3
+ {
4
+ "name": "TENANT",
5
+ "exampleValue": "my-tenant-id"
6
+ },
7
+ {
8
+ "name": "TOKEN",
9
+ "exampleValue": "my-token"
10
+ },
11
+ {
12
+ "name": "STREAM_ID",
13
+ "exampleValue": "my-stream-id"
14
+ }
15
+ ],
16
+ "default": {
17
+ "endpoint": "https://$$TENANT$$.amperity.com/stream/v0/data/$$STREAM_ID$$",
18
+ "method": "POST",
19
+ "headers": [
20
+ {
21
+ "key": "X-Amperity-Tenant",
22
+ "value": "$$TENANT$$"
23
+ },
24
+ {
25
+ "key": "Content-Type",
26
+ "value": "application/json"
27
+ },
28
+ {
29
+ "key": "Accept-Encoding",
30
+ "value": "application/json"
31
+ },
32
+ {
33
+ "key": "Authorization",
34
+ "value": "Bearer $$TOKEN$$"
35
+ }
36
+ ]
37
+ }
38
+ }
@@ -0,0 +1 @@
1
+ "9da41f567b9b941480afd455d121428c"
@@ -0,0 +1,20 @@
1
+ {
2
+ "isDraft": false,
3
+ "isBeta": true,
4
+ "friendlyName": "Amperity",
5
+ "description": "Amperity is a customer data platform that helps companies to unify their customer data from multiple sources",
6
+ "logo": "https://cdn.metarouter.io/Amperity.png",
7
+ "color": "#10BC8B",
8
+ "eventSource": {
9
+ "isAndroidApp": false,
10
+ "isIosApp": false,
11
+ "isWebApp": true
12
+ },
13
+ "inputSchema": "analytics_js",
14
+ "releaseNotes": [
15
+ {
16
+ "date": "2023-07-06T00:00:00.000Z",
17
+ "note": "Amperity initial release."
18
+ }
19
+ ]
20
+ }
@@ -0,0 +1 @@
1
+ "71c76dbec22bb55c09a564e607db8635"
@@ -0,0 +1,51 @@
1
+ {
2
+ "version": "v0.0.1",
3
+ "global": {
4
+ "mappings": [
5
+ {
6
+ "inputKey": "messageId",
7
+ "outputKey": "messageId"
8
+ },
9
+ {
10
+ "inputKey": "anonymousId",
11
+ "outputKey": "anonymousId"
12
+ },
13
+ {
14
+ "inputKey": "userId",
15
+ "outputKey": "userId"
16
+ },
17
+ {
18
+ "inputKey": "originalTimestamp",
19
+ "outputKey": "originalTimestamp"
20
+ },
21
+ {
22
+ "inputKey": "timestamp",
23
+ "outputKey": "timestamp"
24
+ },
25
+ {
26
+ "inputKey": "context.userAgent",
27
+ "outputKey": "context.userAgent"
28
+ },
29
+ {
30
+ "inputKey": "context.providers",
31
+ "outputKey": "context.providers"
32
+ },
33
+ {
34
+ "inputKey": "traits",
35
+ "outputKey": "traits"
36
+ },
37
+ {
38
+ "inputKey": "type",
39
+ "outputKey": "event",
40
+ "transforms": [
41
+ {
42
+ "expression": {
43
+ "lang": "lua",
44
+ "body": "if (input.type == \"track\") then return REPLACE(LOWER(input.event), \" \", \"_\") end\nreturn input.type"
45
+ }
46
+ }
47
+ ]
48
+ }
49
+ ]
50
+ }
51
+ }
@@ -1 +1 @@
1
- "3cceb92d73d335e9c013d6743bfd5cb9"
1
+ "73c6b6f474f87a38856041e850bebb14"
@@ -1,5 +1,5 @@
1
1
  {
2
- "isDraft": false,
2
+ "isDraft": true,
3
3
  "isBeta": true,
4
4
  "friendlyName": "Google Ads",
5
5
  "description": "Google Ads makes it easy to show the world what’s unique about your business, so you can reach customers searching for what you offer.",
@@ -19,6 +19,10 @@
19
19
  {
20
20
  "date": "2022-11-16T00:00:00.000Z",
21
21
  "note": "Add isBeta field"
22
+ },
23
+ {
24
+ "date": "2023-07-04T00:00:00.000Z",
25
+ "note": "Deprecating this in favor of the newly released Google Ads kit"
22
26
  }
23
27
  ]
24
28
  }
@@ -0,0 +1 @@
1
+ "754d227567ff86705430a30e69bbbdf9"
@@ -0,0 +1,72 @@
1
+ {
2
+ "params": [
3
+ {
4
+ "name": "API_VERSION",
5
+ "defaultValue": "v14"
6
+ },
7
+ {
8
+ "name": "CUSTOMER_ID",
9
+ "exampleValue": "customer-id"
10
+ },
11
+ {
12
+ "name": "SERVICE_ACCOUNT_CLIENT_EMAIL",
13
+ "exampleValue": "service-account-client-email"
14
+ },
15
+ {
16
+ "name": "SERVICE_ACCOUNT_PRIVATE_KEY",
17
+ "exampleValue": "service-account-private-key"
18
+ }
19
+ ],
20
+ "default": {
21
+ "endpoint": "https://googleads.googleapis.com/$$API_VERSION$$/customers/$$CUSTOMER_ID$$:uploadClickConversions",
22
+ "batchSize": 100,
23
+ "method": "POST",
24
+ "headers": [
25
+ {
26
+ "key": "Content-Type",
27
+ "value": "application/x-www-form-urlencoded"
28
+ },
29
+ {
30
+ "key": "Accept-Encoding",
31
+ "value": "application/json"
32
+ }
33
+ ],
34
+ "oauth2_auth": {
35
+ "request": {
36
+ "url": "https://oauth2.googleapis.com/token",
37
+ "contentType": "application/x-www-form-urlencoded",
38
+ "method": "POST",
39
+ "body": [
40
+ {
41
+ "key": "grant_type",
42
+ "value": "urn:ietf:params:oauth:grant-type:jwt-bearer"
43
+ }
44
+ ]
45
+ },
46
+ "responseAccessTokenKey": "access_token",
47
+ "jwt": {
48
+ "claims": [
49
+ {
50
+ "key": "aud",
51
+ "value": "https://oauth2.googleapis.com/token"
52
+ },
53
+ {
54
+ "key": "scope",
55
+ "value": "https://www.googleapis.com/auth/adwords"
56
+ },
57
+ {
58
+ "key": "iss",
59
+ "value": "$$SERVICE_ACCOUNT_CLIENT_EMAIL$$"
60
+ }
61
+ ],
62
+ "signingMethod": "SIGNING_METHOD_RS256",
63
+ "rsaPemKey": "$$SERVICE_ACCOUNT_PRIVATE_KEY$$",
64
+ "requestKey": "assertion"
65
+ }
66
+ },
67
+ "transform": {
68
+ "lang": "lua",
69
+ "body": "request.body = { conversions = batch }\nreturn request"
70
+ }
71
+ }
72
+ }
@@ -0,0 +1 @@
1
+ "c0f1ae5b49b9dfcd4543bb181ead9c4f"
@@ -0,0 +1,20 @@
1
+ {
2
+ "isDraft": false,
3
+ "isBeta": true,
4
+ "friendlyName": "Google Ads",
5
+ "description": "Google Ads is an online advertising platform developed by Google, where advertisers bid to display advertisements to users.",
6
+ "logo": "https://cdn.metarouter.io/logo.svg",
7
+ "color": "#4185f5",
8
+ "eventSource": {
9
+ "isAndroidApp": true,
10
+ "isIosApp": true,
11
+ "isWebApp": true
12
+ },
13
+ "inputSchema": "analytics_js",
14
+ "releaseNotes": [
15
+ {
16
+ "date": "2023-07-04T00:00:00.000Z",
17
+ "note": "Google Ads initial release."
18
+ }
19
+ ]
20
+ }
@@ -0,0 +1 @@
1
+ "784aa57838afc393f56535fc586b8dae"
@@ -0,0 +1,148 @@
1
+ {
2
+ "version": "v0.0.1",
3
+ "params": [
4
+ {
5
+ "name": "CUSTOMER_ID",
6
+ "exampleValue": "customer-id"
7
+ },
8
+ {
9
+ "name": "PAGE_CONVERSION_ACTION",
10
+ "defaultValue": "page-conversion-action"
11
+ },
12
+ {
13
+ "name": "ORDER_COMPLETED_CONVERSION_ACTION",
14
+ "defaultValue": "order-completed-conversion-action"
15
+ }
16
+ ],
17
+ "default": {
18
+ "filters": [
19
+ {
20
+ "byEventNames": {
21
+ "action": "allow",
22
+ "events": [
23
+ ""
24
+ ]
25
+ }
26
+ }
27
+ ]
28
+ },
29
+ "global": {
30
+ "expressions": [
31
+ {
32
+ "lang": "lua",
33
+ "body": "local click_ids = {}\nif input.context.providers.googleGtag.data.wbraid then\n click_ids.wbraid = input.context.providers.googleGtag.data.wbraid\nelseif input.context.providers.googleGtag.data.gbraid then\n click_ids.gbraid = input.context.providers.googleGtag.data.gbraid\nend\nreturn click_ids"
34
+ }
35
+ ],
36
+ "filters": [
37
+ {
38
+ "byConditions": {
39
+ "action": "allow",
40
+ "when": {
41
+ "inputPathExists": {
42
+ "inputPath": "context.providers.googleGtag.data.gclid"
43
+ }
44
+ }
45
+ }
46
+ }
47
+ ],
48
+ "mappings": [
49
+ {
50
+ "inputKey": "context.providers.googleGtag.data.gclid",
51
+ "outputKey": "gclid"
52
+ },
53
+ {
54
+ "inputKey": "input",
55
+ "outputKey": "userIdentifiers",
56
+ "transforms": [
57
+ {
58
+ "expression": {
59
+ "lang": "lua",
60
+ "body": "if input.traits.email then\n return {{ hashedEmail = TO_SHA256_HASH(LOWER(TRIM(input.traits.email))) }}\nend"
61
+ }
62
+ }
63
+ ]
64
+ },
65
+ {
66
+ "inputKey": "input",
67
+ "outputKey": "conversionDateTime",
68
+ "transforms": [
69
+ {
70
+ "expression": {
71
+ "lang": "lua",
72
+ "body": "local date = input.originalTimestamp or input.sentAt\nlocal timezoneOffset = input.context.providers.googleGtag.data.timezone_offset or 0\nreturn TO_DATE_TIME(date, { inputFormat = \"2006-01-02T15:04:05Z07:00\", outputLocation = { name = \"!UTC\", offset = TO_TRUNCATED_INT(timezoneOffset) * 60 }, outputFormat = \"2006-01-02 15:04:05-07:00\" })"
73
+ }
74
+ }
75
+ ]
76
+ }
77
+ ]
78
+ },
79
+ "eventSpecific": {
80
+ "page": {
81
+ "enrichments": [
82
+ {
83
+ "outputKey": "conversionValue",
84
+ "staticInt": 1
85
+ }
86
+ ],
87
+ "mappings": [
88
+ {
89
+ "inputKey": "input",
90
+ "outputKey": "conversionAction",
91
+ "transforms": [
92
+ {
93
+ "expression": {
94
+ "body": "return \"customers/$$CUSTOMER_ID$$/conversionActions/$$PAGE_CONVERSION_ACTION$$\"",
95
+ "lang": "lua"
96
+ }
97
+ }
98
+ ]
99
+ }
100
+ ]
101
+ },
102
+ "order_completed": {
103
+ "mappings": [
104
+ {
105
+ "inputKey": "input",
106
+ "outputKey": "conversionAction",
107
+ "transforms": [
108
+ {
109
+ "expression": {
110
+ "body": "return \"customers/$$CUSTOMER_ID$$/conversionActions/$$ORDER_COMPLETED_CONVERSION_ACTION$$\"",
111
+ "lang": "lua"
112
+ }
113
+ }
114
+ ]
115
+ },
116
+ {
117
+ "inputKey": "properties.currency",
118
+ "outputKey": "currencyCode",
119
+ "transforms": [
120
+ {
121
+ "modifyString": "uppercase"
122
+ }
123
+ ]
124
+ },
125
+ {
126
+ "inputKey": "properties.revenue",
127
+ "outputKey": "conversionValue"
128
+ },
129
+ {
130
+ "inputKey": "properties.order_id",
131
+ "outputKey": "orderId"
132
+ },
133
+ {
134
+ "inputKey": "input",
135
+ "outputKey": "cartData.items",
136
+ "transforms": [
137
+ {
138
+ "expression": {
139
+ "body": "return MAP(\n input.properties.products,\n function (p)\n return {\n productId = p.product_id,\n quantity = p.quantity or 1,\n unitPrice = p.price\n }\n end\n)",
140
+ "lang": "lua"
141
+ }
142
+ }
143
+ ]
144
+ }
145
+ ]
146
+ }
147
+ }
148
+ }
@@ -1 +1 @@
1
- "861bbf3e2f69d82bc666d311ea580f62"
1
+ "367871f405d0a7248e21e5d2082adc89"
@@ -11,7 +11,11 @@
11
11
  "key": "Accept-Encoding",
12
12
  "value": "application/json"
13
13
  }
14
- ]
14
+ ],
15
+ "transform": {
16
+ "lang": "lua",
17
+ "body": "request.body = {\n client_id = batch[1].client_id,\n user_id = batch[1].user_id,\n timestamp_micros = batch[1].timestamp_micros,\n events = { batch[1].event }\n}\nreturn request"
18
+ }
15
19
  },
16
20
  "params": [
17
21
  {
@@ -1 +1 @@
1
- "6f425f03ed0c7cece997050145befbe7"
1
+ "1d393c4efd874fac2d3b07c9e537a4b6"
@@ -1 +1 @@
1
- "cd606abbb639430e994aa75840b008fd"
1
+ "7b81587a718ccd28d6ce08a1050f0acf"