glitch-javascript-sdk 0.5.3 → 0.5.4
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 +29 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/api/Events.d.ts +23 -0
- package/dist/esm/index.js +29 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.ts +23 -0
- package/package.json +1 -1
- package/src/api/Events.ts +32 -0
- package/src/routes/EventsRoute.ts +2 -2
package/dist/esm/api/Events.d.ts
CHANGED
|
@@ -299,5 +299,28 @@ declare class Events {
|
|
|
299
299
|
* @returns promise
|
|
300
300
|
*/
|
|
301
301
|
static updateRecording<T>(event_id: string, recording_id: string, data: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
302
|
+
/**
|
|
303
|
+
* Enable a widget for the current event.
|
|
304
|
+
*
|
|
305
|
+
* @see https://api.glitch.fun/api/documentation#/Event%20Route/updateEventRecording
|
|
306
|
+
*
|
|
307
|
+
* @param event_id The id of the event to update.
|
|
308
|
+
* @param widget_id The id of the widget to enable.
|
|
309
|
+
* @param data The data, which should contain the roles.
|
|
310
|
+
*
|
|
311
|
+
* @returns promise
|
|
312
|
+
*/
|
|
313
|
+
static enableWidget<T>(event_id: string, widget_id: string, data: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
314
|
+
/**
|
|
315
|
+
* Disable a widget for the current event.
|
|
316
|
+
*
|
|
317
|
+
* @see https://api.glitch.fun/api/documentation#/Event%20Route/updateEventRecording
|
|
318
|
+
*
|
|
319
|
+
* @param event_id The id of the event to update.
|
|
320
|
+
* @param widget_id The id of the widget to disable.
|
|
321
|
+
*
|
|
322
|
+
* @returns promise
|
|
323
|
+
*/
|
|
324
|
+
static disableWidget<T>(event_id: string, widget_id: string, data: object, params?: Record<string, any>): AxiosPromise<Response<T>>;
|
|
302
325
|
}
|
|
303
326
|
export default Events;
|
package/dist/esm/index.js
CHANGED
|
@@ -31574,6 +31574,8 @@ var EventsRoutes = /** @class */ (function () {
|
|
|
31574
31574
|
addTwitchMulticast: { url: '/events/{event_id}/addTwitchMulticast', method: HTTP_METHODS.POST },
|
|
31575
31575
|
addFacebookMulticast: { url: '/events/{event_id}/addFacebookMulticast', method: HTTP_METHODS.POST },
|
|
31576
31576
|
addYoutubeMulticast: { url: '/events/{event_id}/addYoutubeMulticast', method: HTTP_METHODS.POST },
|
|
31577
|
+
enableWidget: { url: '/events/{event_id}/enableWidget/{widget_id}', method: HTTP_METHODS.POST },
|
|
31578
|
+
disableWidget: { url: '/events/{event_id}/disableWidget/{widget_id}', method: HTTP_METHODS.DELETE },
|
|
31577
31579
|
};
|
|
31578
31580
|
return EventsRoutes;
|
|
31579
31581
|
}());
|
|
@@ -31954,6 +31956,33 @@ var Events = /** @class */ (function () {
|
|
|
31954
31956
|
Events.updateRecording = function (event_id, recording_id, data, params) {
|
|
31955
31957
|
return Requests.processRoute(RecordingsRoute.routes.update, data, { event_id: event_id, recording_id: recording_id }, params);
|
|
31956
31958
|
};
|
|
31959
|
+
/**
|
|
31960
|
+
* Enable a widget for the current event.
|
|
31961
|
+
*
|
|
31962
|
+
* @see https://api.glitch.fun/api/documentation#/Event%20Route/updateEventRecording
|
|
31963
|
+
*
|
|
31964
|
+
* @param event_id The id of the event to update.
|
|
31965
|
+
* @param widget_id The id of the widget to enable.
|
|
31966
|
+
* @param data The data, which should contain the roles.
|
|
31967
|
+
*
|
|
31968
|
+
* @returns promise
|
|
31969
|
+
*/
|
|
31970
|
+
Events.enableWidget = function (event_id, widget_id, data, params) {
|
|
31971
|
+
return Requests.processRoute(EventsRoutes.routes.enableWidget, data, { event_id: event_id, widget_id: widget_id }, params);
|
|
31972
|
+
};
|
|
31973
|
+
/**
|
|
31974
|
+
* Disable a widget for the current event.
|
|
31975
|
+
*
|
|
31976
|
+
* @see https://api.glitch.fun/api/documentation#/Event%20Route/updateEventRecording
|
|
31977
|
+
*
|
|
31978
|
+
* @param event_id The id of the event to update.
|
|
31979
|
+
* @param widget_id The id of the widget to disable.
|
|
31980
|
+
*
|
|
31981
|
+
* @returns promise
|
|
31982
|
+
*/
|
|
31983
|
+
Events.disableWidget = function (event_id, widget_id, data, params) {
|
|
31984
|
+
return Requests.processRoute(EventsRoutes.routes.disableWidget, data, { event_id: event_id, widget_id: widget_id }, params);
|
|
31985
|
+
};
|
|
31957
31986
|
return Events;
|
|
31958
31987
|
}());
|
|
31959
31988
|
|