Share via


快速入門:使用ARM範本來部署 Azure API for FHIR

重要

Azure API for FHIR 將於 2026 年 9 月 30 日淘汰。 請遵循移轉策略,依該日期轉換至 Azure Health Data Services FHIR 服務。 由於 Azure API for FHIR 已淘汰,因此從 2025 年 4 月 1 日開始,將不允許新的部署。 Azure Health Data Services FHIR 服務 是已演進的 Azure API for FHIR 版本,可讓客戶管理 FHIR、DICOM 和 MedTech 服務,並整合至其他 Azure 服務。

在本快速入門中,您將瞭解如何使用 Azure Resource Manager 範本 (ARM 範本) 來部署適用於快速醫療保健互操作性資源的 Azure API。 ® 您可以透過 Azure 入口網站、PowerShell 或 CLI 來部署 Azure API for FHIR。

Azure Resource Manager 範本是 JavaScript 物件表示法 (JSON) 檔案,可定義專案的基礎結構和組態。 範本使用宣告式語法。 您不需要撰寫程式設計命令順序來建立部署,即可描述預定的部署。

如果您的環境符合必要條件,而且您很熟悉 ARM 範本,請選取 [部署至 Azure] 按鈕。 登入后,範本會在 Azure 入口網站 中開啟。

Button to deploy the Resource Manager template to Azure.

必要條件

具有有效訂用帳戶的 Azure 帳戶。 免費建立一個

檢閱範本

本快速入門中使用的範本是來自 Azure 快速入門範本

{
  "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
  "contentVersion": "1.0.0.0",
  "metadata": {
    "_generator": {
      "name": "bicep",
      "version": "0.5.6.12127",
      "templateHash": "9588053699595008971"
    }
  },
  "parameters": {
    "serviceName": {
      "type": "string",
      "metadata": {
        "description": "The name of the service."
      }
    },
    "location": {
      "type": "string",
      "allowedValues": [
        "australiaeast",
        "eastus",
        "eastus2",
        "japaneast",
        "northcentralus",
        "northeurope",
        "southcentralus",
        "southeastasia",
        "uksouth",
        "ukwest",
        "westcentralus",
        "westeurope",
        "westus2"
      ],
      "metadata": {
        "description": "Location of Azure API for FHIR"
      }
    }
  },
  "resources": [
    {
      "type": "Microsoft.HealthcareApis/services",
      "apiVersion": "2021-11-01",
      "name": "[parameters('serviceName')]",
      "location": "[parameters('location')]",
      "kind": "fhir-R4",
      "properties": {
        "authenticationConfiguration": {
          "audience": "[format('https://{0}.azurehealthcareapis.com', parameters('serviceName'))]",
          "authority": "[uri(environment().authentication.loginEndpoint, subscription().tenantId)]"
        }
      }
    }
  ]
}

樣本會定義一個 Azure 資源:

  • Microsoft.HealthcareApis/services

部署範本

選取下列連結,以使用 Azure 入口網站 中的 ARM 範本來部署 Azure API for FHIR:

Button to deploy the Resource Manager template to Azure.

在 [ 部署 Azure API for FHIR ] 頁面上:

  1. 如果您想要,請將 [ 訂用帳戶 ] 從預設值變更為不同的訂用帳戶。

  2. 針對 [ 資源群組],選取 [新建],輸入新資源群組的名稱,然後選取 [ 確定]。

  3. 如果您已建立新的資源群組,請選取資源群組的區域。

  4. 輸入新的 服務名稱 ,然後選擇 Azure API for FHIR 的位置 。 位置可以與資源群組的區域相同或不同。

    Deploy Azure API for FHIR using the ARM template in the Azure portal.

  5. 選取 [檢閱 + 建立]。

  6. 閱讀條款和條件,然後選取 [ 建立]。

注意

部署需要幾分鐘的時間才能完成。 記下 Azure API for FHIR 服務和資源群組的名稱,您稍後會用來檢閱已部署的資源。

檢閱已部署的資源

請遵循下列步驟來查看新 Azure API for FHIR 服務的概觀:

  1. Azure 入口網站 中,搜尋並選取 [Azure API for FHIR]。

  2. 在 FHIR 清單中,選取您的新服務。 新的 Azure API for FHIR 服務的 [ 概觀 ] 頁面隨即出現。

  3. 若要驗證已布建新的 FHIR API 帳戶,請選取 FHIR 元數據端點的連結以擷取 FHIR API 功能語句。 連結的格式為 https://<service-name>.azurehealthcareapis.com/metadata。 如果已布建帳戶,則會顯示大型 JSON 檔案。

清除資源

不再需要資源群組時,請刪除資源群組,以刪除資源群組中的資源。

  1. Azure 入口網站 中,搜尋並選取 [資源群組]。

  2. 在資源群組清單中,選擇資源群組的名稱。

  3. 在資源群組的 [ 概觀] 頁面中,選取 [ 刪除資源群組]。

  4. 在確認對話框中,輸入資源群組的名稱,然後選取 [ 刪除]。

如需逐步教學課程,引導您完成建立ARM範本的程式,請參閱 建立和部署第一個ARM範本的教學課程

下一步

在本快速入門指南中,您已將 Azure API for FHIR 部署至您的訂用帳戶。 如需如何註冊應用程式和 Azure API for FHIR 組態設定的詳細資訊,請參閱

FHIR® 是 HL7註冊商標,並搭配 HL7 的許可權使用。