glitch-javascript-sdk 2.3.3 → 2.3.5

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.
@@ -526,5 +526,16 @@ declare class Scheduler {
526
526
  platform: string;
527
527
  account_id?: string;
528
528
  }): AxiosPromise<Response<T>>;
529
+ /**
530
+ * Trigger a historical sync for a specific platform on a scheduler.
531
+ *
532
+ * @see https://api.glitch.fun/api/documentation#/Scheduler/syncHistory
533
+ *
534
+ * @param scheduler_id The ID of the promotion schedule.
535
+ * @param platform The platform to sync (e.g., 'twitter', 'youtube', 'bluesky').
536
+ *
537
+ * @returns promise
538
+ */
539
+ static syncHistory<T>(scheduler_id: string, platform: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
529
540
  }
530
541
  export default Scheduler;
@@ -233,5 +233,15 @@ declare class SocialPosts {
233
233
  * @returns A promise
234
234
  */
235
235
  static getLinkSummary<T>(post_id: string): AxiosPromise<Response<T>>;
236
+ /**
237
+ * Trigger a historical sync for a specific platform for the current user.
238
+ *
239
+ * @see https://api.glitch.fun/api/documentation#/Social%20Media%20Posts/syncHistory
240
+ *
241
+ * @param platform The platform to sync (e.g., 'twitter', 'youtube', 'bluesky').
242
+ *
243
+ * @returns promise
244
+ */
245
+ static syncHistory<T>(platform: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
236
246
  }
237
247
  export default SocialPosts;
package/dist/esm/index.js CHANGED
@@ -10949,6 +10949,8 @@ var SocialPostsRoute = /** @class */ (function () {
10949
10949
  createComment: { url: '/socialposts/{post_id}/comments', method: HTTP_METHODS.POST },
10950
10950
  getPostAttribution: { url: '/socialposts/{post_id}/attribution', method: HTTP_METHODS.GET },
10951
10951
  getSocialPostAttributionReport: { url: '/reports/fingerprinting/social-post-attribution', method: HTTP_METHODS.GET },
10952
+ getLinkSummary: { url: '/socialposts/{post_id}/link-summary', method: HTTP_METHODS.GET },
10953
+ syncHistory: { url: '/social/sync-history/{platform}', method: HTTP_METHODS.POST },
10952
10954
  };
10953
10955
  return SocialPostsRoute;
10954
10956
  }());
@@ -11242,6 +11244,18 @@ var SocialPosts = /** @class */ (function () {
11242
11244
  SocialPosts.getLinkSummary = function (post_id) {
11243
11245
  return Requests.processRoute(SocialPostsRoute.routes.getLinkSummary, undefined, { post_id: post_id });
11244
11246
  };
11247
+ /**
11248
+ * Trigger a historical sync for a specific platform for the current user.
11249
+ *
11250
+ * @see https://api.glitch.fun/api/documentation#/Social%20Media%20Posts/syncHistory
11251
+ *
11252
+ * @param platform The platform to sync (e.g., 'twitter', 'youtube', 'bluesky').
11253
+ *
11254
+ * @returns promise
11255
+ */
11256
+ SocialPosts.syncHistory = function (platform, params) {
11257
+ return Requests.processRoute(SocialPostsRoute.routes.syncHistory, {}, { platform: platform }, params);
11258
+ };
11245
11259
  return SocialPosts;
11246
11260
  }());
11247
11261
 
@@ -14087,6 +14101,7 @@ var SchedulerRoute = /** @class */ (function () {
14087
14101
  getSchedulerPostsWithComments: { url: '/schedulers/{scheduler_id}/posts-with-comments', method: HTTP_METHODS.GET },
14088
14102
  syncAllSchedulerComments: { url: '/schedulers/{scheduler_id}/sync-all-comments', method: HTTP_METHODS.POST },
14089
14103
  getConversionActions: { url: '/schedulers/{scheduler_id}/conversion-actions', method: HTTP_METHODS.GET },
14104
+ syncHistory: { url: '/schedulers/{scheduler_id}/sync-history/{platform}', method: HTTP_METHODS.POST },
14090
14105
  };
14091
14106
  return SchedulerRoute;
14092
14107
  }());
@@ -14753,6 +14768,19 @@ var Scheduler = /** @class */ (function () {
14753
14768
  Scheduler.getConversionActions = function (scheduler_id, params) {
14754
14769
  return Requests.processRoute(SchedulerRoute.routes.getConversionActions, {}, { scheduler_id: scheduler_id }, params);
14755
14770
  };
14771
+ /**
14772
+ * Trigger a historical sync for a specific platform on a scheduler.
14773
+ *
14774
+ * @see https://api.glitch.fun/api/documentation#/Scheduler/syncHistory
14775
+ *
14776
+ * @param scheduler_id The ID of the promotion schedule.
14777
+ * @param platform The platform to sync (e.g., 'twitter', 'youtube', 'bluesky').
14778
+ *
14779
+ * @returns promise
14780
+ */
14781
+ Scheduler.syncHistory = function (scheduler_id, platform, params) {
14782
+ return Requests.processRoute(SchedulerRoute.routes.syncHistory, {}, { scheduler_id: scheduler_id, platform: platform }, params);
14783
+ };
14756
14784
  return Scheduler;
14757
14785
  }());
14758
14786