@walkeros/web-destination-api 4.7.1 → 4.7.2-next-1791213015481
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/CHANGELOG.md +13 -0
- package/dist/index.browser.js +1 -1
- package/dist/walkerOS.json +7 -7
- package/package.json +4 -4
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,18 @@
|
|
|
1
1
|
# @walkeros/web-destination-api
|
|
2
2
|
|
|
3
|
+
## 4.7.2-next-1791213015481
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [98398fe]
|
|
8
|
+
- Updated dependencies [98398fe]
|
|
9
|
+
- Updated dependencies [ff23953]
|
|
10
|
+
- Updated dependencies [ff23953]
|
|
11
|
+
- Updated dependencies [98398fe]
|
|
12
|
+
- Updated dependencies [98398fe]
|
|
13
|
+
- @walkeros/core@4.7.2-next-1791213015481
|
|
14
|
+
- @walkeros/web-core@4.7.2-next-1791213015481
|
|
15
|
+
|
|
3
16
|
## 4.7.1
|
|
4
17
|
|
|
5
18
|
### Patch Changes
|
package/dist/index.browser.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var Walkerjs=(()=>{var t=Object.defineProperty,e=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,n=Object.prototype.hasOwnProperty,o={};((e,r)=>{for(var n in r)t(e,n,{get:r[n],enumerable:!0})})(o,{DestinationAPI:()=>O,default:()=>$,destinationAPI:()=>N});var s=Object.defineProperty,i=(t,e)=>{for(var r in e)s(t,r,{get:e[r],enumerable:!0})};function a(t,e){if("collector"===t)return"collector";if(!e)throw new Error(`stepId(${t}) requires an id`);return`${t}.${e}`}i({},{stepId:()=>a});function u(t,e){const r=t.destinations[e];if(!r)throw new Error(`Destination not found: ${e}`);return r}i({},{getDestination:()=>u});i({},{Level:()=>f});var c,f=((c=f||{})[c.ERROR=0]="ERROR",c[c.WARN=1]="WARN",c[c.INFO=2]="INFO",c[c.DEBUG=3]="DEBUG",c);function l(t,e){const r=t.transformers[e];if(!r)throw new Error(`Transformer not found: ${e}`);return r}i({},{getTransformer:()=>l});function d(t,e){const r=t.sources[e];if(!r)throw new Error(`Source not found: ${e}`);return r}i({},{getSource:()=>d});function g(t,e){const r=t.stores[e];if(!r)throw new Error(`Store not found: ${e}`);return r}async function p(t,e){return await t.get(e)}i({},{getStore:()=>g,getStoreValue:()=>p});var
|
|
1
|
+
"use strict";var Walkerjs=(()=>{var t=Object.defineProperty,e=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,n=Object.prototype.hasOwnProperty,o={};((e,r)=>{for(var n in r)t(e,n,{get:r[n],enumerable:!0})})(o,{DestinationAPI:()=>O,default:()=>$,destinationAPI:()=>N});var s=Object.defineProperty,i=(t,e)=>{for(var r in e)s(t,r,{get:e[r],enumerable:!0})};function a(t,e){if("collector"===t)return"collector";if(!e)throw new Error(`stepId(${t}) requires an id`);return`${t}.${e}`}i({},{stepId:()=>a});function u(t,e){const r=t.destinations[e];if(!r)throw new Error(`Destination not found: ${e}`);return r}i({},{getDestination:()=>u});i({},{Level:()=>f});var c,f=((c=f||{})[c.ERROR=0]="ERROR",c[c.WARN=1]="WARN",c[c.INFO=2]="INFO",c[c.DEBUG=3]="DEBUG",c);function l(t,e){const r=t.transformers[e];if(!r)throw new Error(`Transformer not found: ${e}`);return r}i({},{getTransformer:()=>l});function d(t,e){const r=t.sources[e];if(!r)throw new Error(`Source not found: ${e}`);return r}i({},{getSource:()=>d});function g(t,e){const r=t.stores[e];if(!r)throw new Error(`Store not found: ${e}`);return r}async function p(t,e){return await t.get(e)}function h(t){return void 0!==t}i({},{getStore:()=>g,getStoreValue:()=>p});var y={merge:!0,shallow:!0,extend:!0};function m(t,e,r){return function(...n){try{return t(...n)}catch(t){if(!e)return;return e(t)}finally{null==r||r()}}}function w(t){return void 0===t||function(t,e){return typeof t==typeof e}(t,"")?t:JSON.stringify(t)}function v(t={}){return function(t,e={},r={}){r={...y,...r};const n=Object.entries(e).reduce((e,[n,o])=>{const s=t[n];return r.merge&&Array.isArray(s)&&Array.isArray(o)?e[n]=o.reduce((t,e)=>t.includes(e)?t:[...t,e],[...s]):(r.extend||n in t)&&(e[n]=o),e},{});return r.shallow?{...t,...n}:(Object.assign(t,n),t)}({"Content-Type":"application/json; charset=utf-8"},t)}function b(t,e,r={transport:"fetch"}){switch(r.transport||"fetch"){case"beacon":return function(t,e){const r=w(e),n=navigator.sendBeacon(t,r);return{ok:n,error:n?void 0:"Failed to send beacon"}}(t,e);case"xhr":return function(t,e,r={}){const n=v(r.headers),o=r.method||"POST",s=w(e);return m(()=>{const e=new XMLHttpRequest;e.open(o,t,!1);for(const t in n)e.setRequestHeader(t,n[t]);e.send(s);const r=e.status>=200&&e.status<300;return{ok:r,data:m(JSON.parse,()=>e.response)(e.response),error:r?void 0:`${e.status} ${e.statusText}`}},t=>({ok:!1,error:t.message}))()}(t,e,r);default:return async function(t,e,r={}){const n=v(r.headers),o=w(e),s=r.timeout,i="number"==typeof s&&Number.isFinite(s)&&s>0?s:1e4,a=new AbortController,u=setTimeout(()=>a.abort(),i);return function(t,e,r){return async function(...n){try{return await t(...n)}catch(t){if(!e)return;return await e(t)}finally{await(null==r?void 0:r())}}}(async()=>{try{const e=await fetch(t,{method:r.method||"POST",headers:n,keepalive:!0,credentials:r.credentials||"same-origin",mode:r.noCors?"no-cors":"cors",body:o,signal:a.signal}),s=r.noCors?"":await e.text();return{ok:e.ok,data:s,error:e.ok?void 0:e.statusText}}finally{clearTimeout(u)}},t=>(clearTimeout(u),{ok:!1,error:t.message}))()}(t,e,r)}}var O={};function j(t,e,r){const{url:n,headers:o,method:s,transport:i="fetch"}=e;r(n,t,{headers:o,method:s,transport:i})}var S,N={type:"api",config:{},init({config:t,logger:e}){const{url:r}=t.settings||{};r||e.throw("Config settings url missing")},push(t,{config:e,rule:r,data:n,env:o,logger:s}){const{settings:i}=e,{url:a,transform:u}=i||{};if(!a)return void s.throw("Config settings url missing");const c=h(n)?n:t,f=u?u(c,e,r):JSON.stringify(c),l=function(t,e){var r;const n=null==(r=t.source)?void 0:r.trace,{id:o}=t,s=e&&Object.keys(e).some(t=>"traceparent"===t.toLowerCase());return n&&o&&!s?{...e,traceparent:`00-${n}-${o}-01`}:e}(t,null==i?void 0:i.headers);j(f,{...i,url:a,headers:l},o.sendWeb||b)},pushBatch(t,{config:e,rule:r,env:n,logger:o}){const{settings:s}=e,{url:i,transform:a}=s||{};if(!i)return void o.throw("Config settings url missing");const u=t.entries.map(t=>h(t.data)?t.data:t.event),c=a?u.map(t=>function(t){if("string"!=typeof t)return t;try{const e=JSON.parse(t);return"object"==typeof e&&null!==e?e:t}catch(e){return t}}(a(t,e,r))):u;j(JSON.stringify(c),{...s,url:i},n.sendWeb||b)}},$=N;return S=o,((o,s,i,a)=>{if(s&&"object"==typeof s||"function"==typeof s)for(let u of r(s))n.call(o,u)||u===i||t(o,u,{get:()=>s[u],enumerable:!(a=e(s,u))||a.enumerable});return o})(t({},"__esModule",{value:!0}),S)})();
|
package/dist/walkerOS.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$meta": {
|
|
3
3
|
"package": "@walkeros/web-destination-api",
|
|
4
|
-
"version": "4.7.
|
|
4
|
+
"version": "4.7.2-next-1791213015481",
|
|
5
5
|
"type": "destination",
|
|
6
6
|
"platform": [
|
|
7
7
|
"web"
|
|
@@ -154,7 +154,7 @@
|
|
|
154
154
|
"consent": {
|
|
155
155
|
"functional": true
|
|
156
156
|
},
|
|
157
|
-
"id": "
|
|
157
|
+
"id": "d2237a64c3e41db7",
|
|
158
158
|
"trigger": "load",
|
|
159
159
|
"entity": "order",
|
|
160
160
|
"action": "complete",
|
|
@@ -187,7 +187,7 @@
|
|
|
187
187
|
"{\"order_id\":\"0rd3r1d\",\"amount\":555,\"tax\":73.76,\"shipping_cost\":5.22,\"currency\":\"EUR\",\"event_name\":\"order complete\",\"user_id\":\"us3r\"}",
|
|
188
188
|
{
|
|
189
189
|
"headers": {
|
|
190
|
-
"traceparent": "00-0a1b2c3d4e5f60718293a4b5c6d7e8f9-
|
|
190
|
+
"traceparent": "00-0a1b2c3d4e5f60718293a4b5c6d7e8f9-d2237a64c3e41db7-01"
|
|
191
191
|
},
|
|
192
192
|
"transport": "fetch"
|
|
193
193
|
}
|
|
@@ -237,7 +237,7 @@
|
|
|
237
237
|
"consent": {
|
|
238
238
|
"functional": true
|
|
239
239
|
},
|
|
240
|
-
"id": "
|
|
240
|
+
"id": "03d83eaa41fdb322",
|
|
241
241
|
"trigger": "test",
|
|
242
242
|
"entity": "entity",
|
|
243
243
|
"action": "action",
|
|
@@ -260,7 +260,7 @@
|
|
|
260
260
|
"{\"string\":\"foo\",\"number\":1,\"boolean\":true,\"array\":[0,\"text\",false]}",
|
|
261
261
|
{
|
|
262
262
|
"headers": {
|
|
263
|
-
"traceparent": "00-0a1b2c3d4e5f60718293a4b5c6d7e8f9-
|
|
263
|
+
"traceparent": "00-0a1b2c3d4e5f60718293a4b5c6d7e8f9-03d83eaa41fdb322-01"
|
|
264
264
|
},
|
|
265
265
|
"transport": "fetch"
|
|
266
266
|
}
|
|
@@ -308,7 +308,7 @@
|
|
|
308
308
|
"consent": {
|
|
309
309
|
"functional": true
|
|
310
310
|
},
|
|
311
|
-
"id": "
|
|
311
|
+
"id": "910950a07440df50",
|
|
312
312
|
"trigger": "load",
|
|
313
313
|
"entity": "page",
|
|
314
314
|
"action": "view",
|
|
@@ -331,7 +331,7 @@
|
|
|
331
331
|
"{\"domain\":\"www.example.com\",\"title\":\"walkerOS documentation\",\"referrer\":\"https://www.walkeros.io/\",\"search\":\"?foo=bar\",\"hash\":\"#hash\",\"id\":\"/docs/\"}",
|
|
332
332
|
{
|
|
333
333
|
"headers": {
|
|
334
|
-
"traceparent": "00-0a1b2c3d4e5f60718293a4b5c6d7e8f9-
|
|
334
|
+
"traceparent": "00-0a1b2c3d4e5f60718293a4b5c6d7e8f9-910950a07440df50-01"
|
|
335
335
|
},
|
|
336
336
|
"transport": "fetch"
|
|
337
337
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@walkeros/web-destination-api",
|
|
3
3
|
"description": "Web API destination for walkerOS",
|
|
4
|
-
"version": "4.7.
|
|
4
|
+
"version": "4.7.2-next-1791213015481",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"main": "./dist/index.js",
|
|
7
7
|
"module": "./dist/index.mjs",
|
|
@@ -38,11 +38,11 @@
|
|
|
38
38
|
"update": "npx npm-check-updates -u && npm update"
|
|
39
39
|
},
|
|
40
40
|
"dependencies": {
|
|
41
|
-
"@walkeros/core": "4.7.
|
|
42
|
-
"@walkeros/web-core": "4.7.
|
|
41
|
+
"@walkeros/core": "4.7.2-next-1791213015481",
|
|
42
|
+
"@walkeros/web-core": "4.7.2-next-1791213015481"
|
|
43
43
|
},
|
|
44
44
|
"devDependencies": {
|
|
45
|
-
"@walkeros/collector": "4.7.
|
|
45
|
+
"@walkeros/collector": "4.7.2-next-1791213015481"
|
|
46
46
|
},
|
|
47
47
|
"repository": {
|
|
48
48
|
"url": "git+https://github.com/elbwalker/walkerOS.git",
|