glitch-javascript-sdk 1.9.6 → 1.9.8

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.
@@ -417,5 +417,45 @@ declare class Ads {
417
417
  community_id?: string;
418
418
  platform?: string;
419
419
  }): AxiosPromise<Response<T>>;
420
+ /**
421
+ * GET /ads/google/targeting/geo/suggest
422
+ */
423
+ static listGoogleGeoSuggestions<T>(params: Record<string, any>): AxiosPromise<Response<T>>;
424
+ /**
425
+ * POST /ads/google/targeting/campaigns/{customer_id}/{campaign_id}/locations
426
+ */
427
+ static addGoogleLocationTargets<T>(customer_id: number, campaign_id: number, data: object): AxiosPromise<Response<T>>;
428
+ /**
429
+ * GET /ads/google/targeting/campaigns/{customer_id}/{campaign_id}/locations
430
+ */
431
+ static getGoogleLocationTargets<T>(customer_id: number, campaign_id: number, params: Record<string, any>): AxiosPromise<Response<T>>;
432
+ /**
433
+ * DELETE /ads/google/targeting/campaigns/{customer_id}/{campaign_id}/locations
434
+ */
435
+ static removeGoogleLocationTargets<T>(customer_id: number, campaign_id: number, data: object): AxiosPromise<Response<T>>;
436
+ /**
437
+ * POST /ads/google/targeting/campaigns/{customer_id}/{campaign_id}/proximity
438
+ */
439
+ static addGoogleProximityTarget<T>(customer_id: number, campaign_id: number, data: object): AxiosPromise<Response<T>>;
440
+ /**
441
+ * PUT /ads/google/targeting/{resource_type}/{customer_id}/{resource_id}/settings
442
+ */
443
+ static updateGoogleTargetingSettings<T>(resource_type: 'campaign' | 'ad_group', customer_id: number, resource_id: number, data: object): AxiosPromise<Response<T>>;
444
+ /**
445
+ * GET /ads/google/targeting/{resource_type}/{customer_id}/{resource_id}/settings
446
+ */
447
+ static getGoogleTargetingSettings<T>(resource_type: 'campaign' | 'ad_group', customer_id: number, resource_id: number, params: Record<string, any>): AxiosPromise<Response<T>>;
448
+ /** GET /ads/posts/google */
449
+ static listGoogleAdPosts<T>(params?: Record<string, any>): AxiosPromise<Response<T>>;
450
+ /** POST /ads/posts/google */
451
+ static createGoogleAdPost<T>(data?: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
452
+ /** PUT /ads/posts/google/{post_id} */
453
+ static updateGoogleAdPost<T>(post_id: string, data?: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
454
+ /** DELETE /ads/posts/google/{post_id} */
455
+ static deleteGoogleAdPost<T>(post_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
456
+ /** POST /ads/posts/google/{post_id}/pause */
457
+ static pauseGoogleAdPost<T>(post_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
458
+ /** POST /ads/posts/google/{post_id}/enable */
459
+ static enableGoogleAdPost<T>(post_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
420
460
  }
421
461
  export default Ads;
@@ -538,5 +538,62 @@ declare class Campaigns {
538
538
  * @returns promise
539
539
  */
540
540
  static sendCampaignContractWithDocusign<T>(campaign_id: string, user_id: string, data?: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
541
+ /**
542
+ * Search IGDB for the campaign's game.
543
+ * @param campaign_id The UUID of the campaign.
544
+ * @param params Query parameters (e.g., search_query, limit).
545
+ * @returns promise
546
+ */
547
+ static sourcingSearchIgdbForCampaignGame<T>(campaign_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
548
+ /**
549
+ * Find popular similar games from IGDB.
550
+ * @param campaign_id The UUID of the campaign.
551
+ * @param params Query parameters (e.g., igdb_id, limit).
552
+ * @returns promise
553
+ */
554
+ static sourcingGetSimilarIgdbGames<T>(campaign_id: string, params: Record<string, any>): AxiosPromise<Response<T>>;
555
+ /**
556
+ * Find content creators for selected games. This does not save them to the database.
557
+ * @param campaign_id The UUID of the campaign.
558
+ * @param data The search criteria (source, igdb_ids, etc.).
559
+ * @returns promise
560
+ */
561
+ static sourcingFindCreators<T>(campaign_id: string, data: object): AxiosPromise<Response<T>>;
562
+ /**
563
+ * Update campaign sourcing settings.
564
+ * @param campaign_id The UUID of the campaign.
565
+ * @param data The settings to update (igdb_id, similar_game_igdb_ids, etc.).
566
+ * @returns promise
567
+ */
568
+ static updateSourcingSettings<T>(campaign_id: string, data: object): AxiosPromise<Response<T>>;
569
+ /**
570
+ * Find and save content creators for selected games to the database.
571
+ * @param campaign_id The UUID of the campaign.
572
+ * @param data The search criteria (source, igdb_ids, etc.).
573
+ * @returns promise
574
+ */
575
+ static sourcingFindAndSaveCreators<T>(campaign_id: string, data: object): AxiosPromise<Response<T>>;
576
+ /**
577
+ * Get sourced creators for a campaign from the database.
578
+ * @param campaign_id The UUID of the campaign.
579
+ * @param params Query parameters for filtering, sorting, and pagination.
580
+ * @returns promise
581
+ */
582
+ static getSourcedCreators<T>(campaign_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
583
+ /**
584
+ * Get a single sourced creator.
585
+ * @param campaign_id The UUID of the campaign.
586
+ * @param sourced_creator_id The UUID of the sourced creator.
587
+ * @returns promise
588
+ */
589
+ static getSourcedCreator<T>(campaign_id: string, sourced_creator_id: string): AxiosPromise<Response<T>>;
590
+ /**
591
+ * Update a sourced creator (e.g., approve or reject).
592
+ * @param campaign_id The UUID of the campaign.
593
+ * @param sourced_creator_id The UUID of the sourced creator to update.
594
+ * @param data The update data (e.g., is_approved, is_rejected).
595
+ * @returns promise
596
+ */
597
+ static updateSourcedCreator<T>(campaign_id: string, sourced_creator_id: string, data: object): AxiosPromise<Response<T>>;
541
598
  }
542
599
  export default Campaigns;
package/dist/esm/index.js CHANGED
@@ -6949,6 +6949,58 @@ var AdsRoute = /** @class */ (function () {
6949
6949
  url: "/ads/reports/time-performance",
6950
6950
  method: HTTP_METHODS.GET,
6951
6951
  },
6952
+ getGoogleGeoSuggestions: {
6953
+ url: "/ads/google/targeting/geo/suggest",
6954
+ method: HTTP_METHODS.GET,
6955
+ },
6956
+ addGoogleLocationTargets: {
6957
+ url: "/ads/google/targeting/campaigns/{customer_id}/{campaign_id}/locations",
6958
+ method: HTTP_METHODS.POST,
6959
+ },
6960
+ getGoogleLocationTargets: {
6961
+ url: "/ads/google/targeting/campaigns/{customer_id}/{campaign_id}/locations",
6962
+ method: HTTP_METHODS.GET,
6963
+ },
6964
+ removeGoogleLocationTargets: {
6965
+ url: "/ads/google/targeting/campaigns/{customer_id}/{campaign_id}/locations",
6966
+ method: HTTP_METHODS.DELETE,
6967
+ },
6968
+ addGoogleProximityTarget: {
6969
+ url: "/ads/google/targeting/campaigns/{customer_id}/{campaign_id}/proximity",
6970
+ method: HTTP_METHODS.POST,
6971
+ },
6972
+ updateGoogleTargetingSettings: {
6973
+ url: "/ads/google/targeting/{resource_type}/{customer_id}/{resource_id}/settings",
6974
+ method: HTTP_METHODS.PUT,
6975
+ },
6976
+ getGoogleTargetingSettings: {
6977
+ url: "/ads/google/targeting/{resource_type}/{customer_id}/{resource_id}/settings",
6978
+ method: HTTP_METHODS.GET,
6979
+ },
6980
+ getGoogleAdPosts: {
6981
+ url: "/ads/posts/google",
6982
+ method: HTTP_METHODS.GET,
6983
+ },
6984
+ createGoogleAdPost: {
6985
+ url: "/ads/posts/google",
6986
+ method: HTTP_METHODS.POST,
6987
+ },
6988
+ updateGoogleAdPost: {
6989
+ url: "/ads/posts/google/{post_id}",
6990
+ method: HTTP_METHODS.PUT,
6991
+ },
6992
+ deleteGoogleAdPost: {
6993
+ url: "/ads/posts/google/{post_id}",
6994
+ method: HTTP_METHODS.DELETE,
6995
+ },
6996
+ pauseGoogleAdPost: {
6997
+ url: "/ads/posts/google/{post_id}/pause",
6998
+ method: HTTP_METHODS.POST,
6999
+ },
7000
+ enableGoogleAdPost: {
7001
+ url: "/ads/posts/google/{post_id}/enable",
7002
+ method: HTTP_METHODS.POST,
7003
+ },
6952
7004
  };
6953
7005
  return AdsRoute;
6954
7006
  }());
@@ -7548,6 +7600,72 @@ var Ads = /** @class */ (function () {
7548
7600
  Ads.getTimePerformanceReport = function (params) {
7549
7601
  return Requests.processRoute(AdsRoute.routes.getTimePerformanceReport, undefined, undefined, params);
7550
7602
  };
7603
+ /**
7604
+ * GET /ads/google/targeting/geo/suggest
7605
+ */
7606
+ Ads.listGoogleGeoSuggestions = function (params) {
7607
+ return Requests.processRoute(AdsRoute.routes.getGoogleGeoSuggestions, undefined, undefined, params);
7608
+ };
7609
+ /**
7610
+ * POST /ads/google/targeting/campaigns/{customer_id}/{campaign_id}/locations
7611
+ */
7612
+ Ads.addGoogleLocationTargets = function (customer_id, campaign_id, data) {
7613
+ return Requests.processRoute(AdsRoute.routes.addGoogleLocationTargets, data, { customer_id: customer_id, campaign_id: campaign_id });
7614
+ };
7615
+ /**
7616
+ * GET /ads/google/targeting/campaigns/{customer_id}/{campaign_id}/locations
7617
+ */
7618
+ Ads.getGoogleLocationTargets = function (customer_id, campaign_id, params) {
7619
+ return Requests.processRoute(AdsRoute.routes.getGoogleLocationTargets, undefined, { customer_id: customer_id, campaign_id: campaign_id }, params);
7620
+ };
7621
+ /**
7622
+ * DELETE /ads/google/targeting/campaigns/{customer_id}/{campaign_id}/locations
7623
+ */
7624
+ Ads.removeGoogleLocationTargets = function (customer_id, campaign_id, data) {
7625
+ return Requests.processRoute(AdsRoute.routes.removeGoogleLocationTargets, data, { customer_id: customer_id, campaign_id: campaign_id });
7626
+ };
7627
+ /**
7628
+ * POST /ads/google/targeting/campaigns/{customer_id}/{campaign_id}/proximity
7629
+ */
7630
+ Ads.addGoogleProximityTarget = function (customer_id, campaign_id, data) {
7631
+ return Requests.processRoute(AdsRoute.routes.addGoogleProximityTarget, data, { customer_id: customer_id, campaign_id: campaign_id });
7632
+ };
7633
+ /**
7634
+ * PUT /ads/google/targeting/{resource_type}/{customer_id}/{resource_id}/settings
7635
+ */
7636
+ Ads.updateGoogleTargetingSettings = function (resource_type, customer_id, resource_id, data) {
7637
+ return Requests.processRoute(AdsRoute.routes.updateGoogleTargetingSettings, data, { resource_type: resource_type, customer_id: customer_id, resource_id: resource_id });
7638
+ };
7639
+ /**
7640
+ * GET /ads/google/targeting/{resource_type}/{customer_id}/{resource_id}/settings
7641
+ */
7642
+ Ads.getGoogleTargetingSettings = function (resource_type, customer_id, resource_id, params) {
7643
+ return Requests.processRoute(AdsRoute.routes.getGoogleTargetingSettings, undefined, { resource_type: resource_type, customer_id: customer_id, resource_id: resource_id }, params);
7644
+ };
7645
+ /** GET /ads/posts/google */
7646
+ Ads.listGoogleAdPosts = function (params) {
7647
+ return Requests.processRoute(AdsRoute.routes.getGoogleAdPosts, undefined, undefined, params);
7648
+ };
7649
+ /** POST /ads/posts/google */
7650
+ Ads.createGoogleAdPost = function (data, params) {
7651
+ return Requests.processRoute(AdsRoute.routes.createGoogleAdPost, data, {}, params);
7652
+ };
7653
+ /** PUT /ads/posts/google/{post_id} */
7654
+ Ads.updateGoogleAdPost = function (post_id, data, params) {
7655
+ return Requests.processRoute(AdsRoute.routes.updateGoogleAdPost, data, { post_id: post_id }, params);
7656
+ };
7657
+ /** DELETE /ads/posts/google/{post_id} */
7658
+ Ads.deleteGoogleAdPost = function (post_id, params) {
7659
+ return Requests.processRoute(AdsRoute.routes.deleteGoogleAdPost, {}, { post_id: post_id }, params);
7660
+ };
7661
+ /** POST /ads/posts/google/{post_id}/pause */
7662
+ Ads.pauseGoogleAdPost = function (post_id, params) {
7663
+ return Requests.processRoute(AdsRoute.routes.pauseGoogleAdPost, {}, { post_id: post_id }, params);
7664
+ };
7665
+ /** POST /ads/posts/google/{post_id}/enable */
7666
+ Ads.enableGoogleAdPost = function (post_id, params) {
7667
+ return Requests.processRoute(AdsRoute.routes.enableGoogleAdPost, {}, { post_id: post_id }, params);
7668
+ };
7551
7669
  return Ads;
7552
7670
  }());
7553
7671
 
@@ -11330,6 +11448,14 @@ var CampaignsRoute = /** @class */ (function () {
11330
11448
  listPayouts: { url: '/campaigns/{campaign_id}/payouts', method: HTTP_METHODS.GET },
11331
11449
  generateCampaignContract: { url: '/campaigns/{campaign_id}/influencers/{user_id}/contract', method: HTTP_METHODS.POST },
11332
11450
  sendCampaignContractWithDocusign: { url: '/campaigns/{campaign_id}/influencers/{user_id}/docusign', method: HTTP_METHODS.POST },
11451
+ sourcingSearchIgdbForCampaignGame: { url: '/campaigns/{campaign_id}/sourcing/search-game', method: HTTP_METHODS.GET },
11452
+ sourcingGetSimilarIgdbGames: { url: '/campaigns/{campaign_id}/sourcing/similar-games', method: HTTP_METHODS.GET },
11453
+ sourcingFindCreators: { url: '/campaigns/{campaign_id}/sourcing/find-creators', method: HTTP_METHODS.POST },
11454
+ updateSourcingSettings: { url: '/campaigns/{campaign_id}/sourcing/settings', method: HTTP_METHODS.PUT },
11455
+ sourcingFindAndSaveCreators: { url: '/campaigns/{campaign_id}/sourcing/find-save-creators', method: HTTP_METHODS.POST },
11456
+ getSourcedCreators: { url: '/campaigns/{campaign_id}/sourcing/creators', method: HTTP_METHODS.GET },
11457
+ getSourcedCreator: { url: '/campaigns/{campaign_id}/sourcing/creators/{sourced_creator_id}', method: HTTP_METHODS.GET },
11458
+ updateSourcedCreator: { url: '/campaigns/{campaign_id}/sourcing/creators/{sourced_creator_id}', method: HTTP_METHODS.PUT },
11333
11459
  };
11334
11460
  return CampaignsRoute;
11335
11461
  }());
@@ -11988,6 +12114,79 @@ var Campaigns = /** @class */ (function () {
11988
12114
  Campaigns.sendCampaignContractWithDocusign = function (campaign_id, user_id, data, params) {
11989
12115
  return Requests.processRoute(CampaignsRoute.routes.sendCampaignContractWithDocusign, data, { campaign_id: campaign_id, user_id: user_id }, params);
11990
12116
  };
12117
+ /**
12118
+ * Search IGDB for the campaign's game.
12119
+ * @param campaign_id The UUID of the campaign.
12120
+ * @param params Query parameters (e.g., search_query, limit).
12121
+ * @returns promise
12122
+ */
12123
+ Campaigns.sourcingSearchIgdbForCampaignGame = function (campaign_id, params) {
12124
+ return Requests.processRoute(CampaignsRoute.routes.sourcingSearchIgdbForCampaignGame, undefined, { campaign_id: campaign_id }, params);
12125
+ };
12126
+ /**
12127
+ * Find popular similar games from IGDB.
12128
+ * @param campaign_id The UUID of the campaign.
12129
+ * @param params Query parameters (e.g., igdb_id, limit).
12130
+ * @returns promise
12131
+ */
12132
+ Campaigns.sourcingGetSimilarIgdbGames = function (campaign_id, params) {
12133
+ return Requests.processRoute(CampaignsRoute.routes.sourcingGetSimilarIgdbGames, undefined, { campaign_id: campaign_id }, params);
12134
+ };
12135
+ /**
12136
+ * Find content creators for selected games. This does not save them to the database.
12137
+ * @param campaign_id The UUID of the campaign.
12138
+ * @param data The search criteria (source, igdb_ids, etc.).
12139
+ * @returns promise
12140
+ */
12141
+ Campaigns.sourcingFindCreators = function (campaign_id, data) {
12142
+ return Requests.processRoute(CampaignsRoute.routes.sourcingFindCreators, data, { campaign_id: campaign_id });
12143
+ };
12144
+ /**
12145
+ * Update campaign sourcing settings.
12146
+ * @param campaign_id The UUID of the campaign.
12147
+ * @param data The settings to update (igdb_id, similar_game_igdb_ids, etc.).
12148
+ * @returns promise
12149
+ */
12150
+ Campaigns.updateSourcingSettings = function (campaign_id, data) {
12151
+ return Requests.processRoute(CampaignsRoute.routes.updateSourcingSettings, data, { campaign_id: campaign_id });
12152
+ };
12153
+ /**
12154
+ * Find and save content creators for selected games to the database.
12155
+ * @param campaign_id The UUID of the campaign.
12156
+ * @param data The search criteria (source, igdb_ids, etc.).
12157
+ * @returns promise
12158
+ */
12159
+ Campaigns.sourcingFindAndSaveCreators = function (campaign_id, data) {
12160
+ return Requests.processRoute(CampaignsRoute.routes.sourcingFindAndSaveCreators, data, { campaign_id: campaign_id });
12161
+ };
12162
+ /**
12163
+ * Get sourced creators for a campaign from the database.
12164
+ * @param campaign_id The UUID of the campaign.
12165
+ * @param params Query parameters for filtering, sorting, and pagination.
12166
+ * @returns promise
12167
+ */
12168
+ Campaigns.getSourcedCreators = function (campaign_id, params) {
12169
+ return Requests.processRoute(CampaignsRoute.routes.getSourcedCreators, undefined, { campaign_id: campaign_id }, params);
12170
+ };
12171
+ /**
12172
+ * Get a single sourced creator.
12173
+ * @param campaign_id The UUID of the campaign.
12174
+ * @param sourced_creator_id The UUID of the sourced creator.
12175
+ * @returns promise
12176
+ */
12177
+ Campaigns.getSourcedCreator = function (campaign_id, sourced_creator_id) {
12178
+ return Requests.processRoute(CampaignsRoute.routes.getSourcedCreator, undefined, { campaign_id: campaign_id, sourced_creator_id: sourced_creator_id });
12179
+ };
12180
+ /**
12181
+ * Update a sourced creator (e.g., approve or reject).
12182
+ * @param campaign_id The UUID of the campaign.
12183
+ * @param sourced_creator_id The UUID of the sourced creator to update.
12184
+ * @param data The update data (e.g., is_approved, is_rejected).
12185
+ * @returns promise
12186
+ */
12187
+ Campaigns.updateSourcedCreator = function (campaign_id, sourced_creator_id, data) {
12188
+ return Requests.processRoute(CampaignsRoute.routes.updateSourcedCreator, data, { campaign_id: campaign_id, sourced_creator_id: sourced_creator_id });
12189
+ };
11991
12190
  return Campaigns;
11992
12191
  }());
11993
12192