@metarouter/ajs-starter-kit 1.0.176 → 1.0.177

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.
@@ -0,0 +1 @@
1
+ "153b4e04b26116f8c14ceccb3cb9af46 -"
@@ -0,0 +1,33 @@
1
+ {
2
+ "params": [
3
+ {
4
+ "name": "DOMAIN_URL",
5
+ "exampleValue": "my-domain-url"
6
+ },
7
+ {
8
+ "name": "TOKEN_AUTH",
9
+ "exampleValue": "my-token-auth",
10
+ "isOptional": true,
11
+ "isSensitive": true
12
+ }
13
+ ],
14
+ "default": {
15
+ "endpoint": "$$DOMAIN_URL$$/matomo.php",
16
+ "method": "POST",
17
+ "batchSize": 500,
18
+ "headers": [
19
+ {
20
+ "key": "Content-Type",
21
+ "value": "application/json"
22
+ },
23
+ {
24
+ "key": "Accept-Encoding",
25
+ "value": "application/json"
26
+ }
27
+ ],
28
+ "transform": {
29
+ "lang": "lua",
30
+ "body": "local function to_request(event)\n local parts = {}\n for key, value in pairs(event) do\n parts[#parts + 1] = key .. \"=\" .. QUERY_ESCAPE(TO_STRING(value))\n end\n return \"?\" .. JOIN(parts, \"&\")\nend\nlocal body = { requests = MAP(batch, to_request) }\n\nlocal token_auth = \"$$TOKEN_AUTH$$\"\nif token_auth ~= \"\" and token_auth ~= \"my-token-auth\" and REPLACE(token_auth, \"$$\", \"\") == token_auth then\n body.token_auth = token_auth\nend\n\nrequest.body = body\nreturn request"
31
+ }
32
+ }
33
+ }
@@ -0,0 +1 @@
1
+ "89aa710cee0fde359180e234e0a1c83e -"
@@ -0,0 +1,21 @@
1
+ {
2
+ "isDraft": false,
3
+ "isDeprecated": false,
4
+ "isBeta": true,
5
+ "friendlyName": "Matomo",
6
+ "description": "Matomo is an open-source web analytics platform that provides page view, event, visit, ecommerce, and campaign attribution tracking.",
7
+ "logo": "https://cdn.metarouter.io/matomo.png",
8
+ "color": "#d4291f",
9
+ "eventSource": {
10
+ "isAndroidApp": false,
11
+ "isIosApp": false,
12
+ "isWebApp": true
13
+ },
14
+ "inputSchema": "analytics_js",
15
+ "releaseNotes": [
16
+ {
17
+ "date": "2026-07-15T21:00:00.000Z",
18
+ "note": "Version: 0.1.0\nBeta Version\nMatomo initial release"
19
+ }
20
+ ]
21
+ }
@@ -0,0 +1 @@
1
+ "e342de08780aaeb05311cc16e674184e -"
@@ -0,0 +1,320 @@
1
+ {
2
+ "version": "0.1.0",
3
+ "params": [
4
+ {
5
+ "name": "SITE_ID",
6
+ "exampleValue": "my-site-id"
7
+ }
8
+ ],
9
+ "global": {
10
+ "enrichments": [
11
+ {
12
+ "staticString": "1",
13
+ "outputKey": "rec"
14
+ },
15
+ {
16
+ "staticString": "1",
17
+ "outputKey": "apiv"
18
+ },
19
+ {
20
+ "staticString": "$$SITE_ID$$",
21
+ "outputKey": "idsite"
22
+ }
23
+ ],
24
+ "mappings": [
25
+ {
26
+ "inputKey": "context.page.url",
27
+ "outputKey": "url"
28
+ },
29
+ {
30
+ "inputKey": "context.page.referrer",
31
+ "outputKey": "urlref"
32
+ },
33
+ {
34
+ "inputKey": "context.userAgent",
35
+ "outputKey": "ua"
36
+ },
37
+ {
38
+ "inputKey": "userId",
39
+ "outputKey": "uid"
40
+ },
41
+ {
42
+ "inputKey": "context.ip",
43
+ "outputKey": "cip"
44
+ },
45
+ {
46
+ "inputKey": "traits.address.city",
47
+ "outputKey": "city"
48
+ },
49
+ {
50
+ "inputKey": "context.locale",
51
+ "outputKey": "lang"
52
+ },
53
+ {
54
+ "inputKey": "messageId",
55
+ "outputKey": "rand"
56
+ },
57
+ {
58
+ "inputKey": "input",
59
+ "outputKey": "_id",
60
+ "transforms": [
61
+ {
62
+ "expression": {
63
+ "lang": "lua",
64
+ "body": "return SUBSTRING(REPLACE(input.anonymousId, \"-\", \"\"), 0, 16)"
65
+ }
66
+ }
67
+ ]
68
+ },
69
+ {
70
+ "inputKey": "input",
71
+ "outputKey": "cdt",
72
+ "transforms": [
73
+ {
74
+ "expression": {
75
+ "lang": "lua",
76
+ "body": "return SECONDS_SINCE_EPOCH_FROM_RFC3999(TO_DATE_TIME(input.timestamp or input.originalTimestamp or input.sentAt))"
77
+ }
78
+ }
79
+ ]
80
+ }
81
+ ]
82
+ },
83
+ "default": {
84
+ "filters": [
85
+ {
86
+ "byEventNames": {
87
+ "action": "allow",
88
+ "events": [
89
+ ""
90
+ ]
91
+ }
92
+ }
93
+ ]
94
+ },
95
+ "eventSpecific": {
96
+ "page": {
97
+ "mappings": [
98
+ {
99
+ "inputKey": "context.page.title",
100
+ "outputKey": "action_name"
101
+ }
102
+ ]
103
+ },
104
+ "products_searched": {
105
+ "mappings": [
106
+ {
107
+ "inputKey": "properties.query",
108
+ "outputKey": "search"
109
+ }
110
+ ]
111
+ },
112
+ "product_list_viewed": {
113
+ "mappings": [
114
+ {
115
+ "inputKey": "properties.category",
116
+ "outputKey": "_pkc"
117
+ }
118
+ ]
119
+ },
120
+ "product_viewed": {
121
+ "mappings": [
122
+ {
123
+ "inputKey": "input",
124
+ "outputKey": "_pks",
125
+ "transforms": [
126
+ {
127
+ "expression": {
128
+ "lang": "lua",
129
+ "body": "return input.properties.sku or input.properties.product_id"
130
+ }
131
+ }
132
+ ]
133
+ },
134
+ {
135
+ "inputKey": "properties.name",
136
+ "outputKey": "_pkn"
137
+ },
138
+ {
139
+ "inputKey": "properties.category",
140
+ "outputKey": "_pkc"
141
+ },
142
+ {
143
+ "inputKey": "properties.price",
144
+ "outputKey": "_pkp",
145
+ "transforms": [
146
+ {
147
+ "toScalar": "float"
148
+ }
149
+ ]
150
+ }
151
+ ]
152
+ },
153
+ "cart_viewed": {
154
+ "enrichments": [
155
+ {
156
+ "staticString": "0",
157
+ "outputKey": "idgoal"
158
+ }
159
+ ],
160
+ "mappings": [
161
+ {
162
+ "inputKey": "input",
163
+ "outputKey": "ec_items",
164
+ "transforms": [
165
+ {
166
+ "expression": {
167
+ "lang": "lua",
168
+ "body": "local function item(p)\n return {\n p.sku or p.product_id,\n p.name or \"\",\n p.category or \"\",\n TO_FLOAT(p.price or 0),\n TO_TRUNCATED_INT(p.quantity or 1),\n }\nend\nreturn MAP(input.properties.products, item)"
169
+ }
170
+ }
171
+ ]
172
+ },
173
+ {
174
+ "inputKey": "input",
175
+ "outputKey": "revenue",
176
+ "transforms": [
177
+ {
178
+ "expression": {
179
+ "lang": "lua",
180
+ "body": "return TOTAL_VALUE(input.properties.products)"
181
+ }
182
+ }
183
+ ]
184
+ }
185
+ ]
186
+ },
187
+ "checkout_started": {
188
+ "enrichments": [
189
+ {
190
+ "staticString": "0",
191
+ "outputKey": "idgoal"
192
+ }
193
+ ],
194
+ "mappings": [
195
+ {
196
+ "inputKey": "properties.revenue",
197
+ "outputKey": "revenue",
198
+ "transforms": [
199
+ {
200
+ "toScalar": "float"
201
+ }
202
+ ]
203
+ },
204
+ {
205
+ "inputKey": "input",
206
+ "outputKey": "ec_items",
207
+ "transforms": [
208
+ {
209
+ "expression": {
210
+ "lang": "lua",
211
+ "body": "local function item(p)\n return {\n p.sku or p.product_id,\n p.name or \"\",\n p.category or \"\",\n TO_FLOAT(p.price or 0),\n TO_TRUNCATED_INT(p.quantity or 1),\n }\nend\nreturn MAP(input.properties.products, item)"
212
+ }
213
+ }
214
+ ]
215
+ }
216
+ ]
217
+ },
218
+ "order_completed": {
219
+ "enrichments": [
220
+ {
221
+ "staticString": "0",
222
+ "outputKey": "idgoal"
223
+ }
224
+ ],
225
+ "mappings": [
226
+ {
227
+ "inputKey": "properties.order_id",
228
+ "outputKey": "ec_id"
229
+ },
230
+ {
231
+ "inputKey": "properties.total",
232
+ "outputKey": "revenue",
233
+ "transforms": [
234
+ {
235
+ "toScalar": "float"
236
+ }
237
+ ]
238
+ },
239
+ {
240
+ "inputKey": "properties.revenue",
241
+ "outputKey": "ec_st",
242
+ "transforms": [
243
+ {
244
+ "toScalar": "float"
245
+ }
246
+ ]
247
+ },
248
+ {
249
+ "inputKey": "properties.tax",
250
+ "outputKey": "ec_tx",
251
+ "transforms": [
252
+ {
253
+ "toScalar": "float"
254
+ }
255
+ ]
256
+ },
257
+ {
258
+ "inputKey": "properties.shipping",
259
+ "outputKey": "ec_sh",
260
+ "transforms": [
261
+ {
262
+ "toScalar": "float"
263
+ }
264
+ ]
265
+ },
266
+ {
267
+ "inputKey": "properties.discount",
268
+ "outputKey": "ec_dt",
269
+ "transforms": [
270
+ {
271
+ "toScalar": "float"
272
+ }
273
+ ]
274
+ },
275
+ {
276
+ "inputKey": "input",
277
+ "outputKey": "ec_items",
278
+ "transforms": [
279
+ {
280
+ "expression": {
281
+ "lang": "lua",
282
+ "body": "local function item(p)\n return {\n p.sku or p.product_id,\n p.name or \"\",\n p.category or \"\",\n TO_FLOAT(p.price or 0),\n TO_TRUNCATED_INT(p.quantity or 1),\n }\nend\nreturn MAP(input.properties.products, item)"
283
+ }
284
+ }
285
+ ]
286
+ }
287
+ ]
288
+ },
289
+ "promotion_viewed": {
290
+ "mappings": [
291
+ {
292
+ "inputKey": "properties.name",
293
+ "outputKey": "c_n"
294
+ },
295
+ {
296
+ "inputKey": "properties.creative",
297
+ "outputKey": "c_p"
298
+ }
299
+ ]
300
+ },
301
+ "promotion_clicked": {
302
+ "enrichments": [
303
+ {
304
+ "staticString": "click",
305
+ "outputKey": "c_i"
306
+ }
307
+ ],
308
+ "mappings": [
309
+ {
310
+ "inputKey": "properties.name",
311
+ "outputKey": "c_n"
312
+ },
313
+ {
314
+ "inputKey": "properties.creative",
315
+ "outputKey": "c_p"
316
+ }
317
+ ]
318
+ }
319
+ }
320
+ }
package/README.md CHANGED
@@ -1,17 +1,9 @@
1
1
  # MetaRouter Starter Kits
2
2
 
3
- ### 2026-06
4
- - Braze
5
- - CM360 - Floodlights
6
- - Google Ads - Conversions
7
- - Google Analytics 4
8
- - Google Analytics 4 (Collect)
9
- - Heap
10
- - Podscribe
11
- - Teads CAPI (New)
12
- - Teads Postback
13
- - Wirtualna Polska
14
- - Yahoo Conversions API
3
+ ### 2026-07
4
+ - Matomo (New)
5
+ - Meta CAPI
6
+ - OpenAI CAPI
15
7
 
16
8
  | Kit Name | Initial Release Date | Stable Release Date | Latest Release Date | Current Version | Latest Note |
17
9
  |----------|----------------------|---------------------|---------------------|-----------------|-------------|
@@ -71,6 +63,7 @@
71
63
  | Lytics | 2021-06-24 | N/A | 2024-10-23 | Version: 1.1.0 | Added header `Accept-Encoding: application/json` |
72
64
  | MIQ (Xandr) | 2023-03-07 | N/A | 2024-10-23 | Version: 0.2.0 | Added header `Accept-Encoding: application/json` |
73
65
  | Magellan AI | 2024-07-24 | 2024-08-07 | 2025-07-30 | Version: 1.2.0 | Replaced context.traits with traits. |
66
+ | Matomo (New) | 2026-07-15 | N/A | 2026-07-15 | Version: 0.1.0 | Beta Version Matomo initial release |
74
67
  | Merkle | 2021-06-24 | N/A | 2025-07-30 | Version: 1.3.0 | Replaced context.traits with traits. |
75
68
  | Meta CAPI | 2021-06-24 | N/A | 2026-07-01 | Version: 1.12.0 | Relocate partner_agent field. |
76
69
  | Microsoft Ads | 2025-01-22 | 2025-04-02 | 2025-12-17 | Version: 1.2.0 | Deprecating this in favor of the released Microsoft Ads CAPI kit |
@@ -82,7 +75,7 @@
82
75
  | Movable Ink - Customer Data | 2024-02-07 | 2024-04-24 | 2025-07-16 | Version: 1.3.0 | TABLE_SLICE custom function usage. |
83
76
  | Nextdoor | 2023-03-07 | 2024-08-07 | 2026-04-15 | Version: 1.1.0 | Deprecating in favor of the released Nextdoor CAPI Kit |
84
77
  | Nextdoor - CAPI | 2024-06-05 | 2024-07-17 | 2025-10-08 | Version: 1.4.0 | Extended Nextdoor CAPI events. |
85
- | OpenAI CAPI (New) | 2026-06-10 | 2026-07-01 | 2026-07-01 | Version: 1.0.0 | Stable Release |
78
+ | OpenAI CAPI | 2026-06-10 | 2026-07-01 | 2026-07-01 | Version: 1.0.0 | Stable Release |
86
79
  | Optimizely | 2026-01-28 | 2026-02-18 | 2026-02-18 | Version: 1.0.0 | Stable Release |
87
80
  | Perion | 2025-05-21 | 2025-07-16 | 2025-10-15 | Version: 1.0.1 | Added friendly names to expressions |
88
81
  | Pinterest Ads | 2021-06-24 | N/A | 2025-10-15 | Version: 1.1.1 | Added friendly names to expressions |
@@ -102,7 +95,7 @@
102
95
  | Snapchat Ads | 2021-06-24 | N/A | 2025-10-15 | Version: 1.1.1 | Added friendly names to expressions |
103
96
  | Snowflake | 2021-06-24 | N/A | 2025-10-15 | Version: 0.1.2 | Added friendly names to expressions |
104
97
  | Stdout | 2026-03-18 | N/A | 2026-03-18 | Version: 0.1.0 | Beta Version Stdout initial release |
105
- | Teads CAPI (New) | 2026-06-03 | 2026-06-24 | 2026-06-24 | Version: 1.0.0 | Stable Release |
98
+ | Teads CAPI | 2026-06-03 | 2026-06-24 | 2026-06-24 | Version: 1.0.0 | Stable Release |
106
99
  | Teads Postback | 2025-11-12 | 2026-01-07 | 2026-06-24 | Version: 1.0.1 | Updated friendly name |
107
100
  | The Trade Desk - Conversions | 2025-06-04 | 2025-07-30 | 2025-12-10 | Version: 1.2.0 | Updating identifier mappings |
108
101
  | The Trade Desk - Offline Conversions | 2026-02-25 | 2026-04-08 | 2026-04-08 | Version: 1.0.0 | Stable Release |
package/index.js CHANGED
@@ -387,6 +387,12 @@ exports['magellan-ai'] = {
387
387
  metadata: require('./.dist/magellan-ai/metadata.json')
388
388
  }
389
389
 
390
+ exports['matomo'] = {
391
+ endpointSchema: require('./.dist/matomo/connection.json'),
392
+ playbook: require('./.dist/matomo/playbook.json'),
393
+ metadata: require('./.dist/matomo/metadata.json')
394
+ }
395
+
390
396
  exports['media-math'] = {
391
397
  endpointSchema: require('./.dist/media-math/connection.json'),
392
398
  playbook: require('./.dist/media-math/playbook.json'),
@@ -965,6 +971,11 @@ exports.etags = {
965
971
  playbook: require('./.dist/magellan-ai/playbook.etag.json'),
966
972
  kit: require('./.dist/magellan-ai/kit.etag.json')
967
973
  },
974
+ 'matomo': {
975
+ endpointSchema: require('./.dist/matomo/connection.etag.json'),
976
+ playbook: require('./.dist/matomo/playbook.etag.json'),
977
+ kit: require('./.dist/matomo/kit.etag.json')
978
+ },
968
979
  'media-math': {
969
980
  endpointSchema: require('./.dist/media-math/connection.etag.json'),
970
981
  playbook: require('./.dist/media-math/playbook.etag.json'),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@metarouter/ajs-starter-kit",
3
- "version": "1.0.176",
3
+ "version": "1.0.177",
4
4
  "description": "MetaRouter analytics.js starter kit",
5
5
  "main": "index.js",
6
6
  "scripts": {