

サポート終了通知: 2025 年 11 月 13 日、 AWS は Amazon Elastic Transcoder のサポートを終了します。2025 年 11 月 13 日以降、Elastic Transcoder コンソールまたは Elastic Transcoder リソースにアクセスできなくなります。

への移行の詳細については AWS Elemental MediaConvert、この[ブログ記事](https://aws.amazon.com/blogs/media/how-to-migrate-workflows-from-amazon-elastic-transcoder-to-aws-elemental-mediaconvert/)を参照してください。

翻訳は機械翻訳により提供されています。提供された翻訳内容と英語版の間で齟齬、不一致または矛盾がある場合、英語版が優先します。

# ジョブの読み取り
<a name="get-job"></a>

**Topics**
+ [説明](#get-job-description)
+ [リクエスト](#get-job-requests)
+ [レスポンス](#get-job-responses)
+ [エラー](#get-job-response-errors)
+ [例](#get-job-examples)

## 説明
<a name="get-job-description"></a>

ジョブに関する詳細情報を取得するには、`/2012-09-25/jobs/{{jobId}}` リソースに GET リクエストを送信します。

## リクエスト
<a name="get-job-requests"></a>

### 構文
<a name="get-job-request-syntax"></a>

```
GET /2012-09-25/jobs/jobId HTTP/1.1
Content-Type: charset=UTF-8
Accept: */*
Host: elastictranscoder.{{Elastic Transcoder endpoint}}.amazonaws.com:443
x-amz-date: 20130114T174952Z
Authorization: AWS4-HMAC-SHA256
               Credential={{AccessKeyID}}/{{request-date}}/{{Elastic Transcoder endpoint}}/elastictranscoder/aws4_request,
               SignedHeaders=host;x-amz-date;x-amz-target,
               Signature={{calculated-signature}}
```

### リクエストパラメータ
<a name="get-job-request-parameters"></a>

このオペレーションでは、次のリクエストパラメーターを使用します。

**JobId**  
詳細情報を取得するジョブの識別子。

### リクエストヘッダー
<a name="get-job-request-headers"></a>

このオペレーションは、すべてのオペレーションに共通のリクエストヘッダーのみを使用します。共通のリクエストヘッダーの詳細については、「[HTTP ヘッダーの内容](making-http-requests.md#http-request-header)」を参照してください。

### リクエスト本文
<a name="get-job-request-body"></a>

この操作にリクエストボディはありません。

## レスポンス
<a name="get-job-responses"></a>

### 構文
<a name="get-job-response-syntax"></a>

```
Status: 200 OK
x-amzn-RequestId: c321ec43-378e-11e2-8e4c-4d5b971203e9
Content-Type: application/json
Content-Length: {{number of characters in the response}}
Date: Mon, 14 Jan 2013 06:01:47 GMT

{
   "Job":{
      "Id":"{{Id that Elastic Transcoder assigned to the job}}",
      "Inputs":[{
         "Key":"{{name of the file to transcode}}",
         "Encryption":{
            "Mode":"aes-cbc-pkcs7|aes-ctr|aes-gcm",
            "Key":"{{encrypted and base64-encoded decryption key}}",
            "KeyMd5":"{{base64-encoded key digest}}",
            "InitializationVector":"{{base64-encoded initialization vector}}"
         },
         "TimeSpan":{
            "StartTime":"{{starting place of the clip, in
               HH:mm:ss.SSS or sssss.SSS}}",
            "Duration":"{{duration of the clip, in HH:mm:ss.SSS
               or sssss.SSS}}"
         },
         "FrameRate":"auto|10|15|23.97|24|25|29.97|30|50|60",
         "Resolution":"auto|{{width in pixels}}x{{height in pixels}}",
         "AspectRatio":"auto|1:1|4:3|3:2|16:9",
         "Interlaced":"auto|true|false",
         "Container":"auto|aac|asf|avi|divx|flv|m4a|mkv|mov|mp2|mp3|
            mp4|mpeg|mpeg-ps|mpeg-ts|mxf|ogg|vob|wav|webm",
         "DetectedProperties":{
            "Width":"{{video width in pixels}}",
            "Height":"{{video height in pixels}}",
            "FrameRate":"{{video frame rate in fps}}",
            "FileSize":"{{file size in bytes}}",
            "DurationMillis":"{{file duration in milliseconds}}"
         },
         "InputCaptions":{
            "MergePolicy":"MergeOverride|MergeRetain|Override",
            "CaptionSources":[
               {
                  "Key":"{{name of the input caption file}}",
                  "Language":"{{language of the input caption file}}",
                  "TimeOffset":"{{starting place of the captions, in
                     either [-+]SS.sss or [-+]HH:mm:SS.ss}}",
                  "Label":"{{label for the caption}}"
                  "Encryption":{
                     "Mode":"aes-cbc-pkcs7|aes-ctr|aes-gcm",
                     "Key":"{{encrypted and base64-encoded decryption key}}",
                     "KeyMd5":"{{base64-encoded key digest}}",
                     "InitializationVector":"{{base64-encoded initialization 
                        vector}}"
                  },
               },
               {...}
            ]
         }
      },
   {...}],
   "OutputKeyPrefix":"{{prefix for file names in Amazon S3 bucket}}",
   "Outputs":[{
         "Id":"{{sequential counter}}",
         "Key":"{{name of the transcoded file}}",
         "Encryption":{
            "Mode":"s3||aes-cbc-pkcs7|aes-ctr|
               aes-gcm",
            "Key":"{{encrypted and base64-encoded encryption key}}",
            "KeyMd5":"{{base64-encoded key digest}}",
            "InitializationVector":"{{base64-encoded initialization vector}}"           
         },
         "ThumbnailPattern":""|"{{pattern}}",
         "Rotate":"auto|0|90|180|270",
         "PresetId":"{{preset to use for the job}}",
         "SegmentDuration":"[1,60]",
         "Watermarks":[
            {
               "InputKey":"{{name of the .png or .jpg file}}",
               "Encryption":{
                  "Mode":"s3||aes-cbc-pkcs7|
                     aes-ctr|aes-gcm",
                  "Key":"{{encrypted and base64-encoded encryption key}}",
                  "KeyMd5":"{{base64-encoded key digest}}",
                  "InitializationVector":"{{base64-encoded initialization 
                     vector}}"
               },
               "PresetWatermarkId":"{{value of Video:Watermarks:Id in 
                  preset}}"
            },
            {...}
         ],
         "AlbumArt":[
            {
               "AlbumArtMerge":"Replace|Prepend|Append|Fallback",
               "AlbumArtArtwork":"{{can be empty, but not null}}":[
                  {
                     "AlbumArtInputKey":"{{name of the file to use as album 
                        art}}",
                     "Encryption":{
                        "Mode":"s3||aes-cbc-pkcs7|
                           aes-ctr|aes-gcm",
                        "Key":"{{encrypted and base64-encoded encryption key}}",
                        "KeyMd5":"{{base64-encoded key digest}}",
                        "InitializationVector":"{{base64-encoded
                           initialization vector}}"
                     },
                     "AlbumArtMaxWidth":"{{maximum width of output album art
                        in pixels}}",
                     "AlbumArtMaxHeight":"{{maximum height of output album
                        art in pixels}}",
                     "AlbumArtSizingPolicy":"Fit|Fill|Stretch|Keep|
                        ShrinkToFit|ShrinkToFill",
                     "AlbumArtPaddingPolicy":"Pad|NoPad",
                     "AlbumArtFormat":"jpg|png"
                  },
                  {...}
               ]
            },
         {...}], 
         "Duration":"{{duration in seconds}}",
         "DurationMillis":"{{duration in milliseconds}}",
         "Height":"{{height in pixels}}",
         "Width":"{{width in pixels}}",
         "FrameRate":"{{frame rate in fps}}",
         "FileSize":"{{file size in bytes}}",
         "Status":"Submitted|In Progress|Complete|Error",
         "StatusDetail":"{{detail associated with Status}}",
         "Captions":{
            "CaptionFormats":[
               {
                  "Format":"cea-708|dfxp|mov-text|scc|srt|webvtt",
                  "Pattern":"{{myCaption/file-language}}",
                  "Encryption":{
                     "Mode":"s3||aes-cbc-pkcs7|
                        aes-ctr|aes-gcm",
                     "Key":"{{encrypted and base64-encoded encryption key}}",
                     "KeyMd5":"{{base64-encoded key digest}}",
                     "InitializationVector":"{{base64-encoded 
                       initialization vector}}"
                  }
               },
               {...}
            ]
         },
         "AppliedColorSpaceConversion":"None|Bt601ToBt709|
            Bt709ToBt601"
      },
      {...}
   ],
   "Playlists":[
      {
         "Format":"HLSv3|HLSv4|MPEG-DASH|Smooth",
         "Name":"{{name}}",
         "OutputKeys":[
            "{{Outputs:Key to include in this playlist}}",
            {...}
         ],
         "HlsContentProtection":{
             "Method":"aes-128",
             "Key":"{{encrypted and base64-encoded protection key}}",
             "KeyMd5":"{{base64-encoded key digest}}",
             "InitializationVector":"{{base64-encoded
                initialization vector}}",
             "LicenseAcquisitionUrl":"{{license acquisition url}}",
             "KeyStoragePolicy":"NoStore|WithVariantPlaylists"
         },
         "PlayReadyDrm":{
             "Format":"microsoft|discretix-3.0",
             "Key":"{{encrypted and base64-encoded DRM key}}",
             "KeyId":"{{id of the DRM key}}",
             "KeyMd5":"{{base64-encoded key digest}}",
             "InitializationVector":"{{base64-encoded
                initialization vector}}",
             "LicenseAcquisitionUrl":"{{license acquisition url}}"
            }
         },
         {...}
      ],
      "UserMetadata":
         {
            "Key":"Value",
            "{{Second user metadata key}}":"{{Second user metadata value}}"
         },
      "PipelineId":"{{PipelineId for the job}}",
      "Status":"Submitted|Progressing|Complete|Canceled|Error",
      "Timing":{
         "SubmitTimeMillis":"{{job submitted time in epoch milliseconds}}",
         "StartTimeMillis":"{{job start time in epoch milliseconds}}",
         "FinishTimeMillis":"{{job finish time in epoch milliseconds}}"
      }
   }
}
```

### レスポンスヘッダー
<a name="get-job-response-headers"></a>

この操作はほとんどのレスポンスに共通のレスポンスヘッダーのみを使用します。共通のレスポンスヘッダーの詳細については、「[HTTP レスポンス](making-http-requests.md#http-response-header)」を参照してください。

### レスポンス本文
<a name="get-job-response-body"></a>

検索条件を満たすジョブごとに、レスポンス本文にはジョブの作成時に指定した値が含まれます。ジョブ値の詳細については、「[Elastic Transcoder ジョブの作成時に指定する設定](job-settings.md)」を参照してください。

また、以下の値も Elastic Transcoder によって返されます。

**(自動) Id**  
Elastic Transcoder でジョブに割り当てられた識別子。この値を使用して、ジョブのプリセットの設定を取得したり、削除したりできます。

**(自動) Inputs:DetectedProperties**  
検出された入力ファイルプロパティ。Elastic Transcoder では、入力ファイルからこれらの値が識別されます。

**(自動) Inputs:Width**  
検出された入力ファイル幅 (ピクセル)。

**(自動) Inputs:Height**  
検出された入力ファイル高さ (ピクセル)。

**(自動) Inputs:FrameRate**  
検出された入力ファイルフレームレート (フレーム/秒)。

**(自動) Inputs: FileSize**  
検出された入力ファイルサイズ (バイト)。

**(自動) Inputs:DurationMillis**  
検出された入力ファイル継続時間 (ミリ秒)。

**(自動) Outputs:Id**  
1 から始まるシーケンシャルカウンター。現在のジョブから出力間の出力を識別します。`Output` 構文ではこの値は常に `1` になります。

**(自動) Outputs:Duration**  
出力ファイルの継続時間 (秒)。端数は切り上げられます。

**(自動) Outputs:DurationMillis**  
出力ファイルの継続時間 (ミリ秒)。

**(自動) Outputs:Width**  
出力ファイルの幅 (ピクセル単位)。

**(自動) Outputs:Height**  
出力ファイルの高さ (ピクセル単位)。

** (自動) Outputs:FrameRate**  
出力ファイルのフレームレート (フレーム/秒)。

**(自動) Outputs:FileSize**  
出力ファイルのファイルサイズ (バイト)。

**(自動) Outputs:Status**  
ジョブ内の 1 つの出力のステータス。ジョブに対して出力を 1 つだけ指定した場合、`Outputs:Status` は常に `Job:Status` と同一になります。複数の出力を指定した場合:  
+ Elastic Transcoder で最初の出力の処理が開始されるまで、すべての出力の `Job:Status` と `Outputs:Status` が `Submitted` になります。
+ Elastic Transcoder で最初の出力の処理が開始されると、その出力の `Outputs:Status` と `Job:Status` の両方が `Progressing` に変わります。各出力については、`Outputs:Status` の値は、Elastic Transcoder で出力の処理が開始されるまで `Submitted` のままになります。
+ `Job:Status` は、すべての出力が終了ステータス (`Complete` または `Error`) に達するまで `Progressing` のままになります。
+ すべての出力が終了ステータスに達すると、すべての出力の `Outputs:Status` が `Complete` である場合のみ、`Job:Status` が `Complete` に変わります。1 つまたは複数の出力の `Outputs:Status` が `Error` になっている場合は、`Job:Status` の終了ステータスも `Error` になります。
`Status` の値は、`Submitted`、`Progressing`、`Complete`、`Canceled`、`Error` のいずれかになります。

**(自動) Outputs:StatusDetail**  
`Outputs:Status` を詳しく説明した情報。

** (自動) Outputs:AppliedColorSpaceConversion**  
Elastic Transcoder で `ColorSpaceConversionMode` とともにプリセットを使用して出力ファイルのトランスコードを行う場合、`AppliedColorSpaceConversion` パラメータは、使用される変換を示します。プリセットで定義されている `ColorSpaceConversionMode` がない場合、このパラメータはジョブ応答に含まれません。

**(自動) Status**  
ジョブに対して複数の出力を指定した場合のジョブ全体のステータス。Elastic Transcoder でジョブの処理が開始された時点で `Job:Status` の値が `Progressing` に変わり、Elastic Transcoderでがすべての出力の処理が完了するまでそれは変わりません。処理が完了すると、`Job:Status` は、`Complete`、または、いずれかの出力が失敗した場合は `Error` に変わります。  
ジョブに対して出力を 1 つだけ指定した場合、`Job:Status` は `Outputs:Status` と同一になります。  
`Job:Status` の値は、`Submitted`、`Progressing`、`Complete`、`Canceled`、`Error` のいずれかになります。

**(自動) Timing**  
ジョブのタイミングに関する詳細。

**(自動) Timing:SubmitTimeMillis**  
ジョブが Elastic Transcoder に送信された時間 (エポックミリ秒単位) 。

**(自動) Timing:StartTimeMillis**  
ジョブがトランスコーディングを開始した時間 (エポックミリ秒単位) 。

**(自動) Timing:FinishTimeMillis**  
ジョブがトランスコーディングを完了した時間 (エポックミリ秒単位) 。  
エポックタイムの詳細については、Wikipediaの「[Epoch (computing)](https://en.wikipedia.org/wiki/Epoch_%28reference_date%29#Computing)」のページを参照してください。

## エラー
<a name="get-job-response-errors"></a>

Elastic Transcoder の例外とエラーメッセージについては、「[Elastic Transcoder でのエラー処理](error-handling.md)」を参照してください。

## 例
<a name="get-job-examples"></a>

### リクエスト例
<a name="get-job-examples-sample-request-1"></a>

次のサンプルリクエストでは、ジョブ ID が 3333333333333-abcde3 であるジョブを取得します。

```
GET /2012-09-25/jobs/3333333333333-abcde3 HTTP/1.1
Content-Type: charset=UTF-8
Accept: */*
Host: elastictranscoder.{{Elastic Transcoder endpoint}}.amazonaws.com:443
x-amz-date: 20130114T174952Z
Authorization: AWS4-HMAC-SHA256
               Credential={{AccessKeyID}}/{{request-date}}/{{Elastic Transcoder endpoint}}/elastictranscoder/aws4_request,
               SignedHeaders=host;x-amz-date;x-amz-target,
               Signature={{calculated-signature}}
```

### レスポンス例
<a name="get-job-examples-sample-response-1"></a>

```
Status: 200 OK
x-amzn-RequestId: c321ec43-378e-11e2-8e4c-4d5b971203e9
Content-Type: application/json
Content-Length: {{number of characters in the response}}
Date: Mon, 14 Jan 2013 06:01:47 GMT

{
   "Job":{
      "Id":"3333333333333-abcde3",
      "Inputs":[{
         "Key":"cooking/lasagna.mp4",
         "FrameRate":"auto",
         "Resolution":"auto",
         "AspectRatio":"auto",
         "Interlaced":"auto",
         "Container":"mp4",
         "InputCaptions":{
            "MergePolicy":"MergeOverride",
            "CaptionSources":[
               {
                  "Key":"scc/lasagna-kindlefirehd.scc",
                  "Language":"en",
                  "Label":"English"
               },
               {
                  "Key":"srt/lasagna-kindlefirehd.srt",
                  "Language":"fr",
                  "TimeOffset":"1:00:00",
                  "Label":"French"
               }
            ],
         }
         "DetectedProperties":{
            "Width":"1280",
            "Height":"720",
            "FrameRate":"30.00",
            "FileSize":"5872000",
            "DurationMillis":"1003000"
         }
      }],
      "OutputKeyPrefix":"",
      "Outputs":[
         {
            "Id":"1",
            "Key":"mp4/lasagna-kindlefirehd.mp4",
            "ThumbnailPattern":"mp4/thumbnails/lasagna-{count}",
            "Rotate":"0",
            "PresetId":"1351620000000-100080",
            "Watermarks":[
               {
                  "InputKey":"logo/128x64.png",
                  "PresetWatermarkId":"company logo 128x64",
               }
            ],
            "Duration":"1003",
            "DurationMillis":"1003000",
            "Width":"1280",
            "Height":"720",
            "FrameRate":"30.00",
            "FileSize":"5872000",
            "Status":"Progressing",
            "StatusDetail":"",
            "Captions":{
               "CaptionFormats":[
                  {
                     "Format":"scc",
                     "Pattern":"scc/lasagna-{language}",
                  },
                  {
                     "Format":"srt",
                     "Pattern":"srt/lasagna-{language}",
                  },
                  {
                     "Format":"mov-text"
                  }
               ]
            }
         },
         {
            "Id":"2",
            "Key":"iphone/lasagna-1024k",
            "ThumbnailPattern":"iphone/th1024k/lasagna-{count}",
            "Rotate":"0",
            "PresetId":"1351620000000-987654",
            "SegmentDuration":"5",
            "Duration":"1003",
            "DurationMillis":"1003000",
            "Width":"1136",
            "Height":"640",
            "FrameRate":"30.00",
            "FileSize":"4718600",
            "Status":"Progressing",
            "StatusDetail":"",
            "AppliedColorSpaceConversion":"None"
         },
         {
            "Id":"3",
            "Key":"iphone/lasagna-512k",
            "ThumbnailPattern":"iphone/th512k/lasagna-{count}",
            "Rotate":"0",
            "PresetId":"1351620000000-456789",
            "SegmentDuration":"5",
            "Duration":"1003",
            "DurationMillis":"1003000",
            "Width":"1136",
            "Height":"640",
            "FrameRate":"30.00",
            "FileSize":"3508900",
            "Status":"Complete",
            "StatusDetail":""
         }
      ],
      "Playlists":[
         {
            "Format":"HLSv3",
            "Name":"playlist-iPhone-lasagna.m3u8",
            "OutputKeys":[
               "iphone/lasagna-1024k",
               "iphone/lasagna-512k"
            ]
         }
      ],
      "UserMetadata":
         {
            "Food type":"Italian",
            "Cook book":"recipe notebook"
         },
      "PipelineId":"1111111111111-abcde1",
      "Status":"Progressing",
      "Timing":{
         "SubmitTime":"1427212800000",
         "StartTime":"1427212856000",
         "FinishTime":"1427212875000"
      }
   }
}
```