Skip to content
Merged
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"parameters": {
"iotHubName": "testHub",
"resourceGroupName": "myResourceGroup",
"api-version": "2023-06-30",
"subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0",
"failoverInput": {
"failoverRegion": "testHub"
}
},
"responses": {
"200": {},
"202": {
"headers": {
"Azure-AsyncOperation": "https://management.azure.com/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/providers/Microsoft.Devices/operationResults/b3NfaWhfYmJhZmM4OWItNzQ3My00OWExLTg0NWUtNzQ3NWU2ODBkNDA3?api-version=2023-06-30-preview&operationSource=os_ih&asyncinfo",
"Location": "https://management.azure.com/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/providers/Microsoft.Devices/operationResults/b3NfaWhfYmJhZmM4OWItNzQ3My00OWExLTg0NWUtNzQ3NWU2ODBkNDA3?api-version=2022-11-01-preview&operationSource=os_ih"
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"parameters": {
"resourceName": "testHub",
"resourceGroupName": "myResourceGroup",
"api-version": "2023-06-30",
"subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0",
"operationInputs": {
"name": "test-request"
}
},
"responses": {
"200": {
"body": {
"nameAvailable": true,
"reason": "Invalid",
"message": ""
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,348 @@
{
"parameters": {
"resourceName": "testHub",
"resourceGroupName": "myResourceGroup",
"api-version": "2023-06-30",
"subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0",
"iotHubDescription": {
"location": "centraluseuap",
"tags": {},
"etag": "AAAAAAFD6M4=",
"properties": {
"ipFilterRules": [],
"networkRuleSets": {
"defaultAction": "Deny",
"applyToBuiltInEventHubEndpoint": true,
"ipRules": [
{
"filterName": "rule1",
"action": "Allow",
"ipMask": "131.117.159.53"
},
{
"filterName": "rule2",
"action": "Allow",
"ipMask": "157.55.59.128/25"
}
]
},
"eventHubEndpoints": {
"events": {
"retentionTimeInDays": 1,
"partitionCount": 2
}
},
"routing": {
"endpoints": {
"serviceBusQueues": [],
"serviceBusTopics": [],
"eventHubs": [],
"storageContainers": [],
"cosmosDBSqlContainers": [
{
"primaryKey": "<primary-key>",
"secondaryKey": "<secondary-key>",
"authenticationType": "keyBased",
"containerName": "test",
"databaseName": "systemstore",
"endpointUri": "https://test-systemstore-test2.documents.azure.com",
"name": "endpointcosmos",
"partitionKeyName": "keystamped",
"partitionKeyTemplate": "{deviceid}-{YYYY}-{MM}",
"resourceGroup": "rg-test",
"subscriptionId": "<subscription-id>"
}
]
},
"routes": [],
"fallbackRoute": {
"name": "$fallback",
"source": "DeviceMessages",
"condition": "true",
"endpointNames": [
"events"
],
"isEnabled": true
}
},
"storageEndpoints": {
"$default": {
"sasTtlAsIso8601": "PT1H",
"connectionString": "",
"containerName": ""
}
},
"messagingEndpoints": {
"fileNotifications": {
"lockDurationAsIso8601": "PT1M",
"ttlAsIso8601": "PT1H",
"maxDeliveryCount": 10
}
},
"enableFileUploadNotifications": false,
"cloudToDevice": {
"maxDeliveryCount": 10,
"defaultTtlAsIso8601": "PT1H",
"feedback": {
"lockDurationAsIso8601": "PT1M",
"ttlAsIso8601": "PT1H",
"maxDeliveryCount": 10
}
},
"features": "None",
"minTlsVersion": "1.2",
"enableDataResidency": false
},
"sku": {
"name": "S1",
"capacity": 1
}
}
},
"responses": {
"200": {
"body": {
"id": "/subscriptions/ae24ff83-d2ca-4fc8-9717-05dae4bba489/resourceGroups/myResourceGroup/providers/Microsoft.Devices/IotHubs/testHub",
"name": "testHub",
"type": "Microsoft.Devices/IotHubs",
"location": "centraluseuap",
"tags": {},
"etag": "AAAAAAFD6M4=",
"properties": {
"state": "Active",
"provisioningState": "Succeeded",
"ipFilterRules": [
{
"filterName": "rule1",
"action": "Accept",
"ipMask": "131.117.159.53"
},
{
"filterName": "rule2",
"action": "Accept",
"ipMask": "157.55.59.128/25"
}
],
"networkRuleSets": {
"defaultAction": "Deny",
"applyToBuiltInEventHubEndpoint": true,
"ipRules": [
{
"filterName": "rule1",
"action": "Allow",
"ipMask": "131.117.159.53"
},
{
"filterName": "rule2",
"action": "Allow",
"ipMask": "157.55.59.128/25"
}
]
},
"hostName": "iot-dps-cit-hub-1.azure-devices.net",
"eventHubEndpoints": {
"events": {
"retentionTimeInDays": 1,
"partitionCount": 2,
"partitionIds": [
"0",
"1"
],
"path": "iot-dps-cit-hub-1",
"endpoint": "sb://iothub-ns-iot-dps-ci-245306-76aca8e13b.servicebus.windows.net/"
}
},
"routing": {
"endpoints": {
"serviceBusQueues": [],
"serviceBusTopics": [],
"eventHubs": [],
"storageContainers": [],
"cosmosDBSqlContainers": [
{
"id": "009208fa-9cb7-4b90-bfbd-f40086e766c9",
"authenticationType": "keyBased",
"containerName": "test",
"databaseName": "systemstore",
"endpointUri": "https://test-systemstore-test2.documents.azure.com",
"name": "endpointcosmos",
"partitionKeyName": "keystamped",
"partitionKeyTemplate": "{deviceid}-{YYYY}-{MM}",
"resourceGroup": "rg-test",
"subscriptionId": "<subscription-id>"
}
]
},
"routes": [],
"fallbackRoute": {
"name": "$fallback",
"source": "DeviceMessages",
"condition": "true",
"endpointNames": [
"events"
],
"isEnabled": true
}
},
"storageEndpoints": {
"$default": {
"sasTtlAsIso8601": "PT1H",
"connectionString": "",
"containerName": ""
}
},
"messagingEndpoints": {
"fileNotifications": {
"lockDurationAsIso8601": "PT1M",
"ttlAsIso8601": "PT1H",
"maxDeliveryCount": 10
}
},
"enableFileUploadNotifications": false,
"cloudToDevice": {
"maxDeliveryCount": 10,
"defaultTtlAsIso8601": "PT1H",
"feedback": {
"lockDurationAsIso8601": "PT1M",
"ttlAsIso8601": "PT1H",
"maxDeliveryCount": 10
}
},
"features": "None",
"minTlsVersion": "1.2",
"enableDataResidency": false
},
"sku": {
"name": "S1",
"tier": "Standard",
"capacity": 1
},
"systemData": {
"createdAt": "2021-01-30T00:28:38.963Z"
}
}
},
"201": {
"body": {
"id": "/subscriptions/ae24ff83-d2ca-4fc8-9717-05dae4bba489/resourceGroups/myResourceGroup/providers/Microsoft.Devices/IotHubs/testHub",
"name": "testHub",
"type": "Microsoft.Devices/IotHubs",
"location": "centraluseuap",
"tags": {},
"etag": "AAAAAAFD6M4=",
"properties": {
"state": "Active",
"provisioningState": "Succeeded",
"ipFilterRules": [
{
"filterName": "rule1",
"action": "Accept",
"ipMask": "131.117.159.53"
},
{
"filterName": "rule2",
"action": "Accept",
"ipMask": "157.55.59.128/25"
}
],
"networkRuleSets": {
"defaultAction": "Deny",
"applyToBuiltInEventHubEndpoint": true,
"ipRules": [
{
"filterName": "rule1",
"action": "Allow",
"ipMask": "131.117.159.53"
},
{
"filterName": "rule2",
"action": "Allow",
"ipMask": "157.55.59.128/25"
}
]
},
"hostName": "iot-dps-cit-hub-1.azure-devices.net",
"eventHubEndpoints": {
"events": {
"retentionTimeInDays": 1,
"partitionCount": 2,
"partitionIds": [
"0",
"1"
],
"path": "iot-dps-cit-hub-1",
"endpoint": "sb://iothub-ns-iot-dps-ci-245306-76aca8e13b.servicebus.windows.net/"
}
},
"routing": {
"endpoints": {
"serviceBusQueues": [],
"serviceBusTopics": [],
"eventHubs": [],
"storageContainers": [],
"cosmosDBSqlContainers": [
{
"id": "009208fa-9cb7-4b90-bfbd-f40086e766c9",
Copy link
Member

@TimLovellSmith TimLovellSmith Jun 29, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"id": "009208fa-9cb7-4b90-bfbd-f40086e766c9",

In ARM APIs 'id' often means the resource id. I suppose you have to do it this way for consistency, but if not, I would have wondered if we could find a better name, maybe uuid or uniqueId, or if it is even really needed. Is there any way the customer will consume this by passing it to other parts of the API? #ByDesign

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

id is inherited name as in all other endpoints

"authenticationType": "keyBased",
"containerName": "test",
"databaseName": "systemstore",
"endpointUri": "https://test-systemstore-test2.documents.azure.com",
"name": "endpointcosmos",
"partitionKeyName": "keystamped",
"partitionKeyTemplate": "{deviceid}-{YYYY}-{MM}",
"resourceGroup": "rg-test",
"subscriptionId": "<subscription-id>"
}
]
},
"routes": [],
"fallbackRoute": {
"name": "$fallback",
"source": "DeviceMessages",
"condition": "true",
"endpointNames": [
"events"
],
"isEnabled": true
}
},
"storageEndpoints": {
"$default": {
"sasTtlAsIso8601": "PT1H",
"connectionString": "",
"containerName": ""
}
},
"messagingEndpoints": {
"fileNotifications": {
"lockDurationAsIso8601": "PT1M",
"ttlAsIso8601": "PT1H",
"maxDeliveryCount": 10
}
},
"enableFileUploadNotifications": false,
"cloudToDevice": {
"maxDeliveryCount": 10,
"defaultTtlAsIso8601": "PT1H",
"feedback": {
"lockDurationAsIso8601": "PT1M",
"ttlAsIso8601": "PT1H",
"maxDeliveryCount": 10
}
},
"features": "None",
"minTlsVersion": "1.2",
"enableDataResidency": false
},
"sku": {
"name": "S1",
"tier": "Standard",
"capacity": 1
},
"systemData": {
"createdAt": "2021-01-30T00:28:38.963Z"
}
}
}
}
}
Loading