UNPKG

23.4 kBTypeScriptView Raw
1import {Request} from '../lib/request';
2import {Response} from '../lib/response';
3import {AWSError} from '../lib/error';
4import {Service} from '../lib/service';
5import {ServiceConfigurationOptions} from '../lib/service';
6import {ConfigBase as Config} from '../lib/config';
7interface Blob {}
8declare class MediaTailor extends Service {
9 /**
10 * Constructs a service object. This object has one method for each API operation.
11 */
12 constructor(options?: MediaTailor.Types.ClientConfiguration)
13 config: Config & MediaTailor.Types.ClientConfiguration;
14 /**
15 * Deletes the playback configuration for the specified name.
16 */
17 deletePlaybackConfiguration(params: MediaTailor.Types.DeletePlaybackConfigurationRequest, callback?: (err: AWSError, data: MediaTailor.Types.DeletePlaybackConfigurationResponse) => void): Request<MediaTailor.Types.DeletePlaybackConfigurationResponse, AWSError>;
18 /**
19 * Deletes the playback configuration for the specified name.
20 */
21 deletePlaybackConfiguration(callback?: (err: AWSError, data: MediaTailor.Types.DeletePlaybackConfigurationResponse) => void): Request<MediaTailor.Types.DeletePlaybackConfigurationResponse, AWSError>;
22 /**
23 * Returns the playback configuration for the specified name.
24 */
25 getPlaybackConfiguration(params: MediaTailor.Types.GetPlaybackConfigurationRequest, callback?: (err: AWSError, data: MediaTailor.Types.GetPlaybackConfigurationResponse) => void): Request<MediaTailor.Types.GetPlaybackConfigurationResponse, AWSError>;
26 /**
27 * Returns the playback configuration for the specified name.
28 */
29 getPlaybackConfiguration(callback?: (err: AWSError, data: MediaTailor.Types.GetPlaybackConfigurationResponse) => void): Request<MediaTailor.Types.GetPlaybackConfigurationResponse, AWSError>;
30 /**
31 * Returns a list of the playback configurations defined in AWS Elemental MediaTailor. You can specify a maximum number of configurations to return at a time. The default maximum is 50. Results are returned in pagefuls. If MediaTailor has more configurations than the specified maximum, it provides parameters in the response that you can use to retrieve the next pageful.
32 */
33 listPlaybackConfigurations(params: MediaTailor.Types.ListPlaybackConfigurationsRequest, callback?: (err: AWSError, data: MediaTailor.Types.ListPlaybackConfigurationsResponse) => void): Request<MediaTailor.Types.ListPlaybackConfigurationsResponse, AWSError>;
34 /**
35 * Returns a list of the playback configurations defined in AWS Elemental MediaTailor. You can specify a maximum number of configurations to return at a time. The default maximum is 50. Results are returned in pagefuls. If MediaTailor has more configurations than the specified maximum, it provides parameters in the response that you can use to retrieve the next pageful.
36 */
37 listPlaybackConfigurations(callback?: (err: AWSError, data: MediaTailor.Types.ListPlaybackConfigurationsResponse) => void): Request<MediaTailor.Types.ListPlaybackConfigurationsResponse, AWSError>;
38 /**
39 * Returns a list of the tags assigned to the specified playback configuration resource.
40 */
41 listTagsForResource(params: MediaTailor.Types.ListTagsForResourceRequest, callback?: (err: AWSError, data: MediaTailor.Types.ListTagsForResourceResponse) => void): Request<MediaTailor.Types.ListTagsForResourceResponse, AWSError>;
42 /**
43 * Returns a list of the tags assigned to the specified playback configuration resource.
44 */
45 listTagsForResource(callback?: (err: AWSError, data: MediaTailor.Types.ListTagsForResourceResponse) => void): Request<MediaTailor.Types.ListTagsForResourceResponse, AWSError>;
46 /**
47 * Adds a new playback configuration to AWS Elemental MediaTailor.
48 */
49 putPlaybackConfiguration(params: MediaTailor.Types.PutPlaybackConfigurationRequest, callback?: (err: AWSError, data: MediaTailor.Types.PutPlaybackConfigurationResponse) => void): Request<MediaTailor.Types.PutPlaybackConfigurationResponse, AWSError>;
50 /**
51 * Adds a new playback configuration to AWS Elemental MediaTailor.
52 */
53 putPlaybackConfiguration(callback?: (err: AWSError, data: MediaTailor.Types.PutPlaybackConfigurationResponse) => void): Request<MediaTailor.Types.PutPlaybackConfigurationResponse, AWSError>;
54 /**
55 * Adds tags to the specified playback configuration resource. You can specify one or more tags to add.
56 */
57 tagResource(params: MediaTailor.Types.TagResourceRequest, callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>;
58 /**
59 * Adds tags to the specified playback configuration resource. You can specify one or more tags to add.
60 */
61 tagResource(callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>;
62 /**
63 * Removes tags from the specified playback configuration resource. You can specify one or more tags to remove.
64 */
65 untagResource(params: MediaTailor.Types.UntagResourceRequest, callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>;
66 /**
67 * Removes tags from the specified playback configuration resource. You can specify one or more tags to remove.
68 */
69 untagResource(callback?: (err: AWSError, data: {}) => void): Request<{}, AWSError>;
70}
71declare namespace MediaTailor {
72 export interface CdnConfiguration {
73 /**
74 * A non-default content delivery network (CDN) to serve ad segments. By default, AWS Elemental MediaTailor uses Amazon CloudFront with default cache settings as its CDN for ad segments. To set up an alternate CDN, create a rule in your CDN for the following origin: ads.mediatailor.&lt;region>.amazonaws.com. Then specify the rule's name in this AdSegmentUrlPrefix. When AWS Elemental MediaTailor serves a manifest, it reports your CDN as the source for ad segments.
75 */
76 AdSegmentUrlPrefix?: __string;
77 /**
78 * A content delivery network (CDN) to cache content segments, so that content requests don’t always have to go to the origin server. First, create a rule in your CDN for the content segment origin server. Then specify the rule's name in this ContentSegmentUrlPrefix. When AWS Elemental MediaTailor serves a manifest, it reports your CDN as the source for content segments.
79 */
80 ContentSegmentUrlPrefix?: __string;
81 }
82 export interface DashConfiguration {
83 /**
84 * The URL generated by MediaTailor to initiate a playback session. The session uses server-side reporting. This setting is ignored in PUT operations.
85 */
86 ManifestEndpointPrefix?: __string;
87 /**
88 * The setting that controls whether MediaTailor includes the Location tag in DASH manifests. MediaTailor populates the Location tag with the URL for manifest update requests, to be used by players that don't support sticky redirects. Disable this if you have CDN routing rules set up for accessing MediaTailor manifests, and you are either using client-side reporting or your players support sticky HTTP redirects. Valid values are DISABLED and EMT_DEFAULT. The EMT_DEFAULT setting enables the inclusion of the tag and is the default value.
89 */
90 MpdLocation?: __string;
91 /**
92 * The setting that controls whether MediaTailor handles manifests from the origin server as multi-period manifests or single-period manifests. If your origin server produces single-period manifests, set this to SINGLE_PERIOD. The default setting is MULTI_PERIOD. For multi-period manifests, omit this setting or set it to MULTI_PERIOD.
93 */
94 OriginManifestType?: OriginManifestType;
95 }
96 export interface DashConfigurationForPut {
97 /**
98 * The setting that controls whether MediaTailor includes the Location tag in DASH manifests. MediaTailor populates the Location tag with the URL for manifest update requests, to be used by players that don't support sticky redirects. Disable this if you have CDN routing rules set up for accessing MediaTailor manifests, and you are either using client-side reporting or your players support sticky HTTP redirects. Valid values are DISABLED and EMT_DEFAULT. The EMT_DEFAULT setting enables the inclusion of the tag and is the default value.
99 */
100 MpdLocation?: __string;
101 /**
102 * The setting that controls whether MediaTailor handles manifests from the origin server as multi-period manifests or single-period manifests. If your origin server produces single-period manifests, set this to SINGLE_PERIOD. The default setting is MULTI_PERIOD. For multi-period manifests, omit this setting or set it to MULTI_PERIOD.
103 */
104 OriginManifestType?: OriginManifestType;
105 }
106 export interface DeletePlaybackConfigurationRequest {
107 /**
108 * The identifier for the playback configuration.
109 */
110 Name: __string;
111 }
112 export interface DeletePlaybackConfigurationResponse {
113 }
114 export interface GetPlaybackConfigurationRequest {
115 /**
116 * The identifier for the playback configuration.
117 */
118 Name: __string;
119 }
120 export interface GetPlaybackConfigurationResponse {
121 /**
122 * The URL for the ad decision server (ADS). This includes the specification of static parameters and placeholders for dynamic parameters. AWS Elemental MediaTailor substitutes player-specific and session-specific parameters as needed when calling the ADS. Alternately, for testing, you can provide a static VAST URL. The maximum length is 25,000 characters.
123 */
124 AdDecisionServerUrl?: __string;
125 /**
126 * The configuration for using a content delivery network (CDN), like Amazon CloudFront, for content and ad segment management.
127 */
128 CdnConfiguration?: CdnConfiguration;
129 /**
130 * The configuration for DASH content.
131 */
132 DashConfiguration?: DashConfiguration;
133 /**
134 * The configuration for HLS content.
135 */
136 HlsConfiguration?: HlsConfiguration;
137 /**
138 * The configuration for pre-roll ad insertion.
139 */
140 LivePreRollConfiguration?: LivePreRollConfiguration;
141 /**
142 * The identifier for the playback configuration.
143 */
144 Name?: __string;
145 /**
146 * The maximum duration of underfilled ad time (in seconds) allowed in an ad break.
147 */
148 PersonalizationThresholdSeconds?: __integerMin1;
149 /**
150 * The Amazon Resource Name (ARN) for the playback configuration.
151 */
152 PlaybackConfigurationArn?: __string;
153 /**
154 * The URL that the player accesses to get a manifest from AWS Elemental MediaTailor. This session will use server-side reporting.
155 */
156 PlaybackEndpointPrefix?: __string;
157 /**
158 * The URL that the player uses to initialize a session that uses client-side reporting.
159 */
160 SessionInitializationEndpointPrefix?: __string;
161 /**
162 * The URL for a high-quality video asset to transcode and use to fill in time that's not used by ads. AWS Elemental MediaTailor shows the slate to fill in gaps in media content. Configuring the slate is optional for non-VPAID playback configurations. For VPAID, the slate is required because MediaTailor provides it in the slots designated for dynamic ad content. The slate must be a high-quality asset that contains both audio and video.
163 */
164 SlateAdUrl?: __string;
165 /**
166 * The tags assigned to the playback configuration.
167 */
168 Tags?: __mapOf__string;
169 /**
170 * The name that is used to associate this playback configuration with a custom transcode profile. This overrides the dynamic transcoding defaults of MediaTailor. Use this only if you have already set up custom profiles with the help of AWS Support.
171 */
172 TranscodeProfileName?: __string;
173 /**
174 * The URL prefix for the master playlist for the stream, minus the asset ID. The maximum length is 512 characters.
175 */
176 VideoContentSourceUrl?: __string;
177 }
178 export interface HlsConfiguration {
179 /**
180 * The URL that is used to initiate a playback session for devices that support Apple HLS. The session uses server-side reporting.
181 */
182 ManifestEndpointPrefix?: __string;
183 }
184 export interface ListPlaybackConfigurationsRequest {
185 /**
186 * Maximum number of records to return.
187 */
188 MaxResults?: __integerMin1Max100;
189 /**
190 * Pagination token returned by the GET list request when results exceed the maximum allowed. Use the token to fetch the next page of results.
191 */
192 NextToken?: __string;
193 }
194 export interface ListPlaybackConfigurationsResponse {
195 /**
196 * Array of playback configurations. This might be all the available configurations or a subset, depending on the settings that you provide and the total number of configurations stored.
197 */
198 Items?: __listOfPlaybackConfigurations;
199 /**
200 * Pagination token returned by the GET list request when results exceed the maximum allowed. Use the token to fetch the next page of results.
201 */
202 NextToken?: __string;
203 }
204 export interface ListTagsForResourceRequest {
205 /**
206 * The Amazon Resource Name (ARN) for the playback configuration. You can get this from the response to any playback configuration request.
207 */
208 ResourceArn: __string;
209 }
210 export interface ListTagsForResourceResponse {
211 /**
212 * A comma-separated list of tag key:value pairs. For example:
213 {
214 "Key1": "Value1",
215 "Key2": "Value2"
216 }
217
218 */
219 Tags?: __mapOf__string;
220 }
221 export type OriginManifestType = "SINGLE_PERIOD"|"MULTI_PERIOD"|string;
222 export interface PlaybackConfiguration {
223 /**
224 * The URL for the ad decision server (ADS). This includes the specification of static parameters and placeholders for dynamic parameters. AWS Elemental MediaTailor substitutes player-specific and session-specific parameters as needed when calling the ADS. Alternately, for testing, you can provide a static VAST URL. The maximum length is 25,000 characters.
225 */
226 AdDecisionServerUrl?: __string;
227 /**
228 * The configuration for using a content delivery network (CDN), like Amazon CloudFront, for content and ad segment management.
229 */
230 CdnConfiguration?: CdnConfiguration;
231 /**
232 * The configuration for DASH content.
233 */
234 DashConfiguration?: DashConfiguration;
235 /**
236 * The configuration for HLS content.
237 */
238 HlsConfiguration?: HlsConfiguration;
239 /**
240 * The identifier for the playback configuration.
241 */
242 Name?: __string;
243 /**
244 * The Amazon Resource Name (ARN) for the playback configuration.
245 */
246 PlaybackConfigurationArn?: __string;
247 /**
248 * The URL that the player accesses to get a manifest from AWS Elemental MediaTailor. This session will use server-side reporting.
249 */
250 PlaybackEndpointPrefix?: __string;
251 /**
252 * The URL that the player uses to initialize a session that uses client-side reporting.
253 */
254 SessionInitializationEndpointPrefix?: __string;
255 /**
256 * The URL for a high-quality video asset to transcode and use to fill in time that's not used by ads. AWS Elemental MediaTailor shows the slate to fill in gaps in media content. Configuring the slate is optional for non-VPAID playback configurations. For VPAID, the slate is required because MediaTailor provides it in the slots designated for dynamic ad content. The slate must be a high-quality asset that contains both audio and video.
257 */
258 SlateAdUrl?: __string;
259 /**
260 * The tags assigned to the playback configuration.
261 */
262 Tags?: __mapOf__string;
263 /**
264 * The name that is used to associate this playback configuration with a custom transcode profile. This overrides the dynamic transcoding defaults of MediaTailor. Use this only if you have already set up custom profiles with the help of AWS Support.
265 */
266 TranscodeProfileName?: __string;
267 /**
268 * The maximum duration of underfilled ad time (in seconds) allowed in an ad break.
269 */
270 PersonalizationThresholdSeconds?: __integerMin1;
271 /**
272 * The URL prefix for the master playlist for the stream, minus the asset ID. The maximum length is 512 characters.
273 */
274 VideoContentSourceUrl?: __string;
275 }
276 export interface LivePreRollConfiguration {
277 /**
278 * The URL for the ad decision server (ADS) for pre-roll ads. This includes the specification of static parameters and placeholders for dynamic parameters. AWS Elemental MediaTailor substitutes player-specific and session-specific parameters as needed when calling the ADS. Alternately, for testing, you can provide a static VAST URL. The maximum length is 25,000 characters.
279 */
280 AdDecisionServerUrl?: __string;
281 /**
282 * The maximum allowed duration for the pre-roll ad avail. AWS Elemental MediaTailor won't play pre-roll ads to exceed this duration, regardless of the total duration of ads that the ADS returns.
283 */
284 MaxDurationSeconds?: __integer;
285 }
286 export interface PutPlaybackConfigurationRequest {
287 /**
288 * The URL for the ad decision server (ADS). This includes the specification of static parameters and placeholders for dynamic parameters. AWS Elemental MediaTailor substitutes player-specific and session-specific parameters as needed when calling the ADS. Alternately, for testing you can provide a static VAST URL. The maximum length is 25,000 characters.
289 */
290 AdDecisionServerUrl?: __string;
291 /**
292 * The configuration for using a content delivery network (CDN), like Amazon CloudFront, for content and ad segment management.
293 */
294 CdnConfiguration?: CdnConfiguration;
295 /**
296 * The configuration for DASH content.
297 */
298 DashConfiguration?: DashConfigurationForPut;
299 /**
300 * The configuration for pre-roll ad insertion.
301 */
302 LivePreRollConfiguration?: LivePreRollConfiguration;
303 /**
304 * The identifier for the playback configuration.
305 */
306 Name?: __string;
307 /**
308 * The maximum duration of underfilled ad time (in seconds) allowed in an ad break.
309 */
310 PersonalizationThresholdSeconds?: __integerMin1;
311 /**
312 * The URL for a high-quality video asset to transcode and use to fill in time that's not used by ads. AWS Elemental MediaTailor shows the slate to fill in gaps in media content. Configuring the slate is optional for non-VPAID configurations. For VPAID, the slate is required because MediaTailor provides it in the slots that are designated for dynamic ad content. The slate must be a high-quality asset that contains both audio and video.
313 */
314 SlateAdUrl?: __string;
315 /**
316 * The tags to assign to the playback configuration.
317 */
318 Tags?: __mapOf__string;
319 /**
320 * The name that is used to associate this playback configuration with a custom transcode profile. This overrides the dynamic transcoding defaults of MediaTailor. Use this only if you have already set up custom profiles with the help of AWS Support.
321 */
322 TranscodeProfileName?: __string;
323 /**
324 * The URL prefix for the master playlist for the stream, minus the asset ID. The maximum length is 512 characters.
325 */
326 VideoContentSourceUrl?: __string;
327 }
328 export interface PutPlaybackConfigurationResponse {
329 /**
330 * The URL for the ad decision server (ADS). This includes the specification of static parameters and placeholders for dynamic parameters. AWS Elemental MediaTailor substitutes player-specific and session-specific parameters as needed when calling the ADS. Alternately, for testing, you can provide a static VAST URL. The maximum length is 25,000 characters.
331 */
332 AdDecisionServerUrl?: __string;
333 /**
334 * The configuration for using a content delivery network (CDN), like Amazon CloudFront, for content and ad segment management.
335 */
336 CdnConfiguration?: CdnConfiguration;
337 /**
338 * The configuration for DASH content.
339 */
340 DashConfiguration?: DashConfiguration;
341 /**
342 * The configuration for HLS content.
343 */
344 HlsConfiguration?: HlsConfiguration;
345 /**
346 * The configuration for pre-roll ad insertion.
347 */
348 LivePreRollConfiguration?: LivePreRollConfiguration;
349 /**
350 * The identifier for the playback configuration.
351 */
352 Name?: __string;
353 /**
354 * The maximum duration of underfilled ad time (in seconds) allowed in an ad break.
355 */
356 PersonalizationThresholdSeconds?: __integerMin1;
357 /**
358 * The Amazon Resource Name (ARN) for the playback configuration.
359 */
360 PlaybackConfigurationArn?: __string;
361 /**
362 * The URL that the player accesses to get a manifest from AWS Elemental MediaTailor. This session will use server-side reporting.
363 */
364 PlaybackEndpointPrefix?: __string;
365 /**
366 * The URL that the player uses to initialize a session that uses client-side reporting.
367 */
368 SessionInitializationEndpointPrefix?: __string;
369 /**
370 * The URL for a high-quality video asset to transcode and use to fill in time that's not used by ads. AWS Elemental MediaTailor shows the slate to fill in gaps in media content. Configuring the slate is optional for non-VPAID playback configurations. For VPAID, the slate is required because MediaTailor provides it in the slots designated for dynamic ad content. The slate must be a high-quality asset that contains both audio and video.
371 */
372 SlateAdUrl?: __string;
373 /**
374 * The tags assigned to the playback configuration.
375 */
376 Tags?: __mapOf__string;
377 /**
378 * The name that is used to associate this playback configuration with a custom transcode profile. This overrides the dynamic transcoding defaults of MediaTailor. Use this only if you have already set up custom profiles with the help of AWS Support.
379 */
380 TranscodeProfileName?: __string;
381 /**
382 * The URL prefix for the master playlist for the stream, minus the asset ID. The maximum length is 512 characters.
383 */
384 VideoContentSourceUrl?: __string;
385 }
386 export interface TagResourceRequest {
387 /**
388 * The Amazon Resource Name (ARN) for the playback configuration. You can get this from the response to any playback configuration request.
389 */
390 ResourceArn: __string;
391 /**
392 * A comma-separated list of tag key:value pairs. For example:
393 {
394 "Key1": "Value1",
395 "Key2": "Value2"
396 }
397
398 */
399 Tags: __mapOf__string;
400 }
401 export interface UntagResourceRequest {
402 /**
403 * The Amazon Resource Name (ARN) for the playback configuration. You can get this from the response to any playback configuration request.
404 */
405 ResourceArn: __string;
406 /**
407 * A comma-separated list of the tag keys to remove from the playback configuration.
408 */
409 TagKeys: __listOf__string;
410 }
411 export type __integer = number;
412 export type __integerMin1 = number;
413 export type __integerMin1Max100 = number;
414 export type __listOfPlaybackConfigurations = PlaybackConfiguration[];
415 export type __listOf__string = __string[];
416 export type __mapOf__string = {[key: string]: __string};
417 export type __string = string;
418 /**
419 * A string in YYYY-MM-DD format that represents the latest possible API version that can be used in this service. Specify 'latest' to use the latest possible version.
420 */
421 export type apiVersion = "2018-04-23"|"latest"|string;
422 export interface ClientApiVersions {
423 /**
424 * A string in YYYY-MM-DD format that represents the latest possible API version that can be used in this service. Specify 'latest' to use the latest possible version.
425 */
426 apiVersion?: apiVersion;
427 }
428 export type ClientConfiguration = ServiceConfigurationOptions & ClientApiVersions;
429 /**
430 * Contains interfaces for use with the MediaTailor client.
431 */
432 export import Types = MediaTailor;
433}
434export = MediaTailor;