Microsoft.Storage storageAccounts/dataShares

Bicep resource definition

The storageAccounts/dataShares resource type can be deployed with operations that target:

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.Storage/storageAccounts/dataShares resource, add the following Bicep to your template.

resource symbolicname 'Microsoft.Storage/storageAccounts/dataShares@2026-04-01' = {
  parent: resourceSymbolicName
  location: 'string'
  name: 'string'
  properties: {
    accessPolicies: [
      {
        permission: 'string'
        principalId: 'string'
        tenantId: 'string'
      }
    ]
    assets: [
      {
        assetPath: 'string'
        displayName: 'string'
      }
    ]
    description: 'string'
  }
  tags: {
    {customized property}: 'string'
  }
}

Property Values

Microsoft.Storage/storageAccounts/dataShares

Name Description Value
location The geo-location where the resource lives string (required)
name The resource name string

Constraints:
Min length = 3
Max length = 63
Pattern = ^[a-z0-9](?!.*--)[a-z0-9-]{1,61}[a-z0-9]$ (required)
parent In Bicep, you can specify the parent resource for a child resource. You only need to add this property when the child resource is declared outside of the parent resource.

For more information, see Child resource outside parent resource.
Symbolic name for resource of type: storageAccounts
properties The properties of the Storage DataShare. StorageDataShareProperties (required)
tags Resource tags Dictionary of tag names and values. See Tags in templates

StorageDataShareAccessPolicy

Name Description Value
permission Allowed permissions. Currently, only supported value is Read. 'None'
'Read' (required)
principalId The AAD principal ID of the Managed Identity. string

Constraints:
Pattern = ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$ (required)
tenantId The AAD tenant ID of the Managed Identity. string

Constraints:
Pattern = ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$ (required)

StorageDataShareAsset

Name Description Value
assetPath Source Path to be shared. It can be a folder or a blob.
The asset path should contain container name followed by path within the container, e.g. /container1/logs/external.
string (required)
displayName Consumer visible name of the original path. string (required)

StorageDataShareProperties

Name Description Value
accessPolicies List of access policies that specify the permission allowed to a managed identity.
For Create - This property is required and cannot be null. If no access policies are provided at creation time, specify an empty array.
For Update - This property is optional. If set to null or not passed, the existing access policies are left unchanged.
If provided with a non-null value, the existing access policies are replaced with the specified list.
StorageDataShareAccessPolicy[] (required)
assets List of assets that specify the properties of the shared resources.
For Create - This property is required and cannot be null. If no assets are provided at creation time, specify an empty array.
For Update - This property is optional. If set to null or not passed, the existing assets are left unchanged.
If provided with a non-null value, the existing assets are replaced with the specified list.
StorageDataShareAsset[] (required)
description Arbitrary description of this Data Share. Max 250 characters. string

Constraints:
Max length = 250

TrackedResourceTags

Name Description Value

ARM template resource definition

The storageAccounts/dataShares resource type can be deployed with operations that target:

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.Storage/storageAccounts/dataShares resource, add the following JSON to your template.

{
  "type": "Microsoft.Storage/storageAccounts/dataShares",
  "apiVersion": "2026-04-01",
  "name": "string",
  "location": "string",
  "properties": {
    "accessPolicies": [
      {
        "permission": "string",
        "principalId": "string",
        "tenantId": "string"
      }
    ],
    "assets": [
      {
        "assetPath": "string",
        "displayName": "string"
      }
    ],
    "description": "string"
  },
  "tags": {
    "{customized property}": "string"
  }
}

Property Values

Microsoft.Storage/storageAccounts/dataShares

Name Description Value
apiVersion The api version '2026-04-01'
location The geo-location where the resource lives string (required)
name The resource name string

Constraints:
Min length = 3
Max length = 63
Pattern = ^[a-z0-9](?!.*--)[a-z0-9-]{1,61}[a-z0-9]$ (required)
properties The properties of the Storage DataShare. StorageDataShareProperties (required)
tags Resource tags Dictionary of tag names and values. See Tags in templates
type The resource type 'Microsoft.Storage/storageAccounts/dataShares'

StorageDataShareAccessPolicy

Name Description Value
permission Allowed permissions. Currently, only supported value is Read. 'None'
'Read' (required)
principalId The AAD principal ID of the Managed Identity. string

Constraints:
Pattern = ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$ (required)
tenantId The AAD tenant ID of the Managed Identity. string

Constraints:
Pattern = ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$ (required)

StorageDataShareAsset

Name Description Value
assetPath Source Path to be shared. It can be a folder or a blob.
The asset path should contain container name followed by path within the container, e.g. /container1/logs/external.
string (required)
displayName Consumer visible name of the original path. string (required)

StorageDataShareProperties

Name Description Value
accessPolicies List of access policies that specify the permission allowed to a managed identity.
For Create - This property is required and cannot be null. If no access policies are provided at creation time, specify an empty array.
For Update - This property is optional. If set to null or not passed, the existing access policies are left unchanged.
If provided with a non-null value, the existing access policies are replaced with the specified list.
StorageDataShareAccessPolicy[] (required)
assets List of assets that specify the properties of the shared resources.
For Create - This property is required and cannot be null. If no assets are provided at creation time, specify an empty array.
For Update - This property is optional. If set to null or not passed, the existing assets are left unchanged.
If provided with a non-null value, the existing assets are replaced with the specified list.
StorageDataShareAsset[] (required)
description Arbitrary description of this Data Share. Max 250 characters. string

Constraints:
Max length = 250

TrackedResourceTags

Name Description Value

Usage Examples

Terraform (AzAPI provider) resource definition

The storageAccounts/dataShares resource type can be deployed with operations that target:

  • Resource groups

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.Storage/storageAccounts/dataShares resource, add the following Terraform to your template.

resource "azapi_resource" "symbolicname" {
  type = "Microsoft.Storage/storageAccounts/dataShares@2026-04-01"
  name = "string"
  parent_id = "string"
  location = "string"
  tags = {
    {customized property} = "string"
  }
  body = {
    properties = {
      accessPolicies = [
        {
          permission = "string"
          principalId = "string"
          tenantId = "string"
        }
      ]
      assets = [
        {
          assetPath = "string"
          displayName = "string"
        }
      ]
      description = "string"
    }
  }
}

Property Values

Microsoft.Storage/storageAccounts/dataShares

Name Description Value
location The geo-location where the resource lives string (required)
name The resource name string

Constraints:
Min length = 3
Max length = 63
Pattern = ^[a-z0-9](?!.*--)[a-z0-9-]{1,61}[a-z0-9]$ (required)
parent_id The ID of the resource that is the parent for this resource. ID for resource of type: storageAccounts
properties The properties of the Storage DataShare. StorageDataShareProperties (required)
tags Resource tags Dictionary of tag names and values.
type The resource type "Microsoft.Storage/storageAccounts/dataShares@2026-04-01"

StorageDataShareAccessPolicy

Name Description Value
permission Allowed permissions. Currently, only supported value is Read. 'None'
'Read' (required)
principalId The AAD principal ID of the Managed Identity. string

Constraints:
Pattern = ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$ (required)
tenantId The AAD tenant ID of the Managed Identity. string

Constraints:
Pattern = ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$ (required)

StorageDataShareAsset

Name Description Value
assetPath Source Path to be shared. It can be a folder or a blob.
The asset path should contain container name followed by path within the container, e.g. /container1/logs/external.
string (required)
displayName Consumer visible name of the original path. string (required)

StorageDataShareProperties

Name Description Value
accessPolicies List of access policies that specify the permission allowed to a managed identity.
For Create - This property is required and cannot be null. If no access policies are provided at creation time, specify an empty array.
For Update - This property is optional. If set to null or not passed, the existing access policies are left unchanged.
If provided with a non-null value, the existing access policies are replaced with the specified list.
StorageDataShareAccessPolicy[] (required)
assets List of assets that specify the properties of the shared resources.
For Create - This property is required and cannot be null. If no assets are provided at creation time, specify an empty array.
For Update - This property is optional. If set to null or not passed, the existing assets are left unchanged.
If provided with a non-null value, the existing assets are replaced with the specified list.
StorageDataShareAsset[] (required)
description Arbitrary description of this Data Share. Max 250 characters. string

Constraints:
Max length = 250

TrackedResourceTags

Name Description Value