UNPKG

@bitmovin/api-sdk

Version:

Bitmovin JS/TS API SDK

33 lines (32 loc) 1.7 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const BaseAPI_1 = require("../../../../common/BaseAPI"); const Mapper_1 = require("../../../../common/Mapper"); const ResetLiveManifestTimeShift_1 = require("../../../../models/ResetLiveManifestTimeShift"); /** * ResetLiveManifestTimeshiftApi - object-oriented interface * @export * @class ResetLiveManifestTimeshiftApi * @extends {BaseAPI} */ class ResetLiveManifestTimeshiftApi extends BaseAPI_1.BaseAPI { constructor(configuration) { super(configuration); } /** * @summary Reset Live manifest time-shift * @param {string} encodingId Id of the encoding. * @param {ResetLiveManifestTimeShift} resetLiveManifestTimeShift Removes older segments from live manifests. This resets or reduces the time-shift (DVR) window. The `residualPeriod` value determines how many seconds will remain in the time-shift window. The original time-shift window does not change. Newer segments will be added and not removed from the manifest until the original time-shift duration is reached again. Currently, only HLS live manifests are supported. * @throws {BitmovinError} * @memberof ResetLiveManifestTimeshiftApi */ create(encodingId, resetLiveManifestTimeShift) { const pathParamMap = { encoding_id: encodingId }; return this.restClient.post('/encoding/encodings/{encoding_id}/live/reset-live-manifest-timeshift', pathParamMap, resetLiveManifestTimeShift).then((response) => { return (0, Mapper_1.map)(response, ResetLiveManifestTimeShift_1.default); }); } } exports.default = ResetLiveManifestTimeshiftApi;