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.
- package/dist/cjs/index.js +28 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/api/Scheduler.d.ts +11 -0
- package/dist/esm/api/SocialPosts.d.ts +10 -0
- package/dist/esm/index.js +28 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.ts +21 -0
- package/package.json +1 -1
- package/src/api/Scheduler.ts +14 -0
- package/src/api/ShortLinks.ts +1 -0
- package/src/api/SocialPosts.ts +13 -0
- package/src/routes/SchedulerRoute.ts +2 -0
- package/src/routes/SocialPostsRoute.ts +2 -0
package/dist/index.d.ts
CHANGED
|
@@ -3610,6 +3610,16 @@ declare class SocialPosts {
|
|
|
3610
3610
|
* @returns A promise
|
|
3611
3611
|
*/
|
|
3612
3612
|
static getLinkSummary<T>(post_id: string): AxiosPromise<Response<T>>;
|
|
3613
|
+
/**
|
|
3614
|
+
* Trigger a historical sync for a specific platform for the current user.
|
|
3615
|
+
*
|
|
3616
|
+
* @see https://api.glitch.fun/api/documentation#/Social%20Media%20Posts/syncHistory
|
|
3617
|
+
*
|
|
3618
|
+
* @param platform The platform to sync (e.g., 'twitter', 'youtube', 'bluesky').
|
|
3619
|
+
*
|
|
3620
|
+
* @returns promise
|
|
3621
|
+
*/
|
|
3622
|
+
static syncHistory<T>(platform: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
3613
3623
|
}
|
|
3614
3624
|
|
|
3615
3625
|
declare class Titles {
|
|
@@ -6045,6 +6055,17 @@ declare class Scheduler {
|
|
|
6045
6055
|
platform: string;
|
|
6046
6056
|
account_id?: string;
|
|
6047
6057
|
}): AxiosPromise<Response<T>>;
|
|
6058
|
+
/**
|
|
6059
|
+
* Trigger a historical sync for a specific platform on a scheduler.
|
|
6060
|
+
*
|
|
6061
|
+
* @see https://api.glitch.fun/api/documentation#/Scheduler/syncHistory
|
|
6062
|
+
*
|
|
6063
|
+
* @param scheduler_id The ID of the promotion schedule.
|
|
6064
|
+
* @param platform The platform to sync (e.g., 'twitter', 'youtube', 'bluesky').
|
|
6065
|
+
*
|
|
6066
|
+
* @returns promise
|
|
6067
|
+
*/
|
|
6068
|
+
static syncHistory<T>(scheduler_id: string, platform: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
6048
6069
|
}
|
|
6049
6070
|
|
|
6050
6071
|
declare class Funnel {
|
package/package.json
CHANGED
package/src/api/Scheduler.ts
CHANGED
|
@@ -813,6 +813,20 @@ class Scheduler {
|
|
|
813
813
|
return Requests.processRoute(SchedulerRoute.routes.getConversionActions, {}, { scheduler_id }, params);
|
|
814
814
|
}
|
|
815
815
|
|
|
816
|
+
/**
|
|
817
|
+
* Trigger a historical sync for a specific platform on a scheduler.
|
|
818
|
+
*
|
|
819
|
+
* @see https://api.glitch.fun/api/documentation#/Scheduler/syncHistory
|
|
820
|
+
*
|
|
821
|
+
* @param scheduler_id The ID of the promotion schedule.
|
|
822
|
+
* @param platform The platform to sync (e.g., 'twitter', 'youtube', 'bluesky').
|
|
823
|
+
*
|
|
824
|
+
* @returns promise
|
|
825
|
+
*/
|
|
826
|
+
public static syncHistory<T>(scheduler_id: string, platform: string, params?: Record<string, any>): AxiosPromise<Response<T>> {
|
|
827
|
+
return Requests.processRoute(SchedulerRoute.routes.syncHistory, {}, { scheduler_id, platform }, params);
|
|
828
|
+
}
|
|
829
|
+
|
|
816
830
|
}
|
|
817
831
|
|
|
818
832
|
export default Scheduler;
|
package/src/api/ShortLinks.ts
CHANGED
|
@@ -132,6 +132,7 @@ class ShortLinks {
|
|
|
132
132
|
public static socialPostTrackingEffectiveness<T>(params?: Record<string, any>): AxiosPromise<Response<T>> {
|
|
133
133
|
return Requests.processRoute(ShortLinksRoute.routes.socialPostTrackingEffectiveness, undefined, undefined, params);
|
|
134
134
|
}
|
|
135
|
+
|
|
135
136
|
}
|
|
136
137
|
|
|
137
138
|
export default ShortLinks;
|
package/src/api/SocialPosts.ts
CHANGED
|
@@ -328,6 +328,19 @@ class SocialPosts {
|
|
|
328
328
|
return Requests.processRoute(SocialPostsRoute.routes.getLinkSummary, undefined, { post_id });
|
|
329
329
|
}
|
|
330
330
|
|
|
331
|
+
/**
|
|
332
|
+
* Trigger a historical sync for a specific platform for the current user.
|
|
333
|
+
*
|
|
334
|
+
* @see https://api.glitch.fun/api/documentation#/Social%20Media%20Posts/syncHistory
|
|
335
|
+
*
|
|
336
|
+
* @param platform The platform to sync (e.g., 'twitter', 'youtube', 'bluesky').
|
|
337
|
+
*
|
|
338
|
+
* @returns promise
|
|
339
|
+
*/
|
|
340
|
+
public static syncHistory<T>(platform: string, params?: Record<string, any>): AxiosPromise<Response<T>> {
|
|
341
|
+
return Requests.processRoute(SocialPostsRoute.routes.syncHistory, {}, { platform }, params);
|
|
342
|
+
}
|
|
343
|
+
|
|
331
344
|
}
|
|
332
345
|
|
|
333
346
|
export default SocialPosts;
|
|
@@ -124,6 +124,8 @@ class SchedulerRoute {
|
|
|
124
124
|
|
|
125
125
|
getConversionActions: { url: '/schedulers/{scheduler_id}/conversion-actions', method: HTTP_METHODS.GET },
|
|
126
126
|
|
|
127
|
+
syncHistory: { url: '/schedulers/{scheduler_id}/sync-history/{platform}', method: HTTP_METHODS.POST },
|
|
128
|
+
|
|
127
129
|
};
|
|
128
130
|
}
|
|
129
131
|
|
|
@@ -33,6 +33,8 @@ class SocialPostsRoute {
|
|
|
33
33
|
|
|
34
34
|
getPostAttribution: { url: '/socialposts/{post_id}/attribution', method: HTTP_METHODS.GET },
|
|
35
35
|
getSocialPostAttributionReport: { url: '/reports/fingerprinting/social-post-attribution', method: HTTP_METHODS.GET },
|
|
36
|
+
getLinkSummary: { url: '/socialposts/{post_id}/link-summary', method: HTTP_METHODS.GET },
|
|
37
|
+
syncHistory: { url: '/social/sync-history/{platform}', method: HTTP_METHODS.POST },
|
|
36
38
|
|
|
37
39
|
};
|
|
38
40
|
|