glitch-javascript-sdk 3.7.0 → 3.8.1
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 +99 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/api/GameShows.d.ts +34 -0
- package/dist/esm/api/Scheduler.d.ts +100 -0
- package/dist/esm/index.js +99 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.ts +134 -0
- package/package.json +2 -2
- package/src/api/GameShows.ts +80 -0
- package/src/api/Scheduler.ts +122 -0
- package/src/routes/GameShowsRoute.ts +17 -0
- package/src/routes/SchedulerRoute.ts +2 -0
package/dist/cjs/index.js
CHANGED
|
@@ -27057,6 +27057,19 @@ var GameShowsRoute = /** @class */ (function () {
|
|
|
27057
27057
|
joinWishlist: { url: '/gameshows/{show_id}/wishlist', method: HTTP_METHODS.POST },
|
|
27058
27058
|
confirmWishlist: { url: '/gameshows/wishlist/confirm/{token}', method: HTTP_METHODS.GET },
|
|
27059
27059
|
listWishlist: { url: '/gameshows/{show_id}/wishlist', method: HTTP_METHODS.GET },
|
|
27060
|
+
// Festival awards, prizes, swag, metric leaderboards, and recipients.
|
|
27061
|
+
listPublicRewards: { url: '/gameshows/{show_id}/rewards', method: HTTP_METHODS.GET },
|
|
27062
|
+
getPublicReward: { url: '/gameshows/{show_id}/rewards/{reward_id}', method: HTTP_METHODS.GET },
|
|
27063
|
+
getPublicRewardLeaderboard: { url: '/gameshows/{show_id}/rewards/{reward_id}/leaderboard/public', method: HTTP_METHODS.GET },
|
|
27064
|
+
manageRewards: { url: '/gameshows/{show_id}/rewards/manage', method: HTTP_METHODS.GET },
|
|
27065
|
+
claimReward: { url: '/gameshows/{show_id}/rewards/{reward_id}/claim', method: HTTP_METHODS.POST },
|
|
27066
|
+
createReward: { url: '/gameshows/{show_id}/rewards', method: HTTP_METHODS.POST },
|
|
27067
|
+
updateReward: { url: '/gameshows/{show_id}/rewards/{reward_id}', method: HTTP_METHODS.PUT },
|
|
27068
|
+
deleteReward: { url: '/gameshows/{show_id}/rewards/{reward_id}', method: HTTP_METHODS.DELETE },
|
|
27069
|
+
rewardLeaderboard: { url: '/gameshows/{show_id}/rewards/{reward_id}/leaderboard', method: HTTP_METHODS.GET },
|
|
27070
|
+
autoAwardReward: { url: '/gameshows/{show_id}/rewards/{reward_id}/auto-award', method: HTTP_METHODS.POST },
|
|
27071
|
+
addRewardRecipient: { url: '/gameshows/{show_id}/rewards/{reward_id}/recipients', method: HTTP_METHODS.POST },
|
|
27072
|
+
updateRewardRecipient: { url: '/gameshows/{show_id}/rewards/{reward_id}/recipients/{recipient_id}', method: HTTP_METHODS.PUT },
|
|
27060
27073
|
listForTitle: { url: '/titles/{title_id}/gameshows', method: HTTP_METHODS.GET },
|
|
27061
27074
|
// Organizer sponsor lifecycle and placement administration.
|
|
27062
27075
|
listSponsors: { url: '/gameshows/{show_id}/sponsors', method: HTTP_METHODS.GET },
|
|
@@ -27076,6 +27089,10 @@ var GameShowsRoute = /** @class */ (function () {
|
|
|
27076
27089
|
sponsorInvitationSubmit: { url: '/gameshow-sponsor-invitations/{token}/submit', method: HTTP_METHODS.POST },
|
|
27077
27090
|
sponsorInvitationPayment: { url: '/gameshow-sponsor-invitations/{token}/payment', method: HTTP_METHODS.POST },
|
|
27078
27091
|
sponsorInvitationConfirmPayment: { url: '/gameshow-sponsor-invitations/{token}/payment/confirm', method: HTTP_METHODS.POST },
|
|
27092
|
+
sponsorInvitationRewards: { url: '/gameshow-sponsor-invitations/{token}/rewards', method: HTTP_METHODS.GET },
|
|
27093
|
+
sponsorInvitationCreateReward: { url: '/gameshow-sponsor-invitations/{token}/rewards', method: HTTP_METHODS.POST },
|
|
27094
|
+
sponsorInvitationUpdateReward: { url: '/gameshow-sponsor-invitations/{token}/rewards/{reward_id}', method: HTTP_METHODS.PUT },
|
|
27095
|
+
sponsorInvitationDeleteReward: { url: '/gameshow-sponsor-invitations/{token}/rewards/{reward_id}', method: HTTP_METHODS.DELETE },
|
|
27079
27096
|
};
|
|
27080
27097
|
return GameShowsRoute;
|
|
27081
27098
|
}());
|
|
@@ -27373,6 +27390,55 @@ var GameShows = /** @class */ (function () {
|
|
|
27373
27390
|
GameShows.listWishlist = function (show_id, params) {
|
|
27374
27391
|
return Requests.processRoute(GameShowsRoute.routes.listWishlist, {}, { show_id: show_id }, params);
|
|
27375
27392
|
};
|
|
27393
|
+
/** List the anonymous, published festival award/prize/swag catalog. */
|
|
27394
|
+
GameShows.listPublicRewards = function (show_id, params) {
|
|
27395
|
+
return Requests.processRoute(GameShowsRoute.routes.listPublicRewards, {}, { show_id: show_id }, params);
|
|
27396
|
+
};
|
|
27397
|
+
/** Retrieve one SSR-ready public festival reward. */
|
|
27398
|
+
GameShows.getPublicReward = function (show_id, reward_id, params) {
|
|
27399
|
+
return Requests.processRoute(GameShowsRoute.routes.getPublicReward, {}, { show_id: show_id, reward_id: reward_id }, params);
|
|
27400
|
+
};
|
|
27401
|
+
/** Retrieve a privacy-safe public game leaderboard for one reward. */
|
|
27402
|
+
GameShows.getPublicRewardLeaderboard = function (show_id, reward_id, params) {
|
|
27403
|
+
return Requests.processRoute(GameShowsRoute.routes.getPublicRewardLeaderboard, {}, { show_id: show_id, reward_id: reward_id }, params);
|
|
27404
|
+
};
|
|
27405
|
+
/** List drafts, sponsor items, inventory, recipients, and fulfillment for organizers. */
|
|
27406
|
+
GameShows.manageRewards = function (show_id, params) {
|
|
27407
|
+
return Requests.processRoute(GameShowsRoute.routes.manageRewards, {}, { show_id: show_id }, params);
|
|
27408
|
+
};
|
|
27409
|
+
/** Claim an eligible attendee, entrant, points, or previously awarded festival reward. */
|
|
27410
|
+
GameShows.claimReward = function (show_id, reward_id, data, params) {
|
|
27411
|
+
if (data === void 0) { data = {}; }
|
|
27412
|
+
return Requests.processRoute(GameShowsRoute.routes.claimReward, data, { show_id: show_id, reward_id: reward_id }, params);
|
|
27413
|
+
};
|
|
27414
|
+
/** Create an organizer-controlled festival award, prize, swag item, or reward. */
|
|
27415
|
+
GameShows.createReward = function (show_id, data, params) {
|
|
27416
|
+
return Requests.processRoute(GameShowsRoute.routes.createReward, data, { show_id: show_id }, params);
|
|
27417
|
+
};
|
|
27418
|
+
/** Update publication, eligibility, metrics, inventory, or rich content. */
|
|
27419
|
+
GameShows.updateReward = function (show_id, reward_id, data, params) {
|
|
27420
|
+
return Requests.processRoute(GameShowsRoute.routes.updateReward, data, { show_id: show_id, reward_id: reward_id }, params);
|
|
27421
|
+
};
|
|
27422
|
+
/** Soft-delete one festival reward. */
|
|
27423
|
+
GameShows.deleteReward = function (show_id, reward_id, params) {
|
|
27424
|
+
return Requests.processRoute(GameShowsRoute.routes.deleteReward, {}, { show_id: show_id, reward_id: reward_id }, params);
|
|
27425
|
+
};
|
|
27426
|
+
/** Preview the organizer-only game or attendee performance leaderboard. */
|
|
27427
|
+
GameShows.rewardLeaderboard = function (show_id, reward_id, params) {
|
|
27428
|
+
return Requests.processRoute(GameShowsRoute.routes.rewardLeaderboard, {}, { show_id: show_id, reward_id: reward_id }, params);
|
|
27429
|
+
};
|
|
27430
|
+
/** Snapshot current metric leaders as reward recipients. */
|
|
27431
|
+
GameShows.autoAwardReward = function (show_id, reward_id, params) {
|
|
27432
|
+
return Requests.processRoute(GameShowsRoute.routes.autoAwardReward, {}, { show_id: show_id, reward_id: reward_id }, params);
|
|
27433
|
+
};
|
|
27434
|
+
/** Add a manual nominee, winner, honoree, claimant, or fulfillment record. */
|
|
27435
|
+
GameShows.addRewardRecipient = function (show_id, reward_id, data, params) {
|
|
27436
|
+
return Requests.processRoute(GameShowsRoute.routes.addRewardRecipient, data, { show_id: show_id, reward_id: reward_id }, params);
|
|
27437
|
+
};
|
|
27438
|
+
/** Update judging, claim, revocation, rank, or fulfillment state. */
|
|
27439
|
+
GameShows.updateRewardRecipient = function (show_id, reward_id, recipient_id, data, params) {
|
|
27440
|
+
return Requests.processRoute(GameShowsRoute.routes.updateRewardRecipient, data, { show_id: show_id, reward_id: reward_id, recipient_id: recipient_id }, params);
|
|
27441
|
+
};
|
|
27376
27442
|
/**
|
|
27377
27443
|
* List public game shows that include a title. Useful for game-page festival banners.
|
|
27378
27444
|
*/
|
|
@@ -27461,6 +27527,22 @@ var GameShows = /** @class */ (function () {
|
|
|
27461
27527
|
GameShows.confirmSponsorInvitationPayment = function (token, params) {
|
|
27462
27528
|
return Requests.processRoute(GameShowsRoute.routes.sponsorInvitationConfirmPayment, {}, { token: token }, params);
|
|
27463
27529
|
};
|
|
27530
|
+
/** List awards, prizes, and swag owned by a sponsor invitation. */
|
|
27531
|
+
GameShows.sponsorInvitationRewards = function (token, params) {
|
|
27532
|
+
return Requests.processRoute(GameShowsRoute.routes.sponsorInvitationRewards, {}, { token: token }, params);
|
|
27533
|
+
};
|
|
27534
|
+
/** Create a draft sponsor-owned award, prize, or swag item. */
|
|
27535
|
+
GameShows.createSponsorInvitationReward = function (token, data, params) {
|
|
27536
|
+
return Requests.processRoute(GameShowsRoute.routes.sponsorInvitationCreateReward, data, { token: token }, params);
|
|
27537
|
+
};
|
|
27538
|
+
/** Update sponsor-owned reward content and eligibility. */
|
|
27539
|
+
GameShows.updateSponsorInvitationReward = function (token, reward_id, data, params) {
|
|
27540
|
+
return Requests.processRoute(GameShowsRoute.routes.sponsorInvitationUpdateReward, data, { token: token, reward_id: reward_id }, params);
|
|
27541
|
+
};
|
|
27542
|
+
/** Remove a sponsor-owned draft reward. */
|
|
27543
|
+
GameShows.deleteSponsorInvitationReward = function (token, reward_id, params) {
|
|
27544
|
+
return Requests.processRoute(GameShowsRoute.routes.sponsorInvitationDeleteReward, {}, { token: token, reward_id: reward_id }, params);
|
|
27545
|
+
};
|
|
27464
27546
|
return GameShows;
|
|
27465
27547
|
}());
|
|
27466
27548
|
|
|
@@ -28173,6 +28255,8 @@ var SchedulerRoute = /** @class */ (function () {
|
|
|
28173
28255
|
getRedditSubredditFlairs: { url: '/schedulers/{scheduler_id}/reddit/subreddits/{subreddit}/flairs', method: HTTP_METHODS.GET },
|
|
28174
28256
|
getRedditSubredditRules: { url: '/schedulers/{scheduler_id}/reddit/subreddits/{subreddit}/rules', method: HTTP_METHODS.GET },
|
|
28175
28257
|
getDiscordChannels: { url: '/schedulers/{scheduler_id}/discord/channels', method: HTTP_METHODS.GET },
|
|
28258
|
+
searchDiscordMedia: { url: '/schedulers/{scheduler_id}/discord/media', method: HTTP_METHODS.GET },
|
|
28259
|
+
importDiscordMedia: { url: '/schedulers/{scheduler_id}/discord/media/import', method: HTTP_METHODS.POST },
|
|
28176
28260
|
crossPromoteListRelationships: {
|
|
28177
28261
|
url: '/schedulers/{scheduler_id}/crosspromote/relationships',
|
|
28178
28262
|
method: HTTP_METHODS.GET
|
|
@@ -28669,6 +28753,21 @@ var Scheduler = /** @class */ (function () {
|
|
|
28669
28753
|
Scheduler.getDiscordChannels = function (scheduler_id, params) {
|
|
28670
28754
|
return Requests.processRoute(SchedulerRoute.routes.getDiscordChannels, {}, { scheduler_id: scheduler_id }, params);
|
|
28671
28755
|
};
|
|
28756
|
+
/**
|
|
28757
|
+
* Search image and video attachments in the connected Discord server.
|
|
28758
|
+
* This call only returns remote candidates; it does not copy files into the
|
|
28759
|
+
* Library and does not create or schedule social posts.
|
|
28760
|
+
*/
|
|
28761
|
+
Scheduler.searchDiscordMedia = function (scheduler_id, params) {
|
|
28762
|
+
return Requests.processRoute(SchedulerRoute.routes.searchDiscordMedia, {}, { scheduler_id: scheduler_id }, params);
|
|
28763
|
+
};
|
|
28764
|
+
/**
|
|
28765
|
+
* Import explicitly selected Discord attachments as pending, unscheduled
|
|
28766
|
+
* Library updates. Attachments selected from one message stay grouped.
|
|
28767
|
+
*/
|
|
28768
|
+
Scheduler.importDiscordMedia = function (scheduler_id, data, params) {
|
|
28769
|
+
return Requests.processRoute(SchedulerRoute.routes.importDiscordMedia, data, { scheduler_id: scheduler_id }, params);
|
|
28770
|
+
};
|
|
28672
28771
|
/**
|
|
28673
28772
|
* Clear Google Ads OAuth credentials from a promotion schedule.
|
|
28674
28773
|
*
|