---
title: "PATCH /v1/projects/{projectsId}/locations/{locationsId}/sources/{sourcesId}/diskMigrationJobs/{diskMigrationJobsId}"
method: PATCH
path: "/v1/projects/{projectsId}/locations/{locationsId}/sources/{sourcesId}/diskMigrationJobs/{diskMigrationJobsId}"
tags: ["projects"]
---

# PATCH /v1/projects/{projectsId}/locations/{locationsId}/sources/{sourcesId}/diskMigrationJobs/{diskMigrationJobsId}

`PATCH /v1/projects/{projectsId}/locations/{locationsId}/sources/{sourcesId}/diskMigrationJobs/{diskMigrationJobsId}`

## Request

- Base URL: `https://vmmigration.googleapis.com`
- URL: `https://vmmigration.googleapis.com/v1/projects/{projectsId}/locations/{locationsId}/sources/{sourcesId}/diskMigrationJobs/{diskMigrationJobsId}`
- Auth: OAuth 2 and OAuth 2
  - Implicit: `https://accounts.google.com/o/oauth2/auth`
  - Scopes: `https://www.googleapis.com/auth/cloud-platform`
  - Authorization code: `https://accounts.google.com/o/oauth2/auth`
  - Token URL: `https://accounts.google.com/o/oauth2/token` scopes: `https://www.googleapis.com/auth/cloud-platform`

Updates the parameters of a single DiskMigrationJob.

## Path parameters

- `projectsId` string, required
- `locationsId` string, required
- `sourcesId` string, required
- `diskMigrationJobsId` string, required

## Query parameters

- `$.xgafv` '1' | '2'
- `access_token` string
- `alt` 'json' | 'media' | 'proto'
- `callback` string
- `fields` string
- `key` string
- `oauth_token` string
- `prettyPrint` boolean
- `quotaUser` string
- `uploadType` string
- `upload_protocol` string
- `requestId` string
- `updateMask` string, google-fieldmask

## Request body

- DiskMigrationJob: Describes the disk which will be migrated from the source environment. The source disk has to be unattached.
  - `awsSourceDiskDetails` AwsSourceDiskDetails: Represents the source AWS Disk details.
    - `diskType` 'TYPE_UNSPECIFIED' | 'GP2' | 'GP3' | 'IO1' | 'IO2' | 'ST1' | 'SC1' | 'STANDARD': Optional. Output only. Disk type.
    - `sizeGib` string, int64: Output only. Size in GiB.
    - `tags` object: Optional. Output only. A map of AWS volume tags.
    - `volumeId` string: Required. AWS volume ID.
  - `createTime` string, google-datetime: Output only. The time the DiskMigrationJob resource was created.
  - `errors` Status[]: Output only. Provides details on the errors that led to the disk migration job's state in case of an error.
    - `code` integer: The status code, which should be an enum value of google.rpc.Code.
    - `details` object[]: A list of messages that carry the error details. There is a common set of message types for APIs to use.
    - `message` string: A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
  - `name` string: Output only. Identifier. The identifier of the DiskMigrationJob.
  - `state` 'STATE_UNSPECIFIED' | 'READY' | 'RUNNING' | 'SUCCEEDED' | 'CANCELLING' | 'CANCELLED' | 'FAILED': Output only. State of the DiskMigrationJob.
  - `steps` DiskMigrationStep[]: Output only. The disk migration steps list representing its progress.
    - `copyingSourceDiskSnapshot` CopyingSourceDiskSnapshotStep: CopyingSourceDiskSnapshotStep contains specific step details.
    - `creatingSourceDiskSnapshot` CreatingSourceDiskSnapshotStep: CreatingSourceDiskSnapshotStep contains specific step details.
    - `endTime` string, google-datetime: Output only. The time the step has ended.
    - `provisioningTargetDisk` ProvisioningTargetDiskStep: ProvisioningTargetDiskStep contains specific step details.
    - `startTime` string, google-datetime: Output only. The time the step has started.
  - `targetDetails` DiskMigrationJobTargetDetails: Details of the target disk in Compute Engine.
    - `encryption` Encryption: Encryption message describes the details of the applied encryption.
      - `kmsKey` string: Required. The name of the encryption key that is stored in Google Cloud KMS.
    - `labels` object: Optional. A map of labels to associate with the disk.
    - `targetDisk` ComputeEngineDisk: Compute Engine disk target details.
      - `diskId` string: Optional. Target Compute Engine Disk ID. This is the resource ID segment of the Compute Engine Disk to create. In the resource name compute/v1/projects/{project}/zones/{zone}/disks/disk1 "disk1" is the resource ID for the disk.
      - `diskType` 'COMPUTE_ENGINE_DISK_TYPE_UNSPECIFIED' | 'COMPUTE_ENGINE_DISK_TYPE_STANDARD' | 'COMPUTE_ENGINE_DISK_TYPE_SSD' | 'COMPUTE_ENGINE_DISK_TYPE_BALANCED' | 'COMPUTE_ENGINE_DISK_TYPE_HYPERDISK_BALANCED' | 'COMPUTE_ENGINE_DISK_TYPE_HYPERDISK_BALANCED_HIGH_AVAILABILITY': Required. The disk type to use.
      - `replicaZones` string[]: Optional. Replication zones of the regional disk. Should be of the form: projects/{target-project}/locations/{replica-zone} Currently only one replica zone is supported.
      - `zone` string: Required. The Compute Engine zone in which to create the disk. Should be of the form: projects/{target-project}/locations/{zone}
    - `targetProject` string: Required. The name of the resource of type TargetProject which represents the Compute Engine project in which to create the disk. Should be of the form: projects/{project}/locations/global/targetProjects/{target-project}
  - `updateTime` string, google-datetime: Output only. The last time the DiskMigrationJob resource was updated.

## Response `200`

Successful response

- Operation: This resource represents a long-running operation that is the result of a network API call.
  - `done` boolean: If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available.
  - `error` Status: The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors).
    - `code` integer: The status code, which should be an enum value of google.rpc.Code.
    - `details` object[]: A list of messages that carry the error details. There is a common set of message types for APIs to use.
    - `message` string: A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
  - `metadata` object: Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
  - `name` string: The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`.
  - `response` object: The normal, successful response of the operation. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`.

---

[API](https://skmtc.dev/google/apis/vmmigration.md) - [All operations](https://skmtc.dev/google/apis/vmmigration/llms.txt) - [OpenAPI document](https://skmtc.dev/google/apis/vmmigration/revisions/dc534bc294f6?raw)
