glitch-javascript-sdk 2.9.0 → 2.9.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 CHANGED
@@ -21985,6 +21985,7 @@ var UserRoutes = /** @class */ (function () {
21985
21985
  resendVerificationEmail: { url: '/users/resendVerificationEmail', method: HTTP_METHODS.POST },
21986
21986
  clearInstagramAuth: { url: '/users/clearInstagramAuth', method: HTTP_METHODS.DELETE },
21987
21987
  getSubredditRules: { url: "/users/reddit/redditrules/{subreddit}", method: HTTP_METHODS.GET },
21988
+ playedGames: { url: '/users/me/played-games', method: HTTP_METHODS.GET },
21988
21989
  };
21989
21990
  return UserRoutes;
21990
21991
  }());
@@ -22468,6 +22469,13 @@ var Users = /** @class */ (function () {
22468
22469
  Users.getSubredditRules = function (subreddit, params) {
22469
22470
  return Requests.processRoute(UserRoutes.routes.getSubredditRules, undefined, { subreddit: subreddit }, params);
22470
22471
  };
22472
+ /**
22473
+ * Get a list of games the current user has played.
22474
+ * Includes playtime and last played timestamps.
22475
+ */
22476
+ Users.playedGames = function (params) {
22477
+ return Requests.processRoute(UserRoutes.routes.playedGames, undefined, undefined, params);
22478
+ };
22471
22479
  return Users;
22472
22480
  }());
22473
22481
 
@@ -26754,6 +26762,8 @@ var SubscriptionsRoute = /** @class */ (function () {
26754
26762
  method: HTTP_METHODS.POST
26755
26763
  },
26756
26764
  purchaseLicense: { url: '/titles/{title_id}/purchase', method: HTTP_METHODS.POST },
26765
+ listMyLicenses: { url: '/subscriptions/my-licenses', method: HTTP_METHODS.GET },
26766
+ refundLicense: { url: '/subscriptions/licenses/{license_id}/refund', method: HTTP_METHODS.POST },
26757
26767
  };
26758
26768
  return SubscriptionsRoute;
26759
26769
  }());
@@ -26869,6 +26879,18 @@ var Subscriptions = /** @class */ (function () {
26869
26879
  Subscriptions.purchaseLicense = function (title_id, data) {
26870
26880
  return Requests.processRoute(SubscriptionsRoute.routes.purchaseLicense, data, { title_id: title_id });
26871
26881
  };
26882
+ /**
26883
+ * List all game licenses (Premium/Rental) owned by the current user.
26884
+ */
26885
+ Subscriptions.listMyLicenses = function (params) {
26886
+ return Requests.processRoute(SubscriptionsRoute.routes.listMyLicenses, undefined, undefined, params);
26887
+ };
26888
+ /**
26889
+ * Request a refund for a premium purchase.
26890
+ */
26891
+ Subscriptions.refundLicense = function (license_id) {
26892
+ return Requests.processRoute(SubscriptionsRoute.routes.refundLicense, {}, { license_id: license_id });
26893
+ };
26872
26894
  return Subscriptions;
26873
26895
  }());
26874
26896