**Full name**: projects.locations.datasets.dicomStores.import

Imports data into the DICOM store by copying it from the specified source. Errors are logged to Cloud Logging. For more information, see [Viewing error logs in Cloud Logging](https://cloud.google.com/healthcare/docs/how-tos/logging). The `https://docs.cloud.google.com/healthcare-api/docs/reference/rest/Shared.Types/ListOperationsResponse#Operation.FIELDS.metadata` field type is `https://docs.cloud.google.com/healthcare-api/docs/reference/rest/v1beta1/OperationMetadata`.

### HTTP request

`POST https://healthcare.googleapis.com/v1beta1/{name=projects/*/locations/*/datasets/*/dicomStores/*}:import`

The URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.

### Path parameters

| Parameters ||
|---|---|
| `name` | `string` Required. The name of the DICOM store resource into which the data is imported. For example, `projects/{projectId}/locations/{locationId}/datasets/{datasetId}/dicomStores/{dicomStoreId}`. Authorization requires the following [IAM](https://cloud.google.com/iam/docs/) permission on the specified resource `name`: - `healthcare.dicomStores.import` |

### Request body

The request body contains data with the following structure:

| JSON representation |
|---|
| ``` { "blobStorageSettings": { object(`https://docs.cloud.google.com/healthcare-api/docs/reference/rest/v1beta1/BlobStorageSettings`) }, // The following is a list of mutually exclusive fields. At most one of the // fields will be set in a response: "gcsSource": { object(`https://docs.cloud.google.com/healthcare-api/docs/reference/rest/v1beta1/projects.locations.datasets.dicomStores/import#GcsSource`) } // End of mutually exclusive fields. } ``` |

| Fields ||
|---|---|
| `blobStorageSettings` | ``object(`https://docs.cloud.google.com/healthcare-api/docs/reference/rest/v1beta1/BlobStorageSettings`)`` Optional. The blob storage settings for the data imported by this operation. |
| Specifies the source data location and import configuration. To enable the Cloud Healthcare API to read from resources in your project such as Cloud Storage, you must give the Cloud Healthcare API service account the proper permissions. The service account is: `service-{PROJECT_NUMBER}@gcp-sa-healthcare.iam.gserviceaccount.com`. The PROJECT_NUMBER identifies the project that the DICOM store resides in. To get the project number, go to the Cloud Console Dashboard. The following is a list of mutually exclusive fields. At most one of the fields will be set in a response: ||
| `gcsSource` | ``object(`https://docs.cloud.google.com/healthcare-api/docs/reference/rest/v1beta1/projects.locations.datasets.dicomStores/import#GcsSource`)`` Cloud Storage source data location and import configuration. The Cloud Healthcare Service Agent requires the `roles/storage.objectViewer` Cloud IAM roles on the Cloud Storage location. |
| End of mutually exclusive fields. ||

### Response body

If successful, the response body contains an instance of `https://docs.cloud.google.com/healthcare-api/docs/reference/rest/Shared.Types/ListOperationsResponse#Operation`.

### Authorization scopes

Requires one of the following OAuth scopes:

- `https://www.googleapis.com/auth/cloud-healthcare`
- `https://www.googleapis.com/auth/cloud-platform`

For more information, see the [Authentication Overview](https://docs.cloud.google.com/docs/authentication#authorization-gcp).

## GcsSource

Specifies the configuration for importing data from Cloud Storage.

| JSON representation |
|---|
| ``` { "uri": string } ``` |

| Fields ||
|---|---|
| `uri` | `string` Points to a Cloud Storage URI containing file(s) with content only. The URI must be in the following format: `gs://{bucket_id}/{objectId}`. The URI can include wildcards in `objectId` and thus identify multiple files. Supported wildcards: - '\*' to match 0 or more non-separator characters - '\*\*' to match 0 or more characters (including separators). Must be used at the end of a path and with no other wildcards in the path. Can also be used with a file extension (such as .dcm), which imports all files with the extension in the specified directory and its sub-directories. For example, `gs://my-bucket/my-directory/**.dcm` imports all files with .dcm extensions in `my-directory/` and its sub-directories. - '?' to match 1 character. All other URI formats are invalid. Files matching the wildcard are expected to contain content only, no metadata. |