# Class Job (1.21.0)

1.21.0 (latest) 1.20.0 1.19.0 1.18.0 1.17.0 1.16.0 1.15.2 1.14.0 1.13.1 1.12.5 1.11.0 1.10.1 1.9.1 1.8.2 1.7.0 1.6.1 1.5.0 1.4.3 1.3.2 1.2.1 1.1.0 1.0.1 0.5.1 0.4.1 0.3.1 0.2.1 0.1.0

    Job(mapping=None, *, ignore_unknown_fields=False, **kwargs)

Transcoding job resource.

This message has `oneof`_ fields (mutually exclusive fields).
For each oneof, at most one member field can be set at the same time.
Setting any member of the oneof automatically clears all other
members.

.. _oneof: <https://proto-plus-python.readthedocs.io/en/stable/fields.html#oneofs-mutually-exclusive-fields>

| ## Attributes ||
|---|---|
| **Name** | **Description** |
| `name` | `str` The resource name of the job. Format: `projects/{project_number}/locations/{location}/jobs/{job}` |
| `input_uri` | `str` Input only. Specify the `input_uri` to populate empty `uri` fields in each element of `Job.config.inputs` or `JobTemplate.config.inputs` when using template. URI of the media. Input files must be at least 5 seconds in duration and stored in Cloud Storage (for example, `gs://bucket/inputs/file.mp4`). See \`Supported input and output formats |
| `output_uri` | `str` Input only. Specify the `output_uri` to populate an empty `Job.config.output.uri` or `JobTemplate.config.output.uri` when using template. URI for the output file(s). For example, `gs://my-bucket/outputs/`. See \`Supported input and output formats |
| `template_id` | `str` Input only. Specify the `template_id` to use for populating `Job.config`. The default is `preset/web-hd`, which is the only supported preset. User defined JobTemplate: `{job_template_id}` This field is a member of `oneof`_ `job_config`. |
| `config` | `https://docs.cloud.google.com/python/docs/reference/transcoder/latest/google.cloud.video.transcoder_v1.types.JobConfig` The configuration for this job. This field is a member of `oneof`_ `job_config`. |
| `state` | `https://docs.cloud.google.com/python/docs/reference/transcoder/latest/google.cloud.video.transcoder_v1.types.Job.ProcessingState` Output only. The current state of the job. |
| `create_time` | `google.protobuf.timestamp_pb2.Timestamp` Output only. The time the job was created. |
| `start_time` | `google.protobuf.timestamp_pb2.Timestamp` Output only. The time the transcoding started. |
| `end_time` | `google.protobuf.timestamp_pb2.Timestamp` Output only. The time the transcoding finished. |
| `ttl_after_completion_days` | `int` Job time to live value in days, which will be effective after job completion. Job should be deleted automatically after the given TTL. Enter a value between 1 and 90. The default is 30. |
| `labels` | `MutableMapping[str, str]` The labels associated with this job. You can use these to organize and group your jobs. |
| `error` | `google.rpc.status_pb2.Status` Output only. An error object that describes the reason for the failure. This property is always present when ProcessingState is `FAILED`. |
| `mode` | `https://docs.cloud.google.com/python/docs/reference/transcoder/latest/google.cloud.video.transcoder_v1.types.Job.ProcessingMode` The processing mode of the job. The default is `PROCESSING_MODE_INTERACTIVE`. |
| `batch_mode_priority` | `int` The processing priority of a batch job. This field can only be set for batch mode jobs. The default value is 0. This value cannot be negative. Higher values correspond to higher priorities for the job. |
| `optimization` | `https://docs.cloud.google.com/python/docs/reference/transcoder/latest/google.cloud.video.transcoder_v1.types.Job.OptimizationStrategy` Optional. The optimization strategy of the job. The default is `AUTODETECT`. |
| `fill_content_gaps` | `bool` Optional. Insert silence and duplicate frames when timestamp gaps are detected in a given stream. |

## Classes

### LabelsEntry

    LabelsEntry(mapping=None, *, ignore_unknown_fields=False, **kwargs)

The abstract base class for a message.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `kwargs` | `dict` Keys and values corresponding to the fields of the message. |
| `mapping` | ``Union[dict, `.Message`]`` A dictionary or message to be used to determine the values for this message. |
| `ignore_unknown_fields` | `Optional(bool)` If True, do not raise errors for unknown fields. Only applied if `mapping` is a mapping type or there are keyword parameters. |

### OptimizationStrategy

    OptimizationStrategy(value)

The optimization strategy of the job. The default is `AUTODETECT`.

### ProcessingMode

    ProcessingMode(value)

The processing mode of the job.

### ProcessingState

    ProcessingState(value)

The current state of the job.