# REST Resource: projects.locations.imageImports

- [Resource: ImageImport](https://docs.cloud.google.com/migrate/virtual-machines/docs/5.0/reference/rest/v1/projects.locations.imageImports#ImageImport)
  - [JSON representation](https://docs.cloud.google.com/migrate/virtual-machines/docs/5.0/reference/rest/v1/projects.locations.imageImports#ImageImport.SCHEMA_REPRESENTATION)
- [Methods](https://docs.cloud.google.com/migrate/virtual-machines/docs/5.0/reference/rest/v1/projects.locations.imageImports#METHODS_SUMMARY)

## Resource: ImageImport

ImageImport describes the configuration of the image import to run.

| JSON representation |
|---|
| ``` { "name": string, "createTime": string, "recentImageImportJobs": [ { object (`https://docs.cloud.google.com/migrate/virtual-machines/docs/5.0/reference/rest/v1/projects.locations.imageImports.imageImportJobs#ImageImportJob`) } ], "encryption": { object (`https://docs.cloud.google.com/migrate/virtual-machines/docs/5.0/reference/rest/v1/Encryption`) }, // Union field `source` can be only one of the following: "cloudStorageUri": string // End of list of possible types for union field `source`. // Union field `target_defaults` can be only one of the following: "diskImageTargetDefaults": { object (`https://docs.cloud.google.com/migrate/virtual-machines/docs/5.0/reference/rest/v1/DiskImageTargetDetails`) }, "machineImageTargetDefaults": { object (`https://docs.cloud.google.com/migrate/virtual-machines/docs/5.0/reference/rest/v1/MachineImageTargetDetails`) } // End of list of possible types for union field `target_defaults`. } ``` |

| Fields ||
|---|---|
| `name` | `string` Output only. The resource path of the ImageImport. |
| `createTime` | ``string (`https://protobuf.dev/reference/protobuf/google.protobuf#timestamp` format)`` Output only. The time the image import was created. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: `"2014-10-02T15:01:23Z"` and `"2014-10-02T15:01:23.045123456Z"`. |
| `recentImageImportJobs[]` | ``object (`https://docs.cloud.google.com/migrate/virtual-machines/docs/5.0/reference/rest/v1/projects.locations.imageImports.imageImportJobs#ImageImportJob`)`` Output only. The result of the most recent runs for this ImageImport. All jobs for this ImageImport can be listed via ListImageImportJobs. |
| `encryption` | ``object (`https://docs.cloud.google.com/migrate/virtual-machines/docs/5.0/reference/rest/v1/Encryption`)`` Immutable. The encryption details used by the image import process during the image adaptation for Compute Engine. |
| Union field `source`. `source` can be only one of the following: ||
| `cloudStorageUri` | `string` Immutable. The path to the Cloud Storage file from which the image should be imported. |
| Union field `target_defaults`. The configuration of the resources that will be created in GCP as a result of the ImageImport. `target_defaults` can be only one of the following: ||
| `diskImageTargetDefaults` | ``object (`https://docs.cloud.google.com/migrate/virtual-machines/docs/5.0/reference/rest/v1/DiskImageTargetDetails`)`` Immutable. Target details for importing a disk image, will be used by ImageImportJob. |
| `machineImageTargetDefaults` | ``object (`https://docs.cloud.google.com/migrate/virtual-machines/docs/5.0/reference/rest/v1/MachineImageTargetDetails`)`` Immutable. Target details for importing a machine image, will be used by ImageImportJob. |

| ## Methods ||
|---|---|
| ### `https://docs.cloud.google.com/migrate/virtual-machines/docs/5.0/reference/rest/v1/projects.locations.imageImports/create` | Creates a new ImageImport in a given project. |
| ### `https://docs.cloud.google.com/migrate/virtual-machines/docs/5.0/reference/rest/v1/projects.locations.imageImports/delete` | Deletes a single ImageImport. |
| ### `https://docs.cloud.google.com/migrate/virtual-machines/docs/5.0/reference/rest/v1/projects.locations.imageImports/get` | Gets details of a single ImageImport. |
| ### `https://docs.cloud.google.com/migrate/virtual-machines/docs/5.0/reference/rest/v1/projects.locations.imageImports/list` | Lists ImageImports in a given project. |