Asynchroon maakt u een nieuw opslagaccount met de opgegeven parameters. Als er al een account is gemaakt en er een volgende aanvraag voor maken wordt uitgegeven met verschillende eigenschappen, worden de accounteigenschappen bijgewerkt. Als er al een account is gemaakt en er een volgende aanvraag voor maken of bijwerken wordt uitgegeven met exact dezelfde set eigenschappen, slaagt de aanvraag.
PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}?api-version=2026-09-01
URI-parameters
| Naam |
In |
Vereist |
Type |
Description |
|
accountName
|
path |
True
|
string
minLength: 3 maxLength: 24 pattern: ^[a-z0-9]+$
|
De naam van het opslagaccount binnen de opgegeven resourcegroep. Namen van opslagaccounts mogen tussen de 3 en 24 tekens lang zijn en mogen alleen cijfers en kleine letters gebruiken.
|
|
resourceGroupName
|
path |
True
|
string
minLength: 1 maxLength: 90
|
De naam van de resource group. De naam is hoofdletterongevoelig.
|
|
subscriptionId
|
path |
True
|
string
(uuid)
|
De ID van het doelabonnement. De waarde moet een UUID zijn.
|
|
api-version
|
query |
True
|
string
minLength: 1
|
De API-versie die voor deze bewerking moet worden gebruikt.
|
Aanvraagbody
| Naam |
Vereist |
Type |
Description |
|
kind
|
True
|
Kind
|
Required. Geeft het type opslagaccount aan.
|
|
location
|
True
|
string
|
Required. Hiermee haalt u de locatie van de resource op of stelt u deze in. Dit is een van de ondersteunde en geregistreerde Azure Geo-regio's (bijvoorbeeld VS - west, VS - oost, Azië - zuidoost, enzovoort). De geografische regio van een resource kan niet worden gewijzigd zodra deze is gemaakt, maar als er een identieke geografische regio is opgegeven bij het bijwerken, slaagt de aanvraag.
|
|
sku
|
True
|
Sku
|
Required. Hiermee haalt u de SKU-naam op of stelt u deze in.
|
|
extendedLocation
|
|
ExtendedLocation
|
Optional. Stel de uitgebreide locatie van de resource in. Als dit niet is ingesteld, wordt het opslagaccount gemaakt in de hoofdregio van Azure. Anders wordt deze gemaakt op de opgegeven uitgebreide locatie
|
|
identity
|
|
Identity
|
De identiteit van de resource.
|
|
placement
|
|
Placement
|
Optional. Hiermee haalt u de zoneplaatsingsgegevens voor het opslagaccount op of stelt u deze in.
|
|
properties.accessTier
|
|
AccessTier
|
Vereist voor opslagaccounts waarbij soort = BlobStorage. De toegangslaag wordt gebruikt voor facturering. De toegangslaag Premium is de standaardwaarde voor het opslagaccounttype Premium-blok-blobs en kan niet worden gewijzigd voor het opslagaccounttype premium blok-blobs.
|
|
properties.allowBlobPublicAccess
|
|
boolean
|
Openbare toegang tot alle blobs of containers in het opslagaccount toestaan of weigeren. De standaardinterpretatie is onwaar voor deze eigenschap.
|
|
properties.allowCrossTenantDelegationSas
|
|
boolean
|
Sta wel of niet toe dat je een SAS (shared access signature) tussen AAD tenant-gebruikers delegeerde en niet toestaat. De standaardinterpretatie is onwaar voor deze eigenschap.
|
|
properties.allowCrossTenantReplication
|
|
boolean
|
Replicatie van meerdere AAD-tenantobjecten toestaan of weigeren. Stel deze eigenschap alleen in op waar voor nieuwe of bestaande accounts als objectreplicatiebeleid opslagaccounts in verschillende AAD-tenants omvat. De standaardinterpretatie is onwaar voor nieuwe accounts om standaard de aanbevolen beveiligingsprocedures te volgen.
|
|
properties.allowSharedKeyAccess
|
|
boolean
|
Hiermee wordt aangegeven of het opslagaccount toestaat dat aanvragen worden geautoriseerd met de toegangssleutel voor het account via een gedeelde sleutel. Als het onwaar is, moeten alle verzoeken, inclusief shared access-handtekeningen, worden geautoriseerd met Azure Active Directory (Azure AD). De standaardwaarde is null, wat gelijk is aan waar.
|
|
properties.allowSharedKeyAccessForServices
|
|
StorageAccountSharedKeyAccessProperties
|
Geef gedeelde sleuteltoegangseigenschappen aan op serviceniveau
|
|
properties.allowedCopyScope
|
|
AllowedCopyScope
|
Kopiëren naar en van opslagaccounts in een AAD-tenant of met privékoppelingen naar hetzelfde VNet beperken.
|
|
properties.azureFilesIdentityBasedAuthentication
|
|
AzureFilesIdentityBasedAuthentication
|
Biedt de identiteitsgebaseerde authenticatie-instellingen voor Azure Files.
|
|
properties.customDomain
|
|
CustomDomain
|
Gebruikersdomein dat is toegewezen aan het opslagaccount. De naam is de CNAME-bron. Op dit moment wordt slechts één aangepast domein ondersteund per opslagaccount. Als u het bestaande aangepaste domein wilt wissen, gebruikt u een lege tekenreeks voor de eigenschap aangepaste domeinnaam.
|
|
properties.dataCollaborationPolicyProperties
|
|
StorageDataCollaborationPolicyProperties
|
Data Collaboration-beleid voor het opslagaccount.
|
|
properties.defaultToOAuthAuthentication
|
|
boolean
|
Een Booleaanse vlag die aangeeft of de standaardverificatie OAuth is of niet. De standaardinterpretatie is onwaar voor deze eigenschap.
|
|
properties.dnsEndpointType
|
|
DnsEndpointType
|
Hiermee kunt u het type eindpunt opgeven. Stel dit in op AzureDNSZone om een groot aantal accounts in één abonnement aan te maken, wat accounts aanmaakt in een Azure DNS Zone en de endpoint-URL zal een alfanumerieke DNS Zone-identificatie hebben.
|
|
properties.dualStackEndpointPreference
|
|
DualStackEndpointPreference
|
Houdt informatie bij over het internetprotocol dat door de gebruiker is gekozen.
|
|
properties.enableExtendedGroups
|
|
boolean
|
Biedt uitgebreide groepsondersteuning met de functie lokale gebruikers, indien ingesteld op true
|
|
properties.encryption
|
|
Encryption
|
Versleutelingsinstellingen die moeten worden gebruikt voor versleuteling aan de serverzijde voor het opslagaccount.
|
|
properties.geoPriorityReplicationStatus
|
|
GeoPriorityReplicationStatus
|
Status die aangeeft of Geo Priority Replication is ingeschakeld voor het account.
|
|
properties.immutableStorageWithVersioning
|
|
ImmutableStorageAccount
|
De eigenschap is onveranderbaar en kan alleen worden ingesteld op true tijdens het maken van het account. Als deze optie is ingesteld op waar, wordt de onveranderbaarheid op objectniveau standaard ingeschakeld voor alle nieuwe containers in het account.
|
|
properties.isHnsEnabled
|
|
boolean
|
Account HierarchicalNamespace ingeschakeld als deze is ingesteld op waar.
|
|
properties.isLocalUserEnabled
|
|
boolean
|
Hiermee schakelt u de functie lokale gebruikers in, indien ingesteld op waar
|
|
properties.isNfsV3Enabled
|
|
boolean
|
Ondersteuning voor NFS 3.0-protocollen is ingeschakeld als deze is ingesteld op waar.
|
|
properties.isSftpEnabled
|
|
boolean
|
Hiermee schakelt u Secure File Transfer Protocol in, indien ingesteld op true
|
|
properties.keyPolicy
|
|
KeyPolicy
|
KeyPolicy toegewezen aan het opslagaccount.
|
|
properties.largeFileSharesState
|
|
LargeFileSharesState
|
Sta grote bestandsshares toe als deze is ingesteld op Ingeschakeld. Deze kan niet worden uitgeschakeld zodra deze is ingeschakeld.
|
|
properties.minimumTlsVersion
|
|
MinimumTlsVersion
|
Stel de minimale TLS-versie in die is toegestaan voor aanvragen voor opslag. De standaardinterpretatie is TLS 1.0 voor deze eigenschap. Minimale TLS versie 1.3 wordt niet ondersteund.
|
|
properties.networkAcls
|
|
NetworkRuleSet
|
Netwerkregelset
|
|
properties.publicNetworkAccess
|
|
PublicNetworkAccess
|
Hiermee kunt u de perimeterconfiguratie van netwerkbeveiliging toestaan, weigeren of toestaan om openbare netwerktoegang tot het opslagaccount te evalueren. De waarde is optioneel, maar moet zijn ingeschakeld, uitgeschakeld of SecuredByPerimeter.
|
|
properties.routingPreference
|
|
RoutingPreference
|
Onderhoudt informatie over de netwerkrouteringskeuze die door de gebruiker is gekozen voor gegevensoverdracht
|
|
properties.sasPolicy
|
|
SasPolicy
|
SasPolicy toegewezen aan het opslagaccount.
|
|
properties.supportsHttpsTrafficOnly
|
|
boolean
|
Hiermee staat u https-verkeer alleen toe naar de opslagservice als deze is ingesteld op waar. De standaardwaarde is waar sinds API-versie 2019-04-01.
|
|
properties.turboTier
|
|
TurboTier
|
Configuratie van Turbo Tier voor het opslagaccount.
|
|
tags
|
|
object
|
Hiermee wordt een lijst met sleutel-waardeparen opgehaald of ingesteld die de resource beschrijven. Deze tags kunnen worden gebruikt voor het weergeven en groeperen van deze resource (tussen resourcegroepen). Er kunnen maximaal 15 tags worden opgegeven voor een resource. Elke tag moet een sleutel hebben met een lengte van maximaal 128 tekens en een waarde met een lengte van maximaal 256 tekens.
|
|
zones
|
|
string[]
|
Optional. Hiermee haalt u de vastgemaakte logische beschikbaarheidszone voor het opslagaccount op of stelt u deze in.
|
Antwoorden
| Naam |
Type |
Description |
|
200 OK
|
StorageAccount
|
De updatebewerking van de resource 'StorageAccount' is geslaagd
|
|
202 Accepted
|
|
Resourcebewerking geaccepteerd.
Kopteksten
- Location: string
- Retry-After: integer
|
|
Other Status Codes
|
ErrorResponse
|
Een onverwachte foutreactie.
|
Beveiliging
azure_auth
OAuth2-stroom voor Azure Active Directory.
Type:
oauth2
Stroom:
implicit
Autorisatie-URL:
https://login.microsoftonline.com/common/oauth2/authorize
Bereiken
| Naam |
Description |
|
user_impersonation
|
Uw gebruikersaccount imiteren
|
Voorbeelden
NfsV3AccountCreate
Voorbeeldaanvraag
PUT https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445?api-version=2026-09-01
{
"kind": "BlockBlobStorage",
"location": "eastus",
"properties": {
"enableExtendedGroups": true,
"isHnsEnabled": true,
"isNfsV3Enabled": true,
"networkAcls": {
"bypass": "AzureServices",
"defaultAction": "Allow",
"ipRules": [],
"virtualNetworkRules": [
{
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Network/virtualNetworks/net123/subnets/subnet12"
}
]
},
"supportsHttpsTrafficOnly": false
},
"sku": {
"name": "Premium_LRS"
}
}
import com.azure.resourcemanager.storage.models.Bypass;
import com.azure.resourcemanager.storage.models.DefaultAction;
import com.azure.resourcemanager.storage.models.Kind;
import com.azure.resourcemanager.storage.models.NetworkRuleSet;
import com.azure.resourcemanager.storage.models.Sku;
import com.azure.resourcemanager.storage.models.SkuName;
import com.azure.resourcemanager.storage.models.StorageAccountCreateParameters;
import com.azure.resourcemanager.storage.models.VirtualNetworkRule;
import java.util.Arrays;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for StorageAccounts Create.
*/
public final class Main {
/*
* x-ms-original-file: 2026-09-01/NfsV3AccountCreate.json
*/
/**
* Sample code: NfsV3AccountCreate.
*
* @param manager Entry point to StorageManager.
*/
public static void nfsV3AccountCreate(com.azure.resourcemanager.storage.StorageManager manager) {
manager.serviceClient().getStorageAccounts().create("res9101", "sto4445", new StorageAccountCreateParameters()
.withSku(new Sku().withName(SkuName.PREMIUM_LRS)).withKind(Kind.BLOCK_BLOB_STORAGE).withLocation("eastus")
.withNetworkRuleSet(new NetworkRuleSet().withBypass(Bypass.AZURE_SERVICES)
.withVirtualNetworkRules(Arrays.asList(new VirtualNetworkRule().withVirtualNetworkResourceId(
"/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Network/virtualNetworks/net123/subnets/subnet12")))
.withIpRules(Arrays.asList()).withDefaultAction(DefaultAction.ALLOW))
.withEnableHttpsTrafficOnly(false).withEnableExtendedGroups(true).withIsHnsEnabled(true)
.withEnableNfsV3(true), com.azure.core.util.Context.NONE);
}
// Use "Map.of" if available
@SuppressWarnings("unchecked")
private static <T> Map<String, T> mapOf(Object... inputs) {
Map<String, T> map = new HashMap<>();
for (int i = 0; i < inputs.length; i += 2) {
String key = (String) inputs[i];
T value = (T) inputs[i + 1];
map.put(key, value);
}
return map;
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python nfs_v3_account_create.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.storage_accounts.begin_create(
resource_group_name="res9101",
account_name="sto4445",
parameters={
"kind": "BlockBlobStorage",
"location": "eastus",
"properties": {
"enableExtendedGroups": True,
"isHnsEnabled": True,
"isNfsV3Enabled": True,
"networkAcls": {
"bypass": "AzureServices",
"defaultAction": "Allow",
"ipRules": [],
"virtualNetworkRules": [
{
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Network/virtualNetworks/net123/subnets/subnet12"
}
],
},
"supportsHttpsTrafficOnly": False,
},
"sku": {"name": "Premium_LRS"},
},
).result()
print(response)
# x-ms-original-file: 2026-09-01/NfsV3AccountCreate.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage/v4"
)
// Generated from example definition: 2026-09-01/NfsV3AccountCreate.json
func ExampleAccountsClient_BeginCreate_nfsV3AccountCreate() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewAccountsClient().BeginCreate(ctx, "res9101", "sto4445", armstorage.AccountCreateParameters{
Kind: to.Ptr(armstorage.KindBlockBlobStorage),
Location: to.Ptr("eastus"),
Properties: &armstorage.AccountPropertiesCreateParameters{
EnableExtendedGroups: to.Ptr(true),
IsHnsEnabled: to.Ptr(true),
EnableNfsV3: to.Ptr(true),
NetworkRuleSet: &armstorage.NetworkRuleSet{
Bypass: to.Ptr(armstorage.BypassAzureServices),
DefaultAction: to.Ptr(armstorage.DefaultActionAllow),
IPRules: []*armstorage.IPRule{},
VirtualNetworkRules: []*armstorage.VirtualNetworkRule{
{
VirtualNetworkResourceID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Network/virtualNetworks/net123/subnets/subnet12"),
},
},
},
EnableHTTPSTrafficOnly: to.Ptr(false),
},
SKU: &armstorage.SKU{
Name: to.Ptr(armstorage.SKUNamePremiumLRS),
},
}, nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
log.Fatalf("failed to poll the result: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res = armstorage.AccountsClientCreateResponse{
// Account: armstorage.Account{
// Name: to.Ptr("sto4445"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts"),
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445"),
// Kind: to.Ptr(armstorage.KindBlockBlobStorage),
// Location: to.Ptr("eastus"),
// Properties: &armstorage.AccountProperties{
// EnableExtendedGroups: to.Ptr(true),
// IsHnsEnabled: to.Ptr(true),
// EnableNfsV3: to.Ptr(true),
// NetworkRuleSet: &armstorage.NetworkRuleSet{
// Bypass: to.Ptr(armstorage.BypassAzureServices),
// DefaultAction: to.Ptr(armstorage.DefaultActionAllow),
// IPRules: []*armstorage.IPRule{
// },
// VirtualNetworkRules: []*armstorage.VirtualNetworkRule{
// {
// VirtualNetworkResourceID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Network/virtualNetworks/net123/subnets/subnet12"),
// },
// },
// },
// EnableHTTPSTrafficOnly: to.Ptr(false),
// },
// SKU: &armstorage.SKU{
// Name: to.Ptr(armstorage.SKUNamePremiumLRS),
// Tier: to.Ptr(armstorage.SKUTierPremium),
// },
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
*
* @summary asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
* x-ms-original-file: 2026-09-01/NfsV3AccountCreate.json
*/
async function nfsV3AccountCreate() {
const credential = new DefaultAzureCredential();
const subscriptionId = "00000000-0000-0000-0000-000000000000";
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.storageAccounts.create("res9101", "sto4445", {
kind: "BlockBlobStorage",
location: "eastus",
enableExtendedGroups: true,
isHnsEnabled: true,
enableNfsV3: true,
networkRuleSet: {
bypass: "AzureServices",
defaultAction: "Allow",
ipRules: [],
virtualNetworkRules: [
{
virtualNetworkResourceId:
"/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Network/virtualNetworks/net123/subnets/subnet12",
},
],
},
enableHttpsTrafficOnly: false,
sku: { name: "Premium_LRS" },
});
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Voorbeeldrespons
{
"name": "sto4445",
"type": "Microsoft.Storage/storageAccounts",
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445",
"kind": "BlockBlobStorage",
"location": "eastus",
"properties": {
"enableExtendedGroups": true,
"isHnsEnabled": true,
"isNfsV3Enabled": true,
"networkAcls": {
"bypass": "AzureServices",
"defaultAction": "Allow",
"ipRules": [],
"virtualNetworkRules": [
{
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Network/virtualNetworks/net123/subnets/subnet12"
}
]
},
"supportsHttpsTrafficOnly": false
},
"sku": {
"name": "Premium_LRS",
"tier": "Premium"
}
}
StorageAccountCreate
Voorbeeldaanvraag
PUT https://management.azure.com/subscriptions/a3f7c2b9-4e1d-4c8a-9d6f-8b2a5e41c7f3/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445?api-version=2026-09-01
{
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"defaultToOAuthAuthentication": false,
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account"
},
"file": {
"enabled": true,
"keyType": "Account"
}
}
},
"isHnsEnabled": true,
"isSftpEnabled": true,
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59",
"requireUserBoundUserDelegationSas": true,
"requireUserBoundUserDelegationSasAction": "Block"
},
"geoPriorityReplicationStatus": {
"isBlobEnabled": true
},
"allowSharedKeyAccessForServices": {
"blob": {
"enabled": true
},
"file": {
"enabled": false
},
"queue": {
"enabled": true
},
"table": {
"enabled": false
}
},
"allowCrossTenantDelegationSas": false
},
"sku": {
"name": "Standard_GRS"
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
import com.azure.resourcemanager.storage.models.Encryption;
import com.azure.resourcemanager.storage.models.EncryptionService;
import com.azure.resourcemanager.storage.models.EncryptionServices;
import com.azure.resourcemanager.storage.models.ExpirationAction;
import com.azure.resourcemanager.storage.models.ExtendedLocation;
import com.azure.resourcemanager.storage.models.ExtendedLocationTypes;
import com.azure.resourcemanager.storage.models.GeoPriorityReplicationStatus;
import com.azure.resourcemanager.storage.models.KeyPolicy;
import com.azure.resourcemanager.storage.models.KeySource;
import com.azure.resourcemanager.storage.models.KeyType;
import com.azure.resourcemanager.storage.models.Kind;
import com.azure.resourcemanager.storage.models.MinimumTlsVersion;
import com.azure.resourcemanager.storage.models.PolicyViolationAction;
import com.azure.resourcemanager.storage.models.RoutingChoice;
import com.azure.resourcemanager.storage.models.RoutingPreference;
import com.azure.resourcemanager.storage.models.SasPolicy;
import com.azure.resourcemanager.storage.models.ServiceSharedKeyAccessProperties;
import com.azure.resourcemanager.storage.models.Sku;
import com.azure.resourcemanager.storage.models.SkuName;
import com.azure.resourcemanager.storage.models.StorageAccountCreateParameters;
import com.azure.resourcemanager.storage.models.StorageAccountSharedKeyAccessProperties;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for StorageAccounts Create.
*/
public final class Main {
/*
* x-ms-original-file: 2026-09-01/StorageAccountCreate.json
*/
/**
* Sample code: StorageAccountCreate.
*
* @param manager Entry point to StorageManager.
*/
public static void storageAccountCreate(com.azure.resourcemanager.storage.StorageManager manager) {
manager.serviceClient().getStorageAccounts()
.create("res9101", "sto4445",
new StorageAccountCreateParameters().withSku(new Sku().withName(SkuName.STANDARD_GRS))
.withKind(Kind.STORAGE).withLocation("eastus")
.withExtendedLocation(
new ExtendedLocation().withName("losangeles001").withType(ExtendedLocationTypes.EDGE_ZONE))
.withTags(mapOf("key1", "fakeTokenPlaceholder", "key2", "fakeTokenPlaceholder"))
.withSasPolicy(
new SasPolicy().withSasExpirationPeriod("1.15:59:59").withExpirationAction(ExpirationAction.LOG)
.withRequireUserBoundUserDelegationSas(true).withRequireUserBoundUserDelegationSasAction(
PolicyViolationAction.BLOCK))
.withKeyPolicy(new KeyPolicy().withKeyExpirationPeriodInDays(20))
.withEncryption(new Encryption()
.withServices(new EncryptionServices()
.withBlob(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT))
.withFile(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT)))
.withKeySource(KeySource.MICROSOFT_STORAGE).withRequireInfrastructureEncryption(false))
.withIsSftpEnabled(true).withIsHnsEnabled(true)
.withRoutingPreference(new RoutingPreference().withRoutingChoice(RoutingChoice.MICROSOFT_ROUTING)
.withPublishMicrosoftEndpoints(true).withPublishInternetEndpoints(true))
.withAllowBlobPublicAccess(false).withMinimumTlsVersion(MinimumTlsVersion.TLS1_2)
.withAllowSharedKeyAccess(true).withDefaultToOAuthAuthentication(false)
.withGeoPriorityReplicationStatus(new GeoPriorityReplicationStatus().withIsBlobEnabled(true))
.withAllowSharedKeyAccessForServices(new StorageAccountSharedKeyAccessProperties()
.withBlob(new ServiceSharedKeyAccessProperties().withEnabled(true))
.withFile(new ServiceSharedKeyAccessProperties().withEnabled(false))
.withTable(new ServiceSharedKeyAccessProperties().withEnabled(false))
.withQueue(new ServiceSharedKeyAccessProperties().withEnabled(true)))
.withAllowCrossTenantDelegationSas(false),
com.azure.core.util.Context.NONE);
}
// Use "Map.of" if available
@SuppressWarnings("unchecked")
private static <T> Map<String, T> mapOf(Object... inputs) {
Map<String, T> map = new HashMap<>();
for (int i = 0; i < inputs.length; i += 2) {
String key = (String) inputs[i];
T value = (T) inputs[i + 1];
map.put(key, value);
}
return map;
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python storage_account_create.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.storage_accounts.begin_create(
resource_group_name="res9101",
account_name="sto4445",
parameters={
"extendedLocation": {"name": "losangeles001", "type": "EdgeZone"},
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": False,
"allowCrossTenantDelegationSas": False,
"allowSharedKeyAccess": True,
"allowSharedKeyAccessForServices": {
"blob": {"enabled": True},
"file": {"enabled": False},
"queue": {"enabled": True},
"table": {"enabled": False},
},
"defaultToOAuthAuthentication": False,
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": False,
"services": {
"blob": {"enabled": True, "keyType": "Account"},
"file": {"enabled": True, "keyType": "Account"},
},
},
"geoPriorityReplicationStatus": {"isBlobEnabled": True},
"isHnsEnabled": True,
"isSftpEnabled": True,
"keyPolicy": {"keyExpirationPeriodInDays": 20},
"minimumTlsVersion": "TLS1_2",
"routingPreference": {
"publishInternetEndpoints": True,
"publishMicrosoftEndpoints": True,
"routingChoice": "MicrosoftRouting",
},
"sasPolicy": {
"expirationAction": "Log",
"requireUserBoundUserDelegationSas": True,
"requireUserBoundUserDelegationSasAction": "Block",
"sasExpirationPeriod": "1.15:59:59",
},
},
"sku": {"name": "Standard_GRS"},
"tags": {"key1": "value1", "key2": "value2"},
},
).result()
print(response)
# x-ms-original-file: 2026-09-01/StorageAccountCreate.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage/v4"
)
// Generated from example definition: 2026-09-01/StorageAccountCreate.json
func ExampleAccountsClient_BeginCreate_storageAccountCreate() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("a3f7c2b9-4e1d-4c8a-9d6f-8b2a5e41c7f3", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewAccountsClient().BeginCreate(ctx, "res9101", "sto4445", armstorage.AccountCreateParameters{
ExtendedLocation: &armstorage.ExtendedLocation{
Name: to.Ptr("losangeles001"),
Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
},
Kind: to.Ptr(armstorage.KindStorage),
Location: to.Ptr("eastus"),
Properties: &armstorage.AccountPropertiesCreateParameters{
AllowBlobPublicAccess: to.Ptr(false),
AllowSharedKeyAccess: to.Ptr(true),
DefaultToOAuthAuthentication: to.Ptr(false),
Encryption: &armstorage.Encryption{
KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
RequireInfrastructureEncryption: to.Ptr(false),
Services: &armstorage.EncryptionServices{
Blob: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
File: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
},
},
IsHnsEnabled: to.Ptr(true),
IsSftpEnabled: to.Ptr(true),
KeyPolicy: &armstorage.KeyPolicy{
KeyExpirationPeriodInDays: to.Ptr[int32](20),
},
MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
RoutingPreference: &armstorage.RoutingPreference{
PublishInternetEndpoints: to.Ptr(true),
PublishMicrosoftEndpoints: to.Ptr(true),
RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
},
SasPolicy: &armstorage.SasPolicy{
ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
SasExpirationPeriod: to.Ptr("1.15:59:59"),
RequireUserBoundUserDelegationSas: to.Ptr(true),
RequireUserBoundUserDelegationSasAction: to.Ptr(armstorage.PolicyViolationActionBlock),
},
GeoPriorityReplicationStatus: &armstorage.GeoPriorityReplicationStatus{
IsBlobEnabled: to.Ptr(true),
},
AllowSharedKeyAccessForServices: &armstorage.AccountSharedKeyAccessProperties{
Blob: &armstorage.ServiceSharedKeyAccessProperties{
Enabled: to.Ptr(true),
},
File: &armstorage.ServiceSharedKeyAccessProperties{
Enabled: to.Ptr(false),
},
Queue: &armstorage.ServiceSharedKeyAccessProperties{
Enabled: to.Ptr(true),
},
Table: &armstorage.ServiceSharedKeyAccessProperties{
Enabled: to.Ptr(false),
},
},
AllowCrossTenantDelegationSas: to.Ptr(false),
},
SKU: &armstorage.SKU{
Name: to.Ptr(armstorage.SKUNameStandardGRS),
},
Tags: map[string]*string{
"key1": to.Ptr("value1"),
"key2": to.Ptr("value2"),
},
}, nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
log.Fatalf("failed to poll the result: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res = armstorage.AccountsClientCreateResponse{
// Account: armstorage.Account{
// Name: to.Ptr("sto4445"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts"),
// ExtendedLocation: &armstorage.ExtendedLocation{
// Name: to.Ptr("losangeles001"),
// Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
// },
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445"),
// Kind: to.Ptr(armstorage.KindStorage),
// Location: to.Ptr("eastus"),
// Properties: &armstorage.AccountProperties{
// AllowBlobPublicAccess: to.Ptr(false),
// AllowSharedKeyAccess: to.Ptr(true),
// CreationTime: to.Ptr(time.Date(2017, time.May, 24, 13, 25, 33, 486323600, time.UTC)),
// Encryption: &armstorage.Encryption{
// KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
// RequireInfrastructureEncryption: to.Ptr(false),
// Services: &armstorage.EncryptionServices{
// Blob: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// File: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// },
// },
// IsHnsEnabled: to.Ptr(true),
// IsSftpEnabled: to.Ptr(true),
// KeyCreationTime: &armstorage.KeyCreationTime{
// Key1: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// Key2: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// },
// KeyPolicy: &armstorage.KeyPolicy{
// KeyExpirationPeriodInDays: to.Ptr[int32](20),
// },
// MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
// PrimaryEndpoints: &armstorage.Endpoints{
// Blob: to.Ptr("https://sto4445.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445.file.core.windows.net/"),
// InternetEndpoints: &armstorage.AccountInternetEndpoints{
// Blob: to.Ptr("https://sto4445-internetrouting.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445-internetrouting.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445-internetrouting.file.core.windows.net/"),
// Web: to.Ptr("https://sto4445-internetrouting.web.core.windows.net/"),
// },
// MicrosoftEndpoints: &armstorage.AccountMicrosoftEndpoints{
// Blob: to.Ptr("https://sto4445-microsoftrouting.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445-microsoftrouting.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445-microsoftrouting.file.core.windows.net/"),
// Queue: to.Ptr("https://sto4445-microsoftrouting.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445-microsoftrouting.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445-microsoftrouting.web.core.windows.net/"),
// },
// Queue: to.Ptr("https://sto4445.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445.web.core.windows.net/"),
// },
// PrimaryLocation: to.Ptr("eastus2euap"),
// ProvisioningState: to.Ptr(armstorage.ProvisioningStateSucceeded),
// RoutingPreference: &armstorage.RoutingPreference{
// PublishInternetEndpoints: to.Ptr(true),
// PublishMicrosoftEndpoints: to.Ptr(true),
// RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
// },
// SasPolicy: &armstorage.SasPolicy{
// ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
// SasExpirationPeriod: to.Ptr("1.15:59:59"),
// RequireUserBoundUserDelegationSas: to.Ptr(true),
// RequireUserBoundUserDelegationSasAction: to.Ptr(armstorage.PolicyViolationActionBlock),
// },
// SecondaryLocation: to.Ptr("centraluseuap"),
// StatusOfPrimary: to.Ptr(armstorage.AccountStatusAvailable),
// StatusOfSecondary: to.Ptr(armstorage.AccountStatusAvailable),
// EnableHTTPSTrafficOnly: to.Ptr(true),
// GeoPriorityReplicationStatus: &armstorage.GeoPriorityReplicationStatus{
// IsBlobEnabled: to.Ptr(true),
// },
// AllowSharedKeyAccessForServices: &armstorage.AccountSharedKeyAccessProperties{
// Blob: &armstorage.ServiceSharedKeyAccessProperties{
// Enabled: to.Ptr(true),
// },
// File: &armstorage.ServiceSharedKeyAccessProperties{
// Enabled: to.Ptr(false),
// },
// Queue: &armstorage.ServiceSharedKeyAccessProperties{
// Enabled: to.Ptr(true),
// },
// Table: &armstorage.ServiceSharedKeyAccessProperties{
// Enabled: to.Ptr(false),
// },
// },
// AllowCrossTenantDelegationSas: to.Ptr(false),
// },
// SKU: &armstorage.SKU{
// Name: to.Ptr(armstorage.SKUNameStandardGRS),
// Tier: to.Ptr(armstorage.SKUTierStandard),
// },
// Tags: map[string]*string{
// "key1": to.Ptr("value1"),
// "key2": to.Ptr("value2"),
// },
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
*
* @summary asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
* x-ms-original-file: 2026-09-01/StorageAccountCreate.json
*/
async function storageAccountCreate() {
const credential = new DefaultAzureCredential();
const subscriptionId = "a3f7c2b9-4e1d-4c8a-9d6f-8b2a5e41c7f3";
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.storageAccounts.create("res9101", "sto4445", {
extendedLocation: { name: "losangeles001", type: "EdgeZone" },
kind: "Storage",
location: "eastus",
allowBlobPublicAccess: false,
allowSharedKeyAccess: true,
defaultToOAuthAuthentication: false,
encryption: {
keySource: "Microsoft.Storage",
requireInfrastructureEncryption: false,
services: {
blob: { enabled: true, keyType: "Account" },
file: { enabled: true, keyType: "Account" },
},
},
isHnsEnabled: true,
isSftpEnabled: true,
keyPolicy: { keyExpirationPeriodInDays: 20 },
minimumTlsVersion: "TLS1_2",
routingPreference: {
publishInternetEndpoints: true,
publishMicrosoftEndpoints: true,
routingChoice: "MicrosoftRouting",
},
sasPolicy: {
expirationAction: "Log",
sasExpirationPeriod: "1.15:59:59",
requireUserBoundUserDelegationSas: true,
requireUserBoundUserDelegationSasAction: "Block",
},
geoPriorityReplicationStatus: { isBlobEnabled: true },
allowSharedKeyAccessForServices: {
blob: { enabled: true },
file: { enabled: false },
queue: { enabled: true },
table: { enabled: false },
},
allowCrossTenantDelegationSas: false,
sku: { name: "Standard_GRS" },
tags: { key1: "value1", key2: "value2" },
});
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Voorbeeldrespons
{
"name": "sto4445",
"type": "Microsoft.Storage/storageAccounts",
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445",
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"creationTime": "2017-05-24T13:25:33.4863236Z",
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
},
"file": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
}
}
},
"isHnsEnabled": true,
"isSftpEnabled": true,
"keyCreationTime": {
"key1": "2021-03-18T04:42:22.4322836Z",
"key2": "2021-03-18T04:42:22.4322836Z"
},
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"primaryEndpoints": {
"blob": "https://sto4445.blob.core.windows.net/",
"dfs": "https://sto4445.dfs.core.windows.net/",
"file": "https://sto4445.file.core.windows.net/",
"internetEndpoints": {
"blob": "https://sto4445-internetrouting.blob.core.windows.net/",
"dfs": "https://sto4445-internetrouting.dfs.core.windows.net/",
"file": "https://sto4445-internetrouting.file.core.windows.net/",
"web": "https://sto4445-internetrouting.web.core.windows.net/"
},
"microsoftEndpoints": {
"blob": "https://sto4445-microsoftrouting.blob.core.windows.net/",
"dfs": "https://sto4445-microsoftrouting.dfs.core.windows.net/",
"file": "https://sto4445-microsoftrouting.file.core.windows.net/",
"queue": "https://sto4445-microsoftrouting.queue.core.windows.net/",
"table": "https://sto4445-microsoftrouting.table.core.windows.net/",
"web": "https://sto4445-microsoftrouting.web.core.windows.net/"
},
"queue": "https://sto4445.queue.core.windows.net/",
"table": "https://sto4445.table.core.windows.net/",
"web": "https://sto4445.web.core.windows.net/"
},
"primaryLocation": "eastus2euap",
"provisioningState": "Succeeded",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59",
"requireUserBoundUserDelegationSas": true,
"requireUserBoundUserDelegationSasAction": "Block"
},
"secondaryLocation": "centraluseuap",
"statusOfPrimary": "available",
"statusOfSecondary": "available",
"supportsHttpsTrafficOnly": true,
"geoPriorityReplicationStatus": {
"isBlobEnabled": true
},
"allowSharedKeyAccessForServices": {
"blob": {
"enabled": true
},
"file": {
"enabled": false
},
"queue": {
"enabled": true
},
"table": {
"enabled": false
}
},
"allowCrossTenantDelegationSas": false
},
"sku": {
"name": "Standard_GRS",
"tier": "Standard"
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
StorageAccountCreate_placement
Voorbeeldaanvraag
PUT https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445?api-version=2026-09-01
{
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"kind": "Storage",
"location": "eastus",
"placement": {
"zonePlacementPolicy": "Any"
},
"properties": {
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"defaultToOAuthAuthentication": false,
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account"
},
"file": {
"enabled": true,
"keyType": "Account"
}
}
},
"isHnsEnabled": true,
"isSftpEnabled": true,
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59"
}
},
"sku": {
"name": "Standard_GRS"
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
import com.azure.resourcemanager.storage.models.Encryption;
import com.azure.resourcemanager.storage.models.EncryptionService;
import com.azure.resourcemanager.storage.models.EncryptionServices;
import com.azure.resourcemanager.storage.models.ExpirationAction;
import com.azure.resourcemanager.storage.models.ExtendedLocation;
import com.azure.resourcemanager.storage.models.ExtendedLocationTypes;
import com.azure.resourcemanager.storage.models.KeyPolicy;
import com.azure.resourcemanager.storage.models.KeySource;
import com.azure.resourcemanager.storage.models.KeyType;
import com.azure.resourcemanager.storage.models.Kind;
import com.azure.resourcemanager.storage.models.MinimumTlsVersion;
import com.azure.resourcemanager.storage.models.Placement;
import com.azure.resourcemanager.storage.models.RoutingChoice;
import com.azure.resourcemanager.storage.models.RoutingPreference;
import com.azure.resourcemanager.storage.models.SasPolicy;
import com.azure.resourcemanager.storage.models.Sku;
import com.azure.resourcemanager.storage.models.SkuName;
import com.azure.resourcemanager.storage.models.StorageAccountCreateParameters;
import com.azure.resourcemanager.storage.models.ZonePlacementPolicy;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for StorageAccounts Create.
*/
public final class Main {
/*
* x-ms-original-file: 2026-09-01/StorageAccountCreate_placement.json
*/
/**
* Sample code: StorageAccountCreate_placement.
*
* @param manager Entry point to StorageManager.
*/
public static void storageAccountCreatePlacement(com.azure.resourcemanager.storage.StorageManager manager) {
manager.serviceClient().getStorageAccounts()
.create("res9101", "sto4445",
new StorageAccountCreateParameters().withSku(new Sku().withName(SkuName.STANDARD_GRS))
.withKind(Kind.STORAGE).withLocation("eastus")
.withExtendedLocation(
new ExtendedLocation().withName("losangeles001").withType(ExtendedLocationTypes.EDGE_ZONE))
.withPlacement(new Placement().withZonePlacementPolicy(ZonePlacementPolicy.ANY))
.withTags(
mapOf("key1", "fakeTokenPlaceholder", "key2", "fakeTokenPlaceholder"))
.withSasPolicy(
new SasPolicy().withSasExpirationPeriod(
"1.15:59:59").withExpirationAction(
ExpirationAction.LOG))
.withKeyPolicy(new KeyPolicy().withKeyExpirationPeriodInDays(20))
.withEncryption(new Encryption()
.withServices(new EncryptionServices()
.withBlob(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT))
.withFile(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT)))
.withKeySource(KeySource.MICROSOFT_STORAGE).withRequireInfrastructureEncryption(false))
.withIsSftpEnabled(true).withIsHnsEnabled(true)
.withRoutingPreference(new RoutingPreference().withRoutingChoice(RoutingChoice.MICROSOFT_ROUTING)
.withPublishMicrosoftEndpoints(true).withPublishInternetEndpoints(true))
.withAllowBlobPublicAccess(false).withMinimumTlsVersion(MinimumTlsVersion.TLS1_2)
.withAllowSharedKeyAccess(true).withDefaultToOAuthAuthentication(false),
com.azure.core.util.Context.NONE);
}
// Use "Map.of" if available
@SuppressWarnings("unchecked")
private static <T> Map<String, T> mapOf(Object... inputs) {
Map<String, T> map = new HashMap<>();
for (int i = 0; i < inputs.length; i += 2) {
String key = (String) inputs[i];
T value = (T) inputs[i + 1];
map.put(key, value);
}
return map;
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python storage_account_create_placement.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.storage_accounts.begin_create(
resource_group_name="res9101",
account_name="sto4445",
parameters={
"extendedLocation": {"name": "losangeles001", "type": "EdgeZone"},
"kind": "Storage",
"location": "eastus",
"placement": {"zonePlacementPolicy": "Any"},
"properties": {
"allowBlobPublicAccess": False,
"allowSharedKeyAccess": True,
"defaultToOAuthAuthentication": False,
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": False,
"services": {
"blob": {"enabled": True, "keyType": "Account"},
"file": {"enabled": True, "keyType": "Account"},
},
},
"isHnsEnabled": True,
"isSftpEnabled": True,
"keyPolicy": {"keyExpirationPeriodInDays": 20},
"minimumTlsVersion": "TLS1_2",
"routingPreference": {
"publishInternetEndpoints": True,
"publishMicrosoftEndpoints": True,
"routingChoice": "MicrosoftRouting",
},
"sasPolicy": {"expirationAction": "Log", "sasExpirationPeriod": "1.15:59:59"},
},
"sku": {"name": "Standard_GRS"},
"tags": {"key1": "value1", "key2": "value2"},
},
).result()
print(response)
# x-ms-original-file: 2026-09-01/StorageAccountCreate_placement.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage/v4"
)
// Generated from example definition: 2026-09-01/StorageAccountCreate_placement.json
func ExampleAccountsClient_BeginCreate_storageAccountCreatePlacement() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewAccountsClient().BeginCreate(ctx, "res9101", "sto4445", armstorage.AccountCreateParameters{
ExtendedLocation: &armstorage.ExtendedLocation{
Name: to.Ptr("losangeles001"),
Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
},
Kind: to.Ptr(armstorage.KindStorage),
Location: to.Ptr("eastus"),
Placement: &armstorage.Placement{
ZonePlacementPolicy: to.Ptr(armstorage.ZonePlacementPolicyAny),
},
Properties: &armstorage.AccountPropertiesCreateParameters{
AllowBlobPublicAccess: to.Ptr(false),
AllowSharedKeyAccess: to.Ptr(true),
DefaultToOAuthAuthentication: to.Ptr(false),
Encryption: &armstorage.Encryption{
KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
RequireInfrastructureEncryption: to.Ptr(false),
Services: &armstorage.EncryptionServices{
Blob: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
File: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
},
},
IsHnsEnabled: to.Ptr(true),
IsSftpEnabled: to.Ptr(true),
KeyPolicy: &armstorage.KeyPolicy{
KeyExpirationPeriodInDays: to.Ptr[int32](20),
},
MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
RoutingPreference: &armstorage.RoutingPreference{
PublishInternetEndpoints: to.Ptr(true),
PublishMicrosoftEndpoints: to.Ptr(true),
RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
},
SasPolicy: &armstorage.SasPolicy{
ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
SasExpirationPeriod: to.Ptr("1.15:59:59"),
},
},
SKU: &armstorage.SKU{
Name: to.Ptr(armstorage.SKUNameStandardGRS),
},
Tags: map[string]*string{
"key1": to.Ptr("value1"),
"key2": to.Ptr("value2"),
},
}, nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
log.Fatalf("failed to poll the result: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res = armstorage.AccountsClientCreateResponse{
// Account: armstorage.Account{
// Name: to.Ptr("sto4445"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts"),
// ExtendedLocation: &armstorage.ExtendedLocation{
// Name: to.Ptr("losangeles001"),
// Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
// },
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445"),
// Kind: to.Ptr(armstorage.KindStorage),
// Location: to.Ptr("eastus"),
// Placement: &armstorage.Placement{
// ZonePlacementPolicy: to.Ptr(armstorage.ZonePlacementPolicyAny),
// },
// Properties: &armstorage.AccountProperties{
// AllowBlobPublicAccess: to.Ptr(false),
// AllowSharedKeyAccess: to.Ptr(true),
// CreationTime: to.Ptr(time.Date(2017, time.May, 24, 13, 25, 33, 486323600, time.UTC)),
// Encryption: &armstorage.Encryption{
// KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
// RequireInfrastructureEncryption: to.Ptr(false),
// Services: &armstorage.EncryptionServices{
// Blob: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// File: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// },
// },
// IsHnsEnabled: to.Ptr(true),
// IsSftpEnabled: to.Ptr(true),
// KeyCreationTime: &armstorage.KeyCreationTime{
// Key1: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// Key2: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// },
// KeyPolicy: &armstorage.KeyPolicy{
// KeyExpirationPeriodInDays: to.Ptr[int32](20),
// },
// MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
// PrimaryEndpoints: &armstorage.Endpoints{
// Blob: to.Ptr("https://sto4445.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445.file.core.windows.net/"),
// InternetEndpoints: &armstorage.AccountInternetEndpoints{
// Blob: to.Ptr("https://sto4445-internetrouting.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445-internetrouting.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445-internetrouting.file.core.windows.net/"),
// Web: to.Ptr("https://sto4445-internetrouting.web.core.windows.net/"),
// },
// MicrosoftEndpoints: &armstorage.AccountMicrosoftEndpoints{
// Blob: to.Ptr("https://sto4445-microsoftrouting.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445-microsoftrouting.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445-microsoftrouting.file.core.windows.net/"),
// Queue: to.Ptr("https://sto4445-microsoftrouting.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445-microsoftrouting.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445-microsoftrouting.web.core.windows.net/"),
// },
// Queue: to.Ptr("https://sto4445.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445.web.core.windows.net/"),
// },
// PrimaryLocation: to.Ptr("eastus2euap"),
// ProvisioningState: to.Ptr(armstorage.ProvisioningStateSucceeded),
// RoutingPreference: &armstorage.RoutingPreference{
// PublishInternetEndpoints: to.Ptr(true),
// PublishMicrosoftEndpoints: to.Ptr(true),
// RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
// },
// SasPolicy: &armstorage.SasPolicy{
// ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
// SasExpirationPeriod: to.Ptr("1.15:59:59"),
// },
// SecondaryLocation: to.Ptr("centraluseuap"),
// StatusOfPrimary: to.Ptr(armstorage.AccountStatusAvailable),
// StatusOfSecondary: to.Ptr(armstorage.AccountStatusAvailable),
// EnableHTTPSTrafficOnly: to.Ptr(true),
// },
// SKU: &armstorage.SKU{
// Name: to.Ptr(armstorage.SKUNameStandardGRS),
// Tier: to.Ptr(armstorage.SKUTierStandard),
// },
// Tags: map[string]*string{
// "key1": to.Ptr("value1"),
// "key2": to.Ptr("value2"),
// },
// Zones: []*string{
// to.Ptr("1"),
// },
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
*
* @summary asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
* x-ms-original-file: 2026-09-01/StorageAccountCreate_placement.json
*/
async function storageAccountCreatePlacement() {
const credential = new DefaultAzureCredential();
const subscriptionId = "00000000-0000-0000-0000-000000000000";
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.storageAccounts.create("res9101", "sto4445", {
extendedLocation: { name: "losangeles001", type: "EdgeZone" },
kind: "Storage",
location: "eastus",
placement: { zonePlacementPolicy: "Any" },
allowBlobPublicAccess: false,
allowSharedKeyAccess: true,
defaultToOAuthAuthentication: false,
encryption: {
keySource: "Microsoft.Storage",
requireInfrastructureEncryption: false,
services: {
blob: { enabled: true, keyType: "Account" },
file: { enabled: true, keyType: "Account" },
},
},
isHnsEnabled: true,
isSftpEnabled: true,
keyPolicy: { keyExpirationPeriodInDays: 20 },
minimumTlsVersion: "TLS1_2",
routingPreference: {
publishInternetEndpoints: true,
publishMicrosoftEndpoints: true,
routingChoice: "MicrosoftRouting",
},
sasPolicy: { expirationAction: "Log", sasExpirationPeriod: "1.15:59:59" },
sku: { name: "Standard_GRS" },
tags: { key1: "value1", key2: "value2" },
});
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Voorbeeldrespons
{
"name": "sto4445",
"type": "Microsoft.Storage/storageAccounts",
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445",
"kind": "Storage",
"location": "eastus",
"placement": {
"zonePlacementPolicy": "Any"
},
"properties": {
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"creationTime": "2017-05-24T13:25:33.4863236Z",
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
},
"file": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
}
}
},
"isHnsEnabled": true,
"isSftpEnabled": true,
"keyCreationTime": {
"key1": "2021-03-18T04:42:22.4322836Z",
"key2": "2021-03-18T04:42:22.4322836Z"
},
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"primaryEndpoints": {
"blob": "https://sto4445.blob.core.windows.net/",
"dfs": "https://sto4445.dfs.core.windows.net/",
"file": "https://sto4445.file.core.windows.net/",
"internetEndpoints": {
"blob": "https://sto4445-internetrouting.blob.core.windows.net/",
"dfs": "https://sto4445-internetrouting.dfs.core.windows.net/",
"file": "https://sto4445-internetrouting.file.core.windows.net/",
"web": "https://sto4445-internetrouting.web.core.windows.net/"
},
"microsoftEndpoints": {
"blob": "https://sto4445-microsoftrouting.blob.core.windows.net/",
"dfs": "https://sto4445-microsoftrouting.dfs.core.windows.net/",
"file": "https://sto4445-microsoftrouting.file.core.windows.net/",
"queue": "https://sto4445-microsoftrouting.queue.core.windows.net/",
"table": "https://sto4445-microsoftrouting.table.core.windows.net/",
"web": "https://sto4445-microsoftrouting.web.core.windows.net/"
},
"queue": "https://sto4445.queue.core.windows.net/",
"table": "https://sto4445.table.core.windows.net/",
"web": "https://sto4445.web.core.windows.net/"
},
"primaryLocation": "eastus2euap",
"provisioningState": "Succeeded",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59"
},
"secondaryLocation": "centraluseuap",
"statusOfPrimary": "available",
"statusOfSecondary": "available",
"supportsHttpsTrafficOnly": true
},
"sku": {
"name": "Standard_GRS",
"tier": "Standard"
},
"tags": {
"key1": "value1",
"key2": "value2"
},
"zones": [
"1"
]
}
StorageAccountCreate_zones
Voorbeeldaanvraag
PUT https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445?api-version=2026-09-01
{
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"defaultToOAuthAuthentication": false,
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account"
},
"file": {
"enabled": true,
"keyType": "Account"
}
}
},
"isHnsEnabled": true,
"isSftpEnabled": true,
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59"
}
},
"sku": {
"name": "Standard_GRS"
},
"tags": {
"key1": "value1",
"key2": "value2"
},
"zones": [
"1"
]
}
import com.azure.resourcemanager.storage.models.Encryption;
import com.azure.resourcemanager.storage.models.EncryptionService;
import com.azure.resourcemanager.storage.models.EncryptionServices;
import com.azure.resourcemanager.storage.models.ExpirationAction;
import com.azure.resourcemanager.storage.models.ExtendedLocation;
import com.azure.resourcemanager.storage.models.ExtendedLocationTypes;
import com.azure.resourcemanager.storage.models.KeyPolicy;
import com.azure.resourcemanager.storage.models.KeySource;
import com.azure.resourcemanager.storage.models.KeyType;
import com.azure.resourcemanager.storage.models.Kind;
import com.azure.resourcemanager.storage.models.MinimumTlsVersion;
import com.azure.resourcemanager.storage.models.RoutingChoice;
import com.azure.resourcemanager.storage.models.RoutingPreference;
import com.azure.resourcemanager.storage.models.SasPolicy;
import com.azure.resourcemanager.storage.models.Sku;
import com.azure.resourcemanager.storage.models.SkuName;
import com.azure.resourcemanager.storage.models.StorageAccountCreateParameters;
import java.util.Arrays;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for StorageAccounts Create.
*/
public final class Main {
/*
* x-ms-original-file: 2026-09-01/StorageAccountCreate_zones.json
*/
/**
* Sample code: StorageAccountCreate_zones.
*
* @param manager Entry point to StorageManager.
*/
public static void storageAccountCreateZones(com.azure.resourcemanager.storage.StorageManager manager) {
manager.serviceClient().getStorageAccounts()
.create("res9101", "sto4445",
new StorageAccountCreateParameters().withSku(new Sku().withName(SkuName.STANDARD_GRS))
.withKind(Kind.STORAGE).withLocation("eastus")
.withExtendedLocation(
new ExtendedLocation().withName("losangeles001").withType(ExtendedLocationTypes.EDGE_ZONE))
.withZones(Arrays.asList("1"))
.withTags(
mapOf("key1", "fakeTokenPlaceholder", "key2", "fakeTokenPlaceholder"))
.withSasPolicy(
new SasPolicy().withSasExpirationPeriod(
"1.15:59:59").withExpirationAction(
ExpirationAction.LOG))
.withKeyPolicy(new KeyPolicy().withKeyExpirationPeriodInDays(20))
.withEncryption(new Encryption()
.withServices(new EncryptionServices()
.withBlob(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT))
.withFile(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT)))
.withKeySource(KeySource.MICROSOFT_STORAGE).withRequireInfrastructureEncryption(false))
.withIsSftpEnabled(true).withIsHnsEnabled(true)
.withRoutingPreference(new RoutingPreference().withRoutingChoice(RoutingChoice.MICROSOFT_ROUTING)
.withPublishMicrosoftEndpoints(true).withPublishInternetEndpoints(true))
.withAllowBlobPublicAccess(false).withMinimumTlsVersion(MinimumTlsVersion.TLS1_2)
.withAllowSharedKeyAccess(true).withDefaultToOAuthAuthentication(false),
com.azure.core.util.Context.NONE);
}
// Use "Map.of" if available
@SuppressWarnings("unchecked")
private static <T> Map<String, T> mapOf(Object... inputs) {
Map<String, T> map = new HashMap<>();
for (int i = 0; i < inputs.length; i += 2) {
String key = (String) inputs[i];
T value = (T) inputs[i + 1];
map.put(key, value);
}
return map;
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python storage_account_create_zones.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.storage_accounts.begin_create(
resource_group_name="res9101",
account_name="sto4445",
parameters={
"extendedLocation": {"name": "losangeles001", "type": "EdgeZone"},
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": False,
"allowSharedKeyAccess": True,
"defaultToOAuthAuthentication": False,
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": False,
"services": {
"blob": {"enabled": True, "keyType": "Account"},
"file": {"enabled": True, "keyType": "Account"},
},
},
"isHnsEnabled": True,
"isSftpEnabled": True,
"keyPolicy": {"keyExpirationPeriodInDays": 20},
"minimumTlsVersion": "TLS1_2",
"routingPreference": {
"publishInternetEndpoints": True,
"publishMicrosoftEndpoints": True,
"routingChoice": "MicrosoftRouting",
},
"sasPolicy": {"expirationAction": "Log", "sasExpirationPeriod": "1.15:59:59"},
},
"sku": {"name": "Standard_GRS"},
"tags": {"key1": "value1", "key2": "value2"},
"zones": ["1"],
},
).result()
print(response)
# x-ms-original-file: 2026-09-01/StorageAccountCreate_zones.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage/v4"
)
// Generated from example definition: 2026-09-01/StorageAccountCreate_zones.json
func ExampleAccountsClient_BeginCreate_storageAccountCreateZones() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewAccountsClient().BeginCreate(ctx, "res9101", "sto4445", armstorage.AccountCreateParameters{
ExtendedLocation: &armstorage.ExtendedLocation{
Name: to.Ptr("losangeles001"),
Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
},
Kind: to.Ptr(armstorage.KindStorage),
Location: to.Ptr("eastus"),
Properties: &armstorage.AccountPropertiesCreateParameters{
AllowBlobPublicAccess: to.Ptr(false),
AllowSharedKeyAccess: to.Ptr(true),
DefaultToOAuthAuthentication: to.Ptr(false),
Encryption: &armstorage.Encryption{
KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
RequireInfrastructureEncryption: to.Ptr(false),
Services: &armstorage.EncryptionServices{
Blob: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
File: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
},
},
IsHnsEnabled: to.Ptr(true),
IsSftpEnabled: to.Ptr(true),
KeyPolicy: &armstorage.KeyPolicy{
KeyExpirationPeriodInDays: to.Ptr[int32](20),
},
MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
RoutingPreference: &armstorage.RoutingPreference{
PublishInternetEndpoints: to.Ptr(true),
PublishMicrosoftEndpoints: to.Ptr(true),
RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
},
SasPolicy: &armstorage.SasPolicy{
ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
SasExpirationPeriod: to.Ptr("1.15:59:59"),
},
},
SKU: &armstorage.SKU{
Name: to.Ptr(armstorage.SKUNameStandardGRS),
},
Tags: map[string]*string{
"key1": to.Ptr("value1"),
"key2": to.Ptr("value2"),
},
Zones: []*string{
to.Ptr("1"),
},
}, nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
log.Fatalf("failed to poll the result: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res = armstorage.AccountsClientCreateResponse{
// Account: armstorage.Account{
// Name: to.Ptr("sto4445"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts"),
// ExtendedLocation: &armstorage.ExtendedLocation{
// Name: to.Ptr("losangeles001"),
// Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
// },
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445"),
// Kind: to.Ptr(armstorage.KindStorage),
// Location: to.Ptr("eastus"),
// Properties: &armstorage.AccountProperties{
// AllowBlobPublicAccess: to.Ptr(false),
// AllowSharedKeyAccess: to.Ptr(true),
// CreationTime: to.Ptr(time.Date(2017, time.May, 24, 13, 25, 33, 486323600, time.UTC)),
// Encryption: &armstorage.Encryption{
// KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
// RequireInfrastructureEncryption: to.Ptr(false),
// Services: &armstorage.EncryptionServices{
// Blob: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// File: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// },
// },
// IsHnsEnabled: to.Ptr(true),
// IsSftpEnabled: to.Ptr(true),
// KeyCreationTime: &armstorage.KeyCreationTime{
// Key1: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// Key2: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// },
// KeyPolicy: &armstorage.KeyPolicy{
// KeyExpirationPeriodInDays: to.Ptr[int32](20),
// },
// MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
// PrimaryEndpoints: &armstorage.Endpoints{
// Blob: to.Ptr("https://sto4445.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445.file.core.windows.net/"),
// InternetEndpoints: &armstorage.AccountInternetEndpoints{
// Blob: to.Ptr("https://sto4445-internetrouting.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445-internetrouting.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445-internetrouting.file.core.windows.net/"),
// Web: to.Ptr("https://sto4445-internetrouting.web.core.windows.net/"),
// },
// MicrosoftEndpoints: &armstorage.AccountMicrosoftEndpoints{
// Blob: to.Ptr("https://sto4445-microsoftrouting.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445-microsoftrouting.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445-microsoftrouting.file.core.windows.net/"),
// Queue: to.Ptr("https://sto4445-microsoftrouting.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445-microsoftrouting.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445-microsoftrouting.web.core.windows.net/"),
// },
// Queue: to.Ptr("https://sto4445.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445.web.core.windows.net/"),
// },
// PrimaryLocation: to.Ptr("eastus2euap"),
// ProvisioningState: to.Ptr(armstorage.ProvisioningStateSucceeded),
// RoutingPreference: &armstorage.RoutingPreference{
// PublishInternetEndpoints: to.Ptr(true),
// PublishMicrosoftEndpoints: to.Ptr(true),
// RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
// },
// SasPolicy: &armstorage.SasPolicy{
// ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
// SasExpirationPeriod: to.Ptr("1.15:59:59"),
// },
// SecondaryLocation: to.Ptr("centraluseuap"),
// StatusOfPrimary: to.Ptr(armstorage.AccountStatusAvailable),
// StatusOfSecondary: to.Ptr(armstorage.AccountStatusAvailable),
// EnableHTTPSTrafficOnly: to.Ptr(true),
// },
// SKU: &armstorage.SKU{
// Name: to.Ptr(armstorage.SKUNameStandardGRS),
// Tier: to.Ptr(armstorage.SKUTierStandard),
// },
// Tags: map[string]*string{
// "key1": to.Ptr("value1"),
// "key2": to.Ptr("value2"),
// },
// Zones: []*string{
// to.Ptr("1"),
// },
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
*
* @summary asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
* x-ms-original-file: 2026-09-01/StorageAccountCreate_zones.json
*/
async function storageAccountCreateZones() {
const credential = new DefaultAzureCredential();
const subscriptionId = "00000000-0000-0000-0000-000000000000";
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.storageAccounts.create("res9101", "sto4445", {
extendedLocation: { name: "losangeles001", type: "EdgeZone" },
kind: "Storage",
location: "eastus",
allowBlobPublicAccess: false,
allowSharedKeyAccess: true,
defaultToOAuthAuthentication: false,
encryption: {
keySource: "Microsoft.Storage",
requireInfrastructureEncryption: false,
services: {
blob: { enabled: true, keyType: "Account" },
file: { enabled: true, keyType: "Account" },
},
},
isHnsEnabled: true,
isSftpEnabled: true,
keyPolicy: { keyExpirationPeriodInDays: 20 },
minimumTlsVersion: "TLS1_2",
routingPreference: {
publishInternetEndpoints: true,
publishMicrosoftEndpoints: true,
routingChoice: "MicrosoftRouting",
},
sasPolicy: { expirationAction: "Log", sasExpirationPeriod: "1.15:59:59" },
sku: { name: "Standard_GRS" },
tags: { key1: "value1", key2: "value2" },
zones: ["1"],
});
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Voorbeeldrespons
{
"name": "sto4445",
"type": "Microsoft.Storage/storageAccounts",
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445",
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"creationTime": "2017-05-24T13:25:33.4863236Z",
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
},
"file": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
}
}
},
"isHnsEnabled": true,
"isSftpEnabled": true,
"keyCreationTime": {
"key1": "2021-03-18T04:42:22.4322836Z",
"key2": "2021-03-18T04:42:22.4322836Z"
},
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"primaryEndpoints": {
"blob": "https://sto4445.blob.core.windows.net/",
"dfs": "https://sto4445.dfs.core.windows.net/",
"file": "https://sto4445.file.core.windows.net/",
"internetEndpoints": {
"blob": "https://sto4445-internetrouting.blob.core.windows.net/",
"dfs": "https://sto4445-internetrouting.dfs.core.windows.net/",
"file": "https://sto4445-internetrouting.file.core.windows.net/",
"web": "https://sto4445-internetrouting.web.core.windows.net/"
},
"microsoftEndpoints": {
"blob": "https://sto4445-microsoftrouting.blob.core.windows.net/",
"dfs": "https://sto4445-microsoftrouting.dfs.core.windows.net/",
"file": "https://sto4445-microsoftrouting.file.core.windows.net/",
"queue": "https://sto4445-microsoftrouting.queue.core.windows.net/",
"table": "https://sto4445-microsoftrouting.table.core.windows.net/",
"web": "https://sto4445-microsoftrouting.web.core.windows.net/"
},
"queue": "https://sto4445.queue.core.windows.net/",
"table": "https://sto4445.table.core.windows.net/",
"web": "https://sto4445.web.core.windows.net/"
},
"primaryLocation": "eastus2euap",
"provisioningState": "Succeeded",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59"
},
"secondaryLocation": "centraluseuap",
"statusOfPrimary": "available",
"statusOfSecondary": "available",
"supportsHttpsTrafficOnly": true
},
"sku": {
"name": "Standard_GRS",
"tier": "Standard"
},
"tags": {
"key1": "value1",
"key2": "value2"
},
"zones": [
"1"
]
}
StorageAccountCreateAllowedCopyScopeToAAD
Voorbeeldaanvraag
PUT https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445?api-version=2026-09-01
{
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"allowedCopyScope": "AAD",
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account"
},
"file": {
"enabled": true,
"keyType": "Account"
}
}
},
"isHnsEnabled": true,
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59"
}
},
"sku": {
"name": "Standard_GRS"
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
import com.azure.resourcemanager.storage.models.AllowedCopyScope;
import com.azure.resourcemanager.storage.models.Encryption;
import com.azure.resourcemanager.storage.models.EncryptionService;
import com.azure.resourcemanager.storage.models.EncryptionServices;
import com.azure.resourcemanager.storage.models.ExpirationAction;
import com.azure.resourcemanager.storage.models.KeyPolicy;
import com.azure.resourcemanager.storage.models.KeySource;
import com.azure.resourcemanager.storage.models.KeyType;
import com.azure.resourcemanager.storage.models.Kind;
import com.azure.resourcemanager.storage.models.MinimumTlsVersion;
import com.azure.resourcemanager.storage.models.RoutingChoice;
import com.azure.resourcemanager.storage.models.RoutingPreference;
import com.azure.resourcemanager.storage.models.SasPolicy;
import com.azure.resourcemanager.storage.models.Sku;
import com.azure.resourcemanager.storage.models.SkuName;
import com.azure.resourcemanager.storage.models.StorageAccountCreateParameters;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for StorageAccounts Create.
*/
public final class Main {
/*
* x-ms-original-file: 2026-09-01/StorageAccountCreateAllowedCopyScopeToAAD.json
*/
/**
* Sample code: StorageAccountCreateAllowedCopyScopeToAAD.
*
* @param manager Entry point to StorageManager.
*/
public static void
storageAccountCreateAllowedCopyScopeToAAD(com.azure.resourcemanager.storage.StorageManager manager) {
manager.serviceClient().getStorageAccounts()
.create("res9101", "sto4445",
new StorageAccountCreateParameters().withSku(new Sku().withName(SkuName.STANDARD_GRS))
.withKind(Kind.STORAGE).withLocation("eastus")
.withTags(mapOf("key1", "fakeTokenPlaceholder", "key2", "fakeTokenPlaceholder"))
.withAllowedCopyScope(
AllowedCopyScope.AAD)
.withSasPolicy(
new SasPolicy().withSasExpirationPeriod(
"1.15:59:59").withExpirationAction(
ExpirationAction.LOG))
.withKeyPolicy(new KeyPolicy().withKeyExpirationPeriodInDays(20))
.withEncryption(new Encryption()
.withServices(new EncryptionServices()
.withBlob(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT))
.withFile(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT)))
.withKeySource(KeySource.MICROSOFT_STORAGE).withRequireInfrastructureEncryption(false))
.withIsHnsEnabled(true)
.withRoutingPreference(new RoutingPreference().withRoutingChoice(RoutingChoice.MICROSOFT_ROUTING)
.withPublishMicrosoftEndpoints(true).withPublishInternetEndpoints(true))
.withAllowBlobPublicAccess(false).withMinimumTlsVersion(MinimumTlsVersion.TLS1_2)
.withAllowSharedKeyAccess(true),
com.azure.core.util.Context.NONE);
}
// Use "Map.of" if available
@SuppressWarnings("unchecked")
private static <T> Map<String, T> mapOf(Object... inputs) {
Map<String, T> map = new HashMap<>();
for (int i = 0; i < inputs.length; i += 2) {
String key = (String) inputs[i];
T value = (T) inputs[i + 1];
map.put(key, value);
}
return map;
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python storage_account_create_allowed_copy_scope_to_aad.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.storage_accounts.begin_create(
resource_group_name="res9101",
account_name="sto4445",
parameters={
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": False,
"allowSharedKeyAccess": True,
"allowedCopyScope": "AAD",
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": False,
"services": {
"blob": {"enabled": True, "keyType": "Account"},
"file": {"enabled": True, "keyType": "Account"},
},
},
"isHnsEnabled": True,
"keyPolicy": {"keyExpirationPeriodInDays": 20},
"minimumTlsVersion": "TLS1_2",
"routingPreference": {
"publishInternetEndpoints": True,
"publishMicrosoftEndpoints": True,
"routingChoice": "MicrosoftRouting",
},
"sasPolicy": {"expirationAction": "Log", "sasExpirationPeriod": "1.15:59:59"},
},
"sku": {"name": "Standard_GRS"},
"tags": {"key1": "value1", "key2": "value2"},
},
).result()
print(response)
# x-ms-original-file: 2026-09-01/StorageAccountCreateAllowedCopyScopeToAAD.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage/v4"
)
// Generated from example definition: 2026-09-01/StorageAccountCreateAllowedCopyScopeToAAD.json
func ExampleAccountsClient_BeginCreate_storageAccountCreateAllowedCopyScopeToAad() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewAccountsClient().BeginCreate(ctx, "res9101", "sto4445", armstorage.AccountCreateParameters{
Kind: to.Ptr(armstorage.KindStorage),
Location: to.Ptr("eastus"),
Properties: &armstorage.AccountPropertiesCreateParameters{
AllowBlobPublicAccess: to.Ptr(false),
AllowSharedKeyAccess: to.Ptr(true),
AllowedCopyScope: to.Ptr(armstorage.AllowedCopyScopeAAD),
Encryption: &armstorage.Encryption{
KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
RequireInfrastructureEncryption: to.Ptr(false),
Services: &armstorage.EncryptionServices{
Blob: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
File: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
},
},
IsHnsEnabled: to.Ptr(true),
KeyPolicy: &armstorage.KeyPolicy{
KeyExpirationPeriodInDays: to.Ptr[int32](20),
},
MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
RoutingPreference: &armstorage.RoutingPreference{
PublishInternetEndpoints: to.Ptr(true),
PublishMicrosoftEndpoints: to.Ptr(true),
RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
},
SasPolicy: &armstorage.SasPolicy{
ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
SasExpirationPeriod: to.Ptr("1.15:59:59"),
},
},
SKU: &armstorage.SKU{
Name: to.Ptr(armstorage.SKUNameStandardGRS),
},
Tags: map[string]*string{
"key1": to.Ptr("value1"),
"key2": to.Ptr("value2"),
},
}, nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
log.Fatalf("failed to poll the result: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res = armstorage.AccountsClientCreateResponse{
// Account: armstorage.Account{
// Name: to.Ptr("sto4445"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts"),
// ExtendedLocation: &armstorage.ExtendedLocation{
// Name: to.Ptr("losangeles001"),
// Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
// },
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445"),
// Kind: to.Ptr(armstorage.KindStorage),
// Location: to.Ptr("eastus"),
// Properties: &armstorage.AccountProperties{
// AllowBlobPublicAccess: to.Ptr(false),
// AllowSharedKeyAccess: to.Ptr(true),
// AllowedCopyScope: to.Ptr(armstorage.AllowedCopyScopeAAD),
// CreationTime: to.Ptr(time.Date(2017, time.May, 24, 13, 25, 33, 486323600, time.UTC)),
// Encryption: &armstorage.Encryption{
// KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
// RequireInfrastructureEncryption: to.Ptr(false),
// Services: &armstorage.EncryptionServices{
// Blob: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// File: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// },
// },
// IsHnsEnabled: to.Ptr(true),
// KeyCreationTime: &armstorage.KeyCreationTime{
// Key1: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// Key2: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// },
// KeyPolicy: &armstorage.KeyPolicy{
// KeyExpirationPeriodInDays: to.Ptr[int32](20),
// },
// MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
// PrimaryEndpoints: &armstorage.Endpoints{
// Blob: to.Ptr("https://sto4445.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445.file.core.windows.net/"),
// InternetEndpoints: &armstorage.AccountInternetEndpoints{
// Blob: to.Ptr("https://sto4445-internetrouting.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445-internetrouting.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445-internetrouting.file.core.windows.net/"),
// Web: to.Ptr("https://sto4445-internetrouting.web.core.windows.net/"),
// },
// MicrosoftEndpoints: &armstorage.AccountMicrosoftEndpoints{
// Blob: to.Ptr("https://sto4445-microsoftrouting.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445-microsoftrouting.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445-microsoftrouting.file.core.windows.net/"),
// Queue: to.Ptr("https://sto4445-microsoftrouting.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445-microsoftrouting.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445-microsoftrouting.web.core.windows.net/"),
// },
// Queue: to.Ptr("https://sto4445.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445.web.core.windows.net/"),
// },
// PrimaryLocation: to.Ptr("eastus2euap"),
// ProvisioningState: to.Ptr(armstorage.ProvisioningStateSucceeded),
// RoutingPreference: &armstorage.RoutingPreference{
// PublishInternetEndpoints: to.Ptr(true),
// PublishMicrosoftEndpoints: to.Ptr(true),
// RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
// },
// SasPolicy: &armstorage.SasPolicy{
// ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
// SasExpirationPeriod: to.Ptr("1.15:59:59"),
// },
// SecondaryLocation: to.Ptr("centraluseuap"),
// StatusOfPrimary: to.Ptr(armstorage.AccountStatusAvailable),
// StatusOfSecondary: to.Ptr(armstorage.AccountStatusAvailable),
// EnableHTTPSTrafficOnly: to.Ptr(true),
// },
// SKU: &armstorage.SKU{
// Name: to.Ptr(armstorage.SKUNameStandardGRS),
// Tier: to.Ptr(armstorage.SKUTierStandard),
// },
// Tags: map[string]*string{
// "key1": to.Ptr("value1"),
// "key2": to.Ptr("value2"),
// },
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
*
* @summary asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
* x-ms-original-file: 2026-09-01/StorageAccountCreateAllowedCopyScopeToAAD.json
*/
async function storageAccountCreateAllowedCopyScopeToAAD() {
const credential = new DefaultAzureCredential();
const subscriptionId = "00000000-0000-0000-0000-000000000000";
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.storageAccounts.create("res9101", "sto4445", {
kind: "Storage",
location: "eastus",
allowBlobPublicAccess: false,
allowSharedKeyAccess: true,
allowedCopyScope: "AAD",
encryption: {
keySource: "Microsoft.Storage",
requireInfrastructureEncryption: false,
services: {
blob: { enabled: true, keyType: "Account" },
file: { enabled: true, keyType: "Account" },
},
},
isHnsEnabled: true,
keyPolicy: { keyExpirationPeriodInDays: 20 },
minimumTlsVersion: "TLS1_2",
routingPreference: {
publishInternetEndpoints: true,
publishMicrosoftEndpoints: true,
routingChoice: "MicrosoftRouting",
},
sasPolicy: { expirationAction: "Log", sasExpirationPeriod: "1.15:59:59" },
sku: { name: "Standard_GRS" },
tags: { key1: "value1", key2: "value2" },
});
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Voorbeeldrespons
{
"name": "sto4445",
"type": "Microsoft.Storage/storageAccounts",
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445",
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"allowedCopyScope": "AAD",
"creationTime": "2017-05-24T13:25:33.4863236Z",
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
},
"file": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
}
}
},
"isHnsEnabled": true,
"keyCreationTime": {
"key1": "2021-03-18T04:42:22.4322836Z",
"key2": "2021-03-18T04:42:22.4322836Z"
},
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"primaryEndpoints": {
"blob": "https://sto4445.blob.core.windows.net/",
"dfs": "https://sto4445.dfs.core.windows.net/",
"file": "https://sto4445.file.core.windows.net/",
"internetEndpoints": {
"blob": "https://sto4445-internetrouting.blob.core.windows.net/",
"dfs": "https://sto4445-internetrouting.dfs.core.windows.net/",
"file": "https://sto4445-internetrouting.file.core.windows.net/",
"web": "https://sto4445-internetrouting.web.core.windows.net/"
},
"microsoftEndpoints": {
"blob": "https://sto4445-microsoftrouting.blob.core.windows.net/",
"dfs": "https://sto4445-microsoftrouting.dfs.core.windows.net/",
"file": "https://sto4445-microsoftrouting.file.core.windows.net/",
"queue": "https://sto4445-microsoftrouting.queue.core.windows.net/",
"table": "https://sto4445-microsoftrouting.table.core.windows.net/",
"web": "https://sto4445-microsoftrouting.web.core.windows.net/"
},
"queue": "https://sto4445.queue.core.windows.net/",
"table": "https://sto4445.table.core.windows.net/",
"web": "https://sto4445.web.core.windows.net/"
},
"primaryLocation": "eastus2euap",
"provisioningState": "Succeeded",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59"
},
"secondaryLocation": "centraluseuap",
"statusOfPrimary": "available",
"statusOfSecondary": "available",
"supportsHttpsTrafficOnly": true
},
"sku": {
"name": "Standard_GRS",
"tier": "Standard"
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
StorageAccountCreateAllowedCopyScopeToPrivateLink
Voorbeeldaanvraag
PUT https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445?api-version=2026-09-01
{
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"allowedCopyScope": "PrivateLink",
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account"
},
"file": {
"enabled": true,
"keyType": "Account"
}
}
},
"isHnsEnabled": true,
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59"
}
},
"sku": {
"name": "Standard_GRS"
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
import com.azure.resourcemanager.storage.models.AllowedCopyScope;
import com.azure.resourcemanager.storage.models.Encryption;
import com.azure.resourcemanager.storage.models.EncryptionService;
import com.azure.resourcemanager.storage.models.EncryptionServices;
import com.azure.resourcemanager.storage.models.ExpirationAction;
import com.azure.resourcemanager.storage.models.KeyPolicy;
import com.azure.resourcemanager.storage.models.KeySource;
import com.azure.resourcemanager.storage.models.KeyType;
import com.azure.resourcemanager.storage.models.Kind;
import com.azure.resourcemanager.storage.models.MinimumTlsVersion;
import com.azure.resourcemanager.storage.models.RoutingChoice;
import com.azure.resourcemanager.storage.models.RoutingPreference;
import com.azure.resourcemanager.storage.models.SasPolicy;
import com.azure.resourcemanager.storage.models.Sku;
import com.azure.resourcemanager.storage.models.SkuName;
import com.azure.resourcemanager.storage.models.StorageAccountCreateParameters;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for StorageAccounts Create.
*/
public final class Main {
/*
* x-ms-original-file: 2026-09-01/StorageAccountCreateAllowedCopyScopeToPrivateLink.json
*/
/**
* Sample code: StorageAccountCreateAllowedCopyScopeToPrivateLink.
*
* @param manager Entry point to StorageManager.
*/
public static void
storageAccountCreateAllowedCopyScopeToPrivateLink(com.azure.resourcemanager.storage.StorageManager manager) {
manager.serviceClient().getStorageAccounts()
.create("res9101", "sto4445",
new StorageAccountCreateParameters().withSku(new Sku().withName(SkuName.STANDARD_GRS))
.withKind(Kind.STORAGE).withLocation("eastus")
.withTags(mapOf("key1", "fakeTokenPlaceholder", "key2", "fakeTokenPlaceholder"))
.withAllowedCopyScope(
AllowedCopyScope.PRIVATE_LINK)
.withSasPolicy(
new SasPolicy().withSasExpirationPeriod(
"1.15:59:59").withExpirationAction(
ExpirationAction.LOG))
.withKeyPolicy(new KeyPolicy().withKeyExpirationPeriodInDays(20))
.withEncryption(new Encryption()
.withServices(new EncryptionServices()
.withBlob(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT))
.withFile(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT)))
.withKeySource(KeySource.MICROSOFT_STORAGE).withRequireInfrastructureEncryption(false))
.withIsHnsEnabled(true)
.withRoutingPreference(new RoutingPreference().withRoutingChoice(RoutingChoice.MICROSOFT_ROUTING)
.withPublishMicrosoftEndpoints(true).withPublishInternetEndpoints(true))
.withAllowBlobPublicAccess(false).withMinimumTlsVersion(MinimumTlsVersion.TLS1_2)
.withAllowSharedKeyAccess(true),
com.azure.core.util.Context.NONE);
}
// Use "Map.of" if available
@SuppressWarnings("unchecked")
private static <T> Map<String, T> mapOf(Object... inputs) {
Map<String, T> map = new HashMap<>();
for (int i = 0; i < inputs.length; i += 2) {
String key = (String) inputs[i];
T value = (T) inputs[i + 1];
map.put(key, value);
}
return map;
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python storage_account_create_allowed_copy_scope_to_private_link.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.storage_accounts.begin_create(
resource_group_name="res9101",
account_name="sto4445",
parameters={
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": False,
"allowSharedKeyAccess": True,
"allowedCopyScope": "PrivateLink",
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": False,
"services": {
"blob": {"enabled": True, "keyType": "Account"},
"file": {"enabled": True, "keyType": "Account"},
},
},
"isHnsEnabled": True,
"keyPolicy": {"keyExpirationPeriodInDays": 20},
"minimumTlsVersion": "TLS1_2",
"routingPreference": {
"publishInternetEndpoints": True,
"publishMicrosoftEndpoints": True,
"routingChoice": "MicrosoftRouting",
},
"sasPolicy": {"expirationAction": "Log", "sasExpirationPeriod": "1.15:59:59"},
},
"sku": {"name": "Standard_GRS"},
"tags": {"key1": "value1", "key2": "value2"},
},
).result()
print(response)
# x-ms-original-file: 2026-09-01/StorageAccountCreateAllowedCopyScopeToPrivateLink.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage/v4"
)
// Generated from example definition: 2026-09-01/StorageAccountCreateAllowedCopyScopeToPrivateLink.json
func ExampleAccountsClient_BeginCreate_storageAccountCreateAllowedCopyScopeToPrivateLink() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewAccountsClient().BeginCreate(ctx, "res9101", "sto4445", armstorage.AccountCreateParameters{
Kind: to.Ptr(armstorage.KindStorage),
Location: to.Ptr("eastus"),
Properties: &armstorage.AccountPropertiesCreateParameters{
AllowBlobPublicAccess: to.Ptr(false),
AllowSharedKeyAccess: to.Ptr(true),
AllowedCopyScope: to.Ptr(armstorage.AllowedCopyScopePrivateLink),
Encryption: &armstorage.Encryption{
KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
RequireInfrastructureEncryption: to.Ptr(false),
Services: &armstorage.EncryptionServices{
Blob: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
File: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
},
},
IsHnsEnabled: to.Ptr(true),
KeyPolicy: &armstorage.KeyPolicy{
KeyExpirationPeriodInDays: to.Ptr[int32](20),
},
MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
RoutingPreference: &armstorage.RoutingPreference{
PublishInternetEndpoints: to.Ptr(true),
PublishMicrosoftEndpoints: to.Ptr(true),
RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
},
SasPolicy: &armstorage.SasPolicy{
ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
SasExpirationPeriod: to.Ptr("1.15:59:59"),
},
},
SKU: &armstorage.SKU{
Name: to.Ptr(armstorage.SKUNameStandardGRS),
},
Tags: map[string]*string{
"key1": to.Ptr("value1"),
"key2": to.Ptr("value2"),
},
}, nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
log.Fatalf("failed to poll the result: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res = armstorage.AccountsClientCreateResponse{
// Account: armstorage.Account{
// Name: to.Ptr("sto4445"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts"),
// ExtendedLocation: &armstorage.ExtendedLocation{
// Name: to.Ptr("losangeles001"),
// Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
// },
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445"),
// Kind: to.Ptr(armstorage.KindStorage),
// Location: to.Ptr("eastus"),
// Properties: &armstorage.AccountProperties{
// AllowBlobPublicAccess: to.Ptr(false),
// AllowSharedKeyAccess: to.Ptr(true),
// AllowedCopyScope: to.Ptr(armstorage.AllowedCopyScopePrivateLink),
// CreationTime: to.Ptr(time.Date(2017, time.May, 24, 13, 25, 33, 486323600, time.UTC)),
// Encryption: &armstorage.Encryption{
// KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
// RequireInfrastructureEncryption: to.Ptr(false),
// Services: &armstorage.EncryptionServices{
// Blob: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// File: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// },
// },
// IsHnsEnabled: to.Ptr(true),
// KeyCreationTime: &armstorage.KeyCreationTime{
// Key1: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// Key2: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// },
// KeyPolicy: &armstorage.KeyPolicy{
// KeyExpirationPeriodInDays: to.Ptr[int32](20),
// },
// MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
// PrimaryEndpoints: &armstorage.Endpoints{
// Blob: to.Ptr("https://sto4445.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445.file.core.windows.net/"),
// InternetEndpoints: &armstorage.AccountInternetEndpoints{
// Blob: to.Ptr("https://sto4445-internetrouting.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445-internetrouting.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445-internetrouting.file.core.windows.net/"),
// Web: to.Ptr("https://sto4445-internetrouting.web.core.windows.net/"),
// },
// MicrosoftEndpoints: &armstorage.AccountMicrosoftEndpoints{
// Blob: to.Ptr("https://sto4445-microsoftrouting.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445-microsoftrouting.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445-microsoftrouting.file.core.windows.net/"),
// Queue: to.Ptr("https://sto4445-microsoftrouting.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445-microsoftrouting.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445-microsoftrouting.web.core.windows.net/"),
// },
// Queue: to.Ptr("https://sto4445.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445.web.core.windows.net/"),
// },
// PrimaryLocation: to.Ptr("eastus2euap"),
// ProvisioningState: to.Ptr(armstorage.ProvisioningStateSucceeded),
// RoutingPreference: &armstorage.RoutingPreference{
// PublishInternetEndpoints: to.Ptr(true),
// PublishMicrosoftEndpoints: to.Ptr(true),
// RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
// },
// SasPolicy: &armstorage.SasPolicy{
// ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
// SasExpirationPeriod: to.Ptr("1.15:59:59"),
// },
// SecondaryLocation: to.Ptr("centraluseuap"),
// StatusOfPrimary: to.Ptr(armstorage.AccountStatusAvailable),
// StatusOfSecondary: to.Ptr(armstorage.AccountStatusAvailable),
// EnableHTTPSTrafficOnly: to.Ptr(true),
// },
// SKU: &armstorage.SKU{
// Name: to.Ptr(armstorage.SKUNameStandardGRS),
// Tier: to.Ptr(armstorage.SKUTierStandard),
// },
// Tags: map[string]*string{
// "key1": to.Ptr("value1"),
// "key2": to.Ptr("value2"),
// },
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
*
* @summary asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
* x-ms-original-file: 2026-09-01/StorageAccountCreateAllowedCopyScopeToPrivateLink.json
*/
async function storageAccountCreateAllowedCopyScopeToPrivateLink() {
const credential = new DefaultAzureCredential();
const subscriptionId = "00000000-0000-0000-0000-000000000000";
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.storageAccounts.create("res9101", "sto4445", {
kind: "Storage",
location: "eastus",
allowBlobPublicAccess: false,
allowSharedKeyAccess: true,
allowedCopyScope: "PrivateLink",
encryption: {
keySource: "Microsoft.Storage",
requireInfrastructureEncryption: false,
services: {
blob: { enabled: true, keyType: "Account" },
file: { enabled: true, keyType: "Account" },
},
},
isHnsEnabled: true,
keyPolicy: { keyExpirationPeriodInDays: 20 },
minimumTlsVersion: "TLS1_2",
routingPreference: {
publishInternetEndpoints: true,
publishMicrosoftEndpoints: true,
routingChoice: "MicrosoftRouting",
},
sasPolicy: { expirationAction: "Log", sasExpirationPeriod: "1.15:59:59" },
sku: { name: "Standard_GRS" },
tags: { key1: "value1", key2: "value2" },
});
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Voorbeeldrespons
{
"name": "sto4445",
"type": "Microsoft.Storage/storageAccounts",
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445",
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"allowedCopyScope": "PrivateLink",
"creationTime": "2017-05-24T13:25:33.4863236Z",
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
},
"file": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
}
}
},
"isHnsEnabled": true,
"keyCreationTime": {
"key1": "2021-03-18T04:42:22.4322836Z",
"key2": "2021-03-18T04:42:22.4322836Z"
},
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"primaryEndpoints": {
"blob": "https://sto4445.blob.core.windows.net/",
"dfs": "https://sto4445.dfs.core.windows.net/",
"file": "https://sto4445.file.core.windows.net/",
"internetEndpoints": {
"blob": "https://sto4445-internetrouting.blob.core.windows.net/",
"dfs": "https://sto4445-internetrouting.dfs.core.windows.net/",
"file": "https://sto4445-internetrouting.file.core.windows.net/",
"web": "https://sto4445-internetrouting.web.core.windows.net/"
},
"microsoftEndpoints": {
"blob": "https://sto4445-microsoftrouting.blob.core.windows.net/",
"dfs": "https://sto4445-microsoftrouting.dfs.core.windows.net/",
"file": "https://sto4445-microsoftrouting.file.core.windows.net/",
"queue": "https://sto4445-microsoftrouting.queue.core.windows.net/",
"table": "https://sto4445-microsoftrouting.table.core.windows.net/",
"web": "https://sto4445-microsoftrouting.web.core.windows.net/"
},
"queue": "https://sto4445.queue.core.windows.net/",
"table": "https://sto4445.table.core.windows.net/",
"web": "https://sto4445.web.core.windows.net/"
},
"primaryLocation": "eastus2euap",
"provisioningState": "Succeeded",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59"
},
"secondaryLocation": "centraluseuap",
"statusOfPrimary": "available",
"statusOfSecondary": "available",
"supportsHttpsTrafficOnly": true
},
"sku": {
"name": "Standard_GRS",
"tier": "Standard"
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
StorageAccountCreateDisallowPublicNetworkAccess
Voorbeeldaanvraag
PUT https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445?api-version=2026-09-01
{
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account"
},
"file": {
"enabled": true,
"keyType": "Account"
}
}
},
"isHnsEnabled": true,
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"publicNetworkAccess": "Disabled",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59"
}
},
"sku": {
"name": "Standard_GRS"
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
import com.azure.resourcemanager.storage.models.Encryption;
import com.azure.resourcemanager.storage.models.EncryptionService;
import com.azure.resourcemanager.storage.models.EncryptionServices;
import com.azure.resourcemanager.storage.models.ExpirationAction;
import com.azure.resourcemanager.storage.models.ExtendedLocation;
import com.azure.resourcemanager.storage.models.ExtendedLocationTypes;
import com.azure.resourcemanager.storage.models.KeyPolicy;
import com.azure.resourcemanager.storage.models.KeySource;
import com.azure.resourcemanager.storage.models.KeyType;
import com.azure.resourcemanager.storage.models.Kind;
import com.azure.resourcemanager.storage.models.MinimumTlsVersion;
import com.azure.resourcemanager.storage.models.PublicNetworkAccess;
import com.azure.resourcemanager.storage.models.RoutingChoice;
import com.azure.resourcemanager.storage.models.RoutingPreference;
import com.azure.resourcemanager.storage.models.SasPolicy;
import com.azure.resourcemanager.storage.models.Sku;
import com.azure.resourcemanager.storage.models.SkuName;
import com.azure.resourcemanager.storage.models.StorageAccountCreateParameters;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for StorageAccounts Create.
*/
public final class Main {
/*
* x-ms-original-file: 2026-09-01/StorageAccountCreateDisallowPublicNetworkAccess.json
*/
/**
* Sample code: StorageAccountCreateDisallowPublicNetworkAccess.
*
* @param manager Entry point to StorageManager.
*/
public static void
storageAccountCreateDisallowPublicNetworkAccess(com.azure.resourcemanager.storage.StorageManager manager) {
manager.serviceClient().getStorageAccounts()
.create("res9101", "sto4445",
new StorageAccountCreateParameters().withSku(new Sku().withName(SkuName.STANDARD_GRS))
.withKind(Kind.STORAGE).withLocation("eastus")
.withExtendedLocation(
new ExtendedLocation().withName("losangeles001").withType(ExtendedLocationTypes.EDGE_ZONE))
.withTags(mapOf("key1", "fakeTokenPlaceholder", "key2", "fakeTokenPlaceholder"))
.withPublicNetworkAccess(
PublicNetworkAccess.DISABLED)
.withSasPolicy(
new SasPolicy().withSasExpirationPeriod(
"1.15:59:59").withExpirationAction(
ExpirationAction.LOG))
.withKeyPolicy(new KeyPolicy().withKeyExpirationPeriodInDays(20))
.withEncryption(new Encryption()
.withServices(new EncryptionServices()
.withBlob(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT))
.withFile(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT)))
.withKeySource(KeySource.MICROSOFT_STORAGE).withRequireInfrastructureEncryption(false))
.withIsHnsEnabled(true)
.withRoutingPreference(new RoutingPreference().withRoutingChoice(RoutingChoice.MICROSOFT_ROUTING)
.withPublishMicrosoftEndpoints(true).withPublishInternetEndpoints(true))
.withAllowBlobPublicAccess(false).withMinimumTlsVersion(MinimumTlsVersion.TLS1_2)
.withAllowSharedKeyAccess(true),
com.azure.core.util.Context.NONE);
}
// Use "Map.of" if available
@SuppressWarnings("unchecked")
private static <T> Map<String, T> mapOf(Object... inputs) {
Map<String, T> map = new HashMap<>();
for (int i = 0; i < inputs.length; i += 2) {
String key = (String) inputs[i];
T value = (T) inputs[i + 1];
map.put(key, value);
}
return map;
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python storage_account_create_disallow_public_network_access.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.storage_accounts.begin_create(
resource_group_name="res9101",
account_name="sto4445",
parameters={
"extendedLocation": {"name": "losangeles001", "type": "EdgeZone"},
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": False,
"allowSharedKeyAccess": True,
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": False,
"services": {
"blob": {"enabled": True, "keyType": "Account"},
"file": {"enabled": True, "keyType": "Account"},
},
},
"isHnsEnabled": True,
"keyPolicy": {"keyExpirationPeriodInDays": 20},
"minimumTlsVersion": "TLS1_2",
"publicNetworkAccess": "Disabled",
"routingPreference": {
"publishInternetEndpoints": True,
"publishMicrosoftEndpoints": True,
"routingChoice": "MicrosoftRouting",
},
"sasPolicy": {"expirationAction": "Log", "sasExpirationPeriod": "1.15:59:59"},
},
"sku": {"name": "Standard_GRS"},
"tags": {"key1": "value1", "key2": "value2"},
},
).result()
print(response)
# x-ms-original-file: 2026-09-01/StorageAccountCreateDisallowPublicNetworkAccess.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage/v4"
)
// Generated from example definition: 2026-09-01/StorageAccountCreateDisallowPublicNetworkAccess.json
func ExampleAccountsClient_BeginCreate_storageAccountCreateDisallowPublicNetworkAccess() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewAccountsClient().BeginCreate(ctx, "res9101", "sto4445", armstorage.AccountCreateParameters{
ExtendedLocation: &armstorage.ExtendedLocation{
Name: to.Ptr("losangeles001"),
Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
},
Kind: to.Ptr(armstorage.KindStorage),
Location: to.Ptr("eastus"),
Properties: &armstorage.AccountPropertiesCreateParameters{
AllowBlobPublicAccess: to.Ptr(false),
AllowSharedKeyAccess: to.Ptr(true),
Encryption: &armstorage.Encryption{
KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
RequireInfrastructureEncryption: to.Ptr(false),
Services: &armstorage.EncryptionServices{
Blob: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
File: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
},
},
IsHnsEnabled: to.Ptr(true),
KeyPolicy: &armstorage.KeyPolicy{
KeyExpirationPeriodInDays: to.Ptr[int32](20),
},
MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
PublicNetworkAccess: to.Ptr(armstorage.PublicNetworkAccessDisabled),
RoutingPreference: &armstorage.RoutingPreference{
PublishInternetEndpoints: to.Ptr(true),
PublishMicrosoftEndpoints: to.Ptr(true),
RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
},
SasPolicy: &armstorage.SasPolicy{
ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
SasExpirationPeriod: to.Ptr("1.15:59:59"),
},
},
SKU: &armstorage.SKU{
Name: to.Ptr(armstorage.SKUNameStandardGRS),
},
Tags: map[string]*string{
"key1": to.Ptr("value1"),
"key2": to.Ptr("value2"),
},
}, nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
log.Fatalf("failed to poll the result: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res = armstorage.AccountsClientCreateResponse{
// Account: armstorage.Account{
// Name: to.Ptr("sto4445"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts"),
// ExtendedLocation: &armstorage.ExtendedLocation{
// Name: to.Ptr("losangeles001"),
// Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
// },
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445"),
// Kind: to.Ptr(armstorage.KindStorage),
// Location: to.Ptr("eastus"),
// Properties: &armstorage.AccountProperties{
// AllowBlobPublicAccess: to.Ptr(false),
// AllowSharedKeyAccess: to.Ptr(true),
// CreationTime: to.Ptr(time.Date(2017, time.May, 24, 13, 25, 33, 486323600, time.UTC)),
// Encryption: &armstorage.Encryption{
// KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
// RequireInfrastructureEncryption: to.Ptr(false),
// Services: &armstorage.EncryptionServices{
// Blob: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// File: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// },
// },
// IsHnsEnabled: to.Ptr(true),
// KeyCreationTime: &armstorage.KeyCreationTime{
// Key1: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// Key2: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// },
// KeyPolicy: &armstorage.KeyPolicy{
// KeyExpirationPeriodInDays: to.Ptr[int32](20),
// },
// MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
// PrimaryEndpoints: &armstorage.Endpoints{
// Blob: to.Ptr("https://sto4445.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445.file.core.windows.net/"),
// InternetEndpoints: &armstorage.AccountInternetEndpoints{
// Blob: to.Ptr("https://sto4445-internetrouting.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445-internetrouting.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445-internetrouting.file.core.windows.net/"),
// Web: to.Ptr("https://sto4445-internetrouting.web.core.windows.net/"),
// },
// MicrosoftEndpoints: &armstorage.AccountMicrosoftEndpoints{
// Blob: to.Ptr("https://sto4445-microsoftrouting.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445-microsoftrouting.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445-microsoftrouting.file.core.windows.net/"),
// Queue: to.Ptr("https://sto4445-microsoftrouting.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445-microsoftrouting.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445-microsoftrouting.web.core.windows.net/"),
// },
// Queue: to.Ptr("https://sto4445.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445.web.core.windows.net/"),
// },
// PrimaryLocation: to.Ptr("eastus2euap"),
// ProvisioningState: to.Ptr(armstorage.ProvisioningStateSucceeded),
// PublicNetworkAccess: to.Ptr(armstorage.PublicNetworkAccessDisabled),
// RoutingPreference: &armstorage.RoutingPreference{
// PublishInternetEndpoints: to.Ptr(true),
// PublishMicrosoftEndpoints: to.Ptr(true),
// RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
// },
// SasPolicy: &armstorage.SasPolicy{
// ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
// SasExpirationPeriod: to.Ptr("1.15:59:59"),
// },
// SecondaryLocation: to.Ptr("centraluseuap"),
// StatusOfPrimary: to.Ptr(armstorage.AccountStatusAvailable),
// StatusOfSecondary: to.Ptr(armstorage.AccountStatusAvailable),
// EnableHTTPSTrafficOnly: to.Ptr(true),
// },
// SKU: &armstorage.SKU{
// Name: to.Ptr(armstorage.SKUNameStandardGRS),
// Tier: to.Ptr(armstorage.SKUTierStandard),
// },
// Tags: map[string]*string{
// "key1": to.Ptr("value1"),
// "key2": to.Ptr("value2"),
// },
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
*
* @summary asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
* x-ms-original-file: 2026-09-01/StorageAccountCreateDisallowPublicNetworkAccess.json
*/
async function storageAccountCreateDisallowPublicNetworkAccess() {
const credential = new DefaultAzureCredential();
const subscriptionId = "00000000-0000-0000-0000-000000000000";
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.storageAccounts.create("res9101", "sto4445", {
extendedLocation: { name: "losangeles001", type: "EdgeZone" },
kind: "Storage",
location: "eastus",
allowBlobPublicAccess: false,
allowSharedKeyAccess: true,
encryption: {
keySource: "Microsoft.Storage",
requireInfrastructureEncryption: false,
services: {
blob: { enabled: true, keyType: "Account" },
file: { enabled: true, keyType: "Account" },
},
},
isHnsEnabled: true,
keyPolicy: { keyExpirationPeriodInDays: 20 },
minimumTlsVersion: "TLS1_2",
publicNetworkAccess: "Disabled",
routingPreference: {
publishInternetEndpoints: true,
publishMicrosoftEndpoints: true,
routingChoice: "MicrosoftRouting",
},
sasPolicy: { expirationAction: "Log", sasExpirationPeriod: "1.15:59:59" },
sku: { name: "Standard_GRS" },
tags: { key1: "value1", key2: "value2" },
});
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Voorbeeldrespons
{
"name": "sto4445",
"type": "Microsoft.Storage/storageAccounts",
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445",
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"creationTime": "2017-05-24T13:25:33.4863236Z",
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
},
"file": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
}
}
},
"isHnsEnabled": true,
"keyCreationTime": {
"key1": "2021-03-18T04:42:22.4322836Z",
"key2": "2021-03-18T04:42:22.4322836Z"
},
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"primaryEndpoints": {
"blob": "https://sto4445.blob.core.windows.net/",
"dfs": "https://sto4445.dfs.core.windows.net/",
"file": "https://sto4445.file.core.windows.net/",
"internetEndpoints": {
"blob": "https://sto4445-internetrouting.blob.core.windows.net/",
"dfs": "https://sto4445-internetrouting.dfs.core.windows.net/",
"file": "https://sto4445-internetrouting.file.core.windows.net/",
"web": "https://sto4445-internetrouting.web.core.windows.net/"
},
"microsoftEndpoints": {
"blob": "https://sto4445-microsoftrouting.blob.core.windows.net/",
"dfs": "https://sto4445-microsoftrouting.dfs.core.windows.net/",
"file": "https://sto4445-microsoftrouting.file.core.windows.net/",
"queue": "https://sto4445-microsoftrouting.queue.core.windows.net/",
"table": "https://sto4445-microsoftrouting.table.core.windows.net/",
"web": "https://sto4445-microsoftrouting.web.core.windows.net/"
},
"queue": "https://sto4445.queue.core.windows.net/",
"table": "https://sto4445.table.core.windows.net/",
"web": "https://sto4445.web.core.windows.net/"
},
"primaryLocation": "eastus2euap",
"provisioningState": "Succeeded",
"publicNetworkAccess": "Disabled",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59"
},
"secondaryLocation": "centraluseuap",
"statusOfPrimary": "available",
"statusOfSecondary": "available",
"supportsHttpsTrafficOnly": true
},
"sku": {
"name": "Standard_GRS",
"tier": "Standard"
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
StorageAccountCreateDnsEndpointTypeToAzureDnsZone
Voorbeeldaanvraag
PUT https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445?api-version=2026-09-01
{
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"defaultToOAuthAuthentication": false,
"dnsEndpointType": "AzureDnsZone",
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account"
},
"file": {
"enabled": true,
"keyType": "Account"
}
}
},
"isHnsEnabled": true,
"isSftpEnabled": true,
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59"
}
},
"sku": {
"name": "Standard_GRS"
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
import com.azure.resourcemanager.storage.models.DnsEndpointType;
import com.azure.resourcemanager.storage.models.Encryption;
import com.azure.resourcemanager.storage.models.EncryptionService;
import com.azure.resourcemanager.storage.models.EncryptionServices;
import com.azure.resourcemanager.storage.models.ExpirationAction;
import com.azure.resourcemanager.storage.models.ExtendedLocation;
import com.azure.resourcemanager.storage.models.ExtendedLocationTypes;
import com.azure.resourcemanager.storage.models.KeyPolicy;
import com.azure.resourcemanager.storage.models.KeySource;
import com.azure.resourcemanager.storage.models.KeyType;
import com.azure.resourcemanager.storage.models.Kind;
import com.azure.resourcemanager.storage.models.MinimumTlsVersion;
import com.azure.resourcemanager.storage.models.RoutingChoice;
import com.azure.resourcemanager.storage.models.RoutingPreference;
import com.azure.resourcemanager.storage.models.SasPolicy;
import com.azure.resourcemanager.storage.models.Sku;
import com.azure.resourcemanager.storage.models.SkuName;
import com.azure.resourcemanager.storage.models.StorageAccountCreateParameters;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for StorageAccounts Create.
*/
public final class Main {
/*
* x-ms-original-file: 2026-09-01/StorageAccountCreateDnsEndpointTypeToAzureDnsZone.json
*/
/**
* Sample code: StorageAccountCreateDnsEndpointTypeToAzureDnsZone.
*
* @param manager Entry point to StorageManager.
*/
public static void
storageAccountCreateDnsEndpointTypeToAzureDnsZone(com.azure.resourcemanager.storage.StorageManager manager) {
manager.serviceClient().getStorageAccounts()
.create("res9101", "sto4445",
new StorageAccountCreateParameters().withSku(new Sku().withName(SkuName.STANDARD_GRS))
.withKind(Kind.STORAGE).withLocation("eastus")
.withExtendedLocation(
new ExtendedLocation().withName("losangeles001").withType(ExtendedLocationTypes.EDGE_ZONE))
.withTags(
mapOf("key1", "fakeTokenPlaceholder", "key2", "fakeTokenPlaceholder"))
.withSasPolicy(
new SasPolicy().withSasExpirationPeriod(
"1.15:59:59").withExpirationAction(
ExpirationAction.LOG))
.withKeyPolicy(new KeyPolicy().withKeyExpirationPeriodInDays(20))
.withEncryption(new Encryption()
.withServices(new EncryptionServices()
.withBlob(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT))
.withFile(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT)))
.withKeySource(KeySource.MICROSOFT_STORAGE).withRequireInfrastructureEncryption(false))
.withIsSftpEnabled(true).withIsHnsEnabled(true)
.withRoutingPreference(new RoutingPreference().withRoutingChoice(RoutingChoice.MICROSOFT_ROUTING)
.withPublishMicrosoftEndpoints(true).withPublishInternetEndpoints(true))
.withAllowBlobPublicAccess(false).withMinimumTlsVersion(MinimumTlsVersion.TLS1_2)
.withAllowSharedKeyAccess(true).withDefaultToOAuthAuthentication(false)
.withDnsEndpointType(DnsEndpointType.AZURE_DNS_ZONE),
com.azure.core.util.Context.NONE);
}
// Use "Map.of" if available
@SuppressWarnings("unchecked")
private static <T> Map<String, T> mapOf(Object... inputs) {
Map<String, T> map = new HashMap<>();
for (int i = 0; i < inputs.length; i += 2) {
String key = (String) inputs[i];
T value = (T) inputs[i + 1];
map.put(key, value);
}
return map;
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python storage_account_create_dns_endpoint_type_to_azure_dns_zone.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.storage_accounts.begin_create(
resource_group_name="res9101",
account_name="sto4445",
parameters={
"extendedLocation": {"name": "losangeles001", "type": "EdgeZone"},
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": False,
"allowSharedKeyAccess": True,
"defaultToOAuthAuthentication": False,
"dnsEndpointType": "AzureDnsZone",
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": False,
"services": {
"blob": {"enabled": True, "keyType": "Account"},
"file": {"enabled": True, "keyType": "Account"},
},
},
"isHnsEnabled": True,
"isSftpEnabled": True,
"keyPolicy": {"keyExpirationPeriodInDays": 20},
"minimumTlsVersion": "TLS1_2",
"routingPreference": {
"publishInternetEndpoints": True,
"publishMicrosoftEndpoints": True,
"routingChoice": "MicrosoftRouting",
},
"sasPolicy": {"expirationAction": "Log", "sasExpirationPeriod": "1.15:59:59"},
},
"sku": {"name": "Standard_GRS"},
"tags": {"key1": "value1", "key2": "value2"},
},
).result()
print(response)
# x-ms-original-file: 2026-09-01/StorageAccountCreateDnsEndpointTypeToAzureDnsZone.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage/v4"
)
// Generated from example definition: 2026-09-01/StorageAccountCreateDnsEndpointTypeToAzureDnsZone.json
func ExampleAccountsClient_BeginCreate_storageAccountCreateDnsEndpointTypeToAzureDnsZone() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewAccountsClient().BeginCreate(ctx, "res9101", "sto4445", armstorage.AccountCreateParameters{
ExtendedLocation: &armstorage.ExtendedLocation{
Name: to.Ptr("losangeles001"),
Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
},
Kind: to.Ptr(armstorage.KindStorage),
Location: to.Ptr("eastus"),
Properties: &armstorage.AccountPropertiesCreateParameters{
AllowBlobPublicAccess: to.Ptr(false),
AllowSharedKeyAccess: to.Ptr(true),
DefaultToOAuthAuthentication: to.Ptr(false),
DNSEndpointType: to.Ptr(armstorage.DNSEndpointTypeAzureDNSZone),
Encryption: &armstorage.Encryption{
KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
RequireInfrastructureEncryption: to.Ptr(false),
Services: &armstorage.EncryptionServices{
Blob: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
File: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
},
},
IsHnsEnabled: to.Ptr(true),
IsSftpEnabled: to.Ptr(true),
KeyPolicy: &armstorage.KeyPolicy{
KeyExpirationPeriodInDays: to.Ptr[int32](20),
},
MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
RoutingPreference: &armstorage.RoutingPreference{
PublishInternetEndpoints: to.Ptr(true),
PublishMicrosoftEndpoints: to.Ptr(true),
RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
},
SasPolicy: &armstorage.SasPolicy{
ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
SasExpirationPeriod: to.Ptr("1.15:59:59"),
},
},
SKU: &armstorage.SKU{
Name: to.Ptr(armstorage.SKUNameStandardGRS),
},
Tags: map[string]*string{
"key1": to.Ptr("value1"),
"key2": to.Ptr("value2"),
},
}, nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
log.Fatalf("failed to poll the result: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res = armstorage.AccountsClientCreateResponse{
// Account: armstorage.Account{
// Name: to.Ptr("sto4445"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts"),
// ExtendedLocation: &armstorage.ExtendedLocation{
// Name: to.Ptr("losangeles001"),
// Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
// },
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445"),
// Kind: to.Ptr(armstorage.KindStorage),
// Location: to.Ptr("eastus"),
// Properties: &armstorage.AccountProperties{
// AllowBlobPublicAccess: to.Ptr(false),
// AllowSharedKeyAccess: to.Ptr(true),
// CreationTime: to.Ptr(time.Date(2017, time.May, 24, 13, 25, 33, 486323600, time.UTC)),
// DNSEndpointType: to.Ptr(armstorage.DNSEndpointTypeAzureDNSZone),
// Encryption: &armstorage.Encryption{
// KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
// RequireInfrastructureEncryption: to.Ptr(false),
// Services: &armstorage.EncryptionServices{
// Blob: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// File: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// },
// },
// IsHnsEnabled: to.Ptr(true),
// IsSftpEnabled: to.Ptr(true),
// KeyCreationTime: &armstorage.KeyCreationTime{
// Key1: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// Key2: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// },
// KeyPolicy: &armstorage.KeyPolicy{
// KeyExpirationPeriodInDays: to.Ptr[int32](20),
// },
// MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
// PrimaryEndpoints: &armstorage.Endpoints{
// Blob: to.Ptr("https://sto4445.z24.blob.storage.azure.net/"),
// Dfs: to.Ptr("https://sto4445.z24.dfs.storage.azure.net/"),
// File: to.Ptr("https://sto4445.z24.file.storage.azure.net/"),
// InternetEndpoints: &armstorage.AccountInternetEndpoints{
// Blob: to.Ptr("https://sto4445-internetrouting.z24.blob.storage.azure.net/"),
// Dfs: to.Ptr("https://sto4445-internetrouting.z24.dfs.storage.azure.net/"),
// File: to.Ptr("https://sto4445-internetrouting.z24.file.storage.azure.net/"),
// Web: to.Ptr("https://sto4445-internetrouting.z24.web.storage.azure.net/"),
// },
// MicrosoftEndpoints: &armstorage.AccountMicrosoftEndpoints{
// Blob: to.Ptr("https://sto4445-microsoftrouting.z24.blob.storage.azure.net/"),
// Dfs: to.Ptr("https://sto4445-microsoftrouting.z24.dfs.storage.azure.net/"),
// File: to.Ptr("https://sto4445-microsoftrouting.z24.file.storage.azure.net/"),
// Queue: to.Ptr("https://sto4445-microsoftrouting.z24.queue.storage.azure.net/"),
// Table: to.Ptr("https://sto4445-microsoftrouting.z24.table.storage.azure.net/"),
// Web: to.Ptr("https://sto4445-microsoftrouting.z24.web.storage.azure.net/"),
// },
// Queue: to.Ptr("https://sto4445.z24.queue.storage.azure.net/"),
// Table: to.Ptr("https://sto4445.z24.table.storage.azure.net/"),
// Web: to.Ptr("https://sto4445.z24.web.storage.azure.net/"),
// },
// PrimaryLocation: to.Ptr("eastus2euap"),
// ProvisioningState: to.Ptr(armstorage.ProvisioningStateSucceeded),
// RoutingPreference: &armstorage.RoutingPreference{
// PublishInternetEndpoints: to.Ptr(true),
// PublishMicrosoftEndpoints: to.Ptr(true),
// RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
// },
// SasPolicy: &armstorage.SasPolicy{
// ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
// SasExpirationPeriod: to.Ptr("1.15:59:59"),
// },
// SecondaryLocation: to.Ptr("centraluseuap"),
// StatusOfPrimary: to.Ptr(armstorage.AccountStatusAvailable),
// StatusOfSecondary: to.Ptr(armstorage.AccountStatusAvailable),
// EnableHTTPSTrafficOnly: to.Ptr(true),
// },
// SKU: &armstorage.SKU{
// Name: to.Ptr(armstorage.SKUNameStandardGRS),
// Tier: to.Ptr(armstorage.SKUTierStandard),
// },
// Tags: map[string]*string{
// "key1": to.Ptr("value1"),
// "key2": to.Ptr("value2"),
// },
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
*
* @summary asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
* x-ms-original-file: 2026-09-01/StorageAccountCreateDnsEndpointTypeToAzureDnsZone.json
*/
async function storageAccountCreateDnsEndpointTypeToAzureDnsZone() {
const credential = new DefaultAzureCredential();
const subscriptionId = "00000000-0000-0000-0000-000000000000";
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.storageAccounts.create("res9101", "sto4445", {
extendedLocation: { name: "losangeles001", type: "EdgeZone" },
kind: "Storage",
location: "eastus",
allowBlobPublicAccess: false,
allowSharedKeyAccess: true,
defaultToOAuthAuthentication: false,
dnsEndpointType: "AzureDnsZone",
encryption: {
keySource: "Microsoft.Storage",
requireInfrastructureEncryption: false,
services: {
blob: { enabled: true, keyType: "Account" },
file: { enabled: true, keyType: "Account" },
},
},
isHnsEnabled: true,
isSftpEnabled: true,
keyPolicy: { keyExpirationPeriodInDays: 20 },
minimumTlsVersion: "TLS1_2",
routingPreference: {
publishInternetEndpoints: true,
publishMicrosoftEndpoints: true,
routingChoice: "MicrosoftRouting",
},
sasPolicy: { expirationAction: "Log", sasExpirationPeriod: "1.15:59:59" },
sku: { name: "Standard_GRS" },
tags: { key1: "value1", key2: "value2" },
});
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Voorbeeldrespons
{
"name": "sto4445",
"type": "Microsoft.Storage/storageAccounts",
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445",
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"creationTime": "2017-05-24T13:25:33.4863236Z",
"dnsEndpointType": "AzureDnsZone",
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
},
"file": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
}
}
},
"isHnsEnabled": true,
"isSftpEnabled": true,
"keyCreationTime": {
"key1": "2021-03-18T04:42:22.4322836Z",
"key2": "2021-03-18T04:42:22.4322836Z"
},
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"primaryEndpoints": {
"blob": "https://sto4445.z24.blob.storage.azure.net/",
"dfs": "https://sto4445.z24.dfs.storage.azure.net/",
"file": "https://sto4445.z24.file.storage.azure.net/",
"internetEndpoints": {
"blob": "https://sto4445-internetrouting.z24.blob.storage.azure.net/",
"dfs": "https://sto4445-internetrouting.z24.dfs.storage.azure.net/",
"file": "https://sto4445-internetrouting.z24.file.storage.azure.net/",
"web": "https://sto4445-internetrouting.z24.web.storage.azure.net/"
},
"microsoftEndpoints": {
"blob": "https://sto4445-microsoftrouting.z24.blob.storage.azure.net/",
"dfs": "https://sto4445-microsoftrouting.z24.dfs.storage.azure.net/",
"file": "https://sto4445-microsoftrouting.z24.file.storage.azure.net/",
"queue": "https://sto4445-microsoftrouting.z24.queue.storage.azure.net/",
"table": "https://sto4445-microsoftrouting.z24.table.storage.azure.net/",
"web": "https://sto4445-microsoftrouting.z24.web.storage.azure.net/"
},
"queue": "https://sto4445.z24.queue.storage.azure.net/",
"table": "https://sto4445.z24.table.storage.azure.net/",
"web": "https://sto4445.z24.web.storage.azure.net/"
},
"primaryLocation": "eastus2euap",
"provisioningState": "Succeeded",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59"
},
"secondaryLocation": "centraluseuap",
"statusOfPrimary": "available",
"statusOfSecondary": "available",
"supportsHttpsTrafficOnly": true
},
"sku": {
"name": "Standard_GRS",
"tier": "Standard"
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
StorageAccountCreateDnsEndpointTypeToStandard
Voorbeeldaanvraag
PUT https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445?api-version=2026-09-01
{
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"defaultToOAuthAuthentication": false,
"dnsEndpointType": "Standard",
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account"
},
"file": {
"enabled": true,
"keyType": "Account"
}
}
},
"isHnsEnabled": true,
"isSftpEnabled": true,
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59"
}
},
"sku": {
"name": "Standard_GRS"
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
import com.azure.resourcemanager.storage.models.DnsEndpointType;
import com.azure.resourcemanager.storage.models.Encryption;
import com.azure.resourcemanager.storage.models.EncryptionService;
import com.azure.resourcemanager.storage.models.EncryptionServices;
import com.azure.resourcemanager.storage.models.ExpirationAction;
import com.azure.resourcemanager.storage.models.ExtendedLocation;
import com.azure.resourcemanager.storage.models.ExtendedLocationTypes;
import com.azure.resourcemanager.storage.models.KeyPolicy;
import com.azure.resourcemanager.storage.models.KeySource;
import com.azure.resourcemanager.storage.models.KeyType;
import com.azure.resourcemanager.storage.models.Kind;
import com.azure.resourcemanager.storage.models.MinimumTlsVersion;
import com.azure.resourcemanager.storage.models.RoutingChoice;
import com.azure.resourcemanager.storage.models.RoutingPreference;
import com.azure.resourcemanager.storage.models.SasPolicy;
import com.azure.resourcemanager.storage.models.Sku;
import com.azure.resourcemanager.storage.models.SkuName;
import com.azure.resourcemanager.storage.models.StorageAccountCreateParameters;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for StorageAccounts Create.
*/
public final class Main {
/*
* x-ms-original-file: 2026-09-01/StorageAccountCreateDnsEndpointTypeToStandard.json
*/
/**
* Sample code: StorageAccountCreateDnsEndpointTypeToStandard.
*
* @param manager Entry point to StorageManager.
*/
public static void
storageAccountCreateDnsEndpointTypeToStandard(com.azure.resourcemanager.storage.StorageManager manager) {
manager.serviceClient().getStorageAccounts()
.create("res9101", "sto4445",
new StorageAccountCreateParameters().withSku(new Sku().withName(SkuName.STANDARD_GRS))
.withKind(Kind.STORAGE).withLocation("eastus")
.withExtendedLocation(
new ExtendedLocation().withName("losangeles001").withType(ExtendedLocationTypes.EDGE_ZONE))
.withTags(
mapOf("key1", "fakeTokenPlaceholder", "key2", "fakeTokenPlaceholder"))
.withSasPolicy(
new SasPolicy().withSasExpirationPeriod(
"1.15:59:59").withExpirationAction(
ExpirationAction.LOG))
.withKeyPolicy(new KeyPolicy().withKeyExpirationPeriodInDays(20))
.withEncryption(new Encryption()
.withServices(new EncryptionServices()
.withBlob(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT))
.withFile(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT)))
.withKeySource(KeySource.MICROSOFT_STORAGE).withRequireInfrastructureEncryption(false))
.withIsSftpEnabled(true).withIsHnsEnabled(true)
.withRoutingPreference(new RoutingPreference().withRoutingChoice(RoutingChoice.MICROSOFT_ROUTING)
.withPublishMicrosoftEndpoints(true).withPublishInternetEndpoints(true))
.withAllowBlobPublicAccess(false).withMinimumTlsVersion(MinimumTlsVersion.TLS1_2)
.withAllowSharedKeyAccess(true).withDefaultToOAuthAuthentication(false)
.withDnsEndpointType(DnsEndpointType.STANDARD),
com.azure.core.util.Context.NONE);
}
// Use "Map.of" if available
@SuppressWarnings("unchecked")
private static <T> Map<String, T> mapOf(Object... inputs) {
Map<String, T> map = new HashMap<>();
for (int i = 0; i < inputs.length; i += 2) {
String key = (String) inputs[i];
T value = (T) inputs[i + 1];
map.put(key, value);
}
return map;
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python storage_account_create_dns_endpoint_type_to_standard.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.storage_accounts.begin_create(
resource_group_name="res9101",
account_name="sto4445",
parameters={
"extendedLocation": {"name": "losangeles001", "type": "EdgeZone"},
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": False,
"allowSharedKeyAccess": True,
"defaultToOAuthAuthentication": False,
"dnsEndpointType": "Standard",
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": False,
"services": {
"blob": {"enabled": True, "keyType": "Account"},
"file": {"enabled": True, "keyType": "Account"},
},
},
"isHnsEnabled": True,
"isSftpEnabled": True,
"keyPolicy": {"keyExpirationPeriodInDays": 20},
"minimumTlsVersion": "TLS1_2",
"routingPreference": {
"publishInternetEndpoints": True,
"publishMicrosoftEndpoints": True,
"routingChoice": "MicrosoftRouting",
},
"sasPolicy": {"expirationAction": "Log", "sasExpirationPeriod": "1.15:59:59"},
},
"sku": {"name": "Standard_GRS"},
"tags": {"key1": "value1", "key2": "value2"},
},
).result()
print(response)
# x-ms-original-file: 2026-09-01/StorageAccountCreateDnsEndpointTypeToStandard.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage/v4"
)
// Generated from example definition: 2026-09-01/StorageAccountCreateDnsEndpointTypeToStandard.json
func ExampleAccountsClient_BeginCreate_storageAccountCreateDnsEndpointTypeToStandard() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewAccountsClient().BeginCreate(ctx, "res9101", "sto4445", armstorage.AccountCreateParameters{
ExtendedLocation: &armstorage.ExtendedLocation{
Name: to.Ptr("losangeles001"),
Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
},
Kind: to.Ptr(armstorage.KindStorage),
Location: to.Ptr("eastus"),
Properties: &armstorage.AccountPropertiesCreateParameters{
AllowBlobPublicAccess: to.Ptr(false),
AllowSharedKeyAccess: to.Ptr(true),
DefaultToOAuthAuthentication: to.Ptr(false),
DNSEndpointType: to.Ptr(armstorage.DNSEndpointTypeStandard),
Encryption: &armstorage.Encryption{
KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
RequireInfrastructureEncryption: to.Ptr(false),
Services: &armstorage.EncryptionServices{
Blob: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
File: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
},
},
IsHnsEnabled: to.Ptr(true),
IsSftpEnabled: to.Ptr(true),
KeyPolicy: &armstorage.KeyPolicy{
KeyExpirationPeriodInDays: to.Ptr[int32](20),
},
MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
RoutingPreference: &armstorage.RoutingPreference{
PublishInternetEndpoints: to.Ptr(true),
PublishMicrosoftEndpoints: to.Ptr(true),
RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
},
SasPolicy: &armstorage.SasPolicy{
ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
SasExpirationPeriod: to.Ptr("1.15:59:59"),
},
},
SKU: &armstorage.SKU{
Name: to.Ptr(armstorage.SKUNameStandardGRS),
},
Tags: map[string]*string{
"key1": to.Ptr("value1"),
"key2": to.Ptr("value2"),
},
}, nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
log.Fatalf("failed to poll the result: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res = armstorage.AccountsClientCreateResponse{
// Account: armstorage.Account{
// Name: to.Ptr("sto4445"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts"),
// ExtendedLocation: &armstorage.ExtendedLocation{
// Name: to.Ptr("losangeles001"),
// Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
// },
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445"),
// Kind: to.Ptr(armstorage.KindStorage),
// Location: to.Ptr("eastus"),
// Properties: &armstorage.AccountProperties{
// AllowBlobPublicAccess: to.Ptr(false),
// AllowSharedKeyAccess: to.Ptr(true),
// CreationTime: to.Ptr(time.Date(2017, time.May, 24, 13, 25, 33, 486323600, time.UTC)),
// DNSEndpointType: to.Ptr(armstorage.DNSEndpointTypeStandard),
// Encryption: &armstorage.Encryption{
// KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
// RequireInfrastructureEncryption: to.Ptr(false),
// Services: &armstorage.EncryptionServices{
// Blob: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// File: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// },
// },
// IsHnsEnabled: to.Ptr(true),
// IsSftpEnabled: to.Ptr(true),
// KeyCreationTime: &armstorage.KeyCreationTime{
// Key1: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// Key2: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// },
// KeyPolicy: &armstorage.KeyPolicy{
// KeyExpirationPeriodInDays: to.Ptr[int32](20),
// },
// MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
// PrimaryEndpoints: &armstorage.Endpoints{
// Blob: to.Ptr("https://sto4445.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445.file.core.windows.net/"),
// InternetEndpoints: &armstorage.AccountInternetEndpoints{
// Blob: to.Ptr("https://sto4445-internetrouting.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445-internetrouting.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445-internetrouting.file.core.windows.net/"),
// Web: to.Ptr("https://sto4445-internetrouting.web.core.windows.net/"),
// },
// MicrosoftEndpoints: &armstorage.AccountMicrosoftEndpoints{
// Blob: to.Ptr("https://sto4445-microsoftrouting.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445-microsoftrouting.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445-microsoftrouting.file.core.windows.net/"),
// Queue: to.Ptr("https://sto4445-microsoftrouting.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445-microsoftrouting.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445-microsoftrouting.web.core.windows.net/"),
// },
// Queue: to.Ptr("https://sto4445.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445.web.core.windows.net/"),
// },
// PrimaryLocation: to.Ptr("eastus2euap"),
// ProvisioningState: to.Ptr(armstorage.ProvisioningStateSucceeded),
// RoutingPreference: &armstorage.RoutingPreference{
// PublishInternetEndpoints: to.Ptr(true),
// PublishMicrosoftEndpoints: to.Ptr(true),
// RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
// },
// SasPolicy: &armstorage.SasPolicy{
// ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
// SasExpirationPeriod: to.Ptr("1.15:59:59"),
// },
// SecondaryLocation: to.Ptr("centraluseuap"),
// StatusOfPrimary: to.Ptr(armstorage.AccountStatusAvailable),
// StatusOfSecondary: to.Ptr(armstorage.AccountStatusAvailable),
// EnableHTTPSTrafficOnly: to.Ptr(true),
// },
// SKU: &armstorage.SKU{
// Name: to.Ptr(armstorage.SKUNameStandardGRS),
// Tier: to.Ptr(armstorage.SKUTierStandard),
// },
// Tags: map[string]*string{
// "key1": to.Ptr("value1"),
// "key2": to.Ptr("value2"),
// },
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
*
* @summary asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
* x-ms-original-file: 2026-09-01/StorageAccountCreateDnsEndpointTypeToStandard.json
*/
async function storageAccountCreateDnsEndpointTypeToStandard() {
const credential = new DefaultAzureCredential();
const subscriptionId = "00000000-0000-0000-0000-000000000000";
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.storageAccounts.create("res9101", "sto4445", {
extendedLocation: { name: "losangeles001", type: "EdgeZone" },
kind: "Storage",
location: "eastus",
allowBlobPublicAccess: false,
allowSharedKeyAccess: true,
defaultToOAuthAuthentication: false,
dnsEndpointType: "Standard",
encryption: {
keySource: "Microsoft.Storage",
requireInfrastructureEncryption: false,
services: {
blob: { enabled: true, keyType: "Account" },
file: { enabled: true, keyType: "Account" },
},
},
isHnsEnabled: true,
isSftpEnabled: true,
keyPolicy: { keyExpirationPeriodInDays: 20 },
minimumTlsVersion: "TLS1_2",
routingPreference: {
publishInternetEndpoints: true,
publishMicrosoftEndpoints: true,
routingChoice: "MicrosoftRouting",
},
sasPolicy: { expirationAction: "Log", sasExpirationPeriod: "1.15:59:59" },
sku: { name: "Standard_GRS" },
tags: { key1: "value1", key2: "value2" },
});
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Voorbeeldrespons
{
"name": "sto4445",
"type": "Microsoft.Storage/storageAccounts",
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445",
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"creationTime": "2017-05-24T13:25:33.4863236Z",
"dnsEndpointType": "Standard",
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
},
"file": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
}
}
},
"isHnsEnabled": true,
"isSftpEnabled": true,
"keyCreationTime": {
"key1": "2021-03-18T04:42:22.4322836Z",
"key2": "2021-03-18T04:42:22.4322836Z"
},
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"primaryEndpoints": {
"blob": "https://sto4445.blob.core.windows.net/",
"dfs": "https://sto4445.dfs.core.windows.net/",
"file": "https://sto4445.file.core.windows.net/",
"internetEndpoints": {
"blob": "https://sto4445-internetrouting.blob.core.windows.net/",
"dfs": "https://sto4445-internetrouting.dfs.core.windows.net/",
"file": "https://sto4445-internetrouting.file.core.windows.net/",
"web": "https://sto4445-internetrouting.web.core.windows.net/"
},
"microsoftEndpoints": {
"blob": "https://sto4445-microsoftrouting.blob.core.windows.net/",
"dfs": "https://sto4445-microsoftrouting.dfs.core.windows.net/",
"file": "https://sto4445-microsoftrouting.file.core.windows.net/",
"queue": "https://sto4445-microsoftrouting.queue.core.windows.net/",
"table": "https://sto4445-microsoftrouting.table.core.windows.net/",
"web": "https://sto4445-microsoftrouting.web.core.windows.net/"
},
"queue": "https://sto4445.queue.core.windows.net/",
"table": "https://sto4445.table.core.windows.net/",
"web": "https://sto4445.web.core.windows.net/"
},
"primaryLocation": "eastus2euap",
"provisioningState": "Succeeded",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59"
},
"secondaryLocation": "centraluseuap",
"statusOfPrimary": "available",
"statusOfSecondary": "available",
"supportsHttpsTrafficOnly": true
},
"sku": {
"name": "Standard_GRS",
"tier": "Standard"
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
StorageAccountCreateEnablePublicNetworkAccess
Voorbeeldaanvraag
PUT https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445?api-version=2026-09-01
{
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account"
},
"file": {
"enabled": true,
"keyType": "Account"
}
}
},
"isHnsEnabled": true,
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"publicNetworkAccess": "Enabled",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59"
}
},
"sku": {
"name": "Standard_GRS"
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
import com.azure.resourcemanager.storage.models.Encryption;
import com.azure.resourcemanager.storage.models.EncryptionService;
import com.azure.resourcemanager.storage.models.EncryptionServices;
import com.azure.resourcemanager.storage.models.ExpirationAction;
import com.azure.resourcemanager.storage.models.ExtendedLocation;
import com.azure.resourcemanager.storage.models.ExtendedLocationTypes;
import com.azure.resourcemanager.storage.models.KeyPolicy;
import com.azure.resourcemanager.storage.models.KeySource;
import com.azure.resourcemanager.storage.models.KeyType;
import com.azure.resourcemanager.storage.models.Kind;
import com.azure.resourcemanager.storage.models.MinimumTlsVersion;
import com.azure.resourcemanager.storage.models.PublicNetworkAccess;
import com.azure.resourcemanager.storage.models.RoutingChoice;
import com.azure.resourcemanager.storage.models.RoutingPreference;
import com.azure.resourcemanager.storage.models.SasPolicy;
import com.azure.resourcemanager.storage.models.Sku;
import com.azure.resourcemanager.storage.models.SkuName;
import com.azure.resourcemanager.storage.models.StorageAccountCreateParameters;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for StorageAccounts Create.
*/
public final class Main {
/*
* x-ms-original-file: 2026-09-01/StorageAccountCreateEnablePublicNetworkAccess.json
*/
/**
* Sample code: StorageAccountCreateEnablePublicNetworkAccess.
*
* @param manager Entry point to StorageManager.
*/
public static void
storageAccountCreateEnablePublicNetworkAccess(com.azure.resourcemanager.storage.StorageManager manager) {
manager.serviceClient().getStorageAccounts()
.create("res9101", "sto4445",
new StorageAccountCreateParameters().withSku(new Sku().withName(SkuName.STANDARD_GRS))
.withKind(Kind.STORAGE).withLocation("eastus")
.withExtendedLocation(
new ExtendedLocation().withName("losangeles001").withType(ExtendedLocationTypes.EDGE_ZONE))
.withTags(mapOf("key1", "fakeTokenPlaceholder", "key2", "fakeTokenPlaceholder"))
.withPublicNetworkAccess(
PublicNetworkAccess.ENABLED)
.withSasPolicy(
new SasPolicy().withSasExpirationPeriod(
"1.15:59:59").withExpirationAction(
ExpirationAction.LOG))
.withKeyPolicy(new KeyPolicy().withKeyExpirationPeriodInDays(20))
.withEncryption(new Encryption()
.withServices(new EncryptionServices()
.withBlob(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT))
.withFile(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT)))
.withKeySource(KeySource.MICROSOFT_STORAGE).withRequireInfrastructureEncryption(false))
.withIsHnsEnabled(true)
.withRoutingPreference(new RoutingPreference().withRoutingChoice(RoutingChoice.MICROSOFT_ROUTING)
.withPublishMicrosoftEndpoints(true).withPublishInternetEndpoints(true))
.withAllowBlobPublicAccess(false).withMinimumTlsVersion(MinimumTlsVersion.TLS1_2)
.withAllowSharedKeyAccess(true),
com.azure.core.util.Context.NONE);
}
// Use "Map.of" if available
@SuppressWarnings("unchecked")
private static <T> Map<String, T> mapOf(Object... inputs) {
Map<String, T> map = new HashMap<>();
for (int i = 0; i < inputs.length; i += 2) {
String key = (String) inputs[i];
T value = (T) inputs[i + 1];
map.put(key, value);
}
return map;
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python storage_account_create_enable_public_network_access.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.storage_accounts.begin_create(
resource_group_name="res9101",
account_name="sto4445",
parameters={
"extendedLocation": {"name": "losangeles001", "type": "EdgeZone"},
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": False,
"allowSharedKeyAccess": True,
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": False,
"services": {
"blob": {"enabled": True, "keyType": "Account"},
"file": {"enabled": True, "keyType": "Account"},
},
},
"isHnsEnabled": True,
"keyPolicy": {"keyExpirationPeriodInDays": 20},
"minimumTlsVersion": "TLS1_2",
"publicNetworkAccess": "Enabled",
"routingPreference": {
"publishInternetEndpoints": True,
"publishMicrosoftEndpoints": True,
"routingChoice": "MicrosoftRouting",
},
"sasPolicy": {"expirationAction": "Log", "sasExpirationPeriod": "1.15:59:59"},
},
"sku": {"name": "Standard_GRS"},
"tags": {"key1": "value1", "key2": "value2"},
},
).result()
print(response)
# x-ms-original-file: 2026-09-01/StorageAccountCreateEnablePublicNetworkAccess.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage/v4"
)
// Generated from example definition: 2026-09-01/StorageAccountCreateEnablePublicNetworkAccess.json
func ExampleAccountsClient_BeginCreate_storageAccountCreateEnablePublicNetworkAccess() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewAccountsClient().BeginCreate(ctx, "res9101", "sto4445", armstorage.AccountCreateParameters{
ExtendedLocation: &armstorage.ExtendedLocation{
Name: to.Ptr("losangeles001"),
Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
},
Kind: to.Ptr(armstorage.KindStorage),
Location: to.Ptr("eastus"),
Properties: &armstorage.AccountPropertiesCreateParameters{
AllowBlobPublicAccess: to.Ptr(false),
AllowSharedKeyAccess: to.Ptr(true),
Encryption: &armstorage.Encryption{
KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
RequireInfrastructureEncryption: to.Ptr(false),
Services: &armstorage.EncryptionServices{
Blob: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
File: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
},
},
IsHnsEnabled: to.Ptr(true),
KeyPolicy: &armstorage.KeyPolicy{
KeyExpirationPeriodInDays: to.Ptr[int32](20),
},
MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
PublicNetworkAccess: to.Ptr(armstorage.PublicNetworkAccessEnabled),
RoutingPreference: &armstorage.RoutingPreference{
PublishInternetEndpoints: to.Ptr(true),
PublishMicrosoftEndpoints: to.Ptr(true),
RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
},
SasPolicy: &armstorage.SasPolicy{
ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
SasExpirationPeriod: to.Ptr("1.15:59:59"),
},
},
SKU: &armstorage.SKU{
Name: to.Ptr(armstorage.SKUNameStandardGRS),
},
Tags: map[string]*string{
"key1": to.Ptr("value1"),
"key2": to.Ptr("value2"),
},
}, nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
log.Fatalf("failed to poll the result: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res = armstorage.AccountsClientCreateResponse{
// Account: armstorage.Account{
// Name: to.Ptr("sto4445"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts"),
// ExtendedLocation: &armstorage.ExtendedLocation{
// Name: to.Ptr("losangeles001"),
// Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
// },
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445"),
// Kind: to.Ptr(armstorage.KindStorage),
// Location: to.Ptr("eastus"),
// Properties: &armstorage.AccountProperties{
// AllowBlobPublicAccess: to.Ptr(false),
// AllowSharedKeyAccess: to.Ptr(true),
// CreationTime: to.Ptr(time.Date(2017, time.May, 24, 13, 25, 33, 486323600, time.UTC)),
// Encryption: &armstorage.Encryption{
// KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
// RequireInfrastructureEncryption: to.Ptr(false),
// Services: &armstorage.EncryptionServices{
// Blob: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// File: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// },
// },
// IsHnsEnabled: to.Ptr(true),
// KeyCreationTime: &armstorage.KeyCreationTime{
// Key1: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// Key2: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// },
// KeyPolicy: &armstorage.KeyPolicy{
// KeyExpirationPeriodInDays: to.Ptr[int32](20),
// },
// MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
// PrimaryEndpoints: &armstorage.Endpoints{
// Blob: to.Ptr("https://sto4445.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445.file.core.windows.net/"),
// InternetEndpoints: &armstorage.AccountInternetEndpoints{
// Blob: to.Ptr("https://sto4445-internetrouting.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445-internetrouting.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445-internetrouting.file.core.windows.net/"),
// Web: to.Ptr("https://sto4445-internetrouting.web.core.windows.net/"),
// },
// MicrosoftEndpoints: &armstorage.AccountMicrosoftEndpoints{
// Blob: to.Ptr("https://sto4445-microsoftrouting.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445-microsoftrouting.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445-microsoftrouting.file.core.windows.net/"),
// Queue: to.Ptr("https://sto4445-microsoftrouting.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445-microsoftrouting.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445-microsoftrouting.web.core.windows.net/"),
// },
// Queue: to.Ptr("https://sto4445.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445.web.core.windows.net/"),
// },
// PrimaryLocation: to.Ptr("eastus2euap"),
// ProvisioningState: to.Ptr(armstorage.ProvisioningStateSucceeded),
// PublicNetworkAccess: to.Ptr(armstorage.PublicNetworkAccessEnabled),
// RoutingPreference: &armstorage.RoutingPreference{
// PublishInternetEndpoints: to.Ptr(true),
// PublishMicrosoftEndpoints: to.Ptr(true),
// RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
// },
// SasPolicy: &armstorage.SasPolicy{
// ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
// SasExpirationPeriod: to.Ptr("1.15:59:59"),
// },
// SecondaryLocation: to.Ptr("centraluseuap"),
// StatusOfPrimary: to.Ptr(armstorage.AccountStatusAvailable),
// StatusOfSecondary: to.Ptr(armstorage.AccountStatusAvailable),
// EnableHTTPSTrafficOnly: to.Ptr(true),
// },
// SKU: &armstorage.SKU{
// Name: to.Ptr(armstorage.SKUNameStandardGRS),
// Tier: to.Ptr(armstorage.SKUTierStandard),
// },
// Tags: map[string]*string{
// "key1": to.Ptr("value1"),
// "key2": to.Ptr("value2"),
// },
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
*
* @summary asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
* x-ms-original-file: 2026-09-01/StorageAccountCreateEnablePublicNetworkAccess.json
*/
async function storageAccountCreateEnablePublicNetworkAccess() {
const credential = new DefaultAzureCredential();
const subscriptionId = "00000000-0000-0000-0000-000000000000";
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.storageAccounts.create("res9101", "sto4445", {
extendedLocation: { name: "losangeles001", type: "EdgeZone" },
kind: "Storage",
location: "eastus",
allowBlobPublicAccess: false,
allowSharedKeyAccess: true,
encryption: {
keySource: "Microsoft.Storage",
requireInfrastructureEncryption: false,
services: {
blob: { enabled: true, keyType: "Account" },
file: { enabled: true, keyType: "Account" },
},
},
isHnsEnabled: true,
keyPolicy: { keyExpirationPeriodInDays: 20 },
minimumTlsVersion: "TLS1_2",
publicNetworkAccess: "Enabled",
routingPreference: {
publishInternetEndpoints: true,
publishMicrosoftEndpoints: true,
routingChoice: "MicrosoftRouting",
},
sasPolicy: { expirationAction: "Log", sasExpirationPeriod: "1.15:59:59" },
sku: { name: "Standard_GRS" },
tags: { key1: "value1", key2: "value2" },
});
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Voorbeeldrespons
{
"name": "sto4445",
"type": "Microsoft.Storage/storageAccounts",
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445",
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"creationTime": "2017-05-24T13:25:33.4863236Z",
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
},
"file": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
}
}
},
"isHnsEnabled": true,
"keyCreationTime": {
"key1": "2021-03-18T04:42:22.4322836Z",
"key2": "2021-03-18T04:42:22.4322836Z"
},
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"primaryEndpoints": {
"blob": "https://sto4445.blob.core.windows.net/",
"dfs": "https://sto4445.dfs.core.windows.net/",
"file": "https://sto4445.file.core.windows.net/",
"internetEndpoints": {
"blob": "https://sto4445-internetrouting.blob.core.windows.net/",
"dfs": "https://sto4445-internetrouting.dfs.core.windows.net/",
"file": "https://sto4445-internetrouting.file.core.windows.net/",
"web": "https://sto4445-internetrouting.web.core.windows.net/"
},
"microsoftEndpoints": {
"blob": "https://sto4445-microsoftrouting.blob.core.windows.net/",
"dfs": "https://sto4445-microsoftrouting.dfs.core.windows.net/",
"file": "https://sto4445-microsoftrouting.file.core.windows.net/",
"queue": "https://sto4445-microsoftrouting.queue.core.windows.net/",
"table": "https://sto4445-microsoftrouting.table.core.windows.net/",
"web": "https://sto4445-microsoftrouting.web.core.windows.net/"
},
"queue": "https://sto4445.queue.core.windows.net/",
"table": "https://sto4445.table.core.windows.net/",
"web": "https://sto4445.web.core.windows.net/"
},
"primaryLocation": "eastus2euap",
"provisioningState": "Succeeded",
"publicNetworkAccess": "Enabled",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59"
},
"secondaryLocation": "centraluseuap",
"statusOfPrimary": "available",
"statusOfSecondary": "available",
"supportsHttpsTrafficOnly": true
},
"sku": {
"name": "Standard_GRS",
"tier": "Standard"
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
StorageAccountCreatePremiumBlockBlobStorage
Voorbeeldaanvraag
PUT https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445?api-version=2026-09-01
{
"kind": "BlockBlobStorage",
"location": "eastus",
"properties": {
"allowSharedKeyAccess": true,
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account"
},
"file": {
"enabled": true,
"keyType": "Account"
}
}
},
"minimumTlsVersion": "TLS1_2"
},
"sku": {
"name": "Premium_LRS"
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
import com.azure.resourcemanager.storage.models.Encryption;
import com.azure.resourcemanager.storage.models.EncryptionService;
import com.azure.resourcemanager.storage.models.EncryptionServices;
import com.azure.resourcemanager.storage.models.KeySource;
import com.azure.resourcemanager.storage.models.KeyType;
import com.azure.resourcemanager.storage.models.Kind;
import com.azure.resourcemanager.storage.models.MinimumTlsVersion;
import com.azure.resourcemanager.storage.models.Sku;
import com.azure.resourcemanager.storage.models.SkuName;
import com.azure.resourcemanager.storage.models.StorageAccountCreateParameters;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for StorageAccounts Create.
*/
public final class Main {
/*
* x-ms-original-file: 2026-09-01/StorageAccountCreatePremiumBlockBlobStorage.json
*/
/**
* Sample code: StorageAccountCreatePremiumBlockBlobStorage.
*
* @param manager Entry point to StorageManager.
*/
public static void
storageAccountCreatePremiumBlockBlobStorage(com.azure.resourcemanager.storage.StorageManager manager) {
manager.serviceClient().getStorageAccounts().create("res9101", "sto4445",
new StorageAccountCreateParameters().withSku(new Sku().withName(SkuName.PREMIUM_LRS))
.withKind(Kind.BLOCK_BLOB_STORAGE).withLocation("eastus")
.withTags(mapOf("key1", "fakeTokenPlaceholder", "key2", "fakeTokenPlaceholder"))
.withEncryption(new Encryption()
.withServices(new EncryptionServices()
.withBlob(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT))
.withFile(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT)))
.withKeySource(KeySource.MICROSOFT_STORAGE).withRequireInfrastructureEncryption(false))
.withMinimumTlsVersion(MinimumTlsVersion.TLS1_2).withAllowSharedKeyAccess(true),
com.azure.core.util.Context.NONE);
}
// Use "Map.of" if available
@SuppressWarnings("unchecked")
private static <T> Map<String, T> mapOf(Object... inputs) {
Map<String, T> map = new HashMap<>();
for (int i = 0; i < inputs.length; i += 2) {
String key = (String) inputs[i];
T value = (T) inputs[i + 1];
map.put(key, value);
}
return map;
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python storage_account_create_premium_block_blob_storage.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.storage_accounts.begin_create(
resource_group_name="res9101",
account_name="sto4445",
parameters={
"kind": "BlockBlobStorage",
"location": "eastus",
"properties": {
"allowSharedKeyAccess": True,
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": False,
"services": {
"blob": {"enabled": True, "keyType": "Account"},
"file": {"enabled": True, "keyType": "Account"},
},
},
"minimumTlsVersion": "TLS1_2",
},
"sku": {"name": "Premium_LRS"},
"tags": {"key1": "value1", "key2": "value2"},
},
).result()
print(response)
# x-ms-original-file: 2026-09-01/StorageAccountCreatePremiumBlockBlobStorage.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage/v4"
)
// Generated from example definition: 2026-09-01/StorageAccountCreatePremiumBlockBlobStorage.json
func ExampleAccountsClient_BeginCreate_storageAccountCreatePremiumBlockBlobStorage() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewAccountsClient().BeginCreate(ctx, "res9101", "sto4445", armstorage.AccountCreateParameters{
Kind: to.Ptr(armstorage.KindBlockBlobStorage),
Location: to.Ptr("eastus"),
Properties: &armstorage.AccountPropertiesCreateParameters{
AllowSharedKeyAccess: to.Ptr(true),
Encryption: &armstorage.Encryption{
KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
RequireInfrastructureEncryption: to.Ptr(false),
Services: &armstorage.EncryptionServices{
Blob: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
File: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
},
},
MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
},
SKU: &armstorage.SKU{
Name: to.Ptr(armstorage.SKUNamePremiumLRS),
},
Tags: map[string]*string{
"key1": to.Ptr("value1"),
"key2": to.Ptr("value2"),
},
}, nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
log.Fatalf("failed to poll the result: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res = armstorage.AccountsClientCreateResponse{
// Account: armstorage.Account{
// Name: to.Ptr("sto4445"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts"),
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445"),
// Kind: to.Ptr(armstorage.KindStorage),
// Location: to.Ptr("eastus"),
// Properties: &armstorage.AccountProperties{
// AccessTier: to.Ptr(armstorage.AccessTierPremium),
// AllowBlobPublicAccess: to.Ptr(false),
// CreationTime: to.Ptr(time.Date(2017, time.May, 24, 13, 25, 33, 486323600, time.UTC)),
// Encryption: &armstorage.Encryption{
// KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
// RequireInfrastructureEncryption: to.Ptr(false),
// Services: &armstorage.EncryptionServices{
// Blob: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// File: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// },
// },
// MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
// PrimaryEndpoints: &armstorage.Endpoints{
// Blob: to.Ptr("https://sto4445.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445.dfs.core.windows.net/"),
// Web: to.Ptr("https://sto4445.web.core.windows.net/"),
// },
// PrimaryLocation: to.Ptr("eastus2euap"),
// ProvisioningState: to.Ptr(armstorage.ProvisioningStateSucceeded),
// StatusOfPrimary: to.Ptr(armstorage.AccountStatusAvailable),
// StatusOfSecondary: to.Ptr(armstorage.AccountStatusAvailable),
// EnableHTTPSTrafficOnly: to.Ptr(true),
// },
// SKU: &armstorage.SKU{
// Name: to.Ptr(armstorage.SKUNamePremiumLRS),
// Tier: to.Ptr(armstorage.SKUTierPremium),
// },
// Tags: map[string]*string{
// "key1": to.Ptr("value1"),
// "key2": to.Ptr("value2"),
// },
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
*
* @summary asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
* x-ms-original-file: 2026-09-01/StorageAccountCreatePremiumBlockBlobStorage.json
*/
async function storageAccountCreatePremiumBlockBlobStorage() {
const credential = new DefaultAzureCredential();
const subscriptionId = "00000000-0000-0000-0000-000000000000";
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.storageAccounts.create("res9101", "sto4445", {
kind: "BlockBlobStorage",
location: "eastus",
allowSharedKeyAccess: true,
encryption: {
keySource: "Microsoft.Storage",
requireInfrastructureEncryption: false,
services: {
blob: { enabled: true, keyType: "Account" },
file: { enabled: true, keyType: "Account" },
},
},
minimumTlsVersion: "TLS1_2",
sku: { name: "Premium_LRS" },
tags: { key1: "value1", key2: "value2" },
});
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Voorbeeldrespons
{
"name": "sto4445",
"type": "Microsoft.Storage/storageAccounts",
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445",
"kind": "Storage",
"location": "eastus",
"properties": {
"accessTier": "Premium",
"allowBlobPublicAccess": false,
"creationTime": "2017-05-24T13:25:33.4863236Z",
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
},
"file": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
}
}
},
"minimumTlsVersion": "TLS1_2",
"primaryEndpoints": {
"blob": "https://sto4445.blob.core.windows.net/",
"dfs": "https://sto4445.dfs.core.windows.net/",
"web": "https://sto4445.web.core.windows.net/"
},
"primaryLocation": "eastus2euap",
"provisioningState": "Succeeded",
"statusOfPrimary": "available",
"statusOfSecondary": "available",
"supportsHttpsTrafficOnly": true
},
"sku": {
"name": "Premium_LRS",
"tier": "Premium"
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
StorageAccountCreateUserAssignedEncryptionIdentityWithCMK
Voorbeeldaanvraag
PUT https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445?api-version=2026-09-01
{
"identity": {
"type": "UserAssigned",
"userAssignedIdentities": {
"/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}": {}
}
},
"kind": "Storage",
"location": "eastus",
"properties": {
"encryption": {
"identity": {
"userAssignedIdentity": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}"
},
"keySource": "Microsoft.Keyvault",
"keyvaultproperties": {
"keyname": "wrappingKey",
"keyvaulturi": "https://myvault8569.vault.azure.net",
"keyversion": ""
},
"services": {
"blob": {
"enabled": true,
"keyType": "Account"
},
"file": {
"enabled": true,
"keyType": "Account"
}
}
}
},
"sku": {
"name": "Standard_LRS"
}
}
import com.azure.resourcemanager.storage.models.Encryption;
import com.azure.resourcemanager.storage.models.EncryptionIdentity;
import com.azure.resourcemanager.storage.models.EncryptionService;
import com.azure.resourcemanager.storage.models.EncryptionServices;
import com.azure.resourcemanager.storage.models.Identity;
import com.azure.resourcemanager.storage.models.IdentityType;
import com.azure.resourcemanager.storage.models.KeySource;
import com.azure.resourcemanager.storage.models.KeyType;
import com.azure.resourcemanager.storage.models.KeyVaultProperties;
import com.azure.resourcemanager.storage.models.Kind;
import com.azure.resourcemanager.storage.models.Sku;
import com.azure.resourcemanager.storage.models.SkuName;
import com.azure.resourcemanager.storage.models.StorageAccountCreateParameters;
import com.azure.resourcemanager.storage.models.UserAssignedIdentity;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for StorageAccounts Create.
*/
public final class Main {
/*
* x-ms-original-file: 2026-09-01/StorageAccountCreateUserAssignedEncryptionIdentityWithCMK.json
*/
/**
* Sample code: StorageAccountCreateUserAssignedEncryptionIdentityWithCMK.
*
* @param manager Entry point to StorageManager.
*/
public static void storageAccountCreateUserAssignedEncryptionIdentityWithCMK(
com.azure.resourcemanager.storage.StorageManager manager) {
manager.serviceClient().getStorageAccounts().create("res9101", "sto4445", new StorageAccountCreateParameters()
.withSku(new Sku().withName(SkuName.STANDARD_LRS)).withKind(Kind.STORAGE).withLocation("eastus")
.withIdentity(new Identity().withType(IdentityType.USER_ASSIGNED).withUserAssignedIdentities(mapOf(
"/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}",
new UserAssignedIdentity())))
.withEncryption(new Encryption()
.withServices(new EncryptionServices()
.withBlob(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT))
.withFile(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT)))
.withKeySource(KeySource.MICROSOFT_KEYVAULT)
.withKeyVaultProperties(new KeyVaultProperties().withKeyName("fakeTokenPlaceholder")
.withKeyVersion("fakeTokenPlaceholder").withKeyVaultUri("fakeTokenPlaceholder"))
.withEncryptionIdentity(new EncryptionIdentity().withEncryptionUserAssignedIdentity(
"/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}"))),
com.azure.core.util.Context.NONE);
}
// Use "Map.of" if available
@SuppressWarnings("unchecked")
private static <T> Map<String, T> mapOf(Object... inputs) {
Map<String, T> map = new HashMap<>();
for (int i = 0; i < inputs.length; i += 2) {
String key = (String) inputs[i];
T value = (T) inputs[i + 1];
map.put(key, value);
}
return map;
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python storage_account_create_user_assigned_encryption_identity_with_cmk.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.storage_accounts.begin_create(
resource_group_name="res9101",
account_name="sto4445",
parameters={
"identity": {
"type": "UserAssigned",
"userAssignedIdentities": {
"/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}": {}
},
},
"kind": "Storage",
"location": "eastus",
"properties": {
"encryption": {
"identity": {
"userAssignedIdentity": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}"
},
"keySource": "Microsoft.Keyvault",
"keyvaultproperties": {
"keyname": "wrappingKey",
"keyvaulturi": "https://myvault8569.vault.azure.net",
"keyversion": "",
},
"services": {
"blob": {"enabled": True, "keyType": "Account"},
"file": {"enabled": True, "keyType": "Account"},
},
}
},
"sku": {"name": "Standard_LRS"},
},
).result()
print(response)
# x-ms-original-file: 2026-09-01/StorageAccountCreateUserAssignedEncryptionIdentityWithCMK.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage/v4"
)
// Generated from example definition: 2026-09-01/StorageAccountCreateUserAssignedEncryptionIdentityWithCMK.json
func ExampleAccountsClient_BeginCreate_storageAccountCreateUserAssignedEncryptionIdentityWithCmk() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewAccountsClient().BeginCreate(ctx, "res9101", "sto4445", armstorage.AccountCreateParameters{
Identity: &armstorage.Identity{
Type: to.Ptr(armstorage.IdentityTypeUserAssigned),
UserAssignedIdentities: map[string]*armstorage.UserAssignedIdentity{
"/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}": {},
},
},
Kind: to.Ptr(armstorage.KindStorage),
Location: to.Ptr("eastus"),
Properties: &armstorage.AccountPropertiesCreateParameters{
Encryption: &armstorage.Encryption{
EncryptionIdentity: &armstorage.EncryptionIdentity{
EncryptionUserAssignedIdentity: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}"),
},
KeySource: to.Ptr(armstorage.KeySourceMicrosoftKeyvault),
KeyVaultProperties: &armstorage.KeyVaultProperties{
KeyName: to.Ptr("wrappingKey"),
KeyVaultURI: to.Ptr("https://myvault8569.vault.azure.net"),
KeyVersion: to.Ptr(""),
},
Services: &armstorage.EncryptionServices{
Blob: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
File: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
},
},
},
SKU: &armstorage.SKU{
Name: to.Ptr(armstorage.SKUNameStandardLRS),
},
}, nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
log.Fatalf("failed to poll the result: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res = armstorage.AccountsClientCreateResponse{
// Account: armstorage.Account{
// Name: to.Ptr("sto4445"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts"),
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445"),
// Identity: &armstorage.Identity{
// Type: to.Ptr(armstorage.IdentityTypeUserAssigned),
// UserAssignedIdentities: map[string]*armstorage.UserAssignedIdentity{
// "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}": &armstorage.UserAssignedIdentity{
// ClientID: to.Ptr("fbaa6278-1ecc-415c-819f-6e2058d3acb5"),
// PrincipalID: to.Ptr("8d823284-1060-42a5-9ec4-ed3d831e24d7"),
// },
// },
// },
// Kind: to.Ptr(armstorage.KindStorageV2),
// Location: to.Ptr("eastus"),
// Properties: &armstorage.AccountProperties{
// AccessTier: to.Ptr(armstorage.AccessTierHot),
// CreationTime: to.Ptr(time.Date(2020, time.December, 15, 0, 43, 14, 83909300, time.UTC)),
// Encryption: &armstorage.Encryption{
// EncryptionIdentity: &armstorage.EncryptionIdentity{
// EncryptionUserAssignedIdentity: to.Ptr("/subscriptions/{subscription-id}/resourcegroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}"),
// },
// KeySource: to.Ptr(armstorage.KeySourceMicrosoftKeyvault),
// KeyVaultProperties: &armstorage.KeyVaultProperties{
// CurrentVersionedKeyIdentifier: to.Ptr("https://myvault8569.vault.azure.net/keys/wrappingKey/0682afdd9c104f4285df20107e956cad"),
// KeyName: to.Ptr("wrappingKey"),
// KeyVaultURI: to.Ptr("https://myvault8569.vault.azure.net"),
// KeyVersion: to.Ptr(""),
// LastKeyRotationTimestamp: to.Ptr(time.Date(2019, time.December, 13, 20, 36, 23, 702329000, time.UTC)),
// },
// Services: &armstorage.EncryptionServices{
// Blob: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2020, time.December, 15, 0, 43, 14, 173958700, time.UTC)),
// },
// File: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2020, time.December, 15, 0, 43, 14, 173958700, time.UTC)),
// },
// },
// },
// NetworkRuleSet: &armstorage.NetworkRuleSet{
// Bypass: to.Ptr(armstorage.BypassAzureServices),
// DefaultAction: to.Ptr(armstorage.DefaultActionAllow),
// IPRules: []*armstorage.IPRule{
// },
// VirtualNetworkRules: []*armstorage.VirtualNetworkRule{
// },
// },
// PrimaryEndpoints: &armstorage.Endpoints{
// Blob: to.Ptr("https://sto4445.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445.file.core.windows.net/"),
// Queue: to.Ptr("https://sto4445.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445.web.core.windows.net/"),
// },
// PrimaryLocation: to.Ptr("eastus"),
// PrivateEndpointConnections: []*armstorage.PrivateEndpointConnection{
// },
// ProvisioningState: to.Ptr(armstorage.ProvisioningStateSucceeded),
// StatusOfPrimary: to.Ptr(armstorage.AccountStatusAvailable),
// EnableHTTPSTrafficOnly: to.Ptr(true),
// },
// SKU: &armstorage.SKU{
// Name: to.Ptr(armstorage.SKUNameStandardLRS),
// Tier: to.Ptr(armstorage.SKUTierStandard),
// },
// Tags: map[string]*string{
// },
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
*
* @summary asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
* x-ms-original-file: 2026-09-01/StorageAccountCreateUserAssignedEncryptionIdentityWithCMK.json
*/
async function storageAccountCreateUserAssignedEncryptionIdentityWithCMK() {
const credential = new DefaultAzureCredential();
const subscriptionId = "00000000-0000-0000-0000-000000000000";
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.storageAccounts.create("res9101", "sto4445", {
identity: {
type: "UserAssigned",
userAssignedIdentities: {
"/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}":
{},
},
},
kind: "Storage",
location: "eastus",
encryption: {
encryptionIdentity: {
encryptionUserAssignedIdentity:
"/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}",
},
keySource: "Microsoft.Keyvault",
keyVaultProperties: {
keyName: "wrappingKey",
keyVaultUri: "https://myvault8569.vault.azure.net",
keyVersion: "",
},
services: {
blob: { enabled: true, keyType: "Account" },
file: { enabled: true, keyType: "Account" },
},
},
sku: { name: "Standard_LRS" },
});
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Voorbeeldrespons
{
"name": "sto4445",
"type": "Microsoft.Storage/storageAccounts",
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445",
"identity": {
"type": "UserAssigned",
"userAssignedIdentities": {
"/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}": {
"clientId": "fbaa6278-1ecc-415c-819f-6e2058d3acb5",
"principalId": "8d823284-1060-42a5-9ec4-ed3d831e24d7"
}
}
},
"kind": "StorageV2",
"location": "eastus",
"properties": {
"accessTier": "Hot",
"creationTime": "2020-12-15T00:43:14.0839093Z",
"encryption": {
"identity": {
"userAssignedIdentity": "/subscriptions/{subscription-id}/resourcegroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}"
},
"keySource": "Microsoft.Keyvault",
"keyvaultproperties": {
"currentVersionedKeyIdentifier": "https://myvault8569.vault.azure.net/keys/wrappingKey/0682afdd9c104f4285df20107e956cad",
"keyname": "wrappingKey",
"keyvaulturi": "https://myvault8569.vault.azure.net",
"keyversion": "",
"lastKeyRotationTimestamp": "2019-12-13T20:36:23.7023290Z"
},
"services": {
"blob": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2020-12-15T00:43:14.1739587Z"
},
"file": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2020-12-15T00:43:14.1739587Z"
}
}
},
"networkAcls": {
"bypass": "AzureServices",
"defaultAction": "Allow",
"ipRules": [],
"virtualNetworkRules": []
},
"primaryEndpoints": {
"blob": "https://sto4445.blob.core.windows.net/",
"dfs": "https://sto4445.dfs.core.windows.net/",
"file": "https://sto4445.file.core.windows.net/",
"queue": "https://sto4445.queue.core.windows.net/",
"table": "https://sto4445.table.core.windows.net/",
"web": "https://sto4445.web.core.windows.net/"
},
"primaryLocation": "eastus",
"privateEndpointConnections": [],
"provisioningState": "Succeeded",
"statusOfPrimary": "available",
"supportsHttpsTrafficOnly": true
},
"sku": {
"name": "Standard_LRS",
"tier": "Standard"
},
"tags": {}
}
StorageAccountCreateUserAssignedIdentityWithFederatedIdentityClientId.
Voorbeeldaanvraag
PUT https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/res131918/providers/Microsoft.Storage/storageAccounts/sto131918?api-version=2026-09-01
{
"identity": {
"type": "UserAssigned",
"userAssignedIdentities": {
"/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}": {}
}
},
"kind": "Storage",
"location": "eastus",
"properties": {
"encryption": {
"identity": {
"federatedIdentityClientId": "f83c6b1b-4d34-47e4-bb34-9d83df58b540",
"userAssignedIdentity": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}"
},
"keySource": "Microsoft.Keyvault",
"keyvaultproperties": {
"keyname": "wrappingKey",
"keyvaulturi": "https://myvault8569.vault.azure.net",
"keyversion": ""
},
"services": {
"blob": {
"enabled": true,
"keyType": "Account"
},
"file": {
"enabled": true,
"keyType": "Account"
}
}
}
},
"sku": {
"name": "Standard_LRS"
}
}
import com.azure.resourcemanager.storage.models.Encryption;
import com.azure.resourcemanager.storage.models.EncryptionIdentity;
import com.azure.resourcemanager.storage.models.EncryptionService;
import com.azure.resourcemanager.storage.models.EncryptionServices;
import com.azure.resourcemanager.storage.models.Identity;
import com.azure.resourcemanager.storage.models.IdentityType;
import com.azure.resourcemanager.storage.models.KeySource;
import com.azure.resourcemanager.storage.models.KeyType;
import com.azure.resourcemanager.storage.models.KeyVaultProperties;
import com.azure.resourcemanager.storage.models.Kind;
import com.azure.resourcemanager.storage.models.Sku;
import com.azure.resourcemanager.storage.models.SkuName;
import com.azure.resourcemanager.storage.models.StorageAccountCreateParameters;
import com.azure.resourcemanager.storage.models.UserAssignedIdentity;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for StorageAccounts Create.
*/
public final class Main {
/*
* x-ms-original-file: 2026-09-01/StorageAccountCreateUserAssignedIdentityWithFederatedIdentityClientId.json
*/
/**
* Sample code: StorageAccountCreateUserAssignedIdentityWithFederatedIdentityClientId.
*
* @param manager Entry point to StorageManager.
*/
public static void storageAccountCreateUserAssignedIdentityWithFederatedIdentityClientId(
com.azure.resourcemanager.storage.StorageManager manager) {
manager.serviceClient().getStorageAccounts().create("res131918", "sto131918",
new StorageAccountCreateParameters().withSku(new Sku().withName(SkuName.STANDARD_LRS))
.withKind(Kind.STORAGE).withLocation("eastus")
.withIdentity(new Identity().withType(IdentityType.USER_ASSIGNED).withUserAssignedIdentities(mapOf(
"/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}",
new UserAssignedIdentity())))
.withEncryption(new Encryption()
.withServices(new EncryptionServices()
.withBlob(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT))
.withFile(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT)))
.withKeySource(KeySource.MICROSOFT_KEYVAULT)
.withKeyVaultProperties(new KeyVaultProperties().withKeyName("fakeTokenPlaceholder")
.withKeyVersion("fakeTokenPlaceholder").withKeyVaultUri("fakeTokenPlaceholder"))
.withEncryptionIdentity(new EncryptionIdentity().withEncryptionUserAssignedIdentity(
"/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}")
.withEncryptionFederatedIdentityClientId("f83c6b1b-4d34-47e4-bb34-9d83df58b540"))),
com.azure.core.util.Context.NONE);
}
// Use "Map.of" if available
@SuppressWarnings("unchecked")
private static <T> Map<String, T> mapOf(Object... inputs) {
Map<String, T> map = new HashMap<>();
for (int i = 0; i < inputs.length; i += 2) {
String key = (String) inputs[i];
T value = (T) inputs[i + 1];
map.put(key, value);
}
return map;
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python storage_account_create_user_assigned_identity_with_federated_identity_client_id.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.storage_accounts.begin_create(
resource_group_name="res131918",
account_name="sto131918",
parameters={
"identity": {
"type": "UserAssigned",
"userAssignedIdentities": {
"/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}": {}
},
},
"kind": "Storage",
"location": "eastus",
"properties": {
"encryption": {
"identity": {
"federatedIdentityClientId": "f83c6b1b-4d34-47e4-bb34-9d83df58b540",
"userAssignedIdentity": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}",
},
"keySource": "Microsoft.Keyvault",
"keyvaultproperties": {
"keyname": "wrappingKey",
"keyvaulturi": "https://myvault8569.vault.azure.net",
"keyversion": "",
},
"services": {
"blob": {"enabled": True, "keyType": "Account"},
"file": {"enabled": True, "keyType": "Account"},
},
}
},
"sku": {"name": "Standard_LRS"},
},
).result()
print(response)
# x-ms-original-file: 2026-09-01/StorageAccountCreateUserAssignedIdentityWithFederatedIdentityClientId.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage/v4"
)
// Generated from example definition: 2026-09-01/StorageAccountCreateUserAssignedIdentityWithFederatedIdentityClientId.json
func ExampleAccountsClient_BeginCreate_storageAccountCreateUserAssignedIdentityWithFederatedIdentityClientId() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewAccountsClient().BeginCreate(ctx, "res131918", "sto131918", armstorage.AccountCreateParameters{
Identity: &armstorage.Identity{
Type: to.Ptr(armstorage.IdentityTypeUserAssigned),
UserAssignedIdentities: map[string]*armstorage.UserAssignedIdentity{
"/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}": {},
},
},
Kind: to.Ptr(armstorage.KindStorage),
Location: to.Ptr("eastus"),
Properties: &armstorage.AccountPropertiesCreateParameters{
Encryption: &armstorage.Encryption{
EncryptionIdentity: &armstorage.EncryptionIdentity{
EncryptionFederatedIdentityClientID: to.Ptr("f83c6b1b-4d34-47e4-bb34-9d83df58b540"),
EncryptionUserAssignedIdentity: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}"),
},
KeySource: to.Ptr(armstorage.KeySourceMicrosoftKeyvault),
KeyVaultProperties: &armstorage.KeyVaultProperties{
KeyName: to.Ptr("wrappingKey"),
KeyVaultURI: to.Ptr("https://myvault8569.vault.azure.net"),
KeyVersion: to.Ptr(""),
},
Services: &armstorage.EncryptionServices{
Blob: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
File: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
},
},
},
SKU: &armstorage.SKU{
Name: to.Ptr(armstorage.SKUNameStandardLRS),
},
}, nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
log.Fatalf("failed to poll the result: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res = armstorage.AccountsClientCreateResponse{
// Account: armstorage.Account{
// Name: to.Ptr("sto4445"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts"),
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445"),
// Identity: &armstorage.Identity{
// Type: to.Ptr(armstorage.IdentityTypeUserAssigned),
// UserAssignedIdentities: map[string]*armstorage.UserAssignedIdentity{
// "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}": &armstorage.UserAssignedIdentity{
// ClientID: to.Ptr("fbaa6278-1ecc-415c-819f-6e2058d3acb5"),
// PrincipalID: to.Ptr("8d823284-1060-42a5-9ec4-ed3d831e24d7"),
// },
// },
// },
// Kind: to.Ptr(armstorage.KindStorageV2),
// Location: to.Ptr("eastus"),
// Properties: &armstorage.AccountProperties{
// AccessTier: to.Ptr(armstorage.AccessTierHot),
// CreationTime: to.Ptr(time.Date(2020, time.December, 15, 0, 43, 14, 83909300, time.UTC)),
// Encryption: &armstorage.Encryption{
// EncryptionIdentity: &armstorage.EncryptionIdentity{
// EncryptionFederatedIdentityClientID: to.Ptr("f83c6b1b-4d34-47e4-bb34-9d83df58b540"),
// EncryptionUserAssignedIdentity: to.Ptr("/subscriptions/{subscription-id}/resourcegroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}"),
// },
// KeySource: to.Ptr(armstorage.KeySourceMicrosoftKeyvault),
// KeyVaultProperties: &armstorage.KeyVaultProperties{
// CurrentVersionedKeyIdentifier: to.Ptr("https://myvault8569.vault.azure.net/keys/wrappingKey/0682afdd9c104f4285df20107e956cad"),
// KeyName: to.Ptr("wrappingKey"),
// KeyVaultURI: to.Ptr("https://myvault8569.vault.azure.net"),
// KeyVersion: to.Ptr(""),
// LastKeyRotationTimestamp: to.Ptr(time.Date(2019, time.December, 13, 20, 36, 23, 702329000, time.UTC)),
// },
// Services: &armstorage.EncryptionServices{
// Blob: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2020, time.December, 15, 0, 43, 14, 173958700, time.UTC)),
// },
// File: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2020, time.December, 15, 0, 43, 14, 173958700, time.UTC)),
// },
// },
// },
// NetworkRuleSet: &armstorage.NetworkRuleSet{
// Bypass: to.Ptr(armstorage.BypassAzureServices),
// DefaultAction: to.Ptr(armstorage.DefaultActionAllow),
// IPRules: []*armstorage.IPRule{
// },
// VirtualNetworkRules: []*armstorage.VirtualNetworkRule{
// },
// },
// PrimaryEndpoints: &armstorage.Endpoints{
// Blob: to.Ptr("https://sto4445.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445.file.core.windows.net/"),
// Queue: to.Ptr("https://sto4445.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445.web.core.windows.net/"),
// },
// PrimaryLocation: to.Ptr("eastus"),
// PrivateEndpointConnections: []*armstorage.PrivateEndpointConnection{
// },
// ProvisioningState: to.Ptr(armstorage.ProvisioningStateSucceeded),
// StatusOfPrimary: to.Ptr(armstorage.AccountStatusAvailable),
// EnableHTTPSTrafficOnly: to.Ptr(true),
// },
// SKU: &armstorage.SKU{
// Name: to.Ptr(armstorage.SKUNameStandardLRS),
// Tier: to.Ptr(armstorage.SKUTierStandard),
// },
// Tags: map[string]*string{
// },
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
*
* @summary asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
* x-ms-original-file: 2026-09-01/StorageAccountCreateUserAssignedIdentityWithFederatedIdentityClientId.json
*/
async function storageAccountCreateUserAssignedIdentityWithFederatedIdentityClientId() {
const credential = new DefaultAzureCredential();
const subscriptionId = "00000000-0000-0000-0000-000000000000";
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.storageAccounts.create("res131918", "sto131918", {
identity: {
type: "UserAssigned",
userAssignedIdentities: {
"/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}":
{},
},
},
kind: "Storage",
location: "eastus",
encryption: {
encryptionIdentity: {
encryptionFederatedIdentityClientId: "f83c6b1b-4d34-47e4-bb34-9d83df58b540",
encryptionUserAssignedIdentity:
"/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}",
},
keySource: "Microsoft.Keyvault",
keyVaultProperties: {
keyName: "wrappingKey",
keyVaultUri: "https://myvault8569.vault.azure.net",
keyVersion: "",
},
services: {
blob: { enabled: true, keyType: "Account" },
file: { enabled: true, keyType: "Account" },
},
},
sku: { name: "Standard_LRS" },
});
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Voorbeeldrespons
{
"name": "sto4445",
"type": "Microsoft.Storage/storageAccounts",
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445",
"identity": {
"type": "UserAssigned",
"userAssignedIdentities": {
"/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}": {
"clientId": "fbaa6278-1ecc-415c-819f-6e2058d3acb5",
"principalId": "8d823284-1060-42a5-9ec4-ed3d831e24d7"
}
}
},
"kind": "StorageV2",
"location": "eastus",
"properties": {
"accessTier": "Hot",
"creationTime": "2020-12-15T00:43:14.0839093Z",
"encryption": {
"identity": {
"federatedIdentityClientId": "f83c6b1b-4d34-47e4-bb34-9d83df58b540",
"userAssignedIdentity": "/subscriptions/{subscription-id}/resourcegroups/res9101/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{managed-identity-name}"
},
"keySource": "Microsoft.Keyvault",
"keyvaultproperties": {
"currentVersionedKeyIdentifier": "https://myvault8569.vault.azure.net/keys/wrappingKey/0682afdd9c104f4285df20107e956cad",
"keyname": "wrappingKey",
"keyvaulturi": "https://myvault8569.vault.azure.net",
"keyversion": "",
"lastKeyRotationTimestamp": "2019-12-13T20:36:23.7023290Z"
},
"services": {
"blob": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2020-12-15T00:43:14.1739587Z"
},
"file": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2020-12-15T00:43:14.1739587Z"
}
}
},
"networkAcls": {
"bypass": "AzureServices",
"defaultAction": "Allow",
"ipRules": [],
"virtualNetworkRules": []
},
"primaryEndpoints": {
"blob": "https://sto4445.blob.core.windows.net/",
"dfs": "https://sto4445.dfs.core.windows.net/",
"file": "https://sto4445.file.core.windows.net/",
"queue": "https://sto4445.queue.core.windows.net/",
"table": "https://sto4445.table.core.windows.net/",
"web": "https://sto4445.web.core.windows.net/"
},
"primaryLocation": "eastus",
"privateEndpointConnections": [],
"provisioningState": "Succeeded",
"statusOfPrimary": "available",
"supportsHttpsTrafficOnly": true
},
"sku": {
"name": "Standard_LRS",
"tier": "Standard"
},
"tags": {}
}
StorageAccountCreateWithDataCollaborationPolicy
Voorbeeldaanvraag
PUT https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445?api-version=2026-09-01
{
"kind": "Storage",
"location": "eastus",
"properties": {
"dataCollaborationPolicyProperties": {
"allowStorageConnectors": true,
"allowStorageDataShares": true,
"allowCrossTenantDataSharing": false
}
},
"sku": {
"name": "Standard_GRS"
}
}
import com.azure.resourcemanager.storage.models.Kind;
import com.azure.resourcemanager.storage.models.Sku;
import com.azure.resourcemanager.storage.models.SkuName;
import com.azure.resourcemanager.storage.models.StorageAccountCreateParameters;
import com.azure.resourcemanager.storage.models.StorageDataCollaborationPolicyProperties;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for StorageAccounts Create.
*/
public final class Main {
/*
* x-ms-original-file: 2026-09-01/StorageAccountCreateWithDataCollaborationPolicy.json
*/
/**
* Sample code: StorageAccountCreateWithDataCollaborationPolicy.
*
* @param manager Entry point to StorageManager.
*/
public static void
storageAccountCreateWithDataCollaborationPolicy(com.azure.resourcemanager.storage.StorageManager manager) {
manager.serviceClient().getStorageAccounts().create("res9101", "sto4445",
new StorageAccountCreateParameters().withSku(new Sku().withName(SkuName.STANDARD_GRS))
.withKind(Kind.STORAGE).withLocation("eastus").withDataCollaborationPolicyProperties(
new StorageDataCollaborationPolicyProperties().withAllowStorageConnectors(true)
.withAllowStorageDataShares(true).withAllowCrossTenantDataSharing(false)),
com.azure.core.util.Context.NONE);
}
// Use "Map.of" if available
@SuppressWarnings("unchecked")
private static <T> Map<String, T> mapOf(Object... inputs) {
Map<String, T> map = new HashMap<>();
for (int i = 0; i < inputs.length; i += 2) {
String key = (String) inputs[i];
T value = (T) inputs[i + 1];
map.put(key, value);
}
return map;
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python storage_account_create_with_data_collaboration_policy.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.storage_accounts.begin_create(
resource_group_name="res9101",
account_name="sto4445",
parameters={
"kind": "Storage",
"location": "eastus",
"properties": {
"dataCollaborationPolicyProperties": {
"allowCrossTenantDataSharing": False,
"allowStorageConnectors": True,
"allowStorageDataShares": True,
}
},
"sku": {"name": "Standard_GRS"},
},
).result()
print(response)
# x-ms-original-file: 2026-09-01/StorageAccountCreateWithDataCollaborationPolicy.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage/v4"
)
// Generated from example definition: 2026-09-01/StorageAccountCreateWithDataCollaborationPolicy.json
func ExampleAccountsClient_BeginCreate_storageAccountCreateWithDataCollaborationPolicy() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewAccountsClient().BeginCreate(ctx, "res9101", "sto4445", armstorage.AccountCreateParameters{
Kind: to.Ptr(armstorage.KindStorage),
Location: to.Ptr("eastus"),
Properties: &armstorage.AccountPropertiesCreateParameters{
DataCollaborationPolicyProperties: &armstorage.DataCollaborationPolicyProperties{
AllowStorageConnectors: to.Ptr(true),
AllowStorageDataShares: to.Ptr(true),
AllowCrossTenantDataSharing: to.Ptr(false),
},
},
SKU: &armstorage.SKU{
Name: to.Ptr(armstorage.SKUNameStandardGRS),
},
}, nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
log.Fatalf("failed to poll the result: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res = armstorage.AccountsClientCreateResponse{
// Account: armstorage.Account{
// Name: to.Ptr("sto4445"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts"),
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445"),
// Kind: to.Ptr(armstorage.KindStorage),
// Location: to.Ptr("eastus"),
// Properties: &armstorage.AccountProperties{
// CreationTime: to.Ptr(time.Date(2017, time.May, 24, 13, 25, 33, 486323600, time.UTC)),
// PrimaryEndpoints: &armstorage.Endpoints{
// Blob: to.Ptr("https://sto4445.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445.file.core.windows.net/"),
// Queue: to.Ptr("https://sto4445.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445.web.core.windows.net/"),
// },
// PrimaryLocation: to.Ptr("eastus2euap"),
// ProvisioningState: to.Ptr(armstorage.ProvisioningStateSucceeded),
// DataCollaborationPolicyProperties: &armstorage.DataCollaborationPolicyProperties{
// AllowStorageConnectors: to.Ptr(true),
// AllowStorageDataShares: to.Ptr(true),
// AllowCrossTenantDataSharing: to.Ptr(false),
// },
// },
// SKU: &armstorage.SKU{
// Name: to.Ptr(armstorage.SKUNameStandardGRS),
// Tier: to.Ptr(armstorage.SKUTierStandard),
// },
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
*
* @summary asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
* x-ms-original-file: 2026-09-01/StorageAccountCreateWithDataCollaborationPolicy.json
*/
async function storageAccountCreateWithDataCollaborationPolicy() {
const credential = new DefaultAzureCredential();
const subscriptionId = "00000000-0000-0000-0000-000000000000";
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.storageAccounts.create("res9101", "sto4445", {
kind: "Storage",
location: "eastus",
dataCollaborationPolicyProperties: {
allowStorageConnectors: true,
allowStorageDataShares: true,
allowCrossTenantDataSharing: false,
},
sku: { name: "Standard_GRS" },
});
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Voorbeeldrespons
{
"name": "sto4445",
"type": "Microsoft.Storage/storageAccounts",
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445",
"kind": "Storage",
"location": "eastus",
"properties": {
"creationTime": "2017-05-24T13:25:33.4863236Z",
"primaryEndpoints": {
"blob": "https://sto4445.blob.core.windows.net/",
"dfs": "https://sto4445.dfs.core.windows.net/",
"file": "https://sto4445.file.core.windows.net/",
"queue": "https://sto4445.queue.core.windows.net/",
"table": "https://sto4445.table.core.windows.net/",
"web": "https://sto4445.web.core.windows.net/"
},
"primaryLocation": "eastus2euap",
"provisioningState": "Succeeded",
"dataCollaborationPolicyProperties": {
"allowStorageConnectors": true,
"allowStorageDataShares": true,
"allowCrossTenantDataSharing": false
}
},
"sku": {
"name": "Standard_GRS",
"tier": "Standard"
}
}
StorageAccountCreateWithImmutabilityPolicy
Voorbeeldaanvraag
PUT https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445?api-version=2026-09-01
{
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"kind": "Storage",
"location": "eastus",
"properties": {
"immutableStorageWithVersioning": {
"enabled": true,
"immutabilityPolicy": {
"allowProtectedAppendWrites": true,
"immutabilityPeriodSinceCreationInDays": 15,
"state": "Unlocked"
}
}
},
"sku": {
"name": "Standard_GRS"
}
}
import com.azure.resourcemanager.storage.models.AccountImmutabilityPolicyProperties;
import com.azure.resourcemanager.storage.models.AccountImmutabilityPolicyState;
import com.azure.resourcemanager.storage.models.ExtendedLocation;
import com.azure.resourcemanager.storage.models.ExtendedLocationTypes;
import com.azure.resourcemanager.storage.models.ImmutableStorageAccount;
import com.azure.resourcemanager.storage.models.Kind;
import com.azure.resourcemanager.storage.models.Sku;
import com.azure.resourcemanager.storage.models.SkuName;
import com.azure.resourcemanager.storage.models.StorageAccountCreateParameters;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for StorageAccounts Create.
*/
public final class Main {
/*
* x-ms-original-file: 2026-09-01/StorageAccountCreateWithImmutabilityPolicy.json
*/
/**
* Sample code: StorageAccountCreateWithImmutabilityPolicy.
*
* @param manager Entry point to StorageManager.
*/
public static void
storageAccountCreateWithImmutabilityPolicy(com.azure.resourcemanager.storage.StorageManager manager) {
manager.serviceClient().getStorageAccounts()
.create("res9101", "sto4445",
new StorageAccountCreateParameters().withSku(new Sku().withName(SkuName.STANDARD_GRS))
.withKind(Kind.STORAGE).withLocation("eastus")
.withExtendedLocation(
new ExtendedLocation().withName("losangeles001").withType(ExtendedLocationTypes.EDGE_ZONE))
.withImmutableStorageWithVersioning(new ImmutableStorageAccount().withEnabled(true)
.withImmutabilityPolicy(new AccountImmutabilityPolicyProperties()
.withImmutabilityPeriodSinceCreationInDays(15)
.withState(AccountImmutabilityPolicyState.UNLOCKED).withAllowProtectedAppendWrites(true))),
com.azure.core.util.Context.NONE);
}
// Use "Map.of" if available
@SuppressWarnings("unchecked")
private static <T> Map<String, T> mapOf(Object... inputs) {
Map<String, T> map = new HashMap<>();
for (int i = 0; i < inputs.length; i += 2) {
String key = (String) inputs[i];
T value = (T) inputs[i + 1];
map.put(key, value);
}
return map;
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python storage_account_create_with_immutability_policy.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.storage_accounts.begin_create(
resource_group_name="res9101",
account_name="sto4445",
parameters={
"extendedLocation": {"name": "losangeles001", "type": "EdgeZone"},
"kind": "Storage",
"location": "eastus",
"properties": {
"immutableStorageWithVersioning": {
"enabled": True,
"immutabilityPolicy": {
"allowProtectedAppendWrites": True,
"immutabilityPeriodSinceCreationInDays": 15,
"state": "Unlocked",
},
}
},
"sku": {"name": "Standard_GRS"},
},
).result()
print(response)
# x-ms-original-file: 2026-09-01/StorageAccountCreateWithImmutabilityPolicy.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage/v4"
)
// Generated from example definition: 2026-09-01/StorageAccountCreateWithImmutabilityPolicy.json
func ExampleAccountsClient_BeginCreate_storageAccountCreateWithImmutabilityPolicy() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewAccountsClient().BeginCreate(ctx, "res9101", "sto4445", armstorage.AccountCreateParameters{
ExtendedLocation: &armstorage.ExtendedLocation{
Name: to.Ptr("losangeles001"),
Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
},
Kind: to.Ptr(armstorage.KindStorage),
Location: to.Ptr("eastus"),
Properties: &armstorage.AccountPropertiesCreateParameters{
ImmutableStorageWithVersioning: &armstorage.ImmutableStorageAccount{
Enabled: to.Ptr(true),
ImmutabilityPolicy: &armstorage.AccountImmutabilityPolicyProperties{
AllowProtectedAppendWrites: to.Ptr(true),
ImmutabilityPeriodSinceCreationInDays: to.Ptr[int32](15),
State: to.Ptr(armstorage.AccountImmutabilityPolicyStateUnlocked),
},
},
},
SKU: &armstorage.SKU{
Name: to.Ptr(armstorage.SKUNameStandardGRS),
},
}, nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
log.Fatalf("failed to poll the result: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res = armstorage.AccountsClientCreateResponse{
// Account: armstorage.Account{
// Name: to.Ptr("sto4445"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts"),
// ExtendedLocation: &armstorage.ExtendedLocation{
// Name: to.Ptr("losangeles001"),
// Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
// },
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445"),
// Kind: to.Ptr(armstorage.KindStorage),
// Location: to.Ptr("eastus"),
// Properties: &armstorage.AccountProperties{
// CreationTime: to.Ptr(time.Date(2017, time.May, 24, 13, 25, 33, 486323600, time.UTC)),
// ImmutableStorageWithVersioning: &armstorage.ImmutableStorageAccount{
// Enabled: to.Ptr(true),
// ImmutabilityPolicy: &armstorage.AccountImmutabilityPolicyProperties{
// AllowProtectedAppendWrites: to.Ptr(true),
// ImmutabilityPeriodSinceCreationInDays: to.Ptr[int32](15),
// State: to.Ptr(armstorage.AccountImmutabilityPolicyStateUnlocked),
// },
// },
// PrimaryEndpoints: &armstorage.Endpoints{
// Blob: to.Ptr("https://sto4445.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445.file.core.windows.net/"),
// Queue: to.Ptr("https://sto4445.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445.web.core.windows.net/"),
// },
// PrimaryLocation: to.Ptr("eastus2euap"),
// ProvisioningState: to.Ptr(armstorage.ProvisioningStateSucceeded),
// },
// SKU: &armstorage.SKU{
// Name: to.Ptr(armstorage.SKUNameStandardGRS),
// Tier: to.Ptr(armstorage.SKUTierStandard),
// },
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
*
* @summary asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
* x-ms-original-file: 2026-09-01/StorageAccountCreateWithImmutabilityPolicy.json
*/
async function storageAccountCreateWithImmutabilityPolicy() {
const credential = new DefaultAzureCredential();
const subscriptionId = "00000000-0000-0000-0000-000000000000";
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.storageAccounts.create("res9101", "sto4445", {
extendedLocation: { name: "losangeles001", type: "EdgeZone" },
kind: "Storage",
location: "eastus",
immutableStorageWithVersioning: {
enabled: true,
immutabilityPolicy: {
allowProtectedAppendWrites: true,
immutabilityPeriodSinceCreationInDays: 15,
state: "Unlocked",
},
},
sku: { name: "Standard_GRS" },
});
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Voorbeeldrespons
{
"name": "sto4445",
"type": "Microsoft.Storage/storageAccounts",
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445",
"kind": "Storage",
"location": "eastus",
"properties": {
"creationTime": "2017-05-24T13:25:33.4863236Z",
"immutableStorageWithVersioning": {
"enabled": true,
"immutabilityPolicy": {
"allowProtectedAppendWrites": true,
"immutabilityPeriodSinceCreationInDays": 15,
"state": "Unlocked"
}
},
"primaryEndpoints": {
"blob": "https://sto4445.blob.core.windows.net/",
"dfs": "https://sto4445.dfs.core.windows.net/",
"file": "https://sto4445.file.core.windows.net/",
"queue": "https://sto4445.queue.core.windows.net/",
"table": "https://sto4445.table.core.windows.net/",
"web": "https://sto4445.web.core.windows.net/"
},
"primaryLocation": "eastus2euap",
"provisioningState": "Succeeded"
},
"sku": {
"name": "Standard_GRS",
"tier": "Standard"
}
}
StorageAccountCreateWithSmartAccessTier
Voorbeeldaanvraag
PUT https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445?api-version=2026-09-01
{
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"kind": "Storage",
"location": "eastus",
"properties": {
"accessTier": "Smart",
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"defaultToOAuthAuthentication": false,
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account"
},
"file": {
"enabled": true,
"keyType": "Account"
}
}
},
"isHnsEnabled": true,
"isSftpEnabled": true,
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59"
},
"geoPriorityReplicationStatus": {
"isBlobEnabled": true
}
},
"sku": {
"name": "Standard_GRS"
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
import com.azure.resourcemanager.storage.models.AccessTier;
import com.azure.resourcemanager.storage.models.Encryption;
import com.azure.resourcemanager.storage.models.EncryptionService;
import com.azure.resourcemanager.storage.models.EncryptionServices;
import com.azure.resourcemanager.storage.models.ExpirationAction;
import com.azure.resourcemanager.storage.models.ExtendedLocation;
import com.azure.resourcemanager.storage.models.ExtendedLocationTypes;
import com.azure.resourcemanager.storage.models.GeoPriorityReplicationStatus;
import com.azure.resourcemanager.storage.models.KeyPolicy;
import com.azure.resourcemanager.storage.models.KeySource;
import com.azure.resourcemanager.storage.models.KeyType;
import com.azure.resourcemanager.storage.models.Kind;
import com.azure.resourcemanager.storage.models.MinimumTlsVersion;
import com.azure.resourcemanager.storage.models.RoutingChoice;
import com.azure.resourcemanager.storage.models.RoutingPreference;
import com.azure.resourcemanager.storage.models.SasPolicy;
import com.azure.resourcemanager.storage.models.Sku;
import com.azure.resourcemanager.storage.models.SkuName;
import com.azure.resourcemanager.storage.models.StorageAccountCreateParameters;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for StorageAccounts Create.
*/
public final class Main {
/*
* x-ms-original-file: 2026-09-01/StorageAccountCreateWithSmartAccessTier.json
*/
/**
* Sample code: StorageAccountCreateWithSmartAccessTier.
*
* @param manager Entry point to StorageManager.
*/
public static void
storageAccountCreateWithSmartAccessTier(com.azure.resourcemanager.storage.StorageManager manager) {
manager.serviceClient().getStorageAccounts()
.create("res9101", "sto4445",
new StorageAccountCreateParameters().withSku(new Sku().withName(SkuName.STANDARD_GRS))
.withKind(Kind.STORAGE).withLocation("eastus")
.withExtendedLocation(
new ExtendedLocation().withName("losangeles001").withType(ExtendedLocationTypes.EDGE_ZONE))
.withTags(
mapOf("key1", "fakeTokenPlaceholder", "key2", "fakeTokenPlaceholder"))
.withSasPolicy(
new SasPolicy().withSasExpirationPeriod(
"1.15:59:59").withExpirationAction(
ExpirationAction.LOG))
.withKeyPolicy(new KeyPolicy().withKeyExpirationPeriodInDays(20))
.withEncryption(new Encryption()
.withServices(new EncryptionServices()
.withBlob(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT))
.withFile(new EncryptionService().withEnabled(true).withKeyType(KeyType.ACCOUNT)))
.withKeySource(KeySource.MICROSOFT_STORAGE).withRequireInfrastructureEncryption(false))
.withAccessTier(AccessTier.SMART).withIsSftpEnabled(true).withIsHnsEnabled(true)
.withRoutingPreference(new RoutingPreference().withRoutingChoice(RoutingChoice.MICROSOFT_ROUTING)
.withPublishMicrosoftEndpoints(true).withPublishInternetEndpoints(true))
.withAllowBlobPublicAccess(false).withMinimumTlsVersion(MinimumTlsVersion.TLS1_2)
.withAllowSharedKeyAccess(true).withDefaultToOAuthAuthentication(false)
.withGeoPriorityReplicationStatus(new GeoPriorityReplicationStatus().withIsBlobEnabled(true)),
com.azure.core.util.Context.NONE);
}
// Use "Map.of" if available
@SuppressWarnings("unchecked")
private static <T> Map<String, T> mapOf(Object... inputs) {
Map<String, T> map = new HashMap<>();
for (int i = 0; i < inputs.length; i += 2) {
String key = (String) inputs[i];
T value = (T) inputs[i + 1];
map.put(key, value);
}
return map;
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python storage_account_create_with_smart_access_tier.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.storage_accounts.begin_create(
resource_group_name="res9101",
account_name="sto4445",
parameters={
"extendedLocation": {"name": "losangeles001", "type": "EdgeZone"},
"kind": "Storage",
"location": "eastus",
"properties": {
"accessTier": "Smart",
"allowBlobPublicAccess": False,
"allowSharedKeyAccess": True,
"defaultToOAuthAuthentication": False,
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": False,
"services": {
"blob": {"enabled": True, "keyType": "Account"},
"file": {"enabled": True, "keyType": "Account"},
},
},
"geoPriorityReplicationStatus": {"isBlobEnabled": True},
"isHnsEnabled": True,
"isSftpEnabled": True,
"keyPolicy": {"keyExpirationPeriodInDays": 20},
"minimumTlsVersion": "TLS1_2",
"routingPreference": {
"publishInternetEndpoints": True,
"publishMicrosoftEndpoints": True,
"routingChoice": "MicrosoftRouting",
},
"sasPolicy": {"expirationAction": "Log", "sasExpirationPeriod": "1.15:59:59"},
},
"sku": {"name": "Standard_GRS"},
"tags": {"key1": "value1", "key2": "value2"},
},
).result()
print(response)
# x-ms-original-file: 2026-09-01/StorageAccountCreateWithSmartAccessTier.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage/v4"
)
// Generated from example definition: 2026-09-01/StorageAccountCreateWithSmartAccessTier.json
func ExampleAccountsClient_BeginCreate_storageAccountCreateWithSmartAccessTier() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewAccountsClient().BeginCreate(ctx, "res9101", "sto4445", armstorage.AccountCreateParameters{
ExtendedLocation: &armstorage.ExtendedLocation{
Name: to.Ptr("losangeles001"),
Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
},
Kind: to.Ptr(armstorage.KindStorage),
Location: to.Ptr("eastus"),
Properties: &armstorage.AccountPropertiesCreateParameters{
AccessTier: to.Ptr(armstorage.AccessTierSmart),
AllowBlobPublicAccess: to.Ptr(false),
AllowSharedKeyAccess: to.Ptr(true),
DefaultToOAuthAuthentication: to.Ptr(false),
Encryption: &armstorage.Encryption{
KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
RequireInfrastructureEncryption: to.Ptr(false),
Services: &armstorage.EncryptionServices{
Blob: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
File: &armstorage.EncryptionService{
Enabled: to.Ptr(true),
KeyType: to.Ptr(armstorage.KeyTypeAccount),
},
},
},
IsHnsEnabled: to.Ptr(true),
IsSftpEnabled: to.Ptr(true),
KeyPolicy: &armstorage.KeyPolicy{
KeyExpirationPeriodInDays: to.Ptr[int32](20),
},
MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
RoutingPreference: &armstorage.RoutingPreference{
PublishInternetEndpoints: to.Ptr(true),
PublishMicrosoftEndpoints: to.Ptr(true),
RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
},
SasPolicy: &armstorage.SasPolicy{
ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
SasExpirationPeriod: to.Ptr("1.15:59:59"),
},
GeoPriorityReplicationStatus: &armstorage.GeoPriorityReplicationStatus{
IsBlobEnabled: to.Ptr(true),
},
},
SKU: &armstorage.SKU{
Name: to.Ptr(armstorage.SKUNameStandardGRS),
},
Tags: map[string]*string{
"key1": to.Ptr("value1"),
"key2": to.Ptr("value2"),
},
}, nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
log.Fatalf("failed to poll the result: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res = armstorage.AccountsClientCreateResponse{
// Account: armstorage.Account{
// Name: to.Ptr("sto4445"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts"),
// ExtendedLocation: &armstorage.ExtendedLocation{
// Name: to.Ptr("losangeles001"),
// Type: to.Ptr(armstorage.ExtendedLocationTypesEdgeZone),
// },
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445"),
// Kind: to.Ptr(armstorage.KindStorage),
// Location: to.Ptr("eastus"),
// Properties: &armstorage.AccountProperties{
// AllowBlobPublicAccess: to.Ptr(false),
// AllowSharedKeyAccess: to.Ptr(true),
// CreationTime: to.Ptr(time.Date(2017, time.May, 24, 13, 25, 33, 486323600, time.UTC)),
// Encryption: &armstorage.Encryption{
// KeySource: to.Ptr(armstorage.KeySourceMicrosoftStorage),
// RequireInfrastructureEncryption: to.Ptr(false),
// Services: &armstorage.EncryptionServices{
// Blob: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// File: &armstorage.EncryptionService{
// Enabled: to.Ptr(true),
// KeyType: to.Ptr(armstorage.KeyTypeAccount),
// LastEnabledTime: to.Ptr(time.Date(2019, time.December, 11, 20, 49, 31, 703614000, time.UTC)),
// },
// },
// },
// IsHnsEnabled: to.Ptr(true),
// IsSftpEnabled: to.Ptr(true),
// KeyCreationTime: &armstorage.KeyCreationTime{
// Key1: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// Key2: to.Ptr(time.Date(2021, time.March, 18, 4, 42, 22, 432283600, time.UTC)),
// },
// KeyPolicy: &armstorage.KeyPolicy{
// KeyExpirationPeriodInDays: to.Ptr[int32](20),
// },
// MinimumTLSVersion: to.Ptr(armstorage.MinimumTLSVersionTLS12),
// PrimaryEndpoints: &armstorage.Endpoints{
// Blob: to.Ptr("https://sto4445.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445.file.core.windows.net/"),
// InternetEndpoints: &armstorage.AccountInternetEndpoints{
// Blob: to.Ptr("https://sto4445-internetrouting.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445-internetrouting.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445-internetrouting.file.core.windows.net/"),
// Web: to.Ptr("https://sto4445-internetrouting.web.core.windows.net/"),
// },
// MicrosoftEndpoints: &armstorage.AccountMicrosoftEndpoints{
// Blob: to.Ptr("https://sto4445-microsoftrouting.blob.core.windows.net/"),
// Dfs: to.Ptr("https://sto4445-microsoftrouting.dfs.core.windows.net/"),
// File: to.Ptr("https://sto4445-microsoftrouting.file.core.windows.net/"),
// Queue: to.Ptr("https://sto4445-microsoftrouting.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445-microsoftrouting.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445-microsoftrouting.web.core.windows.net/"),
// },
// Queue: to.Ptr("https://sto4445.queue.core.windows.net/"),
// Table: to.Ptr("https://sto4445.table.core.windows.net/"),
// Web: to.Ptr("https://sto4445.web.core.windows.net/"),
// },
// PrimaryLocation: to.Ptr("eastus2euap"),
// ProvisioningState: to.Ptr(armstorage.ProvisioningStateSucceeded),
// RoutingPreference: &armstorage.RoutingPreference{
// PublishInternetEndpoints: to.Ptr(true),
// PublishMicrosoftEndpoints: to.Ptr(true),
// RoutingChoice: to.Ptr(armstorage.RoutingChoiceMicrosoftRouting),
// },
// SasPolicy: &armstorage.SasPolicy{
// ExpirationAction: to.Ptr(armstorage.ExpirationActionLog),
// SasExpirationPeriod: to.Ptr("1.15:59:59"),
// },
// SecondaryLocation: to.Ptr("centraluseuap"),
// StatusOfPrimary: to.Ptr(armstorage.AccountStatusAvailable),
// StatusOfSecondary: to.Ptr(armstorage.AccountStatusAvailable),
// EnableHTTPSTrafficOnly: to.Ptr(true),
// GeoPriorityReplicationStatus: &armstorage.GeoPriorityReplicationStatus{
// IsBlobEnabled: to.Ptr(true),
// },
// },
// SKU: &armstorage.SKU{
// Name: to.Ptr(armstorage.SKUNameStandardGRS),
// Tier: to.Ptr(armstorage.SKUTierStandard),
// },
// Tags: map[string]*string{
// "key1": to.Ptr("value1"),
// "key2": to.Ptr("value2"),
// },
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
*
* @summary asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
* x-ms-original-file: 2026-09-01/StorageAccountCreateWithSmartAccessTier.json
*/
async function storageAccountCreateWithSmartAccessTier() {
const credential = new DefaultAzureCredential();
const subscriptionId = "00000000-0000-0000-0000-000000000000";
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.storageAccounts.create("res9101", "sto4445", {
extendedLocation: { name: "losangeles001", type: "EdgeZone" },
kind: "Storage",
location: "eastus",
accessTier: "Smart",
allowBlobPublicAccess: false,
allowSharedKeyAccess: true,
defaultToOAuthAuthentication: false,
encryption: {
keySource: "Microsoft.Storage",
requireInfrastructureEncryption: false,
services: {
blob: { enabled: true, keyType: "Account" },
file: { enabled: true, keyType: "Account" },
},
},
isHnsEnabled: true,
isSftpEnabled: true,
keyPolicy: { keyExpirationPeriodInDays: 20 },
minimumTlsVersion: "TLS1_2",
routingPreference: {
publishInternetEndpoints: true,
publishMicrosoftEndpoints: true,
routingChoice: "MicrosoftRouting",
},
sasPolicy: { expirationAction: "Log", sasExpirationPeriod: "1.15:59:59" },
geoPriorityReplicationStatus: { isBlobEnabled: true },
sku: { name: "Standard_GRS" },
tags: { key1: "value1", key2: "value2" },
});
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Voorbeeldrespons
{
"name": "sto4445",
"type": "Microsoft.Storage/storageAccounts",
"extendedLocation": {
"name": "losangeles001",
"type": "EdgeZone"
},
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/sto4445",
"kind": "Storage",
"location": "eastus",
"properties": {
"allowBlobPublicAccess": false,
"allowSharedKeyAccess": true,
"creationTime": "2017-05-24T13:25:33.4863236Z",
"encryption": {
"keySource": "Microsoft.Storage",
"requireInfrastructureEncryption": false,
"services": {
"blob": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
},
"file": {
"enabled": true,
"keyType": "Account",
"lastEnabledTime": "2019-12-11T20:49:31.7036140Z"
}
}
},
"isHnsEnabled": true,
"isSftpEnabled": true,
"keyCreationTime": {
"key1": "2021-03-18T04:42:22.4322836Z",
"key2": "2021-03-18T04:42:22.4322836Z"
},
"keyPolicy": {
"keyExpirationPeriodInDays": 20
},
"minimumTlsVersion": "TLS1_2",
"primaryEndpoints": {
"blob": "https://sto4445.blob.core.windows.net/",
"dfs": "https://sto4445.dfs.core.windows.net/",
"file": "https://sto4445.file.core.windows.net/",
"internetEndpoints": {
"blob": "https://sto4445-internetrouting.blob.core.windows.net/",
"dfs": "https://sto4445-internetrouting.dfs.core.windows.net/",
"file": "https://sto4445-internetrouting.file.core.windows.net/",
"web": "https://sto4445-internetrouting.web.core.windows.net/"
},
"microsoftEndpoints": {
"blob": "https://sto4445-microsoftrouting.blob.core.windows.net/",
"dfs": "https://sto4445-microsoftrouting.dfs.core.windows.net/",
"file": "https://sto4445-microsoftrouting.file.core.windows.net/",
"queue": "https://sto4445-microsoftrouting.queue.core.windows.net/",
"table": "https://sto4445-microsoftrouting.table.core.windows.net/",
"web": "https://sto4445-microsoftrouting.web.core.windows.net/"
},
"queue": "https://sto4445.queue.core.windows.net/",
"table": "https://sto4445.table.core.windows.net/",
"web": "https://sto4445.web.core.windows.net/"
},
"primaryLocation": "eastus2euap",
"provisioningState": "Succeeded",
"routingPreference": {
"publishInternetEndpoints": true,
"publishMicrosoftEndpoints": true,
"routingChoice": "MicrosoftRouting"
},
"sasPolicy": {
"expirationAction": "Log",
"sasExpirationPeriod": "1.15:59:59"
},
"secondaryLocation": "centraluseuap",
"statusOfPrimary": "available",
"statusOfSecondary": "available",
"supportsHttpsTrafficOnly": true,
"geoPriorityReplicationStatus": {
"isBlobEnabled": true
}
},
"sku": {
"name": "Standard_GRS",
"tier": "Standard"
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
StorageAccountCreateWithTurboTier
Voorbeeldaanvraag
PUT https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/staturbocontoso01?api-version=2026-09-01
{
"kind": "StorageV2",
"location": "eastus2",
"properties": {
"accessTier": "Hot",
"turboTier": {
"status": "Enabled",
"targetPercent": 10
}
},
"sku": {
"name": "Standard_LRS"
}
}
import com.azure.resourcemanager.storage.models.AccessTier;
import com.azure.resourcemanager.storage.models.Kind;
import com.azure.resourcemanager.storage.models.Sku;
import com.azure.resourcemanager.storage.models.SkuName;
import com.azure.resourcemanager.storage.models.StorageAccountCreateParameters;
import com.azure.resourcemanager.storage.models.TurboTier;
import com.azure.resourcemanager.storage.models.TurboTierStatus;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for StorageAccounts Create.
*/
public final class Main {
/*
* x-ms-original-file: 2026-09-01/StorageAccountCreateWithTurboTier.json
*/
/**
* Sample code: StorageAccountCreateWithTurboTier.
*
* @param manager Entry point to StorageManager.
*/
public static void storageAccountCreateWithTurboTier(com.azure.resourcemanager.storage.StorageManager manager) {
manager.serviceClient().getStorageAccounts().create("res9101", "staturbocontoso01",
new StorageAccountCreateParameters().withSku(new Sku().withName(SkuName.STANDARD_LRS))
.withKind(Kind.STORAGE_V2).withLocation("eastus2").withAccessTier(AccessTier.HOT)
.withTurboTier(new TurboTier().withStatus(TurboTierStatus.ENABLED).withTargetPercent(10)),
com.azure.core.util.Context.NONE);
}
// Use "Map.of" if available
@SuppressWarnings("unchecked")
private static <T> Map<String, T> mapOf(Object... inputs) {
Map<String, T> map = new HashMap<>();
for (int i = 0; i < inputs.length; i += 2) {
String key = (String) inputs[i];
T value = (T) inputs[i + 1];
map.put(key, value);
}
return map;
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python storage_account_create_with_turbo_tier.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.storage_accounts.begin_create(
resource_group_name="res9101",
account_name="staturbocontoso01",
parameters={
"kind": "StorageV2",
"location": "eastus2",
"properties": {"accessTier": "Hot", "turboTier": {"status": "Enabled", "targetPercent": 10}},
"sku": {"name": "Standard_LRS"},
},
).result()
print(response)
# x-ms-original-file: 2026-09-01/StorageAccountCreateWithTurboTier.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage/v4"
)
// Generated from example definition: 2026-09-01/StorageAccountCreateWithTurboTier.json
func ExampleAccountsClient_BeginCreate_storageAccountCreateWithTurboTier() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("00000000-0000-0000-0000-000000000000", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewAccountsClient().BeginCreate(ctx, "res9101", "staturbocontoso01", armstorage.AccountCreateParameters{
Kind: to.Ptr(armstorage.KindStorageV2),
Location: to.Ptr("eastus2"),
Properties: &armstorage.AccountPropertiesCreateParameters{
AccessTier: to.Ptr(armstorage.AccessTierHot),
TurboTier: &armstorage.TurboTier{
Status: to.Ptr(armstorage.TurboTierStatusEnabled),
TargetPercent: to.Ptr[int32](10),
},
},
SKU: &armstorage.SKU{
Name: to.Ptr(armstorage.SKUNameStandardLRS),
},
}, nil)
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
res, err := poller.PollUntilDone(ctx, nil)
if err != nil {
log.Fatalf("failed to poll the result: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res = armstorage.AccountsClientCreateResponse{
// Account: armstorage.Account{
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/staturbocontoso01"),
// Kind: to.Ptr(armstorage.KindStorageV2),
// Location: to.Ptr("eastus2"),
// Name: to.Ptr("staturbocontoso01"),
// Properties: &armstorage.AccountProperties{
// AccessTier: to.Ptr(armstorage.AccessTierHot),
// ProvisioningState: to.Ptr(armstorage.ProvisioningStateSucceeded),
// TurboTier: &armstorage.TurboTier{
// Status: to.Ptr(armstorage.TurboTierStatusEnabled),
// TargetPercent: to.Ptr[int32](10),
// },
// },
// SKU: &armstorage.SKU{
// Name: to.Ptr(armstorage.SKUNameStandardLRS),
// Tier: to.Ptr(armstorage.SKUTierStandard),
// },
// Type: to.Ptr("Microsoft.Storage/storageAccounts"),
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
*
* @summary asynchronously creates a new storage account with the specified parameters. If an account is already created and a subsequent create request is issued with different properties, the account properties will be updated. If an account is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
* x-ms-original-file: 2026-09-01/StorageAccountCreateWithTurboTier.json
*/
async function storageAccountCreateWithTurboTier() {
const credential = new DefaultAzureCredential();
const subscriptionId = "00000000-0000-0000-0000-000000000000";
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.storageAccounts.create("res9101", "staturbocontoso01", {
kind: "StorageV2",
location: "eastus2",
accessTier: "Hot",
turboTier: { status: "Enabled", targetPercent: 10 },
sku: { name: "Standard_LRS" },
});
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Voorbeeldrespons
{
"id": "/subscriptions/{subscription-id}/resourceGroups/res9101/providers/Microsoft.Storage/storageAccounts/staturbocontoso01",
"kind": "StorageV2",
"location": "eastus2",
"name": "staturbocontoso01",
"properties": {
"accessTier": "Hot",
"provisioningState": "Succeeded",
"turboTier": {
"status": "Enabled",
"targetPercent": 10
}
},
"sku": {
"name": "Standard_LRS",
"tier": "Standard"
},
"type": "Microsoft.Storage/storageAccounts"
}
Definities
| Naam |
Description |
|
AccessTier
|
De standaard toegangslaag voor blokblobs in het opslagaccount. Vereist voor opslagaccounts waarbij soort = BlobStorage. Zie meer informatie in: https://learn.microsoft.com/azure/storage/blobs/access-tiers-overview.
|
|
AccountImmutabilityPolicyProperties
|
Hiermee definieert u onveranderbaarheidsbeleidseigenschappen op accountniveau.
|
|
AccountImmutabilityPolicyState
|
De status ImmutabilityPolicy definieert de modus van het beleid. Uitgeschakelde status schakelt het beleid uit, ontgrendelde status maakt een toename en afname van de onveranderbaarheidsretentietijd mogelijk en staat ook het in-/uitschakelen van de eigenschap allowProtectedAppendWrites toe, vergrendelde status staat alleen de toename van de retentietijd voor onveranderbaarheid toe. Een beleid kan alleen worden gemaakt met de status Uitgeschakeld of Ontgrendeld en kan tussen de twee statussen worden geplaatst. Alleen een beleid met een ontgrendelde status kan worden overgezet naar een vergrendelde status die niet kan worden teruggezet.
|
|
AccountStatus
|
Hiermee haalt u de status op die aangeeft of de primaire locatie van het opslagaccount beschikbaar of niet beschikbaar is.
|
|
AccountType
|
Hiermee geeft u het Active Directory accounttype voor Azure Storage. Als directoryServiceOptions is ingesteld op AD (AD DS-verificatie), is deze eigenschap optioneel. Indien opgegeven, moet samAccountName ook worden opgegeven. Voor directoryServiceOptions AADDS (Entra DS-verificatie) of AADKERB (Entra-verificatie) kan deze eigenschap worden weggelaten.
|
|
ActiveDirectoryProperties
|
Instellingeneigenschappen voor Active Directory (AD).
|
|
AllowedCopyScope
|
Kopiëren naar en van opslagaccounts in een AAD-tenant of met privékoppelingen naar hetzelfde VNet beperken.
|
|
AzureFilesIdentityBasedAuthentication
|
Instellingen voor verificatie op basis van identiteit in Azure Files.
|
|
BlobRestoreParameters
|
Parameters voor het herstellen van blobs
|
|
BlobRestoreProgressStatus
|
De status van de voortgang van het herstellen van de blob. Mogelijke waarden zijn: - InProgress: Geeft aan dat het herstellen van de blob wordt uitgevoerd. - Voltooid: Geeft aan dat het herstellen van de blob is voltooid. - Mislukt: geeft aan dat het herstellen van de blob is mislukt.
|
|
BlobRestoreRange
|
Blobbereik
|
|
BlobRestoreStatus
|
Status van blobherstel.
|
|
Bypass
|
Hiermee geeft u op of verkeer wordt omzeild voor logboekregistratie/metrics/AzureServices. Mogelijke waarden zijn een combinatie van logboekregistratie|Metrische gegevens |AzureServices (bijvoorbeeld 'Logboekregistratie, metrische gegevens') of Geen om geen van deze verkeer te omzeilen.
|
|
createdByType
|
Het identiteitstype dat de resource heeft gemaakt.
|
|
CustomDomain
|
Het aangepaste domein dat is toegewezen aan dit opslagaccount. Dit kan worden ingesteld via Update.
|
|
DefaultAction
|
Hiermee geeft u de standaardactie toestaan of weigeren wanneer er geen andere regels overeenkomen.
|
|
DefaultSharePermission
|
Standaardmachtiging voor delen voor gebruikers die Kerberos-verificatie gebruiken als er geen RBAC-rol is toegewezen.
|
|
DirectoryServiceOptions
|
Geeft de gebruikte adreslijstservice aan. Houd er rekening mee dat deze opsomming in de toekomst kan worden uitgebreid.
|
|
DnsEndpointType
|
Hiermee kunt u het type eindpunt opgeven. Stel dit in op AzureDNSZone om een groot aantal accounts in één abonnement aan te maken, wat accounts aanmaakt in een Azure DNS Zone en de endpoint-URL zal een alfanumerieke DNS Zone-identificatie hebben.
|
|
DualStackEndpointPreference
|
De voorkeur voor dual-stack-eindpunten bepaalt of IPv6-eindpunten worden gepubliceerd.
|
|
Encryption
|
De versleutelingsinstellingen in het opslagaccount.
|
|
EncryptionIdentity
|
Versleutelingsidentiteit voor het opslagaccount.
|
|
EncryptionService
|
Een service waarmee versleuteling aan de serverzijde kan worden gebruikt.
|
|
EncryptionServices
|
Een lijst met services die ondersteuning bieden voor versleuteling.
|
|
Endpoints
|
De URI's die worden gebruikt voor het ophalen van een openbare blob, wachtrij, tabel, web- of dfs-object.
|
|
ErrorResponse
|
Een foutreactie van de opslagresourceprovider.
|
|
ErrorResponseBody
|
Contract voor antwoordtekst van fout.
|
|
ExpirationAction
|
De SAS-verloopactie definieert de actie die moet worden uitgevoerd wanneer sasPolicy.sasExpirationPeriod wordt geschonden. De actie Logboek kan worden gebruikt voor controledoeleinden en de actie Blokkeren kan worden gebruikt om het gebruik van SAS-tokens te blokkeren en te weigeren die niet voldoen aan de verloopperiode van het SAS-beleid.
|
|
ExtendedLocation
|
Het complexe type van de uitgebreide locatie.
|
|
ExtendedLocationTypes
|
Het type extendedLocation.
|
|
GeoPriorityReplicationStatus
|
Status voor het inschakelen van Geo Priority Replication voor het opslagaccount.
|
|
GeoReplicationStats
|
Statistieken met betrekking tot replicatie voor de blob-, tabel-, wachtrij- en bestandsservices van het opslagaccount. Deze is alleen beschikbaar wanneer geografisch redundante replicatie is ingeschakeld voor het opslagaccount.
|
|
GeoReplicationStatus
|
De status van de secundaire locatie. Mogelijke waarden zijn: - Live: Geeft aan dat de secundaire locatie actief en operationeel is. - Bootstrap: Geeft de initiële synchronisatie van de primaire locatie naar de secundaire locatie wordt uitgevoerd. Dit gebeurt meestal wanneer replicatie voor het eerst wordt ingeschakeld. - Niet beschikbaar: geeft aan dat de secundaire locatie tijdelijk niet beschikbaar is.
|
|
Identity
|
Identiteit voor de resource.
|
|
IdentityType
|
Het identiteitstype.
|
|
ImmutableStorageAccount
|
Met deze eigenschap kunt u onveranderbaarheid op accountniveau inschakelen en definiëren. Als u de functie inschakelt, wordt blobversiebeheer automatisch ingeschakeld.
|
|
IPRule
|
IP-regel met een specifiek IP- of IP-bereik in CIDR-indeling.
|
|
KeyCreationTime
|
Tijd voor het maken van opslagaccountsleutels.
|
|
KeyPolicy
|
KeyPolicy toegewezen aan het opslagaccount.
|
|
KeySource
|
De versleutelingssleutelbron (provider). Mogelijke waarden (hoofdlettergevoelig): Microsoft.Storage, Microsoft.Keyvault
|
|
KeyType
|
Het type versleutelingssleutel dat moet worden gebruikt voor de versleutelingsservice. Het sleuteltype Account impliceert dat een versleutelingssleutel met accountbereik wordt gebruikt. Het sleuteltype Service impliceert dat een standaardservicesleutel wordt gebruikt.
|
|
KeyVaultProperties
|
Eigenschappen van de sleutelkluis.
|
|
Kind
|
Geeft het type opslagaccount aan.
|
|
LargeFileSharesState
|
Sta grote bestandsshares toe als deze is ingesteld op Ingeschakeld. Deze kan niet worden uitgeschakeld zodra deze is ingeschakeld.
|
|
MinimumTlsVersion
|
Stel de minimale TLS-versie in die is toegestaan voor aanvragen voor opslag. De standaardinterpretatie is TLS 1.0 voor deze eigenschap. Minimale TLS versie 1.3 wordt niet ondersteund.
|
|
NetworkRuleSet
|
Netwerkregelset
|
|
Placement
|
Het complexe type van de zonale plaatsingsdetails.
|
|
PolicyViolationAction
|
De actie die wordt uitgevoerd wanneer een SAS-(shared access signature) beleidsvereiste voor gebruikersdelegatie wordt geschonden.
|
|
PostFailoverRedundancy
|
Het redundantietype van het account nadat een accountfailover is uitgevoerd.
|
|
PostPlannedFailoverRedundancy
|
Het redundantietype van het account nadat een failover van een gepland account is uitgevoerd.
|
|
PrivateEndpoint
|
De privé-eindpuntresource.
|
|
PrivateEndpointConnection
|
De privé-eindpuntverbindingsresource.
|
|
PrivateEndpointConnectionProvisioningState
|
De huidige inrichtingsstatus.
|
|
PrivateEndpointServiceConnectionStatus
|
De verbindingsstatus van het privé-eindpunt.
|
|
PrivateLinkServiceConnectionState
|
Een verzameling informatie over de status van de verbinding tussen serviceconsumer en provider.
|
|
ProvisioningState
|
Hiermee wordt de status van het opslagaccount opgehaald op het moment dat de bewerking werd aangeroepen.
|
|
PublicNetworkAccess
|
Hiermee kunt u de perimeterconfiguratie van netwerkbeveiliging toestaan, weigeren of toestaan om openbare netwerktoegang tot het opslagaccount te evalueren. De waarde is optioneel, maar moet zijn ingeschakeld, uitgeschakeld of SecuredByPerimeter.
|
|
ResourceAccessRule
|
Regel voor toegang tot resources.
|
|
RoutingChoice
|
Routeringskeuze definieert het type netwerkroutering dat door de gebruiker is gekozen.
|
|
RoutingPreference
|
Routeringsvoorkeur definieert het type netwerk, microsoft of internetroutering dat moet worden gebruikt om de gebruikersgegevens te leveren. De standaardoptie is Microsoft-routering
|
|
SasPolicy
|
SasPolicy toegewezen aan het opslagaccount.
|
|
ServiceSharedKeyAccessProperties
|
Definieert instellingen voor gedeelde sleuteltoegang voor een individuele opslagdienst.
|
|
Sku
|
De SKU van het opslagaccount.
|
|
SkuConversionStatus
|
Deze eigenschap geeft de huidige SKU-conversiestatus aan.
|
|
SkuName
|
De SKU-naam. Vereist voor het maken van accounts; optioneel voor update. Houd er rekening mee dat in oudere versies de SKU-naam accountType is genoemd.
|
|
SkuTier
|
Het SKU-niveau. Dit is gebaseerd op de SKU-naam.
|
|
SmbOAuthSettings
|
Eigenschap instellen voor Managed Identity-toegang via SMB met behulp van OAuth
|
|
State
|
Hiermee haalt u de status van de regel voor het virtuele netwerk op.
|
|
StorageAccount
|
Het opslagaccount.
|
|
StorageAccountCreateParameters
|
De parameters die worden gebruikt bij het maken van een opslagaccount.
|
|
StorageAccountInternetEndpoints
|
De URI's die worden gebruikt voor het ophalen van een openbare blob, bestand, web of dfs-object via een eindpunt voor internetroutering.
|
|
StorageAccountIpv6Endpoints
|
De URI's die worden gebruikt om een openbare blob, wachtrij, tabel, web of dfs-object op te halen via een IPv6-eindpunt.
|
|
StorageAccountMicrosoftEndpoints
|
De URI's die worden gebruikt voor het ophalen van een openbare blob, wachtrij, tabel, web- of dfs-object via een microsoft-routeringseindpunt.
|
|
StorageAccountSharedKeyAccessProperties
|
Definieert gedeelde sleuteltoegangseigenschappen voor een opslagaccount.
|
|
StorageAccountSkuConversionStatus
|
Hiermee definieert u het SKU-conversiestatusobject voor asynchrone sKU-conversies.
|
|
StorageDataCollaborationPolicyProperties
|
Definieert Data Collaboration Policy voor een opslagaccount.
|
|
systemData
|
Metagegevens met betrekking tot het maken en de laatste wijziging van de resource.
|
|
TurboTier
|
Stel Turbo Tier in voor een opslagaccount.
|
|
TurboTierStatus
|
Geeft aan of Turbo Tier is ingeschakeld of uitgeschakeld.
|
|
UserAssignedIdentity
|
UserAssignedIdentity voor de resource.
|
|
VirtualNetworkRule
|
Regel voor virtueel netwerk.
|
|
ZonePlacementPolicy
|
Het vastmaakbeleid voor de beschikbaarheidszone voor het opslagaccount.
|
AccessTier
Opsomming
De standaard toegangslaag voor blokblobs in het opslagaccount. Vereist voor opslagaccounts waarbij soort = BlobStorage. Zie meer informatie in: https://learn.microsoft.com/azure/storage/blobs/access-tiers-overview.
| Waarde |
Description |
|
Hot
|
|
|
Cool
|
|
|
Premium
|
|
|
Cold
|
|
|
Smart
|
|
AccountImmutabilityPolicyProperties
Object
Hiermee definieert u onveranderbaarheidsbeleidseigenschappen op accountniveau.
| Naam |
Type |
Description |
|
allowProtectedAppendWrites
|
boolean
|
Deze eigenschap kan alleen worden gewijzigd voor uitgeschakeld en ontgrendeld bewaarbeleid op basis van tijd. Wanneer deze optie is ingeschakeld, kunnen nieuwe blokken worden weggeschreven naar een toevoeg-blob terwijl onveranderbaarheidsbeveiliging en -naleving behouden blijven. Alleen nieuwe blokken kunnen worden toegevoegd en bestaande blokken kunnen niet worden gewijzigd of verwijderd.
|
|
immutabilityPeriodSinceCreationInDays
|
integer
(int32)
minimum: 1 maximum: 146000
|
De onveranderbaarheidsperiode voor de blobs in de container sinds het maken van het beleid, in dagen.
|
|
state
|
AccountImmutabilityPolicyState
|
De status ImmutabilityPolicy definieert de modus van het beleid. Uitgeschakelde status schakelt het beleid uit, ontgrendelde status maakt een toename en afname van de onveranderbaarheidsretentietijd mogelijk en staat ook het in-/uitschakelen van de eigenschap allowProtectedAppendWrites toe, vergrendelde status staat alleen de toename van de retentietijd voor onveranderbaarheid toe. Een beleid kan alleen worden gemaakt met de status Uitgeschakeld of Ontgrendeld en kan tussen de twee statussen worden geplaatst. Alleen een beleid met een ontgrendelde status kan worden overgezet naar een vergrendelde status die niet kan worden teruggezet.
|
AccountImmutabilityPolicyState
Opsomming
De status ImmutabilityPolicy definieert de modus van het beleid. Uitgeschakelde status schakelt het beleid uit, ontgrendelde status maakt een toename en afname van de onveranderbaarheidsretentietijd mogelijk en staat ook het in-/uitschakelen van de eigenschap allowProtectedAppendWrites toe, vergrendelde status staat alleen de toename van de retentietijd voor onveranderbaarheid toe. Een beleid kan alleen worden gemaakt met de status Uitgeschakeld of Ontgrendeld en kan tussen de twee statussen worden geplaatst. Alleen een beleid met een ontgrendelde status kan worden overgezet naar een vergrendelde status die niet kan worden teruggezet.
| Waarde |
Description |
|
Unlocked
|
|
|
Locked
|
|
|
Disabled
|
|
AccountStatus
Opsomming
Hiermee haalt u de status op die aangeeft of de primaire locatie van het opslagaccount beschikbaar of niet beschikbaar is.
| Waarde |
Description |
|
available
|
|
|
unavailable
|
|
AccountType
Opsomming
Hiermee geeft u het Active Directory accounttype voor Azure Storage. Als directoryServiceOptions is ingesteld op AD (AD DS-verificatie), is deze eigenschap optioneel. Indien opgegeven, moet samAccountName ook worden opgegeven. Voor directoryServiceOptions AADDS (Entra DS-verificatie) of AADKERB (Entra-verificatie) kan deze eigenschap worden weggelaten.
| Waarde |
Description |
|
User
|
|
|
Computer
|
|
ActiveDirectoryProperties
Object
Instellingeneigenschappen voor Active Directory (AD).
| Naam |
Type |
Description |
|
accountType
|
AccountType
|
Hiermee geeft u het Active Directory accounttype voor Azure Storage. Als directoryServiceOptions is ingesteld op AD (AD DS-verificatie), is deze eigenschap optioneel. Indien opgegeven, moet samAccountName ook worden opgegeven. Voor directoryServiceOptions AADDS (Entra DS-verificatie) of AADKERB (Entra-verificatie) kan deze eigenschap worden weggelaten.
|
|
azureStorageSid
|
string
|
Hiermee geeft u de beveiligings-id (SID) voor Azure Storage op. Als directoryServiceOptions is ingesteld op AD (AD DS-verificatie), is deze eigenschap vereist. Anders kan het worden weggelaten.
|
|
domainGuid
|
string
|
Hiermee geeft u de domein-GUID. Als directoryServiceOptions is ingesteld op AD (AD DS-verificatie), is deze eigenschap vereist. Als directoryServiceOptions is ingesteld op AADDS (Entra DS-verificatie), kan deze eigenschap worden weggelaten. Als directoryServiceOptions is ingesteld op AADKERB (Entra-verificatie), is deze eigenschap optioneel. het is nodig ter ondersteuning van de configuratie van machtigingen op map- en bestandsniveau via Windows Verkenner, maar is niet vereist voor authenticatie.
|
|
domainName
|
string
|
Hiermee geeft u het primaire domein waarvoor de AD DNS-server gezaghebbend is. Deze eigenschap is vereist als directoryServiceOptions is ingesteld op AD (AD DS-verificatie). Als directoryServiceOptions is ingesteld op AADDS (Entra DS-verificatie), is het verstrekken van deze eigenschap optioneel, omdat deze automatisch wordt afgeleid als deze wordt weggelaten. Als directoryServiceOptions is ingesteld op AADKERB (Entra-verificatie), is deze eigenschap optioneel. het is nodig ter ondersteuning van de configuratie van machtigingen op map- en bestandsniveau via Windows Verkenner, maar is niet vereist voor authenticatie.
|
|
domainSid
|
string
|
Hiermee geeft u de beveiligings-id (SID) van het AD-domein op. Als directoryServiceOptions is ingesteld op AD (AD DS-verificatie), is deze eigenschap vereist. Anders kan het worden weggelaten.
|
|
forestName
|
string
|
Hiermee geeft u het Active Directory-forest op dat moet worden get. Als directoryServiceOptions is ingesteld op AD (AD DS-verificatie), is deze eigenschap vereist. Anders kan het worden weggelaten.
|
|
netBiosDomainName
|
string
|
Hiermee geeft u de NetBIOS-domeinnaam. Als directoryServiceOptions is ingesteld op AD (AD DS-verificatie), is deze eigenschap vereist. Anders kan het worden weggelaten.
|
|
samAccountName
|
string
|
Hiermee geeft u de Active Directory SAMAccountName voor Azure Storage. Als directoryServiceOptions is ingesteld op AD (AD DS-verificatie), is deze eigenschap optioneel. Indien opgegeven, moet accountType ook worden opgegeven. Voor directoryServiceOptions AADDS (Entra DS-verificatie) of AADKERB (Entra-verificatie) kan deze eigenschap worden weggelaten.
|
AllowedCopyScope
Opsomming
Kopiëren naar en van opslagaccounts in een AAD-tenant of met privékoppelingen naar hetzelfde VNet beperken.
| Waarde |
Description |
|
PrivateLink
|
|
|
AAD
|
|
|
All
|
|
AzureFilesIdentityBasedAuthentication
Object
Instellingen voor verificatie op basis van identiteit in Azure Files.
| Naam |
Type |
Description |
|
activeDirectoryProperties
|
ActiveDirectoryProperties
|
Aanvullende informatie over de directoryservice. Vereist als directoryServiceOptions AD (AD DS-verificatie) is. Optioneel voor directoryServiceOptions AADDS (Entra DS-authenticatie) en AADKERB (Entra-authenticatie).
|
|
defaultSharePermission
|
DefaultSharePermission
|
Standaardmachtiging voor delen voor gebruikers die Kerberos-verificatie gebruiken als er geen RBAC-rol is toegewezen.
|
|
directoryServiceOptions
|
DirectoryServiceOptions
|
Geeft de gebruikte adreslijstservice aan. Houd er rekening mee dat deze opsomming in de toekomst kan worden uitgebreid.
|
|
smbOAuthSettings
|
SmbOAuthSettings
|
Vereist voor toegang tot beheerde identiteiten met behulp van OAuth via SMB.
|
BlobRestoreParameters
Object
Parameters voor het herstellen van blobs
| Naam |
Type |
Description |
|
blobRanges
|
BlobRestoreRange[]
|
Blobbereiken die moeten worden hersteld.
|
|
timeToRestore
|
string
(date-time)
|
Blob herstellen naar de opgegeven tijd.
|
BlobRestoreProgressStatus
Opsomming
De status van de voortgang van het herstellen van de blob. Mogelijke waarden zijn: - InProgress: Geeft aan dat het herstellen van de blob wordt uitgevoerd. - Voltooid: Geeft aan dat het herstellen van de blob is voltooid. - Mislukt: geeft aan dat het herstellen van de blob is mislukt.
| Waarde |
Description |
|
InProgress
|
|
|
Complete
|
|
|
Failed
|
|
BlobRestoreRange
Object
Blobbereik
| Naam |
Type |
Description |
|
endRange
|
string
|
Blob-eindbereik. Dit is exclusief. Leeg betekent het einde van het account.
|
|
startRange
|
string
|
Beginbereik van blob. Dit is inclusief. Leeg betekent dat account wordt gestart.
|
BlobRestoreStatus
Object
Status van blobherstel.
| Naam |
Type |
Description |
|
failureReason
|
string
|
Reden van fout wanneer het herstellen van de blob is mislukt.
|
|
parameters
|
BlobRestoreParameters
|
Blob-herstelaanvraagparameters.
|
|
restoreId
|
string
|
Id voor het bijhouden van een blobherstelaanvraag.
|
|
status
|
BlobRestoreProgressStatus
|
De status van de voortgang van het herstellen van de blob. Mogelijke waarden zijn: - InProgress: Geeft aan dat het herstellen van de blob wordt uitgevoerd. - Voltooid: Geeft aan dat het herstellen van de blob is voltooid. - Mislukt: geeft aan dat het herstellen van de blob is mislukt.
|
Bypass
Opsomming
Hiermee geeft u op of verkeer wordt omzeild voor logboekregistratie/metrics/AzureServices. Mogelijke waarden zijn een combinatie van logboekregistratie|Metrische gegevens |AzureServices (bijvoorbeeld 'Logboekregistratie, metrische gegevens') of Geen om geen van deze verkeer te omzeilen.
| Waarde |
Description |
|
None
|
|
|
Logging
|
|
|
Metrics
|
|
|
AzureServices
|
|
createdByType
Opsomming
Het identiteitstype dat de resource heeft gemaakt.
| Waarde |
Description |
|
User
|
|
|
Application
|
|
|
ManagedIdentity
|
|
|
Key
|
|
CustomDomain
Object
Het aangepaste domein dat is toegewezen aan dit opslagaccount. Dit kan worden ingesteld via Update.
| Naam |
Type |
Description |
|
name
|
string
|
Hiermee wordt de aangepaste domeinnaam opgehaald of ingesteld die is toegewezen aan het opslagaccount. De naam is de CNAME-bron.
|
|
useSubDomainName
|
boolean
|
Hiermee wordt aangegeven of indirecte CName-validatie is ingeschakeld. De standaardwaarde is onwaar. Dit mag alleen worden ingesteld op updates.
|
DefaultAction
Opsomming
Hiermee geeft u de standaardactie toestaan of weigeren wanneer er geen andere regels overeenkomen.
| Waarde |
Description |
|
Allow
|
|
|
Deny
|
|
DefaultSharePermission
Opsomming
Standaardmachtiging voor delen voor gebruikers die Kerberos-verificatie gebruiken als er geen RBAC-rol is toegewezen.
| Waarde |
Description |
|
None
|
|
|
StorageFileDataSmbShareReader
|
|
|
StorageFileDataSmbShareContributor
|
|
|
StorageFileDataSmbShareElevatedContributor
|
|
DirectoryServiceOptions
Opsomming
Geeft de gebruikte adreslijstservice aan. Houd er rekening mee dat deze opsomming in de toekomst kan worden uitgebreid.
| Waarde |
Description |
|
None
|
|
|
AADDS
|
|
|
AD
|
|
|
AADKERB
|
|
DnsEndpointType
Opsomming
Hiermee kunt u het type eindpunt opgeven. Stel dit in op AzureDNSZone om een groot aantal accounts in één abonnement aan te maken, wat accounts aanmaakt in een Azure DNS Zone en de endpoint-URL zal een alfanumerieke DNS Zone-identificatie hebben.
| Waarde |
Description |
|
Standard
|
|
|
AzureDnsZone
|
|
DualStackEndpointPreference
Object
De voorkeur voor dual-stack-eindpunten bepaalt of IPv6-eindpunten worden gepubliceerd.
| Naam |
Type |
Description |
|
publishIpv6Endpoint
|
boolean
|
Een booleaanse vlag die aangeeft of IPv6-opslageindpunten moeten worden gepubliceerd.
|
Encryption
Object
De versleutelingsinstellingen in het opslagaccount.
| Naam |
Type |
Default value |
Description |
|
identity
|
EncryptionIdentity
|
|
De identiteit die moet worden gebruikt met versleuteling aan de servicezijde at rest.
|
|
keySource
|
KeySource
|
Microsoft.Storage
|
De versleutelingssleutelbron (provider). Mogelijke waarden (hoofdlettergevoelig): Microsoft.Storage, Microsoft.Keyvault
|
|
keyvaultproperties
|
KeyVaultProperties
|
|
Eigenschappen die worden geleverd door de sleutelkluis.
|
|
requireInfrastructureEncryption
|
boolean
|
|
Een Booleaanse waarde die aangeeft of de service een secundaire versleutelingslaag toepast met door het platform beheerde sleutels voor data-at-rest.
|
|
services
|
EncryptionServices
|
|
Lijst met services die versleuteling ondersteunen.
|
EncryptionIdentity
Object
Versleutelingsidentiteit voor het opslagaccount.
| Naam |
Type |
Description |
|
federatedIdentityClientId
|
string
|
ClientId van de toepassing met meerdere tenants die moet worden gebruikt in combinatie met de door de gebruiker toegewezen identiteit voor versleuteling aan de serverzijde van meerdere tenants door de klant beheerde sleutels aan de serverzijde van het opslagaccount.
|
|
userAssignedIdentity
|
string
|
Resource-id van de userAssigned-identiteit die moet worden gekoppeld aan versleuteling aan de serverzijde van het opslagaccount.
|
EncryptionService
Object
Een service waarmee versleuteling aan de serverzijde kan worden gebruikt.
| Naam |
Type |
Description |
|
enabled
|
boolean
|
Een Booleaanse waarde die aangeeft of de service de gegevens versleutelt terwijl deze worden opgeslagen. Versleuteling-at-rest is standaard ingeschakeld en kan niet worden uitgeschakeld.
|
|
keyType
|
KeyType
|
Het type versleutelingssleutel dat moet worden gebruikt voor de versleutelingsservice. Het sleuteltype Account impliceert dat een versleutelingssleutel met accountbereik wordt gebruikt. Het sleuteltype Service impliceert dat een standaardservicesleutel wordt gebruikt.
|
|
lastEnabledTime
|
string
(date-time)
|
Hiermee wordt een ruwe schatting opgehaald van de datum/tijd waarop de versleuteling voor het laatst is ingeschakeld door de gebruiker. Gegevens worden standaard in rust versleuteld en kunnen niet worden uitgeschakeld.
|
EncryptionServices
Object
Een lijst met services die ondersteuning bieden voor versleuteling.
Endpoints
Object
De URI's die worden gebruikt voor het ophalen van een openbare blob, wachtrij, tabel, web- of dfs-object.
| Naam |
Type |
Description |
|
blob
|
string
|
Hiermee haalt u het blob-eindpunt op.
|
|
dfs
|
string
|
Hiermee haalt u het dfs-eindpunt op.
|
|
file
|
string
|
Hiermee haalt u het bestandseindpunt op.
|
|
internetEndpoints
|
StorageAccountInternetEndpoints
|
Haalt de eindpunten voor internetrouteringsopslag op
|
|
ipv6Endpoints
|
StorageAccountIpv6Endpoints
|
Hiermee haalt u de IPv6-opslageindpunten op.
|
|
microsoftEndpoints
|
StorageAccountMicrosoftEndpoints
|
Hiermee haalt u de eindpunten voor microsoft-routeringsopslag op.
|
|
queue
|
string
|
Hiermee wordt het eindpunt van de wachtrij opgehaald.
|
|
table
|
string
|
Hiermee haalt u het tabeleindpunt op.
|
|
web
|
string
|
Hiermee haalt u het webeindpunt op.
|
ErrorResponse
Object
Een foutreactie van de opslagresourceprovider.
| Naam |
Type |
Description |
|
error
|
ErrorResponseBody
|
Azure Storage Resource Provider error response body.
|
ErrorResponseBody
Object
Contract voor antwoordtekst van fout.
| Naam |
Type |
Description |
|
code
|
string
|
Een id voor de fout. Codes zijn invariant en zijn bedoeld om programmatisch te worden gebruikt.
|
|
message
|
string
|
Een bericht met een beschrijving van de fout, bedoeld om te worden weergegeven in een gebruikersinterface.
|
ExpirationAction
Opsomming
De SAS-verloopactie definieert de actie die moet worden uitgevoerd wanneer sasPolicy.sasExpirationPeriod wordt geschonden. De actie Logboek kan worden gebruikt voor controledoeleinden en de actie Blokkeren kan worden gebruikt om het gebruik van SAS-tokens te blokkeren en te weigeren die niet voldoen aan de verloopperiode van het SAS-beleid.
| Waarde |
Description |
|
Log
|
|
|
Block
|
|
ExtendedLocation
Object
Het complexe type van de uitgebreide locatie.
| Naam |
Type |
Description |
|
name
|
string
|
De naam van de uitgebreide locatie.
|
|
type
|
ExtendedLocationTypes
|
Het type van de uitgebreide locatie.
|
ExtendedLocationTypes
Opsomming
Het type extendedLocation.
| Waarde |
Description |
|
EdgeZone
|
|
GeoPriorityReplicationStatus
Object
Status voor het inschakelen van Geo Priority Replication voor het opslagaccount.
| Naam |
Type |
Description |
|
isBlobEnabled
|
boolean
|
Geeft aan of Blob Geo Priority Replication is ingeschakeld voor het opslagaccount.
|
GeoReplicationStats
Object
Statistieken met betrekking tot replicatie voor de blob-, tabel-, wachtrij- en bestandsservices van het opslagaccount. Deze is alleen beschikbaar wanneer geografisch redundante replicatie is ingeschakeld voor het opslagaccount.
| Naam |
Type |
Description |
|
canFailover
|
boolean
|
Een booleaanse vlag die aangeeft of failover van een account wel of niet wordt ondersteund voor het account.
|
|
canPlannedFailover
|
boolean
|
Een booleaanse vlag die aangeeft of failover van gepland account wel of niet wordt ondersteund voor het account.
|
|
lastSyncTime
|
string
(date-time)
|
Alle primaire schrijfbewerkingen voorafgaand aan deze UTC-datum/tijd-waarde zijn gegarandeerd beschikbaar voor leesbewerkingen. Primaire schrijfbewerkingen na dit tijdstip zijn mogelijk of niet beschikbaar voor leesbewerkingen. Het element kan de standaardwaarde zijn als de waarde van LastSyncTime niet beschikbaar is, dit kan gebeuren als secundair offline is of als we in bootstrap zitten.
|
|
postFailoverRedundancy
|
PostFailoverRedundancy
|
Het redundantietype van het account nadat een accountfailover is uitgevoerd.
|
|
postPlannedFailoverRedundancy
|
PostPlannedFailoverRedundancy
|
Het redundantietype van het account nadat een failover van een gepland account is uitgevoerd.
|
|
status
|
GeoReplicationStatus
|
De status van de secundaire locatie. Mogelijke waarden zijn: - Live: Geeft aan dat de secundaire locatie actief en operationeel is. - Bootstrap: Geeft de initiële synchronisatie van de primaire locatie naar de secundaire locatie wordt uitgevoerd. Dit gebeurt meestal wanneer replicatie voor het eerst wordt ingeschakeld. - Niet beschikbaar: geeft aan dat de secundaire locatie tijdelijk niet beschikbaar is.
|
GeoReplicationStatus
Opsomming
De status van de secundaire locatie. Mogelijke waarden zijn: - Live: Geeft aan dat de secundaire locatie actief en operationeel is. - Bootstrap: Geeft de initiële synchronisatie van de primaire locatie naar de secundaire locatie wordt uitgevoerd. Dit gebeurt meestal wanneer replicatie voor het eerst wordt ingeschakeld. - Niet beschikbaar: geeft aan dat de secundaire locatie tijdelijk niet beschikbaar is.
| Waarde |
Description |
|
Live
|
|
|
Bootstrap
|
|
|
Unavailable
|
|
Identity
Object
Identiteit voor de resource.
| Naam |
Type |
Description |
|
principalId
|
string
|
De principal-id van de resource-id.
|
|
tenantId
|
string
|
De tenant-id van de resource.
|
|
type
|
IdentityType
|
Het identiteitstype.
|
|
userAssignedIdentities
|
<string,
UserAssignedIdentity>
|
Hiermee haalt u een lijst op met sleutel-waardeparen die de set door de gebruiker toegewezen identiteiten beschrijven die worden gebruikt met dit opslagaccount. De sleutel is de ARM-resource-id van de identiteit. Hier is slechts 1 door de gebruiker toegewezen identiteit toegestaan.
|
IdentityType
Opsomming
Het identiteitstype.
| Waarde |
Description |
|
None
|
|
|
SystemAssigned
|
|
|
UserAssigned
|
|
|
SystemAssigned,UserAssigned
|
|
ImmutableStorageAccount
Object
Met deze eigenschap kunt u onveranderbaarheid op accountniveau inschakelen en definiëren. Als u de functie inschakelt, wordt blobversiebeheer automatisch ingeschakeld.
| Naam |
Type |
Description |
|
enabled
|
boolean
|
Een Booleaanse vlag die onveranderbaarheid op accountniveau mogelijk maakt. Alle containers onder een dergelijk account hebben standaard onveranderbaarheid op objectniveau ingeschakeld.
|
|
immutabilityPolicy
|
AccountImmutabilityPolicyProperties
|
Hiermee geeft u het standaardbeleid voor onveranderbaarheid op accountniveau op dat wordt overgenomen en toegepast op objecten die geen expliciet onveranderbaarheidsbeleid op objectniveau hebben. Het beleid voor onveranderbaarheid op objectniveau heeft een hogere prioriteit dan het beleid voor onveranderbaarheid op containerniveau, dat een hogere prioriteit heeft dan het beleid voor onveranderbaarheid op accountniveau.
|
IPRule
Object
IP-regel met een specifiek IP- of IP-bereik in CIDR-indeling.
| Naam |
Type |
Description |
|
action
|
enum:
Allow
|
De actie van de IP-ACL-regel.
|
|
value
|
string
|
Hiermee geeft u het IP- of IP-bereik in CIDR-indeling op.
|
KeyCreationTime
Object
Tijd voor het maken van opslagaccountsleutels.
| Naam |
Type |
Description |
|
key1
|
string
(date-time)
|
|
|
key2
|
string
(date-time)
|
|
KeyPolicy
Object
KeyPolicy toegewezen aan het opslagaccount.
| Naam |
Type |
Description |
|
keyExpirationPeriodInDays
|
integer
(int32)
|
De verloopperiode van de sleutel in dagen.
|
KeySource
Opsomming
De versleutelingssleutelbron (provider). Mogelijke waarden (hoofdlettergevoelig): Microsoft.Storage, Microsoft.Keyvault
| Waarde |
Description |
|
Microsoft.Storage
|
|
|
Microsoft.Keyvault
|
|
KeyType
Opsomming
Het type versleutelingssleutel dat moet worden gebruikt voor de versleutelingsservice. Het sleuteltype Account impliceert dat een versleutelingssleutel met accountbereik wordt gebruikt. Het sleuteltype Service impliceert dat een standaardservicesleutel wordt gebruikt.
| Waarde |
Description |
|
Service
|
|
|
Account
|
|
KeyVaultProperties
Object
Eigenschappen van de sleutelkluis.
| Naam |
Type |
Description |
|
currentVersionedKeyExpirationTimestamp
|
string
(date-time)
|
Dit is een alleen-lezen eigenschap die de verlooptijd aangeeft van de huidige versie van de door de klant beheerde sleutel die wordt gebruikt voor versleuteling.
|
|
currentVersionedKeyIdentifier
|
string
|
De object-id van de huidige key vault-sleutel met versiebeheer.
|
|
keyname
|
string
|
De naam van de KeyVault-sleutel.
|
|
keyvaulturi
|
string
|
De URI van KeyVault.
|
|
keyversion
|
string
|
De versie van de KeyVault-sleutel.
|
|
lastKeyRotationTimestamp
|
string
(date-time)
|
Tijdstempel van laatste draaiing van de Key Vault-sleutel.
|
Kind
Opsomming
Geeft het type opslagaccount aan.
| Waarde |
Description |
|
Storage
|
|
|
StorageV2
|
|
|
BlobStorage
|
|
|
FileStorage
|
|
|
BlockBlobStorage
|
|
LargeFileSharesState
Opsomming
Sta grote bestandsshares toe als deze is ingesteld op Ingeschakeld. Deze kan niet worden uitgeschakeld zodra deze is ingeschakeld.
| Waarde |
Description |
|
Disabled
|
|
|
Enabled
|
|
MinimumTlsVersion
Opsomming
Stel de minimale TLS-versie in die is toegestaan voor aanvragen voor opslag. De standaardinterpretatie is TLS 1.0 voor deze eigenschap. Minimale TLS versie 1.3 wordt niet ondersteund.
| Waarde |
Description |
|
TLS1_0
|
|
|
TLS1_1
|
|
|
TLS1_2
|
|
|
TLS1_3
|
|
NetworkRuleSet
Object
Netwerkregelset
| Naam |
Type |
Default value |
Description |
|
bypass
|
Bypass
|
AzureServices
|
Hiermee geeft u op of verkeer wordt omzeild voor logboekregistratie/metrics/AzureServices. Mogelijke waarden zijn een combinatie van logboekregistratie|Metrische gegevens |AzureServices (bijvoorbeeld 'Logboekregistratie, metrische gegevens') of Geen om geen van deze verkeer te omzeilen.
|
|
defaultAction
|
DefaultAction
|
Allow
|
Hiermee geeft u de standaardactie toestaan of weigeren wanneer er geen andere regels overeenkomen.
|
|
ipRules
|
IPRule[]
|
|
Hiermee stelt u de IP-ACL-regels in
|
|
ipv6Rules
|
IPRule[]
|
|
Hiermee stelt u de IPv6 ACL-regels in.
|
|
resourceAccessRules
|
ResourceAccessRule[]
|
|
Hiermee stelt u de toegangsregels voor resources in
|
|
virtualNetworkRules
|
VirtualNetworkRule[]
|
|
Hiermee stelt u de regels voor het virtuele netwerk in
|
Placement
Object
Het complexe type van de zonale plaatsingsdetails.
| Naam |
Type |
Description |
|
zonePlacementPolicy
|
ZonePlacementPolicy
|
Het vastmaakbeleid voor de beschikbaarheidszone voor het opslagaccount.
|
PolicyViolationAction
Opsomming
De actie die wordt uitgevoerd wanneer een SAS-(shared access signature) beleidsvereiste voor gebruikersdelegatie wordt geschonden.
| Waarde |
Description |
|
None
|
Er wordt geen actie ondernomen wanneer de beleidsvereiste wordt overtreden.
|
|
Log
|
De beleidsovertreding wordt geregistreerd voor auditdoeleinden.
|
|
Block
|
Het verzoek wordt geblokkeerd en afgewezen wanneer de beleidsvereiste wordt overtreden.
|
PostFailoverRedundancy
Opsomming
Het redundantietype van het account nadat een accountfailover is uitgevoerd.
| Waarde |
Description |
|
Standard_LRS
|
|
|
Standard_ZRS
|
|
PostPlannedFailoverRedundancy
Opsomming
Het redundantietype van het account nadat een failover van een gepland account is uitgevoerd.
| Waarde |
Description |
|
Standard_GRS
|
|
|
Standard_GZRS
|
|
|
Standard_RAGRS
|
|
|
Standard_RAGZRS
|
|
PrivateEndpoint
Object
De privé-eindpuntresource.
| Naam |
Type |
Description |
|
id
|
string
|
De ARM-id voor privé-eindpunt
|
PrivateEndpointConnection
Object
De privé-eindpuntverbindingsresource.
| Naam |
Type |
Description |
|
id
|
string
(arm-id)
|
Volledig gekwalificeerde resource-id voor de resource. Bijvoorbeeld /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceType}/{resourceName}"
|
|
name
|
string
|
De naam van de resource
|
|
properties.privateEndpoint
|
PrivateEndpoint
|
De resource van het privé-eindpunt.
|
|
properties.privateLinkServiceConnectionState
|
PrivateLinkServiceConnectionState
|
Een verzameling informatie over de status van de verbinding tussen serviceconsumer en provider.
|
|
properties.provisioningState
|
PrivateEndpointConnectionProvisioningState
|
De inrichtingsstatus van de privé-eindpuntverbindingsresource.
|
|
systemData
|
systemData
|
Azure Resource Manager-metagegevens met createdBy- en modifiedBy-gegevens.
|
|
type
|
string
|
Het type bron. Bijvoorbeeld 'Microsoft.Compute/virtualMachines' of 'Microsoft.Storage/storageAccounts'
|
PrivateEndpointConnectionProvisioningState
Opsomming
De huidige inrichtingsstatus.
| Waarde |
Description |
|
Succeeded
|
|
|
Creating
|
|
|
Deleting
|
|
|
Failed
|
|
PrivateEndpointServiceConnectionStatus
Opsomming
De verbindingsstatus van het privé-eindpunt.
| Waarde |
Description |
|
Pending
|
|
|
Approved
|
|
|
Rejected
|
|
PrivateLinkServiceConnectionState
Object
Een verzameling informatie over de status van de verbinding tussen serviceconsumer en provider.
| Naam |
Type |
Description |
|
actionRequired
|
string
|
Een bericht dat aangeeft of wijzigingen in de serviceprovider updates voor de consument vereisen.
|
|
description
|
string
|
De reden voor goedkeuring/afwijzing van de verbinding.
|
|
status
|
PrivateEndpointServiceConnectionStatus
|
Geeft aan of de verbinding is goedgekeurd/geweigerd/verwijderd door de eigenaar van de service.
|
ProvisioningState
Opsomming
Hiermee wordt de status van het opslagaccount opgehaald op het moment dat de bewerking werd aangeroepen.
| Waarde |
Description |
|
Creating
|
|
|
ResolvingDNS
|
|
|
Succeeded
|
|
PublicNetworkAccess
Opsomming
Hiermee kunt u de perimeterconfiguratie van netwerkbeveiliging toestaan, weigeren of toestaan om openbare netwerktoegang tot het opslagaccount te evalueren. De waarde is optioneel, maar moet zijn ingeschakeld, uitgeschakeld of SecuredByPerimeter.
| Waarde |
Description |
|
Enabled
|
|
|
Disabled
|
|
|
SecuredByPerimeter
|
|
ResourceAccessRule
Object
Regel voor toegang tot resources.
| Naam |
Type |
Description |
|
resourceId
|
string
|
Resource-id
|
|
tenantId
|
string
|
Tenant-id
|
RoutingChoice
Opsomming
Routeringskeuze definieert het type netwerkroutering dat door de gebruiker is gekozen.
| Waarde |
Description |
|
MicrosoftRouting
|
|
|
InternetRouting
|
|
RoutingPreference
Object
Routeringsvoorkeur definieert het type netwerk, microsoft of internetroutering dat moet worden gebruikt om de gebruikersgegevens te leveren. De standaardoptie is Microsoft-routering
| Naam |
Type |
Description |
|
publishInternetEndpoints
|
boolean
|
Een booleaanse vlag die aangeeft of eindpunten voor internetroutering moeten worden gepubliceerd
|
|
publishMicrosoftEndpoints
|
boolean
|
Een booleaanse vlag die aangeeft of microsoft-routeringsopslageindpunten moeten worden gepubliceerd
|
|
routingChoice
|
RoutingChoice
|
Routeringskeuze definieert het type netwerkroutering dat door de gebruiker is gekozen.
|
SasPolicy
Object
SasPolicy toegewezen aan het opslagaccount.
| Naam |
Type |
Default value |
Description |
|
expirationAction
|
ExpirationAction
|
Log
|
De SAS-verloopactie definieert de actie die moet worden uitgevoerd wanneer sasPolicy.sasExpirationPeriod wordt geschonden. De actie Logboek kan worden gebruikt voor controledoeleinden en de actie Blokkeren kan worden gebruikt om het gebruik van SAS-tokens te blokkeren en te weigeren die niet voldoen aan de verloopperiode van het SAS-beleid.
|
|
requireUserBoundUserDelegationSas
|
boolean
|
|
Geeft aan of gebruikersdelegatie-SAS (shared access signature) tokens verplicht zijn gebonden aan een specifieke gebruiker. De standaardinterpretatie is onwaar voor deze eigenschap.
|
|
requireUserBoundUserDelegationSasAction
|
PolicyViolationAction
|
|
De actie die wordt uitgevoerd wanneer een gebruikersdelegatietoken voor SAS (shared access signature) niet aan een gebruiker wordt gebonden zoals vereist door revireUserBoundUserDelegationSas.
|
|
sasExpirationPeriod
|
string
|
|
De SAS-verloopperiode, DD.HH:MM:SS.
|
ServiceSharedKeyAccessProperties
Object
Definieert instellingen voor gedeelde sleuteltoegang voor een individuele opslagdienst.
| Naam |
Type |
Description |
|
enabled
|
boolean
|
Geeft aan of gedeelde sleuteltoegang is ingeschakeld voor de dienst.
|
Sku
Object
De SKU van het opslagaccount.
| Naam |
Type |
Description |
|
name
|
SkuName
|
De SKU-naam. Vereist voor het maken van accounts; optioneel voor update. Houd er rekening mee dat in oudere versies de SKU-naam accountType is genoemd.
|
|
tier
|
SkuTier
|
Het SKU-niveau. Dit is gebaseerd op de SKU-naam.
|
SkuConversionStatus
Opsomming
Deze eigenschap geeft de huidige SKU-conversiestatus aan.
| Waarde |
Description |
|
InProgress
|
|
|
Succeeded
|
|
|
Failed
|
|
SkuName
Opsomming
De SKU-naam. Vereist voor het maken van accounts; optioneel voor update. Houd er rekening mee dat in oudere versies de SKU-naam accountType is genoemd.
| Waarde |
Description |
|
Standard_LRS
|
|
|
Standard_GRS
|
|
|
Standard_RAGRS
|
|
|
Standard_ZRS
|
|
|
Premium_LRS
|
|
|
Premium_ZRS
|
|
|
Standard_GZRS
|
|
|
Standard_RAGZRS
|
|
|
StandardV2_LRS
|
|
|
StandardV2_GRS
|
|
|
StandardV2_ZRS
|
|
|
StandardV2_GZRS
|
|
|
PremiumV2_LRS
|
|
|
PremiumV2_ZRS
|
|
SkuTier
Opsomming
Het SKU-niveau. Dit is gebaseerd op de SKU-naam.
| Waarde |
Description |
|
Standard
|
|
|
Premium
|
|
SmbOAuthSettings
Object
Eigenschap instellen voor Managed Identity-toegang via SMB met behulp van OAuth
| Naam |
Type |
Description |
|
isSmbOAuthEnabled
|
boolean
|
Hiermee geeft u op of beheerde identiteiten toegang hebben tot SMB-shares met behulp van OAuth. De standaardinterpretatie is onwaar voor deze eigenschap.
|
State
Opsomming
Hiermee haalt u de status van de regel voor het virtuele netwerk op.
| Waarde |
Description |
|
Provisioning
|
|
|
Deprovisioning
|
|
|
Succeeded
|
|
|
Failed
|
|
|
NetworkSourceDeleted
|
|
StorageAccount
Object
Het opslagaccount.
| Naam |
Type |
Description |
|
extendedLocation
|
ExtendedLocation
|
De extendedLocation van de resource.
|
|
id
|
string
(arm-id)
|
Volledig gekwalificeerde resource-id voor de resource. Bijvoorbeeld /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceType}/{resourceName}"
|
|
identity
|
Identity
|
De identiteit van de resource.
|
|
kind
|
Kind
|
Krijgt het Kind.
|
|
location
|
string
|
De geografische locatie waar de resource zich bevindt
|
|
name
|
string
|
De naam van de resource
|
|
placement
|
Placement
|
Optional. Hiermee haalt u de zoneplaatsingsgegevens voor het opslagaccount op of stelt u deze in.
|
|
properties.accessTier
|
AccessTier
|
Vereist voor opslagaccounts waarbij soort = BlobStorage. De toegangslaag wordt gebruikt voor facturering. De toegangslaag Premium is de standaardwaarde voor het opslagaccounttype Premium-blok-blobs en kan niet worden gewijzigd voor het opslagaccounttype premium blok-blobs.
|
|
properties.accountMigrationInProgress
|
boolean
|
Als de door de klant geïnitieerde accountmigratie wordt uitgevoerd, is de waarde waar, anders is deze null.
|
|
properties.allowBlobPublicAccess
|
boolean
|
Openbare toegang tot alle blobs of containers in het opslagaccount toestaan of weigeren. De standaardinterpretatie is onwaar voor deze eigenschap.
|
|
properties.allowCrossTenantDelegationSas
|
boolean
|
Sta wel of niet toe dat je een SAS (shared access signature) tussen AAD tenant-gebruikers delegeerde en niet toestaat. De standaardinterpretatie is onwaar voor deze eigenschap.
|
|
properties.allowCrossTenantReplication
|
boolean
|
Replicatie van meerdere AAD-tenantobjecten toestaan of weigeren. Stel deze eigenschap alleen in op waar voor nieuwe of bestaande accounts als objectreplicatiebeleid opslagaccounts in verschillende AAD-tenants omvat. De standaardinterpretatie is onwaar voor nieuwe accounts om standaard de aanbevolen beveiligingsprocedures te volgen.
|
|
properties.allowSharedKeyAccess
|
boolean
|
Hiermee wordt aangegeven of het opslagaccount toestaat dat aanvragen worden geautoriseerd met de toegangssleutel voor het account via een gedeelde sleutel. Als het onwaar is, moeten alle verzoeken, inclusief shared access-handtekeningen, worden geautoriseerd met Azure Active Directory (Azure AD). De standaardwaarde is null, wat gelijk is aan waar.
|
|
properties.allowSharedKeyAccessForServices
|
StorageAccountSharedKeyAccessProperties
|
Geef gedeelde sleuteltoegangseigenschappen aan op serviceniveau
|
|
properties.allowedCopyScope
|
AllowedCopyScope
|
Kopiëren naar en van opslagaccounts in een AAD-tenant of met privékoppelingen naar hetzelfde VNet beperken.
|
|
properties.azureFilesIdentityBasedAuthentication
|
AzureFilesIdentityBasedAuthentication
|
Biedt de identiteitsgebaseerde authenticatie-instellingen voor Azure Files.
|
|
properties.blobRestoreStatus
|
BlobRestoreStatus
|
Status van blobherstel
|
|
properties.creationTime
|
string
(date-time)
|
Hiermee haalt u de aanmaakdatum en -tijd van het opslagaccount op in UTC.
|
|
properties.customDomain
|
CustomDomain
|
Hiermee haalt u het aangepaste domein op dat de gebruiker heeft toegewezen aan dit opslagaccount.
|
|
properties.dataCollaborationPolicyProperties
|
StorageDataCollaborationPolicyProperties
|
Data Collaboration-beleid voor het opslagaccount.
|
|
properties.defaultToOAuthAuthentication
|
boolean
|
Een Booleaanse vlag die aangeeft of de standaardverificatie OAuth is of niet. De standaardinterpretatie is onwaar voor deze eigenschap.
|
|
properties.dnsEndpointType
|
DnsEndpointType
|
Hiermee kunt u het type eindpunt opgeven. Stel dit in op AzureDNSZone om een groot aantal accounts in één abonnement aan te maken, wat accounts aanmaakt in een Azure DNS Zone en de endpoint-URL zal een alfanumerieke DNS Zone-identificatie hebben.
|
|
properties.dualStackEndpointPreference
|
DualStackEndpointPreference
|
Houdt informatie bij over het internetprotocol dat door de gebruiker is gekozen.
|
|
properties.enableExtendedGroups
|
boolean
|
Biedt uitgebreide groepsondersteuning met de functie lokale gebruikers, indien ingesteld op true
|
|
properties.encryption
|
Encryption
|
Versleutelingsinstellingen die moeten worden gebruikt voor versleuteling aan de serverzijde voor het opslagaccount.
|
|
properties.failoverInProgress
|
boolean
|
Als de failover wordt uitgevoerd, is de waarde waar, anders is deze null.
|
|
properties.geoPriorityReplicationStatus
|
GeoPriorityReplicationStatus
|
Status die aangeeft of Geo Priority Replication is ingeschakeld voor het account.
|
|
properties.geoReplicationStats
|
GeoReplicationStats
|
Geo-replicatiestatistieken
|
|
properties.immutableStorageWithVersioning
|
ImmutableStorageAccount
|
De eigenschap is onveranderbaar en kan alleen worden ingesteld op true tijdens het maken van het account. Als deze optie is ingesteld op waar, wordt de onveranderbaarheid op objectniveau standaard ingeschakeld voor alle containers in het account.
|
|
properties.isHnsEnabled
|
boolean
|
Account HierarchicalNamespace ingeschakeld als deze is ingesteld op waar.
|
|
properties.isLocalUserEnabled
|
boolean
|
Hiermee schakelt u de functie lokale gebruikers in, indien ingesteld op waar
|
|
properties.isNfsV3Enabled
|
boolean
|
Ondersteuning voor NFS 3.0-protocollen is ingeschakeld als deze is ingesteld op waar.
|
|
properties.isSftpEnabled
|
boolean
|
Hiermee schakelt u Secure File Transfer Protocol in, indien ingesteld op true
|
|
properties.isSkuConversionBlocked
|
boolean
|
Deze eigenschap wordt ingesteld op waar of onwaar voor een gebeurtenis van doorlopende migratie. De standaardwaarde is null.
|
|
properties.keyCreationTime
|
KeyCreationTime
|
Tijd voor het maken van opslagaccountsleutels.
|
|
properties.keyPolicy
|
KeyPolicy
|
KeyPolicy toegewezen aan het opslagaccount.
|
|
properties.largeFileSharesState
|
LargeFileSharesState
|
Sta grote bestandsshares toe als deze is ingesteld op Ingeschakeld. Deze kan niet worden uitgeschakeld zodra deze is ingeschakeld.
|
|
properties.lastGeoFailoverTime
|
string
(date-time)
|
Hiermee haalt u de tijdstempel op van het meest recente exemplaar van een failover naar de secundaire locatie. Alleen de meest recente tijdstempel wordt bewaard. Dit element wordt niet geretourneerd als er nog nooit een failover-exemplaar is geweest. Alleen beschikbaar als het accountType is Standard_GRS of Standard_RAGRS.
|
|
properties.minimumTlsVersion
|
MinimumTlsVersion
|
Stel de minimale TLS-versie in die is toegestaan voor aanvragen voor opslag. De standaardinterpretatie is TLS 1.0 voor deze eigenschap. Minimale TLS versie 1.3 wordt niet ondersteund.
|
|
properties.networkAcls
|
NetworkRuleSet
|
Netwerkregelset
|
|
properties.primaryEndpoints
|
Endpoints
|
Hiermee haalt u de URL's op die worden gebruikt voor het ophalen van een openbare blob, wachtrij of tabelobject. Houd er rekening mee dat Standard_ZRS en Premium_LRS accounts alleen het blob-eindpunt retourneren.
|
|
properties.primaryLocation
|
string
|
Hiermee haalt u de locatie op van het primaire datacenter voor het opslagaccount.
|
|
properties.privateEndpointConnections
|
PrivateEndpointConnection[]
|
Lijst met privé-eindpuntverbindingen die zijn gekoppeld aan het opgegeven opslagaccount
|
|
properties.provisioningState
|
ProvisioningState
|
Hiermee wordt de status van het opslagaccount opgehaald op het moment dat de bewerking werd aangeroepen.
|
|
properties.publicNetworkAccess
|
PublicNetworkAccess
|
Hiermee kunt u de perimeterconfiguratie van netwerkbeveiliging toestaan, weigeren of toestaan om openbare netwerktoegang tot het opslagaccount te evalueren.
|
|
properties.routingPreference
|
RoutingPreference
|
Onderhoudt informatie over de netwerkrouteringskeuze die door de gebruiker is gekozen voor gegevensoverdracht
|
|
properties.sasPolicy
|
SasPolicy
|
SasPolicy toegewezen aan het opslagaccount.
|
|
properties.secondaryEndpoints
|
Endpoints
|
Hiermee haalt u de URL's op die worden gebruikt voor het ophalen van een openbare blob, wachtrij of tabelobject vanaf de secundaire locatie van het opslagaccount. Alleen beschikbaar als de SKU-naam is Standard_RAGRS.
|
|
properties.secondaryLocation
|
string
|
Hiermee haalt u de locatie op van de secundaire geo-replicatie voor het opslagaccount. Alleen beschikbaar als het accountType is Standard_GRS of Standard_RAGRS.
|
|
properties.statusOfPrimary
|
AccountStatus
|
Hiermee haalt u de status op die aangeeft of de primaire locatie van het opslagaccount beschikbaar of niet beschikbaar is.
|
|
properties.statusOfSecondary
|
AccountStatus
|
Hiermee haalt u de status op die aangeeft of de secundaire locatie van het opslagaccount beschikbaar of niet beschikbaar is. Alleen beschikbaar als de SKU-naam is Standard_GRS of Standard_RAGRS.
|
|
properties.storageAccountSkuConversionStatus
|
StorageAccountSkuConversionStatus
|
Deze eigenschap is readOnly en wordt ingesteld door de server tijdens asynchrone SKU-conversiebewerkingen van het opslagaccount.
|
|
properties.supportsHttpsTrafficOnly
|
boolean
|
Hiermee staat u https-verkeer alleen toe naar de opslagservice als deze is ingesteld op waar.
|
|
properties.turboTier
|
TurboTier
|
Configuratie van Turbo Tier voor het opslagaccount.
|
|
sku
|
Sku
|
Hiermee haalt u de SKU op.
|
|
systemData
|
systemData
|
Azure Resource Manager-metagegevens met createdBy- en modifiedBy-gegevens.
|
|
tags
|
object
|
Resourcetags.
|
|
type
|
string
|
Het type bron. Bijvoorbeeld 'Microsoft.Compute/virtualMachines' of 'Microsoft.Storage/storageAccounts'
|
|
zones
|
string[]
|
De beschikbaarheidszones.
|
StorageAccountCreateParameters
Object
De parameters die worden gebruikt bij het maken van een opslagaccount.
| Naam |
Type |
Description |
|
extendedLocation
|
ExtendedLocation
|
Optional. Stel de uitgebreide locatie van de resource in. Als dit niet is ingesteld, wordt het opslagaccount gemaakt in de hoofdregio van Azure. Anders wordt deze gemaakt op de opgegeven uitgebreide locatie
|
|
identity
|
Identity
|
De identiteit van de resource.
|
|
kind
|
Kind
|
Required. Geeft het type opslagaccount aan.
|
|
location
|
string
|
Required. Hiermee haalt u de locatie van de resource op of stelt u deze in. Dit is een van de ondersteunde en geregistreerde Azure Geo-regio's (bijvoorbeeld VS - west, VS - oost, Azië - zuidoost, enzovoort). De geografische regio van een resource kan niet worden gewijzigd zodra deze is gemaakt, maar als er een identieke geografische regio is opgegeven bij het bijwerken, slaagt de aanvraag.
|
|
placement
|
Placement
|
Optional. Hiermee haalt u de zoneplaatsingsgegevens voor het opslagaccount op of stelt u deze in.
|
|
properties.accessTier
|
AccessTier
|
Vereist voor opslagaccounts waarbij soort = BlobStorage. De toegangslaag wordt gebruikt voor facturering. De toegangslaag Premium is de standaardwaarde voor het opslagaccounttype Premium-blok-blobs en kan niet worden gewijzigd voor het opslagaccounttype premium blok-blobs.
|
|
properties.allowBlobPublicAccess
|
boolean
|
Openbare toegang tot alle blobs of containers in het opslagaccount toestaan of weigeren. De standaardinterpretatie is onwaar voor deze eigenschap.
|
|
properties.allowCrossTenantDelegationSas
|
boolean
|
Sta wel of niet toe dat je een SAS (shared access signature) tussen AAD tenant-gebruikers delegeerde en niet toestaat. De standaardinterpretatie is onwaar voor deze eigenschap.
|
|
properties.allowCrossTenantReplication
|
boolean
|
Replicatie van meerdere AAD-tenantobjecten toestaan of weigeren. Stel deze eigenschap alleen in op waar voor nieuwe of bestaande accounts als objectreplicatiebeleid opslagaccounts in verschillende AAD-tenants omvat. De standaardinterpretatie is onwaar voor nieuwe accounts om standaard de aanbevolen beveiligingsprocedures te volgen.
|
|
properties.allowSharedKeyAccess
|
boolean
|
Hiermee wordt aangegeven of het opslagaccount toestaat dat aanvragen worden geautoriseerd met de toegangssleutel voor het account via een gedeelde sleutel. Als het onwaar is, moeten alle verzoeken, inclusief shared access-handtekeningen, worden geautoriseerd met Azure Active Directory (Azure AD). De standaardwaarde is null, wat gelijk is aan waar.
|
|
properties.allowSharedKeyAccessForServices
|
StorageAccountSharedKeyAccessProperties
|
Geef gedeelde sleuteltoegangseigenschappen aan op serviceniveau
|
|
properties.allowedCopyScope
|
AllowedCopyScope
|
Kopiëren naar en van opslagaccounts in een AAD-tenant of met privékoppelingen naar hetzelfde VNet beperken.
|
|
properties.azureFilesIdentityBasedAuthentication
|
AzureFilesIdentityBasedAuthentication
|
Biedt de identiteitsgebaseerde authenticatie-instellingen voor Azure Files.
|
|
properties.customDomain
|
CustomDomain
|
Gebruikersdomein dat is toegewezen aan het opslagaccount. De naam is de CNAME-bron. Op dit moment wordt slechts één aangepast domein ondersteund per opslagaccount. Als u het bestaande aangepaste domein wilt wissen, gebruikt u een lege tekenreeks voor de eigenschap aangepaste domeinnaam.
|
|
properties.dataCollaborationPolicyProperties
|
StorageDataCollaborationPolicyProperties
|
Data Collaboration-beleid voor het opslagaccount.
|
|
properties.defaultToOAuthAuthentication
|
boolean
|
Een Booleaanse vlag die aangeeft of de standaardverificatie OAuth is of niet. De standaardinterpretatie is onwaar voor deze eigenschap.
|
|
properties.dnsEndpointType
|
DnsEndpointType
|
Hiermee kunt u het type eindpunt opgeven. Stel dit in op AzureDNSZone om een groot aantal accounts in één abonnement aan te maken, wat accounts aanmaakt in een Azure DNS Zone en de endpoint-URL zal een alfanumerieke DNS Zone-identificatie hebben.
|
|
properties.dualStackEndpointPreference
|
DualStackEndpointPreference
|
Houdt informatie bij over het internetprotocol dat door de gebruiker is gekozen.
|
|
properties.enableExtendedGroups
|
boolean
|
Biedt uitgebreide groepsondersteuning met de functie lokale gebruikers, indien ingesteld op true
|
|
properties.encryption
|
Encryption
|
Versleutelingsinstellingen die moeten worden gebruikt voor versleuteling aan de serverzijde voor het opslagaccount.
|
|
properties.geoPriorityReplicationStatus
|
GeoPriorityReplicationStatus
|
Status die aangeeft of Geo Priority Replication is ingeschakeld voor het account.
|
|
properties.immutableStorageWithVersioning
|
ImmutableStorageAccount
|
De eigenschap is onveranderbaar en kan alleen worden ingesteld op true tijdens het maken van het account. Als deze optie is ingesteld op waar, wordt de onveranderbaarheid op objectniveau standaard ingeschakeld voor alle nieuwe containers in het account.
|
|
properties.isHnsEnabled
|
boolean
|
Account HierarchicalNamespace ingeschakeld als deze is ingesteld op waar.
|
|
properties.isLocalUserEnabled
|
boolean
|
Hiermee schakelt u de functie lokale gebruikers in, indien ingesteld op waar
|
|
properties.isNfsV3Enabled
|
boolean
|
Ondersteuning voor NFS 3.0-protocollen is ingeschakeld als deze is ingesteld op waar.
|
|
properties.isSftpEnabled
|
boolean
|
Hiermee schakelt u Secure File Transfer Protocol in, indien ingesteld op true
|
|
properties.keyPolicy
|
KeyPolicy
|
KeyPolicy toegewezen aan het opslagaccount.
|
|
properties.largeFileSharesState
|
LargeFileSharesState
|
Sta grote bestandsshares toe als deze is ingesteld op Ingeschakeld. Deze kan niet worden uitgeschakeld zodra deze is ingeschakeld.
|
|
properties.minimumTlsVersion
|
MinimumTlsVersion
|
Stel de minimale TLS-versie in die is toegestaan voor aanvragen voor opslag. De standaardinterpretatie is TLS 1.0 voor deze eigenschap. Minimale TLS versie 1.3 wordt niet ondersteund.
|
|
properties.networkAcls
|
NetworkRuleSet
|
Netwerkregelset
|
|
properties.publicNetworkAccess
|
PublicNetworkAccess
|
Hiermee kunt u de perimeterconfiguratie van netwerkbeveiliging toestaan, weigeren of toestaan om openbare netwerktoegang tot het opslagaccount te evalueren. De waarde is optioneel, maar moet zijn ingeschakeld, uitgeschakeld of SecuredByPerimeter.
|
|
properties.routingPreference
|
RoutingPreference
|
Onderhoudt informatie over de netwerkrouteringskeuze die door de gebruiker is gekozen voor gegevensoverdracht
|
|
properties.sasPolicy
|
SasPolicy
|
SasPolicy toegewezen aan het opslagaccount.
|
|
properties.supportsHttpsTrafficOnly
|
boolean
|
Hiermee staat u https-verkeer alleen toe naar de opslagservice als deze is ingesteld op waar. De standaardwaarde is waar sinds API-versie 2019-04-01.
|
|
properties.turboTier
|
TurboTier
|
Configuratie van Turbo Tier voor het opslagaccount.
|
|
sku
|
Sku
|
Required. Hiermee haalt u de SKU-naam op of stelt u deze in.
|
|
tags
|
object
|
Hiermee wordt een lijst met sleutel-waardeparen opgehaald of ingesteld die de resource beschrijven. Deze tags kunnen worden gebruikt voor het weergeven en groeperen van deze resource (tussen resourcegroepen). Er kunnen maximaal 15 tags worden opgegeven voor een resource. Elke tag moet een sleutel hebben met een lengte van maximaal 128 tekens en een waarde met een lengte van maximaal 256 tekens.
|
|
zones
|
string[]
|
Optional. Hiermee haalt u de vastgemaakte logische beschikbaarheidszone voor het opslagaccount op of stelt u deze in.
|
StorageAccountInternetEndpoints
Object
De URI's die worden gebruikt voor het ophalen van een openbare blob, bestand, web of dfs-object via een eindpunt voor internetroutering.
| Naam |
Type |
Description |
|
blob
|
string
|
Hiermee haalt u het blob-eindpunt op.
|
|
dfs
|
string
|
Hiermee haalt u het dfs-eindpunt op.
|
|
file
|
string
|
Hiermee haalt u het bestandseindpunt op.
|
|
web
|
string
|
Hiermee haalt u het webeindpunt op.
|
StorageAccountIpv6Endpoints
Object
De URI's die worden gebruikt om een openbare blob, wachtrij, tabel, web of dfs-object op te halen via een IPv6-eindpunt.
| Naam |
Type |
Description |
|
blob
|
string
|
Hiermee haalt u het blob-eindpunt op.
|
|
dfs
|
string
|
Hiermee haalt u het dfs-eindpunt op.
|
|
file
|
string
|
Hiermee haalt u het bestandseindpunt op.
|
|
internetEndpoints
|
StorageAccountInternetEndpoints
|
Haalt de eindpunten voor internetrouteringsopslag op
|
|
microsoftEndpoints
|
StorageAccountMicrosoftEndpoints
|
Hiermee haalt u de eindpunten voor microsoft-routeringsopslag op.
|
|
queue
|
string
|
Hiermee wordt het eindpunt van de wachtrij opgehaald.
|
|
table
|
string
|
Hiermee haalt u het tabeleindpunt op.
|
|
web
|
string
|
Hiermee haalt u het webeindpunt op.
|
StorageAccountMicrosoftEndpoints
Object
De URI's die worden gebruikt voor het ophalen van een openbare blob, wachtrij, tabel, web- of dfs-object via een microsoft-routeringseindpunt.
| Naam |
Type |
Description |
|
blob
|
string
|
Hiermee haalt u het blob-eindpunt op.
|
|
dfs
|
string
|
Hiermee haalt u het dfs-eindpunt op.
|
|
file
|
string
|
Hiermee haalt u het bestandseindpunt op.
|
|
queue
|
string
|
Hiermee wordt het eindpunt van de wachtrij opgehaald.
|
|
table
|
string
|
Hiermee haalt u het tabeleindpunt op.
|
|
web
|
string
|
Hiermee haalt u het webeindpunt op.
|
StorageAccountSharedKeyAccessProperties
Object
Definieert gedeelde sleuteltoegangseigenschappen voor een opslagaccount.
StorageAccountSkuConversionStatus
Object
Hiermee definieert u het SKU-conversiestatusobject voor asynchrone sKU-conversies.
| Naam |
Type |
Description |
|
endTime
|
string
|
Deze eigenschap vertegenwoordigt de eindtijd van de SKU-conversie.
|
|
skuConversionStatus
|
SkuConversionStatus
|
Deze eigenschap geeft de huidige SKU-conversiestatus aan.
|
|
startTime
|
string
|
Deze eigenschap vertegenwoordigt de begintijd van de SKU-conversie.
|
|
targetSkuName
|
SkuName
|
Deze eigenschap vertegenwoordigt de doel-sKU-naam waarnaar de account-sKU asynchroon wordt geconverteerd.
|
StorageDataCollaborationPolicyProperties
Object
Definieert Data Collaboration Policy voor een opslagaccount.
| Naam |
Type |
Description |
|
allowBlobAccessPoints
|
boolean
|
Geeft aan of Blob Access Point-configuraties mogen worden aangemaakt of beheerd op het opslagaccount.
|
|
allowCrossTenantDataSharing
|
boolean
|
Geeft aan of het delen van gegevens tussen verschillende tenants is toegestaan op het opslagaccount.
|
|
allowStorageConnectors
|
boolean
|
Geeft aan of opslagconnectoren mogen worden aangemaakt of beheerd op het opslagaccount.
|
|
allowStorageDataShares
|
boolean
|
Geeft aan of datashares mogen worden aangemaakt of beheerd op het opslagaccount.
|
systemData
Object
Metagegevens met betrekking tot het maken en de laatste wijziging van de resource.
| Naam |
Type |
Description |
|
createdAt
|
string
(date-time)
|
De tijdstempel van het aanmaken van resources (UTC).
|
|
createdBy
|
string
|
De identiteit die de resource heeft gemaakt.
|
|
createdByType
|
createdByType
|
Het identiteitstype dat de resource heeft gemaakt.
|
|
lastModifiedAt
|
string
(date-time)
|
De tijdstempel van de laatste wijziging van de resource (UTC)
|
|
lastModifiedBy
|
string
|
De identiteit die de resource voor het laatst heeft gewijzigd.
|
|
lastModifiedByType
|
createdByType
|
Het type identiteit dat de resource voor het laatst heeft gewijzigd.
|
TurboTier
Object
Stel Turbo Tier in voor een opslagaccount.
| Naam |
Type |
Description |
|
status
|
TurboTierStatus
|
Geeft aan of Turbo Tier is ingeschakeld of uitgeschakeld.
|
|
targetPercent
|
integer
(int32)
minimum: 10 maximum: 100
|
Het doel-vulpercentage dat wordt gebruikt voor plaatsing. Het geldige bereik is 10 tot 100. Wanneer status is ingeschakeld en deze eigenschap wordt weggelaten, is de standaardwaarde 20.
|
TurboTierStatus
Opsomming
Geeft aan of Turbo Tier is ingeschakeld of uitgeschakeld.
| Waarde |
Description |
|
Enabled
|
Turbo Tier is ingeschakeld.
|
|
Disabled
|
Turbo Tier is uitgeschakeld.
|
UserAssignedIdentity
Object
UserAssignedIdentity voor de resource.
| Naam |
Type |
Description |
|
clientId
|
string
|
De client-id van de identiteit.
|
|
principalId
|
string
|
De principal-id van de identiteit.
|
VirtualNetworkRule
Object
Regel voor virtueel netwerk.
| Naam |
Type |
Description |
|
action
|
enum:
Allow
|
De actie van de regel voor het virtuele netwerk.
|
|
id
|
string
|
Resource-id van een subnet, bijvoorbeeld: /subscriptions/{subscriptionId}/resourceGroups/{groupName}/providers/Microsoft.Network/virtualNetworks/{vnetName}/subnets/{subnetName}.
|
|
state
|
State
|
Hiermee haalt u de status van de regel voor het virtuele netwerk op.
|
ZonePlacementPolicy
Opsomming
Het vastmaakbeleid voor de beschikbaarheidszone voor het opslagaccount.
| Waarde |
Description |
|
Any
|
|
|
None
|
|