zorihq 0.1.0 → 0.3.0
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 +21 -0
- package/package.json +1 -1
- package/resources/v1/analytics/analytics.d.mts +102 -0
- package/resources/v1/analytics/analytics.d.mts.map +1 -0
- package/resources/v1/analytics/analytics.d.ts +102 -0
- package/resources/v1/analytics/analytics.d.ts.map +1 -0
- package/resources/v1/analytics/analytics.js +21 -0
- package/resources/v1/analytics/analytics.js.map +1 -0
- package/resources/v1/analytics/analytics.mjs +16 -0
- package/resources/v1/analytics/analytics.mjs.map +1 -0
- package/resources/v1/analytics/events.d.mts +32 -0
- package/resources/v1/analytics/events.d.mts.map +1 -0
- package/resources/v1/analytics/events.d.ts +32 -0
- package/resources/v1/analytics/events.d.ts.map +1 -0
- package/resources/v1/analytics/events.js +23 -0
- package/resources/v1/analytics/events.js.map +1 -0
- package/resources/v1/analytics/events.mjs +19 -0
- package/resources/v1/analytics/events.mjs.map +1 -0
- package/resources/v1/analytics/index.d.mts +4 -0
- package/resources/v1/analytics/index.d.mts.map +1 -0
- package/resources/v1/analytics/index.d.ts +4 -0
- package/resources/v1/analytics/index.d.ts.map +1 -0
- package/resources/v1/analytics/index.js +11 -0
- package/resources/v1/analytics/index.js.map +1 -0
- package/resources/v1/analytics/index.mjs +5 -0
- package/resources/v1/analytics/index.mjs.map +1 -0
- package/resources/v1/analytics/visitors.d.mts +155 -0
- package/resources/v1/analytics/visitors.d.mts.map +1 -0
- package/resources/v1/analytics/visitors.d.ts +155 -0
- package/resources/v1/analytics/visitors.d.ts.map +1 -0
- package/resources/v1/analytics/visitors.js +102 -0
- package/resources/v1/analytics/visitors.js.map +1 -0
- package/resources/v1/analytics/visitors.mjs +98 -0
- package/resources/v1/analytics/visitors.mjs.map +1 -0
- package/resources/v1/analytics.d.mts +2 -0
- package/resources/v1/analytics.d.mts.map +1 -0
- package/resources/v1/analytics.d.ts +2 -0
- package/resources/v1/analytics.d.ts.map +1 -0
- package/resources/v1/analytics.js +6 -0
- package/resources/v1/analytics.js.map +1 -0
- package/resources/v1/analytics.mjs +3 -0
- package/resources/v1/analytics.mjs.map +1 -0
- package/resources/v1/index.d.mts +1 -0
- package/resources/v1/index.d.mts.map +1 -1
- package/resources/v1/index.d.ts +1 -0
- package/resources/v1/index.d.ts.map +1 -1
- package/resources/v1/index.js +3 -1
- package/resources/v1/index.js.map +1 -1
- package/resources/v1/index.mjs +1 -0
- package/resources/v1/index.mjs.map +1 -1
- package/resources/v1/projects.d.mts +6 -0
- package/resources/v1/projects.d.mts.map +1 -1
- package/resources/v1/projects.d.ts +6 -0
- package/resources/v1/projects.d.ts.map +1 -1
- package/resources/v1/v1.d.mts +4 -0
- package/resources/v1/v1.d.mts.map +1 -1
- package/resources/v1/v1.d.ts +4 -0
- package/resources/v1/v1.d.ts.map +1 -1
- package/resources/v1/v1.js +4 -0
- package/resources/v1/v1.js.map +1 -1
- package/resources/v1/v1.mjs +4 -0
- package/resources/v1/v1.mjs.map +1 -1
- package/src/resources/v1/analytics/analytics.ts +199 -0
- package/src/resources/v1/analytics/events.ts +39 -0
- package/src/resources/v1/analytics/index.ts +30 -0
- package/src/resources/v1/analytics/visitors.ts +210 -0
- package/src/resources/v1/analytics.ts +3 -0
- package/src/resources/v1/index.ts +18 -0
- package/src/resources/v1/projects.ts +12 -0
- package/src/resources/v1/v1.ts +40 -0
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,26 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.3.0 (2025-10-19)
|
|
4
|
+
|
|
5
|
+
Full Changelog: [v0.2.0...v0.3.0](https://github.com/ZoriHQ/typescript-api-sdk/compare/v0.2.0...v0.3.0)
|
|
6
|
+
|
|
7
|
+
### Features
|
|
8
|
+
|
|
9
|
+
* **api:** manual updates ([f91e9cb](https://github.com/ZoriHQ/typescript-api-sdk/commit/f91e9cbf30acae4a380f70de13fcf703624b0911))
|
|
10
|
+
|
|
11
|
+
## 0.2.0 (2025-10-19)
|
|
12
|
+
|
|
13
|
+
Full Changelog: [v0.1.0...v0.2.0](https://github.com/ZoriHQ/typescript-api-sdk/compare/v0.1.0...v0.2.0)
|
|
14
|
+
|
|
15
|
+
### Features
|
|
16
|
+
|
|
17
|
+
* **api:** manual updates ([175a417](https://github.com/ZoriHQ/typescript-api-sdk/commit/175a41746a5a0f6d2bbc5b131fb87c6e150ea8e0))
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
### Chores
|
|
21
|
+
|
|
22
|
+
* **internal:** use npm pack for build uploads ([78f373a](https://github.com/ZoriHQ/typescript-api-sdk/commit/78f373a8e9d8193148c52c1d45a88f752478509a))
|
|
23
|
+
|
|
3
24
|
## 0.1.0 (2025-10-05)
|
|
4
25
|
|
|
5
26
|
Full Changelog: [v0.0.3...v0.1.0](https://github.com/ZoriHQ/typescript-api-sdk/compare/v0.0.3...v0.1.0)
|
package/package.json
CHANGED
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
import { APIResource } from "../../../core/resource.mjs";
|
|
2
|
+
import * as EventsAPI from "./events.mjs";
|
|
3
|
+
import { EventRecentParams, Events } from "./events.mjs";
|
|
4
|
+
import * as VisitorsAPI from "./visitors.mjs";
|
|
5
|
+
import { VisitorByCountryParams, VisitorByDeviceParams, VisitorByOriginParams, VisitorProfileParams, VisitorTimelineParams, VisitorTopParams, Visitors } from "./visitors.mjs";
|
|
6
|
+
export declare class Analytics extends APIResource {
|
|
7
|
+
visitors: VisitorsAPI.Visitors;
|
|
8
|
+
events: EventsAPI.Events;
|
|
9
|
+
}
|
|
10
|
+
export interface CountryDataPoint {
|
|
11
|
+
country_code?: string;
|
|
12
|
+
unique_visitors?: number;
|
|
13
|
+
}
|
|
14
|
+
export interface EventsOverTimeDataPoint {
|
|
15
|
+
event_count?: number;
|
|
16
|
+
timestamp?: string;
|
|
17
|
+
}
|
|
18
|
+
export interface OriginDataPoint {
|
|
19
|
+
origin?: string;
|
|
20
|
+
unique_visitors?: number;
|
|
21
|
+
}
|
|
22
|
+
export interface RecentEvent {
|
|
23
|
+
browser_name?: string;
|
|
24
|
+
client_timestamp_utc?: string;
|
|
25
|
+
device_type?: string;
|
|
26
|
+
event_name?: string;
|
|
27
|
+
location_city?: string;
|
|
28
|
+
location_country_iso?: string;
|
|
29
|
+
page_path?: string;
|
|
30
|
+
page_url?: string;
|
|
31
|
+
referrer_url?: string;
|
|
32
|
+
visitor_id?: string;
|
|
33
|
+
}
|
|
34
|
+
export interface RecentEventsResponse {
|
|
35
|
+
events?: Array<RecentEvent>;
|
|
36
|
+
total?: number;
|
|
37
|
+
}
|
|
38
|
+
export interface TopVisitor {
|
|
39
|
+
browser_name?: string;
|
|
40
|
+
device_type?: string;
|
|
41
|
+
event_count?: number;
|
|
42
|
+
first_seen?: string;
|
|
43
|
+
last_seen?: string;
|
|
44
|
+
location_city?: string;
|
|
45
|
+
location_country_iso?: string;
|
|
46
|
+
visitor_id?: string;
|
|
47
|
+
}
|
|
48
|
+
export interface TopVisitorsResponse {
|
|
49
|
+
total?: number;
|
|
50
|
+
visitors?: Array<TopVisitor>;
|
|
51
|
+
}
|
|
52
|
+
export interface UniqueVisitorsDataPoint {
|
|
53
|
+
desktop?: number;
|
|
54
|
+
mobile?: number;
|
|
55
|
+
timestamp?: string;
|
|
56
|
+
}
|
|
57
|
+
export interface UniqueVisitorsTimelineResponse {
|
|
58
|
+
data?: Array<UniqueVisitorsDataPoint>;
|
|
59
|
+
}
|
|
60
|
+
export interface VisitorDataPoint {
|
|
61
|
+
desktop?: number;
|
|
62
|
+
mobile?: number;
|
|
63
|
+
tablet?: number;
|
|
64
|
+
timestamp?: string;
|
|
65
|
+
unknown?: number;
|
|
66
|
+
}
|
|
67
|
+
export interface VisitorEvent {
|
|
68
|
+
browser_name?: string;
|
|
69
|
+
client_timestamp_utc?: string;
|
|
70
|
+
device_type?: string;
|
|
71
|
+
event_name?: string;
|
|
72
|
+
page_path?: string;
|
|
73
|
+
page_url?: string;
|
|
74
|
+
referrer_url?: string;
|
|
75
|
+
}
|
|
76
|
+
export interface VisitorProfileResponse {
|
|
77
|
+
events?: Array<VisitorEvent>;
|
|
78
|
+
events_over_time?: Array<EventsOverTimeDataPoint>;
|
|
79
|
+
first_referrer_url?: string;
|
|
80
|
+
first_seen?: string;
|
|
81
|
+
first_traffic_origin?: string;
|
|
82
|
+
last_seen?: string;
|
|
83
|
+
location_city?: string;
|
|
84
|
+
location_country_iso?: string;
|
|
85
|
+
total_events?: number;
|
|
86
|
+
visitor_id?: string;
|
|
87
|
+
}
|
|
88
|
+
export interface VisitorsByCountryResponse {
|
|
89
|
+
data?: Array<CountryDataPoint>;
|
|
90
|
+
}
|
|
91
|
+
export interface VisitorsByDeviceResponse {
|
|
92
|
+
data?: Array<VisitorDataPoint>;
|
|
93
|
+
}
|
|
94
|
+
export interface VisitorsByOriginResponse {
|
|
95
|
+
data?: Array<OriginDataPoint>;
|
|
96
|
+
}
|
|
97
|
+
export declare namespace Analytics {
|
|
98
|
+
export { type CountryDataPoint as CountryDataPoint, type EventsOverTimeDataPoint as EventsOverTimeDataPoint, type OriginDataPoint as OriginDataPoint, type RecentEvent as RecentEvent, type RecentEventsResponse as RecentEventsResponse, type TopVisitor as TopVisitor, type TopVisitorsResponse as TopVisitorsResponse, type UniqueVisitorsDataPoint as UniqueVisitorsDataPoint, type UniqueVisitorsTimelineResponse as UniqueVisitorsTimelineResponse, type VisitorDataPoint as VisitorDataPoint, type VisitorEvent as VisitorEvent, type VisitorProfileResponse as VisitorProfileResponse, type VisitorsByCountryResponse as VisitorsByCountryResponse, type VisitorsByDeviceResponse as VisitorsByDeviceResponse, type VisitorsByOriginResponse as VisitorsByOriginResponse, };
|
|
99
|
+
export { Visitors as Visitors, type VisitorByCountryParams as VisitorByCountryParams, type VisitorByDeviceParams as VisitorByDeviceParams, type VisitorByOriginParams as VisitorByOriginParams, type VisitorProfileParams as VisitorProfileParams, type VisitorTimelineParams as VisitorTimelineParams, type VisitorTopParams as VisitorTopParams, };
|
|
100
|
+
export { Events as Events, type EventRecentParams as EventRecentParams };
|
|
101
|
+
}
|
|
102
|
+
//# sourceMappingURL=analytics.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"analytics.d.mts","sourceRoot":"","sources":["../../../src/resources/v1/analytics/analytics.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,SAAS;OACd,EAAE,iBAAiB,EAAE,MAAM,EAAE;OAC7B,KAAK,WAAW;OAChB,EACL,sBAAsB,EACtB,qBAAqB,EACrB,qBAAqB,EACrB,oBAAoB,EACpB,qBAAqB,EACrB,gBAAgB,EAChB,QAAQ,EACT;AAED,qBAAa,SAAU,SAAQ,WAAW;IACxC,QAAQ,EAAE,WAAW,CAAC,QAAQ,CAA0C;IACxE,MAAM,EAAE,SAAS,CAAC,MAAM,CAAsC;CAC/D;AAED,MAAM,WAAW,gBAAgB;IAC/B,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED,MAAM,WAAW,uBAAuB;IACtC,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,eAAe;IAC9B,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED,MAAM,WAAW,WAAW;IAC1B,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAE9B,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB,aAAa,CAAC,EAAE,MAAM,CAAC;IAEvB,oBAAoB,CAAC,EAAE,MAAM,C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AAmB,EAC/C,KAAK,uBAAuB,IAAI,uBAAuB,EACvD,KAAK,8BAA8B,IAAI,8BAA8B,EACrE,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,YAAY,IAAI,YAAY,EACjC,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,wBAAwB,IAAI,wBAAwB,GAC1D,CAAC;IAEF,OAAO,EACL,QAAQ,IAAI,QAAQ,EACpB,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,oBAAoB,IAAI,oBAAoB,EACjD,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,gBAAgB,IAAI,gBAAgB,GAC1C,CAAC;IAEF,OAAO,EAAE,MAAM,IAAI,MAAM,EAAE,KAAK,iBAAiB,IAAI,iBAAiB,EAAE,CAAC;CAC1E"}
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
import { APIResource } from "../../../core/resource.js";
|
|
2
|
+
import * as EventsAPI from "./events.js";
|
|
3
|
+
import { EventRecentParams, Events } from "./events.js";
|
|
4
|
+
import * as VisitorsAPI from "./visitors.js";
|
|
5
|
+
import { VisitorByCountryParams, VisitorByDeviceParams, VisitorByOriginParams, VisitorProfileParams, VisitorTimelineParams, VisitorTopParams, Visitors } from "./visitors.js";
|
|
6
|
+
export declare class Analytics extends APIResource {
|
|
7
|
+
visitors: VisitorsAPI.Visitors;
|
|
8
|
+
events: EventsAPI.Events;
|
|
9
|
+
}
|
|
10
|
+
export interface CountryDataPoint {
|
|
11
|
+
country_code?: string;
|
|
12
|
+
unique_visitors?: number;
|
|
13
|
+
}
|
|
14
|
+
export interface EventsOverTimeDataPoint {
|
|
15
|
+
event_count?: number;
|
|
16
|
+
timestamp?: string;
|
|
17
|
+
}
|
|
18
|
+
export interface OriginDataPoint {
|
|
19
|
+
origin?: string;
|
|
20
|
+
unique_visitors?: number;
|
|
21
|
+
}
|
|
22
|
+
export interface RecentEvent {
|
|
23
|
+
browser_name?: string;
|
|
24
|
+
client_timestamp_utc?: string;
|
|
25
|
+
device_type?: string;
|
|
26
|
+
event_name?: string;
|
|
27
|
+
location_city?: string;
|
|
28
|
+
location_country_iso?: string;
|
|
29
|
+
page_path?: string;
|
|
30
|
+
page_url?: string;
|
|
31
|
+
referrer_url?: string;
|
|
32
|
+
visitor_id?: string;
|
|
33
|
+
}
|
|
34
|
+
export interface RecentEventsResponse {
|
|
35
|
+
events?: Array<RecentEvent>;
|
|
36
|
+
total?: number;
|
|
37
|
+
}
|
|
38
|
+
export interface TopVisitor {
|
|
39
|
+
browser_name?: string;
|
|
40
|
+
device_type?: string;
|
|
41
|
+
event_count?: number;
|
|
42
|
+
first_seen?: string;
|
|
43
|
+
last_seen?: string;
|
|
44
|
+
location_city?: string;
|
|
45
|
+
location_country_iso?: string;
|
|
46
|
+
visitor_id?: string;
|
|
47
|
+
}
|
|
48
|
+
export interface TopVisitorsResponse {
|
|
49
|
+
total?: number;
|
|
50
|
+
visitors?: Array<TopVisitor>;
|
|
51
|
+
}
|
|
52
|
+
export interface UniqueVisitorsDataPoint {
|
|
53
|
+
desktop?: number;
|
|
54
|
+
mobile?: number;
|
|
55
|
+
timestamp?: string;
|
|
56
|
+
}
|
|
57
|
+
export interface UniqueVisitorsTimelineResponse {
|
|
58
|
+
data?: Array<UniqueVisitorsDataPoint>;
|
|
59
|
+
}
|
|
60
|
+
export interface VisitorDataPoint {
|
|
61
|
+
desktop?: number;
|
|
62
|
+
mobile?: number;
|
|
63
|
+
tablet?: number;
|
|
64
|
+
timestamp?: string;
|
|
65
|
+
unknown?: number;
|
|
66
|
+
}
|
|
67
|
+
export interface VisitorEvent {
|
|
68
|
+
browser_name?: string;
|
|
69
|
+
client_timestamp_utc?: string;
|
|
70
|
+
device_type?: string;
|
|
71
|
+
event_name?: string;
|
|
72
|
+
page_path?: string;
|
|
73
|
+
page_url?: string;
|
|
74
|
+
referrer_url?: string;
|
|
75
|
+
}
|
|
76
|
+
export interface VisitorProfileResponse {
|
|
77
|
+
events?: Array<VisitorEvent>;
|
|
78
|
+
events_over_time?: Array<EventsOverTimeDataPoint>;
|
|
79
|
+
first_referrer_url?: string;
|
|
80
|
+
first_seen?: string;
|
|
81
|
+
first_traffic_origin?: string;
|
|
82
|
+
last_seen?: string;
|
|
83
|
+
location_city?: string;
|
|
84
|
+
location_country_iso?: string;
|
|
85
|
+
total_events?: number;
|
|
86
|
+
visitor_id?: string;
|
|
87
|
+
}
|
|
88
|
+
export interface VisitorsByCountryResponse {
|
|
89
|
+
data?: Array<CountryDataPoint>;
|
|
90
|
+
}
|
|
91
|
+
export interface VisitorsByDeviceResponse {
|
|
92
|
+
data?: Array<VisitorDataPoint>;
|
|
93
|
+
}
|
|
94
|
+
export interface VisitorsByOriginResponse {
|
|
95
|
+
data?: Array<OriginDataPoint>;
|
|
96
|
+
}
|
|
97
|
+
export declare namespace Analytics {
|
|
98
|
+
export { type CountryDataPoint as CountryDataPoint, type EventsOverTimeDataPoint as EventsOverTimeDataPoint, type OriginDataPoint as OriginDataPoint, type RecentEvent as RecentEvent, type RecentEventsResponse as RecentEventsResponse, type TopVisitor as TopVisitor, type TopVisitorsResponse as TopVisitorsResponse, type UniqueVisitorsDataPoint as UniqueVisitorsDataPoint, type UniqueVisitorsTimelineResponse as UniqueVisitorsTimelineResponse, type VisitorDataPoint as VisitorDataPoint, type VisitorEvent as VisitorEvent, type VisitorProfileResponse as VisitorProfileResponse, type VisitorsByCountryResponse as VisitorsByCountryResponse, type VisitorsByDeviceResponse as VisitorsByDeviceResponse, type VisitorsByOriginResponse as VisitorsByOriginResponse, };
|
|
99
|
+
export { Visitors as Visitors, type VisitorByCountryParams as VisitorByCountryParams, type VisitorByDeviceParams as VisitorByDeviceParams, type VisitorByOriginParams as VisitorByOriginParams, type VisitorProfileParams as VisitorProfileParams, type VisitorTimelineParams as VisitorTimelineParams, type VisitorTopParams as VisitorTopParams, };
|
|
100
|
+
export { Events as Events, type EventRecentParams as EventRecentParams };
|
|
101
|
+
}
|
|
102
|
+
//# sourceMappingURL=analytics.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"analytics.d.ts","sourceRoot":"","sources":["../../../src/resources/v1/analytics/analytics.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,SAAS;OACd,EAAE,iBAAiB,EAAE,MAAM,EAAE;OAC7B,KAAK,WAAW;OAChB,EACL,sBAAsB,EACtB,qBAAqB,EACrB,qBAAqB,EACrB,oBAAoB,EACpB,qBAAqB,EACrB,gBAAgB,EAChB,QAAQ,EACT;AAED,qBAAa,SAAU,SAAQ,WAAW;IACxC,QAAQ,EAAE,WAAW,CAAC,QAAQ,CAA0C;IACxE,MAAM,EAAE,SAAS,CAAC,MAAM,CAAsC;CAC/D;AAED,MAAM,WAAW,gBAAgB;IAC/B,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED,MAAM,WAAW,uBAAuB;IACtC,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,eAAe;IAC9B,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED,MAAM,WAAW,WAAW;IAC1B,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAE9B,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB,aAAa,CAAC,EAAE,MAAM,CAAC;IAEvB,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAE9B,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB,QAAQ,CAA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B,IAAI,8BAA8B,EACrE,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,YAAY,IAAI,YAAY,EACjC,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,wBAAwB,IAAI,wBAAwB,GAC1D,CAAC;IAEF,OAAO,EACL,QAAQ,IAAI,QAAQ,EACpB,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,oBAAoB,IAAI,oBAAoB,EACjD,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,gBAAgB,IAAI,gBAAgB,GAC1C,CAAC;IAEF,OAAO,EAAE,MAAM,IAAI,MAAM,EAAE,KAAK,iBAAiB,IAAI,iBAAiB,EAAE,CAAC;CAC1E"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.Analytics = void 0;
|
|
5
|
+
const tslib_1 = require("../../../internal/tslib.js");
|
|
6
|
+
const resource_1 = require("../../../core/resource.js");
|
|
7
|
+
const EventsAPI = tslib_1.__importStar(require("./events.js"));
|
|
8
|
+
const events_1 = require("./events.js");
|
|
9
|
+
const VisitorsAPI = tslib_1.__importStar(require("./visitors.js"));
|
|
10
|
+
const visitors_1 = require("./visitors.js");
|
|
11
|
+
class Analytics extends resource_1.APIResource {
|
|
12
|
+
constructor() {
|
|
13
|
+
super(...arguments);
|
|
14
|
+
this.visitors = new VisitorsAPI.Visitors(this._client);
|
|
15
|
+
this.events = new EventsAPI.Events(this._client);
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
exports.Analytics = Analytics;
|
|
19
|
+
Analytics.Visitors = visitors_1.Visitors;
|
|
20
|
+
Analytics.Events = events_1.Events;
|
|
21
|
+
//# sourceMappingURL=analytics.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"analytics.js","sourceRoot":"","sources":["../../../src/resources/v1/analytics/analytics.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;AAEtF,wDAAqD;AACrD,+DAAsC;AACtC,wCAAqD;AACrD,mEAA0C;AAC1C,4CAQoB;AAEpB,MAAa,SAAU,SAAQ,sBAAW;IAA1C;;QACE,aAAQ,GAAyB,IAAI,WAAW,CAAC,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QACxE,WAAM,GAAqB,IAAI,SAAS,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAChE,CAAC;CAAA;AAHD,8BAGC;AAkJD,SAAS,CAAC,QAAQ,GAAG,mBAAQ,CAAC;AAC9B,SAAS,CAAC,MAAM,GAAG,eAAM,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import { APIResource } from "../../../core/resource.mjs";
|
|
3
|
+
import * as EventsAPI from "./events.mjs";
|
|
4
|
+
import { Events } from "./events.mjs";
|
|
5
|
+
import * as VisitorsAPI from "./visitors.mjs";
|
|
6
|
+
import { Visitors, } from "./visitors.mjs";
|
|
7
|
+
export class Analytics extends APIResource {
|
|
8
|
+
constructor() {
|
|
9
|
+
super(...arguments);
|
|
10
|
+
this.visitors = new VisitorsAPI.Visitors(this._client);
|
|
11
|
+
this.events = new EventsAPI.Events(this._client);
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
Analytics.Visitors = Visitors;
|
|
15
|
+
Analytics.Events = Events;
|
|
16
|
+
//# sourceMappingURL=analytics.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"analytics.mjs","sourceRoot":"","sources":["../../../src/resources/v1/analytics/analytics.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OACf,KAAK,SAAS;OACd,EAAqB,MAAM,EAAE;OAC7B,KAAK,WAAW;OAChB,EAOL,QAAQ,GACT;AAED,MAAM,OAAO,SAAU,SAAQ,WAAW;IAA1C;;QACE,aAAQ,GAAyB,IAAI,WAAW,CAAC,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QACxE,WAAM,GAAqB,IAAI,SAAS,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAChE,CAAC;CAAA;AAkJD,SAAS,CAAC,QAAQ,GAAG,QAAQ,CAAC;AAC9B,SAAS,CAAC,MAAM,GAAG,MAAM,CAAC"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { APIResource } from "../../../core/resource.mjs";
|
|
2
|
+
import * as AnalyticsAPI from "./analytics.mjs";
|
|
3
|
+
import { APIPromise } from "../../../core/api-promise.mjs";
|
|
4
|
+
import { RequestOptions } from "../../../internal/request-options.mjs";
|
|
5
|
+
export declare class Events extends APIResource {
|
|
6
|
+
/**
|
|
7
|
+
* Get a list of the most recent events (default: 15 events)
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
* ```ts
|
|
11
|
+
* const recentEventsResponse =
|
|
12
|
+
* await client.v1.analytics.events.recent({
|
|
13
|
+
* project_id: 'project_id',
|
|
14
|
+
* });
|
|
15
|
+
* ```
|
|
16
|
+
*/
|
|
17
|
+
recent(query: EventRecentParams, options?: RequestOptions): APIPromise<AnalyticsAPI.RecentEventsResponse>;
|
|
18
|
+
}
|
|
19
|
+
export interface EventRecentParams {
|
|
20
|
+
/**
|
|
21
|
+
* Project ID
|
|
22
|
+
*/
|
|
23
|
+
project_id: string;
|
|
24
|
+
/**
|
|
25
|
+
* Maximum number of events to return (default: 15)
|
|
26
|
+
*/
|
|
27
|
+
limit?: number;
|
|
28
|
+
}
|
|
29
|
+
export declare namespace Events {
|
|
30
|
+
export { type EventRecentParams as EventRecentParams };
|
|
31
|
+
}
|
|
32
|
+
//# sourceMappingURL=events.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"events.d.mts","sourceRoot":"","sources":["../../../src/resources/v1/analytics/events.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,YAAY;OACjB,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAEzB,qBAAa,MAAO,SAAQ,WAAW;IACrC;;;;;;;;;;OAUG;IACH,MAAM,CAAC,KAAK,EAAE,iBAAiB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,YAAY,CAAC,oBAAoB,CAAC;CAG1G;AAED,MAAM,WAAW,iBAAiB;IAChC;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,WAAW,MAAM,CAAC;IAC9B,OAAO,EAAE,KAAK,iBAAiB,IAAI,iBAAiB,EAAE,CAAC;CACxD"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { APIResource } from "../../../core/resource.js";
|
|
2
|
+
import * as AnalyticsAPI from "./analytics.js";
|
|
3
|
+
import { APIPromise } from "../../../core/api-promise.js";
|
|
4
|
+
import { RequestOptions } from "../../../internal/request-options.js";
|
|
5
|
+
export declare class Events extends APIResource {
|
|
6
|
+
/**
|
|
7
|
+
* Get a list of the most recent events (default: 15 events)
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
* ```ts
|
|
11
|
+
* const recentEventsResponse =
|
|
12
|
+
* await client.v1.analytics.events.recent({
|
|
13
|
+
* project_id: 'project_id',
|
|
14
|
+
* });
|
|
15
|
+
* ```
|
|
16
|
+
*/
|
|
17
|
+
recent(query: EventRecentParams, options?: RequestOptions): APIPromise<AnalyticsAPI.RecentEventsResponse>;
|
|
18
|
+
}
|
|
19
|
+
export interface EventRecentParams {
|
|
20
|
+
/**
|
|
21
|
+
* Project ID
|
|
22
|
+
*/
|
|
23
|
+
project_id: string;
|
|
24
|
+
/**
|
|
25
|
+
* Maximum number of events to return (default: 15)
|
|
26
|
+
*/
|
|
27
|
+
limit?: number;
|
|
28
|
+
}
|
|
29
|
+
export declare namespace Events {
|
|
30
|
+
export { type EventRecentParams as EventRecentParams };
|
|
31
|
+
}
|
|
32
|
+
//# sourceMappingURL=events.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"events.d.ts","sourceRoot":"","sources":["../../../src/resources/v1/analytics/events.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,YAAY;OACjB,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAEzB,qBAAa,MAAO,SAAQ,WAAW;IACrC;;;;;;;;;;OAUG;IACH,MAAM,CAAC,KAAK,EAAE,iBAAiB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,YAAY,CAAC,oBAAoB,CAAC;CAG1G;AAED,MAAM,WAAW,iBAAiB;IAChC;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,WAAW,MAAM,CAAC;IAC9B,OAAO,EAAE,KAAK,iBAAiB,IAAI,iBAAiB,EAAE,CAAC;CACxD"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.Events = void 0;
|
|
5
|
+
const resource_1 = require("../../../core/resource.js");
|
|
6
|
+
class Events extends resource_1.APIResource {
|
|
7
|
+
/**
|
|
8
|
+
* Get a list of the most recent events (default: 15 events)
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* ```ts
|
|
12
|
+
* const recentEventsResponse =
|
|
13
|
+
* await client.v1.analytics.events.recent({
|
|
14
|
+
* project_id: 'project_id',
|
|
15
|
+
* });
|
|
16
|
+
* ```
|
|
17
|
+
*/
|
|
18
|
+
recent(query, options) {
|
|
19
|
+
return this._client.get('/api/v1/analytics/events/recent', { query, ...options });
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
exports.Events = Events;
|
|
23
|
+
//# sourceMappingURL=events.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"events.js","sourceRoot":"","sources":["../../../src/resources/v1/analytics/events.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,wDAAqD;AAKrD,MAAa,MAAO,SAAQ,sBAAW;IACrC;;;;;;;;;;OAUG;IACH,MAAM,CAAC,KAAwB,EAAE,OAAwB;QACvD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,iCAAiC,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACpF,CAAC;CACF;AAfD,wBAeC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import { APIResource } from "../../../core/resource.mjs";
|
|
3
|
+
export class Events extends APIResource {
|
|
4
|
+
/**
|
|
5
|
+
* Get a list of the most recent events (default: 15 events)
|
|
6
|
+
*
|
|
7
|
+
* @example
|
|
8
|
+
* ```ts
|
|
9
|
+
* const recentEventsResponse =
|
|
10
|
+
* await client.v1.analytics.events.recent({
|
|
11
|
+
* project_id: 'project_id',
|
|
12
|
+
* });
|
|
13
|
+
* ```
|
|
14
|
+
*/
|
|
15
|
+
recent(query, options) {
|
|
16
|
+
return this._client.get('/api/v1/analytics/events/recent', { query, ...options });
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
//# sourceMappingURL=events.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"events.mjs","sourceRoot":"","sources":["../../../src/resources/v1/analytics/events.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;AAKtB,MAAM,OAAO,MAAO,SAAQ,WAAW;IACrC;;;;;;;;;;OAUG;IACH,MAAM,CAAC,KAAwB,EAAE,OAAwB;QACvD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,iCAAiC,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACpF,CAAC;CACF"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { Analytics, type CountryDataPoint, type EventsOverTimeDataPoint, type OriginDataPoint, type RecentEvent, type RecentEventsResponse, type TopVisitor, type TopVisitorsResponse, type UniqueVisitorsDataPoint, type UniqueVisitorsTimelineResponse, type VisitorDataPoint, type VisitorEvent, type VisitorProfileResponse, type VisitorsByCountryResponse, type VisitorsByDeviceResponse, type VisitorsByOriginResponse, } from "./analytics.mjs";
|
|
2
|
+
export { Events, type EventRecentParams } from "./events.mjs";
|
|
3
|
+
export { Visitors, type VisitorByCountryParams, type VisitorByDeviceParams, type VisitorByOriginParams, type VisitorProfileParams, type VisitorTimelineParams, type VisitorTopParams, } from "./visitors.mjs";
|
|
4
|
+
//# sourceMappingURL=index.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../../src/resources/v1/analytics/index.ts"],"names":[],"mappings":"OAEO,EACL,SAAS,EACT,KAAK,gBAAgB,EACrB,KAAK,uBAAuB,EAC5B,KAAK,eAAe,EACpB,KAAK,WAAW,EAChB,KAAK,oBAAoB,EACzB,KAAK,UAAU,EACf,KAAK,mBAAmB,EACxB,KAAK,uBAAuB,EAC5B,KAAK,8BAA8B,EACnC,KAAK,gBAAgB,EACrB,KAAK,YAAY,EACjB,KAAK,sBAAsB,EAC3B,KAAK,yBAAyB,EAC9B,KAAK,wBAAwB,EAC7B,KAAK,wBAAwB,GAC9B;OACM,EAAE,MAAM,EAAE,KAAK,iBAAiB,EAAE;OAClC,EACL,QAAQ,EACR,KAAK,sBAAsB,EAC3B,KAAK,qBAAqB,EAC1B,KAAK,qBAAqB,EAC1B,KAAK,oBAAoB,EACzB,KAAK,qBAAqB,EAC1B,KAAK,gBAAgB,GACtB"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { Analytics, type CountryDataPoint, type EventsOverTimeDataPoint, type OriginDataPoint, type RecentEvent, type RecentEventsResponse, type TopVisitor, type TopVisitorsResponse, type UniqueVisitorsDataPoint, type UniqueVisitorsTimelineResponse, type VisitorDataPoint, type VisitorEvent, type VisitorProfileResponse, type VisitorsByCountryResponse, type VisitorsByDeviceResponse, type VisitorsByOriginResponse, } from "./analytics.js";
|
|
2
|
+
export { Events, type EventRecentParams } from "./events.js";
|
|
3
|
+
export { Visitors, type VisitorByCountryParams, type VisitorByDeviceParams, type VisitorByOriginParams, type VisitorProfileParams, type VisitorTimelineParams, type VisitorTopParams, } from "./visitors.js";
|
|
4
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/resources/v1/analytics/index.ts"],"names":[],"mappings":"OAEO,EACL,SAAS,EACT,KAAK,gBAAgB,EACrB,KAAK,uBAAuB,EAC5B,KAAK,eAAe,EACpB,KAAK,WAAW,EAChB,KAAK,oBAAoB,EACzB,KAAK,UAAU,EACf,KAAK,mBAAmB,EACxB,KAAK,uBAAuB,EAC5B,KAAK,8BAA8B,EACnC,KAAK,gBAAgB,EACrB,KAAK,YAAY,EACjB,KAAK,sBAAsB,EAC3B,KAAK,yBAAyB,EAC9B,KAAK,wBAAwB,EAC7B,KAAK,wBAAwB,GAC9B;OACM,EAAE,MAAM,EAAE,KAAK,iBAAiB,EAAE;OAClC,EACL,QAAQ,EACR,KAAK,sBAAsB,EAC3B,KAAK,qBAAqB,EAC1B,KAAK,qBAAqB,EAC1B,KAAK,oBAAoB,EACzB,KAAK,qBAAqB,EAC1B,KAAK,gBAAgB,GACtB"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.Visitors = exports.Events = exports.Analytics = void 0;
|
|
5
|
+
var analytics_1 = require("./analytics.js");
|
|
6
|
+
Object.defineProperty(exports, "Analytics", { enumerable: true, get: function () { return analytics_1.Analytics; } });
|
|
7
|
+
var events_1 = require("./events.js");
|
|
8
|
+
Object.defineProperty(exports, "Events", { enumerable: true, get: function () { return events_1.Events; } });
|
|
9
|
+
var visitors_1 = require("./visitors.js");
|
|
10
|
+
Object.defineProperty(exports, "Visitors", { enumerable: true, get: function () { return visitors_1.Visitors; } });
|
|
11
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/resources/v1/analytics/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,4CAiBqB;AAhBnB,sGAAA,SAAS,OAAA;AAiBX,sCAA0D;AAAjD,gGAAA,MAAM,OAAA;AACf,0CAQoB;AAPlB,oGAAA,QAAQ,OAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../../src/resources/v1/analytics/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EACL,SAAS,GAgBV;OACM,EAAE,MAAM,EAA0B;OAClC,EACL,QAAQ,GAOT"}
|
|
@@ -0,0 +1,155 @@
|
|
|
1
|
+
import { APIResource } from "../../../core/resource.mjs";
|
|
2
|
+
import * as AnalyticsAPI from "./analytics.mjs";
|
|
3
|
+
import { APIPromise } from "../../../core/api-promise.mjs";
|
|
4
|
+
import { RequestOptions } from "../../../internal/request-options.mjs";
|
|
5
|
+
export declare class Visitors extends APIResource {
|
|
6
|
+
/**
|
|
7
|
+
* Get unique visitor counts grouped by country code
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
* ```ts
|
|
11
|
+
* const visitorsByCountryResponse =
|
|
12
|
+
* await client.v1.analytics.visitors.byCountry({
|
|
13
|
+
* project_id: 'project_id',
|
|
14
|
+
* time_range: 'last_hour',
|
|
15
|
+
* });
|
|
16
|
+
* ```
|
|
17
|
+
*/
|
|
18
|
+
byCountry(query: VisitorByCountryParams, options?: RequestOptions): APIPromise<AnalyticsAPI.VisitorsByCountryResponse>;
|
|
19
|
+
/**
|
|
20
|
+
* Get visitor counts grouped by device type (mobile, desktop, tablet) over a
|
|
21
|
+
* specified time range
|
|
22
|
+
*
|
|
23
|
+
* @example
|
|
24
|
+
* ```ts
|
|
25
|
+
* const visitorsByDeviceResponse =
|
|
26
|
+
* await client.v1.analytics.visitors.byDevice({
|
|
27
|
+
* project_id: 'project_id',
|
|
28
|
+
* time_range: 'last_hour',
|
|
29
|
+
* });
|
|
30
|
+
* ```
|
|
31
|
+
*/
|
|
32
|
+
byDevice(query: VisitorByDeviceParams, options?: RequestOptions): APIPromise<AnalyticsAPI.VisitorsByDeviceResponse>;
|
|
33
|
+
/**
|
|
34
|
+
* Get unique visitor counts grouped by referrer domain (traffic source)
|
|
35
|
+
*
|
|
36
|
+
* @example
|
|
37
|
+
* ```ts
|
|
38
|
+
* const visitorsByOriginResponse =
|
|
39
|
+
* await client.v1.analytics.visitors.byOrigin({
|
|
40
|
+
* project_id: 'project_id',
|
|
41
|
+
* time_range: 'last_hour',
|
|
42
|
+
* });
|
|
43
|
+
* ```
|
|
44
|
+
*/
|
|
45
|
+
byOrigin(query: VisitorByOriginParams, options?: RequestOptions): APIPromise<AnalyticsAPI.VisitorsByOriginResponse>;
|
|
46
|
+
/**
|
|
47
|
+
* Get detailed information about a specific visitor including their event history
|
|
48
|
+
* and aggregated statistics
|
|
49
|
+
*
|
|
50
|
+
* @example
|
|
51
|
+
* ```ts
|
|
52
|
+
* const visitorProfileResponse =
|
|
53
|
+
* await client.v1.analytics.visitors.profile({
|
|
54
|
+
* project_id: 'project_id',
|
|
55
|
+
* visitor_id: 'visitor_id',
|
|
56
|
+
* });
|
|
57
|
+
* ```
|
|
58
|
+
*/
|
|
59
|
+
profile(query: VisitorProfileParams, options?: RequestOptions): APIPromise<AnalyticsAPI.VisitorProfileResponse>;
|
|
60
|
+
/**
|
|
61
|
+
* Get unique visitor counts over time, split by mobile and desktop devices for
|
|
62
|
+
* chart visualization
|
|
63
|
+
*
|
|
64
|
+
* @example
|
|
65
|
+
* ```ts
|
|
66
|
+
* const uniqueVisitorsTimelineResponse =
|
|
67
|
+
* await client.v1.analytics.visitors.timeline({
|
|
68
|
+
* project_id: 'project_id',
|
|
69
|
+
* time_range: 'last_hour',
|
|
70
|
+
* });
|
|
71
|
+
* ```
|
|
72
|
+
*/
|
|
73
|
+
timeline(query: VisitorTimelineParams, options?: RequestOptions): APIPromise<AnalyticsAPI.UniqueVisitorsTimelineResponse>;
|
|
74
|
+
/**
|
|
75
|
+
* Get a list of the most active visitors ranked by event count
|
|
76
|
+
*
|
|
77
|
+
* @example
|
|
78
|
+
* ```ts
|
|
79
|
+
* const topVisitorsResponse =
|
|
80
|
+
* await client.v1.analytics.visitors.top({
|
|
81
|
+
* project_id: 'project_id',
|
|
82
|
+
* time_range: 'last_hour',
|
|
83
|
+
* });
|
|
84
|
+
* ```
|
|
85
|
+
*/
|
|
86
|
+
top(query: VisitorTopParams, options?: RequestOptions): APIPromise<AnalyticsAPI.TopVisitorsResponse>;
|
|
87
|
+
}
|
|
88
|
+
export interface VisitorByCountryParams {
|
|
89
|
+
/**
|
|
90
|
+
* Project ID
|
|
91
|
+
*/
|
|
92
|
+
project_id: string;
|
|
93
|
+
/**
|
|
94
|
+
* Time range
|
|
95
|
+
*/
|
|
96
|
+
time_range: 'last_hour' | 'today' | 'last_7_days' | 'last_30_days' | 'last_90_days';
|
|
97
|
+
}
|
|
98
|
+
export interface VisitorByDeviceParams {
|
|
99
|
+
/**
|
|
100
|
+
* Project ID
|
|
101
|
+
*/
|
|
102
|
+
project_id: string;
|
|
103
|
+
/**
|
|
104
|
+
* Time range
|
|
105
|
+
*/
|
|
106
|
+
time_range: 'last_hour' | 'today' | 'last_7_days' | 'last_30_days' | 'last_90_days';
|
|
107
|
+
}
|
|
108
|
+
export interface VisitorByOriginParams {
|
|
109
|
+
/**
|
|
110
|
+
* Project ID
|
|
111
|
+
*/
|
|
112
|
+
project_id: string;
|
|
113
|
+
/**
|
|
114
|
+
* Time range
|
|
115
|
+
*/
|
|
116
|
+
time_range: 'last_hour' | 'today' | 'last_7_days' | 'last_30_days' | 'last_90_days';
|
|
117
|
+
}
|
|
118
|
+
export interface VisitorProfileParams {
|
|
119
|
+
/**
|
|
120
|
+
* Project ID
|
|
121
|
+
*/
|
|
122
|
+
project_id: string;
|
|
123
|
+
/**
|
|
124
|
+
* Visitor ID
|
|
125
|
+
*/
|
|
126
|
+
visitor_id: string;
|
|
127
|
+
}
|
|
128
|
+
export interface VisitorTimelineParams {
|
|
129
|
+
/**
|
|
130
|
+
* Project ID
|
|
131
|
+
*/
|
|
132
|
+
project_id: string;
|
|
133
|
+
/**
|
|
134
|
+
* Time range
|
|
135
|
+
*/
|
|
136
|
+
time_range: 'last_hour' | 'today' | 'last_7_days' | 'last_30_days' | 'last_90_days';
|
|
137
|
+
}
|
|
138
|
+
export interface VisitorTopParams {
|
|
139
|
+
/**
|
|
140
|
+
* Project ID
|
|
141
|
+
*/
|
|
142
|
+
project_id: string;
|
|
143
|
+
/**
|
|
144
|
+
* Time range
|
|
145
|
+
*/
|
|
146
|
+
time_range: 'last_hour' | 'today' | 'last_7_days' | 'last_30_days' | 'last_90_days';
|
|
147
|
+
/**
|
|
148
|
+
* Maximum number of visitors to return (default: 50)
|
|
149
|
+
*/
|
|
150
|
+
limit?: number;
|
|
151
|
+
}
|
|
152
|
+
export declare namespace Visitors {
|
|
153
|
+
export { type VisitorByCountryParams as VisitorByCountryParams, type VisitorByDeviceParams as VisitorByDeviceParams, type VisitorByOriginParams as VisitorByOriginParams, type VisitorProfileParams as VisitorProfileParams, type VisitorTimelineParams as VisitorTimelineParams, type VisitorTopParams as VisitorTopParams, };
|
|
154
|
+
}
|
|
155
|
+
//# sourceMappingURL=visitors.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"visitors.d.mts","sourceRoot":"","sources":["../../../src/resources/v1/analytics/visitors.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,YAAY;OACjB,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAEzB,qBAAa,QAAS,SAAQ,WAAW;IACvC;;;;;;;;;;;OAWG;IACH,SAAS,CACP,KAAK,EAAE,sBAAsB,EAC7B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,YAAY,CAAC,yBAAyB,CAAC;IAIrD;;;;;;;;;;;;OAYG;IACH,QAAQ,CACN,KAAK,EAAE,qBAAqB,EAC5B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,YAAY,CAAC,wBAAwB,CAAC;IAIpD;;;;;;;;;;;OAWG;IACH,QAAQ,CACN,KAAK,EAAE,qBAAqB,EAC5B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,YAAY,CAAC,wBAAwB,CAAC;IAIpD;;;;;;;;;;;;OAYG;IACH,OAAO,CACL,KAAK,EAAE,oBAAoB,EAC3B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,YAAY,CAAC,sBAAsB,CAAC;IAIlD;;;;;;;;;;;;OAYG;IACH,QAAQ,CACN,KAAK,EAAE,qBAAqB,EAC5B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,YAAY,CAAC,8BAA8B,CAAC;IAI1D;;;;;;;;;;;OAWG;IACH,GAAG,CAAC,KAAK,EAAE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