@vibiz/cli 0.3.24 → 0.3.26
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.
|
@@ -857,7 +857,33 @@ var Vibiz = class {
|
|
|
857
857
|
/** Visitors, pageviews, top pages, sources, countries, events and a timeseries. */
|
|
858
858
|
get: (projectId, opts = {}) => this.request(
|
|
859
859
|
`/projects/${projectId}/analytics?period=${opts.period ?? "7d"}`
|
|
860
|
-
)
|
|
860
|
+
),
|
|
861
|
+
/**
|
|
862
|
+
* Visitor journeys, newest first: each visitor-day's source, landing page,
|
|
863
|
+
* pages in order, events, and whether it converted (a sale or a goal event).
|
|
864
|
+
*/
|
|
865
|
+
visitors: (projectId, opts = {}) => {
|
|
866
|
+
const q = new URLSearchParams();
|
|
867
|
+
q.set("period", opts.period ?? "7d");
|
|
868
|
+
if (opts.source) q.set("source", opts.source);
|
|
869
|
+
if (opts.landing) q.set("landing", opts.landing);
|
|
870
|
+
if (opts.country) q.set("country", opts.country);
|
|
871
|
+
if (opts.converted) q.set("converted", "true");
|
|
872
|
+
if (opts.goals?.length) q.set("goals", opts.goals.join(","));
|
|
873
|
+
if (opts.limit) q.set("limit", String(opts.limit));
|
|
874
|
+
if (opts.cursor) q.set("cursor", opts.cursor);
|
|
875
|
+
return this.request(`/projects/${projectId}/analytics/visitors?${q}`);
|
|
876
|
+
},
|
|
877
|
+
/** One visitor's path on one UTC day: the timeline, its replays and the sales it led to. */
|
|
878
|
+
visitor: (projectId, visitorId, opts = {}) => {
|
|
879
|
+
const q = new URLSearchParams();
|
|
880
|
+
if (opts.day) q.set("day", opts.day);
|
|
881
|
+
if (opts.goals?.length) q.set("goals", opts.goals.join(","));
|
|
882
|
+
const qs2 = q.size ? `?${q}` : "";
|
|
883
|
+
return this.request(
|
|
884
|
+
`/projects/${projectId}/analytics/visitors/${encodeURIComponent(visitorId)}${qs2}`
|
|
885
|
+
);
|
|
886
|
+
}
|
|
861
887
|
};
|
|
862
888
|
/**
|
|
863
889
|
* Mission Control (docs: Mission Control and health checks): every business
|
|
@@ -2228,7 +2254,7 @@ function formatMinor(minor, currency) {
|
|
|
2228
2254
|
}
|
|
2229
2255
|
|
|
2230
2256
|
// packages/sdk/src/one-key.ts
|
|
2231
|
-
var APP_SDK_VERSION = "0.3.
|
|
2257
|
+
var APP_SDK_VERSION = "0.3.26";
|
|
2232
2258
|
var ONE_KEY_GIVES = "database, sign-in, email and inbox, AI models, files, payments, analytics with session replays, web data, social, phone and connectors";
|
|
2233
2259
|
function oneKeyMessage(url, host) {
|
|
2234
2260
|
const where = host ?? "your host";
|