glitch-javascript-sdk 3.4.0 → 3.5.0

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.
@@ -97,11 +97,29 @@ declare class GameShows {
97
97
  * Register a title to a game show.
98
98
  */
99
99
  static registerTitle<T>(show_id: string, data: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
100
+ /** List the active ordered custom-question schema used by public registration. */
101
+ static listRegistrationQuestions<T>(show_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
102
+ /** List active, inactive, and archived custom questions for organizers. */
103
+ static manageRegistrationQuestions<T>(show_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
104
+ /** Create one schema-driven custom developer-registration question. */
105
+ static createRegistrationQuestion<T>(show_id: string, data: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
106
+ /** Update wording, validation, visibility, ordering, or stable choices. */
107
+ static updateRegistrationQuestion<T>(show_id: string, question_id: string, data: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
108
+ /** Archive a question while preserving historical answers and reporting. */
109
+ static deleteRegistrationQuestion<T>(show_id: string, question_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
110
+ /** Apply the organizer's exact ordered list of question UUIDs. */
111
+ static reorderRegistrationQuestions<T>(show_id: string, data: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
112
+ /** Review custom answers grouped by submitted game. */
113
+ static listRegistrationResponses<T>(show_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
114
+ /** Retrieve type-aware aggregate reports without exposing free-text values. */
115
+ static registrationQuestionReports<T>(show_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
100
116
  /**
101
117
  * Add a title to a game show by admin.
102
118
  */
103
119
  static addTitle<T>(show_id: string, data: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
120
+ /** Preview CSV/TSV/TXT/ZIP registrations without writing showcase data. */
104
121
  static previewExternalTitles<T>(show_id: string, file: File, data?: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
122
+ /** Import valid external registrations after organizer preview. */
105
123
  static importExternalTitles<T>(show_id: string, file: File, data?: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
106
124
  /**
107
125
  * List all titles for a game show.
@@ -179,20 +197,35 @@ declare class GameShows {
179
197
  * List public game shows that include a title. Useful for game-page festival banners.
180
198
  */
181
199
  static listForTitle<T>(title_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
200
+ /** List private sponsor workflow, contact, billing, media, and placements. */
182
201
  static listSponsors<T>(show_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
202
+ /** Create a manual sponsor or send a self-service invitation. */
183
203
  static createSponsor<T>(show_id: string, data: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
204
+ /** Retrieve one organizer-authorized festival sponsor. */
184
205
  static getSponsor<T>(show_id: string, sponsor_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
206
+ /** Update sponsor workflow, creative metadata, schedule, or billing terms. */
185
207
  static updateSponsor<T>(show_id: string, sponsor_id: string, data: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
208
+ /** Delete an unpaid sponsor and its placements. */
186
209
  static deleteSponsor<T>(show_id: string, sponsor_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
210
+ /** Replace the private token and resend the sponsor invitation. */
187
211
  static resendSponsorInvitation<T>(show_id: string, sponsor_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
212
+ /** Add another festival, game, session, or event placement. */
188
213
  static createSponsorPlacement<T>(show_id: string, sponsor_id: string, data: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
214
+ /** Partially update an existing sponsor placement. */
189
215
  static updateSponsorPlacement<T>(show_id: string, sponsor_id: string, placement_id: string, data: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
216
+ /** Delete one placement without deleting the sponsor creative. */
190
217
  static deleteSponsorPlacement<T>(show_id: string, sponsor_id: string, placement_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
218
+ /** List privacy-limited, publicly eligible creatives and placements. */
191
219
  static listPublicSponsors<T>(show_id: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
220
+ /** Open a token-protected sponsor portal without a user session. */
192
221
  static sponsorInvitation<T>(token: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
222
+ /** Upload sponsor image/video through the shared Media pipeline. */
193
223
  static uploadSponsorInvitationMedia<T>(token: string, file: File, data?: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
224
+ /** Submit sponsor identity, destination, and accessibility metadata. */
194
225
  static submitSponsorInvitation<T>(token: string, data: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
226
+ /** Create/confirm a destination PaymentIntent from a PaymentMethod ID. */
195
227
  static paySponsorInvitation<T>(token: string, data: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
228
+ /** Synchronize the same intent after Stripe.js completes required 3DS. */
196
229
  static confirmSponsorInvitationPayment<T>(token: string, params?: Record<string, any>): AxiosPromise<Response<T>>;
197
230
  }
198
231
  export default GameShows;
package/dist/esm/index.js CHANGED
@@ -15007,6 +15007,10 @@ var Publications = /** @class */ (function () {
15007
15007
  var GameShowsRoute = /** @class */ (function () {
15008
15008
  function GameShowsRoute() {
15009
15009
  }
15010
+ /**
15011
+ * Canonical API route templates. JSON routes are substituted by
15012
+ * Requests.processRoute; multipart methods replace tokens before upload.
15013
+ */
15010
15014
  GameShowsRoute.routes = {
15011
15015
  list: { url: '/gameshows', method: HTTP_METHODS.GET },
15012
15016
  create: { url: '/gameshows', method: HTTP_METHODS.POST },
@@ -15016,8 +15020,18 @@ var GameShowsRoute = /** @class */ (function () {
15016
15020
  uploadLogo: { url: '/gameshows/{show_id}/uploadLogo', method: HTTP_METHODS.POST },
15017
15021
  uploadBannerImage: { url: '/gameshows/{show_id}/uploadBannerImage', method: HTTP_METHODS.POST },
15018
15022
  registerTitle: { url: '/gameshows/{show_id}/registerTitle', method: HTTP_METHODS.POST },
15023
+ // Schema-driven developer registration questions and organizer reports.
15024
+ listRegistrationQuestions: { url: '/gameshows/{show_id}/registration-questions', method: HTTP_METHODS.GET },
15025
+ manageRegistrationQuestions: { url: '/gameshows/{show_id}/registration-form/questions', method: HTTP_METHODS.GET },
15026
+ createRegistrationQuestion: { url: '/gameshows/{show_id}/registration-form/questions', method: HTTP_METHODS.POST },
15027
+ updateRegistrationQuestion: { url: '/gameshows/{show_id}/registration-form/questions/{question_id}', method: HTTP_METHODS.PUT },
15028
+ deleteRegistrationQuestion: { url: '/gameshows/{show_id}/registration-form/questions/{question_id}', method: HTTP_METHODS.DELETE },
15029
+ reorderRegistrationQuestions: { url: '/gameshows/{show_id}/registration-form/questions/reorder', method: HTTP_METHODS.POST },
15030
+ listRegistrationResponses: { url: '/gameshows/{show_id}/registration-form/responses', method: HTTP_METHODS.GET },
15031
+ registrationQuestionReports: { url: '/gameshows/{show_id}/registration-form/reports', method: HTTP_METHODS.GET },
15019
15032
  listTitles: { url: '/gameshows/{show_id}/titles', method: HTTP_METHODS.GET },
15020
15033
  addTitle: { url: '/gameshows/{show_id}/addTitle', method: HTTP_METHODS.POST },
15034
+ // External registration file preview/import endpoints.
15021
15035
  previewExternalTitles: { url: '/gameshows/{show_id}/external-titles/preview', method: HTTP_METHODS.POST },
15022
15036
  importExternalTitles: { url: '/gameshows/{show_id}/external-titles/import', method: HTTP_METHODS.POST },
15023
15037
  viewTitle: { url: '/gameshows/{show_id}/titles/{title_id}', method: HTTP_METHODS.GET },
@@ -15038,6 +15052,7 @@ var GameShowsRoute = /** @class */ (function () {
15038
15052
  joinWishlist: { url: '/gameshows/{show_id}/wishlist', method: HTTP_METHODS.POST },
15039
15053
  listWishlist: { url: '/gameshows/{show_id}/wishlist', method: HTTP_METHODS.GET },
15040
15054
  listForTitle: { url: '/titles/{title_id}/gameshows', method: HTTP_METHODS.GET },
15055
+ // Organizer sponsor lifecycle and placement administration.
15041
15056
  listSponsors: { url: '/gameshows/{show_id}/sponsors', method: HTTP_METHODS.GET },
15042
15057
  createSponsor: { url: '/gameshows/{show_id}/sponsors', method: HTTP_METHODS.POST },
15043
15058
  getSponsor: { url: '/gameshows/{show_id}/sponsors/{sponsor_id}', method: HTTP_METHODS.GET },
@@ -15047,7 +15062,9 @@ var GameShowsRoute = /** @class */ (function () {
15047
15062
  createSponsorPlacement: { url: '/gameshows/{show_id}/sponsors/{sponsor_id}/placements', method: HTTP_METHODS.POST },
15048
15063
  updateSponsorPlacement: { url: '/gameshows/{show_id}/sponsors/{sponsor_id}/placements/{placement_id}', method: HTTP_METHODS.PUT },
15049
15064
  deleteSponsorPlacement: { url: '/gameshows/{show_id}/sponsors/{sponsor_id}/placements/{placement_id}', method: HTTP_METHODS.DELETE },
15065
+ // Privacy-limited anonymous sponsor inventory.
15050
15066
  listPublicSponsors: { url: '/gameshows/{show_id}/sponsors/public', method: HTTP_METHODS.GET },
15067
+ // Token-protected sponsor self-service; backend applies per-route limits.
15051
15068
  sponsorInvitation: { url: '/gameshow-sponsor-invitations/{token}', method: HTTP_METHODS.GET },
15052
15069
  sponsorInvitationUpload: { url: '/gameshow-sponsor-invitations/{token}/media', method: HTTP_METHODS.POST },
15053
15070
  sponsorInvitationSubmit: { url: '/gameshow-sponsor-invitations/{token}/submit', method: HTTP_METHODS.POST },
@@ -15180,16 +15197,51 @@ var GameShows = /** @class */ (function () {
15180
15197
  GameShows.registerTitle = function (show_id, data, params) {
15181
15198
  return Requests.processRoute(GameShowsRoute.routes.registerTitle, data, { show_id: show_id }, params);
15182
15199
  };
15200
+ /** List the active ordered custom-question schema used by public registration. */
15201
+ GameShows.listRegistrationQuestions = function (show_id, params) {
15202
+ return Requests.processRoute(GameShowsRoute.routes.listRegistrationQuestions, {}, { show_id: show_id }, params);
15203
+ };
15204
+ /** List active, inactive, and archived custom questions for organizers. */
15205
+ GameShows.manageRegistrationQuestions = function (show_id, params) {
15206
+ return Requests.processRoute(GameShowsRoute.routes.manageRegistrationQuestions, {}, { show_id: show_id }, params);
15207
+ };
15208
+ /** Create one schema-driven custom developer-registration question. */
15209
+ GameShows.createRegistrationQuestion = function (show_id, data, params) {
15210
+ return Requests.processRoute(GameShowsRoute.routes.createRegistrationQuestion, data, { show_id: show_id }, params);
15211
+ };
15212
+ /** Update wording, validation, visibility, ordering, or stable choices. */
15213
+ GameShows.updateRegistrationQuestion = function (show_id, question_id, data, params) {
15214
+ return Requests.processRoute(GameShowsRoute.routes.updateRegistrationQuestion, data, { show_id: show_id, question_id: question_id }, params);
15215
+ };
15216
+ /** Archive a question while preserving historical answers and reporting. */
15217
+ GameShows.deleteRegistrationQuestion = function (show_id, question_id, params) {
15218
+ return Requests.processRoute(GameShowsRoute.routes.deleteRegistrationQuestion, {}, { show_id: show_id, question_id: question_id }, params);
15219
+ };
15220
+ /** Apply the organizer's exact ordered list of question UUIDs. */
15221
+ GameShows.reorderRegistrationQuestions = function (show_id, data, params) {
15222
+ return Requests.processRoute(GameShowsRoute.routes.reorderRegistrationQuestions, data, { show_id: show_id }, params);
15223
+ };
15224
+ /** Review custom answers grouped by submitted game. */
15225
+ GameShows.listRegistrationResponses = function (show_id, params) {
15226
+ return Requests.processRoute(GameShowsRoute.routes.listRegistrationResponses, {}, { show_id: show_id }, params);
15227
+ };
15228
+ /** Retrieve type-aware aggregate reports without exposing free-text values. */
15229
+ GameShows.registrationQuestionReports = function (show_id, params) {
15230
+ return Requests.processRoute(GameShowsRoute.routes.registrationQuestionReports, {}, { show_id: show_id }, params);
15231
+ };
15183
15232
  /**
15184
15233
  * Add a title to a game show by admin.
15185
15234
  */
15186
15235
  GameShows.addTitle = function (show_id, data, params) {
15187
15236
  return Requests.processRoute(GameShowsRoute.routes.addTitle, data, { show_id: show_id }, params);
15188
15237
  };
15238
+ /** Preview CSV/TSV/TXT/ZIP registrations without writing showcase data. */
15189
15239
  GameShows.previewExternalTitles = function (show_id, file, data, params) {
15240
+ // Multipart helpers require the concrete URL before uploading.
15190
15241
  var url = GameShowsRoute.routes.previewExternalTitles.url.replace('{show_id}', show_id);
15191
15242
  return Requests.uploadFile(url, 'file', file, data, params);
15192
15243
  };
15244
+ /** Import valid external registrations after organizer preview. */
15193
15245
  GameShows.importExternalTitles = function (show_id, file, data, params) {
15194
15246
  var url = GameShowsRoute.routes.importExternalTitles.url.replace('{show_id}', show_id);
15195
15247
  return Requests.uploadFile(url, 'file', file, data, params);
@@ -15308,49 +15360,65 @@ var GameShows = /** @class */ (function () {
15308
15360
  GameShows.listForTitle = function (title_id, params) {
15309
15361
  return Requests.processRoute(GameShowsRoute.routes.listForTitle, {}, { title_id: title_id }, params);
15310
15362
  };
15363
+ /** List private sponsor workflow, contact, billing, media, and placements. */
15311
15364
  GameShows.listSponsors = function (show_id, params) {
15312
15365
  return Requests.processRoute(GameShowsRoute.routes.listSponsors, {}, { show_id: show_id }, params);
15313
15366
  };
15367
+ /** Create a manual sponsor or send a self-service invitation. */
15314
15368
  GameShows.createSponsor = function (show_id, data, params) {
15315
15369
  return Requests.processRoute(GameShowsRoute.routes.createSponsor, data, { show_id: show_id }, params);
15316
15370
  };
15371
+ /** Retrieve one organizer-authorized festival sponsor. */
15317
15372
  GameShows.getSponsor = function (show_id, sponsor_id, params) {
15318
15373
  return Requests.processRoute(GameShowsRoute.routes.getSponsor, {}, { show_id: show_id, sponsor_id: sponsor_id }, params);
15319
15374
  };
15375
+ /** Update sponsor workflow, creative metadata, schedule, or billing terms. */
15320
15376
  GameShows.updateSponsor = function (show_id, sponsor_id, data, params) {
15321
15377
  return Requests.processRoute(GameShowsRoute.routes.updateSponsor, data, { show_id: show_id, sponsor_id: sponsor_id }, params);
15322
15378
  };
15379
+ /** Delete an unpaid sponsor and its placements. */
15323
15380
  GameShows.deleteSponsor = function (show_id, sponsor_id, params) {
15324
15381
  return Requests.processRoute(GameShowsRoute.routes.deleteSponsor, {}, { show_id: show_id, sponsor_id: sponsor_id }, params);
15325
15382
  };
15383
+ /** Replace the private token and resend the sponsor invitation. */
15326
15384
  GameShows.resendSponsorInvitation = function (show_id, sponsor_id, params) {
15327
15385
  return Requests.processRoute(GameShowsRoute.routes.resendSponsorInvitation, {}, { show_id: show_id, sponsor_id: sponsor_id }, params);
15328
15386
  };
15387
+ /** Add another festival, game, session, or event placement. */
15329
15388
  GameShows.createSponsorPlacement = function (show_id, sponsor_id, data, params) {
15330
15389
  return Requests.processRoute(GameShowsRoute.routes.createSponsorPlacement, data, { show_id: show_id, sponsor_id: sponsor_id }, params);
15331
15390
  };
15391
+ /** Partially update an existing sponsor placement. */
15332
15392
  GameShows.updateSponsorPlacement = function (show_id, sponsor_id, placement_id, data, params) {
15333
15393
  return Requests.processRoute(GameShowsRoute.routes.updateSponsorPlacement, data, { show_id: show_id, sponsor_id: sponsor_id, placement_id: placement_id }, params);
15334
15394
  };
15395
+ /** Delete one placement without deleting the sponsor creative. */
15335
15396
  GameShows.deleteSponsorPlacement = function (show_id, sponsor_id, placement_id, params) {
15336
15397
  return Requests.processRoute(GameShowsRoute.routes.deleteSponsorPlacement, {}, { show_id: show_id, sponsor_id: sponsor_id, placement_id: placement_id }, params);
15337
15398
  };
15399
+ /** List privacy-limited, publicly eligible creatives and placements. */
15338
15400
  GameShows.listPublicSponsors = function (show_id, params) {
15339
15401
  return Requests.processRoute(GameShowsRoute.routes.listPublicSponsors, {}, { show_id: show_id }, params);
15340
15402
  };
15403
+ /** Open a token-protected sponsor portal without a user session. */
15341
15404
  GameShows.sponsorInvitation = function (token, params) {
15342
15405
  return Requests.processRoute(GameShowsRoute.routes.sponsorInvitation, {}, { token: token }, params);
15343
15406
  };
15407
+ /** Upload sponsor image/video through the shared Media pipeline. */
15344
15408
  GameShows.uploadSponsorInvitationMedia = function (token, file, data, params) {
15409
+ // Sponsor uploads use the `media` multipart field documented by API.
15345
15410
  var url = GameShowsRoute.routes.sponsorInvitationUpload.url.replace('{token}', token);
15346
15411
  return Requests.uploadFile(url, 'media', file, data, params);
15347
15412
  };
15413
+ /** Submit sponsor identity, destination, and accessibility metadata. */
15348
15414
  GameShows.submitSponsorInvitation = function (token, data, params) {
15349
15415
  return Requests.processRoute(GameShowsRoute.routes.sponsorInvitationSubmit, data, { token: token }, params);
15350
15416
  };
15417
+ /** Create/confirm a destination PaymentIntent from a PaymentMethod ID. */
15351
15418
  GameShows.paySponsorInvitation = function (token, data, params) {
15352
15419
  return Requests.processRoute(GameShowsRoute.routes.sponsorInvitationPayment, data, { token: token }, params);
15353
15420
  };
15421
+ /** Synchronize the same intent after Stripe.js completes required 3DS. */
15354
15422
  GameShows.confirmSponsorInvitationPayment = function (token, params) {
15355
15423
  return Requests.processRoute(GameShowsRoute.routes.sponsorInvitationConfirmPayment, {}, { token: token }, params);
15356
15424
  };