UNPKG

21.6 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 identifier for the playback configuration.
139 */
140 Name?: __string;
141 /**
142 * The Amazon Resource Name (ARN) for the playback configuration.
143 */
144 PlaybackConfigurationArn?: __string;
145 /**
146 * The URL that the player accesses to get a manifest from AWS Elemental MediaTailor. This session will use server-side reporting.
147 */
148 PlaybackEndpointPrefix?: __string;
149 /**
150 * The URL that the player uses to initialize a session that uses client-side reporting.
151 */
152 SessionInitializationEndpointPrefix?: __string;
153 /**
154 * 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.
155 */
156 SlateAdUrl?: __string;
157 /**
158 * The tags assigned to the playback configuration.
159 */
160 Tags?: __mapOf__string;
161 /**
162 * 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.
163 */
164 TranscodeProfileName?: __string;
165 /**
166 * The URL prefix for the master playlist for the stream, minus the asset ID. The maximum length is 512 characters.
167 */
168 VideoContentSourceUrl?: __string;
169 }
170 export interface HlsConfiguration {
171 /**
172 * The URL that is used to initiate a playback session for devices that support Apple HLS. The session uses server-side reporting.
173 */
174 ManifestEndpointPrefix?: __string;
175 }
176 export interface ListPlaybackConfigurationsRequest {
177 /**
178 * Maximum number of records to return.
179 */
180 MaxResults?: __integerMin1Max100;
181 /**
182 * Pagination token returned by the GET list request when results exceed the maximum allowed. Use the token to fetch the next page of results.
183 */
184 NextToken?: __string;
185 }
186 export interface ListPlaybackConfigurationsResponse {
187 /**
188 * 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.
189 */
190 Items?: __listOfPlaybackConfigurations;
191 /**
192 * Pagination token returned by the GET list request when results exceed the maximum allowed. Use the token to fetch the next page of results.
193 */
194 NextToken?: __string;
195 }
196 export interface ListTagsForResourceRequest {
197 /**
198 * The Amazon Resource Name (ARN) for the playback configuration. You can get this from the response to any playback configuration request.
199 */
200 ResourceArn: __string;
201 }
202 export interface ListTagsForResourceResponse {
203 /**
204 * A comma-separated list of tag key:value pairs. For example:
205 {
206 "Key1": "Value1",
207 "Key2": "Value2"
208 }
209
210 */
211 Tags?: __mapOf__string;
212 }
213 export type OriginManifestType = "SINGLE_PERIOD"|"MULTI_PERIOD"|string;
214 export interface PlaybackConfiguration {
215 /**
216 * 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.
217 */
218 AdDecisionServerUrl?: __string;
219 /**
220 * The configuration for using a content delivery network (CDN), like Amazon CloudFront, for content and ad segment management.
221 */
222 CdnConfiguration?: CdnConfiguration;
223 /**
224 * The configuration for DASH content.
225 */
226 DashConfiguration?: DashConfiguration;
227 /**
228 * The configuration for HLS content.
229 */
230 HlsConfiguration?: HlsConfiguration;
231 /**
232 * The identifier for the playback configuration.
233 */
234 Name?: __string;
235 /**
236 * The Amazon Resource Name (ARN) for the playback configuration.
237 */
238 PlaybackConfigurationArn?: __string;
239 /**
240 * The URL that the player accesses to get a manifest from AWS Elemental MediaTailor. This session will use server-side reporting.
241 */
242 PlaybackEndpointPrefix?: __string;
243 /**
244 * The URL that the player uses to initialize a session that uses client-side reporting.
245 */
246 SessionInitializationEndpointPrefix?: __string;
247 /**
248 * 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.
249 */
250 SlateAdUrl?: __string;
251 /**
252 * The tags assigned to the playback configuration.
253 */
254 Tags?: __mapOf__string;
255 /**
256 * 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.
257 */
258 TranscodeProfileName?: __string;
259 /**
260 * The URL prefix for the master playlist for the stream, minus the asset ID. The maximum length is 512 characters.
261 */
262 VideoContentSourceUrl?: __string;
263 }
264 export interface PutPlaybackConfigurationRequest {
265 /**
266 * 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.
267 */
268 AdDecisionServerUrl?: __string;
269 /**
270 * The configuration for using a content delivery network (CDN), like Amazon CloudFront, for content and ad segment management.
271 */
272 CdnConfiguration?: CdnConfiguration;
273 /**
274 * The configuration for DASH content.
275 */
276 DashConfiguration?: DashConfigurationForPut;
277 /**
278 * The identifier for the playback configuration.
279 */
280 Name?: __string;
281 /**
282 * 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.
283 */
284 SlateAdUrl?: __string;
285 /**
286 * The tags to assign to the playback configuration.
287 */
288 Tags?: __mapOf__string;
289 /**
290 * 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.
291 */
292 TranscodeProfileName?: __string;
293 /**
294 * The URL prefix for the master playlist for the stream, minus the asset ID. The maximum length is 512 characters.
295 */
296 VideoContentSourceUrl?: __string;
297 }
298 export interface PutPlaybackConfigurationResponse {
299 /**
300 * 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.
301 */
302 AdDecisionServerUrl?: __string;
303 /**
304 * The configuration for using a content delivery network (CDN), like Amazon CloudFront, for content and ad segment management.
305 */
306 CdnConfiguration?: CdnConfiguration;
307 /**
308 * The configuration for DASH content.
309 */
310 DashConfiguration?: DashConfiguration;
311 /**
312 * The configuration for HLS content.
313 */
314 HlsConfiguration?: HlsConfiguration;
315 /**
316 * The identifier for the playback configuration.
317 */
318 Name?: __string;
319 /**
320 * The Amazon Resource Name (ARN) for the playback configuration.
321 */
322 PlaybackConfigurationArn?: __string;
323 /**
324 * The URL that the player accesses to get a manifest from AWS Elemental MediaTailor. This session will use server-side reporting.
325 */
326 PlaybackEndpointPrefix?: __string;
327 /**
328 * The URL that the player uses to initialize a session that uses client-side reporting.
329 */
330 SessionInitializationEndpointPrefix?: __string;
331 /**
332 * 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.
333 */
334 SlateAdUrl?: __string;
335 /**
336 * The tags assigned to the playback configuration.
337 */
338 Tags?: __mapOf__string;
339 /**
340 * 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.
341 */
342 TranscodeProfileName?: __string;
343 /**
344 * The URL prefix for the master playlist for the stream, minus the asset ID. The maximum length is 512 characters.
345 */
346 VideoContentSourceUrl?: __string;
347 }
348 export interface TagResourceRequest {
349 /**
350 * The Amazon Resource Name (ARN) for the playback configuration. You can get this from the response to any playback configuration request.
351 */
352 ResourceArn: __string;
353 /**
354 * A comma-separated list of tag key:value pairs. For example:
355 {
356 "Key1": "Value1",
357 "Key2": "Value2"
358 }
359
360 */
361 Tags: __mapOf__string;
362 }
363 export interface UntagResourceRequest {
364 /**
365 * The Amazon Resource Name (ARN) for the playback configuration. You can get this from the response to any playback configuration request.
366 */
367 ResourceArn: __string;
368 /**
369 * A comma-separated list of the tag keys to remove from the playback configuration.
370 */
371 TagKeys: __listOf__string;
372 }
373 export type __integerMin1Max100 = number;
374 export type __listOfPlaybackConfigurations = PlaybackConfiguration[];
375 export type __listOf__string = __string[];
376 export type __mapOf__string = {[key: string]: __string};
377 export type __string = string;
378 /**
379 * 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.
380 */
381 export type apiVersion = "2018-04-23"|"latest"|string;
382 export interface ClientApiVersions {
383 /**
384 * 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.
385 */
386 apiVersion?: apiVersion;
387 }
388 export type ClientConfiguration = ServiceConfigurationOptions & ClientApiVersions;
389 /**
390 * Contains interfaces for use with the MediaTailor client.
391 */
392 export import Types = MediaTailor;
393}
394export = MediaTailor;