glitch-javascript-sdk 2.4.3 → 2.4.6
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 +86 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/api/Campaigns.d.ts +10 -0
- package/dist/esm/api/SocialPosts.d.ts +50 -0
- package/dist/esm/api/Titles.d.ts +1 -0
- package/dist/esm/index.js +86 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.ts +61 -0
- package/package.json +1 -1
- package/src/api/Campaigns.ts +10 -0
- package/src/api/SocialPosts.ts +68 -0
- package/src/api/Titles.ts +4 -0
- package/src/routes/CampaignsRoute.ts +4 -0
- package/src/routes/SocialPostsRoute.ts +10 -0
- package/src/routes/TitlesRoute.ts +2 -0
package/dist/cjs/index.js
CHANGED
|
@@ -24137,6 +24137,13 @@ var SocialPostsRoute = /** @class */ (function () {
|
|
|
24137
24137
|
syncHistory: { url: '/social/sync-history/{platform}', method: HTTP_METHODS.POST },
|
|
24138
24138
|
performAction: { url: '/socialposts/{post_id}/action', method: HTTP_METHODS.POST },
|
|
24139
24139
|
performCommentAction: { url: '/socialposts/comments/{comment_id}/action', method: HTTP_METHODS.POST },
|
|
24140
|
+
creativePerformance: { url: '/socialposts/creative-performance', method: HTTP_METHODS.GET },
|
|
24141
|
+
// Social Messaging (DM) Routes
|
|
24142
|
+
listConversations: { url: '/social/conversations', method: HTTP_METHODS.GET },
|
|
24143
|
+
syncConversations: { url: '/social/conversations/sync', method: HTTP_METHODS.POST },
|
|
24144
|
+
getConversation: { url: '/social/conversations/{conversation_id}', method: HTTP_METHODS.GET },
|
|
24145
|
+
getConversationMessages: { url: '/social/conversations/{conversation_id}/messages', method: HTTP_METHODS.GET },
|
|
24146
|
+
sendSocialMessage: { url: '/social/messages', method: HTTP_METHODS.POST },
|
|
24140
24147
|
};
|
|
24141
24148
|
return SocialPostsRoute;
|
|
24142
24149
|
}());
|
|
@@ -24462,6 +24469,68 @@ var SocialPosts = /** @class */ (function () {
|
|
|
24462
24469
|
SocialPosts.performCommentAction = function (comment_id, action) {
|
|
24463
24470
|
return Requests.processRoute(SocialPostsRoute.routes.performCommentAction, { action: action }, { comment_id: comment_id });
|
|
24464
24471
|
};
|
|
24472
|
+
/**
|
|
24473
|
+
* Get ad creative performance matrix.
|
|
24474
|
+
*/
|
|
24475
|
+
SocialPosts.creativePerformance = function (params) {
|
|
24476
|
+
return Requests.processRoute(SocialPostsRoute.routes.creativePerformance, {}, {}, params);
|
|
24477
|
+
};
|
|
24478
|
+
/**
|
|
24479
|
+
* List social media conversations.
|
|
24480
|
+
*
|
|
24481
|
+
* @see https://api.glitch.fun/api/documentation#/Social%20Messaging/listSocialConversations
|
|
24482
|
+
*
|
|
24483
|
+
* @param params Query parameters (scheduler_id, platform, page, per_page).
|
|
24484
|
+
* @returns promise
|
|
24485
|
+
*/
|
|
24486
|
+
SocialPosts.listConversations = function (params) {
|
|
24487
|
+
return Requests.processRoute(SocialPostsRoute.routes.listConversations, undefined, undefined, params);
|
|
24488
|
+
};
|
|
24489
|
+
/**
|
|
24490
|
+
* Sync conversations from external platform.
|
|
24491
|
+
*
|
|
24492
|
+
* @see https://api.glitch.fun/api/documentation#/Social%20Messaging/syncSocialConversations
|
|
24493
|
+
*
|
|
24494
|
+
* @param data Body parameters (platform, scheduler_id).
|
|
24495
|
+
* @returns promise
|
|
24496
|
+
*/
|
|
24497
|
+
SocialPosts.syncConversations = function (data) {
|
|
24498
|
+
return Requests.processRoute(SocialPostsRoute.routes.syncConversations, data);
|
|
24499
|
+
};
|
|
24500
|
+
/**
|
|
24501
|
+
* Get a specific conversation.
|
|
24502
|
+
*
|
|
24503
|
+
* @see https://api.glitch.fun/api/documentation#/Social%20Messaging/getSocialConversation
|
|
24504
|
+
*
|
|
24505
|
+
* @param conversation_id The ID of the conversation.
|
|
24506
|
+
* @returns promise
|
|
24507
|
+
*/
|
|
24508
|
+
SocialPosts.getConversation = function (conversation_id) {
|
|
24509
|
+
return Requests.processRoute(SocialPostsRoute.routes.getConversation, undefined, { conversation_id: conversation_id });
|
|
24510
|
+
};
|
|
24511
|
+
/**
|
|
24512
|
+
* List messages in a conversation.
|
|
24513
|
+
*
|
|
24514
|
+
* @see https://api.glitch.fun/api/documentation#/Social%20Messaging/listSocialMessages
|
|
24515
|
+
*
|
|
24516
|
+
* @param conversation_id The ID of the conversation.
|
|
24517
|
+
* @param params Query parameters (sync, page, per_page).
|
|
24518
|
+
* @returns promise
|
|
24519
|
+
*/
|
|
24520
|
+
SocialPosts.getConversationMessages = function (conversation_id, params) {
|
|
24521
|
+
return Requests.processRoute(SocialPostsRoute.routes.getConversationMessages, undefined, { conversation_id: conversation_id }, params);
|
|
24522
|
+
};
|
|
24523
|
+
/**
|
|
24524
|
+
* Send a Direct Message.
|
|
24525
|
+
*
|
|
24526
|
+
* @see https://api.glitch.fun/api/documentation#/Social%20Messaging/sendSocialMessage
|
|
24527
|
+
*
|
|
24528
|
+
* @param data Body parameters (message, conversation_id, recipient_id, platform, scheduler_id, media_ids).
|
|
24529
|
+
* @returns promise
|
|
24530
|
+
*/
|
|
24531
|
+
SocialPosts.sendSocialMessage = function (data) {
|
|
24532
|
+
return Requests.processRoute(SocialPostsRoute.routes.sendSocialMessage, data);
|
|
24533
|
+
};
|
|
24465
24534
|
return SocialPosts;
|
|
24466
24535
|
}());
|
|
24467
24536
|
|
|
@@ -24615,6 +24684,7 @@ var TitlesRoute = /** @class */ (function () {
|
|
|
24615
24684
|
translateLandingPage: { url: '/landing-pages/{landing_page_id}/translate', method: HTTP_METHODS.POST },
|
|
24616
24685
|
generateLandingPageAiContent: { url: '/landing-pages/{landing_page_id}/generate-ai-content', method: HTTP_METHODS.POST },
|
|
24617
24686
|
saveLandingPageTranslation: { url: '/landing-pages/{landing_page_id}/translations', method: HTTP_METHODS.POST },
|
|
24687
|
+
cohorts: { url: '/titles/{title_id}/installs/cohorts', method: HTTP_METHODS.GET },
|
|
24618
24688
|
};
|
|
24619
24689
|
return TitlesRoute;
|
|
24620
24690
|
}());
|
|
@@ -25161,6 +25231,9 @@ var Titles = /** @class */ (function () {
|
|
|
25161
25231
|
Titles.saveLandingPageTranslation = function (landing_page_id, translationData, params) {
|
|
25162
25232
|
return Requests.processRoute(TitlesRoute.routes.saveLandingPageTranslation, translationData, { landing_page_id: landing_page_id }, params);
|
|
25163
25233
|
};
|
|
25234
|
+
Titles.cohorts = function (title_id, params) {
|
|
25235
|
+
return Requests.processRoute(TitlesRoute.routes.cohorts, {}, { title_id: title_id }, params);
|
|
25236
|
+
};
|
|
25164
25237
|
/**
|
|
25165
25238
|
* Get an aggregated report of ad conversion events for charting.
|
|
25166
25239
|
*/
|
|
@@ -25264,6 +25337,10 @@ var CampaignsRoute = /** @class */ (function () {
|
|
|
25264
25337
|
url: '/campaigns/{campaign_id}/influencers/{user_id}/landing-page',
|
|
25265
25338
|
method: HTTP_METHODS.PUT
|
|
25266
25339
|
},
|
|
25340
|
+
exportInfluencerInvites: {
|
|
25341
|
+
url: '/campaigns/{campaign_id}/influencers/invites/export',
|
|
25342
|
+
method: HTTP_METHODS.POST
|
|
25343
|
+
},
|
|
25267
25344
|
};
|
|
25268
25345
|
return CampaignsRoute;
|
|
25269
25346
|
}());
|
|
@@ -26145,6 +26222,15 @@ var Campaigns = /** @class */ (function () {
|
|
|
26145
26222
|
Campaigns.updateInfluencerLandingPage = function (campaign_id, user_id, data) {
|
|
26146
26223
|
return Requests.processRoute(CampaignsRoute.routes.updateInfluencerLandingPage, data, { campaign_id: campaign_id, user_id: user_id });
|
|
26147
26224
|
};
|
|
26225
|
+
/**
|
|
26226
|
+
* Export influencer invites to CSV.
|
|
26227
|
+
*
|
|
26228
|
+
* @param campaign_id The UUID of the campaign.
|
|
26229
|
+
* @param data Filters for the export (stages, status).
|
|
26230
|
+
*/
|
|
26231
|
+
Campaigns.exportInfluencerInvites = function (campaign_id, data) {
|
|
26232
|
+
return Requests.processRoute(CampaignsRoute.routes.exportInfluencerInvites, data, { campaign_id: campaign_id });
|
|
26233
|
+
};
|
|
26148
26234
|
return Campaigns;
|
|
26149
26235
|
}());
|
|
26150
26236
|
|