glitch-javascript-sdk 2.8.2 → 2.8.4
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/cjs/index.js +36 -1
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/api/Titles.d.ts +5 -0
- package/dist/esm/api/Utility.d.ts +7 -0
- package/dist/esm/api/WebsiteAnalytics.d.ts +11 -0
- package/dist/esm/index.js +36 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.ts +23 -0
- package/package.json +1 -1
- package/src/api/Titles.ts +13 -5
- package/src/api/Utility.ts +10 -0
- package/src/api/WebsiteAnalytics.ts +26 -7
- package/src/routes/TitlesRoute.ts +3 -0
- package/src/routes/UtilityRoutes.ts +1 -0
- package/src/routes/WebsiteAnalyticsRoute.ts +9 -5
package/dist/index.d.ts
CHANGED
|
@@ -3291,6 +3291,13 @@ declare class Utility {
|
|
|
3291
3291
|
* @returns promise
|
|
3292
3292
|
*/
|
|
3293
3293
|
static listTypes<T>(params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
3294
|
+
/**
|
|
3295
|
+
* Get all genres that are associated with at least one game title.
|
|
3296
|
+
* Includes the 'titles_count' property.
|
|
3297
|
+
*
|
|
3298
|
+
* @returns promise
|
|
3299
|
+
*/
|
|
3300
|
+
static listActiveGenres<T>(params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
3294
3301
|
}
|
|
3295
3302
|
|
|
3296
3303
|
declare class Tips {
|
|
@@ -4302,6 +4309,11 @@ declare class Titles {
|
|
|
4302
4309
|
* @returns AxiosPromise containing { valid: boolean, user_name: string, license_type: string }
|
|
4303
4310
|
*/
|
|
4304
4311
|
static validateInstall<T>(title_id: string, install_id: string): AxiosPromise<Response<T>>;
|
|
4312
|
+
/**
|
|
4313
|
+
* List all builds/deployments for a specific title.
|
|
4314
|
+
* @param title_id The UUID of the title.
|
|
4315
|
+
*/
|
|
4316
|
+
static listBuilds<T>(title_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
4305
4317
|
}
|
|
4306
4318
|
|
|
4307
4319
|
declare class Campaigns {
|
|
@@ -6970,6 +6982,17 @@ declare class WebsiteAnalytics {
|
|
|
6970
6982
|
* @returns Promise with a unified timeline of the user’s journey, in chronological order.
|
|
6971
6983
|
*/
|
|
6972
6984
|
static userJourney<T>(params: Record<string, any>): AxiosPromise<Response<T>>;
|
|
6985
|
+
/**
|
|
6986
|
+
* Get a detailed marketing report for the game's landing page.
|
|
6987
|
+
* Includes scroll depth, video watch time distribution, and CTA performance.
|
|
6988
|
+
*
|
|
6989
|
+
* @param params
|
|
6990
|
+
* - title_id: string (Required)
|
|
6991
|
+
* - start_date?: string (YYYY-MM-DD)
|
|
6992
|
+
* - end_date?: string (YYYY-MM-DD)
|
|
6993
|
+
* - group_by?: 'country' | 'device'
|
|
6994
|
+
*/
|
|
6995
|
+
static landingPageReport<T>(params: Record<string, any>): AxiosPromise<Response<T>>;
|
|
6973
6996
|
}
|
|
6974
6997
|
|
|
6975
6998
|
declare class ShortLinks {
|
package/package.json
CHANGED
package/src/api/Titles.ts
CHANGED
|
@@ -933,9 +933,9 @@ class Titles {
|
|
|
933
933
|
return Requests.processRoute(TitlesRoute.routes.deleteBehavioralFunnel, {}, { title_id, funnel_id });
|
|
934
934
|
}
|
|
935
935
|
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
936
|
+
/**
|
|
937
|
+
* Generates a presigned S3 URL for uploading a game build ZIP.
|
|
938
|
+
*/
|
|
939
939
|
public static getDeploymentUploadUrl<T>(title_id: string): AxiosPromise<Response<T>> {
|
|
940
940
|
return Requests.processRoute(TitlesRoute.routes.getDeploymentUploadUrl, {}, { title_id });
|
|
941
941
|
}
|
|
@@ -991,11 +991,19 @@ class Titles {
|
|
|
991
991
|
*/
|
|
992
992
|
public static validateInstall<T>(title_id: string, install_id: string): AxiosPromise<Response<T>> {
|
|
993
993
|
return Requests.processRoute(
|
|
994
|
-
TitlesRoute.routes.validateInstall,
|
|
995
|
-
{},
|
|
994
|
+
TitlesRoute.routes.validateInstall,
|
|
995
|
+
{},
|
|
996
996
|
{ title_id: title_id, install_id: install_id }
|
|
997
997
|
);
|
|
998
998
|
}
|
|
999
|
+
|
|
1000
|
+
/**
|
|
1001
|
+
* List all builds/deployments for a specific title.
|
|
1002
|
+
* @param title_id The UUID of the title.
|
|
1003
|
+
*/
|
|
1004
|
+
public static listBuilds<T>(title_id: string, params?: Record<string, any>): AxiosPromise<Response<T>> {
|
|
1005
|
+
return Requests.processRoute(TitlesRoute.routes.listBuilds, {}, { title_id }, params);
|
|
1006
|
+
}
|
|
999
1007
|
}
|
|
1000
1008
|
|
|
1001
1009
|
export default Titles;
|
package/src/api/Utility.ts
CHANGED
|
@@ -71,6 +71,16 @@ class Utility {
|
|
|
71
71
|
return Requests.processRoute(UtilityRoutes.routes.types, undefined, undefined, params);
|
|
72
72
|
}
|
|
73
73
|
|
|
74
|
+
/**
|
|
75
|
+
* Get all genres that are associated with at least one game title.
|
|
76
|
+
* Includes the 'titles_count' property.
|
|
77
|
+
*
|
|
78
|
+
* @returns promise
|
|
79
|
+
*/
|
|
80
|
+
public static listActiveGenres<T>(params?: Record<string, any>) : AxiosPromise<Response<T>> {
|
|
81
|
+
return Requests.processRoute(UtilityRoutes.routes.genres_active, undefined, undefined, params);
|
|
82
|
+
}
|
|
83
|
+
|
|
74
84
|
}
|
|
75
85
|
|
|
76
86
|
export default Utility;
|
|
@@ -319,15 +319,34 @@ class WebsiteAnalytics {
|
|
|
319
319
|
* - end_date?: string Optional. End date (YYYY-MM-DD) if your API supports time limiting
|
|
320
320
|
*
|
|
321
321
|
* @returns Promise with a unified timeline of the user’s journey, in chronological order.
|
|
322
|
-
*/
|
|
323
|
-
public static userJourney<T>(params: Record<string, any>): AxiosPromise<Response<T>> {
|
|
324
|
-
return Requests.processRoute(
|
|
322
|
+
*/
|
|
323
|
+
public static userJourney<T>(params: Record<string, any>): AxiosPromise<Response<T>> {
|
|
324
|
+
return Requests.processRoute(
|
|
325
325
|
WebsiteAnalyticsRoute.routes.journey, // references our new route definition
|
|
326
326
|
{}, // no body data (GET request)
|
|
327
|
-
undefined,
|
|
328
|
-
params
|
|
329
|
-
);
|
|
330
|
-
}
|
|
327
|
+
undefined,
|
|
328
|
+
params
|
|
329
|
+
);
|
|
330
|
+
}
|
|
331
|
+
|
|
332
|
+
/**
|
|
333
|
+
* Get a detailed marketing report for the game's landing page.
|
|
334
|
+
* Includes scroll depth, video watch time distribution, and CTA performance.
|
|
335
|
+
*
|
|
336
|
+
* @param params
|
|
337
|
+
* - title_id: string (Required)
|
|
338
|
+
* - start_date?: string (YYYY-MM-DD)
|
|
339
|
+
* - end_date?: string (YYYY-MM-DD)
|
|
340
|
+
* - group_by?: 'country' | 'device'
|
|
341
|
+
*/
|
|
342
|
+
public static landingPageReport<T>(params: Record<string, any>): AxiosPromise<Response<T>> {
|
|
343
|
+
return Requests.processRoute(
|
|
344
|
+
WebsiteAnalyticsRoute.routes.landingPageReport,
|
|
345
|
+
{},
|
|
346
|
+
undefined,
|
|
347
|
+
params
|
|
348
|
+
);
|
|
349
|
+
}
|
|
331
350
|
}
|
|
332
351
|
|
|
333
352
|
export default WebsiteAnalytics;
|
|
@@ -10,6 +10,7 @@ class UtilityRoutes {
|
|
|
10
10
|
genders: { url: '/util/genders', method: HTTP_METHODS.GET },
|
|
11
11
|
ethnicities : { url: '/util/ethnicities', method: HTTP_METHODS.GET },
|
|
12
12
|
types : { url: '/util/types', method: HTTP_METHODS.GET },
|
|
13
|
+
genres_active: { url: '/util/genres/active', method: HTTP_METHODS.GET },
|
|
13
14
|
};
|
|
14
15
|
|
|
15
16
|
}
|
|
@@ -63,11 +63,15 @@ class WebsiteAnalyticsRoute {
|
|
|
63
63
|
url: '/analytics/utm-performance',
|
|
64
64
|
method: HTTP_METHODS.GET
|
|
65
65
|
},
|
|
66
|
-
journey: {
|
|
67
|
-
url: '/analytics/journey',
|
|
68
|
-
method: HTTP_METHODS.GET
|
|
69
|
-
}
|
|
70
|
-
|
|
66
|
+
journey: {
|
|
67
|
+
url: '/analytics/journey',
|
|
68
|
+
method: HTTP_METHODS.GET
|
|
69
|
+
},
|
|
70
|
+
landingPageReport: {
|
|
71
|
+
url: '/analytics/reports/landing-page',
|
|
72
|
+
method: HTTP_METHODS.GET
|
|
73
|
+
},
|
|
74
|
+
|
|
71
75
|
};
|
|
72
76
|
}
|
|
73
77
|
|