@codeserk/forge-api-public-generated 0.0.0-stage → 0.1.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/dist/index.mjs ADDED
@@ -0,0 +1,2012 @@
1
+ //#region src/generated/runtime.ts
2
+ /**
3
+ * Forge API / Public
4
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
+ *
6
+ * The version of the OpenAPI document: 1.0
7
+ *
8
+ *
9
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
10
+ * https://openapi-generator.tech
11
+ * Do not edit the class manually.
12
+ */
13
+ const BASE_PATH = "http://localhost".replace(/\/+$/, "");
14
+ var Configuration = class {
15
+ constructor(configuration = {}) {
16
+ this.configuration = configuration;
17
+ }
18
+ set config(configuration) {
19
+ this.configuration = configuration;
20
+ }
21
+ get basePath() {
22
+ return this.configuration.basePath != null ? this.configuration.basePath : BASE_PATH;
23
+ }
24
+ get fetchApi() {
25
+ return this.configuration.fetchApi;
26
+ }
27
+ get middleware() {
28
+ return this.configuration.middleware || [];
29
+ }
30
+ get queryParamsStringify() {
31
+ return this.configuration.queryParamsStringify || querystring;
32
+ }
33
+ get username() {
34
+ return this.configuration.username;
35
+ }
36
+ get password() {
37
+ return this.configuration.password;
38
+ }
39
+ get apiKey() {
40
+ const apiKey = this.configuration.apiKey;
41
+ if (apiKey) return typeof apiKey === "function" ? apiKey : () => apiKey;
42
+ }
43
+ get accessToken() {
44
+ const accessToken = this.configuration.accessToken;
45
+ if (accessToken) return typeof accessToken === "function" ? accessToken : async () => accessToken;
46
+ }
47
+ get headers() {
48
+ return this.configuration.headers;
49
+ }
50
+ get credentials() {
51
+ return this.configuration.credentials;
52
+ }
53
+ };
54
+ const DefaultConfig = new Configuration();
55
+ /**
56
+ * This is the base class for all generated API classes.
57
+ */
58
+ var BaseAPI = class BaseAPI {
59
+ static {
60
+ this.jsonRegex = /^(:?application\/json|[^;/ \t]+\/[^;/ \t]+[+]json)[ \t]*(:?;.*)?$/i;
61
+ }
62
+ constructor(configuration = DefaultConfig) {
63
+ this.configuration = configuration;
64
+ this.fetchApi = async (url, init) => {
65
+ let fetchParams = {
66
+ url,
67
+ init
68
+ };
69
+ for (const middleware of this.middleware) if (middleware.pre) fetchParams = await middleware.pre({
70
+ fetch: this.fetchApi,
71
+ ...fetchParams
72
+ }) || fetchParams;
73
+ let response = void 0;
74
+ try {
75
+ response = await (this.configuration.fetchApi || fetch)(fetchParams.url, fetchParams.init);
76
+ } catch (e) {
77
+ for (const middleware of this.middleware) if (middleware.onError) response = await middleware.onError({
78
+ fetch: this.fetchApi,
79
+ url: fetchParams.url,
80
+ init: fetchParams.init,
81
+ error: e,
82
+ response: response ? response.clone() : void 0
83
+ }) || response;
84
+ if (response === void 0) if (e instanceof Error) throw new FetchError(e, "The request failed and the interceptors did not return an alternative response");
85
+ else throw e;
86
+ }
87
+ for (const middleware of this.middleware) if (middleware.post) response = await middleware.post({
88
+ fetch: this.fetchApi,
89
+ url: fetchParams.url,
90
+ init: fetchParams.init,
91
+ response: response.clone()
92
+ }) || response;
93
+ return response;
94
+ };
95
+ this.middleware = configuration.middleware;
96
+ }
97
+ withMiddleware(...middlewares) {
98
+ const next = this.clone();
99
+ next.middleware = next.middleware.concat(...middlewares);
100
+ return next;
101
+ }
102
+ withPreMiddleware(...preMiddlewares) {
103
+ const middlewares = preMiddlewares.map((pre) => ({ pre }));
104
+ return this.withMiddleware(...middlewares);
105
+ }
106
+ withPostMiddleware(...postMiddlewares) {
107
+ const middlewares = postMiddlewares.map((post) => ({ post }));
108
+ return this.withMiddleware(...middlewares);
109
+ }
110
+ /**
111
+ * Check if the given MIME is a JSON MIME.
112
+ * JSON MIME examples:
113
+ * application/json
114
+ * application/json; charset=UTF8
115
+ * APPLICATION/JSON
116
+ * application/vnd.company+json
117
+ * @param mime - MIME (Multipurpose Internet Mail Extensions)
118
+ * @return True if the given MIME is JSON, false otherwise.
119
+ */
120
+ isJsonMime(mime) {
121
+ if (!mime) return false;
122
+ return BaseAPI.jsonRegex.test(mime);
123
+ }
124
+ async request(context, initOverrides) {
125
+ const { url, init } = await this.createFetchParams(context, initOverrides);
126
+ const response = await this.fetchApi(url, init);
127
+ if (response && response.status >= 200 && response.status < 300) return response;
128
+ throw new ResponseError(response, "Response returned an error code");
129
+ }
130
+ async createFetchParams(context, initOverrides) {
131
+ let url = this.configuration.basePath + context.path;
132
+ if (context.query !== void 0 && Object.keys(context.query).length !== 0) url += "?" + this.configuration.queryParamsStringify(context.query);
133
+ const headers = Object.assign({}, this.configuration.headers, context.headers);
134
+ Object.keys(headers).forEach((key) => headers[key] === void 0 ? delete headers[key] : {});
135
+ const initOverrideFn = typeof initOverrides === "function" ? initOverrides : async () => initOverrides;
136
+ const initParams = {
137
+ method: context.method,
138
+ headers,
139
+ body: context.body,
140
+ credentials: this.configuration.credentials
141
+ };
142
+ const overriddenInit = {
143
+ ...initParams,
144
+ ...await initOverrideFn({
145
+ init: initParams,
146
+ context
147
+ })
148
+ };
149
+ let body;
150
+ if (isFormData(overriddenInit.body) || overriddenInit.body instanceof URLSearchParams || isBlob(overriddenInit.body)) body = overriddenInit.body;
151
+ else if (this.isJsonMime(headers["Content-Type"])) body = JSON.stringify(overriddenInit.body);
152
+ else body = overriddenInit.body;
153
+ const init = {
154
+ ...overriddenInit,
155
+ body
156
+ };
157
+ return {
158
+ url,
159
+ init
160
+ };
161
+ }
162
+ /**
163
+ * Create a shallow clone of `this` by constructing a new instance
164
+ * and then shallow cloning data members.
165
+ */
166
+ clone() {
167
+ const constructor = this.constructor;
168
+ const next = new constructor(this.configuration);
169
+ next.middleware = this.middleware.slice();
170
+ return next;
171
+ }
172
+ };
173
+ function isBlob(value) {
174
+ return typeof Blob !== "undefined" && value instanceof Blob;
175
+ }
176
+ function isFormData(value) {
177
+ return typeof FormData !== "undefined" && value instanceof FormData;
178
+ }
179
+ var ResponseError = class extends Error {
180
+ constructor(response, msg) {
181
+ super(msg);
182
+ this.response = response;
183
+ this.name = "ResponseError";
184
+ const actualProto = new.target.prototype;
185
+ if (Object.setPrototypeOf) Object.setPrototypeOf(this, actualProto);
186
+ }
187
+ };
188
+ var FetchError = class extends Error {
189
+ constructor(cause, msg) {
190
+ super(msg);
191
+ this.cause = cause;
192
+ this.name = "FetchError";
193
+ const actualProto = new.target.prototype;
194
+ if (Object.setPrototypeOf) Object.setPrototypeOf(this, actualProto);
195
+ }
196
+ };
197
+ var RequiredError = class extends Error {
198
+ constructor(field, msg) {
199
+ super(msg);
200
+ this.field = field;
201
+ this.name = "RequiredError";
202
+ const actualProto = new.target.prototype;
203
+ if (Object.setPrototypeOf) Object.setPrototypeOf(this, actualProto);
204
+ }
205
+ };
206
+ const COLLECTION_FORMATS = {
207
+ csv: ",",
208
+ ssv: " ",
209
+ tsv: " ",
210
+ pipes: "|"
211
+ };
212
+ function querystring(params, prefix = "") {
213
+ return Object.keys(params).map((key) => querystringSingleKey(key, params[key], prefix)).filter((part) => part.length > 0).join("&");
214
+ }
215
+ function querystringSingleKey(key, value, keyPrefix = "") {
216
+ const fullKey = keyPrefix + (keyPrefix.length ? `[${key}]` : key);
217
+ if (value instanceof Array) {
218
+ const multiValue = value.map((singleValue) => encodeURIComponent(String(singleValue))).join(`&${encodeURIComponent(fullKey)}=`);
219
+ return `${encodeURIComponent(fullKey)}=${multiValue}`;
220
+ }
221
+ if (value instanceof Set) return querystringSingleKey(key, Array.from(value), keyPrefix);
222
+ if (value instanceof Date) return `${encodeURIComponent(fullKey)}=${encodeURIComponent(value.toISOString())}`;
223
+ if (value instanceof Object) return querystring(value, fullKey);
224
+ return `${encodeURIComponent(fullKey)}=${encodeURIComponent(String(value))}`;
225
+ }
226
+ function exists(json, key) {
227
+ const value = json[key];
228
+ return value !== null && value !== void 0;
229
+ }
230
+ function mapValues(data, fn) {
231
+ const result = {};
232
+ for (const key of Object.keys(data)) result[key] = fn(data[key]);
233
+ return result;
234
+ }
235
+ function canConsumeForm(consumes) {
236
+ for (const consume of consumes) if ("multipart/form-data" === consume.contentType) return true;
237
+ return false;
238
+ }
239
+ var JSONApiResponse = class {
240
+ constructor(raw, transformer = (jsonValue) => jsonValue) {
241
+ this.raw = raw;
242
+ this.transformer = transformer;
243
+ }
244
+ async value() {
245
+ return this.transformer(await this.raw.json());
246
+ }
247
+ };
248
+ var VoidApiResponse = class {
249
+ constructor(raw) {
250
+ this.raw = raw;
251
+ }
252
+ async value() {}
253
+ };
254
+ var BlobApiResponse = class {
255
+ constructor(raw) {
256
+ this.raw = raw;
257
+ }
258
+ async value() {
259
+ return await this.raw.blob();
260
+ }
261
+ };
262
+ var TextApiResponse = class {
263
+ constructor(raw) {
264
+ this.raw = raw;
265
+ }
266
+ async value() {
267
+ return await this.raw.text();
268
+ }
269
+ };
270
+ //#endregion
271
+ //#region src/generated/models/UploadDebugSymbolsSourceMapRequest.ts
272
+ /**
273
+ * @export
274
+ */
275
+ const UploadDebugSymbolsSourceMapRequestFormatVersionEnum = { NUMBER_1: 1 };
276
+ /**
277
+ * Check if a given object implements the UploadDebugSymbolsSourceMapRequest interface.
278
+ */
279
+ function instanceOfUploadDebugSymbolsSourceMapRequest(value) {
280
+ if (!("formatVersion" in value) || value["formatVersion"] === void 0) return false;
281
+ return true;
282
+ }
283
+ function UploadDebugSymbolsSourceMapRequestFromJSON(json) {
284
+ return UploadDebugSymbolsSourceMapRequestFromJSONTyped(json, false);
285
+ }
286
+ function UploadDebugSymbolsSourceMapRequestFromJSONTyped(json, ignoreDiscriminator) {
287
+ if (json == null) return json;
288
+ return {
289
+ "formatVersion": json["formatVersion"],
290
+ "ignoredSources": json["ignoredSources"] == null ? void 0 : json["ignoredSources"],
291
+ "names": json["names"] == null ? void 0 : json["names"],
292
+ "segments": json["segments"] == null ? void 0 : json["segments"],
293
+ "sources": json["sources"] == null ? void 0 : json["sources"]
294
+ };
295
+ }
296
+ function UploadDebugSymbolsSourceMapRequestToJSON(json) {
297
+ return UploadDebugSymbolsSourceMapRequestToJSONTyped(json, false);
298
+ }
299
+ function UploadDebugSymbolsSourceMapRequestToJSONTyped(value, ignoreDiscriminator = false) {
300
+ if (value == null) return value;
301
+ return {
302
+ "formatVersion": value["formatVersion"],
303
+ "ignoredSources": value["ignoredSources"],
304
+ "names": value["names"],
305
+ "segments": value["segments"],
306
+ "sources": value["sources"]
307
+ };
308
+ }
309
+ //#endregion
310
+ //#region src/generated/models/UploadDebugSymbolsFileRequest.ts
311
+ /**
312
+ * Check if a given object implements the UploadDebugSymbolsFileRequest interface.
313
+ */
314
+ function instanceOfUploadDebugSymbolsFileRequest(value) {
315
+ if (!("name" in value) || value["name"] === void 0) return false;
316
+ if (!("sourceMap" in value) || value["sourceMap"] === void 0) return false;
317
+ return true;
318
+ }
319
+ function UploadDebugSymbolsFileRequestFromJSON(json) {
320
+ return UploadDebugSymbolsFileRequestFromJSONTyped(json, false);
321
+ }
322
+ function UploadDebugSymbolsFileRequestFromJSONTyped(json, ignoreDiscriminator) {
323
+ if (json == null) return json;
324
+ return {
325
+ "name": json["name"],
326
+ "sourceMap": UploadDebugSymbolsSourceMapRequestFromJSON(json["sourceMap"])
327
+ };
328
+ }
329
+ function UploadDebugSymbolsFileRequestToJSON(json) {
330
+ return UploadDebugSymbolsFileRequestToJSONTyped(json, false);
331
+ }
332
+ function UploadDebugSymbolsFileRequestToJSONTyped(value, ignoreDiscriminator = false) {
333
+ if (value == null) return value;
334
+ return {
335
+ "name": value["name"],
336
+ "sourceMap": UploadDebugSymbolsSourceMapRequestToJSON(value["sourceMap"])
337
+ };
338
+ }
339
+ //#endregion
340
+ //#region src/generated/models/UploadDebugSymbolsRequest.ts
341
+ /**
342
+ * @export
343
+ */
344
+ const UploadDebugSymbolsRequestTypeEnum = { Sourcemap: "sourcemap" };
345
+ /**
346
+ * Check if a given object implements the UploadDebugSymbolsRequest interface.
347
+ */
348
+ function instanceOfUploadDebugSymbolsRequest(value) {
349
+ if (!("files" in value) || value["files"] === void 0) return false;
350
+ if (!("type" in value) || value["type"] === void 0) return false;
351
+ if (!("version" in value) || value["version"] === void 0) return false;
352
+ return true;
353
+ }
354
+ function UploadDebugSymbolsRequestFromJSON(json) {
355
+ return UploadDebugSymbolsRequestFromJSONTyped(json, false);
356
+ }
357
+ function UploadDebugSymbolsRequestFromJSONTyped(json, ignoreDiscriminator) {
358
+ if (json == null) return json;
359
+ return {
360
+ "files": json["files"].map(UploadDebugSymbolsFileRequestFromJSON),
361
+ "type": json["type"],
362
+ "version": json["version"]
363
+ };
364
+ }
365
+ function UploadDebugSymbolsRequestToJSON(json) {
366
+ return UploadDebugSymbolsRequestToJSONTyped(json, false);
367
+ }
368
+ function UploadDebugSymbolsRequestToJSONTyped(value, ignoreDiscriminator = false) {
369
+ if (value == null) return value;
370
+ return {
371
+ "files": value["files"].map(UploadDebugSymbolsFileRequestToJSON),
372
+ "type": value["type"],
373
+ "version": value["version"]
374
+ };
375
+ }
376
+ //#endregion
377
+ //#region src/generated/apis/DebugSymbolsApi.ts
378
+ /**
379
+ * Forge API / Public
380
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
381
+ *
382
+ * The version of the OpenAPI document: 1.0
383
+ *
384
+ *
385
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
386
+ * https://openapi-generator.tech
387
+ * Do not edit the class manually.
388
+ */
389
+ /**
390
+ *
391
+ */
392
+ var DebugSymbolsApi = class extends BaseAPI {
393
+ /**
394
+ * Creates request options for uploadDebugSymbols without sending the request
395
+ */
396
+ async uploadDebugSymbolsRequestOpts(requestParameters) {
397
+ const queryParameters = {};
398
+ const headerParameters = {};
399
+ headerParameters["Content-Type"] = "application/json";
400
+ if (this.configuration && this.configuration.apiKey) headerParameters["x-token"] = await this.configuration.apiKey("x-token");
401
+ return {
402
+ path: `/api/v1/debug-symbols`,
403
+ method: "POST",
404
+ headers: headerParameters,
405
+ query: queryParameters,
406
+ body: UploadDebugSymbolsRequestToJSON(requestParameters["uploadDebugSymbolsRequest"])
407
+ };
408
+ }
409
+ /**
410
+ * Stores the source map of every generated file of the build, replacing the files the version had.
411
+ * Upload the debug symbols of a build
412
+ */
413
+ async uploadDebugSymbolsRaw(requestParameters, initOverrides) {
414
+ const requestOptions = await this.uploadDebugSymbolsRequestOpts(requestParameters);
415
+ return new VoidApiResponse(await this.request(requestOptions, initOverrides));
416
+ }
417
+ /**
418
+ * Stores the source map of every generated file of the build, replacing the files the version had.
419
+ * Upload the debug symbols of a build
420
+ */
421
+ async uploadDebugSymbols(requestParameters = {}, initOverrides) {
422
+ await this.uploadDebugSymbolsRaw(requestParameters, initOverrides);
423
+ }
424
+ };
425
+ //#endregion
426
+ //#region src/generated/models/HealthResponse.ts
427
+ /**
428
+ * Check if a given object implements the HealthResponse interface.
429
+ */
430
+ function instanceOfHealthResponse(value) {
431
+ if (!("ok" in value) || value["ok"] === void 0) return false;
432
+ return true;
433
+ }
434
+ function HealthResponseFromJSON(json) {
435
+ return HealthResponseFromJSONTyped(json, false);
436
+ }
437
+ function HealthResponseFromJSONTyped(json, ignoreDiscriminator) {
438
+ if (json == null) return json;
439
+ return { "ok": json["ok"] };
440
+ }
441
+ function HealthResponseToJSON(json) {
442
+ return HealthResponseToJSONTyped(json, false);
443
+ }
444
+ function HealthResponseToJSONTyped(value, ignoreDiscriminator = false) {
445
+ if (value == null) return value;
446
+ return { "ok": value["ok"] };
447
+ }
448
+ //#endregion
449
+ //#region src/generated/apis/HealthApi.ts
450
+ /**
451
+ * Forge API / Public
452
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
453
+ *
454
+ * The version of the OpenAPI document: 1.0
455
+ *
456
+ *
457
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
458
+ * https://openapi-generator.tech
459
+ * Do not edit the class manually.
460
+ */
461
+ /**
462
+ *
463
+ */
464
+ var HealthApi = class extends BaseAPI {
465
+ /**
466
+ * Creates request options for health without sending the request
467
+ */
468
+ async healthRequestOpts() {
469
+ return {
470
+ path: `/health`,
471
+ method: "GET",
472
+ headers: {},
473
+ query: {}
474
+ };
475
+ }
476
+ /**
477
+ * Answers ok while the application is running, for uptime checks.
478
+ * Health endpoint
479
+ */
480
+ async healthRaw(initOverrides) {
481
+ const requestOptions = await this.healthRequestOpts();
482
+ return new JSONApiResponse(await this.request(requestOptions, initOverrides), (jsonValue) => HealthResponseFromJSON(jsonValue));
483
+ }
484
+ /**
485
+ * Answers ok while the application is running, for uptime checks.
486
+ * Health endpoint
487
+ */
488
+ async health(initOverrides) {
489
+ return await (await this.healthRaw(initOverrides)).value();
490
+ }
491
+ };
492
+ //#endregion
493
+ //#region src/generated/models/OrganizationResponse.ts
494
+ /**
495
+ * Check if a given object implements the OrganizationResponse interface.
496
+ */
497
+ function instanceOfOrganizationResponse(value) {
498
+ if (!("createdAt" in value) || value["createdAt"] === void 0) return false;
499
+ if (!("id" in value) || value["id"] === void 0) return false;
500
+ if (!("name" in value) || value["name"] === void 0) return false;
501
+ if (!("updatedAt" in value) || value["updatedAt"] === void 0) return false;
502
+ return true;
503
+ }
504
+ function OrganizationResponseFromJSON(json) {
505
+ return OrganizationResponseFromJSONTyped(json, false);
506
+ }
507
+ function OrganizationResponseFromJSONTyped(json, ignoreDiscriminator) {
508
+ if (json == null) return json;
509
+ return {
510
+ "archivedAt": json["archivedAt"] == null ? void 0 : new Date(json["archivedAt"]),
511
+ "createdAt": new Date(json["createdAt"]),
512
+ "id": json["id"],
513
+ "name": json["name"],
514
+ "updatedAt": new Date(json["updatedAt"])
515
+ };
516
+ }
517
+ function OrganizationResponseToJSON(json) {
518
+ return OrganizationResponseToJSONTyped(json, false);
519
+ }
520
+ function OrganizationResponseToJSONTyped(value, ignoreDiscriminator = false) {
521
+ if (value == null) return value;
522
+ return {
523
+ "archivedAt": value["archivedAt"] == null ? value["archivedAt"] : value["archivedAt"].toISOString(),
524
+ "createdAt": value["createdAt"].toISOString(),
525
+ "id": value["id"],
526
+ "name": value["name"],
527
+ "updatedAt": value["updatedAt"].toISOString()
528
+ };
529
+ }
530
+ //#endregion
531
+ //#region src/generated/apis/OrganizationApi.ts
532
+ /**
533
+ * Forge API / Public
534
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
535
+ *
536
+ * The version of the OpenAPI document: 1.0
537
+ *
538
+ *
539
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
540
+ * https://openapi-generator.tech
541
+ * Do not edit the class manually.
542
+ */
543
+ /**
544
+ *
545
+ */
546
+ var OrganizationApi = class extends BaseAPI {
547
+ /**
548
+ * Creates request options for getOrganizationByID without sending the request
549
+ */
550
+ async getOrganizationByIDRequestOpts(requestParameters) {
551
+ if (requestParameters["id"] == null) throw new RequiredError("id", "Required parameter \"id\" was null or undefined when calling getOrganizationByID().");
552
+ const queryParameters = {};
553
+ const headerParameters = {};
554
+ if (this.configuration && this.configuration.apiKey) headerParameters["x-token"] = await this.configuration.apiKey("x-token");
555
+ let urlPath = `/api/v1/organizations/{id}`;
556
+ urlPath = urlPath.replace("{id}", encodeURIComponent(String(requestParameters["id"])));
557
+ return {
558
+ path: urlPath,
559
+ method: "GET",
560
+ headers: headerParameters,
561
+ query: queryParameters
562
+ };
563
+ }
564
+ /**
565
+ * Returns the organization of the project the client belongs to; any other ID answers 404.
566
+ * Get organization by ID
567
+ */
568
+ async getOrganizationByIDRaw(requestParameters, initOverrides) {
569
+ const requestOptions = await this.getOrganizationByIDRequestOpts(requestParameters);
570
+ return new JSONApiResponse(await this.request(requestOptions, initOverrides), (jsonValue) => OrganizationResponseFromJSON(jsonValue));
571
+ }
572
+ /**
573
+ * Returns the organization of the project the client belongs to; any other ID answers 404.
574
+ * Get organization by ID
575
+ */
576
+ async getOrganizationByID(requestParameters, initOverrides) {
577
+ return await (await this.getOrganizationByIDRaw(requestParameters, initOverrides)).value();
578
+ }
579
+ };
580
+ //#endregion
581
+ //#region src/generated/models/ProjectPublicSettingsResponse.ts
582
+ /**
583
+ * Check if a given object implements the ProjectPublicSettingsResponse interface.
584
+ */
585
+ function instanceOfProjectPublicSettingsResponse(value) {
586
+ if (!("isEnabled" in value) || value["isEnabled"] === void 0) return false;
587
+ return true;
588
+ }
589
+ function ProjectPublicSettingsResponseFromJSON(json) {
590
+ return ProjectPublicSettingsResponseFromJSONTyped(json, false);
591
+ }
592
+ function ProjectPublicSettingsResponseFromJSONTyped(json, ignoreDiscriminator) {
593
+ if (json == null) return json;
594
+ return {
595
+ "isEnabled": json["isEnabled"],
596
+ "token": json["token"] == null ? void 0 : json["token"]
597
+ };
598
+ }
599
+ function ProjectPublicSettingsResponseToJSON(json) {
600
+ return ProjectPublicSettingsResponseToJSONTyped(json, false);
601
+ }
602
+ function ProjectPublicSettingsResponseToJSONTyped(value, ignoreDiscriminator = false) {
603
+ if (value == null) return value;
604
+ return {
605
+ "isEnabled": value["isEnabled"],
606
+ "token": value["token"]
607
+ };
608
+ }
609
+ //#endregion
610
+ //#region src/generated/models/ProjectResponse.ts
611
+ /**
612
+ * Check if a given object implements the ProjectResponse interface.
613
+ */
614
+ function instanceOfProjectResponse(value) {
615
+ if (!("createdAt" in value) || value["createdAt"] === void 0) return false;
616
+ if (!("id" in value) || value["id"] === void 0) return false;
617
+ if (!("name" in value) || value["name"] === void 0) return false;
618
+ if (!("organizationID" in value) || value["organizationID"] === void 0) return false;
619
+ if (!("updatedAt" in value) || value["updatedAt"] === void 0) return false;
620
+ return true;
621
+ }
622
+ function ProjectResponseFromJSON(json) {
623
+ return ProjectResponseFromJSONTyped(json, false);
624
+ }
625
+ function ProjectResponseFromJSONTyped(json, ignoreDiscriminator) {
626
+ if (json == null) return json;
627
+ return {
628
+ "archivedAt": json["archivedAt"] == null ? void 0 : new Date(json["archivedAt"]),
629
+ "createdAt": new Date(json["createdAt"]),
630
+ "id": json["id"],
631
+ "name": json["name"],
632
+ "organizationID": json["organizationID"],
633
+ "publicSettings": json["publicSettings"] == null ? void 0 : ProjectPublicSettingsResponseFromJSON(json["publicSettings"]),
634
+ "updatedAt": new Date(json["updatedAt"])
635
+ };
636
+ }
637
+ function ProjectResponseToJSON(json) {
638
+ return ProjectResponseToJSONTyped(json, false);
639
+ }
640
+ function ProjectResponseToJSONTyped(value, ignoreDiscriminator = false) {
641
+ if (value == null) return value;
642
+ return {
643
+ "archivedAt": value["archivedAt"] == null ? value["archivedAt"] : value["archivedAt"].toISOString(),
644
+ "createdAt": value["createdAt"].toISOString(),
645
+ "id": value["id"],
646
+ "name": value["name"],
647
+ "organizationID": value["organizationID"],
648
+ "publicSettings": ProjectPublicSettingsResponseToJSON(value["publicSettings"]),
649
+ "updatedAt": value["updatedAt"].toISOString()
650
+ };
651
+ }
652
+ //#endregion
653
+ //#region src/generated/apis/ProjectApi.ts
654
+ /**
655
+ * Forge API / Public
656
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
657
+ *
658
+ * The version of the OpenAPI document: 1.0
659
+ *
660
+ *
661
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
662
+ * https://openapi-generator.tech
663
+ * Do not edit the class manually.
664
+ */
665
+ /**
666
+ *
667
+ */
668
+ var ProjectApi = class extends BaseAPI {
669
+ /**
670
+ * Creates request options for getProjectByID without sending the request
671
+ */
672
+ async getProjectByIDRequestOpts(requestParameters) {
673
+ if (requestParameters["id"] == null) throw new RequiredError("id", "Required parameter \"id\" was null or undefined when calling getProjectByID().");
674
+ const queryParameters = {};
675
+ const headerParameters = {};
676
+ if (this.configuration && this.configuration.apiKey) headerParameters["x-token"] = await this.configuration.apiKey("x-token");
677
+ let urlPath = `/api/v1/projects/{id}`;
678
+ urlPath = urlPath.replace("{id}", encodeURIComponent(String(requestParameters["id"])));
679
+ return {
680
+ path: urlPath,
681
+ method: "GET",
682
+ headers: headerParameters,
683
+ query: queryParameters
684
+ };
685
+ }
686
+ /**
687
+ * Returns the project the client belongs to, without client tokens; any other ID answers 404.
688
+ * Get project by ID
689
+ */
690
+ async getProjectByIDRaw(requestParameters, initOverrides) {
691
+ const requestOptions = await this.getProjectByIDRequestOpts(requestParameters);
692
+ return new JSONApiResponse(await this.request(requestOptions, initOverrides), (jsonValue) => ProjectResponseFromJSON(jsonValue));
693
+ }
694
+ /**
695
+ * Returns the project the client belongs to, without client tokens; any other ID answers 404.
696
+ * Get project by ID
697
+ */
698
+ async getProjectByID(requestParameters, initOverrides) {
699
+ return await (await this.getProjectByIDRaw(requestParameters, initOverrides)).value();
700
+ }
701
+ };
702
+ //#endregion
703
+ //#region src/generated/models/GranularityType.ts
704
+ /**
705
+ * Forge API / Public
706
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
707
+ *
708
+ * The version of the OpenAPI document: 1.0
709
+ *
710
+ *
711
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
712
+ * https://openapi-generator.tech
713
+ * Do not edit the class manually.
714
+ */
715
+ /**
716
+ *
717
+ * @export
718
+ */
719
+ const GranularityType = {
720
+ Hourly: "hourly",
721
+ Daily: "daily",
722
+ Monthly: "monthly",
723
+ Yearly: "yearly",
724
+ TotalByHour: "total_by_hour",
725
+ TotalByWeekday: "total_by_weekday",
726
+ Total: "total"
727
+ };
728
+ function instanceOfGranularityType(value) {
729
+ for (const key in GranularityType) if (Object.prototype.hasOwnProperty.call(GranularityType, key)) {
730
+ if (GranularityType[key] === value) return true;
731
+ }
732
+ return false;
733
+ }
734
+ function GranularityTypeFromJSON(json) {
735
+ return GranularityTypeFromJSONTyped(json, false);
736
+ }
737
+ function GranularityTypeFromJSONTyped(json, ignoreDiscriminator) {
738
+ return json;
739
+ }
740
+ function GranularityTypeToJSON(value) {
741
+ return value;
742
+ }
743
+ function GranularityTypeToJSONTyped(value, ignoreDiscriminator) {
744
+ return value;
745
+ }
746
+ //#endregion
747
+ //#region src/generated/models/EventTimeStatsRowResponse.ts
748
+ /**
749
+ * Check if a given object implements the EventTimeStatsRowResponse interface.
750
+ */
751
+ function instanceOfEventTimeStatsRowResponse(value) {
752
+ if (!("count" in value) || value["count"] === void 0) return false;
753
+ if (!("estimatedCount" in value) || value["estimatedCount"] === void 0) return false;
754
+ if (!("key" in value) || value["key"] === void 0) return false;
755
+ if (!("users" in value) || value["users"] === void 0) return false;
756
+ return true;
757
+ }
758
+ function EventTimeStatsRowResponseFromJSON(json) {
759
+ return EventTimeStatsRowResponseFromJSONTyped(json, false);
760
+ }
761
+ function EventTimeStatsRowResponseFromJSONTyped(json, ignoreDiscriminator) {
762
+ if (json == null) return json;
763
+ return {
764
+ "count": json["count"],
765
+ "estimatedCount": json["estimatedCount"],
766
+ "key": new Date(json["key"]),
767
+ "users": json["users"]
768
+ };
769
+ }
770
+ function EventTimeStatsRowResponseToJSON(json) {
771
+ return EventTimeStatsRowResponseToJSONTyped(json, false);
772
+ }
773
+ function EventTimeStatsRowResponseToJSONTyped(value, ignoreDiscriminator = false) {
774
+ if (value == null) return value;
775
+ return {
776
+ "count": value["count"],
777
+ "estimatedCount": value["estimatedCount"],
778
+ "key": value["key"].toISOString(),
779
+ "users": value["users"]
780
+ };
781
+ }
782
+ //#endregion
783
+ //#region src/generated/models/StatsAggregationResponse.ts
784
+ /**
785
+ * Check if a given object implements the StatsAggregationResponse interface.
786
+ */
787
+ function instanceOfStatsAggregationResponse(value) {
788
+ if (!("aggregation" in value) || value["aggregation"] === void 0) return false;
789
+ if (!("keys" in value) || value["keys"] === void 0) return false;
790
+ if (!("values" in value) || value["values"] === void 0) return false;
791
+ return true;
792
+ }
793
+ function StatsAggregationResponseFromJSON(json) {
794
+ return StatsAggregationResponseFromJSONTyped(json, false);
795
+ }
796
+ function StatsAggregationResponseFromJSONTyped(json, ignoreDiscriminator) {
797
+ if (json == null) return json;
798
+ return {
799
+ "aggregation": json["aggregation"],
800
+ "keys": json["keys"],
801
+ "values": json["values"]
802
+ };
803
+ }
804
+ function StatsAggregationResponseToJSON(json) {
805
+ return StatsAggregationResponseToJSONTyped(json, false);
806
+ }
807
+ function StatsAggregationResponseToJSONTyped(value, ignoreDiscriminator = false) {
808
+ if (value == null) return value;
809
+ return {
810
+ "aggregation": value["aggregation"],
811
+ "keys": value["keys"],
812
+ "values": value["values"]
813
+ };
814
+ }
815
+ //#endregion
816
+ //#region src/generated/models/EventTimeStatsAggregationResponse.ts
817
+ /**
818
+ * Check if a given object implements the EventTimeStatsAggregationResponse interface.
819
+ */
820
+ function instanceOfEventTimeStatsAggregationResponse(value) {
821
+ return true;
822
+ }
823
+ function EventTimeStatsAggregationResponseFromJSON(json) {
824
+ return EventTimeStatsAggregationResponseFromJSONTyped(json, false);
825
+ }
826
+ function EventTimeStatsAggregationResponseFromJSONTyped(json, ignoreDiscriminator) {
827
+ if (json == null) return json;
828
+ return {
829
+ "aggregation": json["aggregation"] == null ? void 0 : StatsAggregationResponseFromJSON(json["aggregation"]),
830
+ "current": json["current"] == null ? void 0 : json["current"].map(EventTimeStatsRowResponseFromJSON),
831
+ "previous": json["previous"] == null ? void 0 : json["previous"].map(EventTimeStatsRowResponseFromJSON)
832
+ };
833
+ }
834
+ function EventTimeStatsAggregationResponseToJSON(json) {
835
+ return EventTimeStatsAggregationResponseToJSONTyped(json, false);
836
+ }
837
+ function EventTimeStatsAggregationResponseToJSONTyped(value, ignoreDiscriminator = false) {
838
+ if (value == null) return value;
839
+ return {
840
+ "aggregation": StatsAggregationResponseToJSON(value["aggregation"]),
841
+ "current": value["current"] == null ? void 0 : value["current"].map(EventTimeStatsRowResponseToJSON),
842
+ "previous": value["previous"] == null ? void 0 : value["previous"].map(EventTimeStatsRowResponseToJSON)
843
+ };
844
+ }
845
+ //#endregion
846
+ //#region src/generated/models/EventTimeStatsResponse.ts
847
+ /**
848
+ * Check if a given object implements the EventTimeStatsResponse interface.
849
+ */
850
+ function instanceOfEventTimeStatsResponse(value) {
851
+ return true;
852
+ }
853
+ function EventTimeStatsResponseFromJSON(json) {
854
+ return EventTimeStatsResponseFromJSONTyped(json, false);
855
+ }
856
+ function EventTimeStatsResponseFromJSONTyped(json, ignoreDiscriminator) {
857
+ if (json == null) return json;
858
+ return {
859
+ "aggregations": json["aggregations"] == null ? void 0 : json["aggregations"].map(EventTimeStatsAggregationResponseFromJSON),
860
+ "granularity": json["granularity"] == null ? void 0 : GranularityTypeFromJSON(json["granularity"]),
861
+ "projectID": json["projectID"] == null ? void 0 : json["projectID"]
862
+ };
863
+ }
864
+ function EventTimeStatsResponseToJSON(json) {
865
+ return EventTimeStatsResponseToJSONTyped(json, false);
866
+ }
867
+ function EventTimeStatsResponseToJSONTyped(value, ignoreDiscriminator = false) {
868
+ if (value == null) return value;
869
+ return {
870
+ "aggregations": value["aggregations"] == null ? void 0 : value["aggregations"].map(EventTimeStatsAggregationResponseToJSON),
871
+ "granularity": GranularityTypeToJSON(value["granularity"]),
872
+ "projectID": value["projectID"]
873
+ };
874
+ }
875
+ //#endregion
876
+ //#region src/generated/models/StatsDistributionResponse.ts
877
+ /**
878
+ * Check if a given object implements the StatsDistributionResponse interface.
879
+ */
880
+ function instanceOfStatsDistributionResponse(value) {
881
+ if (!("avg" in value) || value["avg"] === void 0) return false;
882
+ if (!("max" in value) || value["max"] === void 0) return false;
883
+ if (!("min" in value) || value["min"] === void 0) return false;
884
+ if (!("q25" in value) || value["q25"] === void 0) return false;
885
+ if (!("q50" in value) || value["q50"] === void 0) return false;
886
+ if (!("q75" in value) || value["q75"] === void 0) return false;
887
+ if (!("total" in value) || value["total"] === void 0) return false;
888
+ return true;
889
+ }
890
+ function StatsDistributionResponseFromJSON(json) {
891
+ return StatsDistributionResponseFromJSONTyped(json, false);
892
+ }
893
+ function StatsDistributionResponseFromJSONTyped(json, ignoreDiscriminator) {
894
+ if (json == null) return json;
895
+ return {
896
+ "avg": json["avg"],
897
+ "max": json["max"],
898
+ "min": json["min"],
899
+ "q25": json["q25"],
900
+ "q50": json["q50"],
901
+ "q75": json["q75"],
902
+ "total": json["total"]
903
+ };
904
+ }
905
+ function StatsDistributionResponseToJSON(json) {
906
+ return StatsDistributionResponseToJSONTyped(json, false);
907
+ }
908
+ function StatsDistributionResponseToJSONTyped(value, ignoreDiscriminator = false) {
909
+ if (value == null) return value;
910
+ return {
911
+ "avg": value["avg"],
912
+ "max": value["max"],
913
+ "min": value["min"],
914
+ "q25": value["q25"],
915
+ "q50": value["q50"],
916
+ "q75": value["q75"],
917
+ "total": value["total"]
918
+ };
919
+ }
920
+ //#endregion
921
+ //#region src/generated/models/EventTotalStatsValuesResponse.ts
922
+ /**
923
+ * Check if a given object implements the EventTotalStatsValuesResponse interface.
924
+ */
925
+ function instanceOfEventTotalStatsValuesResponse(value) {
926
+ if (!("events" in value) || value["events"] === void 0) return false;
927
+ if (!("users" in value) || value["users"] === void 0) return false;
928
+ return true;
929
+ }
930
+ function EventTotalStatsValuesResponseFromJSON(json) {
931
+ return EventTotalStatsValuesResponseFromJSONTyped(json, false);
932
+ }
933
+ function EventTotalStatsValuesResponseFromJSONTyped(json, ignoreDiscriminator) {
934
+ if (json == null) return json;
935
+ return {
936
+ "events": StatsDistributionResponseFromJSON(json["events"]),
937
+ "users": StatsDistributionResponseFromJSON(json["users"])
938
+ };
939
+ }
940
+ function EventTotalStatsValuesResponseToJSON(json) {
941
+ return EventTotalStatsValuesResponseToJSONTyped(json, false);
942
+ }
943
+ function EventTotalStatsValuesResponseToJSONTyped(value, ignoreDiscriminator = false) {
944
+ if (value == null) return value;
945
+ return {
946
+ "events": StatsDistributionResponseToJSON(value["events"]),
947
+ "users": StatsDistributionResponseToJSON(value["users"])
948
+ };
949
+ }
950
+ //#endregion
951
+ //#region src/generated/models/EventTotalStatsResponse.ts
952
+ /**
953
+ * Check if a given object implements the EventTotalStatsResponse interface.
954
+ */
955
+ function instanceOfEventTotalStatsResponse(value) {
956
+ if (!("current" in value) || value["current"] === void 0) return false;
957
+ if (!("granularity" in value) || value["granularity"] === void 0) return false;
958
+ if (!("projectID" in value) || value["projectID"] === void 0) return false;
959
+ return true;
960
+ }
961
+ function EventTotalStatsResponseFromJSON(json) {
962
+ return EventTotalStatsResponseFromJSONTyped(json, false);
963
+ }
964
+ function EventTotalStatsResponseFromJSONTyped(json, ignoreDiscriminator) {
965
+ if (json == null) return json;
966
+ return {
967
+ "current": EventTotalStatsValuesResponseFromJSON(json["current"]),
968
+ "granularity": GranularityTypeFromJSON(json["granularity"]),
969
+ "previous": json["previous"] == null ? void 0 : EventTotalStatsValuesResponseFromJSON(json["previous"]),
970
+ "projectID": json["projectID"]
971
+ };
972
+ }
973
+ function EventTotalStatsResponseToJSON(json) {
974
+ return EventTotalStatsResponseToJSONTyped(json, false);
975
+ }
976
+ function EventTotalStatsResponseToJSONTyped(value, ignoreDiscriminator = false) {
977
+ if (value == null) return value;
978
+ return {
979
+ "current": EventTotalStatsValuesResponseToJSON(value["current"]),
980
+ "granularity": GranularityTypeToJSON(value["granularity"]),
981
+ "previous": EventTotalStatsValuesResponseToJSON(value["previous"]),
982
+ "projectID": value["projectID"]
983
+ };
984
+ }
985
+ //#endregion
986
+ //#region src/generated/models/EventQueryConditionRequest.ts
987
+ /**
988
+ * @export
989
+ */
990
+ const EventQueryConditionRequestOperationEnum = {
991
+ Eq: "eq",
992
+ Neq: "neq"
993
+ };
994
+ /**
995
+ * Check if a given object implements the EventQueryConditionRequest interface.
996
+ */
997
+ function instanceOfEventQueryConditionRequest(value) {
998
+ if (!("operation" in value) || value["operation"] === void 0) return false;
999
+ if (!("predicate" in value) || value["predicate"] === void 0) return false;
1000
+ if (!("value" in value) || value["value"] === void 0) return false;
1001
+ return true;
1002
+ }
1003
+ function EventQueryConditionRequestFromJSON(json) {
1004
+ return EventQueryConditionRequestFromJSONTyped(json, false);
1005
+ }
1006
+ function EventQueryConditionRequestFromJSONTyped(json, ignoreDiscriminator) {
1007
+ if (json == null) return json;
1008
+ return {
1009
+ "operation": json["operation"],
1010
+ "predicate": json["predicate"],
1011
+ "value": json["value"]
1012
+ };
1013
+ }
1014
+ function EventQueryConditionRequestToJSON(json) {
1015
+ return EventQueryConditionRequestToJSONTyped(json, false);
1016
+ }
1017
+ function EventQueryConditionRequestToJSONTyped(value, ignoreDiscriminator = false) {
1018
+ if (value == null) return value;
1019
+ return {
1020
+ "operation": value["operation"],
1021
+ "predicate": value["predicate"],
1022
+ "value": value["value"]
1023
+ };
1024
+ }
1025
+ //#endregion
1026
+ //#region src/generated/models/EventQueryRequest.ts
1027
+ /**
1028
+ * @export
1029
+ */
1030
+ const EventQueryRequestResultEnum = {
1031
+ NumEvents: "NumEvents",
1032
+ Users: "Users"
1033
+ };
1034
+ /**
1035
+ * Check if a given object implements the EventQueryRequest interface.
1036
+ */
1037
+ function instanceOfEventQueryRequest(value) {
1038
+ if (!("conditions" in value) || value["conditions"] === void 0) return false;
1039
+ if (!("result" in value) || value["result"] === void 0) return false;
1040
+ if (!("type" in value) || value["type"] === void 0) return false;
1041
+ return true;
1042
+ }
1043
+ function EventQueryRequestFromJSON(json) {
1044
+ return EventQueryRequestFromJSONTyped(json, false);
1045
+ }
1046
+ function EventQueryRequestFromJSONTyped(json, ignoreDiscriminator) {
1047
+ if (json == null) return json;
1048
+ return {
1049
+ "conditions": json["conditions"].map(EventQueryConditionRequestFromJSON),
1050
+ "result": json["result"],
1051
+ "type": json["type"]
1052
+ };
1053
+ }
1054
+ function EventQueryRequestToJSON(json) {
1055
+ return EventQueryRequestToJSONTyped(json, false);
1056
+ }
1057
+ function EventQueryRequestToJSONTyped(value, ignoreDiscriminator = false) {
1058
+ if (value == null) return value;
1059
+ return {
1060
+ "conditions": value["conditions"].map(EventQueryConditionRequestToJSON),
1061
+ "result": value["result"],
1062
+ "type": value["type"]
1063
+ };
1064
+ }
1065
+ //#endregion
1066
+ //#region src/generated/models/Period.ts
1067
+ /**
1068
+ * Forge API / Public
1069
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
1070
+ *
1071
+ * The version of the OpenAPI document: 1.0
1072
+ *
1073
+ *
1074
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
1075
+ * https://openapi-generator.tech
1076
+ * Do not edit the class manually.
1077
+ */
1078
+ /**
1079
+ *
1080
+ * @export
1081
+ */
1082
+ const Period = {
1083
+ Realtime: "realtime",
1084
+ Day: "day",
1085
+ _7days: "7days",
1086
+ _14days: "14days",
1087
+ Week: "week",
1088
+ Month: "month",
1089
+ Year: "year",
1090
+ All: "all"
1091
+ };
1092
+ function instanceOfPeriod(value) {
1093
+ for (const key in Period) if (Object.prototype.hasOwnProperty.call(Period, key)) {
1094
+ if (Period[key] === value) return true;
1095
+ }
1096
+ return false;
1097
+ }
1098
+ function PeriodFromJSON(json) {
1099
+ return PeriodFromJSONTyped(json, false);
1100
+ }
1101
+ function PeriodFromJSONTyped(json, ignoreDiscriminator) {
1102
+ return json;
1103
+ }
1104
+ function PeriodToJSON(value) {
1105
+ return value;
1106
+ }
1107
+ function PeriodToJSONTyped(value, ignoreDiscriminator) {
1108
+ return value;
1109
+ }
1110
+ //#endregion
1111
+ //#region src/generated/models/GetEventQueryStatsRequest.ts
1112
+ /**
1113
+ * Check if a given object implements the GetEventQueryStatsRequest interface.
1114
+ */
1115
+ function instanceOfGetEventQueryStatsRequest(value) {
1116
+ if (!("period" in value) || value["period"] === void 0) return false;
1117
+ if (!("projectID" in value) || value["projectID"] === void 0) return false;
1118
+ if (!("query" in value) || value["query"] === void 0) return false;
1119
+ return true;
1120
+ }
1121
+ function GetEventQueryStatsRequestFromJSON(json) {
1122
+ return GetEventQueryStatsRequestFromJSONTyped(json, false);
1123
+ }
1124
+ function GetEventQueryStatsRequestFromJSONTyped(json, ignoreDiscriminator) {
1125
+ if (json == null) return json;
1126
+ return {
1127
+ "period": PeriodFromJSON(json["period"]),
1128
+ "projectID": json["projectID"],
1129
+ "query": EventQueryRequestFromJSON(json["query"])
1130
+ };
1131
+ }
1132
+ function GetEventQueryStatsRequestToJSON(json) {
1133
+ return GetEventQueryStatsRequestToJSONTyped(json, false);
1134
+ }
1135
+ function GetEventQueryStatsRequestToJSONTyped(value, ignoreDiscriminator = false) {
1136
+ if (value == null) return value;
1137
+ return {
1138
+ "period": PeriodToJSON(value["period"]),
1139
+ "projectID": value["projectID"],
1140
+ "query": EventQueryRequestToJSON(value["query"])
1141
+ };
1142
+ }
1143
+ //#endregion
1144
+ //#region src/generated/models/SessionTimeStatsRowResponse.ts
1145
+ /**
1146
+ * Check if a given object implements the SessionTimeStatsRowResponse interface.
1147
+ */
1148
+ function instanceOfSessionTimeStatsRowResponse(value) {
1149
+ if (!("bounceRate" in value) || value["bounceRate"] === void 0) return false;
1150
+ if (!("duration" in value) || value["duration"] === void 0) return false;
1151
+ if (!("events" in value) || value["events"] === void 0) return false;
1152
+ if (!("key" in value) || value["key"] === void 0) return false;
1153
+ if (!("sessions" in value) || value["sessions"] === void 0) return false;
1154
+ if (!("users" in value) || value["users"] === void 0) return false;
1155
+ return true;
1156
+ }
1157
+ function SessionTimeStatsRowResponseFromJSON(json) {
1158
+ return SessionTimeStatsRowResponseFromJSONTyped(json, false);
1159
+ }
1160
+ function SessionTimeStatsRowResponseFromJSONTyped(json, ignoreDiscriminator) {
1161
+ if (json == null) return json;
1162
+ return {
1163
+ "bounceRate": StatsDistributionResponseFromJSON(json["bounceRate"]),
1164
+ "duration": StatsDistributionResponseFromJSON(json["duration"]),
1165
+ "events": StatsDistributionResponseFromJSON(json["events"]),
1166
+ "key": new Date(json["key"]),
1167
+ "sessions": StatsDistributionResponseFromJSON(json["sessions"]),
1168
+ "users": StatsDistributionResponseFromJSON(json["users"])
1169
+ };
1170
+ }
1171
+ function SessionTimeStatsRowResponseToJSON(json) {
1172
+ return SessionTimeStatsRowResponseToJSONTyped(json, false);
1173
+ }
1174
+ function SessionTimeStatsRowResponseToJSONTyped(value, ignoreDiscriminator = false) {
1175
+ if (value == null) return value;
1176
+ return {
1177
+ "bounceRate": StatsDistributionResponseToJSON(value["bounceRate"]),
1178
+ "duration": StatsDistributionResponseToJSON(value["duration"]),
1179
+ "events": StatsDistributionResponseToJSON(value["events"]),
1180
+ "key": value["key"].toISOString(),
1181
+ "sessions": StatsDistributionResponseToJSON(value["sessions"]),
1182
+ "users": StatsDistributionResponseToJSON(value["users"])
1183
+ };
1184
+ }
1185
+ //#endregion
1186
+ //#region src/generated/models/SessionTimeStatsResponse.ts
1187
+ /**
1188
+ * Check if a given object implements the SessionTimeStatsResponse interface.
1189
+ */
1190
+ function instanceOfSessionTimeStatsResponse(value) {
1191
+ if (!("comparison" in value) || value["comparison"] === void 0) return false;
1192
+ if (!("current" in value) || value["current"] === void 0) return false;
1193
+ if (!("granularity" in value) || value["granularity"] === void 0) return false;
1194
+ if (!("projectID" in value) || value["projectID"] === void 0) return false;
1195
+ return true;
1196
+ }
1197
+ function SessionTimeStatsResponseFromJSON(json) {
1198
+ return SessionTimeStatsResponseFromJSONTyped(json, false);
1199
+ }
1200
+ function SessionTimeStatsResponseFromJSONTyped(json, ignoreDiscriminator) {
1201
+ if (json == null) return json;
1202
+ return {
1203
+ "comparison": json["comparison"].map(SessionTimeStatsRowResponseFromJSON),
1204
+ "current": json["current"].map(SessionTimeStatsRowResponseFromJSON),
1205
+ "granularity": GranularityTypeFromJSON(json["granularity"]),
1206
+ "projectID": json["projectID"]
1207
+ };
1208
+ }
1209
+ function SessionTimeStatsResponseToJSON(json) {
1210
+ return SessionTimeStatsResponseToJSONTyped(json, false);
1211
+ }
1212
+ function SessionTimeStatsResponseToJSONTyped(value, ignoreDiscriminator = false) {
1213
+ if (value == null) return value;
1214
+ return {
1215
+ "comparison": value["comparison"].map(SessionTimeStatsRowResponseToJSON),
1216
+ "current": value["current"].map(SessionTimeStatsRowResponseToJSON),
1217
+ "granularity": GranularityTypeToJSON(value["granularity"]),
1218
+ "projectID": value["projectID"]
1219
+ };
1220
+ }
1221
+ //#endregion
1222
+ //#region src/generated/models/SessionTotalStatsValuesResponse.ts
1223
+ /**
1224
+ * Check if a given object implements the SessionTotalStatsValuesResponse interface.
1225
+ */
1226
+ function instanceOfSessionTotalStatsValuesResponse(value) {
1227
+ if (!("bounceRate" in value) || value["bounceRate"] === void 0) return false;
1228
+ if (!("duration" in value) || value["duration"] === void 0) return false;
1229
+ if (!("events" in value) || value["events"] === void 0) return false;
1230
+ if (!("eventsBySession" in value) || value["eventsBySession"] === void 0) return false;
1231
+ if (!("sessions" in value) || value["sessions"] === void 0) return false;
1232
+ if (!("users" in value) || value["users"] === void 0) return false;
1233
+ return true;
1234
+ }
1235
+ function SessionTotalStatsValuesResponseFromJSON(json) {
1236
+ return SessionTotalStatsValuesResponseFromJSONTyped(json, false);
1237
+ }
1238
+ function SessionTotalStatsValuesResponseFromJSONTyped(json, ignoreDiscriminator) {
1239
+ if (json == null) return json;
1240
+ return {
1241
+ "bounceRate": StatsDistributionResponseFromJSON(json["bounceRate"]),
1242
+ "duration": StatsDistributionResponseFromJSON(json["duration"]),
1243
+ "events": StatsDistributionResponseFromJSON(json["events"]),
1244
+ "eventsBySession": StatsDistributionResponseFromJSON(json["eventsBySession"]),
1245
+ "sessions": StatsDistributionResponseFromJSON(json["sessions"]),
1246
+ "users": StatsDistributionResponseFromJSON(json["users"])
1247
+ };
1248
+ }
1249
+ function SessionTotalStatsValuesResponseToJSON(json) {
1250
+ return SessionTotalStatsValuesResponseToJSONTyped(json, false);
1251
+ }
1252
+ function SessionTotalStatsValuesResponseToJSONTyped(value, ignoreDiscriminator = false) {
1253
+ if (value == null) return value;
1254
+ return {
1255
+ "bounceRate": StatsDistributionResponseToJSON(value["bounceRate"]),
1256
+ "duration": StatsDistributionResponseToJSON(value["duration"]),
1257
+ "events": StatsDistributionResponseToJSON(value["events"]),
1258
+ "eventsBySession": StatsDistributionResponseToJSON(value["eventsBySession"]),
1259
+ "sessions": StatsDistributionResponseToJSON(value["sessions"]),
1260
+ "users": StatsDistributionResponseToJSON(value["users"])
1261
+ };
1262
+ }
1263
+ //#endregion
1264
+ //#region src/generated/models/SessionTotalStatsResponse.ts
1265
+ /**
1266
+ * Check if a given object implements the SessionTotalStatsResponse interface.
1267
+ */
1268
+ function instanceOfSessionTotalStatsResponse(value) {
1269
+ if (!("current" in value) || value["current"] === void 0) return false;
1270
+ if (!("granularity" in value) || value["granularity"] === void 0) return false;
1271
+ if (!("projectID" in value) || value["projectID"] === void 0) return false;
1272
+ return true;
1273
+ }
1274
+ function SessionTotalStatsResponseFromJSON(json) {
1275
+ return SessionTotalStatsResponseFromJSONTyped(json, false);
1276
+ }
1277
+ function SessionTotalStatsResponseFromJSONTyped(json, ignoreDiscriminator) {
1278
+ if (json == null) return json;
1279
+ return {
1280
+ "current": SessionTotalStatsValuesResponseFromJSON(json["current"]),
1281
+ "granularity": GranularityTypeFromJSON(json["granularity"]),
1282
+ "previous": json["previous"] == null ? void 0 : SessionTotalStatsValuesResponseFromJSON(json["previous"]),
1283
+ "projectID": json["projectID"]
1284
+ };
1285
+ }
1286
+ function SessionTotalStatsResponseToJSON(json) {
1287
+ return SessionTotalStatsResponseToJSONTyped(json, false);
1288
+ }
1289
+ function SessionTotalStatsResponseToJSONTyped(value, ignoreDiscriminator = false) {
1290
+ if (value == null) return value;
1291
+ return {
1292
+ "current": SessionTotalStatsValuesResponseToJSON(value["current"]),
1293
+ "granularity": GranularityTypeToJSON(value["granularity"]),
1294
+ "previous": SessionTotalStatsValuesResponseToJSON(value["previous"]),
1295
+ "projectID": value["projectID"]
1296
+ };
1297
+ }
1298
+ //#endregion
1299
+ //#region src/generated/models/StatsCardinalityResponse.ts
1300
+ /**
1301
+ * Check if a given object implements the StatsCardinalityResponse interface.
1302
+ */
1303
+ function instanceOfStatsCardinalityResponse(value) {
1304
+ if (!("aggregation" in value) || value["aggregation"] === void 0) return false;
1305
+ if (!("cardinality" in value) || value["cardinality"] === void 0) return false;
1306
+ if (!("keys" in value) || value["keys"] === void 0) return false;
1307
+ return true;
1308
+ }
1309
+ function StatsCardinalityResponseFromJSON(json) {
1310
+ return StatsCardinalityResponseFromJSONTyped(json, false);
1311
+ }
1312
+ function StatsCardinalityResponseFromJSONTyped(json, ignoreDiscriminator) {
1313
+ if (json == null) return json;
1314
+ return {
1315
+ "aggregation": json["aggregation"],
1316
+ "cardinality": json["cardinality"],
1317
+ "keys": json["keys"]
1318
+ };
1319
+ }
1320
+ function StatsCardinalityResponseToJSON(json) {
1321
+ return StatsCardinalityResponseToJSONTyped(json, false);
1322
+ }
1323
+ function StatsCardinalityResponseToJSONTyped(value, ignoreDiscriminator = false) {
1324
+ if (value == null) return value;
1325
+ return {
1326
+ "aggregation": value["aggregation"],
1327
+ "cardinality": value["cardinality"],
1328
+ "keys": value["keys"]
1329
+ };
1330
+ }
1331
+ //#endregion
1332
+ //#region src/generated/models/StatsCardinalitiesResponse.ts
1333
+ /**
1334
+ * Check if a given object implements the StatsCardinalitiesResponse interface.
1335
+ */
1336
+ function instanceOfStatsCardinalitiesResponse(value) {
1337
+ if (!("cardinalities" in value) || value["cardinalities"] === void 0) return false;
1338
+ if (!("projectID" in value) || value["projectID"] === void 0) return false;
1339
+ return true;
1340
+ }
1341
+ function StatsCardinalitiesResponseFromJSON(json) {
1342
+ return StatsCardinalitiesResponseFromJSONTyped(json, false);
1343
+ }
1344
+ function StatsCardinalitiesResponseFromJSONTyped(json, ignoreDiscriminator) {
1345
+ if (json == null) return json;
1346
+ return {
1347
+ "cardinalities": json["cardinalities"].map(StatsCardinalityResponseFromJSON),
1348
+ "projectID": json["projectID"]
1349
+ };
1350
+ }
1351
+ function StatsCardinalitiesResponseToJSON(json) {
1352
+ return StatsCardinalitiesResponseToJSONTyped(json, false);
1353
+ }
1354
+ function StatsCardinalitiesResponseToJSONTyped(value, ignoreDiscriminator = false) {
1355
+ if (value == null) return value;
1356
+ return {
1357
+ "cardinalities": value["cardinalities"].map(StatsCardinalityResponseToJSON),
1358
+ "projectID": value["projectID"]
1359
+ };
1360
+ }
1361
+ //#endregion
1362
+ //#region src/generated/models/StatsEventsGlobalDistributionTypeNameResponse.ts
1363
+ /**
1364
+ * Check if a given object implements the StatsEventsGlobalDistributionTypeNameResponse interface.
1365
+ */
1366
+ function instanceOfStatsEventsGlobalDistributionTypeNameResponse(value) {
1367
+ if (!("name" in value) || value["name"] === void 0) return false;
1368
+ if (!("percentage" in value) || value["percentage"] === void 0) return false;
1369
+ if (!("total" in value) || value["total"] === void 0) return false;
1370
+ return true;
1371
+ }
1372
+ function StatsEventsGlobalDistributionTypeNameResponseFromJSON(json) {
1373
+ return StatsEventsGlobalDistributionTypeNameResponseFromJSONTyped(json, false);
1374
+ }
1375
+ function StatsEventsGlobalDistributionTypeNameResponseFromJSONTyped(json, ignoreDiscriminator) {
1376
+ if (json == null) return json;
1377
+ return {
1378
+ "name": json["name"],
1379
+ "percentage": json["percentage"],
1380
+ "total": json["total"]
1381
+ };
1382
+ }
1383
+ function StatsEventsGlobalDistributionTypeNameResponseToJSON(json) {
1384
+ return StatsEventsGlobalDistributionTypeNameResponseToJSONTyped(json, false);
1385
+ }
1386
+ function StatsEventsGlobalDistributionTypeNameResponseToJSONTyped(value, ignoreDiscriminator = false) {
1387
+ if (value == null) return value;
1388
+ return {
1389
+ "name": value["name"],
1390
+ "percentage": value["percentage"],
1391
+ "total": value["total"]
1392
+ };
1393
+ }
1394
+ //#endregion
1395
+ //#region src/generated/models/StatsEventsGlobalDistributionTypeResponse.ts
1396
+ /**
1397
+ * Check if a given object implements the StatsEventsGlobalDistributionTypeResponse interface.
1398
+ */
1399
+ function instanceOfStatsEventsGlobalDistributionTypeResponse(value) {
1400
+ if (!("names" in value) || value["names"] === void 0) return false;
1401
+ if (!("total" in value) || value["total"] === void 0) return false;
1402
+ if (!("type" in value) || value["type"] === void 0) return false;
1403
+ return true;
1404
+ }
1405
+ function StatsEventsGlobalDistributionTypeResponseFromJSON(json) {
1406
+ return StatsEventsGlobalDistributionTypeResponseFromJSONTyped(json, false);
1407
+ }
1408
+ function StatsEventsGlobalDistributionTypeResponseFromJSONTyped(json, ignoreDiscriminator) {
1409
+ if (json == null) return json;
1410
+ return {
1411
+ "names": json["names"].map(StatsEventsGlobalDistributionTypeNameResponseFromJSON),
1412
+ "total": json["total"],
1413
+ "type": json["type"]
1414
+ };
1415
+ }
1416
+ function StatsEventsGlobalDistributionTypeResponseToJSON(json) {
1417
+ return StatsEventsGlobalDistributionTypeResponseToJSONTyped(json, false);
1418
+ }
1419
+ function StatsEventsGlobalDistributionTypeResponseToJSONTyped(value, ignoreDiscriminator = false) {
1420
+ if (value == null) return value;
1421
+ return {
1422
+ "names": value["names"].map(StatsEventsGlobalDistributionTypeNameResponseToJSON),
1423
+ "total": value["total"],
1424
+ "type": value["type"]
1425
+ };
1426
+ }
1427
+ //#endregion
1428
+ //#region src/generated/models/StatsEventsGlobalDistributionResponse.ts
1429
+ /**
1430
+ * Check if a given object implements the StatsEventsGlobalDistributionResponse interface.
1431
+ */
1432
+ function instanceOfStatsEventsGlobalDistributionResponse(value) {
1433
+ if (!("types" in value) || value["types"] === void 0) return false;
1434
+ return true;
1435
+ }
1436
+ function StatsEventsGlobalDistributionResponseFromJSON(json) {
1437
+ return StatsEventsGlobalDistributionResponseFromJSONTyped(json, false);
1438
+ }
1439
+ function StatsEventsGlobalDistributionResponseFromJSONTyped(json, ignoreDiscriminator) {
1440
+ if (json == null) return json;
1441
+ return { "types": json["types"].map(StatsEventsGlobalDistributionTypeResponseFromJSON) };
1442
+ }
1443
+ function StatsEventsGlobalDistributionResponseToJSON(json) {
1444
+ return StatsEventsGlobalDistributionResponseToJSONTyped(json, false);
1445
+ }
1446
+ function StatsEventsGlobalDistributionResponseToJSONTyped(value, ignoreDiscriminator = false) {
1447
+ if (value == null) return value;
1448
+ return { "types": value["types"].map(StatsEventsGlobalDistributionTypeResponseToJSON) };
1449
+ }
1450
+ //#endregion
1451
+ //#region src/generated/models/StatsTopAggregationValuesResponse.ts
1452
+ /**
1453
+ * Check if a given object implements the StatsTopAggregationValuesResponse interface.
1454
+ */
1455
+ function instanceOfStatsTopAggregationValuesResponse(value) {
1456
+ if (!("count" in value) || value["count"] === void 0) return false;
1457
+ if (!("users" in value) || value["users"] === void 0) return false;
1458
+ if (!("values" in value) || value["values"] === void 0) return false;
1459
+ return true;
1460
+ }
1461
+ function StatsTopAggregationValuesResponseFromJSON(json) {
1462
+ return StatsTopAggregationValuesResponseFromJSONTyped(json, false);
1463
+ }
1464
+ function StatsTopAggregationValuesResponseFromJSONTyped(json, ignoreDiscriminator) {
1465
+ if (json == null) return json;
1466
+ return {
1467
+ "count": json["count"],
1468
+ "users": json["users"],
1469
+ "values": json["values"]
1470
+ };
1471
+ }
1472
+ function StatsTopAggregationValuesResponseToJSON(json) {
1473
+ return StatsTopAggregationValuesResponseToJSONTyped(json, false);
1474
+ }
1475
+ function StatsTopAggregationValuesResponseToJSONTyped(value, ignoreDiscriminator = false) {
1476
+ if (value == null) return value;
1477
+ return {
1478
+ "count": value["count"],
1479
+ "users": value["users"],
1480
+ "values": value["values"]
1481
+ };
1482
+ }
1483
+ //#endregion
1484
+ //#region src/generated/models/StatsTopAggregationResponse.ts
1485
+ /**
1486
+ * Check if a given object implements the StatsTopAggregationResponse interface.
1487
+ */
1488
+ function instanceOfStatsTopAggregationResponse(value) {
1489
+ if (!("aggregation" in value) || value["aggregation"] === void 0) return false;
1490
+ if (!("id" in value) || value["id"] === void 0) return false;
1491
+ if (!("keys" in value) || value["keys"] === void 0) return false;
1492
+ if (!("values" in value) || value["values"] === void 0) return false;
1493
+ return true;
1494
+ }
1495
+ function StatsTopAggregationResponseFromJSON(json) {
1496
+ return StatsTopAggregationResponseFromJSONTyped(json, false);
1497
+ }
1498
+ function StatsTopAggregationResponseFromJSONTyped(json, ignoreDiscriminator) {
1499
+ if (json == null) return json;
1500
+ return {
1501
+ "aggregation": json["aggregation"],
1502
+ "id": json["id"],
1503
+ "keys": json["keys"],
1504
+ "values": json["values"].map(StatsTopAggregationValuesResponseFromJSON)
1505
+ };
1506
+ }
1507
+ function StatsTopAggregationResponseToJSON(json) {
1508
+ return StatsTopAggregationResponseToJSONTyped(json, false);
1509
+ }
1510
+ function StatsTopAggregationResponseToJSONTyped(value, ignoreDiscriminator = false) {
1511
+ if (value == null) return value;
1512
+ return {
1513
+ "aggregation": value["aggregation"],
1514
+ "id": value["id"],
1515
+ "keys": value["keys"],
1516
+ "values": value["values"].map(StatsTopAggregationValuesResponseToJSON)
1517
+ };
1518
+ }
1519
+ //#endregion
1520
+ //#region src/generated/models/StatsTopResponse.ts
1521
+ /**
1522
+ * Check if a given object implements the StatsTopResponse interface.
1523
+ */
1524
+ function instanceOfStatsTopResponse(value) {
1525
+ if (!("aggregations" in value) || value["aggregations"] === void 0) return false;
1526
+ if (!("granularity" in value) || value["granularity"] === void 0) return false;
1527
+ if (!("projectID" in value) || value["projectID"] === void 0) return false;
1528
+ return true;
1529
+ }
1530
+ function StatsTopResponseFromJSON(json) {
1531
+ return StatsTopResponseFromJSONTyped(json, false);
1532
+ }
1533
+ function StatsTopResponseFromJSONTyped(json, ignoreDiscriminator) {
1534
+ if (json == null) return json;
1535
+ return {
1536
+ "aggregations": json["aggregations"].map(StatsTopAggregationResponseFromJSON),
1537
+ "granularity": GranularityTypeFromJSON(json["granularity"]),
1538
+ "projectID": json["projectID"]
1539
+ };
1540
+ }
1541
+ function StatsTopResponseToJSON(json) {
1542
+ return StatsTopResponseToJSONTyped(json, false);
1543
+ }
1544
+ function StatsTopResponseToJSONTyped(value, ignoreDiscriminator = false) {
1545
+ if (value == null) return value;
1546
+ return {
1547
+ "aggregations": value["aggregations"].map(StatsTopAggregationResponseToJSON),
1548
+ "granularity": GranularityTypeToJSON(value["granularity"]),
1549
+ "projectID": value["projectID"]
1550
+ };
1551
+ }
1552
+ //#endregion
1553
+ //#region src/generated/apis/StatsApi.ts
1554
+ /**
1555
+ * Forge API / Public
1556
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
1557
+ *
1558
+ * The version of the OpenAPI document: 1.0
1559
+ *
1560
+ *
1561
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
1562
+ * https://openapi-generator.tech
1563
+ * Do not edit the class manually.
1564
+ */
1565
+ /**
1566
+ *
1567
+ */
1568
+ var StatsApi = class extends BaseAPI {
1569
+ /**
1570
+ * Creates request options for getCardinalities without sending the request
1571
+ */
1572
+ async getCardinalitiesRequestOpts(requestParameters) {
1573
+ if (requestParameters["projectID"] == null) throw new RequiredError("projectID", "Required parameter \"projectID\" was null or undefined when calling getCardinalities().");
1574
+ const queryParameters = {};
1575
+ if (requestParameters["projectID"] != null) queryParameters["projectID"] = requestParameters["projectID"];
1576
+ const headerParameters = {};
1577
+ if (this.configuration && this.configuration.apiKey) headerParameters["x-token"] = await this.configuration.apiKey("x-token");
1578
+ return {
1579
+ path: `/api/v1/stats/cardinalities`,
1580
+ method: "GET",
1581
+ headers: headerParameters,
1582
+ query: queryParameters
1583
+ };
1584
+ }
1585
+ /**
1586
+ * Returns how many distinct values each dimension aggregation of the project has.
1587
+ * Get cardinalities
1588
+ */
1589
+ async getCardinalitiesRaw(requestParameters, initOverrides) {
1590
+ const requestOptions = await this.getCardinalitiesRequestOpts(requestParameters);
1591
+ return new JSONApiResponse(await this.request(requestOptions, initOverrides), (jsonValue) => StatsCardinalitiesResponseFromJSON(jsonValue));
1592
+ }
1593
+ /**
1594
+ * Returns how many distinct values each dimension aggregation of the project has.
1595
+ * Get cardinalities
1596
+ */
1597
+ async getCardinalities(requestParameters, initOverrides) {
1598
+ return await (await this.getCardinalitiesRaw(requestParameters, initOverrides)).value();
1599
+ }
1600
+ /**
1601
+ * Creates request options for getEventQueryStats without sending the request
1602
+ */
1603
+ async getEventQueryStatsRequestOpts(requestParameters) {
1604
+ const queryParameters = {};
1605
+ const headerParameters = {};
1606
+ headerParameters["Content-Type"] = "application/json";
1607
+ if (this.configuration && this.configuration.apiKey) headerParameters["x-token"] = await this.configuration.apiKey("x-token");
1608
+ return {
1609
+ path: `/api/v1/stats/event/query`,
1610
+ method: "POST",
1611
+ headers: headerParameters,
1612
+ query: queryParameters,
1613
+ body: GetEventQueryStatsRequestToJSON(requestParameters["getEventQueryStatsRequest"])
1614
+ };
1615
+ }
1616
+ /**
1617
+ * Returns the event counts over time of events matching a query, with the previous period.
1618
+ * Get event query stats
1619
+ */
1620
+ async getEventQueryStatsRaw(requestParameters, initOverrides) {
1621
+ const requestOptions = await this.getEventQueryStatsRequestOpts(requestParameters);
1622
+ return new JSONApiResponse(await this.request(requestOptions, initOverrides), (jsonValue) => EventTimeStatsResponseFromJSON(jsonValue));
1623
+ }
1624
+ /**
1625
+ * Returns the event counts over time of events matching a query, with the previous period.
1626
+ * Get event query stats
1627
+ */
1628
+ async getEventQueryStats(requestParameters = {}, initOverrides) {
1629
+ return await (await this.getEventQueryStatsRaw(requestParameters, initOverrides)).value();
1630
+ }
1631
+ /**
1632
+ * Creates request options for getEventTimeStats without sending the request
1633
+ */
1634
+ async getEventTimeStatsRequestOpts(requestParameters) {
1635
+ if (requestParameters["projectID"] == null) throw new RequiredError("projectID", "Required parameter \"projectID\" was null or undefined when calling getEventTimeStats().");
1636
+ if (requestParameters["period"] == null) throw new RequiredError("period", "Required parameter \"period\" was null or undefined when calling getEventTimeStats().");
1637
+ const queryParameters = {};
1638
+ if (requestParameters["projectID"] != null) queryParameters["projectID"] = requestParameters["projectID"];
1639
+ if (requestParameters["keys"] != null) queryParameters["keys"] = requestParameters["keys"];
1640
+ if (requestParameters["values"] != null) queryParameters["values"] = requestParameters["values"];
1641
+ if (requestParameters["period"] != null) queryParameters["period"] = requestParameters["period"];
1642
+ const headerParameters = {};
1643
+ if (this.configuration && this.configuration.apiKey) headerParameters["x-token"] = await this.configuration.apiKey("x-token");
1644
+ return {
1645
+ path: `/api/v1/stats/event/time`,
1646
+ method: "GET",
1647
+ headers: headerParameters,
1648
+ query: queryParameters
1649
+ };
1650
+ }
1651
+ /**
1652
+ * Returns the event counts of each requested aggregation over time, with the previous period.
1653
+ * Get event time stats
1654
+ */
1655
+ async getEventTimeStatsRaw(requestParameters, initOverrides) {
1656
+ const requestOptions = await this.getEventTimeStatsRequestOpts(requestParameters);
1657
+ return new JSONApiResponse(await this.request(requestOptions, initOverrides), (jsonValue) => EventTimeStatsResponseFromJSON(jsonValue));
1658
+ }
1659
+ /**
1660
+ * Returns the event counts of each requested aggregation over time, with the previous period.
1661
+ * Get event time stats
1662
+ */
1663
+ async getEventTimeStats(requestParameters, initOverrides) {
1664
+ return await (await this.getEventTimeStatsRaw(requestParameters, initOverrides)).value();
1665
+ }
1666
+ /**
1667
+ * Creates request options for getEventTotalStats without sending the request
1668
+ */
1669
+ async getEventTotalStatsRequestOpts(requestParameters) {
1670
+ if (requestParameters["projectID"] == null) throw new RequiredError("projectID", "Required parameter \"projectID\" was null or undefined when calling getEventTotalStats().");
1671
+ if (requestParameters["period"] == null) throw new RequiredError("period", "Required parameter \"period\" was null or undefined when calling getEventTotalStats().");
1672
+ const queryParameters = {};
1673
+ if (requestParameters["projectID"] != null) queryParameters["projectID"] = requestParameters["projectID"];
1674
+ if (requestParameters["period"] != null) queryParameters["period"] = requestParameters["period"];
1675
+ const headerParameters = {};
1676
+ if (this.configuration && this.configuration.apiKey) headerParameters["x-token"] = await this.configuration.apiKey("x-token");
1677
+ return {
1678
+ path: `/api/v1/stats/event/total`,
1679
+ method: "GET",
1680
+ headers: headerParameters,
1681
+ query: queryParameters
1682
+ };
1683
+ }
1684
+ /**
1685
+ * Returns the event and user distributions of the period, with the previous period.
1686
+ * Get event total stats
1687
+ */
1688
+ async getEventTotalStatsRaw(requestParameters, initOverrides) {
1689
+ const requestOptions = await this.getEventTotalStatsRequestOpts(requestParameters);
1690
+ return new JSONApiResponse(await this.request(requestOptions, initOverrides), (jsonValue) => EventTotalStatsResponseFromJSON(jsonValue));
1691
+ }
1692
+ /**
1693
+ * Returns the event and user distributions of the period, with the previous period.
1694
+ * Get event total stats
1695
+ */
1696
+ async getEventTotalStats(requestParameters, initOverrides) {
1697
+ return await (await this.getEventTotalStatsRaw(requestParameters, initOverrides)).value();
1698
+ }
1699
+ /**
1700
+ * Creates request options for getEventsGlobalDistribution without sending the request
1701
+ */
1702
+ async getEventsGlobalDistributionRequestOpts(requestParameters) {
1703
+ if (requestParameters["types"] == null) throw new RequiredError("types", "Required parameter \"types\" was null or undefined when calling getEventsGlobalDistribution().");
1704
+ const queryParameters = {};
1705
+ if (requestParameters["types"] != null) queryParameters["types"] = requestParameters["types"];
1706
+ const headerParameters = {};
1707
+ if (this.configuration && this.configuration.apiKey) headerParameters["x-token"] = await this.configuration.apiKey("x-token");
1708
+ return {
1709
+ path: `/api/v1/stats/event/distribution`,
1710
+ method: "GET",
1711
+ headers: headerParameters,
1712
+ query: queryParameters
1713
+ };
1714
+ }
1715
+ /**
1716
+ * Returns, for each requested event type, how its events split by name across the project.
1717
+ * Get events global distribution
1718
+ */
1719
+ async getEventsGlobalDistributionRaw(requestParameters, initOverrides) {
1720
+ const requestOptions = await this.getEventsGlobalDistributionRequestOpts(requestParameters);
1721
+ return new JSONApiResponse(await this.request(requestOptions, initOverrides), (jsonValue) => StatsEventsGlobalDistributionResponseFromJSON(jsonValue));
1722
+ }
1723
+ /**
1724
+ * Returns, for each requested event type, how its events split by name across the project.
1725
+ * Get events global distribution
1726
+ */
1727
+ async getEventsGlobalDistribution(requestParameters, initOverrides) {
1728
+ return await (await this.getEventsGlobalDistributionRaw(requestParameters, initOverrides)).value();
1729
+ }
1730
+ /**
1731
+ * Creates request options for getSessionTimeStats without sending the request
1732
+ */
1733
+ async getSessionTimeStatsRequestOpts(requestParameters) {
1734
+ if (requestParameters["projectID"] == null) throw new RequiredError("projectID", "Required parameter \"projectID\" was null or undefined when calling getSessionTimeStats().");
1735
+ if (requestParameters["period"] == null) throw new RequiredError("period", "Required parameter \"period\" was null or undefined when calling getSessionTimeStats().");
1736
+ const queryParameters = {};
1737
+ if (requestParameters["projectID"] != null) queryParameters["projectID"] = requestParameters["projectID"];
1738
+ if (requestParameters["period"] != null) queryParameters["period"] = requestParameters["period"];
1739
+ const headerParameters = {};
1740
+ if (this.configuration && this.configuration.apiKey) headerParameters["x-token"] = await this.configuration.apiKey("x-token");
1741
+ return {
1742
+ path: `/api/v1/stats/session/time`,
1743
+ method: "GET",
1744
+ headers: headerParameters,
1745
+ query: queryParameters
1746
+ };
1747
+ }
1748
+ /**
1749
+ * Returns the session stats of each row over time, with the comparison period.
1750
+ * Get sessions time stats
1751
+ */
1752
+ async getSessionTimeStatsRaw(requestParameters, initOverrides) {
1753
+ const requestOptions = await this.getSessionTimeStatsRequestOpts(requestParameters);
1754
+ return new JSONApiResponse(await this.request(requestOptions, initOverrides), (jsonValue) => SessionTimeStatsResponseFromJSON(jsonValue));
1755
+ }
1756
+ /**
1757
+ * Returns the session stats of each row over time, with the comparison period.
1758
+ * Get sessions time stats
1759
+ */
1760
+ async getSessionTimeStats(requestParameters, initOverrides) {
1761
+ return await (await this.getSessionTimeStatsRaw(requestParameters, initOverrides)).value();
1762
+ }
1763
+ /**
1764
+ * Creates request options for getSessionTotalStats without sending the request
1765
+ */
1766
+ async getSessionTotalStatsRequestOpts(requestParameters) {
1767
+ if (requestParameters["projectID"] == null) throw new RequiredError("projectID", "Required parameter \"projectID\" was null or undefined when calling getSessionTotalStats().");
1768
+ if (requestParameters["period"] == null) throw new RequiredError("period", "Required parameter \"period\" was null or undefined when calling getSessionTotalStats().");
1769
+ const queryParameters = {};
1770
+ if (requestParameters["projectID"] != null) queryParameters["projectID"] = requestParameters["projectID"];
1771
+ if (requestParameters["period"] != null) queryParameters["period"] = requestParameters["period"];
1772
+ const headerParameters = {};
1773
+ if (this.configuration && this.configuration.apiKey) headerParameters["x-token"] = await this.configuration.apiKey("x-token");
1774
+ return {
1775
+ path: `/api/v1/stats/session/total`,
1776
+ method: "GET",
1777
+ headers: headerParameters,
1778
+ query: queryParameters
1779
+ };
1780
+ }
1781
+ /**
1782
+ * Returns the session distributions of the period, with the previous period.
1783
+ * Get session total stats
1784
+ */
1785
+ async getSessionTotalStatsRaw(requestParameters, initOverrides) {
1786
+ const requestOptions = await this.getSessionTotalStatsRequestOpts(requestParameters);
1787
+ return new JSONApiResponse(await this.request(requestOptions, initOverrides), (jsonValue) => SessionTotalStatsResponseFromJSON(jsonValue));
1788
+ }
1789
+ /**
1790
+ * Returns the session distributions of the period, with the previous period.
1791
+ * Get session total stats
1792
+ */
1793
+ async getSessionTotalStats(requestParameters, initOverrides) {
1794
+ return await (await this.getSessionTotalStatsRaw(requestParameters, initOverrides)).value();
1795
+ }
1796
+ /**
1797
+ * Creates request options for getTopStats without sending the request
1798
+ */
1799
+ async getTopStatsRequestOpts(requestParameters) {
1800
+ if (requestParameters["projectID"] == null) throw new RequiredError("projectID", "Required parameter \"projectID\" was null or undefined when calling getTopStats().");
1801
+ if (requestParameters["period"] == null) throw new RequiredError("period", "Required parameter \"period\" was null or undefined when calling getTopStats().");
1802
+ const queryParameters = {};
1803
+ if (requestParameters["projectID"] != null) queryParameters["projectID"] = requestParameters["projectID"];
1804
+ if (requestParameters["keys"] != null) queryParameters["keys"] = requestParameters["keys"];
1805
+ if (requestParameters["aggregation"] != null) queryParameters["aggregation"] = requestParameters["aggregation"];
1806
+ if (requestParameters["values"] != null) queryParameters["values"] = requestParameters["values"];
1807
+ if (requestParameters["period"] != null) queryParameters["period"] = requestParameters["period"];
1808
+ const headerParameters = {};
1809
+ if (this.configuration && this.configuration.apiKey) headerParameters["x-token"] = await this.configuration.apiKey("x-token");
1810
+ return {
1811
+ path: `/api/v1/stats/top`,
1812
+ method: "GET",
1813
+ headers: headerParameters,
1814
+ query: queryParameters
1815
+ };
1816
+ }
1817
+ /**
1818
+ * Returns the most frequent values of each requested aggregation within the period.
1819
+ * Get top stats
1820
+ */
1821
+ async getTopStatsRaw(requestParameters, initOverrides) {
1822
+ const requestOptions = await this.getTopStatsRequestOpts(requestParameters);
1823
+ return new JSONApiResponse(await this.request(requestOptions, initOverrides), (jsonValue) => StatsTopResponseFromJSON(jsonValue));
1824
+ }
1825
+ /**
1826
+ * Returns the most frequent values of each requested aggregation within the period.
1827
+ * Get top stats
1828
+ */
1829
+ async getTopStats(requestParameters, initOverrides) {
1830
+ return await (await this.getTopStatsRaw(requestParameters, initOverrides)).value();
1831
+ }
1832
+ };
1833
+ //#endregion
1834
+ //#region src/generated/models/IdentifyUserResponse.ts
1835
+ /**
1836
+ * Check if a given object implements the IdentifyUserResponse interface.
1837
+ */
1838
+ function instanceOfIdentifyUserResponse(value) {
1839
+ if (!("city" in value) || value["city"] === void 0) return false;
1840
+ if (!("country" in value) || value["country"] === void 0) return false;
1841
+ if (!("deviceBrowser" in value) || value["deviceBrowser"] === void 0) return false;
1842
+ if (!("deviceType" in value) || value["deviceType"] === void 0) return false;
1843
+ if (!("lat" in value) || value["lat"] === void 0) return false;
1844
+ if (!("lng" in value) || value["lng"] === void 0) return false;
1845
+ if (!("os" in value) || value["os"] === void 0) return false;
1846
+ if (!("postcode" in value) || value["postcode"] === void 0) return false;
1847
+ if (!("region" in value) || value["region"] === void 0) return false;
1848
+ if (!("timeZone" in value) || value["timeZone"] === void 0) return false;
1849
+ return true;
1850
+ }
1851
+ function IdentifyUserResponseFromJSON(json) {
1852
+ return IdentifyUserResponseFromJSONTyped(json, false);
1853
+ }
1854
+ function IdentifyUserResponseFromJSONTyped(json, ignoreDiscriminator) {
1855
+ if (json == null) return json;
1856
+ return {
1857
+ "city": json["city"],
1858
+ "country": json["country"],
1859
+ "deviceBrowser": json["deviceBrowser"],
1860
+ "deviceType": json["deviceType"],
1861
+ "lat": json["lat"],
1862
+ "lng": json["lng"],
1863
+ "os": json["os"],
1864
+ "postcode": json["postcode"],
1865
+ "region": json["region"],
1866
+ "timeZone": json["timeZone"]
1867
+ };
1868
+ }
1869
+ function IdentifyUserResponseToJSON(json) {
1870
+ return IdentifyUserResponseToJSONTyped(json, false);
1871
+ }
1872
+ function IdentifyUserResponseToJSONTyped(value, ignoreDiscriminator = false) {
1873
+ if (value == null) return value;
1874
+ return {
1875
+ "city": value["city"],
1876
+ "country": value["country"],
1877
+ "deviceBrowser": value["deviceBrowser"],
1878
+ "deviceType": value["deviceType"],
1879
+ "lat": value["lat"],
1880
+ "lng": value["lng"],
1881
+ "os": value["os"],
1882
+ "postcode": value["postcode"],
1883
+ "region": value["region"],
1884
+ "timeZone": value["timeZone"]
1885
+ };
1886
+ }
1887
+ //#endregion
1888
+ //#region src/generated/apis/UserApi.ts
1889
+ /**
1890
+ * Forge API / Public
1891
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
1892
+ *
1893
+ * The version of the OpenAPI document: 1.0
1894
+ *
1895
+ *
1896
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
1897
+ * https://openapi-generator.tech
1898
+ * Do not edit the class manually.
1899
+ */
1900
+ /**
1901
+ *
1902
+ */
1903
+ var UserApi = class extends BaseAPI {
1904
+ /**
1905
+ * Creates request options for identifyUser without sending the request
1906
+ */
1907
+ async identifyUserRequestOpts(requestParameters) {
1908
+ const queryParameters = {};
1909
+ if (requestParameters["userIp"] != null) queryParameters["userIp"] = requestParameters["userIp"];
1910
+ if (requestParameters["userAgent"] != null) queryParameters["userAgent"] = requestParameters["userAgent"];
1911
+ const headerParameters = {};
1912
+ if (this.configuration && this.configuration.apiKey) headerParameters["x-token"] = await this.configuration.apiKey("x-token");
1913
+ return {
1914
+ path: `/api/v1/user/identify`,
1915
+ method: "GET",
1916
+ headers: headerParameters,
1917
+ query: queryParameters
1918
+ };
1919
+ }
1920
+ /**
1921
+ * Returns the location of the IP address and the device of the user agent, those of the request unless given; needs the get-stats permission.
1922
+ * Identify user
1923
+ */
1924
+ async identifyUserRaw(requestParameters, initOverrides) {
1925
+ const requestOptions = await this.identifyUserRequestOpts(requestParameters);
1926
+ return new JSONApiResponse(await this.request(requestOptions, initOverrides), (jsonValue) => IdentifyUserResponseFromJSON(jsonValue));
1927
+ }
1928
+ /**
1929
+ * Returns the location of the IP address and the device of the user agent, those of the request unless given; needs the get-stats permission.
1930
+ * Identify user
1931
+ */
1932
+ async identifyUser(requestParameters = {}, initOverrides) {
1933
+ return await (await this.identifyUserRaw(requestParameters, initOverrides)).value();
1934
+ }
1935
+ };
1936
+ //#endregion
1937
+ //#region src/generated/models/FieldError.ts
1938
+ /**
1939
+ * Check if a given object implements the FieldError interface.
1940
+ */
1941
+ function instanceOfFieldError(value) {
1942
+ if (!("field" in value) || value["field"] === void 0) return false;
1943
+ if (!("message" in value) || value["message"] === void 0) return false;
1944
+ return true;
1945
+ }
1946
+ function FieldErrorFromJSON(json) {
1947
+ return FieldErrorFromJSONTyped(json, false);
1948
+ }
1949
+ function FieldErrorFromJSONTyped(json, ignoreDiscriminator) {
1950
+ if (json == null) return json;
1951
+ return {
1952
+ "field": json["field"],
1953
+ "message": json["message"]
1954
+ };
1955
+ }
1956
+ function FieldErrorToJSON(json) {
1957
+ return FieldErrorToJSONTyped(json, false);
1958
+ }
1959
+ function FieldErrorToJSONTyped(value, ignoreDiscriminator = false) {
1960
+ if (value == null) return value;
1961
+ return {
1962
+ "field": value["field"],
1963
+ "message": value["message"]
1964
+ };
1965
+ }
1966
+ //#endregion
1967
+ //#region src/generated/models/ErrorResponse.ts
1968
+ /**
1969
+ * @export
1970
+ */
1971
+ const ErrorResponseCodeEnum = {
1972
+ Internal001: "INTERNAL_001",
1973
+ Validation: "VALIDATION",
1974
+ BadRequest: "BAD_REQUEST",
1975
+ TooLarge: "TOO_LARGE",
1976
+ Org016: "ORG_016",
1977
+ Prj008: "PRJ_008"
1978
+ };
1979
+ /**
1980
+ * Check if a given object implements the ErrorResponse interface.
1981
+ */
1982
+ function instanceOfErrorResponse(value) {
1983
+ if (!("code" in value) || value["code"] === void 0) return false;
1984
+ if (!("message" in value) || value["message"] === void 0) return false;
1985
+ return true;
1986
+ }
1987
+ function ErrorResponseFromJSON(json) {
1988
+ return ErrorResponseFromJSONTyped(json, false);
1989
+ }
1990
+ function ErrorResponseFromJSONTyped(json, ignoreDiscriminator) {
1991
+ if (json == null) return json;
1992
+ return {
1993
+ "code": json["code"],
1994
+ "fields": json["fields"] == null ? void 0 : json["fields"].map(FieldErrorFromJSON),
1995
+ "message": json["message"]
1996
+ };
1997
+ }
1998
+ function ErrorResponseToJSON(json) {
1999
+ return ErrorResponseToJSONTyped(json, false);
2000
+ }
2001
+ function ErrorResponseToJSONTyped(value, ignoreDiscriminator = false) {
2002
+ if (value == null) return value;
2003
+ return {
2004
+ "code": value["code"],
2005
+ "fields": value["fields"] == null ? void 0 : value["fields"].map(FieldErrorToJSON),
2006
+ "message": value["message"]
2007
+ };
2008
+ }
2009
+ //#endregion
2010
+ export { BASE_PATH, BaseAPI, BlobApiResponse, COLLECTION_FORMATS, Configuration, DebugSymbolsApi, DefaultConfig, ErrorResponseCodeEnum, ErrorResponseFromJSON, ErrorResponseFromJSONTyped, ErrorResponseToJSON, ErrorResponseToJSONTyped, EventQueryConditionRequestFromJSON, EventQueryConditionRequestFromJSONTyped, EventQueryConditionRequestOperationEnum, EventQueryConditionRequestToJSON, EventQueryConditionRequestToJSONTyped, EventQueryRequestFromJSON, EventQueryRequestFromJSONTyped, EventQueryRequestResultEnum, EventQueryRequestToJSON, EventQueryRequestToJSONTyped, EventTimeStatsAggregationResponseFromJSON, EventTimeStatsAggregationResponseFromJSONTyped, EventTimeStatsAggregationResponseToJSON, EventTimeStatsAggregationResponseToJSONTyped, EventTimeStatsResponseFromJSON, EventTimeStatsResponseFromJSONTyped, EventTimeStatsResponseToJSON, EventTimeStatsResponseToJSONTyped, EventTimeStatsRowResponseFromJSON, EventTimeStatsRowResponseFromJSONTyped, EventTimeStatsRowResponseToJSON, EventTimeStatsRowResponseToJSONTyped, EventTotalStatsResponseFromJSON, EventTotalStatsResponseFromJSONTyped, EventTotalStatsResponseToJSON, EventTotalStatsResponseToJSONTyped, EventTotalStatsValuesResponseFromJSON, EventTotalStatsValuesResponseFromJSONTyped, EventTotalStatsValuesResponseToJSON, EventTotalStatsValuesResponseToJSONTyped, FetchError, FieldErrorFromJSON, FieldErrorFromJSONTyped, FieldErrorToJSON, FieldErrorToJSONTyped, GetEventQueryStatsRequestFromJSON, GetEventQueryStatsRequestFromJSONTyped, GetEventQueryStatsRequestToJSON, GetEventQueryStatsRequestToJSONTyped, GranularityType, GranularityTypeFromJSON, GranularityTypeFromJSONTyped, GranularityTypeToJSON, GranularityTypeToJSONTyped, HealthApi, HealthResponseFromJSON, HealthResponseFromJSONTyped, HealthResponseToJSON, HealthResponseToJSONTyped, IdentifyUserResponseFromJSON, IdentifyUserResponseFromJSONTyped, IdentifyUserResponseToJSON, IdentifyUserResponseToJSONTyped, JSONApiResponse, OrganizationApi, OrganizationResponseFromJSON, OrganizationResponseFromJSONTyped, OrganizationResponseToJSON, OrganizationResponseToJSONTyped, Period, PeriodFromJSON, PeriodFromJSONTyped, PeriodToJSON, PeriodToJSONTyped, ProjectApi, ProjectPublicSettingsResponseFromJSON, ProjectPublicSettingsResponseFromJSONTyped, ProjectPublicSettingsResponseToJSON, ProjectPublicSettingsResponseToJSONTyped, ProjectResponseFromJSON, ProjectResponseFromJSONTyped, ProjectResponseToJSON, ProjectResponseToJSONTyped, RequiredError, ResponseError, SessionTimeStatsResponseFromJSON, SessionTimeStatsResponseFromJSONTyped, SessionTimeStatsResponseToJSON, SessionTimeStatsResponseToJSONTyped, SessionTimeStatsRowResponseFromJSON, SessionTimeStatsRowResponseFromJSONTyped, SessionTimeStatsRowResponseToJSON, SessionTimeStatsRowResponseToJSONTyped, SessionTotalStatsResponseFromJSON, SessionTotalStatsResponseFromJSONTyped, SessionTotalStatsResponseToJSON, SessionTotalStatsResponseToJSONTyped, SessionTotalStatsValuesResponseFromJSON, SessionTotalStatsValuesResponseFromJSONTyped, SessionTotalStatsValuesResponseToJSON, SessionTotalStatsValuesResponseToJSONTyped, StatsAggregationResponseFromJSON, StatsAggregationResponseFromJSONTyped, StatsAggregationResponseToJSON, StatsAggregationResponseToJSONTyped, StatsApi, StatsCardinalitiesResponseFromJSON, StatsCardinalitiesResponseFromJSONTyped, StatsCardinalitiesResponseToJSON, StatsCardinalitiesResponseToJSONTyped, StatsCardinalityResponseFromJSON, StatsCardinalityResponseFromJSONTyped, StatsCardinalityResponseToJSON, StatsCardinalityResponseToJSONTyped, StatsDistributionResponseFromJSON, StatsDistributionResponseFromJSONTyped, StatsDistributionResponseToJSON, StatsDistributionResponseToJSONTyped, StatsEventsGlobalDistributionResponseFromJSON, StatsEventsGlobalDistributionResponseFromJSONTyped, StatsEventsGlobalDistributionResponseToJSON, StatsEventsGlobalDistributionResponseToJSONTyped, StatsEventsGlobalDistributionTypeNameResponseFromJSON, StatsEventsGlobalDistributionTypeNameResponseFromJSONTyped, StatsEventsGlobalDistributionTypeNameResponseToJSON, StatsEventsGlobalDistributionTypeNameResponseToJSONTyped, StatsEventsGlobalDistributionTypeResponseFromJSON, StatsEventsGlobalDistributionTypeResponseFromJSONTyped, StatsEventsGlobalDistributionTypeResponseToJSON, StatsEventsGlobalDistributionTypeResponseToJSONTyped, StatsTopAggregationResponseFromJSON, StatsTopAggregationResponseFromJSONTyped, StatsTopAggregationResponseToJSON, StatsTopAggregationResponseToJSONTyped, StatsTopAggregationValuesResponseFromJSON, StatsTopAggregationValuesResponseFromJSONTyped, StatsTopAggregationValuesResponseToJSON, StatsTopAggregationValuesResponseToJSONTyped, StatsTopResponseFromJSON, StatsTopResponseFromJSONTyped, StatsTopResponseToJSON, StatsTopResponseToJSONTyped, TextApiResponse, UploadDebugSymbolsFileRequestFromJSON, UploadDebugSymbolsFileRequestFromJSONTyped, UploadDebugSymbolsFileRequestToJSON, UploadDebugSymbolsFileRequestToJSONTyped, UploadDebugSymbolsRequestFromJSON, UploadDebugSymbolsRequestFromJSONTyped, UploadDebugSymbolsRequestToJSON, UploadDebugSymbolsRequestToJSONTyped, UploadDebugSymbolsRequestTypeEnum, UploadDebugSymbolsSourceMapRequestFormatVersionEnum, UploadDebugSymbolsSourceMapRequestFromJSON, UploadDebugSymbolsSourceMapRequestFromJSONTyped, UploadDebugSymbolsSourceMapRequestToJSON, UploadDebugSymbolsSourceMapRequestToJSONTyped, UserApi, VoidApiResponse, canConsumeForm, exists, instanceOfErrorResponse, instanceOfEventQueryConditionRequest, instanceOfEventQueryRequest, instanceOfEventTimeStatsAggregationResponse, instanceOfEventTimeStatsResponse, instanceOfEventTimeStatsRowResponse, instanceOfEventTotalStatsResponse, instanceOfEventTotalStatsValuesResponse, instanceOfFieldError, instanceOfGetEventQueryStatsRequest, instanceOfGranularityType, instanceOfHealthResponse, instanceOfIdentifyUserResponse, instanceOfOrganizationResponse, instanceOfPeriod, instanceOfProjectPublicSettingsResponse, instanceOfProjectResponse, instanceOfSessionTimeStatsResponse, instanceOfSessionTimeStatsRowResponse, instanceOfSessionTotalStatsResponse, instanceOfSessionTotalStatsValuesResponse, instanceOfStatsAggregationResponse, instanceOfStatsCardinalitiesResponse, instanceOfStatsCardinalityResponse, instanceOfStatsDistributionResponse, instanceOfStatsEventsGlobalDistributionResponse, instanceOfStatsEventsGlobalDistributionTypeNameResponse, instanceOfStatsEventsGlobalDistributionTypeResponse, instanceOfStatsTopAggregationResponse, instanceOfStatsTopAggregationValuesResponse, instanceOfStatsTopResponse, instanceOfUploadDebugSymbolsFileRequest, instanceOfUploadDebugSymbolsRequest, instanceOfUploadDebugSymbolsSourceMapRequest, mapValues, querystring };
2011
+
2012
+ //# sourceMappingURL=index.mjs.map