Create or update the metadata of the provisioning service. The usual pattern to modify a property is to retrieve the provisioning service metadata and security metadata, and then combine them with the modified values in a new body to update the provisioning service.
PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/provisioningServices/{provisioningServiceName}?api-version=2026-08-31
URI Parameters
| Name |
In |
Required |
Type |
Description |
|
provisioningServiceName
|
path |
True
|
string
|
Name of the provisioning service to retrieve.
|
|
resourceGroupName
|
path |
True
|
string
minLength: 1 maxLength: 90
|
The name of the resource group. The name is case insensitive.
|
|
subscriptionId
|
path |
True
|
string
minLength: 1
|
The ID of the target subscription.
|
|
api-version
|
query |
True
|
string
minLength: 1
|
The API version to use for this operation.
|
Request Body
| Name |
Required |
Type |
Description |
|
location
|
True
|
string
|
The geo-location where the resource lives
|
|
properties
|
True
|
IotDpsPropertiesDescription
|
Service specific properties for a provisioning service
|
|
sku
|
True
|
IotDpsSkuInfo
|
Sku info for a provisioning Service.
|
|
etag
|
|
string
|
The Etag field is not required. If it is provided in the response body, it must also be provided as a header per the normal ETag convention.
|
|
identity
|
|
ManagedServiceIdentity
|
The managed service identities assigned to this resource.
|
|
resourcegroup
|
|
string
|
The resource group of the resource.
|
|
subscriptionid
|
|
string
|
The subscription id of the resource.
|
|
tags
|
|
object
|
Resource tags.
|
Responses
Security
azure_auth
Azure Active Directory OAuth2 Flow.
Type:
oauth2
Flow:
implicit
Authorization URL:
https://login.microsoftonline.com/common/oauth2/authorize
Scopes
| Name |
Description |
|
user_impersonation
|
impersonate your user account
|
Examples
DPSCreate
Sample request
PUT https://management.azure.com/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/provisioningServices/myFirstProvisioningService?api-version=2026-08-31
{
"location": "East US",
"properties": {
"enableDataResidency": false
},
"sku": {
"name": "S1",
"capacity": 1
},
"tags": {}
}
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsPropertiesDescription;
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsSku;
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsSkuInfo;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for IotDpsResource CreateOrUpdate.
*/
public final class Main {
/*
* x-ms-original-file: 2026-08-31/DPSCreate.json
*/
/**
* Sample code: DPSCreate.
*
* @param manager Entry point to IotDpsManager.
*/
public static void dPSCreate(com.azure.resourcemanager.deviceprovisioningservices.IotDpsManager manager) {
manager.iotDpsResources().define("myFirstProvisioningService").withRegion("East US")
.withExistingResourceGroup("myResourceGroup")
.withProperties(new IotDpsPropertiesDescription().withEnableDataResidency(false))
.withSku(new IotDpsSkuInfo().withName(IotDpsSku.S1).withCapacity(1L)).withTags(mapOf()).create();
}
// 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.iothubprovisioningservices import IotDpsClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-iothubprovisioningservices
# USAGE
python dps_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 = IotDpsClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.iot_dps_resource.begin_create_or_update(
resource_group_name="myResourceGroup",
provisioning_service_name="myFirstProvisioningService",
iot_dps_description={
"location": "East US",
"properties": {"enableDataResidency": False},
"sku": {"capacity": 1, "name": "S1"},
"tags": {},
},
).result()
print(response)
# x-ms-original-file: 2026-08-31/DPSCreate.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 armdeviceprovisioningservices_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/deviceprovisioningservices/armdeviceprovisioningservices"
)
// Generated from example definition: 2026-08-31/DPSCreate.json
func ExampleIotDpsResourceClient_BeginCreateOrUpdate_dpsCreate() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armdeviceprovisioningservices.NewClientFactory("91d12660-3dec-467a-be2a-213b5544ddc0", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewIotDpsResourceClient().BeginCreateOrUpdate(ctx, "myResourceGroup", "myFirstProvisioningService", armdeviceprovisioningservices.ProvisioningServiceDescription{
Location: to.Ptr("East US"),
Properties: &armdeviceprovisioningservices.IotDpsPropertiesDescription{
EnableDataResidency: to.Ptr(false),
},
SKU: &armdeviceprovisioningservices.IotDpsSKUInfo{
Name: to.Ptr(armdeviceprovisioningservices.IotDpsSKUS1),
Capacity: to.Ptr[int64](1),
},
Tags: map[string]*string{},
}, 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 = armdeviceprovisioningservices.IotDpsResourceClientCreateOrUpdateResponse{
// ProvisioningServiceDescription: armdeviceprovisioningservices.ProvisioningServiceDescription{
// Name: to.Ptr("myFirstProvisioningService"),
// Type: to.Ptr("Microsoft.Devices/ProvisioningServices"),
// Etag: to.Ptr("AAAAAAAADGk="),
// ID: to.Ptr("/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups//providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService"),
// Location: to.Ptr("eastus"),
// Properties: &armdeviceprovisioningservices.IotDpsPropertiesDescription{
// AllocationPolicy: to.Ptr(armdeviceprovisioningservices.AllocationPolicyHashed),
// AuthorizationPolicies: []*armdeviceprovisioningservices.SharedAccessSignatureAuthorizationRuleAccessRightsDescription{
// },
// DeviceProvisioningHostName: to.Ptr("global.azure-devices-provisioning.net"),
// EnableDataResidency: to.Ptr(false),
// IDScope: to.Ptr("0ne00000012"),
// PortalOperationsHostName: to.Ptr("myFirstProvisioningService.services.azure-devices-provisioning.net"),
// ServiceOperationsHostName: to.Ptr("myFirstProvisioningService.azure-devices-provisioning.net"),
// State: to.Ptr(armdeviceprovisioningservices.StateActive),
// },
// Resourcegroup: to.Ptr("myResourceGroup"),
// SKU: &armdeviceprovisioningservices.IotDpsSKUInfo{
// Name: to.Ptr(armdeviceprovisioningservices.IotDpsSKUS1),
// Capacity: to.Ptr[int64](1),
// Tier: to.Ptr("Standard"),
// },
// Subscriptionid: to.Ptr("91d12660-3dec-467a-be2a-213b5544ddc0"),
// 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 { IotDpsClient } = require("@azure/arm-deviceprovisioningservices");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to create or update the metadata of the provisioning service. The usual pattern to modify a property is to retrieve the provisioning service metadata and security metadata, and then combine them with the modified values in a new body to update the provisioning service.
*
* @summary create or update the metadata of the provisioning service. The usual pattern to modify a property is to retrieve the provisioning service metadata and security metadata, and then combine them with the modified values in a new body to update the provisioning service.
* x-ms-original-file: 2026-08-31/DPSCreate.json
*/
async function dpsCreate() {
const credential = new DefaultAzureCredential();
const subscriptionId = "91d12660-3dec-467a-be2a-213b5544ddc0";
const client = new IotDpsClient(credential, subscriptionId);
const result = await client.iotDpsResource.createOrUpdate(
"myResourceGroup",
"myFirstProvisioningService",
{
location: "East US",
properties: { enableDataResidency: false },
sku: { name: "S1", capacity: 1 },
tags: {},
},
);
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
Sample response
{
"name": "myFirstProvisioningService",
"type": "Microsoft.Devices/ProvisioningServices",
"etag": "AAAAAAAADGk=",
"id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups//providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService",
"location": "eastus",
"properties": {
"allocationPolicy": "Hashed",
"authorizationPolicies": [],
"deviceProvisioningHostName": "global.azure-devices-provisioning.net",
"enableDataResidency": false,
"idScope": "0ne00000012",
"portalOperationsHostName": "myFirstProvisioningService.services.azure-devices-provisioning.net",
"serviceOperationsHostName": "myFirstProvisioningService.azure-devices-provisioning.net",
"state": "Active"
},
"resourcegroup": "myResourceGroup",
"sku": {
"name": "S1",
"capacity": 1,
"tier": "Standard"
},
"subscriptionid": "91d12660-3dec-467a-be2a-213b5544ddc0",
"tags": {}
}
{
"name": "myFirstProvisioningService",
"type": "Microsoft.Devices/ProvisioningServices",
"etag": "AAAAAAAADGk=",
"id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups//providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService",
"location": "eastus",
"properties": {
"allocationPolicy": "Hashed",
"authorizationPolicies": [],
"deviceProvisioningHostName": "global.azure-devices-provisioning.net",
"enableDataResidency": false,
"idScope": "0ne00000012",
"portalOperationsHostName": "myFirstProvisioningService.services.azure-devices-provisioning.net",
"serviceOperationsHostName": "myFirstProvisioningService.azure-devices-provisioning.net",
"state": "Active"
},
"resourcegroup": "myResourceGroup",
"sku": {
"name": "S1",
"capacity": 1,
"tier": "Standard"
},
"subscriptionid": "91d12660-3dec-467a-be2a-213b5544ddc0",
"tags": {}
}
DPSCreate_DisableLocalAuthFalse
Sample request
PUT https://management.azure.com/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/provisioningServices/myFirstProvisioningService?api-version=2026-08-31
{
"location": "East US",
"properties": {
"publicNetworkAccess": "Enabled",
"disableLocalAuth": false
},
"sku": {
"name": "S1",
"capacity": 1
},
"tags": {
"key1": "value1"
}
}
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsPropertiesDescription;
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsSku;
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsSkuInfo;
import com.azure.resourcemanager.deviceprovisioningservices.models.PublicNetworkAccess;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for IotDpsResource CreateOrUpdate.
*/
public final class Main {
/*
* x-ms-original-file: 2026-08-31/DPSCreate_DisableLocalAuthFalse.json
*/
/**
* Sample code: DPSCreate_DisableLocalAuthFalse.
*
* @param manager Entry point to IotDpsManager.
*/
public static void
dPSCreateDisableLocalAuthFalse(com.azure.resourcemanager.deviceprovisioningservices.IotDpsManager manager) {
manager.iotDpsResources().define("myFirstProvisioningService").withRegion("East US")
.withExistingResourceGroup("myResourceGroup")
.withProperties(new IotDpsPropertiesDescription().withPublicNetworkAccess(PublicNetworkAccess.ENABLED)
.withDisableLocalAuth(false))
.withSku(new IotDpsSkuInfo().withName(IotDpsSku.S1).withCapacity(1L))
.withTags(mapOf("key1", "fakeTokenPlaceholder")).create();
}
// 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.iothubprovisioningservices import IotDpsClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-iothubprovisioningservices
# USAGE
python dps_create_disable_local_auth_false.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 = IotDpsClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.iot_dps_resource.begin_create_or_update(
resource_group_name="myResourceGroup",
provisioning_service_name="myFirstProvisioningService",
iot_dps_description={
"location": "East US",
"properties": {"disableLocalAuth": False, "publicNetworkAccess": "Enabled"},
"sku": {"capacity": 1, "name": "S1"},
"tags": {"key1": "value1"},
},
).result()
print(response)
# x-ms-original-file: 2026-08-31/DPSCreate_DisableLocalAuthFalse.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 armdeviceprovisioningservices_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/deviceprovisioningservices/armdeviceprovisioningservices"
)
// Generated from example definition: 2026-08-31/DPSCreate_DisableLocalAuthFalse.json
func ExampleIotDpsResourceClient_BeginCreateOrUpdate_dpsCreateDisableLocalAuthFalse() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armdeviceprovisioningservices.NewClientFactory("91d12660-3dec-467a-be2a-213b5544ddc0", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewIotDpsResourceClient().BeginCreateOrUpdate(ctx, "myResourceGroup", "myFirstProvisioningService", armdeviceprovisioningservices.ProvisioningServiceDescription{
Location: to.Ptr("East US"),
Properties: &armdeviceprovisioningservices.IotDpsPropertiesDescription{
PublicNetworkAccess: to.Ptr(armdeviceprovisioningservices.PublicNetworkAccessEnabled),
DisableLocalAuth: to.Ptr(false),
},
SKU: &armdeviceprovisioningservices.IotDpsSKUInfo{
Name: to.Ptr(armdeviceprovisioningservices.IotDpsSKUS1),
Capacity: to.Ptr[int64](1),
},
Tags: map[string]*string{
"key1": to.Ptr("value1"),
},
}, 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 = armdeviceprovisioningservices.IotDpsResourceClientCreateOrUpdateResponse{
// ProvisioningServiceDescription: armdeviceprovisioningservices.ProvisioningServiceDescription{
// Name: to.Ptr("myFirstProvisioningService"),
// Type: to.Ptr("Microsoft.Devices/ProvisioningServices"),
// Etag: to.Ptr("AAAAAAAADGk="),
// ID: to.Ptr("/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService"),
// Location: to.Ptr("eastus"),
// Properties: &armdeviceprovisioningservices.IotDpsPropertiesDescription{
// AllocationPolicy: to.Ptr(armdeviceprovisioningservices.AllocationPolicyHashed),
// AuthorizationPolicies: []*armdeviceprovisioningservices.SharedAccessSignatureAuthorizationRuleAccessRightsDescription{
// },
// DeviceProvisioningHostName: to.Ptr("global.azure-devices-provisioning.net"),
// IDScope: to.Ptr("0ne00000012"),
// PortalOperationsHostName: to.Ptr("myFirstProvisioningService.services.azure-devices-provisioning.net"),
// ServiceOperationsHostName: to.Ptr("myFirstProvisioningService.azure-devices-provisioning.net"),
// State: to.Ptr(armdeviceprovisioningservices.StateActive),
// DisableLocalAuth: to.Ptr(false),
// },
// Resourcegroup: to.Ptr("myResourceGroup"),
// SKU: &armdeviceprovisioningservices.IotDpsSKUInfo{
// Name: to.Ptr(armdeviceprovisioningservices.IotDpsSKUS1),
// Capacity: to.Ptr[int64](1),
// Tier: to.Ptr("Standard"),
// },
// Subscriptionid: to.Ptr("91d12660-3dec-467a-be2a-213b5544ddc0"),
// Tags: map[string]*string{
// "key1": to.Ptr("value1"),
// },
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { IotDpsClient } = require("@azure/arm-deviceprovisioningservices");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to create or update the metadata of the provisioning service. The usual pattern to modify a property is to retrieve the provisioning service metadata and security metadata, and then combine them with the modified values in a new body to update the provisioning service.
*
* @summary create or update the metadata of the provisioning service. The usual pattern to modify a property is to retrieve the provisioning service metadata and security metadata, and then combine them with the modified values in a new body to update the provisioning service.
* x-ms-original-file: 2026-08-31/DPSCreate_DisableLocalAuthFalse.json
*/
async function dpsCreateDisableLocalAuthFalse() {
const credential = new DefaultAzureCredential();
const subscriptionId = "91d12660-3dec-467a-be2a-213b5544ddc0";
const client = new IotDpsClient(credential, subscriptionId);
const result = await client.iotDpsResource.createOrUpdate(
"myResourceGroup",
"myFirstProvisioningService",
{
location: "East US",
properties: { publicNetworkAccess: "Enabled", disableLocalAuth: false },
sku: { name: "S1", capacity: 1 },
tags: { key1: "value1" },
},
);
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
Sample response
{
"name": "myFirstProvisioningService",
"type": "Microsoft.Devices/ProvisioningServices",
"etag": "AAAAAAAADGk=",
"id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService",
"location": "eastus",
"properties": {
"allocationPolicy": "Hashed",
"authorizationPolicies": [],
"deviceProvisioningHostName": "global.azure-devices-provisioning.net",
"idScope": "0ne00000012",
"portalOperationsHostName": "myFirstProvisioningService.services.azure-devices-provisioning.net",
"serviceOperationsHostName": "myFirstProvisioningService.azure-devices-provisioning.net",
"state": "Active",
"disableLocalAuth": false
},
"resourcegroup": "myResourceGroup",
"sku": {
"name": "S1",
"capacity": 1,
"tier": "Standard"
},
"subscriptionid": "91d12660-3dec-467a-be2a-213b5544ddc0",
"tags": {
"key1": "value1"
}
}
{
"name": "myFirstProvisioningService",
"type": "Microsoft.Devices/ProvisioningServices",
"etag": "AAAAAAAADGk=",
"id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService",
"location": "eastus",
"properties": {
"allocationPolicy": "Hashed",
"authorizationPolicies": [],
"deviceProvisioningHostName": "global.azure-devices-provisioning.net",
"idScope": "0ne00000012",
"portalOperationsHostName": "myFirstProvisioningService.services.azure-devices-provisioning.net",
"serviceOperationsHostName": "myFirstProvisioningService.azure-devices-provisioning.net",
"state": "Active",
"disableLocalAuth": false
},
"resourcegroup": "myResourceGroup",
"sku": {
"name": "S1",
"capacity": 1,
"tier": "Standard"
},
"subscriptionid": "91d12660-3dec-467a-be2a-213b5544ddc0",
"tags": {
"key1": "value1"
}
}
DPSCreate_DisableLocalAuthTrue
Sample request
PUT https://management.azure.com/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/provisioningServices/myFirstProvisioningService?api-version=2026-08-31
{
"location": "East US",
"properties": {
"publicNetworkAccess": "Enabled",
"disableLocalAuth": true
},
"sku": {
"name": "S1",
"capacity": 1
},
"tags": {
"key1": "value1",
"key2": "value2"
}
}
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsPropertiesDescription;
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsSku;
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsSkuInfo;
import com.azure.resourcemanager.deviceprovisioningservices.models.PublicNetworkAccess;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for IotDpsResource CreateOrUpdate.
*/
public final class Main {
/*
* x-ms-original-file: 2026-08-31/DPSCreate_DisableLocalAuthTrue.json
*/
/**
* Sample code: DPSCreate_DisableLocalAuthTrue.
*
* @param manager Entry point to IotDpsManager.
*/
public static void
dPSCreateDisableLocalAuthTrue(com.azure.resourcemanager.deviceprovisioningservices.IotDpsManager manager) {
manager.iotDpsResources().define("myFirstProvisioningService").withRegion("East US")
.withExistingResourceGroup("myResourceGroup")
.withProperties(new IotDpsPropertiesDescription().withPublicNetworkAccess(PublicNetworkAccess.ENABLED)
.withDisableLocalAuth(true))
.withSku(new IotDpsSkuInfo().withName(IotDpsSku.S1).withCapacity(1L))
.withTags(mapOf("key1", "fakeTokenPlaceholder", "key2", "fakeTokenPlaceholder")).create();
}
// 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.iothubprovisioningservices import IotDpsClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-iothubprovisioningservices
# USAGE
python dps_create_disable_local_auth_true.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 = IotDpsClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.iot_dps_resource.begin_create_or_update(
resource_group_name="myResourceGroup",
provisioning_service_name="myFirstProvisioningService",
iot_dps_description={
"location": "East US",
"properties": {"disableLocalAuth": True, "publicNetworkAccess": "Enabled"},
"sku": {"capacity": 1, "name": "S1"},
"tags": {"key1": "value1", "key2": "value2"},
},
).result()
print(response)
# x-ms-original-file: 2026-08-31/DPSCreate_DisableLocalAuthTrue.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 armdeviceprovisioningservices_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/deviceprovisioningservices/armdeviceprovisioningservices"
)
// Generated from example definition: 2026-08-31/DPSCreate_DisableLocalAuthTrue.json
func ExampleIotDpsResourceClient_BeginCreateOrUpdate_dpsCreateDisableLocalAuthTrue() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armdeviceprovisioningservices.NewClientFactory("91d12660-3dec-467a-be2a-213b5544ddc0", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewIotDpsResourceClient().BeginCreateOrUpdate(ctx, "myResourceGroup", "myFirstProvisioningService", armdeviceprovisioningservices.ProvisioningServiceDescription{
Location: to.Ptr("East US"),
Properties: &armdeviceprovisioningservices.IotDpsPropertiesDescription{
PublicNetworkAccess: to.Ptr(armdeviceprovisioningservices.PublicNetworkAccessEnabled),
DisableLocalAuth: to.Ptr(true),
},
SKU: &armdeviceprovisioningservices.IotDpsSKUInfo{
Name: to.Ptr(armdeviceprovisioningservices.IotDpsSKUS1),
Capacity: to.Ptr[int64](1),
},
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 = armdeviceprovisioningservices.IotDpsResourceClientCreateOrUpdateResponse{
// ProvisioningServiceDescription: armdeviceprovisioningservices.ProvisioningServiceDescription{
// Name: to.Ptr("myFirstProvisioningService"),
// Type: to.Ptr("Microsoft.Devices/ProvisioningServices"),
// Etag: to.Ptr("AAAAAAAADGk="),
// ID: to.Ptr("/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService"),
// Location: to.Ptr("eastus"),
// Properties: &armdeviceprovisioningservices.IotDpsPropertiesDescription{
// AllocationPolicy: to.Ptr(armdeviceprovisioningservices.AllocationPolicyHashed),
// AuthorizationPolicies: []*armdeviceprovisioningservices.SharedAccessSignatureAuthorizationRuleAccessRightsDescription{
// },
// DeviceProvisioningHostName: to.Ptr("global.azure-devices-provisioning.net"),
// IDScope: to.Ptr("0ne00000012"),
// PortalOperationsHostName: to.Ptr("myFirstProvisioningService.services.azure-devices-provisioning.net"),
// ServiceOperationsHostName: to.Ptr("myFirstProvisioningService.azure-devices-provisioning.net"),
// State: to.Ptr(armdeviceprovisioningservices.StateActive),
// DisableLocalAuth: to.Ptr(true),
// },
// Resourcegroup: to.Ptr("myResourceGroup"),
// SKU: &armdeviceprovisioningservices.IotDpsSKUInfo{
// Name: to.Ptr(armdeviceprovisioningservices.IotDpsSKUS1),
// Capacity: to.Ptr[int64](1),
// Tier: to.Ptr("Standard"),
// },
// Subscriptionid: to.Ptr("91d12660-3dec-467a-be2a-213b5544ddc0"),
// 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 { IotDpsClient } = require("@azure/arm-deviceprovisioningservices");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to create or update the metadata of the provisioning service. The usual pattern to modify a property is to retrieve the provisioning service metadata and security metadata, and then combine them with the modified values in a new body to update the provisioning service.
*
* @summary create or update the metadata of the provisioning service. The usual pattern to modify a property is to retrieve the provisioning service metadata and security metadata, and then combine them with the modified values in a new body to update the provisioning service.
* x-ms-original-file: 2026-08-31/DPSCreate_DisableLocalAuthTrue.json
*/
async function dpsCreateDisableLocalAuthTrue() {
const credential = new DefaultAzureCredential();
const subscriptionId = "91d12660-3dec-467a-be2a-213b5544ddc0";
const client = new IotDpsClient(credential, subscriptionId);
const result = await client.iotDpsResource.createOrUpdate(
"myResourceGroup",
"myFirstProvisioningService",
{
location: "East US",
properties: { publicNetworkAccess: "Enabled", disableLocalAuth: true },
sku: { name: "S1", capacity: 1 },
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
Sample response
{
"name": "myFirstProvisioningService",
"type": "Microsoft.Devices/ProvisioningServices",
"etag": "AAAAAAAADGk=",
"id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService",
"location": "eastus",
"properties": {
"allocationPolicy": "Hashed",
"authorizationPolicies": [],
"deviceProvisioningHostName": "global.azure-devices-provisioning.net",
"idScope": "0ne00000012",
"portalOperationsHostName": "myFirstProvisioningService.services.azure-devices-provisioning.net",
"serviceOperationsHostName": "myFirstProvisioningService.azure-devices-provisioning.net",
"state": "Active",
"disableLocalAuth": true
},
"resourcegroup": "myResourceGroup",
"sku": {
"name": "S1",
"capacity": 1,
"tier": "Standard"
},
"subscriptionid": "91d12660-3dec-467a-be2a-213b5544ddc0",
"tags": {
"key1": "value1",
"key2": "value2"
}
}
{
"name": "myFirstProvisioningService",
"type": "Microsoft.Devices/ProvisioningServices",
"etag": "AAAAAAAADGk=",
"id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService",
"location": "eastus",
"properties": {
"allocationPolicy": "Hashed",
"authorizationPolicies": [],
"deviceProvisioningHostName": "global.azure-devices-provisioning.net",
"idScope": "0ne00000012",
"portalOperationsHostName": "myFirstProvisioningService.services.azure-devices-provisioning.net",
"serviceOperationsHostName": "myFirstProvisioningService.azure-devices-provisioning.net",
"state": "Active",
"disableLocalAuth": true
},
"resourcegroup": "myResourceGroup",
"sku": {
"name": "S1",
"capacity": 1,
"tier": "Standard"
},
"subscriptionid": "91d12660-3dec-467a-be2a-213b5544ddc0",
"tags": {
"key1": "value1",
"key2": "value2"
}
}
DPSCreateWithIotHub
Sample request
PUT https://management.azure.com/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/provisioningServices/myFirstProvisioningService?api-version=2026-08-31
{
"location": "East US",
"properties": {
"enableDataResidency": false,
"iotHubs": [
{
"applyAllocationPolicy": true,
"allocationWeight": 1,
"hostName": "myFirstIoTHub.azure-devices.net",
"authenticationType": "UserAssigned",
"selectedUserAssignedIdentityResourceId": "/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-1",
"location": "eastus"
}
]
},
"sku": {
"name": "S1",
"capacity": 1
},
"identity": {
"type": "SystemAssigned, UserAssigned",
"userAssignedIdentities": {
"/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-1": {}
}
},
"tags": {}
}
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsPropertiesDescription;
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsSku;
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsSkuInfo;
import com.azure.resourcemanager.deviceprovisioningservices.models.IotHubAuthenticationType;
import com.azure.resourcemanager.deviceprovisioningservices.models.IotHubDefinitionDescription;
import com.azure.resourcemanager.deviceprovisioningservices.models.ManagedServiceIdentity;
import com.azure.resourcemanager.deviceprovisioningservices.models.ManagedServiceIdentityType;
import com.azure.resourcemanager.deviceprovisioningservices.models.UserAssignedIdentity;
import java.util.Arrays;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for IotDpsResource CreateOrUpdate.
*/
public final class Main {
/*
* x-ms-original-file: 2026-08-31/DPSCreateWithIotHub.json
*/
/**
* Sample code: DPSCreateWithIotHub.
*
* @param manager Entry point to IotDpsManager.
*/
public static void dPSCreateWithIotHub(com.azure.resourcemanager.deviceprovisioningservices.IotDpsManager manager) {
manager.iotDpsResources().define("myFirstProvisioningService").withRegion("East US")
.withExistingResourceGroup("myResourceGroup")
.withProperties(new IotDpsPropertiesDescription()
.withIotHubs(Arrays.asList(new IotHubDefinitionDescription().withApplyAllocationPolicy(true)
.withAllocationWeight(1).withHostName("myFirstIoTHub.azure-devices.net")
.withAuthenticationType(IotHubAuthenticationType.USER_ASSIGNED)
.withSelectedUserAssignedIdentityResourceId(
"/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-1")
.withLocation("eastus")))
.withEnableDataResidency(false))
.withSku(new IotDpsSkuInfo().withName(IotDpsSku.S1).withCapacity(1L)).withTags(mapOf())
.withIdentity(new ManagedServiceIdentity()
.withType(ManagedServiceIdentityType.fromString("SystemAssigned, UserAssigned"))
.withUserAssignedIdentities(mapOf(
"/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-1",
new UserAssignedIdentity())))
.create();
}
// 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.iothubprovisioningservices import IotDpsClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-iothubprovisioningservices
# USAGE
python dps_create_with_iot_hub.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 = IotDpsClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.iot_dps_resource.begin_create_or_update(
resource_group_name="myResourceGroup",
provisioning_service_name="myFirstProvisioningService",
iot_dps_description={
"identity": {
"type": "SystemAssigned, UserAssigned",
"userAssignedIdentities": {
"/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-1": {}
},
},
"location": "East US",
"properties": {
"enableDataResidency": False,
"iotHubs": [
{
"allocationWeight": 1,
"applyAllocationPolicy": True,
"authenticationType": "UserAssigned",
"hostName": "myFirstIoTHub.azure-devices.net",
"location": "eastus",
"selectedUserAssignedIdentityResourceId": "/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-1",
}
],
},
"sku": {"capacity": 1, "name": "S1"},
"tags": {},
},
).result()
print(response)
# x-ms-original-file: 2026-08-31/DPSCreateWithIotHub.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 armdeviceprovisioningservices_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/deviceprovisioningservices/armdeviceprovisioningservices"
)
// Generated from example definition: 2026-08-31/DPSCreateWithIotHub.json
func ExampleIotDpsResourceClient_BeginCreateOrUpdate_dpsCreateWithIotHub() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armdeviceprovisioningservices.NewClientFactory("91d12660-3dec-467a-be2a-213b5544ddc0", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewIotDpsResourceClient().BeginCreateOrUpdate(ctx, "myResourceGroup", "myFirstProvisioningService", armdeviceprovisioningservices.ProvisioningServiceDescription{
Location: to.Ptr("East US"),
Properties: &armdeviceprovisioningservices.IotDpsPropertiesDescription{
EnableDataResidency: to.Ptr(false),
IotHubs: []*armdeviceprovisioningservices.IotHubDefinitionDescription{
{
ApplyAllocationPolicy: to.Ptr(true),
AllocationWeight: to.Ptr[int32](1),
HostName: to.Ptr("myFirstIoTHub.azure-devices.net"),
AuthenticationType: to.Ptr(armdeviceprovisioningservices.IotHubAuthenticationTypeUserAssigned),
SelectedUserAssignedIdentityResourceID: to.Ptr("/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-1"),
Location: to.Ptr("eastus"),
},
},
},
SKU: &armdeviceprovisioningservices.IotDpsSKUInfo{
Name: to.Ptr(armdeviceprovisioningservices.IotDpsSKUS1),
Capacity: to.Ptr[int64](1),
},
Identity: &armdeviceprovisioningservices.ManagedServiceIdentity{
Type: to.Ptr(armdeviceprovisioningservices.ManagedServiceIdentityType("SystemAssigned, UserAssigned")),
UserAssignedIdentities: map[string]*armdeviceprovisioningservices.UserAssignedIdentity{
"/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-1": {},
},
},
Tags: map[string]*string{},
}, 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 = armdeviceprovisioningservices.IotDpsResourceClientCreateOrUpdateResponse{
// ProvisioningServiceDescription: armdeviceprovisioningservices.ProvisioningServiceDescription{
// Name: to.Ptr("myFirstProvisioningService"),
// Type: to.Ptr("Microsoft.Devices/ProvisioningServices"),
// Etag: to.Ptr("AAAAAAAADGk="),
// ID: to.Ptr("/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService"),
// Location: to.Ptr("eastus"),
// Properties: &armdeviceprovisioningservices.IotDpsPropertiesDescription{
// AllocationPolicy: to.Ptr(armdeviceprovisioningservices.AllocationPolicyHashed),
// AuthorizationPolicies: []*armdeviceprovisioningservices.SharedAccessSignatureAuthorizationRuleAccessRightsDescription{
// },
// DeviceProvisioningHostName: to.Ptr("global.azure-devices-provisioning.net"),
// EnableDataResidency: to.Ptr(false),
// IDScope: to.Ptr("0ne00000012"),
// IotHubs: []*armdeviceprovisioningservices.IotHubDefinitionDescription{
// {
// ApplyAllocationPolicy: to.Ptr(true),
// AllocationWeight: to.Ptr[int32](1),
// Name: to.Ptr("myFirstIoTHub.azure-devices.net"),
// HostName: to.Ptr("myFirstIoTHub.azure-devices.net"),
// AuthenticationType: to.Ptr(armdeviceprovisioningservices.IotHubAuthenticationTypeUserAssigned),
// SelectedUserAssignedIdentityResourceID: to.Ptr("/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-1"),
// Location: to.Ptr("eastus"),
// },
// },
// PortalOperationsHostName: to.Ptr("myFirstProvisioningService.services.azure-devices-provisioning.net"),
// ServiceOperationsHostName: to.Ptr("myFirstProvisioningService.azure-devices-provisioning.net"),
// State: to.Ptr(armdeviceprovisioningservices.StateActive),
// },
// Resourcegroup: to.Ptr("myResourceGroup"),
// SKU: &armdeviceprovisioningservices.IotDpsSKUInfo{
// Name: to.Ptr(armdeviceprovisioningservices.IotDpsSKUS1),
// Capacity: to.Ptr[int64](1),
// Tier: to.Ptr("Standard"),
// },
// Identity: &armdeviceprovisioningservices.ManagedServiceIdentity{
// Type: to.Ptr(armdeviceprovisioningservices.ManagedServiceIdentityType("SystemAssigned, UserAssigned")),
// UserAssignedIdentities: map[string]*armdeviceprovisioningservices.UserAssignedIdentity{
// "/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-1": &armdeviceprovisioningservices.UserAssignedIdentity{
// },
// },
// },
// Subscriptionid: to.Ptr("91d12660-3dec-467a-be2a-213b5544ddc0"),
// 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 { IotDpsClient } = require("@azure/arm-deviceprovisioningservices");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to create or update the metadata of the provisioning service. The usual pattern to modify a property is to retrieve the provisioning service metadata and security metadata, and then combine them with the modified values in a new body to update the provisioning service.
*
* @summary create or update the metadata of the provisioning service. The usual pattern to modify a property is to retrieve the provisioning service metadata and security metadata, and then combine them with the modified values in a new body to update the provisioning service.
* x-ms-original-file: 2026-08-31/DPSCreateWithIotHub.json
*/
async function dpsCreateWithIotHub() {
const credential = new DefaultAzureCredential();
const subscriptionId = "91d12660-3dec-467a-be2a-213b5544ddc0";
const client = new IotDpsClient(credential, subscriptionId);
const result = await client.iotDpsResource.createOrUpdate(
"myResourceGroup",
"myFirstProvisioningService",
{
location: "East US",
properties: {
enableDataResidency: false,
iotHubs: [
{
applyAllocationPolicy: true,
allocationWeight: 1,
hostName: "myFirstIoTHub.azure-devices.net",
authenticationType: "UserAssigned",
selectedUserAssignedIdentityResourceId:
"/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-1",
location: "eastus",
},
],
},
sku: { name: "S1", capacity: 1 },
identity: {
type: "SystemAssigned, UserAssigned",
userAssignedIdentities: {
"/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-1":
{},
},
},
tags: {},
},
);
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
Sample response
{
"name": "myFirstProvisioningService",
"type": "Microsoft.Devices/ProvisioningServices",
"etag": "AAAAAAAADGk=",
"id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService",
"location": "eastus",
"properties": {
"allocationPolicy": "Hashed",
"authorizationPolicies": [],
"deviceProvisioningHostName": "global.azure-devices-provisioning.net",
"enableDataResidency": false,
"idScope": "0ne00000012",
"iotHubs": [
{
"applyAllocationPolicy": true,
"allocationWeight": 1,
"name": "myFirstIoTHub.azure-devices.net",
"hostName": "myFirstIoTHub.azure-devices.net",
"authenticationType": "UserAssigned",
"selectedUserAssignedIdentityResourceId": "/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-1",
"location": "eastus"
}
],
"portalOperationsHostName": "myFirstProvisioningService.services.azure-devices-provisioning.net",
"serviceOperationsHostName": "myFirstProvisioningService.azure-devices-provisioning.net",
"state": "Active"
},
"resourcegroup": "myResourceGroup",
"sku": {
"name": "S1",
"capacity": 1,
"tier": "Standard"
},
"identity": {
"type": "SystemAssigned, UserAssigned",
"userAssignedIdentities": {
"/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-1": {}
}
},
"subscriptionid": "91d12660-3dec-467a-be2a-213b5544ddc0",
"tags": {}
}
{
"name": "myFirstProvisioningService",
"type": "Microsoft.Devices/ProvisioningServices",
"etag": "AAAAAAAADGk=",
"id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService",
"location": "eastus",
"properties": {
"allocationPolicy": "Hashed",
"authorizationPolicies": [],
"deviceProvisioningHostName": "global.azure-devices-provisioning.net",
"enableDataResidency": false,
"idScope": "0ne00000012",
"iotHubs": [
{
"applyAllocationPolicy": true,
"allocationWeight": 1,
"name": "myFirstIoTHub.azure-devices.net",
"hostName": "myFirstIoTHub.azure-devices.net",
"authenticationType": "UserAssigned",
"selectedUserAssignedIdentityResourceId": "/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-1",
"location": "eastus"
}
],
"portalOperationsHostName": "myFirstProvisioningService.services.azure-devices-provisioning.net",
"serviceOperationsHostName": "myFirstProvisioningService.azure-devices-provisioning.net",
"state": "Active"
},
"resourcegroup": "myResourceGroup",
"sku": {
"name": "S1",
"capacity": 1,
"tier": "Standard"
},
"identity": {
"type": "SystemAssigned, UserAssigned",
"userAssignedIdentities": {
"/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-1": {}
}
},
"subscriptionid": "91d12660-3dec-467a-be2a-213b5544ddc0",
"tags": {}
}
DPSCreateWithNamespace
Sample request
PUT https://management.azure.com/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/provisioningServices/myFirstProvisioningService?api-version=2026-08-31
{
"location": "East US",
"properties": {
"enableDataResidency": false
},
"sku": {
"name": "S1",
"capacity": 1
},
"tags": {}
}
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsPropertiesDescription;
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsSku;
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsSkuInfo;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for IotDpsResource CreateOrUpdate.
*/
public final class Main {
/*
* x-ms-original-file: 2026-08-31/DPSCreateWithNamespace.json
*/
/**
* Sample code: DPSCreateWithNamespace.
*
* @param manager Entry point to IotDpsManager.
*/
public static void
dPSCreateWithNamespace(com.azure.resourcemanager.deviceprovisioningservices.IotDpsManager manager) {
manager.iotDpsResources().define("myFirstProvisioningService").withRegion("East US")
.withExistingResourceGroup("myResourceGroup")
.withProperties(new IotDpsPropertiesDescription().withEnableDataResidency(false))
.withSku(new IotDpsSkuInfo().withName(IotDpsSku.S1).withCapacity(1L)).withTags(mapOf()).create();
}
// 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.iothubprovisioningservices import IotDpsClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-iothubprovisioningservices
# USAGE
python dps_create_with_namespace.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 = IotDpsClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.iot_dps_resource.begin_create_or_update(
resource_group_name="myResourceGroup",
provisioning_service_name="myFirstProvisioningService",
iot_dps_description={
"location": "East US",
"properties": {"enableDataResidency": False},
"sku": {"capacity": 1, "name": "S1"},
"tags": {},
},
).result()
print(response)
# x-ms-original-file: 2026-08-31/DPSCreateWithNamespace.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 armdeviceprovisioningservices_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/deviceprovisioningservices/armdeviceprovisioningservices"
)
// Generated from example definition: 2026-08-31/DPSCreateWithNamespace.json
func ExampleIotDpsResourceClient_BeginCreateOrUpdate_dpsCreateWithNamespace() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armdeviceprovisioningservices.NewClientFactory("91d12660-3dec-467a-be2a-213b5544ddc0", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewIotDpsResourceClient().BeginCreateOrUpdate(ctx, "myResourceGroup", "myFirstProvisioningService", armdeviceprovisioningservices.ProvisioningServiceDescription{
Location: to.Ptr("East US"),
Properties: &armdeviceprovisioningservices.IotDpsPropertiesDescription{
EnableDataResidency: to.Ptr(false),
},
SKU: &armdeviceprovisioningservices.IotDpsSKUInfo{
Name: to.Ptr(armdeviceprovisioningservices.IotDpsSKUS1),
Capacity: to.Ptr[int64](1),
},
Tags: map[string]*string{},
}, 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 = armdeviceprovisioningservices.IotDpsResourceClientCreateOrUpdateResponse{
// ProvisioningServiceDescription: armdeviceprovisioningservices.ProvisioningServiceDescription{
// Name: to.Ptr("myFirstProvisioningService"),
// Type: to.Ptr("Microsoft.Devices/ProvisioningServices"),
// Etag: to.Ptr("AAAAAAAADGk="),
// ID: to.Ptr("/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups//providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService"),
// Location: to.Ptr("eastus"),
// Properties: &armdeviceprovisioningservices.IotDpsPropertiesDescription{
// AllocationPolicy: to.Ptr(armdeviceprovisioningservices.AllocationPolicyHashed),
// AuthorizationPolicies: []*armdeviceprovisioningservices.SharedAccessSignatureAuthorizationRuleAccessRightsDescription{
// },
// DeviceProvisioningHostName: to.Ptr("global.azure-devices-provisioning.net"),
// EnableDataResidency: to.Ptr(false),
// IDScope: to.Ptr("0ne00000012"),
// PortalOperationsHostName: to.Ptr("myFirstProvisioningService.services.azure-devices-provisioning.net"),
// ServiceOperationsHostName: to.Ptr("myFirstProvisioningService.azure-devices-provisioning.net"),
// State: to.Ptr(armdeviceprovisioningservices.StateActive),
// },
// Resourcegroup: to.Ptr("myResourceGroup"),
// SKU: &armdeviceprovisioningservices.IotDpsSKUInfo{
// Name: to.Ptr(armdeviceprovisioningservices.IotDpsSKUS1),
// Capacity: to.Ptr[int64](1),
// Tier: to.Ptr("Standard"),
// },
// Identity: &armdeviceprovisioningservices.ManagedServiceIdentity{
// Type: to.Ptr(armdeviceprovisioningservices.ManagedServiceIdentityType("SystemAssigned, UserAssigned")),
// UserAssignedIdentities: map[string]*armdeviceprovisioningservices.UserAssignedIdentity{
// "/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-1": &armdeviceprovisioningservices.UserAssignedIdentity{
// },
// "/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-2": &armdeviceprovisioningservices.UserAssignedIdentity{
// },
// },
// },
// Subscriptionid: to.Ptr("91d12660-3dec-467a-be2a-213b5544ddc0"),
// 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 { IotDpsClient } = require("@azure/arm-deviceprovisioningservices");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to create or update the metadata of the provisioning service. The usual pattern to modify a property is to retrieve the provisioning service metadata and security metadata, and then combine them with the modified values in a new body to update the provisioning service.
*
* @summary create or update the metadata of the provisioning service. The usual pattern to modify a property is to retrieve the provisioning service metadata and security metadata, and then combine them with the modified values in a new body to update the provisioning service.
* x-ms-original-file: 2026-08-31/DPSCreateWithNamespace.json
*/
async function dpsCreateWithNamespace() {
const credential = new DefaultAzureCredential();
const subscriptionId = "91d12660-3dec-467a-be2a-213b5544ddc0";
const client = new IotDpsClient(credential, subscriptionId);
const result = await client.iotDpsResource.createOrUpdate(
"myResourceGroup",
"myFirstProvisioningService",
{
location: "East US",
properties: { enableDataResidency: false },
sku: { name: "S1", capacity: 1 },
tags: {},
},
);
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
Sample response
{
"name": "myFirstProvisioningService",
"type": "Microsoft.Devices/ProvisioningServices",
"etag": "AAAAAAAADGk=",
"id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups//providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService",
"location": "eastus",
"properties": {
"allocationPolicy": "Hashed",
"authorizationPolicies": [],
"deviceProvisioningHostName": "global.azure-devices-provisioning.net",
"enableDataResidency": false,
"idScope": "0ne00000012",
"portalOperationsHostName": "myFirstProvisioningService.services.azure-devices-provisioning.net",
"serviceOperationsHostName": "myFirstProvisioningService.azure-devices-provisioning.net",
"state": "Active"
},
"resourcegroup": "myResourceGroup",
"sku": {
"name": "S1",
"capacity": 1,
"tier": "Standard"
},
"identity": {
"type": "SystemAssigned, UserAssigned",
"userAssignedIdentities": {
"/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-1": {},
"/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-2": {}
}
},
"subscriptionid": "91d12660-3dec-467a-be2a-213b5544ddc0",
"tags": {}
}
{
"name": "myFirstProvisioningService",
"type": "Microsoft.Devices/ProvisioningServices",
"etag": "AAAAAAAADGk=",
"id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups//providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService",
"location": "eastus",
"properties": {
"allocationPolicy": "Hashed",
"authorizationPolicies": [],
"deviceProvisioningHostName": "global.azure-devices-provisioning.net",
"enableDataResidency": false,
"idScope": "0ne00000012",
"portalOperationsHostName": "myFirstProvisioningService.services.azure-devices-provisioning.net",
"serviceOperationsHostName": "myFirstProvisioningService.azure-devices-provisioning.net",
"state": "Active"
},
"resourcegroup": "myResourceGroup",
"sku": {
"name": "S1",
"capacity": 1,
"tier": "Standard"
},
"identity": {
"type": "SystemAssigned, UserAssigned",
"userAssignedIdentities": {
"/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-1": {},
"/subscriptions/abcf2d55-764f-419f-974d-f77a55c2ce55/resourcegroups/my-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/my-mi-2": {}
}
},
"subscriptionid": "91d12660-3dec-467a-be2a-213b5544ddc0",
"tags": {}
}
DPSUpdate
Sample request
PUT https://management.azure.com/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/provisioningServices/myFirstProvisioningService?api-version=2026-08-31
{
"identity": {
"type": "SystemAssigned,UserAssigned",
"userAssignedIdentities": {
"/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourcegroups/testrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/testidentity": {}
}
},
"location": "East US",
"properties": {
"enableDataResidency": false
},
"sku": {
"name": "S1",
"capacity": 1
},
"tags": {}
}
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsPropertiesDescription;
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsSku;
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsSkuInfo;
import com.azure.resourcemanager.deviceprovisioningservices.models.ManagedServiceIdentity;
import com.azure.resourcemanager.deviceprovisioningservices.models.ManagedServiceIdentityType;
import com.azure.resourcemanager.deviceprovisioningservices.models.UserAssignedIdentity;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for IotDpsResource CreateOrUpdate.
*/
public final class Main {
/*
* x-ms-original-file: 2026-08-31/DPSUpdate.json
*/
/**
* Sample code: DPSUpdate.
*
* @param manager Entry point to IotDpsManager.
*/
public static void dPSUpdate(com.azure.resourcemanager.deviceprovisioningservices.IotDpsManager manager) {
manager.iotDpsResources().define("myFirstProvisioningService").withRegion("East US")
.withExistingResourceGroup("myResourceGroup")
.withProperties(new IotDpsPropertiesDescription().withEnableDataResidency(false))
.withSku(new IotDpsSkuInfo().withName(IotDpsSku.S1).withCapacity(1L)).withTags(mapOf())
.withIdentity(new ManagedServiceIdentity()
.withType(ManagedServiceIdentityType.SYSTEM_ASSIGNED_USER_ASSIGNED)
.withUserAssignedIdentities(mapOf(
"/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourcegroups/testrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/testidentity",
new UserAssignedIdentity())))
.create();
}
// 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.iothubprovisioningservices import IotDpsClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-iothubprovisioningservices
# USAGE
python dps_update.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 = IotDpsClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.iot_dps_resource.begin_create_or_update(
resource_group_name="myResourceGroup",
provisioning_service_name="myFirstProvisioningService",
iot_dps_description={
"identity": {
"type": "SystemAssigned,UserAssigned",
"userAssignedIdentities": {
"/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourcegroups/testrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/testidentity": {}
},
},
"location": "East US",
"properties": {"enableDataResidency": False},
"sku": {"capacity": 1, "name": "S1"},
"tags": {},
},
).result()
print(response)
# x-ms-original-file: 2026-08-31/DPSUpdate.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 armdeviceprovisioningservices_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/deviceprovisioningservices/armdeviceprovisioningservices"
)
// Generated from example definition: 2026-08-31/DPSUpdate.json
func ExampleIotDpsResourceClient_BeginCreateOrUpdate_dpsUpdate() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armdeviceprovisioningservices.NewClientFactory("91d12660-3dec-467a-be2a-213b5544ddc0", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewIotDpsResourceClient().BeginCreateOrUpdate(ctx, "myResourceGroup", "myFirstProvisioningService", armdeviceprovisioningservices.ProvisioningServiceDescription{
Identity: &armdeviceprovisioningservices.ManagedServiceIdentity{
Type: to.Ptr(armdeviceprovisioningservices.ManagedServiceIdentityTypeSystemAssignedUserAssigned),
UserAssignedIdentities: map[string]*armdeviceprovisioningservices.UserAssignedIdentity{
"/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourcegroups/testrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/testidentity": {},
},
},
Location: to.Ptr("East US"),
Properties: &armdeviceprovisioningservices.IotDpsPropertiesDescription{
EnableDataResidency: to.Ptr(false),
},
SKU: &armdeviceprovisioningservices.IotDpsSKUInfo{
Name: to.Ptr(armdeviceprovisioningservices.IotDpsSKUS1),
Capacity: to.Ptr[int64](1),
},
Tags: map[string]*string{},
}, 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 = armdeviceprovisioningservices.IotDpsResourceClientCreateOrUpdateResponse{
// ProvisioningServiceDescription: armdeviceprovisioningservices.ProvisioningServiceDescription{
// Name: to.Ptr("myFirstProvisioningService"),
// Type: to.Ptr("Microsoft.Devices/ProvisioningServices"),
// Etag: to.Ptr("AAAAAAAADGk="),
// ID: to.Ptr("/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups//providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService"),
// Identity: &armdeviceprovisioningservices.ManagedServiceIdentity{
// Type: to.Ptr(armdeviceprovisioningservices.ManagedServiceIdentityTypeSystemAssignedUserAssigned),
// PrincipalID: to.Ptr("aa80bd74-a3f0-4f14-b9da-99c5351cf9d5"),
// TenantID: to.Ptr("f686d426-8d16-42db-81b7-ab578e110ccd"),
// UserAssignedIdentities: map[string]*armdeviceprovisioningservices.UserAssignedIdentity{
// "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourcegroups/testrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/testidentity": &armdeviceprovisioningservices.UserAssignedIdentity{
// ClientID: to.Ptr("c38f618d-47f6-4260-8b3d-1dd8c130f323"),
// PrincipalID: to.Ptr("f1b0b133-10dc-4985-966f-a98a04675fe9"),
// },
// },
// },
// Location: to.Ptr("eastus"),
// Properties: &armdeviceprovisioningservices.IotDpsPropertiesDescription{
// AllocationPolicy: to.Ptr(armdeviceprovisioningservices.AllocationPolicyHashed),
// AuthorizationPolicies: []*armdeviceprovisioningservices.SharedAccessSignatureAuthorizationRuleAccessRightsDescription{
// },
// DeviceProvisioningHostName: to.Ptr("global.azure-devices-provisioning.net"),
// EnableDataResidency: to.Ptr(false),
// IDScope: to.Ptr("0ne00000012"),
// PortalOperationsHostName: to.Ptr("myFirstProvisioningService.services.azure-devices-provisioning.net"),
// ServiceOperationsHostName: to.Ptr("myFirstProvisioningService.azure-devices-provisioning.net"),
// State: to.Ptr(armdeviceprovisioningservices.StateActive),
// },
// Resourcegroup: to.Ptr("myResourceGroup"),
// SKU: &armdeviceprovisioningservices.IotDpsSKUInfo{
// Name: to.Ptr(armdeviceprovisioningservices.IotDpsSKUS1),
// Capacity: to.Ptr[int64](1),
// Tier: to.Ptr("Standard"),
// },
// Subscriptionid: to.Ptr("91d12660-3dec-467a-be2a-213b5544ddc0"),
// 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 { IotDpsClient } = require("@azure/arm-deviceprovisioningservices");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to create or update the metadata of the provisioning service. The usual pattern to modify a property is to retrieve the provisioning service metadata and security metadata, and then combine them with the modified values in a new body to update the provisioning service.
*
* @summary create or update the metadata of the provisioning service. The usual pattern to modify a property is to retrieve the provisioning service metadata and security metadata, and then combine them with the modified values in a new body to update the provisioning service.
* x-ms-original-file: 2026-08-31/DPSUpdate.json
*/
async function dpsUpdate() {
const credential = new DefaultAzureCredential();
const subscriptionId = "91d12660-3dec-467a-be2a-213b5544ddc0";
const client = new IotDpsClient(credential, subscriptionId);
const result = await client.iotDpsResource.createOrUpdate(
"myResourceGroup",
"myFirstProvisioningService",
{
identity: {
type: "SystemAssigned,UserAssigned",
userAssignedIdentities: {
"/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourcegroups/testrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/testidentity":
{},
},
},
location: "East US",
properties: { enableDataResidency: false },
sku: { name: "S1", capacity: 1 },
tags: {},
},
);
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
Sample response
{
"name": "myFirstProvisioningService",
"type": "Microsoft.Devices/ProvisioningServices",
"etag": "AAAAAAAADGk=",
"id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups//providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService",
"identity": {
"type": "SystemAssigned,UserAssigned",
"principalId": "aa80bd74-a3f0-4f14-b9da-99c5351cf9d5",
"tenantId": "f686d426-8d16-42db-81b7-ab578e110ccd",
"userAssignedIdentities": {
"/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourcegroups/testrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/testidentity": {
"clientId": "c38f618d-47f6-4260-8b3d-1dd8c130f323",
"principalId": "f1b0b133-10dc-4985-966f-a98a04675fe9"
}
}
},
"location": "eastus",
"properties": {
"allocationPolicy": "Hashed",
"authorizationPolicies": [],
"deviceProvisioningHostName": "global.azure-devices-provisioning.net",
"enableDataResidency": false,
"idScope": "0ne00000012",
"portalOperationsHostName": "myFirstProvisioningService.services.azure-devices-provisioning.net",
"serviceOperationsHostName": "myFirstProvisioningService.azure-devices-provisioning.net",
"state": "Active"
},
"resourcegroup": "myResourceGroup",
"sku": {
"name": "S1",
"capacity": 1,
"tier": "Standard"
},
"subscriptionid": "91d12660-3dec-467a-be2a-213b5544ddc0",
"tags": {}
}
{
"name": "myFirstProvisioningService",
"type": "Microsoft.Devices/ProvisioningServices",
"etag": "AAAAAAAADGk=",
"id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups//providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService",
"identity": {
"type": "SystemAssigned,UserAssigned",
"principalId": "aa80bd74-a3f0-4f14-b9da-99c5351cf9d5",
"tenantId": "f686d426-8d16-42db-81b7-ab578e110ccd",
"userAssignedIdentities": {
"/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourcegroups/testrg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/testidentity": {
"clientId": "c38f618d-47f6-4260-8b3d-1dd8c130f323",
"principalId": "f1b0b133-10dc-4985-966f-a98a04675fe9"
}
}
},
"location": "eastus",
"properties": {
"allocationPolicy": "Hashed",
"authorizationPolicies": [],
"deviceProvisioningHostName": "global.azure-devices-provisioning.net",
"enableDataResidency": false,
"idScope": "0ne00000012",
"portalOperationsHostName": "myFirstProvisioningService.services.azure-devices-provisioning.net",
"serviceOperationsHostName": "myFirstProvisioningService.azure-devices-provisioning.net",
"state": "Active"
},
"resourcegroup": "myResourceGroup",
"sku": {
"name": "S1",
"capacity": 1,
"tier": "Standard"
},
"subscriptionid": "91d12660-3dec-467a-be2a-213b5544ddc0",
"tags": {}
}
DPSUpdate_DisableLocalAuth
Sample request
PUT https://management.azure.com/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/provisioningServices/myFirstProvisioningService?api-version=2026-08-31
{
"location": "East US",
"properties": {
"disableLocalAuth": true
},
"sku": {
"name": "S1",
"capacity": 1
},
"tags": {}
}
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsPropertiesDescription;
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsSku;
import com.azure.resourcemanager.deviceprovisioningservices.models.IotDpsSkuInfo;
import java.util.HashMap;
import java.util.Map;
/**
* Samples for IotDpsResource CreateOrUpdate.
*/
public final class Main {
/*
* x-ms-original-file: 2026-08-31/DPSUpdate_DisableLocalAuth.json
*/
/**
* Sample code: DPSUpdate_DisableLocalAuth.
*
* @param manager Entry point to IotDpsManager.
*/
public static void
dPSUpdateDisableLocalAuth(com.azure.resourcemanager.deviceprovisioningservices.IotDpsManager manager) {
manager.iotDpsResources().define("myFirstProvisioningService").withRegion("East US")
.withExistingResourceGroup("myResourceGroup")
.withProperties(new IotDpsPropertiesDescription().withDisableLocalAuth(true))
.withSku(new IotDpsSkuInfo().withName(IotDpsSku.S1).withCapacity(1L)).withTags(mapOf()).create();
}
// 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.iothubprovisioningservices import IotDpsClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-iothubprovisioningservices
# USAGE
python dps_update_disable_local_auth.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 = IotDpsClient(
credential=DefaultAzureCredential(),
subscription_id="SUBSCRIPTION_ID",
)
response = client.iot_dps_resource.begin_create_or_update(
resource_group_name="myResourceGroup",
provisioning_service_name="myFirstProvisioningService",
iot_dps_description={
"location": "East US",
"properties": {"disableLocalAuth": True},
"sku": {"capacity": 1, "name": "S1"},
"tags": {},
},
).result()
print(response)
# x-ms-original-file: 2026-08-31/DPSUpdate_DisableLocalAuth.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 armdeviceprovisioningservices_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/deviceprovisioningservices/armdeviceprovisioningservices"
)
// Generated from example definition: 2026-08-31/DPSUpdate_DisableLocalAuth.json
func ExampleIotDpsResourceClient_BeginCreateOrUpdate_dpsUpdateDisableLocalAuth() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armdeviceprovisioningservices.NewClientFactory("91d12660-3dec-467a-be2a-213b5544ddc0", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
poller, err := clientFactory.NewIotDpsResourceClient().BeginCreateOrUpdate(ctx, "myResourceGroup", "myFirstProvisioningService", armdeviceprovisioningservices.ProvisioningServiceDescription{
Location: to.Ptr("East US"),
Properties: &armdeviceprovisioningservices.IotDpsPropertiesDescription{
DisableLocalAuth: to.Ptr(true),
},
SKU: &armdeviceprovisioningservices.IotDpsSKUInfo{
Name: to.Ptr(armdeviceprovisioningservices.IotDpsSKUS1),
Capacity: to.Ptr[int64](1),
},
Tags: map[string]*string{},
}, 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 = armdeviceprovisioningservices.IotDpsResourceClientCreateOrUpdateResponse{
// ProvisioningServiceDescription: armdeviceprovisioningservices.ProvisioningServiceDescription{
// Name: to.Ptr("myFirstProvisioningService"),
// Type: to.Ptr("Microsoft.Devices/ProvisioningServices"),
// Etag: to.Ptr("AAAAAAAADGk="),
// ID: to.Ptr("/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService"),
// Location: to.Ptr("eastus"),
// Properties: &armdeviceprovisioningservices.IotDpsPropertiesDescription{
// AllocationPolicy: to.Ptr(armdeviceprovisioningservices.AllocationPolicyHashed),
// AuthorizationPolicies: []*armdeviceprovisioningservices.SharedAccessSignatureAuthorizationRuleAccessRightsDescription{
// },
// DeviceProvisioningHostName: to.Ptr("global.azure-devices-provisioning.net"),
// IDScope: to.Ptr("0ne00000012"),
// PortalOperationsHostName: to.Ptr("myFirstProvisioningService.services.azure-devices-provisioning.net"),
// ServiceOperationsHostName: to.Ptr("myFirstProvisioningService.azure-devices-provisioning.net"),
// State: to.Ptr(armdeviceprovisioningservices.StateActive),
// DisableLocalAuth: to.Ptr(true),
// },
// Resourcegroup: to.Ptr("myResourceGroup"),
// SKU: &armdeviceprovisioningservices.IotDpsSKUInfo{
// Name: to.Ptr(armdeviceprovisioningservices.IotDpsSKUS1),
// Capacity: to.Ptr[int64](1),
// Tier: to.Ptr("Standard"),
// },
// Subscriptionid: to.Ptr("91d12660-3dec-467a-be2a-213b5544ddc0"),
// 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 { IotDpsClient } = require("@azure/arm-deviceprovisioningservices");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to create or update the metadata of the provisioning service. The usual pattern to modify a property is to retrieve the provisioning service metadata and security metadata, and then combine them with the modified values in a new body to update the provisioning service.
*
* @summary create or update the metadata of the provisioning service. The usual pattern to modify a property is to retrieve the provisioning service metadata and security metadata, and then combine them with the modified values in a new body to update the provisioning service.
* x-ms-original-file: 2026-08-31/DPSUpdate_DisableLocalAuth.json
*/
async function dpsUpdateDisableLocalAuth() {
const credential = new DefaultAzureCredential();
const subscriptionId = "91d12660-3dec-467a-be2a-213b5544ddc0";
const client = new IotDpsClient(credential, subscriptionId);
const result = await client.iotDpsResource.createOrUpdate(
"myResourceGroup",
"myFirstProvisioningService",
{
location: "East US",
properties: { disableLocalAuth: true },
sku: { name: "S1", capacity: 1 },
tags: {},
},
);
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
Sample response
{
"name": "myFirstProvisioningService",
"type": "Microsoft.Devices/ProvisioningServices",
"etag": "AAAAAAAADGk=",
"id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService",
"location": "eastus",
"properties": {
"allocationPolicy": "Hashed",
"authorizationPolicies": [],
"deviceProvisioningHostName": "global.azure-devices-provisioning.net",
"idScope": "0ne00000012",
"portalOperationsHostName": "myFirstProvisioningService.services.azure-devices-provisioning.net",
"serviceOperationsHostName": "myFirstProvisioningService.azure-devices-provisioning.net",
"state": "Active",
"disableLocalAuth": true
},
"resourcegroup": "myResourceGroup",
"sku": {
"name": "S1",
"capacity": 1,
"tier": "Standard"
},
"subscriptionid": "91d12660-3dec-467a-be2a-213b5544ddc0",
"tags": {}
}
{
"name": "myFirstProvisioningService",
"type": "Microsoft.Devices/ProvisioningServices",
"etag": "AAAAAAAADGk=",
"id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService",
"location": "eastus",
"properties": {
"allocationPolicy": "Hashed",
"authorizationPolicies": [],
"deviceProvisioningHostName": "global.azure-devices-provisioning.net",
"idScope": "0ne00000012",
"portalOperationsHostName": "myFirstProvisioningService.services.azure-devices-provisioning.net",
"serviceOperationsHostName": "myFirstProvisioningService.azure-devices-provisioning.net",
"state": "Active",
"disableLocalAuth": true
},
"resourcegroup": "myResourceGroup",
"sku": {
"name": "S1",
"capacity": 1,
"tier": "Standard"
},
"subscriptionid": "91d12660-3dec-467a-be2a-213b5544ddc0",
"tags": {}
}
Definitions
AccessRightsDescription
Enumeration
Rights that this key has.
| Value |
Description |
|
ServiceConfig
|
|
|
EnrollmentRead
|
|
|
EnrollmentWrite
|
|
|
DeviceConnect
|
|
|
RegistrationStatusRead
|
|
|
RegistrationStatusWrite
|
|
AllocationPolicy
Enumeration
Allocation policy to be used by this provisioning service.
| Value |
Description |
|
Hashed
|
|
|
GeoLatency
|
|
|
Static
|
|
createdByType
Enumeration
The type of identity that created the resource.
| Value |
Description |
|
User
|
|
|
Application
|
|
|
ManagedIdentity
|
|
|
Key
|
|
ErrorDetails
Object
Error details.
| Name |
Type |
Description |
|
code
|
integer
(int32)
|
The error code.
|
|
details
|
string
|
The error details.
|
|
httpStatusCode
|
string
|
The HTTP status code.
|
|
message
|
string
|
The error message.
|
IotDpsPropertiesDescription
Object
the service specific properties of a provisioning service, including keys, linked iot hubs, current state, and system generated properties such as hostname and idScope
| Name |
Type |
Default value |
Description |
|
allocationPolicy
|
AllocationPolicy
|
|
Allocation policy to be used by this provisioning service.
|
|
authorizationPolicies
|
SharedAccessSignatureAuthorizationRuleAccessRightsDescription[]
|
|
List of authorization keys for a provisioning service.
|
|
deviceProvisioningHostName
|
string
|
|
Device endpoint for this provisioning service.
|
|
disableLocalAuth
|
boolean
|
False
|
Disables all authentication methods other than Azure RBAC.
|
|
enableDataResidency
|
boolean
|
|
Optional.
Indicates if the DPS instance has Data Residency enabled, removing the cross geo-pair disaster recovery.
|
|
idScope
|
string
|
|
Unique identifier of this provisioning service.
|
|
iotHubs
|
IotHubDefinitionDescription[]
|
|
List of IoT hubs associated with this provisioning service.
|
|
ipFilterRules
|
IpFilterRule[]
|
|
The IP filter rules.
|
|
portalOperationsHostName
|
string
|
|
Portal endpoint to enable CORS for this provisioning service.
|
|
privateEndpointConnections
|
PrivateEndpointConnection[]
|
|
Private endpoint connections created on this IotHub
|
|
provisioningState
|
string
|
|
The ARM provisioning state of the provisioning service.
|
|
publicNetworkAccess
|
PublicNetworkAccess
|
|
Whether requests from Public Network are allowed
|
|
serviceOperationsHostName
|
string
|
|
Service endpoint for provisioning service.
|
|
state
|
State
|
|
Current state of the provisioning service.
|
IotDpsSku
Enumeration
Sku name.
IotDpsSkuInfo
Object
List of possible provisioning service SKUs.
| Name |
Type |
Description |
|
capacity
|
integer
(int64)
|
The number of units to provision
|
|
name
|
IotDpsSku
|
Sku name.
|
|
tier
|
string
|
Pricing tier name of the provisioning service.
|
IotHubAuthenticationType
Enumeration
IotHub MI authentication type: KeyBased, UserAssigned, SystemAssigned.
| Value |
Description |
|
KeyBased
|
Key Based authentication type.
|
|
UserAssigned
|
User assigned authentication type.
|
|
SystemAssigned
|
System assigned authentication type.
|
IotHubDefinitionDescription
Object
Description of the IoT hub.
| Name |
Type |
Description |
|
allocationWeight
|
integer
(int32)
|
weight to apply for a given iot h.
|
|
applyAllocationPolicy
|
boolean
|
flag for applying allocationPolicy or not for a given iot hub.
|
|
authenticationType
|
IotHubAuthenticationType
|
IotHub MI authentication type: KeyBased, UserAssigned, SystemAssigned.
|
|
connectionString
|
string
|
Connection string of the IoT hub. This is required when authenticationType is KeyBased.
|
|
hostName
|
string
|
Host name of the IoT hub. This is required when connectionString is not provided.
|
|
location
|
string
|
ARM region of the IoT hub.
|
|
name
|
string
|
Host name of the IoT hub.
|
|
selectedUserAssignedIdentityResourceId
|
string
(arm-id)
|
The selected user-assigned identity resource Id associated with IoT hub. This is required when authenticationType is UserAssigned.
|
IpFilterActionType
Enumeration
The desired action for requests captured by this rule.
| Value |
Description |
|
Accept
|
|
|
Reject
|
|
IpFilterRule
Object
The IP filter rules for a provisioning Service.
| Name |
Type |
Description |
|
action
|
IpFilterActionType
|
The desired action for requests captured by this rule.
|
|
filterName
|
string
|
The name of the IP filter rule.
|
|
ipMask
|
string
|
A string that contains the IP address range in CIDR notation for the rule.
|
|
target
|
IpFilterTargetType
|
Target for requests captured by this rule.
|
IpFilterTargetType
Enumeration
Target for requests captured by this rule.
| Value |
Description |
|
all
|
|
|
serviceApi
|
|
|
deviceApi
|
|
ManagedServiceIdentity
Object
Managed service identity (system assigned and/or user assigned identities)
| Name |
Type |
Description |
|
principalId
|
string
(uuid)
|
The service principal ID of the system assigned identity. This property will only be provided for a system assigned identity.
|
|
tenantId
|
string
(uuid)
|
The tenant ID of the system assigned identity. This property will only be provided for a system assigned identity.
|
|
type
|
ManagedServiceIdentityType
|
Type of managed service identity (where both SystemAssigned and UserAssigned types are allowed).
|
|
userAssignedIdentities
|
<string,
UserAssignedIdentity>
|
User-Assigned Identities
The set of user assigned identities associated with the resource. The userAssignedIdentities dictionary keys will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}. The dictionary values can be empty objects ({}) in requests.
|
ManagedServiceIdentityType
Enumeration
Type of managed service identity (where both SystemAssigned and UserAssigned types are allowed).
| Value |
Description |
|
None
|
|
|
SystemAssigned
|
|
|
UserAssigned
|
|
|
SystemAssigned,UserAssigned
|
|
PrivateEndpoint
Object
The private endpoint property of a private endpoint connection
| Name |
Type |
Description |
|
id
|
string
|
The resource identifier.
|
PrivateEndpointConnection
Object
The private endpoint connection of a provisioning service
| Name |
Type |
Description |
|
id
|
string
|
Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
|
|
name
|
string
|
The name of the resource
|
|
properties
|
PrivateEndpointConnectionProperties
|
The properties of a private endpoint connection
|
|
systemData
|
systemData
|
Azure Resource Manager metadata containing createdBy and modifiedBy information.
|
|
type
|
string
|
The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
|
PrivateEndpointConnectionProperties
Object
The properties of a private endpoint connection
PrivateLinkServiceConnectionState
Object
The current state of a private endpoint connection
| Name |
Type |
Description |
|
actionsRequired
|
string
|
Actions required for a private endpoint connection
|
|
description
|
string
|
The description for the current state of a private endpoint connection
|
|
status
|
PrivateLinkServiceConnectionStatus
|
The status of a private endpoint connection
|
PrivateLinkServiceConnectionStatus
Enumeration
The status of a private endpoint connection
| Value |
Description |
|
Pending
|
|
|
Approved
|
|
|
Rejected
|
|
|
Disconnected
|
|
ProvisioningServiceDescription
Object
The description of the provisioning service.
| Name |
Type |
Description |
|
etag
|
string
|
The Etag field is not required. If it is provided in the response body, it must also be provided as a header per the normal ETag convention.
|
|
id
|
string
|
Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
|
|
identity
|
ManagedServiceIdentity
|
The managed service identities assigned to this resource.
|
|
location
|
string
|
The geo-location where the resource lives
|
|
name
|
string
|
The name of the resource
|
|
properties
|
IotDpsPropertiesDescription
|
Service specific properties for a provisioning service
|
|
resourcegroup
|
string
|
The resource group of the resource.
|
|
sku
|
IotDpsSkuInfo
|
Sku info for a provisioning Service.
|
|
subscriptionid
|
string
|
The subscription id of the resource.
|
|
systemData
|
systemData
|
Azure Resource Manager metadata containing createdBy and modifiedBy information.
|
|
tags
|
object
|
Resource tags.
|
|
type
|
string
|
The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
|
PublicNetworkAccess
Enumeration
Whether requests from Public Network are allowed
| Value |
Description |
|
Enabled
|
|
|
Disabled
|
|
SharedAccessSignatureAuthorizationRuleAccessRightsDescription
Object
Description of the shared access key.
| Name |
Type |
Description |
|
keyName
|
string
|
Name of the key.
|
|
primaryKey
|
string
|
Primary SAS key value.
|
|
rights
|
AccessRightsDescription
|
Rights that this key has.
|
|
secondaryKey
|
string
|
Secondary SAS key value.
|
State
Enumeration
Current state of the provisioning service.
| Value |
Description |
|
Activating
|
|
|
Active
|
|
|
Deleting
|
|
|
Deleted
|
|
|
ActivationFailed
|
|
|
DeletionFailed
|
|
|
Transitioning
|
|
|
Suspending
|
|
|
Suspended
|
|
|
Resuming
|
|
|
FailingOver
|
|
|
FailoverFailed
|
|
systemData
Object
Metadata pertaining to creation and last modification of the resource.
| Name |
Type |
Description |
|
createdAt
|
string
(date-time)
|
The timestamp of resource creation (UTC).
|
|
createdBy
|
string
|
The identity that created the resource.
|
|
createdByType
|
createdByType
|
The type of identity that created the resource.
|
|
lastModifiedAt
|
string
(date-time)
|
The timestamp of resource last modification (UTC)
|
|
lastModifiedBy
|
string
|
The identity that last modified the resource.
|
|
lastModifiedByType
|
createdByType
|
The type of identity that last modified the resource.
|
UserAssignedIdentity
Object
User assigned identity properties
| Name |
Type |
Description |
|
clientId
|
string
(uuid)
|
The client ID of the assigned identity.
|
|
principalId
|
string
(uuid)
|
The principal ID of the assigned identity.
|