universal-s3
Version:
Universal S3 SDK for JavaScript, available for Node.js backends
459 lines • 148 kB
TypeScript
import {Request} from '../lib/request';
import {Response} from '../lib/response';
import {AWSError} from '../lib/error';
import {Service} from '../lib/service';
import {WaiterConfiguration} from '../lib/service';
import {ServiceConfigurationOptions} from '../lib/service';
import {ConfigBase as Config} from '../lib/config';
interface Blob {}
declare class ElasticTranscoder extends Service {
/**
* Constructs a service object. This object has one method for each API operation.
*/
constructor(options?: ElasticTranscoder.Types.ClientConfiguration)
config: Config & ElasticTranscoder.Types.ClientConfiguration;
/**
* The CancelJob operation cancels an unfinished job. You can only cancel a job that has a status of Submitted. To prevent a pipeline from starting to process a job while you're getting the job identifier, use UpdatePipelineStatus to temporarily pause the pipeline.
*/
cancelJob(params: ElasticTranscoder.Types.CancelJobRequest, callback?: (err: AWSError, data: ElasticTranscoder.Types.CancelJobResponse) => void): Request<ElasticTranscoder.Types.CancelJobResponse, AWSError>;
/**
* The CancelJob operation cancels an unfinished job. You can only cancel a job that has a status of Submitted. To prevent a pipeline from starting to process a job while you're getting the job identifier, use UpdatePipelineStatus to temporarily pause the pipeline.
*/
cancelJob(callback?: (err: AWSError, data: ElasticTranscoder.Types.CancelJobResponse) => void): Request<ElasticTranscoder.Types.CancelJobResponse, AWSError>;
/**
* When you create a job, Elastic Transcoder returns JSON data that includes the values that you specified plus information about the job that is created. If you have specified more than one output for your jobs (for example, one output for the Kindle Fire and another output for the Apple iPhone 4s), you currently must use the Elastic Transcoder API to list the jobs (as opposed to the AWS Console).
*/
createJob(params: ElasticTranscoder.Types.CreateJobRequest, callback?: (err: AWSError, data: ElasticTranscoder.Types.CreateJobResponse) => void): Request<ElasticTranscoder.Types.CreateJobResponse, AWSError>;
/**
* When you create a job, Elastic Transcoder returns JSON data that includes the values that you specified plus information about the job that is created. If you have specified more than one output for your jobs (for example, one output for the Kindle Fire and another output for the Apple iPhone 4s), you currently must use the Elastic Transcoder API to list the jobs (as opposed to the AWS Console).
*/
createJob(callback?: (err: AWSError, data: ElasticTranscoder.Types.CreateJobResponse) => void): Request<ElasticTranscoder.Types.CreateJobResponse, AWSError>;
/**
* The CreatePipeline operation creates a pipeline with settings that you specify.
*/
createPipeline(params: ElasticTranscoder.Types.CreatePipelineRequest, callback?: (err: AWSError, data: ElasticTranscoder.Types.CreatePipelineResponse) => void): Request<ElasticTranscoder.Types.CreatePipelineResponse, AWSError>;
/**
* The CreatePipeline operation creates a pipeline with settings that you specify.
*/
createPipeline(callback?: (err: AWSError, data: ElasticTranscoder.Types.CreatePipelineResponse) => void): Request<ElasticTranscoder.Types.CreatePipelineResponse, AWSError>;
/**
* The CreatePreset operation creates a preset with settings that you specify. Elastic Transcoder checks the CreatePreset settings to ensure that they meet Elastic Transcoder requirements and to determine whether they comply with H.264 standards. If your settings are not valid for Elastic Transcoder, Elastic Transcoder returns an HTTP 400 response (ValidationException) and does not create the preset. If the settings are valid for Elastic Transcoder but aren't strictly compliant with the H.264 standard, Elastic Transcoder creates the preset and returns a warning message in the response. This helps you determine whether your settings comply with the H.264 standard while giving you greater flexibility with respect to the video that Elastic Transcoder produces. Elastic Transcoder uses the H.264 video-compression format. For more information, see the International Telecommunication Union publication Recommendation ITU-T H.264: Advanced video coding for generic audiovisual services.
*/
createPreset(params: ElasticTranscoder.Types.CreatePresetRequest, callback?: (err: AWSError, data: ElasticTranscoder.Types.CreatePresetResponse) => void): Request<ElasticTranscoder.Types.CreatePresetResponse, AWSError>;
/**
* The CreatePreset operation creates a preset with settings that you specify. Elastic Transcoder checks the CreatePreset settings to ensure that they meet Elastic Transcoder requirements and to determine whether they comply with H.264 standards. If your settings are not valid for Elastic Transcoder, Elastic Transcoder returns an HTTP 400 response (ValidationException) and does not create the preset. If the settings are valid for Elastic Transcoder but aren't strictly compliant with the H.264 standard, Elastic Transcoder creates the preset and returns a warning message in the response. This helps you determine whether your settings comply with the H.264 standard while giving you greater flexibility with respect to the video that Elastic Transcoder produces. Elastic Transcoder uses the H.264 video-compression format. For more information, see the International Telecommunication Union publication Recommendation ITU-T H.264: Advanced video coding for generic audiovisual services.
*/
createPreset(callback?: (err: AWSError, data: ElasticTranscoder.Types.CreatePresetResponse) => void): Request<ElasticTranscoder.Types.CreatePresetResponse, AWSError>;
/**
* The DeletePipeline operation removes a pipeline. You can only delete a pipeline that has never been used or that is not currently in use (doesn't contain any active jobs). If the pipeline is currently in use, DeletePipeline returns an error.
*/
deletePipeline(params: ElasticTranscoder.Types.DeletePipelineRequest, callback?: (err: AWSError, data: ElasticTranscoder.Types.DeletePipelineResponse) => void): Request<ElasticTranscoder.Types.DeletePipelineResponse, AWSError>;
/**
* The DeletePipeline operation removes a pipeline. You can only delete a pipeline that has never been used or that is not currently in use (doesn't contain any active jobs). If the pipeline is currently in use, DeletePipeline returns an error.
*/
deletePipeline(callback?: (err: AWSError, data: ElasticTranscoder.Types.DeletePipelineResponse) => void): Request<ElasticTranscoder.Types.DeletePipelineResponse, AWSError>;
/**
* The DeletePreset operation removes a preset that you've added in an AWS region. You can't delete the default presets that are included with Elastic Transcoder.
*/
deletePreset(params: ElasticTranscoder.Types.DeletePresetRequest, callback?: (err: AWSError, data: ElasticTranscoder.Types.DeletePresetResponse) => void): Request<ElasticTranscoder.Types.DeletePresetResponse, AWSError>;
/**
* The DeletePreset operation removes a preset that you've added in an AWS region. You can't delete the default presets that are included with Elastic Transcoder.
*/
deletePreset(callback?: (err: AWSError, data: ElasticTranscoder.Types.DeletePresetResponse) => void): Request<ElasticTranscoder.Types.DeletePresetResponse, AWSError>;
/**
* The ListJobsByPipeline operation gets a list of the jobs currently in a pipeline. Elastic Transcoder returns all of the jobs currently in the specified pipeline. The response body contains one element for each job that satisfies the search criteria.
*/
listJobsByPipeline(params: ElasticTranscoder.Types.ListJobsByPipelineRequest, callback?: (err: AWSError, data: ElasticTranscoder.Types.ListJobsByPipelineResponse) => void): Request<ElasticTranscoder.Types.ListJobsByPipelineResponse, AWSError>;
/**
* The ListJobsByPipeline operation gets a list of the jobs currently in a pipeline. Elastic Transcoder returns all of the jobs currently in the specified pipeline. The response body contains one element for each job that satisfies the search criteria.
*/
listJobsByPipeline(callback?: (err: AWSError, data: ElasticTranscoder.Types.ListJobsByPipelineResponse) => void): Request<ElasticTranscoder.Types.ListJobsByPipelineResponse, AWSError>;
/**
* The ListJobsByStatus operation gets a list of jobs that have a specified status. The response body contains one element for each job that satisfies the search criteria.
*/
listJobsByStatus(params: ElasticTranscoder.Types.ListJobsByStatusRequest, callback?: (err: AWSError, data: ElasticTranscoder.Types.ListJobsByStatusResponse) => void): Request<ElasticTranscoder.Types.ListJobsByStatusResponse, AWSError>;
/**
* The ListJobsByStatus operation gets a list of jobs that have a specified status. The response body contains one element for each job that satisfies the search criteria.
*/
listJobsByStatus(callback?: (err: AWSError, data: ElasticTranscoder.Types.ListJobsByStatusResponse) => void): Request<ElasticTranscoder.Types.ListJobsByStatusResponse, AWSError>;
/**
* The ListPipelines operation gets a list of the pipelines associated with the current AWS account.
*/
listPipelines(params: ElasticTranscoder.Types.ListPipelinesRequest, callback?: (err: AWSError, data: ElasticTranscoder.Types.ListPipelinesResponse) => void): Request<ElasticTranscoder.Types.ListPipelinesResponse, AWSError>;
/**
* The ListPipelines operation gets a list of the pipelines associated with the current AWS account.
*/
listPipelines(callback?: (err: AWSError, data: ElasticTranscoder.Types.ListPipelinesResponse) => void): Request<ElasticTranscoder.Types.ListPipelinesResponse, AWSError>;
/**
* The ListPresets operation gets a list of the default presets included with Elastic Transcoder and the presets that you've added in an AWS region.
*/
listPresets(params: ElasticTranscoder.Types.ListPresetsRequest, callback?: (err: AWSError, data: ElasticTranscoder.Types.ListPresetsResponse) => void): Request<ElasticTranscoder.Types.ListPresetsResponse, AWSError>;
/**
* The ListPresets operation gets a list of the default presets included with Elastic Transcoder and the presets that you've added in an AWS region.
*/
listPresets(callback?: (err: AWSError, data: ElasticTranscoder.Types.ListPresetsResponse) => void): Request<ElasticTranscoder.Types.ListPresetsResponse, AWSError>;
/**
* The ReadJob operation returns detailed information about a job.
*/
readJob(params: ElasticTranscoder.Types.ReadJobRequest, callback?: (err: AWSError, data: ElasticTranscoder.Types.ReadJobResponse) => void): Request<ElasticTranscoder.Types.ReadJobResponse, AWSError>;
/**
* The ReadJob operation returns detailed information about a job.
*/
readJob(callback?: (err: AWSError, data: ElasticTranscoder.Types.ReadJobResponse) => void): Request<ElasticTranscoder.Types.ReadJobResponse, AWSError>;
/**
* The ReadPipeline operation gets detailed information about a pipeline.
*/
readPipeline(params: ElasticTranscoder.Types.ReadPipelineRequest, callback?: (err: AWSError, data: ElasticTranscoder.Types.ReadPipelineResponse) => void): Request<ElasticTranscoder.Types.ReadPipelineResponse, AWSError>;
/**
* The ReadPipeline operation gets detailed information about a pipeline.
*/
readPipeline(callback?: (err: AWSError, data: ElasticTranscoder.Types.ReadPipelineResponse) => void): Request<ElasticTranscoder.Types.ReadPipelineResponse, AWSError>;
/**
* The ReadPreset operation gets detailed information about a preset.
*/
readPreset(params: ElasticTranscoder.Types.ReadPresetRequest, callback?: (err: AWSError, data: ElasticTranscoder.Types.ReadPresetResponse) => void): Request<ElasticTranscoder.Types.ReadPresetResponse, AWSError>;
/**
* The ReadPreset operation gets detailed information about a preset.
*/
readPreset(callback?: (err: AWSError, data: ElasticTranscoder.Types.ReadPresetResponse) => void): Request<ElasticTranscoder.Types.ReadPresetResponse, AWSError>;
/**
* The TestRole operation tests the IAM role used to create the pipeline. The TestRole action lets you determine whether the IAM role you are using has sufficient permissions to let Elastic Transcoder perform tasks associated with the transcoding process. The action attempts to assume the specified IAM role, checks read access to the input and output buckets, and tries to send a test notification to Amazon SNS topics that you specify.
*/
testRole(params: ElasticTranscoder.Types.TestRoleRequest, callback?: (err: AWSError, data: ElasticTranscoder.Types.TestRoleResponse) => void): Request<ElasticTranscoder.Types.TestRoleResponse, AWSError>;
/**
* The TestRole operation tests the IAM role used to create the pipeline. The TestRole action lets you determine whether the IAM role you are using has sufficient permissions to let Elastic Transcoder perform tasks associated with the transcoding process. The action attempts to assume the specified IAM role, checks read access to the input and output buckets, and tries to send a test notification to Amazon SNS topics that you specify.
*/
testRole(callback?: (err: AWSError, data: ElasticTranscoder.Types.TestRoleResponse) => void): Request<ElasticTranscoder.Types.TestRoleResponse, AWSError>;
/**
* Use the UpdatePipeline operation to update settings for a pipeline. When you change pipeline settings, your changes take effect immediately. Jobs that you have already submitted and that Elastic Transcoder has not started to process are affected in addition to jobs that you submit after you change settings.
*/
updatePipeline(params: ElasticTranscoder.Types.UpdatePipelineRequest, callback?: (err: AWSError, data: ElasticTranscoder.Types.UpdatePipelineResponse) => void): Request<ElasticTranscoder.Types.UpdatePipelineResponse, AWSError>;
/**
* Use the UpdatePipeline operation to update settings for a pipeline. When you change pipeline settings, your changes take effect immediately. Jobs that you have already submitted and that Elastic Transcoder has not started to process are affected in addition to jobs that you submit after you change settings.
*/
updatePipeline(callback?: (err: AWSError, data: ElasticTranscoder.Types.UpdatePipelineResponse) => void): Request<ElasticTranscoder.Types.UpdatePipelineResponse, AWSError>;
/**
* With the UpdatePipelineNotifications operation, you can update Amazon Simple Notification Service (Amazon SNS) notifications for a pipeline. When you update notifications for a pipeline, Elastic Transcoder returns the values that you specified in the request.
*/
updatePipelineNotifications(params: ElasticTranscoder.Types.UpdatePipelineNotificationsRequest, callback?: (err: AWSError, data: ElasticTranscoder.Types.UpdatePipelineNotificationsResponse) => void): Request<ElasticTranscoder.Types.UpdatePipelineNotificationsResponse, AWSError>;
/**
* With the UpdatePipelineNotifications operation, you can update Amazon Simple Notification Service (Amazon SNS) notifications for a pipeline. When you update notifications for a pipeline, Elastic Transcoder returns the values that you specified in the request.
*/
updatePipelineNotifications(callback?: (err: AWSError, data: ElasticTranscoder.Types.UpdatePipelineNotificationsResponse) => void): Request<ElasticTranscoder.Types.UpdatePipelineNotificationsResponse, AWSError>;
/**
* The UpdatePipelineStatus operation pauses or reactivates a pipeline, so that the pipeline stops or restarts the processing of jobs. Changing the pipeline status is useful if you want to cancel one or more jobs. You can't cancel jobs after Elastic Transcoder has started processing them; if you pause the pipeline to which you submitted the jobs, you have more time to get the job IDs for the jobs that you want to cancel, and to send a CancelJob request.
*/
updatePipelineStatus(params: ElasticTranscoder.Types.UpdatePipelineStatusRequest, callback?: (err: AWSError, data: ElasticTranscoder.Types.UpdatePipelineStatusResponse) => void): Request<ElasticTranscoder.Types.UpdatePipelineStatusResponse, AWSError>;
/**
* The UpdatePipelineStatus operation pauses or reactivates a pipeline, so that the pipeline stops or restarts the processing of jobs. Changing the pipeline status is useful if you want to cancel one or more jobs. You can't cancel jobs after Elastic Transcoder has started processing them; if you pause the pipeline to which you submitted the jobs, you have more time to get the job IDs for the jobs that you want to cancel, and to send a CancelJob request.
*/
updatePipelineStatus(callback?: (err: AWSError, data: ElasticTranscoder.Types.UpdatePipelineStatusResponse) => void): Request<ElasticTranscoder.Types.UpdatePipelineStatusResponse, AWSError>;
/**
* Waits for the jobComplete state by periodically calling the underlying ElasticTranscoder.readJoboperation every 30 seconds (at most 120 times).
*/
waitFor(state: "jobComplete", params: ElasticTranscoder.Types.ReadJobRequest & {$waiter?: WaiterConfiguration}, callback?: (err: AWSError, data: ElasticTranscoder.Types.ReadJobResponse) => void): Request<ElasticTranscoder.Types.ReadJobResponse, AWSError>;
/**
* Waits for the jobComplete state by periodically calling the underlying ElasticTranscoder.readJoboperation every 30 seconds (at most 120 times).
*/
waitFor(state: "jobComplete", callback?: (err: AWSError, data: ElasticTranscoder.Types.ReadJobResponse) => void): Request<ElasticTranscoder.Types.ReadJobResponse, AWSError>;
}
declare namespace ElasticTranscoder {
export type AccessControl = string;
export type AccessControls = AccessControl[];
export interface Artwork {
/**
* The name of the file to be used as album art. To determine which Amazon S3 bucket contains the specified file, Elastic Transcoder checks the pipeline specified by PipelineId; the InputBucket object in that pipeline identifies the bucket. If the file name includes a prefix, for example, cooking/pie.jpg, include the prefix in the key. If the file isn't in the specified bucket, Elastic Transcoder returns an error.
*/
InputKey?: WatermarkKey;
/**
* The maximum width of the output album art in pixels. If you specify auto, Elastic Transcoder uses 600 as the default value. If you specify a numeric value, enter an even integer between 32 and 4096, inclusive.
*/
MaxWidth?: DigitsOrAuto;
/**
* The maximum height of the output album art in pixels. If you specify auto, Elastic Transcoder uses 600 as the default value. If you specify a numeric value, enter an even integer between 32 and 3072, inclusive.
*/
MaxHeight?: DigitsOrAuto;
/**
* Specify one of the following values to control scaling of the output album art: Fit: Elastic Transcoder scales the output art so it matches the value that you specified in either MaxWidth or MaxHeight without exceeding the other value. Fill: Elastic Transcoder scales the output art so it matches the value that you specified in either MaxWidth or MaxHeight and matches or exceeds the other value. Elastic Transcoder centers the output art and then crops it in the dimension (if any) that exceeds the maximum value. Stretch: Elastic Transcoder stretches the output art to match the values that you specified for MaxWidth and MaxHeight. If the relative proportions of the input art and the output art are different, the output art will be distorted. Keep: Elastic Transcoder does not scale the output art. If either dimension of the input art exceeds the values that you specified for MaxWidth and MaxHeight, Elastic Transcoder crops the output art. ShrinkToFit: Elastic Transcoder scales the output art down so that its dimensions match the values that you specified for at least one of MaxWidth and MaxHeight without exceeding either value. If you specify this option, Elastic Transcoder does not scale the art up. ShrinkToFill Elastic Transcoder scales the output art down so that its dimensions match the values that you specified for at least one of MaxWidth and MaxHeight without dropping below either value. If you specify this option, Elastic Transcoder does not scale the art up.
*/
SizingPolicy?: SizingPolicy;
/**
* When you set PaddingPolicy to Pad, Elastic Transcoder may add white bars to the top and bottom and/or left and right sides of the output album art to make the total size of the output art match the values that you specified for MaxWidth and MaxHeight.
*/
PaddingPolicy?: PaddingPolicy;
/**
* The format of album art, if any. Valid formats are .jpg and .png.
*/
AlbumArtFormat?: JpgOrPng;
/**
* The encryption settings, if any, that you want Elastic Transcoder to apply to your artwork.
*/
Encryption?: Encryption;
}
export type Artworks = Artwork[];
export type Ascending = string;
export type AspectRatio = string;
export type AudioBitDepth = string;
export type AudioBitOrder = string;
export type AudioBitRate = string;
export type AudioChannels = string;
export type AudioCodec = string;
export interface AudioCodecOptions {
/**
* You can only choose an audio profile when you specify AAC for the value of Audio:Codec. Specify the AAC profile for the output file. Elastic Transcoder supports the following profiles: auto: If you specify auto, Elastic Transcoder selects the profile based on the bit rate selected for the output file. AAC-LC: The most common AAC profile. Use for bit rates larger than 64 kbps. HE-AAC: Not supported on some older players and devices. Use for bit rates between 40 and 80 kbps. HE-AACv2: Not supported on some players and devices. Use for bit rates less than 48 kbps. All outputs in a Smooth playlist must have the same value for Profile. If you created any presets before AAC profiles were added, Elastic Transcoder automatically updated your presets to use AAC-LC. You can change the value as required.
*/
Profile?: AudioCodecProfile;
/**
* You can only choose an audio bit depth when you specify flac or pcm for the value of Audio:Codec. The bit depth of a sample is how many bits of information are included in the audio samples. The higher the bit depth, the better the audio, but the larger the file. Valid values are 16 and 24. The most common bit depth is 24.
*/
BitDepth?: AudioBitDepth;
/**
* You can only choose an audio bit order when you specify pcm for the value of Audio:Codec. The order the bits of a PCM sample are stored in. The supported value is LittleEndian.
*/
BitOrder?: AudioBitOrder;
/**
* You can only choose whether an audio sample is signed when you specify pcm for the value of Audio:Codec. Whether audio samples are represented with negative and positive numbers (signed) or only positive numbers (unsigned). The supported value is Signed.
*/
Signed?: AudioSigned;
}
export type AudioCodecProfile = string;
export type AudioPackingMode = string;
export interface AudioParameters {
/**
* The audio codec for the output file. Valid values include aac, flac, mp2, mp3, pcm, and vorbis.
*/
Codec?: AudioCodec;
/**
* The sample rate of the audio stream in the output file, in Hertz. Valid values include: auto, 22050, 32000, 44100, 48000, 96000 If you specify auto, Elastic Transcoder automatically detects the sample rate.
*/
SampleRate?: AudioSampleRate;
/**
* The bit rate of the audio stream in the output file, in kilobits/second. Enter an integer between 64 and 320, inclusive.
*/
BitRate?: AudioBitRate;
/**
* The number of audio channels in the output file. The following values are valid: auto, 0, 1, 2 One channel carries the information played by a single speaker. For example, a stereo track with two channels sends one channel to the left speaker, and the other channel to the right speaker. The output channels are organized into tracks. If you want Elastic Transcoder to automatically detect the number of audio channels in the input file and use that value for the output file, select auto. The output of a specific channel value and inputs are as follows: auto channel specified, with any input: Pass through up to eight input channels. 0 channels specified, with any input: Audio omitted from the output. 1 channel specified, with at least one input channel: Mono sound. 2 channels specified, with any input: Two identical mono channels or stereo. For more information about tracks, see Audio:AudioPackingMode. For more information about how Elastic Transcoder organizes channels and tracks, see Audio:AudioPackingMode.
*/
Channels?: AudioChannels;
/**
* The method of organizing audio channels and tracks. Use Audio:Channels to specify the number of channels in your output, and Audio:AudioPackingMode to specify the number of tracks and their relation to the channels. If you do not specify an Audio:AudioPackingMode, Elastic Transcoder uses SingleTrack. The following values are valid: SingleTrack, OneChannelPerTrack, and OneChannelPerTrackWithMosTo8Tracks When you specify SingleTrack, Elastic Transcoder creates a single track for your output. The track can have up to eight channels. Use SingleTrack for all non-mxf containers. The outputs of SingleTrack for a specific channel value and inputs are as follows: 0 channels with any input: Audio omitted from the output 1, 2, or auto channels with no audio input: Audio omitted from the output 1 channel with any input with audio: One track with one channel, downmixed if necessary 2 channels with one track with one channel: One track with two identical channels 2 or auto channels with two tracks with one channel each: One track with two channels 2 or auto channels with one track with two channels: One track with two channels 2 channels with one track with multiple channels: One track with two channels auto channels with one track with one channel: One track with one channel auto channels with one track with multiple channels: One track with multiple channels When you specify OneChannelPerTrack, Elastic Transcoder creates a new track for every channel in your output. Your output can have up to eight single-channel tracks. The outputs of OneChannelPerTrack for a specific channel value and inputs are as follows: 0 channels with any input: Audio omitted from the output 1, 2, or auto channels with no audio input: Audio omitted from the output 1 channel with any input with audio: One track with one channel, downmixed if necessary 2 channels with one track with one channel: Two tracks with one identical channel each 2 or auto channels with two tracks with one channel each: Two tracks with one channel each 2 or auto channels with one track with two channels: Two tracks with one channel each 2 channels with one track with multiple channels: Two tracks with one channel each auto channels with one track with one channel: One track with one channel auto channels with one track with multiple channels: Up to eight tracks with one channel each When you specify OneChannelPerTrackWithMosTo8Tracks, Elastic Transcoder creates eight single-channel tracks for your output. All tracks that do not contain audio data from an input channel are MOS, or Mit Out Sound, tracks. The outputs of OneChannelPerTrackWithMosTo8Tracks for a specific channel value and inputs are as follows: 0 channels with any input: Audio omitted from the output 1, 2, or auto channels with no audio input: Audio omitted from the output 1 channel with any input with audio: One track with one channel, downmixed if necessary, plus six MOS tracks 2 channels with one track with one channel: Two tracks with one identical channel each, plus six MOS tracks 2 or auto channels with two tracks with one channel each: Two tracks with one channel each, plus six MOS tracks 2 or auto channels with one track with two channels: Two tracks with one channel each, plus six MOS tracks 2 channels with one track with multiple channels: Two tracks with one channel each, plus six MOS tracks auto channels with one track with one channel: One track with one channel, plus seven MOS tracks auto channels with one track with multiple channels: Up to eight tracks with one channel each, plus MOS tracks until there are eight tracks in all
*/
AudioPackingMode?: AudioPackingMode;
/**
* If you specified AAC for Audio:Codec, this is the AAC compression profile to use. Valid values include: auto, AAC-LC, HE-AAC, HE-AACv2 If you specify auto, Elastic Transcoder chooses a profile based on the bit rate of the output file.
*/
CodecOptions?: AudioCodecOptions;
}
export type AudioSampleRate = string;
export type AudioSigned = string;
export type Base64EncodedString = string;
export type BucketName = string;
export interface CancelJobRequest {
/**
* The identifier of the job that you want to cancel. To get a list of the jobs (including their jobId) that have a status of Submitted, use the ListJobsByStatus API action.
*/
Id: Id;
}
export interface CancelJobResponse {
}
export interface CaptionFormat {
/**
* The format you specify determines whether Elastic Transcoder generates an embedded or sidecar caption for this output. Valid Embedded Caption Formats: for FLAC: None For MP3: None For MP4: mov-text For MPEG-TS: None For ogg: None For webm: None Valid Sidecar Caption Formats: Elastic Transcoder supports dfxp (first div element only), scc, srt, and webvtt. If you want ttml or smpte-tt compatible captions, specify dfxp as your output format. For FMP4: dfxp Non-FMP4 outputs: All sidecar types fmp4 captions have an extension of .ismt
*/
Format?: CaptionFormatFormat;
/**
* The prefix for caption filenames, in the form description-{language}, where: description is a description of the video. {language} is a literal value that Elastic Transcoder replaces with the two- or three-letter code for the language of the caption in the output file names. If you don't include {language} in the file name pattern, Elastic Transcoder automatically appends "{language}" to the value that you specify for the description. In addition, Elastic Transcoder automatically appends the count to the end of the segment files. For example, suppose you're transcoding into srt format. When you enter "Sydney-{language}-sunrise", and the language of the captions is English (en), the name of the first caption file is be Sydney-en-sunrise00000.srt.
*/
Pattern?: CaptionFormatPattern;
/**
* The encryption settings, if any, that you want Elastic Transcoder to apply to your caption formats.
*/
Encryption?: Encryption;
}
export type CaptionFormatFormat = string;
export type CaptionFormatPattern = string;
export type CaptionFormats = CaptionFormat[];
export type CaptionMergePolicy = string;
export interface CaptionSource {
/**
* The name of the sidecar caption file that you want Elastic Transcoder to include in the output file.
*/
Key?: LongKey;
/**
* A string that specifies the language of the caption. If you specified multiple inputs with captions, the caption language must match in order to be included in the output. Specify this as one of: 2-character ISO 639-1 code 3-character ISO 639-2 code For more information on ISO language codes and language names, see the List of ISO 639-1 codes.
*/
Language?: Key;
/**
* For clip generation or captions that do not start at the same time as the associated video file, the TimeOffset tells Elastic Transcoder how much of the video to encode before including captions. Specify the TimeOffset in the form [+-]SS.sss or [+-]HH:mm:SS.ss.
*/
TimeOffset?: TimeOffset;
/**
* The label of the caption shown in the player when choosing a language. We recommend that you put the caption language name here, in the language of the captions.
*/
Label?: Name;
/**
* The encryption settings, if any, that Elastic Transcoder needs to decyrpt your caption sources, or that you want Elastic Transcoder to apply to your caption sources.
*/
Encryption?: Encryption;
}
export type CaptionSources = CaptionSource[];
export interface Captions {
/**
* A policy that determines how Elastic Transcoder handles the existence of multiple captions. MergeOverride: Elastic Transcoder transcodes both embedded and sidecar captions into outputs. If captions for a language are embedded in the input file and also appear in a sidecar file, Elastic Transcoder uses the sidecar captions and ignores the embedded captions for that language. MergeRetain: Elastic Transcoder transcodes both embedded and sidecar captions into outputs. If captions for a language are embedded in the input file and also appear in a sidecar file, Elastic Transcoder uses the embedded captions and ignores the sidecar captions for that language. If CaptionSources is empty, Elastic Transcoder omits all sidecar captions from the output files. Override: Elastic Transcoder transcodes only the sidecar captions that you specify in CaptionSources. MergePolicy cannot be null.
*/
MergePolicy?: CaptionMergePolicy;
/**
* Source files for the input sidecar captions used during the transcoding process. To omit all sidecar captions, leave CaptionSources blank.
*/
CaptionSources?: CaptionSources;
/**
* The array of file formats for the output captions. If you leave this value blank, Elastic Transcoder returns an error.
*/
CaptionFormats?: CaptionFormats;
}
export interface Clip {
/**
* Settings that determine when a clip begins and how long it lasts.
*/
TimeSpan?: TimeSpan;
}
export type CodecOption = string;
export type CodecOptions = {[key: string]: CodecOption};
export type Composition = Clip[];
export interface CreateJobOutput {
/**
* The name to assign to the transcoded file. Elastic Transcoder saves the file in the Amazon S3 bucket specified by the OutputBucket object in the pipeline that is specified by the pipeline ID. If a file with the specified name already exists in the output bucket, the job fails.
*/
Key?: Key;
/**
* Whether you want Elastic Transcoder to create thumbnails for your videos and, if so, how you want Elastic Transcoder to name the files. If you don't want Elastic Transcoder to create thumbnails, specify "". If you do want Elastic Transcoder to create thumbnails, specify the information that you want to include in the file name for each thumbnail. You can specify the following values in any sequence: {count} (Required): If you want to create thumbnails, you must include {count} in the ThumbnailPattern object. Wherever you specify {count}, Elastic Transcoder adds a five-digit sequence number (beginning with 00001) to thumbnail file names. The number indicates where a given thumbnail appears in the sequence of thumbnails for a transcoded file. If you specify a literal value and/or {resolution} but you omit {count}, Elastic Transcoder returns a validation error and does not create the job. Literal values (Optional): You can specify literal values anywhere in the ThumbnailPattern object. For example, you can include them as a file name prefix or as a delimiter between {resolution} and {count}. {resolution} (Optional): If you want Elastic Transcoder to include the resolution in the file name, include {resolution} in the ThumbnailPattern object. When creating thumbnails, Elastic Transcoder automatically saves the files in the format (.jpg or .png) that appears in the preset that you specified in the PresetID value of CreateJobOutput. Elastic Transcoder also appends the applicable file name extension.
*/
ThumbnailPattern?: ThumbnailPattern;
/**
* The encryption settings, if any, that you want Elastic Transcoder to apply to your thumbnail.
*/
ThumbnailEncryption?: Encryption;
/**
* The number of degrees clockwise by which you want Elastic Transcoder to rotate the output relative to the input. Enter one of the following values: auto, 0, 90, 180, 270. The value auto generally works only if the file that you're transcoding contains rotation metadata.
*/
Rotate?: Rotate;
/**
* The Id of the preset to use for this job. The preset determines the audio, video, and thumbnail settings that Elastic Transcoder uses for transcoding.
*/
PresetId?: Id;
/**
* (Outputs in Fragmented MP4 or MPEG-TS format only. If you specify a preset in PresetId for which the value of Container is fmp4 (Fragmented MP4) or ts (MPEG-TS), SegmentDuration is the target maximum duration of each segment in seconds. For HLSv3 format playlists, each media segment is stored in a separate .ts file. For HLSv4 and Smooth playlists, all media segments for an output are stored in a single file. Each segment is approximately the length of the SegmentDuration, though individual segments might be shorter or longer. The range of valid values is 1 to 60 seconds. If the duration of the video is not evenly divisible by SegmentDuration, the duration of the last segment is the remainder of total length/SegmentDuration. Elastic Transcoder creates an output-specific playlist for each output HLS output that you specify in OutputKeys. To add an output to the master playlist for this job, include it in the OutputKeys of the associated playlist.
*/
SegmentDuration?: FloatString;
/**
* Information about the watermarks that you want Elastic Transcoder to add to the video during transcoding. You can specify up to four watermarks for each output. Settings for each watermark must be defined in the preset for the current output.
*/
Watermarks?: JobWatermarks;
/**
* Information about the album art that you want Elastic Transcoder to add to the file during transcoding. You can specify up to twenty album artworks for each output. Settings for each artwork must be defined in the job for the current output.
*/
AlbumArt?: JobAlbumArt;
/**
* You can create an output file that contains an excerpt from the input file. This excerpt, called a clip, can come from the beginning, middle, or end of the file. The Composition object contains settings for the clips that make up an output file. For the current release, you can only specify settings for a single clip per output file. The Composition object cannot be null.
*/
Composition?: Composition;
/**
* You can configure Elastic Transcoder to transcode captions, or subtitles, from one format to another. All captions must be in UTF-8. Elastic Transcoder supports two types of captions: Embedded: Embedded captions are included in the same file as the audio and video. Elastic Transcoder supports only one embedded caption per language, to a maximum of 300 embedded captions per file. Valid input values include: CEA-608 (EIA-608, first non-empty channel only), CEA-708 (EIA-708, first non-empty channel only), and mov-text Valid outputs include: mov-text Elastic Transcoder supports a maximum of one embedded format per output. Sidecar: Sidecar captions are kept in a separate metadata file from the audio and video data. Sidecar captions require a player that is capable of understanding the relationship between the video file and the sidecar file. Elastic Transcoder supports only one sidecar caption per language, to a maximum of 20 sidecar captions per file. Valid input values include: dfxp (first div element only), ebu-tt, scc, smpt, srt, ttml (first div element only), and webvtt Valid outputs include: dfxp (first div element only), scc, srt, and webvtt. If you want ttml or smpte-tt compatible captions, specify dfxp as your output format. Elastic Transcoder does not support OCR (Optical Character Recognition), does not accept pictures as a valid input for captions, and is not available for audio-only transcoding. Elastic Transcoder does not preserve text formatting (for example, italics) during the transcoding process. To remove captions or leave the captions empty, set Captions to null. To pass through existing captions unchanged, set the MergePolicy to MergeRetain, and pass in a null CaptionSources array. For more information on embedded files, see the Subtitles Wikipedia page. For more information on sidecar files, see the Extensible Metadata Platform and Sidecar file Wikipedia pages.
*/
Captions?: Captions;
/**
* You can specify encryption settings for any output files that you want to use for a transcoding job. This includes the output file and any watermarks, thumbnails, album art, or captions that you want to use. You must specify encryption settings for each file individually.
*/
Encryption?: Encryption;
}
export type CreateJobOutputs = CreateJobOutput[];
export interface CreateJobPlaylist {
/**
* The name that you want Elastic Transcoder to assign to the master playlist, for example, nyc-vacation.m3u8. If the name includes a / character, the section of the name before the last / must be identical for all Name objects. If you create more than one master playlist, the values of all Name objects must be unique. Elastic Transcoder automatically appends the relevant file extension to the file name (.m3u8 for HLSv3 and HLSv4 playlists, and .ism and .ismc for Smooth playlists). If you include a file extension in Name, the file name will have two extensions.
*/
Name?: Filename;
/**
* The format of the output playlist. Valid formats include HLSv3, HLSv4, and Smooth.
*/
Format?: PlaylistFormat;
/**
* For each output in this job that you want to include in a master playlist, the value of the Outputs:Key object. If your output is not HLS or does not have a segment duration set, the name of the output file is a concatenation of OutputKeyPrefix and Outputs:Key: OutputKeyPrefixOutputs:Key If your output is HLSv3 and has a segment duration set, or is not included in a playlist, Elastic Transcoder creates an output playlist file with a file extension of .m3u8, and a series of .ts files that include a five-digit sequential counter beginning with 00000: OutputKeyPrefixOutputs:Key.m3u8 OutputKeyPrefixOutputs:Key00000.ts If your output is HLSv4, has a segment duration set, and is included in an HLSv4 playlist, Elastic Transcoder creates an output playlist file with a file extension of _v4.m3u8. If the output is video, Elastic Transcoder also creates an output file with an extension of _iframe.m3u8: OutputKeyPrefixOutputs:Key_v4.m3u8 OutputKeyPrefixOutputs:Key_iframe.m3u8 OutputKeyPrefixOutputs:Key.ts Elastic Transcoder automatically appends the relevant file extension to the file name. If you include a file extension in Output Key, the file name will have two extensions. If you include more than one output in a playlist, any segment duration settings, clip settings, or caption settings must be the same for all outputs in the playlist. For Smooth playlists, the Audio:Profile, Video:Profile, and Video:FrameRate to Video:KeyframesMaxDist ratio must be the same for all outputs.
*/
OutputKeys?: OutputKeys;
/**
* The HLS content protection settings, if any, that you want Elastic Transcoder to apply to the output files associated with this playlist.
*/
HlsContentProtection?: HlsContentProtection;
/**
* The DRM settings, if any, that you want Elastic Transcoder to apply to the output files associated with this playlist.
*/
PlayReadyDrm?: PlayReadyDrm;
}
export type CreateJobPlaylists = CreateJobPlaylist[];
export interface CreateJobRequest {
/**
* The Id of the pipeline that you want Elastic Transcoder to use for transcoding. The pipeline determines several settings, including the Amazon S3 bucket from which Elastic Transcoder gets the files to transcode and the bucket into which Elastic Transcoder puts the transcoded files.
*/
PipelineId: Id;
/**
* A section of the request body that provides information about the file that is being transcoded.
*/
Input?: JobInput;
/**
* A section of the request body that provides information about the files that are being transcoded.
*/
Inputs?: JobInputs;
/**
* A section of the request body that provides information about the transcoded (target) file. We strongly recommend that you use the Outputs syntax instead of the Output syntax.
*/
Output?: CreateJobOutput;
/**
* A section of the request body that provides information about the transcoded (target) files. We recommend that you use the Outputs syntax instead of the Output syntax.
*/
Outputs?: CreateJobOutputs;
/**
* The value, if any, that you want Elastic Transcoder to prepend to the names of all files that this job creates, including output files, thumbnails, and playlists.
*/
OutputKeyPrefix?: Key;
/**
* If you specify a preset in PresetId for which the value of Container is fmp4 (Fragmented MP4) or ts (MPEG-TS), Playlists contains information about the master playlists that you want Elastic Transcoder to create. The maximum number of master playlists in a job is 30.
*/
Playlists?: CreateJobPlaylists;
/**
* User-defined metadata that you want to associate with an Elastic Transcoder job. You specify metadata in key/value pairs, and you can add up to 10 key/value pairs per job. Elastic Transcoder does not guarantee that key/value pairs are returned in the same order in which you specify them.
*/
UserMetadata?: UserMetadata;
}
export interface CreateJobResponse {
/**
* A section of the response body that provides information about the job that is created.
*/
Job?: Job;
}
export interface CreatePipelineRequest {
/**
* The name of the pipeline. We recommend that the name be unique within the AWS account, but uniqueness is not enforced. Constraints: Maximum 40 characters.
*/
Name: Name;
/**
* The Amazon S3 bucket in which you saved the media files that you want to transcode.
*/
InputBucket: BucketName;
/**
* The Amazon S3 bucket in which you want Elastic Transcoder to save the transcoded files. (Use this, or use ContentConfig:Bucket plus ThumbnailConfig:Bucket.) Specify this value when all of the following are true: You want to save transcoded files, thumbnails (if any), and playlists (if any) together in one bucket. You do not want to specify the users or groups who have access to the transcoded files, thumbnails, and playlists. You do not want to specify the permissions that Elastic Transcoder grants to the files. When Elastic Transcoder saves files in OutputBucket, it grants full control over the files only to the AWS account that owns the role that is specified by Role. You want to associate the transcoded files and thumbnails with the Amazon S3 Standard storage class. If you want to save transcoded files and playlists in one bucket and thumbnails in another bucket, specify which users can access the transcoded files or the permissions the users have, or change the Amazon S3 storage class, omit OutputBucket and specify values for ContentConfig and ThumbnailConfig instead.
*/
OutputBucket?: BucketName;
/**
* The IAM Amazon Resource Name (ARN) for the role that you want Elastic Transcoder to use to create the pipeline.
*/
Role: Role;
/**
* The AWS Key Management Service (AWS KMS) key that you want to use with this pipeline. If you use either s3 or s3-aws-kms as your Encryption:Mode, you don't need to provide a key with your job because a default key, known as an AWS-KMS key, is created for you automatically. You need to provide an AWS-KMS key only if you want to use a non-default AWS-KMS key, or if you are using an Encryption:Mode of aes-cbc-pkcs7, aes-ctr, or aes-gcm.
*/
AwsKmsKeyArn?: KeyArn;
/**
* The Amazon Simple Notification Service (Amazon SNS) topic that you want to notify to report job status. To receive notifications, you must also subscribe to the new topic in the Amazon SNS console. Progressing: The topic ARN for the Amazon Simple Notification Service (Amazon SNS) topic that you want to notify when Elastic Transcoder has started to process a job in this pipeline. This is the ARN that Amazon SNS returned when you created the topic. For more information, see Create a Topic in the Amazon Simple Notification Service Developer Guide. Complete: The topic ARN for the Amazon SNS topic that you want to notify when Elastic Transcoder has finished processing a job in this pipeline. This is the ARN that Amazon SNS returned when you created the topic. Warning: The topic ARN for the Amazon SNS topic that you want to notify when Elastic Transcoder encounters a warning condition while processing a job in this pipeline. This is the ARN that Amazon SNS returned when you created the topic. Error: The topic ARN for the Amazon SNS topic that you want to notify when Elastic Transcoder encounters an error condition while processing a job in this pipeline. This is the ARN that Amazon SNS returned when you created the topic.
*/
Notifications?: Notifications;
/**
* The optional ContentConfig object specifies information about the Amazon S3 bucket in which you want Elastic Transcoder to save transcoded files and playlists: which bucket to use, which users you want to have access to the files, the type of access you want users to