glitch-javascript-sdk 2.0.9 → 2.1.1

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.d.ts CHANGED
@@ -2709,6 +2709,28 @@ declare class Fingerprinting {
2709
2709
  * @returns Promise with geolocation report data
2710
2710
  */
2711
2711
  static geolocationReport<T>(params: Record<string, any>): AxiosPromise<Response<T>>;
2712
+ /**
2713
+ * Get pixel and utem reports
2714
+ *
2715
+ * @param params Report options:
2716
+ * - title_id: string - Required title ID
2717
+ * - start_date?: string - Start date (YYYY-MM-DD)
2718
+ * - end_date?: string - End date (YYYY-MM-DD)
2719
+ * - group_by?: 'country'|'region'|'city' - Grouping level
2720
+ * @returns Promise with geolocation report data
2721
+ */
2722
+ static pixelAttributionReport<T>(params: Record<string, any>): AxiosPromise<Response<T>>;
2723
+ /**
2724
+ * Get an understanding of the path people take to install your game
2725
+ *
2726
+ * @param params Report options:
2727
+ * - title_id: string - Required title ID
2728
+ * - start_date?: string - Start date (YYYY-MM-DD)
2729
+ * - end_date?: string - End date (YYYY-MM-DD)
2730
+ * - group_by?: 'country'|'region'|'city' - Grouping level
2731
+ * @returns Promise with geolocation report data
2732
+ */
2733
+ static installJourneyReport<T>(params: Record<string, any>): AxiosPromise<Response<T>>;
2712
2734
  }
2713
2735
 
2714
2736
  declare class Teams {
@@ -4484,6 +4506,26 @@ declare class Campaigns {
4484
4506
  format: 'csv' | 'xlsx';
4485
4507
  [key: string]: any;
4486
4508
  }): AxiosPromise<Response<T>>;
4509
+ /**
4510
+ * Search IGDB for any game by a query string.
4511
+ * @param campaign_id The UUID of the campaign (for permission checking).
4512
+ * @param params Query parameters including 'search_query' and optional 'limit'.
4513
+ * @returns promise
4514
+ */
4515
+ static sourcingSearchAnyIgdbGame<T>(campaign_id: string, params: {
4516
+ search_query: string;
4517
+ limit?: number;
4518
+ }): AxiosPromise<Response<T>>;
4519
+ /**
4520
+ * Get full game details from a list of IGDB IDs.
4521
+ * @param campaign_id The UUID of the campaign.
4522
+ * @param data An object containing the array of IGDB IDs.
4523
+ * @param data.igdb_ids An array of IGDB game IDs.
4524
+ * @returns promise
4525
+ */
4526
+ static sourcingGetGamesByIds<T>(campaign_id: string, data: {
4527
+ igdb_ids: number[];
4528
+ }): AxiosPromise<Response<T>>;
4487
4529
  }
4488
4530
 
4489
4531
  declare class Subscriptions {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "glitch-javascript-sdk",
3
- "version": "2.0.9",
3
+ "version": "2.1.1",
4
4
  "description": "Javascript SDK for Glitch",
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/esm/index.js",
@@ -916,6 +916,28 @@ class Campaigns {
916
916
  return Requests.processRoute(CampaignsRoute.routes.exportSourcedCreators, undefined, { campaign_id }, params);
917
917
  }
918
918
 
919
+ /**
920
+ * Search IGDB for any game by a query string.
921
+ * @param campaign_id The UUID of the campaign (for permission checking).
922
+ * @param params Query parameters including 'search_query' and optional 'limit'.
923
+ * @returns promise
924
+ */
925
+ public static sourcingSearchAnyIgdbGame<T>(campaign_id: string, params: { search_query: string, limit?: number }): AxiosPromise<Response<T>> {
926
+ return Requests.processRoute(CampaignsRoute.routes.sourcingSearchAnyIgdbGame, undefined, { campaign_id }, params);
927
+ }
928
+
929
+ /**
930
+ * Get full game details from a list of IGDB IDs.
931
+ * @param campaign_id The UUID of the campaign.
932
+ * @param data An object containing the array of IGDB IDs.
933
+ * @param data.igdb_ids An array of IGDB game IDs.
934
+ * @returns promise
935
+ */
936
+ public static sourcingGetGamesByIds<T>(campaign_id: string, data: { igdb_ids: number[] }): AxiosPromise<Response<T>> {
937
+ return Requests.processRoute(CampaignsRoute.routes.sourcingGetGamesByIds, data, { campaign_id });
938
+ }
939
+
940
+
919
941
  }
920
942
 
921
943
  export default Campaigns;
@@ -210,6 +210,45 @@ class Fingerprinting {
210
210
  params
211
211
  );
212
212
  }
213
+
214
+ /**
215
+ * Get pixel and utem reports
216
+ *
217
+ * @param params Report options:
218
+ * - title_id: string - Required title ID
219
+ * - start_date?: string - Start date (YYYY-MM-DD)
220
+ * - end_date?: string - End date (YYYY-MM-DD)
221
+ * - group_by?: 'country'|'region'|'city' - Grouping level
222
+ * @returns Promise with geolocation report data
223
+ */
224
+ public static pixelAttributionReport<T>(params: Record<string, any>): AxiosPromise<Response<T>> {
225
+ return Requests.processRoute(
226
+ FingerprintingRoute.routes.pixelAttributionReport,
227
+ {},
228
+ undefined,
229
+ params
230
+ );
231
+ }
232
+
233
+
234
+ /**
235
+ * Get an understanding of the path people take to install your game
236
+ *
237
+ * @param params Report options:
238
+ * - title_id: string - Required title ID
239
+ * - start_date?: string - Start date (YYYY-MM-DD)
240
+ * - end_date?: string - End date (YYYY-MM-DD)
241
+ * - group_by?: 'country'|'region'|'city' - Grouping level
242
+ * @returns Promise with geolocation report data
243
+ */
244
+ public static installJourneyReport<T>(params: Record<string, any>): AxiosPromise<Response<T>> {
245
+ return Requests.processRoute(
246
+ FingerprintingRoute.routes.installJourneyReport,
247
+ {},
248
+ undefined,
249
+ params
250
+ );
251
+ }
213
252
  }
214
253
 
215
254
  export default Fingerprinting;
@@ -74,7 +74,8 @@ class CampaignsRoute {
74
74
  sourcingFindAndSaveTwitchCreators: { url: '/campaigns/{campaign_id}/sourcing/find-save-twitch-creators', method: HTTP_METHODS.POST },
75
75
  sourcingFindAndSaveYouTubeCreators: { url: '/campaigns/{campaign_id}/sourcing/find-save-youtube-creators', method: HTTP_METHODS.POST },
76
76
  exportSourcedCreators: { url: '/campaigns/{campaign_id}/sourcing/creators/export', method: HTTP_METHODS.GET },
77
-
77
+ sourcingSearchAnyIgdbGame: { url: '/campaigns/{campaign_id}/sourcing/search-any-game', method: HTTP_METHODS.GET },
78
+ sourcingGetGamesByIds: { url: '/campaigns/{campaign_id}/sourcing/games-by-ids', method: HTTP_METHODS.POST },
78
79
 
79
80
  };
80
81
 
@@ -42,7 +42,15 @@ class FingerprintingRoute {
42
42
  geolocationReport: {
43
43
  url: '/reports/fingerprinting/geolocation',
44
44
  method: HTTP_METHODS.GET
45
- }
45
+ },
46
+ pixelAttributionReport: {
47
+ url: '/reports/fingerprinting/pixel-attribution',
48
+ method: HTTP_METHODS.GET
49
+ },
50
+ installJourneyReport: {
51
+ url: '/reports/fingerprinting/install-journey',
52
+ method: HTTP_METHODS.GET
53
+ },
46
54
  };
47
55
  }
48
56