glitch-javascript-sdk 1.7.2 → 1.7.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.
@@ -289,74 +289,56 @@ declare class Scheduler {
289
289
  */
290
290
  static getSchedulerProgression<T>(scheduler_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
291
291
  /**
292
- * List active cross-promote relationships for a scheduler.
293
- *
294
- * @param scheduler_id The ID of the promotion schedule
295
- * @param params Optional query params
296
- */
292
+ * List cross-promote relationships for a scheduler (with optional pagination).
293
+ * GET /schedulers/{scheduler_id}/crosspromote/relationships
294
+ */
297
295
  static crossPromoteListRelationships<T>(scheduler_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
298
296
  /**
299
- * Find potential cross-promote partners for a scheduler.
300
- *
301
- * @param scheduler_id The ID of the promotion schedule
302
- * @param params Optional query params
297
+ * Find potential cross-promote partners for a scheduler (with optional filters).
298
+ * GET /schedulers/{scheduler_id}/crosspromote/find
303
299
  */
304
300
  static crossPromoteFind<T>(scheduler_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
305
301
  /**
306
- * List cross-promote invites for a scheduler.
307
- *
308
- * @param scheduler_id The ID of the promotion schedule
309
- * @param params Optional query params
302
+ * List cross-promote invites for a scheduler (incoming + outgoing).
303
+ * GET /schedulers/{scheduler_id}/crosspromote/invites
310
304
  */
311
305
  static crossPromoteInvitesList<T>(scheduler_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
312
306
  /**
313
- * Send an invite to cross-promote.
307
+ * Send an invite to cross-promote (from scheduler_id to partner_scheduler_id).
308
+ * POST /schedulers/{scheduler_id}/crosspromote/invites
314
309
  *
315
- * @param scheduler_id The ID of the promotion schedule
316
310
  * @param data { partner_scheduler_id, optional_message }
317
311
  */
318
312
  static crossPromoteInviteSend<T>(scheduler_id: string, data: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
319
313
  /**
320
314
  * Accept an invite to cross-promote.
321
- *
322
- * @param scheduler_id The ID of the promotion schedule
323
- * @param invite_id The ID of the invite
315
+ * POST /schedulers/{scheduler_id}/crosspromote/invites/{invite_id}/accept
324
316
  */
325
317
  static crossPromoteInviteAccept<T>(scheduler_id: string, invite_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
326
318
  /**
327
319
  * Reject an invite to cross-promote.
328
- *
329
- * @param scheduler_id The ID of the promotion schedule
330
- * @param invite_id The ID of the invite
320
+ * POST /schedulers/{scheduler_id}/crosspromote/invites/{invite_id}/reject
331
321
  */
332
322
  static crossPromoteInviteReject<T>(scheduler_id: string, invite_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
333
323
  /**
334
- * End a cross-promote relationship.
335
- *
336
- * @param scheduler_id The ID of the promotion schedule
337
- * @param relationship_id The ID of the relationship
324
+ * End a cross-promote relationship (delete).
325
+ * DELETE /schedulers/{scheduler_id}/crosspromote/relationships/{relationship_id}
338
326
  */
339
327
  static crossPromoteRelationshipDelete<T>(scheduler_id: string, relationship_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
340
328
  /**
341
329
  * Get which platforms are cross-promoted in an existing relationship.
342
- *
343
- * @param scheduler_id The ID of the promotion schedule
344
- * @param relationship_id The ID of the relationship
330
+ * GET /schedulers/{scheduler_id}/crosspromote/relationships/{relationship_id}/platforms
345
331
  */
346
332
  static crossPromoteRelationshipGetPlatforms<T>(scheduler_id: string, relationship_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
347
333
  /**
348
334
  * Set which platforms are cross-promoted in an existing relationship.
349
- *
350
- * @param scheduler_id The ID of the promotion schedule
351
- * @param relationship_id The ID of the relationship
352
- * @param data An object like { platforms: ['twitter', 'facebook', ...] }
335
+ * PUT /schedulers/{scheduler_id}/crosspromote/relationships/{relationship_id}/platforms
336
+ * data = { platforms: ['twitter','facebook',...]}
353
337
  */
354
338
  static crossPromoteRelationshipSetPlatforms<T>(scheduler_id: string, relationship_id: string, data: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
355
339
  /**
356
- * Get recently cross-promoted posts under a relationship.
357
- *
358
- * @param scheduler_id The ID of the promotion schedule
359
- * @param relationship_id The ID of the relationship
340
+ * Get recently cross-promoted logs under a relationship.
341
+ * GET /schedulers/{scheduler_id}/crosspromote/relationships/{relationship_id}/posts
360
342
  */
361
343
  static crossPromoteRelationshipPosts<T>(scheduler_id: string, relationship_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
362
344
  }
package/dist/esm/index.js CHANGED
@@ -11639,37 +11639,30 @@ var SchedulerRoute = /** @class */ (function () {
11639
11639
  url: '/schedulers/{scheduler_id}/crosspromote/relationships',
11640
11640
  method: HTTP_METHODS.GET
11641
11641
  },
11642
- // 2) Find potential cross-promote partners
11643
11642
  crossPromoteFind: {
11644
11643
  url: '/schedulers/{scheduler_id}/crosspromote/find',
11645
11644
  method: HTTP_METHODS.GET
11646
11645
  },
11647
- // 3) List invites
11648
11646
  crossPromoteInvitesList: {
11649
11647
  url: '/schedulers/{scheduler_id}/crosspromote/invites',
11650
11648
  method: HTTP_METHODS.GET
11651
11649
  },
11652
- // 4) Send an invite to cross-promote
11653
11650
  crossPromoteInviteSend: {
11654
11651
  url: '/schedulers/{scheduler_id}/crosspromote/invites',
11655
11652
  method: HTTP_METHODS.POST
11656
11653
  },
11657
- // 5) Accept an invite
11658
11654
  crossPromoteInviteAccept: {
11659
11655
  url: '/schedulers/{scheduler_id}/crosspromote/invites/{invite_id}/accept',
11660
11656
  method: HTTP_METHODS.POST
11661
11657
  },
11662
- // 6) Reject an invite
11663
11658
  crossPromoteInviteReject: {
11664
11659
  url: '/schedulers/{scheduler_id}/crosspromote/invites/{invite_id}/reject',
11665
11660
  method: HTTP_METHODS.POST
11666
11661
  },
11667
- // 7) End a cross-promote relationship
11668
11662
  crossPromoteRelationshipDelete: {
11669
11663
  url: '/schedulers/{scheduler_id}/crosspromote/relationships/{relationship_id}',
11670
11664
  method: HTTP_METHODS.DELETE
11671
11665
  },
11672
- // 8) Get/Set which platforms are cross-promoted in an existing relationship
11673
11666
  crossPromoteRelationshipGetPlatforms: {
11674
11667
  url: '/schedulers/{scheduler_id}/crosspromote/relationships/{relationship_id}/platforms',
11675
11668
  method: HTTP_METHODS.GET
@@ -11678,7 +11671,6 @@ var SchedulerRoute = /** @class */ (function () {
11678
11671
  url: '/schedulers/{scheduler_id}/crosspromote/relationships/{relationship_id}/platforms',
11679
11672
  method: HTTP_METHODS.PUT
11680
11673
  },
11681
- // 9) Get recently cross-promoted posts under a relationship
11682
11674
  crossPromoteRelationshipPosts: {
11683
11675
  url: '/schedulers/{scheduler_id}/crosspromote/relationships/{relationship_id}/posts',
11684
11676
  method: HTTP_METHODS.GET
@@ -12046,36 +12038,31 @@ var Scheduler = /** @class */ (function () {
12046
12038
  return Requests.processRoute(SchedulerRoute.routes.getSchedulerProgression, {}, { scheduler_id: scheduler_id }, params);
12047
12039
  };
12048
12040
  /**
12049
- * List active cross-promote relationships for a scheduler.
12050
- *
12051
- * @param scheduler_id The ID of the promotion schedule
12052
- * @param params Optional query params
12053
- */
12041
+ * List cross-promote relationships for a scheduler (with optional pagination).
12042
+ * GET /schedulers/{scheduler_id}/crosspromote/relationships
12043
+ */
12054
12044
  Scheduler.crossPromoteListRelationships = function (scheduler_id, params) {
12055
12045
  return Requests.processRoute(SchedulerRoute.routes.crossPromoteListRelationships, {}, { scheduler_id: scheduler_id }, params);
12056
12046
  };
12057
12047
  /**
12058
- * Find potential cross-promote partners for a scheduler.
12059
- *
12060
- * @param scheduler_id The ID of the promotion schedule
12061
- * @param params Optional query params
12048
+ * Find potential cross-promote partners for a scheduler (with optional filters).
12049
+ * GET /schedulers/{scheduler_id}/crosspromote/find
12062
12050
  */
12063
12051
  Scheduler.crossPromoteFind = function (scheduler_id, params) {
12052
+ // e.g. { platform:'twitter', min_followers:500, sort:'desc', page:2, limit:5 }
12064
12053
  return Requests.processRoute(SchedulerRoute.routes.crossPromoteFind, {}, { scheduler_id: scheduler_id }, params);
12065
12054
  };
12066
12055
  /**
12067
- * List cross-promote invites for a scheduler.
12068
- *
12069
- * @param scheduler_id The ID of the promotion schedule
12070
- * @param params Optional query params
12056
+ * List cross-promote invites for a scheduler (incoming + outgoing).
12057
+ * GET /schedulers/{scheduler_id}/crosspromote/invites
12071
12058
  */
12072
12059
  Scheduler.crossPromoteInvitesList = function (scheduler_id, params) {
12073
12060
  return Requests.processRoute(SchedulerRoute.routes.crossPromoteInvitesList, {}, { scheduler_id: scheduler_id }, params);
12074
12061
  };
12075
12062
  /**
12076
- * Send an invite to cross-promote.
12063
+ * Send an invite to cross-promote (from scheduler_id to partner_scheduler_id).
12064
+ * POST /schedulers/{scheduler_id}/crosspromote/invites
12077
12065
  *
12078
- * @param scheduler_id The ID of the promotion schedule
12079
12066
  * @param data { partner_scheduler_id, optional_message }
12080
12067
  */
12081
12068
  Scheduler.crossPromoteInviteSend = function (scheduler_id, data, params) {
@@ -12083,55 +12070,43 @@ var Scheduler = /** @class */ (function () {
12083
12070
  };
12084
12071
  /**
12085
12072
  * Accept an invite to cross-promote.
12086
- *
12087
- * @param scheduler_id The ID of the promotion schedule
12088
- * @param invite_id The ID of the invite
12073
+ * POST /schedulers/{scheduler_id}/crosspromote/invites/{invite_id}/accept
12089
12074
  */
12090
12075
  Scheduler.crossPromoteInviteAccept = function (scheduler_id, invite_id, params) {
12091
12076
  return Requests.processRoute(SchedulerRoute.routes.crossPromoteInviteAccept, {}, { scheduler_id: scheduler_id, invite_id: invite_id }, params);
12092
12077
  };
12093
12078
  /**
12094
12079
  * Reject an invite to cross-promote.
12095
- *
12096
- * @param scheduler_id The ID of the promotion schedule
12097
- * @param invite_id The ID of the invite
12080
+ * POST /schedulers/{scheduler_id}/crosspromote/invites/{invite_id}/reject
12098
12081
  */
12099
12082
  Scheduler.crossPromoteInviteReject = function (scheduler_id, invite_id, params) {
12100
12083
  return Requests.processRoute(SchedulerRoute.routes.crossPromoteInviteReject, {}, { scheduler_id: scheduler_id, invite_id: invite_id }, params);
12101
12084
  };
12102
12085
  /**
12103
- * End a cross-promote relationship.
12104
- *
12105
- * @param scheduler_id The ID of the promotion schedule
12106
- * @param relationship_id The ID of the relationship
12086
+ * End a cross-promote relationship (delete).
12087
+ * DELETE /schedulers/{scheduler_id}/crosspromote/relationships/{relationship_id}
12107
12088
  */
12108
12089
  Scheduler.crossPromoteRelationshipDelete = function (scheduler_id, relationship_id, params) {
12109
12090
  return Requests.processRoute(SchedulerRoute.routes.crossPromoteRelationshipDelete, {}, { scheduler_id: scheduler_id, relationship_id: relationship_id }, params);
12110
12091
  };
12111
12092
  /**
12112
12093
  * Get which platforms are cross-promoted in an existing relationship.
12113
- *
12114
- * @param scheduler_id The ID of the promotion schedule
12115
- * @param relationship_id The ID of the relationship
12094
+ * GET /schedulers/{scheduler_id}/crosspromote/relationships/{relationship_id}/platforms
12116
12095
  */
12117
12096
  Scheduler.crossPromoteRelationshipGetPlatforms = function (scheduler_id, relationship_id, params) {
12118
12097
  return Requests.processRoute(SchedulerRoute.routes.crossPromoteRelationshipGetPlatforms, {}, { scheduler_id: scheduler_id, relationship_id: relationship_id }, params);
12119
12098
  };
12120
12099
  /**
12121
12100
  * Set which platforms are cross-promoted in an existing relationship.
12122
- *
12123
- * @param scheduler_id The ID of the promotion schedule
12124
- * @param relationship_id The ID of the relationship
12125
- * @param data An object like { platforms: ['twitter', 'facebook', ...] }
12101
+ * PUT /schedulers/{scheduler_id}/crosspromote/relationships/{relationship_id}/platforms
12102
+ * data = { platforms: ['twitter','facebook',...]}
12126
12103
  */
12127
12104
  Scheduler.crossPromoteRelationshipSetPlatforms = function (scheduler_id, relationship_id, data, params) {
12128
12105
  return Requests.processRoute(SchedulerRoute.routes.crossPromoteRelationshipSetPlatforms, data, { scheduler_id: scheduler_id, relationship_id: relationship_id }, params);
12129
12106
  };
12130
12107
  /**
12131
- * Get recently cross-promoted posts under a relationship.
12132
- *
12133
- * @param scheduler_id The ID of the promotion schedule
12134
- * @param relationship_id The ID of the relationship
12108
+ * Get recently cross-promoted logs under a relationship.
12109
+ * GET /schedulers/{scheduler_id}/crosspromote/relationships/{relationship_id}/posts
12135
12110
  */
12136
12111
  Scheduler.crossPromoteRelationshipPosts = function (scheduler_id, relationship_id, params) {
12137
12112
  return Requests.processRoute(SchedulerRoute.routes.crossPromoteRelationshipPosts, {}, { scheduler_id: scheduler_id, relationship_id: relationship_id }, params);