Quickstart: Deploy the Azure Health Data Services de-identification service with Bicep

In this quickstart, you use a Bicep definition to deploy a de-identification service.

Bicep is a domain-specific language (DSL) that uses declarative syntax to deploy Azure resources. It provides concise syntax, reliable type safety, and support for code reuse. Bicep offers the best authoring experience for your infrastructure-as-code solutions in Azure.

If your environment meets the prerequisites and you're familiar with using Bicep, select the Deploy to Azure button. The template opens in the Azure portal.

Button to deploy the Bicep definition to Azure.

Prerequisites

  • If you don't have an Azure subscription, create a free account before you begin.

Review the Bicep file

The Bicep file used in this quickstart is from Azure Quickstart Templates.

@description('The name of the Azure Health Data Services de-identification service to create. Name must be alphanumeric, between 1 and 30 characters in length, and unique per resource group.')
@minLength(1)
@maxLength(30)
param deidServiceName string

@description('Location of the Azure Health Data Services de-identification service.')
param location string = resourceGroup().location

resource deidentificationService 'Microsoft.HealthDataAIServices/deidServices@2024-09-20' = {
  name: deidServiceName
  location: location
  identity: {
    type: 'SystemAssigned'
  }
}

output deidServiceName string = deidentificationService.properties.serviceUrl

The following Azure resources are defined in the Bicep file:

Deploy the Bicep file

  1. Save the Bicep file as main.bicep to your local computer.

  2. Deploy the Bicep file by using either Azure CLI or Azure PowerShell, replacing <deid-service-name> with a name for your de-identification service.

    This command requires Azure CLI version 2.6 or later. You can check the currently installed version by running az --version.

    az group create --name exampleRG --location eastus
    az deployment group create --resource-group exampleRG --template-file main.bicep --parameters deidServiceName=<deid-service-name>
    

Review deployed resources

Use the Azure portal, the Azure CLI, or Azure PowerShell to list the deployed resources in the resource group.

az resource list --resource-group exampleRG

Clean up resources

When you no longer need the resources, use the Azure portal, the Azure CLI, or Azure PowerShell to delete the resource group.

az group delete --name exampleRG

Next steps