Halaman ini menjelaskan cara melakukan de-identifikasi data DICOM dan menulis metadata tentang operasi de-identifikasi dan data yang dide-identifikasi ke penyimpanan FHIR. Metadata disimpan dalam resource Provenance FHIR di penyimpanan FHIR. Kemudian, Anda dapat membuat kueri data menggunakan penelusuran kustom FHIR untuk menjawab pertanyaan seperti berikut:
- Apa yang dideidentifikasi?
- Bagaimana dan mengapa data dideidentifikasi?
- Kapan operasi penghapusan identitas terjadi, dan berapa lama waktu yang diperlukan?
Sebelum memulai
Menggunakan FHIR, bukan anotasi
Cloud Healthcare API menawarkan API anotasi yang dapat Anda gunakan untuk menambahkan anotasi pada data yang dide-identifikasi.
Menulis metadata operasi de-identifikasi ke penyimpanan FHIR berfungsi dengan cara yang sama, dan memiliki keuntungan berikut:
- Anda tidak perlu menggunakan API anotasi, yang merupakan API terpisah.
- Anda tidak perlu membuat dan mengelola penyimpanan anotasi serta catatan anotasi.
- Anda dapat terus menggunakan standar FHIR dan API FHIR Cloud Healthcare API.
- Anda dapat mengekspor resource FHIR ke BigQuery
untuk eksplorasi dan analisis. Data yang dihasilkan hanya kompatibel dengan
SchemaType
LOSSLESS
atauANALYTICS_V2
.- Anda dapat melakukan streaming perubahan resource FHIR ke BigQuery untuk menyinkronkan data di penyimpanan FHIR dengan set data BigQuery secara mendekati real-time.
- Informasi selengkapnya diberikan tentang metadata operasi penghapusan identitas.
Persyaratan
Penyimpanan FHIR yang menyimpan metadata operasi de-identifikasi harus memenuhi persyaratan berikut:
- Harus sudah ada.
- Harus berupa penyimpanan FHIR versi R4.
- Harus menetapkan
enableUpdateCreate
ketrue
.
Resource asal di penyimpanan FHIR metadata operasi
Saat Anda menjalankan operasi de-identifikasi DICOM, resource Provenance berikut akan ditulis ke penyimpanan FHIR metadata operasi:
Resource Provenance yang merangkum operasi de-identifikasi, seperti nama operasi yang berjalan lama, kapan operasi terjadi, dan konfigurasi apa yang digunakan. Untuk mengetahui daftar kolom dalam resource Provenance ini, lihat Mende-identifikasi metadata operasi di resource Provenance.
Resource Provenance untuk setiap instance DICOM yang dide-identifikasi. Untuk daftar kolom dalam resource Provenance ini, lihat Metadata de-identifikasi DICOM dalam resource Provenance.
- Resource ini berisi informasi tentang apa yang dide-identifikasi, seperti tag DICOM atau bagian gambar DICOM, dan tindakan yang dilakukan, seperti apakah informasi tersebut disamarkan, diubah, atau diabaikan.
Resource tersebut mungkin berisi data yang dide-identifikasi yang diproses oleh pengenalan karakter optik (OCR) yang termasuk dalam cakupan informasi kesehatan terlindungi (PHI).
Teks yang dide-identifikasi, atau
quote
, disertai dengan jenis informasinya, atauinfoType
, dan kemungkinan menemukan informasi tersebut, atauconfidence
. Misalnya, jika gambar DICOM yang berisi teks sisipanJohn Doe
dideidentifikasi, resource Provenance akan berisiquote
yang ditetapkan keJohn Doe
,infoType
ditetapkan kePERSON_NAME
, dan nilaiconfidence
antara 0 dan 1.Metadata de-identifikasi DICOM hanya dibuat jika metode
dicomStores.deidentify
dipanggil denganImageConfig.textRedactionMode
ditetapkan keREDACT_SENSITIVE_TEXT
atauREDACT_SENSITIVE_TEXT_CLEAN_DESCRIPTORS
. Jika Anda menetapkanREDACT_ALL_TEXT
, metode ini akan menghasilkan teks yang dide-identifikasi sebagai string tunggal di kolomextracted-text
. String tidak berisi segmentasi. Token dipisahkan dengan spasi.
Melakukan de-identifikasi metadata operasi di resource Provenance
Tabel berikut menunjukkan deskripsi metadata dalam operasi penghapusan identitas dan kolom yang sesuai dalam metadata tempat metadata tersebut dapat ditemukan di resource Provenance. Sel "Kolom resource asal" berisi nilai contoh yang ditujukan untuk tujuan demonstrasi.
Deskripsi metadata | Kolom resource asal |
---|---|
ID resource asal | Provenance.id |
Saat operasi de-identifikasi dimulai | Provenance.occurredDateTime |
Stempel waktu pembuatan resource asal | Provenance.recorded |
Nama operasi de-identifikasi yang berjalan lama | Provenance.agent.who: { "identifier": { "system": "https://g.co/healthcare/operation" "value": "projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/operations/OPERATION_ID" } } |
Penyimpanan DICOM sumber | Provenance.entity.role: "SOURCE" Provenance.entity.what.identifier.value: "projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/dicomStores/SOURCE_DICOM_STORE_ID" |
Penyimpanan DICOM tujuan | Provenance.target.type.value |
Nilai DeidentifyConfig yang digunakan |
Provenance.entity.extension: [{ url: 'https://g.co/deidentify-config', valueString: 'DEIDENTIFY_CONFIG' // Can be either a JSON configuration or a path to a Cloud Storage URI and timestamp if the configuration was provided using Cloud Storage }] |
Metadata de-identifikasi DICOM dalam resource Provenance
Tabel berikut menunjukkan deskripsi metadata dalam instance DICOM yang dide-identifikasi dan kolom metadata yang sesuai dalam resource Provenance. Sel "Kolom resource asal" berisi nilai contoh yang ditujukan untuk tujuan demonstrasi.
Deskripsi metadata | Kolom resource asal |
---|---|
Link ke resource operasi penghapusan identitas | Provenance.agent.who: {reference: "Provenance/PROVENANCE_RESOURCE_ID"} |
Stempel waktu pembuatan resource asal | Provenance.recorded |
Jalur REST instance DICOM sumber | Provenance.entity.role: SOURCE Provenance.entity.what.identifier.value |
Jalur REST instance DICOM tujuan | Provenance.target.type.value |
Ukuran gambar DICOM | Provenance.entity.extension: [ { url: 'https://g.co/WIDTH', valueDecimal: WIDTH }, url: 'https://g.co/HEIGHT', valueDecimal: HEIGHT } ] |
Ukuran terstruktur | Provenance.entity.extension: [{ url: 'https://g.co/DICOM_STRUCTURED_SIZE', valueDecimal: VALUE, }] |
Anotasi gambar DICOM | Provenance.entity.extension: [{ url: 'https://g.co/DICOM_IMAGES', extension: [ { FRAME_0 }, { FRAME_1 }, ... ] }] |
Anotasi frame DICOM | Provenance.entity.extension['https://g.co/dicom-images'].extension: [ { url: 'frame-index', valueDecimal: 0, extension: [ { url: 'left', valueDecimal: LEFT_VALUE }, { url: 'right', valueDecimal: RIGHT_VALUE }, { url: 'top', valueDecimal: TOP_VALUE }, { url: 'bottom', valueDecimal: BOTTOM_VALUE }, { url: 'relative-left', valueDecimal: RELATIVE_LEFT_VALUE / WIDTH }, { url: 'relative-right', valueDecimal: RELATIVE_RIGHT_VALUE / HEIGHT }, { url: 'relative-top', valueDecimal: RELATIVE_TOP_VALUE / WIDTH }, { url: 'relative-bottom', valueDecimal: RELATIVE_BOTTOM / HEIGHT } ] } ] |
Anotasi frame DICOM | // Only available if the text redaction mode is REDACT_SENSITIVE_TEXT or // REDACT_SENSITIVE_TEXT_CLEAN_DESCRIPTORS Provenance.entity.extension: [ { "url": "quote", // The PHI text de-identified "valueString": "John Doe" }, { "url": "infoType", // The type of the de-identified text "valueString": "PERSON_NAME" }, { "url": "confidence", // The likelihood of finding this quote and its infoType "valueDecimal": 0.7 } ] |
Anotasi frame DICOM | // Only available if the text redaction mode is REDACT_ALL_TEXT Provenance.entity.extension: [ { "url": "extracted-text", // The entire PHI text de-identified "valueString": "John Doe 27-Jan-1999 Sex:M" } ] |
Semua anotasi tag DICOM | Provenance.entity.extension: [{ url: 'https://g.co/dicom-tags', extension: [ { // tag (0002,0000) }, { // tag (0002,0001) }, ... ] }] |
Notasi tag individual DICOM | Provenance.entity.extension['https://g.co/dicom-tags'].extension: [ { url: 'tag-id', valueString: '00080012', extension: [ { url: 'byte-start', valueDecimal: 10 }, { url: 'byte-end', valueDecimal: 18 }, { url: 'finding-infotype', valueString: 'PERSON_NAME' }, { url: 'text-original', valueString: 'John Doe' }, { url: 'text-replaced', valueString: 'PERSON_NAME' }, { url: 'deidentify-action', valueString: 'REMOVED' // Possible values are "REMOVED", "DELETED", "REGENERATED UID", // "RESET", "CLEANED", and "RECURSED" }, { url: 'deidentify-reason', valueString: 'Matched VALUE' // Possible values include "ID", "VR", or "Expression", // for example "Matched ID: DICOM_TAG_ID" } ] } ] |
Contoh
Sebelum memulai
Pastikan Anda memiliki peran roles/healthcare.fhirResourceEditor
di penyimpanan FHIR metadata operasi sebelum menjalankan salah satu
contoh berikut. Anda memerlukan peran ini untuk menulis ke penyimpanan FHIR metadata operasi.
Melakukan de-identifikasi data DICOM, menulis ke penyimpanan FHIR, dan menelusuri resource Provenance
Sebelum menjalankan contoh ini, selesaikan langkah-langkah berikut:
- Buat set data sumber yang berisi penyimpanan DICOM dengan minimal satu instance DICOM yang akan dide-identifikasi.
- Buat set data tujuan yang berisi penyimpanan DICOM kosong dan penyimpanan FHIR kosong. FHIR store harus memenuhi persyaratan.
Contoh ini memperluas Menggabungkan de-identifikasi tag dan penyamaran teks yang di-burn-in. Dalam contoh ini, de-identifikasi terjadi di satu penyimpanan DICOM dan data yang dide-identifikasi ditulis ke penyimpanan DICOM baru. Penyimpanan FHIR metadata operasi berada dalam set data yang sama dengan penyimpanan DICOM baru.
Contoh ini menggunakan dua instance DICOM. Instance tidak disediakan untuk Anda, sehingga contoh respons tidak akan sama persis dengan data Anda yang dide-identifikasi.
Lakukan de-identifikasi data DICOM.
Sebelum menggunakan salah satu data permintaan, lakukan penggantian berikut:
- PROJECT_ID: project ID Google Cloud Anda
- LOCATION: lokasi set data yang berisi penyimpanan DICOM sumber
- SOURCE_DATASET_ID: set data induk penyimpanan DICOM sumber
- SOURCE_DICOM_STORE_ID: ID penyimpanan DICOM yang berisi data yang Anda de-identifikasi
- DESTINATION_DATASET_ID: set data yang ada yang berisi penyimpanan FHIR operasi metadata, dan tempat penyimpanan DICOM yang dide-identifikasi akan dibuat
- DESTINATION_DICOM_STORE_ID: penyimpanan DICOM tempat data yang dide-identifikasi dari penyimpanan DICOM sumber akan ditulis
- OPERATION_METADATA_FHIR_STORE_ID: penyimpanan FHIR tempat metadata operasi de-identifikasi akan ditulis
Meminta isi JSON:
{ "destinationStore": "projects/PROJECT_ID/locations/LOCATION/datasets/DESTINATION_DATASET_ID/dicomStores/DESTINATION_DICOM_STORE_ID", "config": { "dicom": { "filterProfile": "DEIDENTIFY_TAG_CONTENTS" }, "image": { "textRedactionMode": "REDACT_ALL_TEXT" }, "operationMetadata": { "fhirOutput": { "fhirStore": "projects/PROJECT_ID/locations/LOCATION/datasets/DESTINATION_DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE" } } } }
Untuk mengirim permintaan Anda, pilih salah satu opsi berikut:
curl
Simpan isi permintaan dalam file bernama
request.json
. Jalankan perintah berikut di terminal untuk membuat atau menimpa file ini di direktori saat ini:cat > request.json << 'EOF' { "destinationStore": "projects/PROJECT_ID/locations/LOCATION/datasets/DESTINATION_DATASET_ID/dicomStores/DESTINATION_DICOM_STORE_ID", "config": { "dicom": { "filterProfile": "DEIDENTIFY_TAG_CONTENTS" }, "image": { "textRedactionMode": "REDACT_ALL_TEXT" }, "operationMetadata": { "fhirOutput": { "fhirStore": "projects/PROJECT_ID/locations/LOCATION/datasets/DESTINATION_DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE" } } } } EOF
Kemudian, jalankan perintah berikut untuk mengirim permintaan REST Anda:
curl -X POST \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
-H "Content-Type: application/json; charset=utf-8" \
-d @request.json \
"https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/SOURCE_DATASET_ID/dicomStores/SOURCE_DICOM_STORE_ID:deidentify"PowerShell
Simpan isi permintaan dalam file bernama
request.json
. Jalankan perintah berikut di terminal untuk membuat atau menimpa file ini di direktori saat ini:@' { "destinationStore": "projects/PROJECT_ID/locations/LOCATION/datasets/DESTINATION_DATASET_ID/dicomStores/DESTINATION_DICOM_STORE_ID", "config": { "dicom": { "filterProfile": "DEIDENTIFY_TAG_CONTENTS" }, "image": { "textRedactionMode": "REDACT_ALL_TEXT" }, "operationMetadata": { "fhirOutput": { "fhirStore": "projects/PROJECT_ID/locations/LOCATION/datasets/DESTINATION_DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE" } } } } '@ | Out-File -FilePath request.json -Encoding utf8
Kemudian jalankan perintah berikut untuk mengirim permintaan REST Anda:
$cred = gcloud auth print-access-token
$headers = @{ "Authorization" = "Bearer $cred" }
Invoke-WebRequest `
-Method POST `
-Headers $headers `
-ContentType: "application/json; charset=utf-8" `
-InFile request.json `
-Uri "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/SOURCE_DATASET_ID/dicomStores/SOURCE_DICOM_STORE_ID:deidentify" | Select-Object -Expand ContentMendapatkan status operasi.
Sebelum menggunakan salah satu data permintaan, lakukan penggantian berikut:
- PROJECT_ID: project ID Google Cloud Anda
- LOCATION: lokasi set data
- SOURCE_DATASET_ID: set data tempat operasi penghapusan identitas berjalan
- OPERATION_ID: ID operasi penghapusan identitas
Untuk mengirim permintaan Anda, pilih salah satu opsi berikut:
curl
Jalankan perintah berikut:
curl -X GET \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
"https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/operations/OPERATION_ID"PowerShell
Jalankan perintah berikut:
$cred = gcloud auth print-access-token
$headers = @{ "Authorization" = "Bearer $cred" }
Invoke-WebRequest `
-Method GET `
-Headers $headers `
-Uri "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/operations/OPERATION_ID" | Select-Object -Expand ContentAPIs Explorer
Buka halaman referensi metode. Panel API Explorer terbuka di sisi kanan halaman. Anda bisa berinteraksi dengan alat ini untuk mengirim permintaan. Lengkapi kolom yang wajib diisi, lalu klik Jalankan.
Anda akan melihat respons JSON seperti berikut:
Setelah berhasil melakukan de-identifikasi data DICOM dan menulis metadata operasi ke penyimpanan FHIR, Anda dapat melihat resource Provenance di penyimpanan FHIR.
Untuk melihat resource Provenance, gunakan metode
fhir.search
.Sebelum menggunakan salah satu data permintaan, lakukan penggantian berikut:
- PROJECT_ID: project ID Google Cloud Anda
- LOCATION: lokasi set data induk
- DATASET_ID: set data induk penyimpanan FHIR
- OPERATION_METADATA_FHIR_STORE_ID: ID penyimpanan FHIR yang berisi metadata
Untuk mengirim permintaan Anda, pilih salah satu opsi berikut:
curl
Jalankan perintah berikut:
curl -X GET \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
"https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DESTINATION_DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir/Provenance"PowerShell
Jalankan perintah berikut:
$cred = gcloud auth print-access-token
$headers = @{ "Authorization" = "Bearer $cred" }
Invoke-WebRequest `
-Method GET `
-Headers $headers `
-Uri "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DESTINATION_DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir/Provenance" | Select-Object -Expand Content- Satu resource Provenance untuk setiap dua instance DICOM
- Satu resource Provenance untuk operasi de-identifikasi
Menyimpan data sampel, membuat penelusuran FHIR kustom koordinat x relatif, dan membuat kueri
Sebelum menjalankan contoh ini, buat set data tujuan yang berisi penyimpanan DICOM kosong dan penyimpanan FHIR kosong. FHIR store harus memenuhi persyaratan.
Contoh berikut menunjukkan cara menyimpan tiga resource Provenance yang dibuat
di Melakukan de-identifikasi data DICOM, menulis ke penyimpanan FHIR, dan menelusuri resource Provenance,
lalu membuat penelusuran kustom. Penelusuran kustom
mengkueri relative-x-coordinate-bottom-left
di salah satu instance
DICOM yang dide-identifikasi.
Menyimpan resource Provenance.
Sebelum menggunakan salah satu data permintaan, lakukan penggantian berikut:
- PROJECT_ID: project ID Google Cloud Anda
- LOCATION: lokasi set data induk
- DATASET_ID: set data induk penyimpanan FHIR
- OPERATION_METADATA_FHIR_STORE_ID: ID penyimpanan FHIR yang berisi metadata
Meminta isi JSON:
{ "resourceType": "Bundle", "type": "transaction", "entry": [ { "request": {"method": "PUT", "url": "Provenance/operation-123"}, "resource": { "resourceType": "Provenance", "id": "operation-123", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store" } } ], "occurredDateTime": "2010-11-08T08:30:00-04:00", "recorded": "2010-11-08T08:30:24-04:00", "agent": [ { "who": { "identifier": { "system": "https://g.co/healthcare/operation", "value": "projects/my-project/locations/us-central1/datasets/my-dataset/operations/123" } } } ], "entity": [ { "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store" } } } ] } }, { "request": {"method": "POST", "url": "Provenance"}, "resource": { "resourceType": "Provenance", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store/dicomWeb/studies/1/series/2/instances/3" } } ], "recorded": "2010-11-08T08:39:24-04:00", "agent": [ { "who": { "identifier": { "value": "projects/test-project/locations/us-central1/datasets/test-dataset/fhirStores/test-fhir-store/fhir/Provenance/operation-123" } } } ], "entity": [ { "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store/dicomWeb/studies/1/series/2/instances/3" } }, "extension": [ { "url": "https://g.co/dicom-images", "extension": [ { "url": "frame-index", "valueDecimal": 0, "extension": [ { "url": "bottom", "valueDecimal": 100 }, { "url": "left", "valueDecimal": 100 }, { "url": "right", "valueDecimal": 200 }, { "url": "top", "valueDecimal": 200 }, { "url": "relative-bottom", "valueDecimal": 0.05 }, { "url": "relative-left", "valueDecimal": 0.05 }, { "url": "relative-right", "valueDecimal": 0.1 }, { "url": "relative-top", "valueDecimal": 0.1 }, { "url": "bottom", "valueDecimal": 900 }, { "url": "left", "valueDecimal": 900 }, { "url": "right", "valueDecimal": 1000 }, { "url": "top", "valueDecimal": 1000 }, { "url": "relative-bottom", "valueDecimal": 0.45 }, { "url": "relative-left", "valueDecimal": 0.45 }, { "url": "relative-right", "valueDecimal": 0.5 }, { "url": "relative-top", "valueDecimal": 0.5 } ] } ] }, { "url": "https://g.co/dicom-tags", "extension": [ { "url": "tag-id", "valueString": "00100021", "extension": [ { "url": "byte-start", "valueDecimal": 10 }, { "url": "byte-end", "valueDecimal": 18 }, { "url": "finding-infotype", "valueString": "PERSON_NAME" }, { "url": "text-original", "valueString": "John Doe" }, { "url": "text-replaced", "valueString": "PERSON_NAME" }, { "url": "byte-start", "valueDecimal": 25 }, { "url": "byte-end", "valueDecimal": 35 }, { "url": "finding-infotype", "valueString": "DATE" }, { "url": "text-original", "valueString": "1900-12-31" }, { "url": "text-replaced", "valueString": "DATE" } ] }, { "url": "tag-id", "valueString": "00102150", "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 2 }, { "url": "finding-infotype", "valueString": "LOCATION" }, { "url": "text-original", "valueString": "US" }, { "url": "text-replaced", "valueString": "LOCATION" } ] } ] } ] } ] } }, { "request": {"method": "POST", "url": "Provenance"}, "resource": { "resourceType": "Provenance", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store/dicomWeb/studies/1/series/2/instances/4" } } ], "recorded": "2010-11-08T08:39:25-04:00", "agent": [ { "who": { "identifier": { "value": "projects/test-project/locations/us-central1/datasets/test-dataset/fhirStores/test-fhir-store/fhir/Provenance/operation-123" } } } ], "entity": [ { "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store/dicomWeb/studies/1/series/2/instances/4" } }, "extension": [ { "url": "https://g.co/dicom-images", "extension": [ { "url": "frame-index", "valueDecimal": 0 }, { "url": "frame-index", "valueDecimal": 1, "extension": [ ] } ] }, { "url": "https://g.co/dicom-tags", "extension": [ { "url": "tag-id", "valueString": "00101010", "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 2 }, { "url": "finding-infotype", "valueString": "AGE" }, { "url": "text-original", "valueString": "30" }, { "url": "text-replaced", "valueString": "AGE" } ] }, { "url": "tag-id", "valueString": "00100020", "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 4 }, { "url": "finding-infotype", "valueString": "GENERIC_ID" }, { "url": "text-original", "valueString": "1234" }, { "url": "text-replaced", "valueString": "GENERIC_ID" } ] } ] } ] } ] } } ] }
Untuk mengirim permintaan Anda, pilih salah satu opsi berikut:
curl
Simpan isi permintaan dalam file bernama
request.json
. Jalankan perintah berikut di terminal untuk membuat atau menimpa file ini di direktori saat ini:cat > request.json << 'EOF' { "resourceType": "Bundle", "type": "transaction", "entry": [ { "request": {"method": "PUT", "url": "Provenance/operation-123"}, "resource": { "resourceType": "Provenance", "id": "operation-123", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store" } } ], "occurredDateTime": "2010-11-08T08:30:00-04:00", "recorded": "2010-11-08T08:30:24-04:00", "agent": [ { "who": { "identifier": { "system": "https://g.co/healthcare/operation", "value": "projects/my-project/locations/us-central1/datasets/my-dataset/operations/123" } } } ], "entity": [ { "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store" } } } ] } }, { "request": {"method": "POST", "url": "Provenance"}, "resource": { "resourceType": "Provenance", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store/dicomWeb/studies/1/series/2/instances/3" } } ], "recorded": "2010-11-08T08:39:24-04:00", "agent": [ { "who": { "identifier": { "value": "projects/test-project/locations/us-central1/datasets/test-dataset/fhirStores/test-fhir-store/fhir/Provenance/operation-123" } } } ], "entity": [ { "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store/dicomWeb/studies/1/series/2/instances/3" } }, "extension": [ { "url": "https://g.co/dicom-images", "extension": [ { "url": "frame-index", "valueDecimal": 0, "extension": [ { "url": "bottom", "valueDecimal": 100 }, { "url": "left", "valueDecimal": 100 }, { "url": "right", "valueDecimal": 200 }, { "url": "top", "valueDecimal": 200 }, { "url": "relative-bottom", "valueDecimal": 0.05 }, { "url": "relative-left", "valueDecimal": 0.05 }, { "url": "relative-right", "valueDecimal": 0.1 }, { "url": "relative-top", "valueDecimal": 0.1 }, { "url": "bottom", "valueDecimal": 900 }, { "url": "left", "valueDecimal": 900 }, { "url": "right", "valueDecimal": 1000 }, { "url": "top", "valueDecimal": 1000 }, { "url": "relative-bottom", "valueDecimal": 0.45 }, { "url": "relative-left", "valueDecimal": 0.45 }, { "url": "relative-right", "valueDecimal": 0.5 }, { "url": "relative-top", "valueDecimal": 0.5 } ] } ] }, { "url": "https://g.co/dicom-tags", "extension": [ { "url": "tag-id", "valueString": "00100021", "extension": [ { "url": "byte-start", "valueDecimal": 10 }, { "url": "byte-end", "valueDecimal": 18 }, { "url": "finding-infotype", "valueString": "PERSON_NAME" }, { "url": "text-original", "valueString": "John Doe" }, { "url": "text-replaced", "valueString": "PERSON_NAME" }, { "url": "byte-start", "valueDecimal": 25 }, { "url": "byte-end", "valueDecimal": 35 }, { "url": "finding-infotype", "valueString": "DATE" }, { "url": "text-original", "valueString": "1900-12-31" }, { "url": "text-replaced", "valueString": "DATE" } ] }, { "url": "tag-id", "valueString": "00102150", "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 2 }, { "url": "finding-infotype", "valueString": "LOCATION" }, { "url": "text-original", "valueString": "US" }, { "url": "text-replaced", "valueString": "LOCATION" } ] } ] } ] } ] } }, { "request": {"method": "POST", "url": "Provenance"}, "resource": { "resourceType": "Provenance", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store/dicomWeb/studies/1/series/2/instances/4" } } ], "recorded": "2010-11-08T08:39:25-04:00", "agent": [ { "who": { "identifier": { "value": "projects/test-project/locations/us-central1/datasets/test-dataset/fhirStores/test-fhir-store/fhir/Provenance/operation-123" } } } ], "entity": [ { "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store/dicomWeb/studies/1/series/2/instances/4" } }, "extension": [ { "url": "https://g.co/dicom-images", "extension": [ { "url": "frame-index", "valueDecimal": 0 }, { "url": "frame-index", "valueDecimal": 1, "extension": [ ] } ] }, { "url": "https://g.co/dicom-tags", "extension": [ { "url": "tag-id", "valueString": "00101010", "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 2 }, { "url": "finding-infotype", "valueString": "AGE" }, { "url": "text-original", "valueString": "30" }, { "url": "text-replaced", "valueString": "AGE" } ] }, { "url": "tag-id", "valueString": "00100020", "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 4 }, { "url": "finding-infotype", "valueString": "GENERIC_ID" }, { "url": "text-original", "valueString": "1234" }, { "url": "text-replaced", "valueString": "GENERIC_ID" } ] } ] } ] } ] } } ] } EOF
Kemudian, jalankan perintah berikut untuk mengirim permintaan REST Anda:
curl -X POST \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
-H "Content-Type: application/fhir+json" \
-d @request.json \
"https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir"PowerShell
Simpan isi permintaan dalam file bernama
request.json
. Jalankan perintah berikut di terminal untuk membuat atau menimpa file ini di direktori saat ini:@' { "resourceType": "Bundle", "type": "transaction", "entry": [ { "request": {"method": "PUT", "url": "Provenance/operation-123"}, "resource": { "resourceType": "Provenance", "id": "operation-123", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store" } } ], "occurredDateTime": "2010-11-08T08:30:00-04:00", "recorded": "2010-11-08T08:30:24-04:00", "agent": [ { "who": { "identifier": { "system": "https://g.co/healthcare/operation", "value": "projects/my-project/locations/us-central1/datasets/my-dataset/operations/123" } } } ], "entity": [ { "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store" } } } ] } }, { "request": {"method": "POST", "url": "Provenance"}, "resource": { "resourceType": "Provenance", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store/dicomWeb/studies/1/series/2/instances/3" } } ], "recorded": "2010-11-08T08:39:24-04:00", "agent": [ { "who": { "identifier": { "value": "projects/test-project/locations/us-central1/datasets/test-dataset/fhirStores/test-fhir-store/fhir/Provenance/operation-123" } } } ], "entity": [ { "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store/dicomWeb/studies/1/series/2/instances/3" } }, "extension": [ { "url": "https://g.co/dicom-images", "extension": [ { "url": "frame-index", "valueDecimal": 0, "extension": [ { "url": "bottom", "valueDecimal": 100 }, { "url": "left", "valueDecimal": 100 }, { "url": "right", "valueDecimal": 200 }, { "url": "top", "valueDecimal": 200 }, { "url": "relative-bottom", "valueDecimal": 0.05 }, { "url": "relative-left", "valueDecimal": 0.05 }, { "url": "relative-right", "valueDecimal": 0.1 }, { "url": "relative-top", "valueDecimal": 0.1 }, { "url": "bottom", "valueDecimal": 900 }, { "url": "left", "valueDecimal": 900 }, { "url": "right", "valueDecimal": 1000 }, { "url": "top", "valueDecimal": 1000 }, { "url": "relative-bottom", "valueDecimal": 0.45 }, { "url": "relative-left", "valueDecimal": 0.45 }, { "url": "relative-right", "valueDecimal": 0.5 }, { "url": "relative-top", "valueDecimal": 0.5 } ] } ] }, { "url": "https://g.co/dicom-tags", "extension": [ { "url": "tag-id", "valueString": "00100021", "extension": [ { "url": "byte-start", "valueDecimal": 10 }, { "url": "byte-end", "valueDecimal": 18 }, { "url": "finding-infotype", "valueString": "PERSON_NAME" }, { "url": "text-original", "valueString": "John Doe" }, { "url": "text-replaced", "valueString": "PERSON_NAME" }, { "url": "byte-start", "valueDecimal": 25 }, { "url": "byte-end", "valueDecimal": 35 }, { "url": "finding-infotype", "valueString": "DATE" }, { "url": "text-original", "valueString": "1900-12-31" }, { "url": "text-replaced", "valueString": "DATE" } ] }, { "url": "tag-id", "valueString": "00102150", "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 2 }, { "url": "finding-infotype", "valueString": "LOCATION" }, { "url": "text-original", "valueString": "US" }, { "url": "text-replaced", "valueString": "LOCATION" } ] } ] } ] } ] } }, { "request": {"method": "POST", "url": "Provenance"}, "resource": { "resourceType": "Provenance", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store/dicomWeb/studies/1/series/2/instances/4" } } ], "recorded": "2010-11-08T08:39:25-04:00", "agent": [ { "who": { "identifier": { "value": "projects/test-project/locations/us-central1/datasets/test-dataset/fhirStores/test-fhir-store/fhir/Provenance/operation-123" } } } ], "entity": [ { "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store/dicomWeb/studies/1/series/2/instances/4" } }, "extension": [ { "url": "https://g.co/dicom-images", "extension": [ { "url": "frame-index", "valueDecimal": 0 }, { "url": "frame-index", "valueDecimal": 1, "extension": [ ] } ] }, { "url": "https://g.co/dicom-tags", "extension": [ { "url": "tag-id", "valueString": "00101010", "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 2 }, { "url": "finding-infotype", "valueString": "AGE" }, { "url": "text-original", "valueString": "30" }, { "url": "text-replaced", "valueString": "AGE" } ] }, { "url": "tag-id", "valueString": "00100020", "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 4 }, { "url": "finding-infotype", "valueString": "GENERIC_ID" }, { "url": "text-original", "valueString": "1234" }, { "url": "text-replaced", "valueString": "GENERIC_ID" } ] } ] } ] } ] } } ] } '@ | Out-File -FilePath request.json -Encoding utf8
Kemudian jalankan perintah berikut untuk mengirim permintaan REST Anda:
$cred = gcloud auth print-access-token
$headers = @{ "Authorization" = "Bearer $cred" }
Invoke-WebRequest `
-Method POST `
-Headers $headers `
-ContentType: "application/fhir+json" `
-InFile request.json `
-Uri "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir" | Select-Object -Expand ContentAnda akan melihat respons JSON seperti berikut:
Buat resource SearchParameter pada koordinat x relatif gambar DICOM.
Sebelum menggunakan salah satu data permintaan, lakukan penggantian berikut:
- PROJECT_ID: project ID Google Cloud Anda
- LOCATION: lokasi set data induk
- DATASET_ID: set data induk penyimpanan FHIR
- OPERATION_METADATA_FHIR_STORE_ID: ID penyimpanan FHIR yang berisi metadata
Meminta isi JSON:
{ "resourceType": "SearchParameter", "url": "relative-x-coordinate-bottom-left", "base": ["Provenance"], "code": "relative-x-coordinate-bottom-left", "name": "relative x-coordinate of the bottom left corner of the bounding box", "type": "number", "expression": "Provenance.entity.extension('https://g.co/dicom-images').extension('frame-index').extension('relative-bottom').value.as(Decimal)", "status": "active", "description": "A search on bottom left relative x-coordinate of annotations generated from de-identification of a DICOM file" }
Untuk mengirim permintaan Anda, pilih salah satu opsi berikut:
curl
Simpan isi permintaan dalam file bernama
request.json
. Jalankan perintah berikut di terminal untuk membuat atau menimpa file ini di direktori saat ini:cat > request.json << 'EOF' { "resourceType": "SearchParameter", "url": "relative-x-coordinate-bottom-left", "base": ["Provenance"], "code": "relative-x-coordinate-bottom-left", "name": "relative x-coordinate of the bottom left corner of the bounding box", "type": "number", "expression": "Provenance.entity.extension('https://g.co/dicom-images').extension('frame-index').extension('relative-bottom').value.as(Decimal)", "status": "active", "description": "A search on bottom left relative x-coordinate of annotations generated from de-identification of a DICOM file" } EOF
Kemudian, jalankan perintah berikut untuk mengirim permintaan REST Anda:
curl -X POST \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
-H "Content-Type: application/fhir+json" \
-d @request.json \
"https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir/SearchParameter"PowerShell
Simpan isi permintaan dalam file bernama
request.json
. Jalankan perintah berikut di terminal untuk membuat atau menimpa file ini di direktori saat ini:@' { "resourceType": "SearchParameter", "url": "relative-x-coordinate-bottom-left", "base": ["Provenance"], "code": "relative-x-coordinate-bottom-left", "name": "relative x-coordinate of the bottom left corner of the bounding box", "type": "number", "expression": "Provenance.entity.extension('https://g.co/dicom-images').extension('frame-index').extension('relative-bottom').value.as(Decimal)", "status": "active", "description": "A search on bottom left relative x-coordinate of annotations generated from de-identification of a DICOM file" } '@ | Out-File -FilePath request.json -Encoding utf8
Kemudian jalankan perintah berikut untuk mengirim permintaan REST Anda:
$cred = gcloud auth print-access-token
$headers = @{ "Authorization" = "Bearer $cred" }
Invoke-WebRequest `
-Method POST `
-Headers $headers `
-ContentType: "application/fhir+json" `
-InFile request.json `
-Uri "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir/SearchParameter" | Select-Object -Expand ContentAnda akan melihat respons JSON seperti berikut:
Aktifkan resource SearchParameter kustom di FHIR Store.
Sebelum menggunakan salah satu data permintaan, lakukan penggantian berikut:
- PROJECT_ID: project ID Google Cloud Anda
- LOCATION: lokasi set data induk
- DATASET_ID: set data induk penyimpanan FHIR
- OPERATION_METADATA_FHIR_STORE_ID: ID penyimpanan FHIR yang berisi metadata
Meminta isi JSON:
{ "canonicalUrls": [ "relative-x-coordinate-bottom-left" ] }
Untuk mengirim permintaan Anda, pilih salah satu opsi berikut:
curl
Simpan isi permintaan dalam file bernama
request.json
. Jalankan perintah berikut di terminal untuk membuat atau menimpa file ini di direktori saat ini:cat > request.json << 'EOF' { "canonicalUrls": [ "relative-x-coordinate-bottom-left" ] } EOF
Kemudian, jalankan perintah berikut untuk mengirim permintaan REST Anda:
curl -X POST \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
-H "Content-Type: application/fhir+json" \
-d @request.json \
"https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID:configureSearch"PowerShell
Simpan isi permintaan dalam file bernama
request.json
. Jalankan perintah berikut di terminal untuk membuat atau menimpa file ini di direktori saat ini:@' { "canonicalUrls": [ "relative-x-coordinate-bottom-left" ] } '@ | Out-File -FilePath request.json -Encoding utf8
Kemudian jalankan perintah berikut untuk mengirim permintaan REST Anda:
$cred = gcloud auth print-access-token
$headers = @{ "Authorization" = "Bearer $cred" }
Invoke-WebRequest `
-Method POST `
-Headers $headers `
-ContentType: "application/fhir+json" `
-InFile request.json `
-Uri "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID:configureSearch" | Select-Object -Expand ContentMendapatkan status operasi.
Sebelum menggunakan salah satu data permintaan, lakukan penggantian berikut:
- PROJECT_ID: project ID Google Cloud Anda
- LOCATION: lokasi set data
- DATASET_ID: set data tempat operasi penelusuran kustom berjalan
- OPERATION_ID: ID operasi penelusuran kustom
Untuk mengirim permintaan Anda, pilih salah satu opsi berikut:
curl
Jalankan perintah berikut:
curl -X GET \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
"https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/operations/OPERATION_ID"PowerShell
Jalankan perintah berikut:
$cred = gcloud auth print-access-token
$headers = @{ "Authorization" = "Bearer $cred" }
Invoke-WebRequest `
-Method GET `
-Headers $headers `
-Uri "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/operations/OPERATION_ID" | Select-Object -Expand ContentAPIs Explorer
Buka halaman referensi metode. Panel API Explorer terbuka di sisi kanan halaman. Anda bisa berinteraksi dengan alat ini untuk mengirim permintaan. Lengkapi kolom yang wajib diisi, lalu klik Jalankan.
Anda akan melihat respons JSON seperti berikut:
Buat kueri resource Provenance menggunakan parameter penelusuran koordinat x relatif:
Sebelum menggunakan salah satu data permintaan, lakukan penggantian berikut:
- PROJECT_ID: project ID Google Cloud Anda
- LOCATION: lokasi set data induk
- DATASET_ID: set data induk penyimpanan FHIR
- OPERATION_METADATA_FHIR_STORE_ID: ID penyimpanan FHIR yang berisi metadata
Untuk mengirim permintaan Anda, pilih salah satu opsi berikut:
curl
Contoh berikut menggunakan kuerirelative-x-coordinate-bottom-left=le0.05
, yang menelusuri koordinat x dalam 5% dari tepi gambar.Jalankan perintah berikut:
curl -X GET \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
"https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir/Provenance?relative-x-coordinate-bottom-left=le0.05"PowerShell
Contoh berikut menggunakan kuerirelative-x-coordinate-bottom-left=le0.05
, yang menelusuri koordinat x dalam 5% dari tepi gambar.Jalankan perintah berikut:
$cred = gcloud auth print-access-token
$headers = @{ "Authorization" = "Bearer $cred" }
Invoke-WebRequest `
-Method GET `
-Headers $headers `
-Uri "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir/Provenance?relative-x-coordinate-bottom-left=le0.05" | Select-Object -Expand Content{ "entry": [ { "fullUrl": "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir/Provenance/90062087-8ac2-499c-b952-a04999578bd0", "resource": { "agent": [ { "who": { "identifier": { "value": "projects/test-project/locations/us-central1/datasets/test-dataset/fhirStores/test-fhir-store/fhir/Provenance/operation-123" } } } ], "entity": [ { "extension": [ { "extension": [ { "extension": [ { "url": "bottom", "valueDecimal": 100 }, { "url": "left", "valueDecimal": 100 }, { "url": "right", "valueDecimal": 200 }, { "url": "top", "valueDecimal": 200 }, { "url": "relative-bottom", "valueDecimal": 0.05 }, { "url": "relative-left", "valueDecimal": 0.05 }, { "url": "relative-right", "valueDecimal": 0.1 }, { "url": "relative-top", "valueDecimal": 0.1 }, { "url": "bottom", "valueDecimal": 900 }, { "url": "left", "valueDecimal": 900 }, { "url": "right", "valueDecimal": 1000 }, { "url": "top", "valueDecimal": 1000 }, { "url": "relative-bottom", "valueDecimal": 0.45 }, { "url": "relative-left", "valueDecimal": 0.45 }, { "url": "relative-right", "valueDecimal": 0.5 }, { "url": "relative-top", "valueDecimal": 0.5 } ], "url": "frame-index", "valueDecimal": 0 } ], "url": "https://g.co/dicom-images" }, { "extension": [ { "extension": [ { "url": "byte-start", "valueDecimal": 10 }, { "url": "byte-end", "valueDecimal": 18 }, { "url": "finding-infotype", "valueString": "PERSON_NAME" }, { "url": "text-original", "valueString": "John Doe" }, { "url": "text-replaced", "valueString": "PERSON_NAME" }, { "url": "byte-start", "valueDecimal": 25 }, { "url": "byte-end", "valueDecimal": 35 }, { "url": "finding-infotype", "valueString": "DATE" }, { "url": "text-original", "valueString": "1900-12-31" }, { "url": "text-replaced", "valueString": "DATE" } ], "url": "tag-id", "valueString": "00100021" }, { "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 2 }, { "url": "finding-infotype", "valueString": "LOCATION" }, { "url": "text-original", "valueString": "US" }, { "url": "text-replaced", "valueString": "LOCATION" } ], "url": "tag-id", "valueString": "00102150" } ], "url": "https://g.co/dicom-tags" } ], "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store/dicomWeb/studies/1/series/2/instances/3" } } } ], "id": "90062087-8ac2-499c-b952-a04999578bd0", "meta": { "lastUpdated": "LAST_UPDATED", "versionId": "MTY0NjY4NDg4Nzk3MDM2MTAwMA" }, "recorded": "2010-11-08T08:39:24-04:00", "resourceType": "Provenance", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store/dicomWeb/studies/1/series/2/instances/3" } } ] }, "search": { "mode": "match" } } ], "link": [ { "relation": "search", "url": "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir/Provenance/?relative-x-coordinate-bottom-left=le0.05" }, { "relation": "first", "url": "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir/Provenance/?relative-x-coordinate-bottom-left=le0.05" }, { "relation": "self", "url": "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir/Provenance/?relative-x-coordinate-bottom-left=le0.05" } ], "resourceType": "Bundle", "total": 1, "type": "searchset" }
Menyimpan data sampel, membuat penelusuran FHIR kustom DICOM sumber, dan membuat kueri
Sebelum menjalankan contoh ini, buat set data tujuan yang berisi penyimpanan DICOM kosong dan penyimpanan FHIR kosong. FHIR store harus memenuhi persyaratan.
Contoh berikut menunjukkan cara menyimpan tiga resource Provenance yang dibuat di Melakukan de-identifikasi data DICOM, menulis ke penyimpanan FHIR, dan menelusuri resource Provenance, lalu membuat penelusuran kustom. Kueri penelusuran kustom akan mencari informasi tentang salah satu dari dua gambar DICOM sumber.
Menyimpan resource Provenance.
Sebelum menggunakan salah satu data permintaan, lakukan penggantian berikut:
- PROJECT_ID: project ID Google Cloud Anda
- LOCATION: lokasi set data induk
- DATASET_ID: set data induk penyimpanan FHIR
- OPERATION_METADATA_FHIR_STORE_ID: ID penyimpanan FHIR yang berisi metadata
Meminta isi JSON:
{ "resourceType": "Bundle", "type": "transaction", "entry": [ { "request": {"method": "PUT", "url": "Provenance/operation-123"}, "resource": { "resourceType": "Provenance", "id": "operation-123", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store" } } ], "occurredDateTime": "2010-11-08T08:30:00-04:00", "recorded": "2010-11-08T08:30:24-04:00", "agent": [ { "who": { "identifier": { "system": "https://g.co/healthcare/operation", "value": "projects/my-project/locations/us-central1/datasets/my-dataset/operations/123" } } } ], "entity": [ { "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store" } } } ] } }, { "request": {"method": "POST", "url": "Provenance"}, "resource": { "resourceType": "Provenance", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store/dicomWeb/studies/1/series/2/instances/3" } } ], "recorded": "2010-11-08T08:39:24-04:00", "agent": [ { "who": { "identifier": { "value": "projects/test-project/locations/us-central1/datasets/test-dataset/fhirStores/test-fhir-store/fhir/Provenance/operation-123" } } } ], "entity": [ { "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store/dicomWeb/studies/1/series/2/instances/3" } }, "extension": [ { "url": "https://g.co/dicom-images", "extension": [ { "url": "frame-index", "valueDecimal": 0, "extension": [ { "url": "bottom", "valueDecimal": 100 }, { "url": "left", "valueDecimal": 100 }, { "url": "right", "valueDecimal": 200 }, { "url": "top", "valueDecimal": 200 }, { "url": "relative-bottom", "valueDecimal": 0.05 }, { "url": "relative-left", "valueDecimal": 0.05 }, { "url": "relative-right", "valueDecimal": 0.1 }, { "url": "relative-top", "valueDecimal": 0.1 }, { "url": "bottom", "valueDecimal": 900 }, { "url": "left", "valueDecimal": 900 }, { "url": "right", "valueDecimal": 1000 }, { "url": "top", "valueDecimal": 1000 }, { "url": "relative-bottom", "valueDecimal": 0.45 }, { "url": "relative-left", "valueDecimal": 0.45 }, { "url": "relative-right", "valueDecimal": 0.5 }, { "url": "relative-top", "valueDecimal": 0.5 } ] } ] }, { "url": "https://g.co/dicom-tags", "extension": [ { "url": "tag-id", "valueString": "00100021", "extension": [ { "url": "byte-start", "valueDecimal": 10 }, { "url": "byte-end", "valueDecimal": 18 }, { "url": "finding-infotype", "valueString": "PERSON_NAME" }, { "url": "text-original", "valueString": "John Doe" }, { "url": "text-replaced", "valueString": "PERSON_NAME" }, { "url": "byte-start", "valueDecimal": 25 }, { "url": "byte-end", "valueDecimal": 35 }, { "url": "finding-infotype", "valueString": "DATE" }, { "url": "text-original", "valueString": "1900-12-31" }, { "url": "text-replaced", "valueString": "DATE" } ] }, { "url": "tag-id", "valueString": "00102150", "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 2 }, { "url": "finding-infotype", "valueString": "LOCATION" }, { "url": "text-original", "valueString": "US" }, { "url": "text-replaced", "valueString": "LOCATION" } ] } ] } ] } ] } }, { "request": {"method": "POST", "url": "Provenance"}, "resource": { "resourceType": "Provenance", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store/dicomWeb/studies/1/series/2/instances/4" } } ], "recorded": "2010-11-08T08:39:25-04:00", "agent": [ { "who": { "identifier": { "value": "projects/test-project/locations/us-central1/datasets/test-dataset/fhirStores/test-fhir-store/fhir/Provenance/operation-123" } } } ], "entity": [ { "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store/dicomWeb/studies/1/series/2/instances/4" } }, "extension": [ { "url": "https://g.co/dicom-images", "extension": [ { "url": "frame-index", "valueDecimal": 0 }, { "url": "frame-index", "valueDecimal": 1, "extension": [ ] } ] }, { "url": "https://g.co/dicom-tags", "extension": [ { "url": "tag-id", "valueString": "00101010", "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 2 }, { "url": "finding-infotype", "valueString": "AGE" }, { "url": "text-original", "valueString": "30" }, { "url": "text-replaced", "valueString": "AGE" } ] }, { "url": "tag-id", "valueString": "00100020", "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 4 }, { "url": "finding-infotype", "valueString": "GENERIC_ID" }, { "url": "text-original", "valueString": "1234" }, { "url": "text-replaced", "valueString": "GENERIC_ID" } ] } ] } ] } ] } } ] }
Untuk mengirim permintaan Anda, pilih salah satu opsi berikut:
curl
Simpan isi permintaan dalam file bernama
request.json
. Jalankan perintah berikut di terminal untuk membuat atau menimpa file ini di direktori saat ini:cat > request.json << 'EOF' { "resourceType": "Bundle", "type": "transaction", "entry": [ { "request": {"method": "PUT", "url": "Provenance/operation-123"}, "resource": { "resourceType": "Provenance", "id": "operation-123", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store" } } ], "occurredDateTime": "2010-11-08T08:30:00-04:00", "recorded": "2010-11-08T08:30:24-04:00", "agent": [ { "who": { "identifier": { "system": "https://g.co/healthcare/operation", "value": "projects/my-project/locations/us-central1/datasets/my-dataset/operations/123" } } } ], "entity": [ { "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store" } } } ] } }, { "request": {"method": "POST", "url": "Provenance"}, "resource": { "resourceType": "Provenance", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store/dicomWeb/studies/1/series/2/instances/3" } } ], "recorded": "2010-11-08T08:39:24-04:00", "agent": [ { "who": { "identifier": { "value": "projects/test-project/locations/us-central1/datasets/test-dataset/fhirStores/test-fhir-store/fhir/Provenance/operation-123" } } } ], "entity": [ { "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store/dicomWeb/studies/1/series/2/instances/3" } }, "extension": [ { "url": "https://g.co/dicom-images", "extension": [ { "url": "frame-index", "valueDecimal": 0, "extension": [ { "url": "bottom", "valueDecimal": 100 }, { "url": "left", "valueDecimal": 100 }, { "url": "right", "valueDecimal": 200 }, { "url": "top", "valueDecimal": 200 }, { "url": "relative-bottom", "valueDecimal": 0.05 }, { "url": "relative-left", "valueDecimal": 0.05 }, { "url": "relative-right", "valueDecimal": 0.1 }, { "url": "relative-top", "valueDecimal": 0.1 }, { "url": "bottom", "valueDecimal": 900 }, { "url": "left", "valueDecimal": 900 }, { "url": "right", "valueDecimal": 1000 }, { "url": "top", "valueDecimal": 1000 }, { "url": "relative-bottom", "valueDecimal": 0.45 }, { "url": "relative-left", "valueDecimal": 0.45 }, { "url": "relative-right", "valueDecimal": 0.5 }, { "url": "relative-top", "valueDecimal": 0.5 } ] } ] }, { "url": "https://g.co/dicom-tags", "extension": [ { "url": "tag-id", "valueString": "00100021", "extension": [ { "url": "byte-start", "valueDecimal": 10 }, { "url": "byte-end", "valueDecimal": 18 }, { "url": "finding-infotype", "valueString": "PERSON_NAME" }, { "url": "text-original", "valueString": "John Doe" }, { "url": "text-replaced", "valueString": "PERSON_NAME" }, { "url": "byte-start", "valueDecimal": 25 }, { "url": "byte-end", "valueDecimal": 35 }, { "url": "finding-infotype", "valueString": "DATE" }, { "url": "text-original", "valueString": "1900-12-31" }, { "url": "text-replaced", "valueString": "DATE" } ] }, { "url": "tag-id", "valueString": "00102150", "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 2 }, { "url": "finding-infotype", "valueString": "LOCATION" }, { "url": "text-original", "valueString": "US" }, { "url": "text-replaced", "valueString": "LOCATION" } ] } ] } ] } ] } }, { "request": {"method": "POST", "url": "Provenance"}, "resource": { "resourceType": "Provenance", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store/dicomWeb/studies/1/series/2/instances/4" } } ], "recorded": "2010-11-08T08:39:25-04:00", "agent": [ { "who": { "identifier": { "value": "projects/test-project/locations/us-central1/datasets/test-dataset/fhirStores/test-fhir-store/fhir/Provenance/operation-123" } } } ], "entity": [ { "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store/dicomWeb/studies/1/series/2/instances/4" } }, "extension": [ { "url": "https://g.co/dicom-images", "extension": [ { "url": "frame-index", "valueDecimal": 0 }, { "url": "frame-index", "valueDecimal": 1, "extension": [ ] } ] }, { "url": "https://g.co/dicom-tags", "extension": [ { "url": "tag-id", "valueString": "00101010", "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 2 }, { "url": "finding-infotype", "valueString": "AGE" }, { "url": "text-original", "valueString": "30" }, { "url": "text-replaced", "valueString": "AGE" } ] }, { "url": "tag-id", "valueString": "00100020", "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 4 }, { "url": "finding-infotype", "valueString": "GENERIC_ID" }, { "url": "text-original", "valueString": "1234" }, { "url": "text-replaced", "valueString": "GENERIC_ID" } ] } ] } ] } ] } } ] } EOF
Kemudian, jalankan perintah berikut untuk mengirim permintaan REST Anda:
curl -X POST \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
-H "Content-Type: application/fhir+json" \
-d @request.json \
"https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir"PowerShell
Simpan isi permintaan dalam file bernama
request.json
. Jalankan perintah berikut di terminal untuk membuat atau menimpa file ini di direktori saat ini:@' { "resourceType": "Bundle", "type": "transaction", "entry": [ { "request": {"method": "PUT", "url": "Provenance/operation-123"}, "resource": { "resourceType": "Provenance", "id": "operation-123", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store" } } ], "occurredDateTime": "2010-11-08T08:30:00-04:00", "recorded": "2010-11-08T08:30:24-04:00", "agent": [ { "who": { "identifier": { "system": "https://g.co/healthcare/operation", "value": "projects/my-project/locations/us-central1/datasets/my-dataset/operations/123" } } } ], "entity": [ { "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store" } } } ] } }, { "request": {"method": "POST", "url": "Provenance"}, "resource": { "resourceType": "Provenance", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store/dicomWeb/studies/1/series/2/instances/3" } } ], "recorded": "2010-11-08T08:39:24-04:00", "agent": [ { "who": { "identifier": { "value": "projects/test-project/locations/us-central1/datasets/test-dataset/fhirStores/test-fhir-store/fhir/Provenance/operation-123" } } } ], "entity": [ { "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store/dicomWeb/studies/1/series/2/instances/3" } }, "extension": [ { "url": "https://g.co/dicom-images", "extension": [ { "url": "frame-index", "valueDecimal": 0, "extension": [ { "url": "bottom", "valueDecimal": 100 }, { "url": "left", "valueDecimal": 100 }, { "url": "right", "valueDecimal": 200 }, { "url": "top", "valueDecimal": 200 }, { "url": "relative-bottom", "valueDecimal": 0.05 }, { "url": "relative-left", "valueDecimal": 0.05 }, { "url": "relative-right", "valueDecimal": 0.1 }, { "url": "relative-top", "valueDecimal": 0.1 }, { "url": "bottom", "valueDecimal": 900 }, { "url": "left", "valueDecimal": 900 }, { "url": "right", "valueDecimal": 1000 }, { "url": "top", "valueDecimal": 1000 }, { "url": "relative-bottom", "valueDecimal": 0.45 }, { "url": "relative-left", "valueDecimal": 0.45 }, { "url": "relative-right", "valueDecimal": 0.5 }, { "url": "relative-top", "valueDecimal": 0.5 } ] } ] }, { "url": "https://g.co/dicom-tags", "extension": [ { "url": "tag-id", "valueString": "00100021", "extension": [ { "url": "byte-start", "valueDecimal": 10 }, { "url": "byte-end", "valueDecimal": 18 }, { "url": "finding-infotype", "valueString": "PERSON_NAME" }, { "url": "text-original", "valueString": "John Doe" }, { "url": "text-replaced", "valueString": "PERSON_NAME" }, { "url": "byte-start", "valueDecimal": 25 }, { "url": "byte-end", "valueDecimal": 35 }, { "url": "finding-infotype", "valueString": "DATE" }, { "url": "text-original", "valueString": "1900-12-31" }, { "url": "text-replaced", "valueString": "DATE" } ] }, { "url": "tag-id", "valueString": "00102150", "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 2 }, { "url": "finding-infotype", "valueString": "LOCATION" }, { "url": "text-original", "valueString": "US" }, { "url": "text-replaced", "valueString": "LOCATION" } ] } ] } ] } ] } }, { "request": {"method": "POST", "url": "Provenance"}, "resource": { "resourceType": "Provenance", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store/dicomWeb/studies/1/series/2/instances/4" } } ], "recorded": "2010-11-08T08:39:25-04:00", "agent": [ { "who": { "identifier": { "value": "projects/test-project/locations/us-central1/datasets/test-dataset/fhirStores/test-fhir-store/fhir/Provenance/operation-123" } } } ], "entity": [ { "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store/dicomWeb/studies/1/series/2/instances/4" } }, "extension": [ { "url": "https://g.co/dicom-images", "extension": [ { "url": "frame-index", "valueDecimal": 0 }, { "url": "frame-index", "valueDecimal": 1, "extension": [ ] } ] }, { "url": "https://g.co/dicom-tags", "extension": [ { "url": "tag-id", "valueString": "00101010", "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 2 }, { "url": "finding-infotype", "valueString": "AGE" }, { "url": "text-original", "valueString": "30" }, { "url": "text-replaced", "valueString": "AGE" } ] }, { "url": "tag-id", "valueString": "00100020", "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 4 }, { "url": "finding-infotype", "valueString": "GENERIC_ID" }, { "url": "text-original", "valueString": "1234" }, { "url": "text-replaced", "valueString": "GENERIC_ID" } ] } ] } ] } ] } } ] } '@ | Out-File -FilePath request.json -Encoding utf8
Kemudian jalankan perintah berikut untuk mengirim permintaan REST Anda:
$cred = gcloud auth print-access-token
$headers = @{ "Authorization" = "Bearer $cred" }
Invoke-WebRequest `
-Method POST `
-Headers $headers `
-ContentType: "application/fhir+json" `
-InFile request.json `
-Uri "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir" | Select-Object -Expand ContentAnda akan melihat respons JSON seperti berikut:
Buat resource SearchParameter pada gambar DICOM sumber.
Sebelum menggunakan salah satu data permintaan, lakukan penggantian berikut:
- PROJECT_ID: project ID Google Cloud Anda
- LOCATION: lokasi set data induk
- DATASET_ID: set data induk penyimpanan FHIR
- OPERATION_METADATA_FHIR_STORE_ID: ID penyimpanan FHIR yang berisi metadata
Meminta isi JSON:
{ "resourceType": "SearchParameter", "url": "lookup-source-instance", "base": ["Provenance"], "code": "lookup-source-instance", "name": "look up the source DICOM instance", "type": "string", "expression": "Provenance.entity.what.identifier.value", "status": "active", "description": "A search on the source DICOM instance" }
Untuk mengirim permintaan Anda, pilih salah satu opsi berikut:
curl
Simpan isi permintaan dalam file bernama
request.json
. Jalankan perintah berikut di terminal untuk membuat atau menimpa file ini di direktori saat ini:cat > request.json << 'EOF' { "resourceType": "SearchParameter", "url": "lookup-source-instance", "base": ["Provenance"], "code": "lookup-source-instance", "name": "look up the source DICOM instance", "type": "string", "expression": "Provenance.entity.what.identifier.value", "status": "active", "description": "A search on the source DICOM instance" } EOF
Kemudian, jalankan perintah berikut untuk mengirim permintaan REST Anda:
curl -X POST \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
-H "Content-Type: application/fhir+json" \
-d @request.json \
"https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir/SearchParameter"PowerShell
Simpan isi permintaan dalam file bernama
request.json
. Jalankan perintah berikut di terminal untuk membuat atau menimpa file ini di direktori saat ini:@' { "resourceType": "SearchParameter", "url": "lookup-source-instance", "base": ["Provenance"], "code": "lookup-source-instance", "name": "look up the source DICOM instance", "type": "string", "expression": "Provenance.entity.what.identifier.value", "status": "active", "description": "A search on the source DICOM instance" } '@ | Out-File -FilePath request.json -Encoding utf8
Kemudian jalankan perintah berikut untuk mengirim permintaan REST Anda:
$cred = gcloud auth print-access-token
$headers = @{ "Authorization" = "Bearer $cred" }
Invoke-WebRequest `
-Method POST `
-Headers $headers `
-ContentType: "application/fhir+json" `
-InFile request.json `
-Uri "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir/SearchParameter" | Select-Object -Expand ContentAnda akan melihat respons JSON seperti berikut:
Aktifkan resource SearchParameter kustom di FHIR Store.
Sebelum menggunakan salah satu data permintaan, lakukan penggantian berikut:
- PROJECT_ID: project ID Google Cloud Anda
- LOCATION: lokasi set data induk
- DATASET_ID: set data induk penyimpanan FHIR
- OPERATION_METADATA_FHIR_STORE_ID: ID penyimpanan FHIR yang berisi metadata
Meminta isi JSON:
{ "canonicalUrls": [ "lookup-source-instance" ] }
Untuk mengirim permintaan Anda, pilih salah satu opsi berikut:
curl
Simpan isi permintaan dalam file bernama
request.json
. Jalankan perintah berikut di terminal untuk membuat atau menimpa file ini di direktori saat ini:cat > request.json << 'EOF' { "canonicalUrls": [ "lookup-source-instance" ] } EOF
Kemudian, jalankan perintah berikut untuk mengirim permintaan REST Anda:
curl -X POST \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
-H "Content-Type: application/fhir+json" \
-d @request.json \
"https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID:configureSearch"PowerShell
Simpan isi permintaan dalam file bernama
request.json
. Jalankan perintah berikut di terminal untuk membuat atau menimpa file ini di direktori saat ini:@' { "canonicalUrls": [ "lookup-source-instance" ] } '@ | Out-File -FilePath request.json -Encoding utf8
Kemudian jalankan perintah berikut untuk mengirim permintaan REST Anda:
$cred = gcloud auth print-access-token
$headers = @{ "Authorization" = "Bearer $cred" }
Invoke-WebRequest `
-Method POST `
-Headers $headers `
-ContentType: "application/fhir+json" `
-InFile request.json `
-Uri "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID:configureSearch" | Select-Object -Expand ContentMendapatkan status operasi.
Sebelum menggunakan salah satu data permintaan, lakukan penggantian berikut:
- PROJECT_ID: project ID Google Cloud Anda
- LOCATION: lokasi set data
- DATASET_ID: set data tempat operasi penelusuran kustom berjalan
- OPERATION_ID: ID operasi penelusuran kustom
Untuk mengirim permintaan Anda, pilih salah satu opsi berikut:
curl
Jalankan perintah berikut:
curl -X GET \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
"https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/operations/OPERATION_ID"PowerShell
Jalankan perintah berikut:
$cred = gcloud auth print-access-token
$headers = @{ "Authorization" = "Bearer $cred" }
Invoke-WebRequest `
-Method GET `
-Headers $headers `
-Uri "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/operations/OPERATION_ID" | Select-Object -Expand ContentAPIs Explorer
Buka halaman referensi metode. Panel API Explorer terbuka di sisi kanan halaman. Anda bisa berinteraksi dengan alat ini untuk mengirim permintaan. Lengkapi kolom yang wajib diisi, lalu klik Jalankan.
Anda akan melihat respons JSON seperti berikut:
Buat kueri resource Provenance menggunakan parameter penelusuran gambar DICOM sumber.
Sebelum menggunakan salah satu data permintaan, lakukan penggantian berikut:
- PROJECT_ID: project ID Google Cloud Anda
- LOCATION: lokasi set data induk
- DATASET_ID: set data induk penyimpanan FHIR
- OPERATION_METADATA_FHIR_STORE_ID: ID penyimpanan FHIR yang berisi metadata
Untuk mengirim permintaan Anda, pilih salah satu opsi berikut:
curl
Contoh berikut menggunakan kuerilookup-source-instance:contains=studies/1/series/2/instances/4
, yang menampilkan informasi tentang instance yang berisistudies/1/series/2/instances/4
dalam ID-nya.Jalankan perintah berikut:
curl -X GET \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
"https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir/Provenance?lookup-source-instance:contains=studies/1/series/2/instances/4"PowerShell
Contoh berikut menggunakan kuerilookup-source-instance:contains=studies/1/series/2/instances/4
, yang menampilkan informasi tentang instance yang berisistudies/1/series/2/instances/4
dalam ID-nya.Jalankan perintah berikut:
$cred = gcloud auth print-access-token
$headers = @{ "Authorization" = "Bearer $cred" }
Invoke-WebRequest `
-Method GET `
-Headers $headers `
-Uri "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir/Provenance?lookup-source-instance:contains=studies/1/series/2/instances/4" | Select-Object -Expand Content{ "entry": [ { "fullUrl": "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir/Provenance/d82007a1-6481-4793-b17c-ae152051ee9f", "resource": { "agent": [ { "who": { "identifier": { "value": "projects/test-project/locations/us-central1/datasets/test-dataset/fhirStores/test-fhir-store/fhir/Provenance/operation-123" } } } ], "entity": [ { "extension": [ { "extension": [ { "url": "frame-index", "valueDecimal": 0 }, { "url": "frame-index", "valueDecimal": 1 } ], "url": "https://g.co/dicom-images" }, { "extension": [ { "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 2 }, { "url": "finding-infotype", "valueString": "AGE" }, { "url": "text-original", "valueString": "30" }, { "url": "text-replaced", "valueString": "AGE" } ], "url": "tag-id", "valueString": "00101010" }, { "extension": [ { "url": "byte-start", "valueDecimal": 0 }, { "url": "byte-end", "valueDecimal": 4 }, { "url": "finding-infotype", "valueString": "GENERIC_ID" }, { "url": "text-original", "valueString": "1234" }, { "url": "text-replaced", "valueString": "GENERIC_ID" } ], "url": "tag-id", "valueString": "00100020" } ], "url": "https://g.co/dicom-tags" } ], "role": "source", "what": { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/test-dicom-store/dicomWeb/studies/1/series/2/instances/4" } } } ], "id": "d82007a1-6481-4793-b17c-ae152051ee9f", "meta": { "lastUpdated": "2022-03-07T20:28:07.970361+00:00", "versionId": "MTY0NjY4NDg4Nzk3MDM2MTAwMA" }, "recorded": "2010-11-08T08:39:25-04:00", "resourceType": "Provenance", "target": [ { "identifier": { "value": "https://healthcare.googleapis.com/projects/test-project/locations/us-central1/datasets/test-dataset/dicomStores/deid-dicom-store/dicomWeb/studies/1/series/2/instances/4" } } ] }, "search": { "mode": "match" } } ], "link": [ { "relation": "search", "url": "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir/Provenance/?lookup-source-instance%3Acontains=studies%2F1%2Fseries%2F2%2Finstances%2F4" }, { "relation": "first", "url": "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir/Provenance/?lookup-source-instance%3Acontains=studies%2F1%2Fseries%2F2%2Finstances%2F4" }, { "relation": "self", "url": "https://healthcare.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION/datasets/DATASET_ID/fhirStores/OPERATION_METADATA_FHIR_STORE_ID/fhir/Provenance/?lookup-source-instance%3Acontains=studies%2F1%2Fseries%2F2%2Finstances%2F4" } ], "resourceType": "Bundle", "total": 1, "type": "searchset" }
Mengekspor dan membuat kueri penyimpanan FHIR metadata operasi
Contoh berikut menunjukkan cara mengekspor metadata operasi de-identifikasi di penyimpanan FHIR ke BigQuery dan membuat kueri data yang diekspor untuk data PHI yang diproses oleh OCR. Data yang dihasilkan hanya kompatibel dengan
SchemaType
LOSSLESS
atau ANALYTICS_V2
.
Ekspor metadata di penyimpanan FHIR ke set data BigQuery.
Metadata diekspor ke tabel bernama
Provenance
di set data BigQuery yang dipilih.Buka halaman BigQuery.
Di panel Penjelajah, selesaikan langkah-langkah berikut:
- Pilih project Google Cloud Anda.
- Pilih set data BigQuery tempat Anda mengekspor metadata DICOM.
- Pilih tabel Provenance.
Klik
Compose new query.Jalankan kueri berikut:
SELECT what.identifier.value AS Source, target[OFFSET(0)].identifier.value AS Destination, `left` AS `Left`, `right` AS `Right`, top AS Top, bottom AS Bottom, quote AS Quote, infoType AS InfoType, confidence AS Confidence FROM `PROJECT_ID.BIGQUERY_DATASET.Provenance`, UNNEST(entity), UNNEST(dicom_images), UNNEST(frame_index) LIMIT 10
Ganti kode berikut:
- PROJECT_ID: ID project Google Cloud Anda
- BIGQUERY_DATASET: set data BigQuery tempat Anda mengekspor metadata dari penyimpanan FHIR
Klik
Run.Hasil kueri menampilkan metadata untuk data PHI yang dide-identifikasi dalam format tabel. Jika Anda tidak menentukan tabel tujuan, tugas kueri akan menulis output ke tabel sementara (cache).
Kuota
Menulis metadata operasi de-identifikasi ke penyimpanan FHIR akan menggunakan kuota fhir_write_ops
di project tempat metadata operasi ditulis.
Satu resource FHIR dibuat untuk setiap instance DICOM, sehingga throughput operasi penghapusan identitas tidak boleh lebih besar dari yang diizinkan kuota FHIR Anda.
Penagihan
Setiap resource Provenance yang dibuat di penyimpanan FHIR metadata operasi
akan dikenai biaya untuk memanggil fhir.update
.
Jumlah panggilan API ke fhir.update
dapat dihitung sebagai:
Total number of DICOM instances de-identified + 1
.
Langkah selanjutnya
- Pelajari cara mengekspor resource FHIR ke BigQuery untuk eksplorasi dan analisis.
- Pelajari cara melakukan streaming perubahan resource FHIR ke BigQuery untuk menyinkronkan data di penyimpanan FHIR dengan set data BigQuery dalam waktu mendekati real-time.