From 462851d4197aed39d380e33101344cde7e6d9d51 Mon Sep 17 00:00:00 2001 From: didact2401 Date: Mon, 18 Apr 2022 15:09:22 -0700 Subject: [PATCH 01/42] Adds base for updating Microsoft.Devices from version preview/2021-07-02-preview to version 2022-04-30-preview --- .../examples/IotHub_ManualFailover.json | 15 + .../examples/checkNameAvailability.json | 20 + .../iothub_certificatescreateorupdate.json | 50 + .../examples/iothub_certificatesdelete.json | 14 + .../examples/iothub_certverify.json | 31 + .../examples/iothub_createOrUpdate.json | 305 ++ .../examples/iothub_createconsumergroup.json | 28 + .../examples/iothub_delete.json | 224 + .../examples/iothub_deleteconsumergroup.json | 13 + ...othub_deleteprivateendpointconnection.json | 46 + .../examples/iothub_exportdevices.json | 27 + .../iothub_generateverificationcode.json | 26 + .../examples/iothub_get.json | 131 + .../examples/iothub_getcertificate.json | 28 + .../examples/iothub_getconsumergroup.json | 23 + .../examples/iothub_getjob.json | 20 + .../examples/iothub_getkey.json | 19 + .../iothub_getprivateendpointconnection.json | 28 + .../iothub_getprivatelinkresources.json | 27 + .../examples/iothub_getskus.json | 53 + .../examples/iothub_importdevices.json | 23 + .../examples/iothub_listbyrg.json | 120 + .../examples/iothub_listbysubscription.json | 119 + .../examples/iothub_listcertificates.json | 31 + .../examples/iothub_listehgroups.json | 26 + .../examples/iothub_listjobs.json | 23 + .../examples/iothub_listkeys.json | 46 + ...iothub_listprivateendpointconnections.json | 29 + .../iothub_listprivatelinkresources.json | 30 + .../examples/iothub_operations.json | 328 ++ .../examples/iothub_patch.json | 125 + .../examples/iothub_quotametrics.json | 26 + .../iothub_routingendpointhealth.json | 34 + .../examples/iothub_stats.json | 17 + .../examples/iothub_testallroutes.json | 38 + .../examples/iothub_testnewroute.json | 52 + ...othub_updateprivateendpointconnection.json | 53 + .../examples/iothub_usages.json | 25 + .../preview/2022-04-30-preview/iothub.json | 4514 +++++++++++++++++ 39 files changed, 6787 insertions(+) create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/IotHub_ManualFailover.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/checkNameAvailability.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certificatescreateorupdate.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certificatesdelete.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certverify.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createOrUpdate.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createconsumergroup.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_delete.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteconsumergroup.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteprivateendpointconnection.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_exportdevices.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_generateverificationcode.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_get.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getcertificate.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getconsumergroup.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getjob.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getkey.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getprivateendpointconnection.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getprivatelinkresources.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getskus.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_importdevices.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listbyrg.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listbysubscription.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listcertificates.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listehgroups.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listjobs.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listkeys.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listprivateendpointconnections.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listprivatelinkresources.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_operations.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_patch.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_quotametrics.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_routingendpointhealth.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_stats.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_testallroutes.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_testnewroute.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_updateprivateendpointconnection.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_usages.json create mode 100644 specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/IotHub_ManualFailover.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/IotHub_ManualFailover.json new file mode 100644 index 000000000000..ba3ce8591da0 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/IotHub_ManualFailover.json @@ -0,0 +1,15 @@ +{ + "parameters": { + "iotHubName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "failoverInput": { + "failoverRegion": "testHub" + } + }, + "responses": { + "200": {}, + "202": {} + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/checkNameAvailability.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/checkNameAvailability.json new file mode 100644 index 000000000000..f9d5e2f6e31f --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/checkNameAvailability.json @@ -0,0 +1,20 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "operationInputs": { + "name": "test-request" + } + }, + "responses": { + "200": { + "body": { + "nameAvailable": true, + "reason": "Invalid", + "message": "" + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certificatescreateorupdate.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certificatescreateorupdate.json new file mode 100644 index 000000000000..5c7ffa5f75d2 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certificatescreateorupdate.json @@ -0,0 +1,50 @@ +{ + "parameters": { + "resourceName": "iothub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "certificateName": "cert", + "certificateDescription": { + "properties": { + "certificate": "############################################" + } + } + }, + "responses": { + "201": { + "body": { + "properties": { + "subject": "CN=testdevice1", + "expiry": "Sat, 31 Dec 2039 23:59:59 GMT", + "thumbprint": "97388663832D0393C9246CAB4FBA2C8677185A25", + "isVerified": false, + "created": "Thu, 12 Oct 2017 19:23:50 GMT", + "updated": "Thu, 12 Oct 2017 19:23:50 GMT", + "certificate": "############################################" + }, + "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/ProvisioningServives/myFirstProvisioningService/certificates/cert", + "name": "cert", + "type": "Microsoft.Devices/IotHubs/Certificates", + "etag": "AAAAAAExpNs=" + } + }, + "200": { + "body": { + "properties": { + "subject": "CN=testdevice1", + "expiry": "Sat, 31 Dec 2039 23:59:59 GMT", + "thumbprint": "97388663832D0393C9246CAB4FBA2C8677185A25", + "isVerified": false, + "created": "Thu, 12 Oct 2017 19:23:50 GMT", + "updated": "Thu, 12 Oct 2017 19:23:50 GMT", + "certificate": "############################################" + }, + "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/ProvisioningServives/myFirstProvisioningService/certificates/cert", + "name": "cert", + "type": "Microsoft.Devices/IotHubs/Certificates", + "etag": "AAAAAAExpNs=" + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certificatesdelete.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certificatesdelete.json new file mode 100644 index 000000000000..6674ad724fce --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certificatesdelete.json @@ -0,0 +1,14 @@ +{ + "parameters": { + "resourceName": "myhub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "certificateName": "cert", + "If-Match": "AAAAAAAADGk=" + }, + "responses": { + "200": {}, + "204": {} + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certverify.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certverify.json new file mode 100644 index 000000000000..9f14c412ae66 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certverify.json @@ -0,0 +1,31 @@ +{ + "parameters": { + "resourceName": "myFirstProvisioningService", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "certificateName": "cert", + "If-Match": "AAAAAAAADGk=", + "certificateVerificationBody": { + "certificate": "#####################################" + } + }, + "responses": { + "200": { + "body": { + "properties": { + "subject": "CN=andbucdevice1", + "expiry": "Sat, 31 Dec 2039 23:59:59 GMT", + "thumbprint": "97388663832D0393C9246CAB4FBA2C8677185A25", + "isVerified": true, + "created": "Thu, 12 Oct 2017 19:23:50 GMT", + "updated": "Thu, 12 Oct 2017 19:26:56 GMT" + }, + "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/ProvisioningServices/myFirstProvisioningService/certificates/cert", + "name": "cert", + "type": "Microsoft.Devices/IotHubs/Certificates", + "etag": "AAAAAAExpTQ=" + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createOrUpdate.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createOrUpdate.json new file mode 100644 index 000000000000..b0e130d5660a --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createOrUpdate.json @@ -0,0 +1,305 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "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": [] + }, + "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": true + }, + "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": [] + }, + "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": true + }, + "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": [] + }, + "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": true + }, + "sku": { + "name": "S1", + "tier": "Standard", + "capacity": 1 + }, + "systemData": { + "createdAt": "2021-01-30T00:28:38.963Z" + } + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createconsumergroup.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createconsumergroup.json new file mode 100644 index 000000000000..5ae8777b4386 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createconsumergroup.json @@ -0,0 +1,28 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "eventHubEndpointName": "events", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "name": "test", + "consumerGroupBody": { + "properties": { + "name": "test" + } + } + }, + "responses": { + "200": { + "body": { + "properties": { + "created": "Thu, 15 Jun 2017 19:20:58 GMT" + }, + "id": "/subscriptions/cmd-sub-1/resourceGroups/cmd-rg-1/providers/Microsoft.Devices/IotHubs/test-hub-2/eventHubEndpoints/events/ConsumerGroups/%24Default", + "name": "test", + "type": "Microsoft.Devices/IotHubs/EventHubEndpoints/ConsumerGroups", + "etag": "AAAAAAFD6M4=" + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_delete.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_delete.json new file mode 100644 index 000000000000..20685015f32a --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_delete.json @@ -0,0 +1,224 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" + }, + "responses": { + "200": { + "body": { + "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/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": [] + }, + "routes": [], + "fallbackRoute": { + "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" + }, + "sku": { + "name": "S1", + "tier": "Standard", + "capacity": 1 + }, + "systemData": { + "createdAt": "2021-01-30T00:28:38.963Z" + } + } + }, + "204": {}, + "202": { + "body": { + "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/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": [] + }, + "routes": [], + "fallbackRoute": { + "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" + }, + "sku": { + "name": "S1", + "tier": "Standard", + "capacity": 1 + }, + "systemData": { + "createdAt": "2021-01-30T00:28:38.963Z" + } + } + }, + "404": { + "body": {} + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteconsumergroup.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteconsumergroup.json new file mode 100644 index 000000000000..f8e12b770a27 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteconsumergroup.json @@ -0,0 +1,13 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "eventHubEndpointName": "events", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "name": "test" + }, + "responses": { + "200": {} + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteprivateendpointconnection.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteprivateendpointconnection.json new file mode 100644 index 000000000000..27d65e823743 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteprivateendpointconnection.json @@ -0,0 +1,46 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "privateEndpointConnectionName": "myPrivateEndpointConnection" + }, + "responses": { + "200": { + "body": { + "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/IotHubs/testHub/PrivateEndpointConnections/myPrivateEndpointConnection", + "name": "myPrivateEndpointConnection", + "type": "Microsoft.Devices/IotHubs/PrivateEndpointConnections", + "properties": { + "privateEndpoint": { + "id": "/subscriptions/a9eba280-4734-4d49-878f-b5549d1d0453/resourceGroups/networkResourceGroup/providers/Microsoft.Network/privateEndpoints/myPrivateEndpoint" + }, + "privateLinkServiceConnectionState": { + "status": "Disconnected", + "description": "Deleted", + "actionsRequired": "None" + } + } + } + }, + "202": { + "body": { + "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/IotHubs/testHub/PrivateEndpointConnections/myPrivateEndpointConnection", + "name": "myPrivateEndpointConnection", + "type": "Microsoft.Devices/IotHubs/PrivateEndpointConnections", + "properties": { + "privateEndpoint": { + "id": "/subscriptions/a9eba280-4734-4d49-878f-b5549d1d0453/resourceGroups/networkResourceGroup/providers/Microsoft.Network/privateEndpoints/myPrivateEndpoint" + }, + "privateLinkServiceConnectionState": { + "status": "Disconnected", + "description": "Deleted", + "actionsRequired": "None" + } + } + } + }, + "204": {} + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_exportdevices.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_exportdevices.json new file mode 100644 index 000000000000..3e7a090bb890 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_exportdevices.json @@ -0,0 +1,27 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "exportDevicesParameters": { + "authenticationType": "identityBased", + "identity": { + "userAssignedIdentity": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.ManagedIdentity/userAssignedIdentities/id1" + }, + "exportBlobContainerUri": "testBlob", + "excludeKeys": true + } + }, + "responses": { + "200": { + "body": { + "jobId": "test", + "startTimeUtc": "Thu, 15 Jun 2017 19:20:58 GMT", + "endTimeUtc": "Thu, 15 Jun 2017 19:20:58 GMT", + "type": "unknown", + "status": "unknown" + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_generateverificationcode.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_generateverificationcode.json new file mode 100644 index 000000000000..2a56c890fcc2 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_generateverificationcode.json @@ -0,0 +1,26 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "certificateName": "cert", + "If-Match": "AAAAAAAADGk=" + }, + "responses": { + "200": { + "body": { + "name": "cert", + "properties": { + "verificationCode": "##################################", + "subject": "CN=andbucdevice1", + "expiry": "Sat, 31 Dec 2039 23:59:59 GMT", + "thumbprint": "##############################", + "isVerified": false, + "created": "Thu, 12 Oct 2017 19:23:50 GMT", + "updated": "Thu, 12 Oct 2017 19:26:56 GMT" + } + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_get.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_get.json new file mode 100644 index 000000000000..083f33f8bc60 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_get.json @@ -0,0 +1,131 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" + }, + "responses": { + "200": { + "body": { + "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/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": [] + }, + "routes": [], + "fallbackRoute": { + "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", + "deviceStreams": { + "streamingEndpoints": [ + "https://streams.azure-devices-int.net:9443" + ] + }, + "locations": [ + { + "location": "West US", + "role": "primary" + }, + { + "location": "East US", + "role": "secondary" + } + ], + "minTlsVersion": "1.2" + }, + "sku": { + "name": "S1", + "tier": "Standard", + "capacity": 1 + }, + "systemData": { + "createdAt": "2021-01-30T00:28:38.963Z" + } + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getcertificate.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getcertificate.json new file mode 100644 index 000000000000..31ff921df634 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getcertificate.json @@ -0,0 +1,28 @@ +{ + "parameters": { + "resourceName": "testhub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "certificateName": "cert" + }, + "responses": { + "200": { + "body": { + "properties": { + "subject": "CN=testdevice1", + "expiry": "Sat, 31 Dec 2039 23:59:59 GMT", + "thumbprint": "97388663832D0393C9246CAB4FBA2C8677185A25", + "isVerified": false, + "created": "Thu, 12 Oct 2017 19:23:50 GMT", + "updated": "Thu, 12 Oct 2017 19:23:50 GMT", + "certificate": "############################################" + }, + "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/IotHubs/andbuc-hub/certificates/cert", + "name": "cert", + "type": "Microsoft.Devices/IotHubs/Certificates", + "etag": "AAAAAAExpNs=" + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getconsumergroup.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getconsumergroup.json new file mode 100644 index 000000000000..7d37e97dd0d5 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getconsumergroup.json @@ -0,0 +1,23 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "eventHubEndpointName": "events", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "name": "test" + }, + "responses": { + "200": { + "body": { + "properties": { + "created": "Thu, 15 Jun 2017 19:20:58 GMT" + }, + "id": "/subscriptions/cmd-sub-1/resourceGroups/cmd-rg-1/providers/Microsoft.Devices/IotHubs/test-hub-2/eventHubEndpoints/events/ConsumerGroups/%24Default", + "name": "test", + "type": "Microsoft.Devices/IotHubs/EventHubEndpoints/ConsumerGroups", + "etag": "AAAAAAFD6M4=" + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getjob.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getjob.json new file mode 100644 index 000000000000..11311db37fd6 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getjob.json @@ -0,0 +1,20 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "jobId": "test" + }, + "responses": { + "200": { + "body": { + "jobId": "test", + "startTimeUtc": "Thu, 15 Jun 2017 19:20:58 GMT", + "endTimeUtc": "Thu, 15 Jun 2017 19:20:58 GMT", + "type": "unknown", + "status": "unknown" + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getkey.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getkey.json new file mode 100644 index 000000000000..bf4f814f8518 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getkey.json @@ -0,0 +1,19 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "keyName": "iothubowner" + }, + "responses": { + "200": { + "body": { + "keyName": "iothubowner", + "primaryKey": "", + "secondaryKey": "", + "rights": "RegistryWrite, ServiceConnect, DeviceConnect" + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getprivateendpointconnection.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getprivateendpointconnection.json new file mode 100644 index 000000000000..4ff0b85da780 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getprivateendpointconnection.json @@ -0,0 +1,28 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "privateEndpointConnectionName": "myPrivateEndpointConnection" + }, + "responses": { + "200": { + "body": { + "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/IotHubs/testHub/PrivateEndpointConnections/myPrivateEndpointConnection", + "name": "myPrivateEndpointConnection", + "type": "Microsoft.Devices/IotHubs/PrivateEndpointConnections", + "properties": { + "privateEndpoint": { + "id": "/subscriptions/a9eba280-4734-4d49-878f-b5549d1d0453/resourceGroups/networkResourceGroup/providers/Microsoft.Network/privateEndpoints/myPrivateEndpoint" + }, + "privateLinkServiceConnectionState": { + "status": "Pending", + "description": "Please approve my request!", + "actionsRequired": "None" + } + } + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getprivatelinkresources.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getprivatelinkresources.json new file mode 100644 index 000000000000..2208810789c9 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getprivatelinkresources.json @@ -0,0 +1,27 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "groupId": "iotHub" + }, + "responses": { + "200": { + "body": { + "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/IotHubs/testHub/PrivateLinkResources/iotHub", + "name": "iotHub", + "type": "Microsoft.Devices/IotHubs/PrivateLinkResources", + "properties": { + "groupId": "iotHub", + "requiredMembers": [ + "iotHub" + ], + "requiredZoneNames": [ + "privatelink.azure-devices.net" + ] + } + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getskus.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getskus.json new file mode 100644 index 000000000000..367922d2f233 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getskus.json @@ -0,0 +1,53 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "resourceType": "Microsoft.Devices/IotHubs", + "sku": { + "name": "S1", + "tier": "Standard" + }, + "capacity": { + "default": 1, + "scaleType": "Manual" + } + }, + { + "resourceType": "Microsoft.Devices/IotHubs", + "sku": { + "name": "S2", + "tier": "Standard" + }, + "capacity": { + "minimum": 1, + "maximum": 200, + "default": 1, + "scaleType": "Manual" + } + }, + { + "resourceType": "Microsoft.Devices/IotHubs", + "sku": { + "name": "S3", + "tier": "Standard" + }, + "capacity": { + "minimum": 1, + "maximum": 10, + "default": 1, + "scaleType": "Manual" + } + } + ] + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_importdevices.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_importdevices.json new file mode 100644 index 000000000000..cf3940c37ac4 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_importdevices.json @@ -0,0 +1,23 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "importDevicesParameters": { + "inputBlobContainerUri": "testBlob", + "outputBlobContainerUri": "testBlob" + } + }, + "responses": { + "200": { + "body": { + "jobId": "test", + "startTimeUtc": "Thu, 15 Jun 2017 19:20:58 GMT", + "endTimeUtc": "Thu, 15 Jun 2017 19:20:58 GMT", + "type": "unknown", + "status": "unknown" + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listbyrg.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listbyrg.json new file mode 100644 index 000000000000..4c4d8590fd3f --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listbyrg.json @@ -0,0 +1,120 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/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": [] + }, + "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" + }, + "sku": { + "name": "S1", + "tier": "Standard", + "capacity": 1 + }, + "systemData": { + "createdAt": "2021-01-30T00:28:38.963Z" + } + } + ] + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listbysubscription.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listbysubscription.json new file mode 100644 index 000000000000..4cba193e6de0 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listbysubscription.json @@ -0,0 +1,119 @@ +{ + "parameters": { + "resourceName": "testHub", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/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": [] + }, + "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" + }, + "sku": { + "name": "S1", + "tier": "Standard", + "capacity": 1 + }, + "systemData": { + "createdAt": "2021-01-30T00:28:38.963Z" + } + } + ] + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listcertificates.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listcertificates.json new file mode 100644 index 000000000000..bac71cb62a87 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listcertificates.json @@ -0,0 +1,31 @@ +{ + "parameters": { + "resourceName": "testhub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "properties": { + "subject": "CN=testdevice1", + "expiry": "Sat, 31 Dec 2039 23:59:59 GMT", + "thumbprint": "97388663832D0393C9246CAB4FBA2C8677185A25", + "isVerified": false, + "created": "Thu, 12 Oct 2017 19:23:50 GMT", + "updated": "Thu, 12 Oct 2017 19:23:50 GMT", + "certificate": "############################################" + }, + "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/IotHubs/andbuc-hub/certificates/cert", + "name": "cert", + "type": "Microsoft.Devices/IotHubs/Certificates", + "etag": "AAAAAAExpNs=" + } + ] + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listehgroups.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listehgroups.json new file mode 100644 index 000000000000..92f349047ce9 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listehgroups.json @@ -0,0 +1,26 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "eventHubEndpointName": "events", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "properties": { + "created": "Thu, 15 Jun 2017 19:20:58 GMT" + }, + "id": "/subscriptions/cmd-sub-1/resourceGroups/cmd-rg-1/providers/Microsoft.Devices/IotHubs/test-hub-2/eventHubEndpoints/events/ConsumerGroups/%24Default", + "name": "$Default", + "type": "Microsoft.Devices/IotHubs/EventHubEndpoints/ConsumerGroups", + "etag": "AAAAAAFD6M4=" + } + ] + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listjobs.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listjobs.json new file mode 100644 index 000000000000..c5a6c8fe132d --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listjobs.json @@ -0,0 +1,23 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "jobId": "test", + "startTimeUtc": "Thu, 15 Jun 2017 19:20:58 GMT", + "endTimeUtc": "Thu, 15 Jun 2017 19:20:58 GMT", + "type": "unknown", + "status": "unknown" + } + ] + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listkeys.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listkeys.json new file mode 100644 index 000000000000..51dfe405df35 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listkeys.json @@ -0,0 +1,46 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "keyName": "iothubowner", + "primaryKey": "", + "secondaryKey": "", + "rights": "RegistryWrite, ServiceConnect, DeviceConnect" + }, + { + "keyName": "service", + "primaryKey": "", + "secondaryKey": "", + "rights": "ServiceConnect" + }, + { + "keyName": "device", + "primaryKey": "", + "secondaryKey": "", + "rights": "DeviceConnect" + }, + { + "keyName": "registryRead", + "primaryKey": "", + "secondaryKey": "", + "rights": "RegistryRead" + }, + { + "keyName": "registryReadWrite", + "primaryKey": "", + "secondaryKey": "", + "rights": "RegistryWrite" + } + ] + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listprivateendpointconnections.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listprivateendpointconnections.json new file mode 100644 index 000000000000..8867691fb477 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listprivateendpointconnections.json @@ -0,0 +1,29 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" + }, + "responses": { + "200": { + "body": [ + { + "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/IotHubs/testHub/PrivateEndpointConnections/myPrivateEndpointConnection", + "name": "myPrivateEndpointConnection", + "type": "Microsoft.Devices/IotHubs/PrivateEndpointConnections", + "properties": { + "privateEndpoint": { + "id": "/subscriptions/a9eba280-4734-4d49-878f-b5549d1d0453/resourceGroups/networkResourceGroup/providers/Microsoft.Network/privateEndpoints/myPrivateEndpoint" + }, + "privateLinkServiceConnectionState": { + "status": "Pending", + "description": "Please approve my request!", + "actionsRequired": "None" + } + } + } + ] + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listprivatelinkresources.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listprivatelinkresources.json new file mode 100644 index 000000000000..d690aa05e12c --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listprivatelinkresources.json @@ -0,0 +1,30 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/IotHubs/testHub/PrivateLinkResources/iotHub", + "name": "iotHub", + "type": "Microsoft.Devices/IotHubs/PrivateLinkResources", + "properties": { + "groupId": "iotHub", + "requiredMembers": [ + "iotHub" + ], + "requiredZoneNames": [ + "privatelink.azure-devices.net" + ] + } + } + ] + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_operations.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_operations.json new file mode 100644 index 000000000000..acd916d9d5ef --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_operations.json @@ -0,0 +1,328 @@ +{ + "parameters": { + "api-version": "2021-07-02-preview" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "name": "Microsoft.Devices/register/action", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Register Resource Provider", + "description": "Register the subscription for the IotHub resource provider and enables the creation of IotHub resources" + } + }, + { + "name": "Microsoft.Devices/IotHubs/diagnosticSettings/read", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Get Diagnostic Setting", + "description": "Gets the diagnostic setting for the resource" + } + }, + { + "name": "Microsoft.Devices/IotHubs/diagnosticSettings/write", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Set Diagnostic Setting", + "description": "Creates or updates the diagnostic setting for the resource" + } + }, + { + "name": "Microsoft.Devices/IotHubs/metricDefinitions/read", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Read IotHub service metric definitions", + "description": "Gets the available metrics for the IotHub service" + } + }, + { + "name": "Microsoft.Devices/IotHubs/logDefinitions/read", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Read IotHub service log definitions", + "description": "Gets the available log definitions for the IotHub Service" + } + }, + { + "name": "Microsoft.Devices/operations/Read", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Get All ResourceProvider Operations", + "description": "Get All ResourceProvider Operations" + } + }, + { + "name": "Microsoft.Devices/checkNameAvailability/Action", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Check If IotHub name is available", + "description": "Check If IotHub name is available" + } + }, + { + "name": "Microsoft.Devices/usages/Read", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Get Subscription Usages", + "description": "Get subscription usage details for this provider." + } + }, + { + "name": "Microsoft.Devices/iotHubs/Read", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Get IotHub(s)", + "description": "Gets the IotHub resource(s)" + } + }, + { + "name": "Microsoft.Devices/iotHubs/Write", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Create or update IotHub Resource", + "description": "Create or update IotHub Resource" + } + }, + { + "name": "Microsoft.Devices/iotHubs/Delete", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Delete IotHub Resource", + "description": "Delete IotHub Resource" + } + }, + { + "name": "Microsoft.Devices/iotHubs/iotHubStats/Read", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Get IotHub Statistics", + "description": "Get IotHub Statistics" + } + }, + { + "name": "Microsoft.Devices/iotHubs/skus/Read", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Get valid IotHub Skus", + "description": "Get valid IotHub Skus" + } + }, + { + "name": "Microsoft.Devices/iotHubs/listkeys/Action", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Get all IotHub Keys", + "description": "Get all IotHub Keys" + } + }, + { + "name": "Microsoft.Devices/iotHubs/iotHubKeys/listkeys/Action", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Get IotHub Key for the given name", + "description": "Get IotHub Key for the given name" + } + }, + { + "name": "Microsoft.Devices/iotHubs/eventHubEndpoints/consumerGroups/Write", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Create EventHub Consumer Group", + "description": "Create EventHub Consumer Group" + } + }, + { + "name": "Microsoft.Devices/iotHubs/eventHubEndpoints/consumerGroups/Read", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Get EventHub Consumer Group(s)", + "description": "Get EventHub Consumer Group(s)" + } + }, + { + "name": "Microsoft.Devices/iotHubs/eventHubEndpoints/consumerGroups/Delete", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Delete EventHub Consumer Group", + "description": "Delete EventHub Consumer Group" + } + }, + { + "name": "Microsoft.Devices/iotHubs/exportDevices/Action", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Export Devices", + "description": "Export Devices" + } + }, + { + "name": "Microsoft.Devices/iotHubs/importDevices/Action", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Import Devices", + "description": "Import Devices" + } + }, + { + "name": "Microsoft.Devices/iotHubs/jobs/Read", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Get the Job(s) on IotHub", + "description": "Get Job(s) details submitted on given IotHub" + } + }, + { + "name": "Microsoft.Devices/iotHubs/quotaMetrics/Read", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Get Quota Metrics", + "description": "Get Quota Metrics" + } + }, + { + "name": "Microsoft.Devices/iotHubs/routing/routes/$testall/Action", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Routing Rule Test All", + "description": "Test a message against all existing Routes" + } + }, + { + "name": "Microsoft.Devices/iotHubs/routing/routes/$testnew/Action", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Routing Rule Test Route", + "description": "Test a message against a provided test Route" + } + }, + { + "name": "Microsoft.Devices/iotHubs/routingEndpointsHealth/Read", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Get Endpoint Health", + "description": "Gets the health of all routing Endpoints for an IotHub" + } + }, + { + "name": "Microsoft.Devices/ProvisioningServices/diagnosticSettings/read", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Get Diagnostic Setting", + "description": "Gets the diagnostic setting for the resource" + } + }, + { + "name": "Microsoft.Devices/ProvisioningServices/diagnosticSettings/write", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Set Diagnostic Setting", + "description": "Creates or updates the diagnostic setting for the resource" + } + }, + { + "name": "Microsoft.Devices/ProvisioningServices/metricDefinitions/read", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Read DPS service metric definitions", + "description": "Gets the available metrics for the DPS service" + } + }, + { + "name": "Microsoft.Devices/ProvisioningServices/logDefinitions/read", + "display": { + "provider": "Microsoft Devices", + "resource": "IotHubs", + "operation": "Read DPS service log definitions", + "description": "Gets the available log definitions for the DPS Service" + } + }, + { + "name": "Microsoft.Devices/checkProvisioningServiceNameAvailability/Action", + "display": { + "provider": "Microsoft Devices", + "resource": "ProvisioningServives", + "operation": "Check If Provisioning Service name is available", + "description": "Check If Provisioning Service name is available" + } + }, + { + "name": "Microsoft.Devices/provisioningServices/Read", + "display": { + "provider": "Microsoft Devices", + "resource": "ProvisioningServices", + "operation": "Get Provisioning Service resource", + "description": "Get Provisioning Service resource" + } + }, + { + "name": "Microsoft.Devices/provisioningServices/Write", + "display": { + "provider": "Microsoft Devices", + "resource": "ProvisioningServices", + "operation": "Create Provisioning Service resource", + "description": "Create Provisioning Service resource" + } + }, + { + "name": "Microsoft.Devices/provisioningServices/Delete", + "display": { + "provider": "Microsoft Devices", + "resource": "ProvisioningServices", + "operation": "Delete Provisioning Service resource", + "description": "Delete Provisioning Service resource" + } + }, + { + "name": "Microsoft.Devices/provisioningServices/skus/Read", + "display": { + "provider": "Microsoft Devices", + "resource": "ProvisioningServices", + "operation": "Delete Provisioning Service resource", + "description": "Delete Provisioning Service resource" + } + }, + { + "name": "Microsoft.Devices/provisioningServices/listkeys/Action", + "display": { + "provider": "Microsoft Devices", + "resource": "ProvisioningServices", + "operation": "get security related metadata", + "description": "get security related metadata" + } + } + ] + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_patch.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_patch.json new file mode 100644 index 000000000000..8f28ea7a184e --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_patch.json @@ -0,0 +1,125 @@ +{ + "parameters": { + "resourceName": "myHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "location": "East US", + "type": "Microsoft.Devices/IotHubs", + "IotHubTags": { + "tags": { + "foo": "bar" + } + } + }, + "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": { + "foo": "bar" + }, + "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": [] + }, + "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" + }, + "sku": { + "name": "S1", + "tier": "Standard", + "capacity": 1 + }, + "systemData": { + "createdAt": "2021-01-30T00:28:38.963Z" + } + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_quotametrics.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_quotametrics.json new file mode 100644 index 000000000000..d8c89aa76fa3 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_quotametrics.json @@ -0,0 +1,26 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "name": "TotalMessages", + "currentValue": 0, + "maxValue": 400000 + }, + { + "name": "TotalDeviceCount", + "currentValue": 0, + "maxValue": 500000 + } + ] + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_routingendpointhealth.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_routingendpointhealth.json new file mode 100644 index 000000000000..a11d3e1bccd1 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_routingendpointhealth.json @@ -0,0 +1,34 @@ +{ + "parameters": { + "iotHubName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "endpointId": "id1", + "healthStatus": "healthy", + "lastSuccessfulSendAttemptTime": "2020-03-26T21:20:57Z", + "lastSendAttemptTime": "2020-03-26T21:24:57Z" + }, + { + "endpointId": "id2", + "healthStatus": "unknown" + }, + { + "endpointId": "id3", + "healthStatus": "unhealthy", + "lastKnownError": "NotFound", + "lastKnownErrorTime": "2020-03-26T21:24:57Z", + "lastSuccessfulSendAttemptTime": "2020-03-26T21:20:57Z", + "lastSendAttemptTime": "2020-03-26T21:24:57Z" + } + ] + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_stats.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_stats.json new file mode 100644 index 000000000000..1a7bcb918e7e --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_stats.json @@ -0,0 +1,17 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2018-04-01", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" + }, + "responses": { + "200": { + "body": { + "totalDeviceCount": 0, + "enabledDeviceCount": 0, + "disabledDeviceCount": 0 + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_testallroutes.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_testallroutes.json new file mode 100644 index 000000000000..852b33807074 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_testallroutes.json @@ -0,0 +1,38 @@ +{ + "parameters": { + "iotHubName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "input": { + "routingSource": "DeviceMessages", + "message": { + "body": "Body of message", + "appProperties": { + "key1": "value1" + }, + "systemProperties": { + "key1": "value1" + } + } + } + }, + "responses": { + "200": { + "body": { + "routes": [ + { + "properties": { + "name": "Routeid", + "source": "DeviceMessages", + "endpointNames": [ + "id1" + ], + "isEnabled": true + } + } + ] + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_testnewroute.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_testnewroute.json new file mode 100644 index 000000000000..7d3725b8243f --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_testnewroute.json @@ -0,0 +1,52 @@ +{ + "parameters": { + "iotHubName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "input": { + "message": { + "body": "Body of message", + "appProperties": { + "key1": "value1" + }, + "systemProperties": { + "key1": "value1" + } + }, + "route": { + "name": "Routeid", + "source": "DeviceMessages", + "endpointNames": [ + "id1" + ], + "isEnabled": true + } + } + }, + "responses": { + "200": { + "body": { + "result": "false", + "details": { + "compilationErrors": [ + { + "message": "string response", + "severity": "error", + "location": { + "start": { + "line": 12, + "column": 12 + }, + "end": { + "line": 12, + "column": 24 + } + } + } + ] + } + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_updateprivateendpointconnection.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_updateprivateendpointconnection.json new file mode 100644 index 000000000000..791e5ee279fc --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_updateprivateendpointconnection.json @@ -0,0 +1,53 @@ +{ + "parameters": { + "resourceName": "testHub", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", + "privateEndpointConnectionName": "myPrivateEndpointConnection", + "privateEndpointConnection": { + "properties": { + "privateLinkServiceConnectionState": { + "status": "Approved", + "description": "Approved by johndoe@contoso.com" + } + } + } + }, + "responses": { + "200": { + "body": { + "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/IotHubs/testHub/PrivateEndpointConnections/myPrivateEndpointConnection", + "name": "myPrivateEndpointConnection", + "type": "Microsoft.Devices/IotHubs/PrivateEndpointConnections", + "properties": { + "privateEndpoint": { + "id": "/subscriptions/a9eba280-4734-4d49-878f-b5549d1d0453/resourceGroups/networkResourceGroup/providers/Microsoft.Network/privateEndpoints/myPrivateEndpoint" + }, + "privateLinkServiceConnectionState": { + "status": "Approved", + "description": "Approved by johndoe@contoso.com", + "actionsRequired": "None" + } + } + } + }, + "201": { + "body": { + "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/IotHubs/testHub/PrivateEndpointConnections/myPrivateEndpointConnection", + "name": "myPrivateEndpointConnection", + "type": "Microsoft.Devices/IotHubs/PrivateEndpointConnections", + "properties": { + "privateEndpoint": { + "id": "/subscriptions/a9eba280-4734-4d49-878f-b5549d1d0453/resourceGroups/networkResourceGroup/providers/Microsoft.Network/privateEndpoints/myPrivateEndpoint" + }, + "privateLinkServiceConnectionState": { + "status": "Approved", + "description": "Approved by johndoe@contoso.com", + "actionsRequired": "None" + } + } + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_usages.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_usages.json new file mode 100644 index 000000000000..ee71609f8b0c --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_usages.json @@ -0,0 +1,25 @@ +{ + "parameters": { + "api-version": "2021-07-02-preview", + "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "id": "/subscription/91d12660-3dec-467a-be2a-213b5544ddc0/providers/Microsoft.Devices/usages/freeHubCount", + "type": "/subscription/91d12660-3dec-467a-be2a-213b5544ddc0/providers/Microsoft.Devices/usages", + "unit": "count", + "currentValue": 1, + "limit": 1, + "name": { + "value": "FreeHubCount", + "localizedValue": "Free Hub Count" + } + } + ] + } + } + } +} diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json new file mode 100644 index 000000000000..5dd7e602e110 --- /dev/null +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -0,0 +1,4514 @@ +{ + "swagger": "2.0", + "info": { + "version": "2021-07-02-preview", + "title": "iotHubClient", + "description": "Use this API to manage the IoT hubs in your Azure subscription.", + "x-ms-code-generation-settings": { + "header": "MICROSOFT_MIT_NO_VERSION" + } + }, + "host": "management.azure.com", + "schemes": [ + "https" + ], + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "security": [ + { + "azure_auth": [ + "user_impersonation" + ] + } + ], + "securityDefinitions": { + "azure_auth": { + "type": "oauth2", + "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", + "flow": "implicit", + "description": "Azure Active Directory OAuth2 Flow", + "scopes": { + "user_impersonation": "impersonate your user account" + } + } + }, + "paths": { + "/providers/Microsoft.Devices/operations": { + "get": { + "tags": [ + "Operations" + ], + "x-ms-examples": { + "Operations_List": { + "$ref": "./examples/iothub_operations.json" + } + }, + "operationId": "Operations_List", + "description": "Lists all of the available IoT Hub REST API operations.", + "parameters": [ + { + "$ref": "#/parameters/api-version" + } + ], + "responses": { + "200": { + "description": "OK. The request has succeeded.", + "schema": { + "$ref": "#/definitions/OperationListResult" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink" + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}": { + "get": { + "tags": [ + "GET" + ], + "summary": "Get the non-security related metadata of an IoT hub", + "description": "Get the non-security related metadata of an IoT hub.", + "operationId": "IotHubResource_Get", + "x-ms-examples": { + "IotHubResource_Get": { + "$ref": "./examples/iothub_get.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + } + ], + "responses": { + "200": { + "description": "The body contains all the non-security properties of the IoT hub. Security-related properties are set to null.", + "schema": { + "$ref": "#/definitions/IotHubDescription" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + }, + "put": { + "tags": [ + "PUT" + ], + "summary": "Create or update the metadata of an IoT hub.", + "description": "Create or update the metadata of an Iot hub. The usual pattern to modify a property is to retrieve the IoT hub metadata and security metadata, and then combine them with the modified values in a new body to update the IoT hub.", + "operationId": "IotHubResource_CreateOrUpdate", + "x-ms-examples": { + "IotHubResource_CreateOrUpdate": { + "$ref": "./examples/iothub_createOrUpdate.json" + } + }, + "x-ms-long-running-operation": true, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + }, + { + "name": "iotHubDescription", + "in": "body", + "description": "The IoT hub metadata and security metadata.", + "required": true, + "schema": { + "$ref": "#/definitions/IotHubDescription" + } + }, + { + "name": "If-Match", + "in": "header", + "required": false, + "type": "string", + "description": "ETag of the IoT Hub. Do not specify for creating a brand new IoT Hub. Required to update an existing IoT Hub." + } + ], + "responses": { + "201": { + "description": "This is a long running operation. The operation returns a 201 if the validation is complete. The response includes an Azure-AsyncOperation header that contains a status URL. Clients are expected to poll the status URL for the status of the operation. If successful, the operation returns HTTP status code of 201 (OK).", + "schema": { + "$ref": "#/definitions/IotHubDescription" + } + }, + "200": { + "description": "This is returned as a response to the status polling request for the create or update operation. The body contains the resource representation that indicates a transitional provisioning state.", + "schema": { + "$ref": "#/definitions/IotHubDescription" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + }, + "patch": { + "tags": [ + "PATCH" + ], + "summary": "Update an existing IoT Hubs tags.", + "description": "Update an existing IoT Hub tags. to update other fields use the CreateOrUpdate method", + "x-ms-long-running-operation": true, + "operationId": "IotHubResource_Update", + "x-ms-examples": { + "IotHubResource_Update": { + "$ref": "./examples/iothub_patch.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/subscriptionId" + }, + { + "name": "resourceGroupName", + "in": "path", + "required": true, + "type": "string", + "description": "Resource group identifier." + }, + { + "name": "resourceName", + "in": "path", + "required": true, + "type": "string", + "description": "Name of iot hub to update." + }, + { + "name": "IotHubTags", + "in": "body", + "required": true, + "description": "Updated tag information to set into the iot hub instance.", + "schema": { + "$ref": "#/definitions/TagsResource" + } + }, + { + "$ref": "#/parameters/api-version" + } + ], + "responses": { + "200": { + "description": "Iot Hub was successfully updated", + "schema": { + "$ref": "#/definitions/IotHubDescription" + } + } + }, + "produces": [ + "application/json" + ], + "consumes": [ + "application/json" + ] + }, + "delete": { + "tags": [ + "DELETE" + ], + "summary": "Delete an IoT hub", + "description": "Delete an IoT hub.", + "operationId": "IotHubResource_Delete", + "x-ms-examples": { + "IotHubResource_Delete": { + "$ref": "./examples/iothub_delete.json" + } + }, + "x-ms-long-running-operation": true, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + } + ], + "responses": { + "202": { + "description": "The Iot Hub resource provider always returns a 202 Accepted status code with valid Location and Retry-After headers. The resource provider also sets the Azure-AsyncOperation header with a URL that points to the operation resource for this operation. Subsequent GET attempts on the resource after a DELETE operation return a resource representation that indicates a transitional provisioning state (such as Terminating). To retrieve the status of the operation, a client can either poll the URL returned in the Location header after the Retry-After interval, get the IoT Hub service status directly, or query the operation resource.", + "schema": { + "$ref": "#/definitions/IotHubDescription" + } + }, + "200": { + "description": "This is returned as a response to the status polling request for the delete operation. The body contains the resource representation that indicates a transitional provisioning state.", + "schema": { + "$ref": "#/definitions/IotHubDescription" + } + }, + "204": { + "description": "Once the long running delete operation completes successfully, a 204 No Content status code is returned when the status polling request finds the Iot hub metadata in the service and the status of the delete operation is set to a completed state." + }, + "404": { + "description": "After the long running delete operation completes successfully, a 404 Not Found is returned when the status polling request no longer finds the Iot hub metadata in the service.", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + } + }, + "/subscriptions/{subscriptionId}/providers/Microsoft.Devices/IotHubs": { + "get": { + "tags": [ + "GET" + ], + "summary": "Get all the IoT hubs in a subscription", + "description": "Get all the IoT hubs in a subscription.", + "operationId": "IotHubResource_ListBySubscription", + "x-ms-examples": { + "IotHubResource_ListBySubscription": { + "$ref": "./examples/iothub_listbysubscription.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + } + ], + "responses": { + "200": { + "description": "This is a synchronous operation. The body contains a JSON-serialized array of the metadata from all the IoT hubs in the subscription.", + "schema": { + "$ref": "#/definitions/IotHubDescriptionListResult" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false, + "x-ms-pageable": { + "nextLinkName": "nextLink" + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs": { + "get": { + "tags": [ + "GET" + ], + "summary": "Get all the IoT hubs in a resource group", + "description": "Get all the IoT hubs in a resource group.", + "operationId": "IotHubResource_ListByResourceGroup", + "x-ms-examples": { + "IotHubResource_ListByResourceGroup": { + "$ref": "./examples/iothub_listbyrg.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + } + ], + "responses": { + "200": { + "description": "This is a synchronous operation. The body contains a JSON-serialized array of the metadata from all the IoT hubs in the resource group.", + "schema": { + "$ref": "#/definitions/IotHubDescriptionListResult" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false, + "x-ms-pageable": { + "nextLinkName": "nextLink" + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/IotHubStats": { + "get": { + "tags": [ + "GET" + ], + "summary": "Get the statistics from an IoT hub", + "description": "Get the statistics from an IoT hub.", + "operationId": "IotHubResource_GetStats", + "x-ms-examples": { + "IotHubResource_GetStats": { + "$ref": "./examples/iothub_stats.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + } + ], + "responses": { + "200": { + "description": "This is a synchronous operation. The body contains JSON-serialized statistics from the identity registry in the IoT hub.", + "schema": { + "$ref": "#/definitions/RegistryStatistics" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/skus": { + "get": { + "tags": [ + "GET" + ], + "summary": "Get the list of valid SKUs for an IoT hub", + "description": "Get the list of valid SKUs for an IoT hub.", + "operationId": "IotHubResource_GetValidSkus", + "x-ms-examples": { + "IotHubResource_GetValidSkus": { + "$ref": "./examples/iothub_getskus.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + } + ], + "responses": { + "200": { + "description": "This is a synchronous operation. The body contains a JSON-serialized array of the valid SKUs for this IoT hub.", + "schema": { + "$ref": "#/definitions/IotHubSkuDescriptionListResult" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false, + "x-ms-pageable": { + "nextLinkName": "nextLink" + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/eventHubEndpoints/{eventHubEndpointName}/ConsumerGroups": { + "get": { + "tags": [ + "GET" + ], + "summary": "Get a list of the consumer groups in the Event Hub-compatible device-to-cloud endpoint in an IoT hub", + "description": "Get a list of the consumer groups in the Event Hub-compatible device-to-cloud endpoint in an IoT hub.", + "operationId": "IotHubResource_ListEventHubConsumerGroups", + "x-ms-examples": { + "IotHubResource_ListEventHubConsumerGroups": { + "$ref": "./examples/iothub_listehgroups.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + }, + { + "name": "eventHubEndpointName", + "in": "path", + "description": "The name of the Event Hub-compatible endpoint.", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "This is a synchronous operation. The body contains a JSON-serialized list of the consumer groups in the Event Hub-compatible endpoint in this IoT hub", + "schema": { + "$ref": "#/definitions/EventHubConsumerGroupsListResult" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false, + "x-ms-pageable": { + "nextLinkName": "nextLink" + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/eventHubEndpoints/{eventHubEndpointName}/ConsumerGroups/{name}": { + "get": { + "tags": [ + "GET" + ], + "summary": "Get a consumer group from the Event Hub-compatible device-to-cloud endpoint for an IoT hub", + "description": "Get a consumer group from the Event Hub-compatible device-to-cloud endpoint for an IoT hub.", + "operationId": "IotHubResource_GetEventHubConsumerGroup", + "x-ms-examples": { + "IotHubResource_ListEventHubConsumerGroups": { + "$ref": "./examples/iothub_getconsumergroup.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + }, + { + "name": "eventHubEndpointName", + "in": "path", + "description": "The name of the Event Hub-compatible endpoint in the IoT hub.", + "required": true, + "type": "string" + }, + { + "name": "name", + "in": "path", + "description": "The name of the consumer group to retrieve.", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "This is a synchronous operation. The body contains a JSON-serialized consumer group.", + "schema": { + "$ref": "#/definitions/EventHubConsumerGroupInfo" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + }, + "put": { + "tags": [ + "PUT" + ], + "summary": "Add a consumer group to an Event Hub-compatible endpoint in an IoT hub", + "description": "Add a consumer group to an Event Hub-compatible endpoint in an IoT hub.", + "operationId": "IotHubResource_CreateEventHubConsumerGroup", + "x-ms-examples": { + "IotHubResource_CreateEventHubConsumerGroup": { + "$ref": "./examples/iothub_createconsumergroup.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + }, + { + "name": "eventHubEndpointName", + "in": "path", + "description": "The name of the Event Hub-compatible endpoint in the IoT hub.", + "required": true, + "type": "string" + }, + { + "name": "name", + "in": "path", + "description": "The name of the consumer group to add.", + "required": true, + "type": "string" + }, + { + "name": "consumerGroupBody", + "in": "body", + "description": "The consumer group to add.", + "required": true, + "schema": { + "$ref": "#/definitions/EventHubConsumerGroupBodyDescription" + } + } + ], + "responses": { + "200": { + "description": "This is a synchronous operation.", + "schema": { + "$ref": "#/definitions/EventHubConsumerGroupInfo" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + }, + "delete": { + "tags": [ + "DELETE" + ], + "summary": "Delete a consumer group from an Event Hub-compatible endpoint in an IoT hub", + "description": "Delete a consumer group from an Event Hub-compatible endpoint in an IoT hub.", + "operationId": "IotHubResource_DeleteEventHubConsumerGroup", + "x-ms-examples": { + "IotHubResource_DeleteEventHubConsumerGroup": { + "$ref": "./examples/iothub_deleteconsumergroup.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + }, + { + "name": "eventHubEndpointName", + "in": "path", + "description": "The name of the Event Hub-compatible endpoint in the IoT hub.", + "required": true, + "type": "string" + }, + { + "name": "name", + "in": "path", + "description": "The name of the consumer group to delete.", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "This is a synchronous operation." + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/jobs": { + "get": { + "tags": [ + "GET" + ], + "summary": "Get a list of all the jobs in an IoT hub. For more information, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-identity-registry", + "description": "Get a list of all the jobs in an IoT hub. For more information, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-identity-registry.", + "operationId": "IotHubResource_ListJobs", + "x-ms-examples": { + "IotHubResource_ListJobs": { + "$ref": "./examples/iothub_listjobs.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + } + ], + "responses": { + "200": { + "description": "This is a synchronous operation. The response contains a JSON-serialized array of all the jobs in the IoT hub.", + "schema": { + "$ref": "#/definitions/JobResponseListResult" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false, + "x-ms-pageable": { + "nextLinkName": "nextLink" + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/jobs/{jobId}": { + "get": { + "tags": [ + "GET" + ], + "summary": "Get the details of a job from an IoT hub. For more information, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-identity-registry", + "description": "Get the details of a job from an IoT hub. For more information, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-identity-registry.", + "operationId": "IotHubResource_GetJob", + "x-ms-examples": { + "IotHubResource_GetJob": { + "$ref": "./examples/iothub_getjob.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + }, + { + "name": "jobId", + "in": "path", + "description": "The job identifier.", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "This is a synchronous operation. The response contains a JSON-serialized description of the job in the IoT hub.", + "schema": { + "$ref": "#/definitions/JobResponse" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/quotaMetrics": { + "get": { + "tags": [ + "GET" + ], + "summary": "Get the quota metrics for an IoT hub", + "description": "Get the quota metrics for an IoT hub.", + "operationId": "IotHubResource_GetQuotaMetrics", + "x-ms-examples": { + "IotHubResource_GetQuotaMetrics": { + "$ref": "./examples/iothub_quotametrics.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + } + ], + "responses": { + "200": { + "description": "This is a synchronous operation. The response contains a JSON-serialized array of the quota metrics for the IoT hub.", + "schema": { + "$ref": "#/definitions/IotHubQuotaMetricInfoListResult" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false, + "x-ms-pageable": { + "nextLinkName": "nextLink" + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{iotHubName}/routingEndpointsHealth": { + "get": { + "tags": [ + "GET" + ], + "operationId": "IotHubResource_GetEndpointHealth", + "summary": "Get the health for routing endpoints", + "description": "Get the health for routing endpoints.", + "x-ms-examples": { + "IotHubResource_GetEndpointHealth": { + "$ref": "./examples/iothub_routingendpointhealth.json" + } + }, + "consumes": [], + "produces": [ + "application/json" + ], + "parameters": [ + { + "$ref": "#/parameters/subscriptionId" + }, + { + "name": "resourceGroupName", + "in": "path", + "required": true, + "type": "string" + }, + { + "name": "iotHubName", + "in": "path", + "required": true, + "type": "string" + }, + { + "$ref": "#/parameters/api-version" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/EndpointHealthDataListResult" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false, + "x-ms-pageable": { + "nextLinkName": "nextLink" + } + } + }, + "/subscriptions/{subscriptionId}/providers/Microsoft.Devices/checkNameAvailability": { + "post": { + "tags": [ + "POST" + ], + "summary": "Check if an IoT hub name is available", + "description": "Check if an IoT hub name is available.", + "operationId": "IotHubResource_CheckNameAvailability", + "x-ms-examples": { + "IotHubResource_CheckNameAvailability": { + "$ref": "./examples/checkNameAvailability.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "name": "operationInputs", + "in": "body", + "description": "Set the name parameter in the OperationInputs structure to the name of the IoT hub to check.", + "required": true, + "schema": { + "$ref": "#/definitions/OperationInputs" + } + } + ], + "responses": { + "200": { + "description": "This is a synchronous operation. The body contains a JSON-serialized response that specifies whether the IoT hub name is available. If the name is not available, the body contains the reason.", + "schema": { + "$ref": "#/definitions/IotHubNameAvailabilityInfo" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + } + }, + "/subscriptions/{subscriptionId}/providers/Microsoft.Devices/usages": { + "get": { + "tags": [ + "GET" + ], + "summary": "Get the number of iot hubs in the subscription", + "description": "Get the number of free and paid iot hubs in the subscription", + "operationId": "ResourceProviderCommon_GetSubscriptionQuota", + "x-ms-examples": { + "ResourceProviderCommon_GetSubscriptionQuota": { + "$ref": "./examples/iothub_usages.json" + } + }, + "consumes": [], + "produces": [ + "application/json" + ], + "parameters": [ + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/api-version" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/UserSubscriptionQuotaListResult" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{iotHubName}/routing/routes/$testall": { + "post": { + "tags": [ + "POST" + ], + "operationId": "IotHubResource_TestAllRoutes", + "summary": "Test all routes", + "description": "Test all routes configured in this Iot Hub", + "x-ms-examples": { + "IotHubResource_TestAllRoutes": { + "$ref": "./examples/iothub_testallroutes.json" + } + }, + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "input", + "description": "Input for testing all routes", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/TestAllRoutesInput" + } + }, + { + "name": "iotHubName", + "description": "IotHub to be tested", + "in": "path", + "required": true, + "type": "string" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "name": "resourceGroupName", + "description": "resource group which Iot Hub belongs to", + "in": "path", + "required": true, + "type": "string" + }, + { + "$ref": "#/parameters/api-version" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/TestAllRoutesResult" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{iotHubName}/routing/routes/$testnew": { + "post": { + "tags": [ + "POST" + ], + "operationId": "IotHubResource_TestRoute", + "summary": "Test the new route", + "description": "Test the new route for this Iot Hub", + "x-ms-examples": { + "IotHubResource_TestRoute": { + "$ref": "./examples/iothub_testnewroute.json" + } + }, + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "parameters": [ + { + "name": "input", + "description": "Route that needs to be tested", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/TestRouteInput" + } + }, + { + "name": "iotHubName", + "description": "IotHub to be tested", + "in": "path", + "required": true, + "type": "string" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "name": "resourceGroupName", + "description": "resource group which Iot Hub belongs to", + "in": "path", + "required": true, + "type": "string" + }, + { + "$ref": "#/parameters/api-version" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/TestRouteResult" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/listkeys": { + "post": { + "tags": [ + "POST" + ], + "summary": "Get the security metadata for an IoT hub. For more information, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-security", + "description": "Get the security metadata for an IoT hub. For more information, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-security.", + "operationId": "IotHubResource_ListKeys", + "x-ms-examples": { + "IotHubResource_ListKeys": { + "$ref": "./examples/iothub_listkeys.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + } + ], + "responses": { + "200": { + "description": "This is a synchronous operation. The body contains a JSON-serialized array of shared access policies, including keys, that you can use to access the IoT hub endpoints.", + "schema": { + "$ref": "#/definitions/SharedAccessSignatureAuthorizationRuleListResult" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false, + "x-ms-pageable": { + "nextLinkName": "nextLink" + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/IotHubKeys/{keyName}/listkeys": { + "post": { + "tags": [ + "POST" + ], + "summary": "Get a shared access policy by name from an IoT hub. For more information, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-security", + "description": "Get a shared access policy by name from an IoT hub. For more information, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-security.", + "operationId": "IotHubResource_GetKeysForKeyName", + "x-ms-examples": { + "IotHubResource_GetKeysForKeyName": { + "$ref": "./examples/iothub_getkey.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + }, + { + "name": "keyName", + "in": "path", + "description": "The name of the shared access policy.", + "required": true, + "type": "string" + } + ], + "responses": { + "200": { + "description": "This is a synchronous operation. The body contains a JSON-serialized shared access policy, including keys, that you can use to access one or more IoT hub endpoints.", + "schema": { + "$ref": "#/definitions/SharedAccessSignatureAuthorizationRule" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/exportDevices": { + "post": { + "tags": [ + "POST" + ], + "summary": "Exports all the device identities in the IoT hub identity registry to an Azure Storage blob container. For more information, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-identity-registry#import-and-export-device-identities", + "description": "Exports all the device identities in the IoT hub identity registry to an Azure Storage blob container. For more information, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-identity-registry#import-and-export-device-identities.", + "operationId": "IotHubResource_ExportDevices", + "x-ms-examples": { + "IotHubResource_ExportDevices": { + "$ref": "./examples/iothub_exportdevices.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + }, + { + "name": "exportDevicesParameters", + "in": "body", + "description": "The parameters that specify the export devices operation.", + "required": true, + "schema": { + "$ref": "#/definitions/ExportDevicesRequest" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/JobResponse" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/importDevices": { + "post": { + "tags": [ + "POST" + ], + "summary": "Import, update, or delete device identities in the IoT hub identity registry from a blob. For more information, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-identity-registry#import-and-export-device-identities", + "description": "Import, update, or delete device identities in the IoT hub identity registry from a blob. For more information, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-identity-registry#import-and-export-device-identities.", + "operationId": "IotHubResource_ImportDevices", + "x-ms-examples": { + "IotHubResource_ImportDevices": { + "$ref": "./examples/iothub_importdevices.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + }, + { + "name": "importDevicesParameters", + "in": "body", + "description": "The parameters that specify the import devices operation.", + "required": true, + "schema": { + "$ref": "#/definitions/ImportDevicesRequest" + } + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/JobResponse" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/certificates": { + "get": { + "tags": [ + "Certificates" + ], + "summary": "Get the certificate list.", + "description": "Returns the list of certificates.", + "operationId": "Certificates_ListByIotHub", + "x-ms-examples": { + "Certificates_ListByIotHub": { + "$ref": "./examples/iothub_listcertificates.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + } + ], + "responses": { + "200": { + "description": "The body contains all the certificate list.", + "schema": { + "$ref": "#/definitions/CertificateListDescription" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/certificates/{certificateName}": { + "get": { + "tags": [ + "Certificates" + ], + "summary": "Get the certificate.", + "description": "Returns the certificate.", + "operationId": "Certificates_Get", + "x-ms-examples": { + "Certificates_Get": { + "$ref": "./examples/iothub_getcertificate.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + }, + { + "$ref": "#/parameters/certificateName" + } + ], + "responses": { + "200": { + "description": "The body contains the certificate.", + "schema": { + "$ref": "#/definitions/CertificateDescription" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + }, + "put": { + "tags": [ + "Certificates" + ], + "summary": "Upload the certificate to the IoT hub.", + "description": "Adds new or replaces existing certificate.", + "operationId": "Certificates_CreateOrUpdate", + "x-ms-examples": { + "Certificates_CreateOrUpdate": { + "$ref": "./examples/iothub_certificatescreateorupdate.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + }, + { + "$ref": "#/parameters/certificateName" + }, + { + "name": "certificateDescription", + "in": "body", + "description": "The certificate body.", + "required": true, + "schema": { + "$ref": "#/definitions/CertificateDescription" + } + }, + { + "name": "If-Match", + "in": "header", + "required": false, + "type": "string", + "description": "ETag of the Certificate. Do not specify for creating a brand new certificate. Required to update an existing certificate." + } + ], + "responses": { + "201": { + "description": "If certificate didn't exist creation was successful, the operation returns HTTP status code of 201 (OK).", + "schema": { + "$ref": "#/definitions/CertificateDescription" + } + }, + "200": { + "description": "If certificate already exist and update was successful, the operation returns HTTP status code of 201 (OK).", + "schema": { + "$ref": "#/definitions/CertificateDescription" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + }, + "delete": { + "tags": [ + "Certificates" + ], + "summary": "Delete an X509 certificate.", + "description": "Deletes an existing X509 certificate or does nothing if it does not exist.", + "operationId": "Certificates_Delete", + "x-ms-examples": { + "Certificates_Delete": { + "$ref": "./examples/iothub_certificatesdelete.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + }, + { + "$ref": "#/parameters/certificateName" + }, + { + "name": "If-Match", + "in": "header", + "required": true, + "type": "string", + "description": "ETag of the Certificate." + } + ], + "responses": { + "200": { + "description": "Certificate has been deleted." + }, + "204": { + "description": "Certificate does not exist." + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/certificates/{certificateName}/generateVerificationCode": { + "post": { + "tags": [ + "Certificates" + ], + "summary": "Generate verification code for proof of possession flow.", + "description": "Generates verification code for proof of possession flow. The verification code will be used to generate a leaf certificate.", + "operationId": "Certificates_GenerateVerificationCode", + "x-ms-examples": { + "Certificates_GenerateVerificationCode": { + "$ref": "./examples/iothub_generateverificationcode.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + }, + { + "$ref": "#/parameters/certificateName" + }, + { + "name": "If-Match", + "in": "header", + "required": true, + "type": "string", + "description": "ETag of the Certificate." + } + ], + "responses": { + "200": { + "description": "The body contains the certificate.", + "schema": { + "$ref": "#/definitions/CertificateWithNonceDescription" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/certificates/{certificateName}/verify": { + "post": { + "tags": [ + "Certificates" + ], + "summary": "Verify certificate's private key possession.", + "description": "Verifies the certificate's private key possession by providing the leaf cert issued by the verifying pre uploaded certificate.", + "operationId": "Certificates_Verify", + "x-ms-examples": { + "Certificates_Verify": { + "$ref": "./examples/iothub_certverify.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + }, + { + "$ref": "#/parameters/certificateName" + }, + { + "name": "certificateVerificationBody", + "in": "body", + "description": "The name of the certificate", + "required": true, + "schema": { + "$ref": "#/definitions/CertificateVerificationDescription" + } + }, + { + "name": "If-Match", + "in": "header", + "required": true, + "type": "string", + "description": "ETag of the Certificate." + } + ], + "responses": { + "200": { + "description": "The body contains the certificate.", + "schema": { + "$ref": "#/definitions/CertificateDescription" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{iotHubName}/failover": { + "post": { + "tags": [ + "POST" + ], + "operationId": "IotHub_ManualFailover", + "summary": "Manually initiate a failover for the IoT Hub to its secondary region", + "description": "Manually initiate a failover for the IoT Hub to its secondary region. To learn more, see https://aka.ms/manualfailover", + "x-ms-examples": { + "IotHub_ManualFailover": { + "$ref": "./examples/IotHub_ManualFailover.json" + } + }, + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "x-ms-long-running-operation": true, + "parameters": [ + { + "name": "iotHubName", + "description": "Name of the IoT hub to failover", + "in": "path", + "required": true, + "type": "string" + }, + { + "name": "failoverInput", + "description": "Region to failover to. Must be the Azure paired region. Get the value from the secondary location in the locations property. To learn more, see https://aka.ms/manualfailover/region", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/FailoverInput" + } + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "name": "resourceGroupName", + "description": "Name of the resource group containing the IoT hub resource", + "in": "path", + "required": true, + "type": "string" + }, + { + "$ref": "#/parameters/api-version" + } + ], + "responses": { + "200": { + "description": "Long running manual failover operation for the IoT hub completed" + }, + "202": { + "description": "Manual failover initiated" + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/iotHubs/{resourceName}/privateLinkResources": { + "get": { + "tags": [ + "GET" + ], + "summary": "List private link resources", + "description": "List private link resources for the given IotHub", + "operationId": "PrivateLinkResources_List", + "x-ms-examples": { + "PrivateLinkResources_List": { + "$ref": "./examples/iothub_listprivatelinkresources.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + } + ], + "responses": { + "200": { + "description": "The body contains the list of private link resources", + "schema": { + "$ref": "#/definitions/PrivateLinkResources" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/iotHubs/{resourceName}/privateLinkResources/{groupId}": { + "get": { + "tags": [ + "GET" + ], + "summary": "Get the specified private link resource", + "description": "Get the specified private link resource for the given IotHub", + "operationId": "PrivateLinkResources_Get", + "x-ms-examples": { + "PrivateLinkResources_List": { + "$ref": "./examples/iothub_getprivatelinkresources.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + }, + { + "$ref": "#/parameters/groupId" + } + ], + "responses": { + "200": { + "description": "The body contains the specified of private link resource", + "schema": { + "$ref": "#/definitions/GroupIdInformation" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/iotHubs/{resourceName}/privateEndpointConnections": { + "get": { + "tags": [ + "GET" + ], + "summary": "List private endpoint connections", + "description": "List private endpoint connection properties", + "operationId": "PrivateEndpointConnections_List", + "x-ms-examples": { + "PrivateEndpointConnections_List": { + "$ref": "./examples/iothub_listprivateendpointconnections.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + } + ], + "responses": { + "200": { + "description": "The body contains the list of private endpoint connection properties", + "schema": { + "$ref": "#/definitions/PrivateEndpointConnectionsList" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/iotHubs/{resourceName}/privateEndpointConnections/{privateEndpointConnectionName}": { + "get": { + "tags": [ + "GET" + ], + "summary": "Get private endpoint connection", + "description": "Get private endpoint connection properties", + "operationId": "PrivateEndpointConnections_Get", + "x-ms-examples": { + "PrivateEndpointConnection_Get": { + "$ref": "./examples/iothub_getprivateendpointconnection.json" + } + }, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + }, + { + "$ref": "#/parameters/privateEndpointConnectionName" + } + ], + "responses": { + "200": { + "description": "The body contains the private endpoint connection properties", + "schema": { + "$ref": "#/definitions/PrivateEndpointConnection" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + }, + "put": { + "tags": [ + "PUT" + ], + "summary": "Update private endpoint connection", + "description": "Update the status of a private endpoint connection with the specified name", + "operationId": "PrivateEndpointConnections_Update", + "x-ms-examples": { + "PrivateEndpointConnection_Update": { + "$ref": "./examples/iothub_updateprivateendpointconnection.json" + } + }, + "x-ms-long-running-operation": true, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + }, + { + "$ref": "#/parameters/privateEndpointConnectionName" + }, + { + "name": "privateEndpointConnection", + "in": "body", + "description": "The private endpoint connection with updated properties", + "required": true, + "schema": { + "$ref": "#/definitions/PrivateEndpointConnection" + } + } + ], + "responses": { + "201": { + "description": "This is a long running operation. The operation returns a 201 if the validation is complete. The response includes an Azure-AsyncOperation header that contains a status URL. Clients are expected to poll the status URL for the status of the operation. If successful, the operation returns HTTP status code of 201 (OK).", + "schema": { + "$ref": "#/definitions/PrivateEndpointConnection" + } + }, + "200": { + "description": "This is returned as a response to the status polling request for the update operation.", + "schema": { + "$ref": "#/definitions/PrivateEndpointConnection" + } + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + }, + "delete": { + "tags": [ + "DELETE" + ], + "summary": "Delete private endpoint connection", + "description": "Delete private endpoint connection with the specified name", + "operationId": "PrivateEndpointConnections_Delete", + "x-ms-examples": { + "PrivateEndpointConnection_Delete": { + "$ref": "./examples/iothub_deleteprivateendpointconnection.json" + } + }, + "x-ms-long-running-operation": true, + "parameters": [ + { + "$ref": "#/parameters/api-version" + }, + { + "$ref": "#/parameters/subscriptionId" + }, + { + "$ref": "#/parameters/resourceGroupName" + }, + { + "$ref": "#/parameters/resourceName" + }, + { + "$ref": "#/parameters/privateEndpointConnectionName" + } + ], + "responses": { + "202": { + "description": "This is a long running operation. The operation returns a 202 if the validation is complete. The response includes an Azure-AsyncOperation header that contains a status URL. Clients are expected to poll the status URL for the status of the operation.", + "schema": { + "$ref": "#/definitions/PrivateEndpointConnection" + } + }, + "200": { + "description": "This is returned as a response to the status polling request for the delete operation.", + "schema": { + "$ref": "#/definitions/PrivateEndpointConnection" + } + }, + "204": { + "description": "PrivateEndpoint does not exist." + }, + "default": { + "description": "DefaultErrorResponse", + "schema": { + "$ref": "#/definitions/ErrorDetails" + } + } + }, + "deprecated": false + } + } + }, + "definitions": { + "CertificateVerificationDescription": { + "description": "The JSON-serialized leaf certificate", + "type": "object", + "properties": { + "certificate": { + "description": "base-64 representation of X509 certificate .cer file or just .pem file content.", + "type": "string" + } + } + }, + "CertificateListDescription": { + "description": "The JSON-serialized array of Certificate objects.", + "type": "object", + "properties": { + "value": { + "description": "The array of Certificate objects.", + "type": "array", + "items": { + "$ref": "#/definitions/CertificateDescription" + } + } + } + }, + "CertificateBodyDescription": { + "description": "The JSON-serialized X509 Certificate.", + "type": "object", + "properties": { + "certificate": { + "description": "base-64 representation of the X509 leaf certificate .cer file or just .pem file content.", + "type": "string" + }, + "isVerified": { + "description": "True indicates that the certificate will be created in verified state and proof of possession will not be required.", + "type": "boolean" + } + } + }, + "CertificateDescription": { + "description": "The X509 Certificate.", + "type": "object", + "properties": { + "properties": { + "$ref": "#/definitions/CertificateProperties" + }, + "id": { + "readOnly": true, + "type": "string", + "description": "The resource identifier." + }, + "name": { + "description": "The name of the certificate.", + "type": "string", + "readOnly": true + }, + "etag": { + "description": "The entity tag.", + "type": "string", + "readOnly": true + }, + "type": { + "readOnly": true, + "type": "string", + "description": "The resource type." + } + }, + "x-ms-azure-resource": true + }, + "CertificateWithNonceDescription": { + "description": "The X509 Certificate.", + "type": "object", + "properties": { + "properties": { + "$ref": "#/definitions/CertificatePropertiesWithNonce" + }, + "id": { + "readOnly": true, + "type": "string", + "description": "The resource identifier." + }, + "name": { + "description": "The name of the certificate.", + "type": "string", + "readOnly": true + }, + "etag": { + "description": "The entity tag.", + "type": "string", + "readOnly": true + }, + "type": { + "readOnly": true, + "type": "string", + "description": "The resource type." + } + }, + "x-ms-azure-resource": true + }, + "SharedAccessSignatureAuthorizationRule": { + "description": "The properties of an IoT hub shared access policy.", + "type": "object", + "properties": { + "keyName": { + "description": "The name of the shared access policy.", + "type": "string" + }, + "primaryKey": { + "description": "The primary key.", + "type": "string" + }, + "secondaryKey": { + "description": "The secondary key.", + "type": "string" + }, + "rights": { + "description": "The permissions assigned to the shared access policy.", + "enum": [ + "RegistryRead", + "RegistryWrite", + "ServiceConnect", + "DeviceConnect", + "RegistryRead, RegistryWrite", + "RegistryRead, ServiceConnect", + "RegistryRead, DeviceConnect", + "RegistryWrite, ServiceConnect", + "RegistryWrite, DeviceConnect", + "ServiceConnect, DeviceConnect", + "RegistryRead, RegistryWrite, ServiceConnect", + "RegistryRead, RegistryWrite, DeviceConnect", + "RegistryRead, ServiceConnect, DeviceConnect", + "RegistryWrite, ServiceConnect, DeviceConnect", + "RegistryRead, RegistryWrite, ServiceConnect, DeviceConnect" + ], + "type": "string", + "x-ms-enum": { + "name": "AccessRights", + "modelAsString": false + } + } + }, + "required": [ + "keyName", + "rights" + ] + }, + "CertificateProperties": { + "description": "The description of an X509 CA Certificate.", + "type": "object", + "properties": { + "subject": { + "description": "The certificate's subject name.", + "type": "string", + "readOnly": true + }, + "expiry": { + "description": "The certificate's expiration date and time.", + "type": "string", + "format": "date-time-rfc1123", + "readOnly": true + }, + "thumbprint": { + "description": "The certificate's thumbprint.", + "type": "string", + "readOnly": true + }, + "isVerified": { + "description": "Determines whether certificate has been verified.", + "type": "boolean" + }, + "created": { + "description": "The certificate's create date and time.", + "type": "string", + "format": "date-time-rfc1123", + "readOnly": true + }, + "updated": { + "description": "The certificate's last update date and time.", + "type": "string", + "format": "date-time-rfc1123", + "readOnly": true + }, + "certificate": { + "description": "The certificate content", + "type": "string" + } + } + }, + "CertificatePropertiesWithNonce": { + "description": "The description of an X509 CA Certificate including the challenge nonce issued for the Proof-Of-Possession flow.", + "type": "object", + "properties": { + "subject": { + "description": "The certificate's subject name.", + "type": "string", + "readOnly": true + }, + "expiry": { + "description": "The certificate's expiration date and time.", + "type": "string", + "format": "date-time-rfc1123", + "readOnly": true + }, + "thumbprint": { + "description": "The certificate's thumbprint.", + "type": "string", + "readOnly": true + }, + "isVerified": { + "description": "Determines whether certificate has been verified.", + "type": "boolean", + "readOnly": true + }, + "created": { + "description": "The certificate's create date and time.", + "type": "string", + "format": "date-time-rfc1123", + "readOnly": true + }, + "updated": { + "description": "The certificate's last update date and time.", + "type": "string", + "format": "date-time-rfc1123", + "readOnly": true + }, + "verificationCode": { + "description": "The certificate's verification code that will be used for proof of possession.", + "type": "string", + "readOnly": true + }, + "certificate": { + "description": "The certificate content", + "type": "string", + "readOnly": true + } + } + }, + "IotHubProperties": { + "description": "The properties of an IoT hub.", + "type": "object", + "properties": { + "authorizationPolicies": { + "description": "The shared access policies you can use to secure a connection to the IoT hub.", + "type": "array", + "items": { + "$ref": "#/definitions/SharedAccessSignatureAuthorizationRule" + } + }, + "disableLocalAuth": { + "description": "If true, SAS tokens with Iot hub scoped SAS keys cannot be used for authentication.", + "type": "boolean" + }, + "disableDeviceSAS": { + "description": "If true, all device(including Edge devices but excluding modules) scoped SAS keys cannot be used for authentication.", + "type": "boolean" + }, + "disableModuleSAS": { + "description": "If true, all module scoped SAS keys cannot be used for authentication.", + "type": "boolean" + }, + "restrictOutboundNetworkAccess": { + "description": "If true, egress from IotHub will be restricted to only the allowed FQDNs that are configured via allowedFqdnList.", + "type": "boolean" + }, + "allowedFqdnList": { + "description": "List of allowed FQDNs(Fully Qualified Domain Name) for egress from Iot Hub.", + "type": "array", + "items": { + "description": "FQDN to be allowed for egress. Example: my-eventhub.servicebus.windows.net", + "type": "string" + } + }, + "publicNetworkAccess": { + "type": "string", + "description": "Whether requests from Public Network are allowed", + "enum": [ + "Enabled", + "Disabled" + ], + "x-ms-enum": { + "modelAsString": true, + "name": "PublicNetworkAccess" + } + }, + "ipFilterRules": { + "description": "The IP filter rules.", + "type": "array", + "items": { + "$ref": "#/definitions/IpFilterRule" + } + }, + "networkRuleSets": { + "$ref": "#/definitions/NetworkRuleSetProperties" + }, + "minTlsVersion": { + "type": "string", + "description": "Specifies the minimum TLS version to support for this hub. Can be set to \"1.2\" to have clients that use a TLS version below 1.2 to be rejected." + }, + "privateEndpointConnections": { + "description": "Private endpoint connections created on this IotHub", + "type": "array", + "items": { + "$ref": "#/definitions/PrivateEndpointConnection" + } + }, + "provisioningState": { + "description": "The provisioning state.", + "type": "string", + "readOnly": true + }, + "state": { + "description": "The hub state.", + "type": "string", + "readOnly": true + }, + "hostName": { + "description": "The name of the host.", + "type": "string", + "readOnly": true + }, + "eventHubEndpoints": { + "description": "The Event Hub-compatible endpoint properties. The only possible keys to this dictionary is events. This key has to be present in the dictionary while making create or update calls for the IoT hub.", + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/EventHubProperties" + } + }, + "routing": { + "$ref": "#/definitions/RoutingProperties" + }, + "storageEndpoints": { + "description": "The list of Azure Storage endpoints where you can upload files. Currently you can configure only one Azure Storage account and that MUST have its key as $default. Specifying more than one storage account causes an error to be thrown. Not specifying a value for this property when the enableFileUploadNotifications property is set to True, causes an error to be thrown.", + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/StorageEndpointProperties" + } + }, + "messagingEndpoints": { + "description": "The messaging endpoint properties for the file upload notification queue.", + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/MessagingEndpointProperties" + } + }, + "enableFileUploadNotifications": { + "description": "If True, file upload notifications are enabled.", + "type": "boolean" + }, + "cloudToDevice": { + "$ref": "#/definitions/CloudToDeviceProperties" + }, + "comments": { + "description": "IoT hub comments.", + "type": "string" + }, + "deviceStreams": { + "description": "The device streams properties of iothub.", + "type": "object", + "properties": { + "streamingEndpoints": { + "description": "List of Device Streams Endpoints.", + "type": "array", + "items": { + "type": "string" + } + } + } + }, + "features": { + "description": "The capabilities and features enabled for the IoT hub.", + "enum": [ + "None", + "DeviceManagement" + ], + "type": "string", + "x-ms-enum": { + "name": "Capabilities", + "modelAsString": true + } + }, + "encryption": { + "description": "The encryption properties for the IoT hub.", + "$ref": "#/definitions/EncryptionPropertiesDescription" + }, + "locations": { + "description": "Primary and secondary location for iot hub", + "readOnly": true, + "type": "array", + "items": { + "$ref": "#/definitions/IotHubLocationDescription" + } + }, + "enableDataResidency": { + "description": "This property when set to true, will enable data residency, thus, disabling disaster recovery.", + "type": "boolean" + } + } + }, + "IotHubSkuInfo": { + "description": "Information about the SKU of the IoT hub.", + "type": "object", + "properties": { + "name": { + "description": "The name of the SKU.", + "enum": [ + "F1", + "S1", + "S2", + "S3", + "B1", + "B2", + "B3" + ], + "type": "string", + "x-ms-enum": { + "name": "IotHubSku", + "modelAsString": true + } + }, + "tier": { + "description": "The billing tier for the IoT hub.", + "enum": [ + "Free", + "Standard", + "Basic" + ], + "type": "string", + "readOnly": true, + "x-ms-enum": { + "name": "IotHubSkuTier", + "modelAsString": false + } + }, + "capacity": { + "format": "int64", + "description": "The number of provisioned IoT Hub units. See: https://docs.microsoft.com/azure/azure-subscription-service-limits#iot-hub-limits.", + "type": "integer" + } + }, + "required": [ + "name" + ] + }, + "EventHubProperties": { + "description": "The properties of the provisioned Event Hub-compatible endpoint used by the IoT hub.", + "type": "object", + "properties": { + "retentionTimeInDays": { + "format": "int64", + "description": "The retention time for device-to-cloud messages in days. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging#device-to-cloud-messages", + "type": "integer" + }, + "partitionCount": { + "format": "int32", + "description": "The number of partitions for receiving device-to-cloud messages in the Event Hub-compatible endpoint. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging#device-to-cloud-messages.", + "type": "integer" + }, + "partitionIds": { + "description": "The partition ids in the Event Hub-compatible endpoint.", + "readOnly": true, + "type": "array", + "items": { + "type": "string" + } + }, + "path": { + "description": "The Event Hub-compatible name.", + "type": "string", + "readOnly": true + }, + "endpoint": { + "description": "The Event Hub-compatible endpoint.", + "type": "string", + "readOnly": true + } + } + }, + "StorageEndpointProperties": { + "description": "The properties of the Azure Storage endpoint for file upload.", + "type": "object", + "properties": { + "sasTtlAsIso8601": { + "description": "The period of time for which the SAS URI generated by IoT Hub for file upload is valid. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-file-upload#file-upload-notification-configuration-options.", + "type": "string", + "format": "duration" + }, + "connectionString": { + "description": "The connection string for the Azure Storage account to which files are uploaded.", + "type": "string" + }, + "containerName": { + "description": "The name of the root container where you upload files. The container need not exist but should be creatable using the connectionString specified.", + "type": "string" + }, + "authenticationType": { + "description": "Specifies authentication type being used for connecting to the storage account.", + "enum": [ + "keyBased", + "identityBased" + ], + "type": "string", + "x-ms-enum": { + "name": "AuthenticationType", + "modelAsString": true + } + }, + "identity": { + "description": "Managed identity properties of storage endpoint for file upload.", + "$ref": "#/definitions/ManagedIdentity" + } + }, + "required": [ + "connectionString", + "containerName" + ] + }, + "MessagingEndpointProperties": { + "description": "The properties of the messaging endpoints used by this IoT hub.", + "type": "object", + "properties": { + "lockDurationAsIso8601": { + "description": "The lock duration. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-file-upload.", + "type": "string", + "format": "duration" + }, + "ttlAsIso8601": { + "description": "The period of time for which a message is available to consume before it is expired by the IoT hub. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-file-upload.", + "type": "string", + "format": "duration" + }, + "maxDeliveryCount": { + "description": "The number of times the IoT hub attempts to deliver a message. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-file-upload.", + "format": "int32", + "type": "integer", + "minimum": 1, + "maximum": 100 + } + } + }, + "CloudToDeviceProperties": { + "description": "The IoT hub cloud-to-device messaging properties.", + "type": "object", + "properties": { + "maxDeliveryCount": { + "description": "The max delivery count for cloud-to-device messages in the device queue. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging#cloud-to-device-messages.", + "format": "int32", + "type": "integer", + "minimum": 1, + "maximum": 100 + }, + "defaultTtlAsIso8601": { + "description": "The default time to live for cloud-to-device messages in the device queue. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging#cloud-to-device-messages.", + "type": "string", + "format": "duration" + }, + "feedback": { + "$ref": "#/definitions/FeedbackProperties" + } + } + }, + "IpFilterRule": { + "description": "The IP filter rules for the IoT hub.", + "type": "object", + "properties": { + "filterName": { + "description": "The name of the IP filter rule.", + "type": "string" + }, + "action": { + "description": "The desired action for requests captured by this rule.", + "enum": [ + "Accept", + "Reject" + ], + "type": "string", + "x-ms-enum": { + "name": "IpFilterActionType", + "modelAsString": false + } + }, + "ipMask": { + "description": "A string that contains the IP address range in CIDR notation for the rule.", + "type": "string" + } + }, + "required": [ + "filterName", + "action", + "ipMask" + ] + }, + "NetworkRuleSetProperties": { + "description": "Network Rule Set Properties of IotHub", + "type": "object", + "properties": { + "defaultAction": { + "type": "string", + "description": "Default Action for Network Rule Set", + "enum": [ + "Deny", + "Allow" + ], + "x-ms-enum": { + "name": "DefaultAction", + "modelAsString": true + }, + "default": "Deny" + }, + "applyToBuiltInEventHubEndpoint": { + "type": "boolean", + "description": "If True, then Network Rule Set is also applied to BuiltIn EventHub EndPoint of IotHub" + }, + "ipRules": { + "type": "array", + "items": { + "$ref": "#/definitions/NetworkRuleSetIpRule" + }, + "description": "List of IP Rules" + } + }, + "required": [ + "applyToBuiltInEventHubEndpoint", + "ipRules" + ] + }, + "NetworkRuleSetIpRule": { + "description": "IP Rule to be applied as part of Network Rule Set", + "type": "object", + "properties": { + "filterName": { + "type": "string", + "description": "Name of the IP filter rule." + }, + "action": { + "type": "string", + "description": "IP Filter Action", + "enum": [ + "Allow" + ], + "x-ms-enum": { + "name": "NetworkRuleIPAction", + "modelAsString": true + }, + "default": "Allow" + }, + "ipMask": { + "type": "string", + "description": "A string that contains the IP address range in CIDR notation for the rule." + } + }, + "required": [ + "filterName", + "ipMask" + ] + }, + "PrivateLinkResources": { + "description": "The available private link resources for an IotHub", + "type": "object", + "properties": { + "value": { + "description": "The list of available private link resources for an IotHub", + "type": "array", + "items": { + "$ref": "#/definitions/GroupIdInformation" + } + } + } + }, + "GroupIdInformation": { + "description": "The group information for creating a private endpoint on an IotHub", + "type": "object", + "properties": { + "id": { + "readOnly": true, + "type": "string", + "description": "The resource identifier." + }, + "name": { + "readOnly": true, + "type": "string", + "description": "The resource name." + }, + "type": { + "readOnly": true, + "type": "string", + "description": "The resource type." + }, + "properties": { + "$ref": "#/definitions/GroupIdInformationProperties" + } + }, + "required": [ + "properties" + ] + }, + "GroupIdInformationProperties": { + "description": "The properties for a group information object", + "type": "object", + "properties": { + "groupId": { + "type": "string", + "description": "The group id" + }, + "requiredMembers": { + "description": "The required members for a specific group id", + "type": "array", + "items": { + "type": "string" + } + }, + "requiredZoneNames": { + "description": "The required DNS zones for a specific group id", + "type": "array", + "items": { + "type": "string" + } + } + } + }, + "PrivateEndpointConnectionsList": { + "description": "The list of private endpoint connections for an IotHub", + "type": "array", + "items": { + "$ref": "#/definitions/PrivateEndpointConnection" + } + }, + "PrivateEndpointConnection": { + "description": "The private endpoint connection of an IotHub", + "x-ms-azure-resource": true, + "type": "object", + "properties": { + "id": { + "readOnly": true, + "type": "string", + "description": "The resource identifier." + }, + "name": { + "readOnly": true, + "type": "string", + "description": "The resource name." + }, + "type": { + "readOnly": true, + "type": "string", + "description": "The resource type." + }, + "properties": { + "$ref": "#/definitions/PrivateEndpointConnectionProperties" + } + }, + "required": [ + "properties" + ] + }, + "PrivateEndpointConnectionProperties": { + "description": "The properties of a private endpoint connection", + "type": "object", + "properties": { + "privateEndpoint": { + "$ref": "#/definitions/PrivateEndpoint" + }, + "privateLinkServiceConnectionState": { + "$ref": "#/definitions/PrivateLinkServiceConnectionState" + } + }, + "required": [ + "privateLinkServiceConnectionState" + ] + }, + "PrivateEndpoint": { + "description": "The private endpoint property of a private endpoint connection", + "type": "object", + "properties": { + "id": { + "readOnly": true, + "type": "string", + "description": "The resource identifier." + } + } + }, + "PrivateLinkServiceConnectionState": { + "description": "The current state of a private endpoint connection", + "type": "object", + "properties": { + "status": { + "description": "The status of a private endpoint connection", + "enum": [ + "Pending", + "Approved", + "Rejected", + "Disconnected" + ], + "type": "string", + "x-ms-enum": { + "name": "PrivateLinkServiceConnectionStatus", + "modelAsString": true + } + }, + "description": { + "type": "string", + "description": "The description for the current state of a private endpoint connection" + }, + "actionsRequired": { + "type": "string", + "description": "Actions required for a private endpoint connection" + } + }, + "required": [ + "status", + "description" + ] + }, + "FeedbackProperties": { + "description": "The properties of the feedback queue for cloud-to-device messages.", + "type": "object", + "properties": { + "lockDurationAsIso8601": { + "description": "The lock duration for the feedback queue. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging#cloud-to-device-messages.", + "type": "string", + "format": "duration" + }, + "ttlAsIso8601": { + "description": "The period of time for which a message is available to consume before it is expired by the IoT hub. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging#cloud-to-device-messages.", + "type": "string", + "format": "duration" + }, + "maxDeliveryCount": { + "description": "The number of times the IoT hub attempts to deliver a message on the feedback queue. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging#cloud-to-device-messages.", + "format": "int32", + "type": "integer", + "minimum": 1, + "maximum": 100 + } + } + }, + "RoutingProperties": { + "description": "The routing related properties of the IoT hub. See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging", + "type": "object", + "properties": { + "endpoints": { + "$ref": "#/definitions/RoutingEndpoints" + }, + "routes": { + "description": "The list of user-provided routing rules that the IoT hub uses to route messages to built-in and custom endpoints. A maximum of 100 routing rules are allowed for paid hubs and a maximum of 5 routing rules are allowed for free hubs.", + "type": "array", + "items": { + "$ref": "#/definitions/RouteProperties" + } + }, + "fallbackRoute": { + "description": "The properties of the route that is used as a fall-back route when none of the conditions specified in the 'routes' section are met. This is an optional parameter. When this property is not set, the messages which do not meet any of the conditions specified in the 'routes' section get routed to the built-in eventhub endpoint.", + "$ref": "#/definitions/FallbackRouteProperties" + }, + "enrichments": { + "description": "The list of user-provided enrichments that the IoT hub applies to messages to be delivered to built-in and custom endpoints. See: https://aka.ms/telemetryoneventgrid", + "type": "array", + "items": { + "$ref": "#/definitions/EnrichmentProperties" + } + } + } + }, + "RoutingEndpoints": { + "description": "The properties related to the custom endpoints to which your IoT hub routes messages based on the routing rules. A maximum of 10 custom endpoints are allowed across all endpoint types for paid hubs and only 1 custom endpoint is allowed across all endpoint types for free hubs.", + "type": "object", + "properties": { + "serviceBusQueues": { + "description": "The list of Service Bus queue endpoints that IoT hub routes the messages to, based on the routing rules.", + "type": "array", + "items": { + "$ref": "#/definitions/RoutingServiceBusQueueEndpointProperties" + } + }, + "serviceBusTopics": { + "description": "The list of Service Bus topic endpoints that the IoT hub routes the messages to, based on the routing rules.", + "type": "array", + "items": { + "$ref": "#/definitions/RoutingServiceBusTopicEndpointProperties" + } + }, + "eventHubs": { + "description": "The list of Event Hubs endpoints that IoT hub routes messages to, based on the routing rules. This list does not include the built-in Event Hubs endpoint.", + "type": "array", + "items": { + "$ref": "#/definitions/RoutingEventHubProperties" + } + }, + "storageContainers": { + "description": "The list of storage container endpoints that IoT hub routes messages to, based on the routing rules.", + "type": "array", + "items": { + "$ref": "#/definitions/RoutingStorageContainerProperties" + } + } + } + }, + "RoutingServiceBusQueueEndpointProperties": { + "description": "The properties related to service bus queue endpoint types.", + "type": "object", + "properties": { + "id": { + "description": "Id of the service bus queue endpoint", + "type": "string" + }, + "connectionString": { + "description": "The connection string of the service bus queue endpoint.", + "type": "string" + }, + "endpointUri": { + "description": "The url of the service bus queue endpoint. It must include the protocol sb://", + "type": "string" + }, + "entityPath": { + "description": "Queue name on the service bus namespace", + "type": "string" + }, + "authenticationType": { + "description": "Method used to authenticate against the service bus queue endpoint", + "enum": [ + "keyBased", + "identityBased" + ], + "type": "string", + "x-ms-enum": { + "name": "authenticationType", + "modelAsString": true + } + }, + "identity": { + "description": "Managed identity properties of routing service bus queue endpoint.", + "$ref": "#/definitions/ManagedIdentity" + }, + "name": { + "description": "The name that identifies this endpoint. The name can only include alphanumeric characters, periods, underscores, hyphens and has a maximum length of 64 characters. The following names are reserved: events, fileNotifications, $default. Endpoint names must be unique across endpoint types. The name need not be the same as the actual queue name.", + "type": "string", + "pattern": "^[A-Za-z0-9-._]{1,64}$" + }, + "subscriptionId": { + "description": "The subscription identifier of the service bus queue endpoint.", + "type": "string" + }, + "resourceGroup": { + "description": "The name of the resource group of the service bus queue endpoint.", + "type": "string" + } + }, + "required": [ + "name" + ] + }, + "RoutingServiceBusTopicEndpointProperties": { + "description": "The properties related to service bus topic endpoint types.", + "type": "object", + "properties": { + "id": { + "description": "Id of the service bus topic endpoint", + "type": "string" + }, + "connectionString": { + "description": "The connection string of the service bus topic endpoint.", + "type": "string" + }, + "endpointUri": { + "description": "The url of the service bus topic endpoint. It must include the protocol sb://", + "type": "string" + }, + "entityPath": { + "description": "Queue name on the service bus topic", + "type": "string" + }, + "authenticationType": { + "description": "Method used to authenticate against the service bus topic endpoint", + "enum": [ + "keyBased", + "identityBased" + ], + "type": "string", + "x-ms-enum": { + "name": "authenticationType", + "modelAsString": true + } + }, + "identity": { + "description": "Managed identity properties of routing service bus topic endpoint.", + "$ref": "#/definitions/ManagedIdentity" + }, + "name": { + "description": "The name that identifies this endpoint. The name can only include alphanumeric characters, periods, underscores, hyphens and has a maximum length of 64 characters. The following names are reserved: events, fileNotifications, $default. Endpoint names must be unique across endpoint types. The name need not be the same as the actual topic name.", + "type": "string", + "pattern": "^[A-Za-z0-9-._]{1,64}$" + }, + "subscriptionId": { + "description": "The subscription identifier of the service bus topic endpoint.", + "type": "string" + }, + "resourceGroup": { + "description": "The name of the resource group of the service bus topic endpoint.", + "type": "string" + } + }, + "required": [ + "name" + ] + }, + "RoutingEventHubProperties": { + "description": "The properties related to an event hub endpoint.", + "type": "object", + "properties": { + "id": { + "description": "Id of the event hub endpoint", + "type": "string" + }, + "connectionString": { + "description": "The connection string of the event hub endpoint. ", + "type": "string" + }, + "endpointUri": { + "description": "The url of the event hub endpoint. It must include the protocol sb://", + "type": "string" + }, + "entityPath": { + "description": "Event hub name on the event hub namespace", + "type": "string" + }, + "authenticationType": { + "description": "Method used to authenticate against the event hub endpoint", + "enum": [ + "keyBased", + "identityBased" + ], + "type": "string", + "x-ms-enum": { + "name": "authenticationType", + "modelAsString": true + } + }, + "identity": { + "description": "Managed identity properties of routing event hub endpoint.", + "$ref": "#/definitions/ManagedIdentity" + }, + "name": { + "description": "The name that identifies this endpoint. The name can only include alphanumeric characters, periods, underscores, hyphens and has a maximum length of 64 characters. The following names are reserved: events, fileNotifications, $default. Endpoint names must be unique across endpoint types.", + "type": "string", + "pattern": "^[A-Za-z0-9-._]{1,64}$" + }, + "subscriptionId": { + "description": "The subscription identifier of the event hub endpoint.", + "type": "string" + }, + "resourceGroup": { + "description": "The name of the resource group of the event hub endpoint.", + "type": "string" + } + }, + "required": [ + "name" + ] + }, + "RoutingStorageContainerProperties": { + "description": "The properties related to a storage container endpoint.", + "type": "object", + "properties": { + "id": { + "description": "Id of the storage container endpoint", + "type": "string" + }, + "connectionString": { + "description": "The connection string of the storage account.", + "type": "string" + }, + "endpointUri": { + "description": "The url of the storage endpoint. It must include the protocol https://", + "type": "string" + }, + "authenticationType": { + "description": "Method used to authenticate against the storage endpoint", + "enum": [ + "keyBased", + "identityBased" + ], + "type": "string", + "x-ms-enum": { + "name": "authenticationType", + "modelAsString": true + } + }, + "identity": { + "description": "Managed identity properties of routing storage endpoint.", + "$ref": "#/definitions/ManagedIdentity" + }, + "name": { + "description": "The name that identifies this endpoint. The name can only include alphanumeric characters, periods, underscores, hyphens and has a maximum length of 64 characters. The following names are reserved: events, fileNotifications, $default. Endpoint names must be unique across endpoint types.", + "type": "string", + "pattern": "^[A-Za-z0-9-._]{1,64}$" + }, + "subscriptionId": { + "description": "The subscription identifier of the storage account.", + "type": "string" + }, + "resourceGroup": { + "description": "The name of the resource group of the storage account.", + "type": "string" + }, + "containerName": { + "description": "The name of storage container in the storage account.", + "type": "string" + }, + "fileNameFormat": { + "description": "File name format for the blob. Default format is {iothub}/{partition}/{YYYY}/{MM}/{DD}/{HH}/{mm}. All parameters are mandatory but can be reordered.", + "type": "string" + }, + "batchFrequencyInSeconds": { + "description": "Time interval at which blobs are written to storage. Value should be between 60 and 720 seconds. Default value is 300 seconds.", + "format": "int32", + "type": "integer", + "maximum": 720, + "minimum": 60 + }, + "maxChunkSizeInBytes": { + "description": "Maximum number of bytes for each blob written to storage. Value should be between 10485760(10MB) and 524288000(500MB). Default value is 314572800(300MB).", + "format": "int32", + "type": "integer", + "maximum": 524288000, + "minimum": 10485760 + }, + "encoding": { + "description": "Encoding that is used to serialize messages to blobs. Supported values are 'avro', 'avrodeflate', and 'JSON'. Default value is 'avro'.", + "type": "string", + "enum": [ + "Avro", + "AvroDeflate", + "JSON" + ] + } + }, + "required": [ + "name", + "containerName" + ] + }, + "RouteProperties": { + "description": "The properties of a routing rule that your IoT hub uses to route messages to endpoints.", + "type": "object", + "properties": { + "name": { + "description": "The name of the route. The name can only include alphanumeric characters, periods, underscores, hyphens, has a maximum length of 64 characters, and must be unique.", + "type": "string", + "pattern": "^[A-Za-z0-9-._]{1,64}$" + }, + "source": { + "description": "The source that the routing rule is to be applied to, such as DeviceMessages.", + "enum": [ + "Invalid", + "DeviceMessages", + "TwinChangeEvents", + "DeviceLifecycleEvents", + "DeviceJobLifecycleEvents", + "DigitalTwinChangeEvents", + "DeviceConnectionStateEvents", + "MqttBrokerMessages" + ], + "type": "string", + "x-ms-enum": { + "name": "RoutingSource", + "modelAsString": true + } + }, + "condition": { + "description": "The condition that is evaluated to apply the routing rule. If no condition is provided, it evaluates to true by default. For grammar, see: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-query-language", + "type": "string" + }, + "endpointNames": { + "description": "The list of endpoints to which messages that satisfy the condition are routed. Currently only one endpoint is allowed.", + "minItems": 1, + "maxItems": 1, + "type": "array", + "items": { + "type": "string" + } + }, + "isEnabled": { + "description": "Used to specify whether a route is enabled.", + "type": "boolean" + } + }, + "required": [ + "name", + "endpointNames", + "source", + "isEnabled" + ] + }, + "FallbackRouteProperties": { + "description": "The properties of the fallback route. IoT Hub uses these properties when it routes messages to the fallback endpoint.", + "type": "object", + "properties": { + "name": { + "description": "The name of the route. The name can only include alphanumeric characters, periods, underscores, hyphens, has a maximum length of 64 characters, and must be unique.", + "type": "string" + }, + "source": { + "description": "The source to which the routing rule is to be applied to. For example, DeviceMessages", + "enum": [ + "DeviceMessages" + ], + "type": "string", + "x-ms-enum": { + "name": "RoutingSource", + "modelAsString": true + } + }, + "condition": { + "description": "The condition which is evaluated in order to apply the fallback route. If the condition is not provided it will evaluate to true by default. For grammar, See: https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-query-language", + "type": "string" + }, + "endpointNames": { + "description": "The list of endpoints to which the messages that satisfy the condition are routed to. Currently only 1 endpoint is allowed.", + "minItems": 1, + "maxItems": 1, + "type": "array", + "items": { + "type": "string" + } + }, + "isEnabled": { + "description": "Used to specify whether the fallback route is enabled.", + "type": "boolean" + } + }, + "required": [ + "endpointNames", + "source", + "isEnabled" + ] + }, + "EnrichmentProperties": { + "description": "The properties of an enrichment that your IoT hub applies to messages delivered to endpoints.", + "type": "object", + "properties": { + "key": { + "description": "The key or name for the enrichment property.", + "type": "string" + }, + "value": { + "description": "The value for the enrichment property.", + "type": "string" + }, + "endpointNames": { + "description": "The list of endpoints for which the enrichment is applied to the message.", + "minItems": 1, + "type": "array", + "items": { + "type": "string" + } + } + }, + "required": [ + "key", + "value", + "endpointNames" + ] + }, + "IotHubDescription": { + "description": "The description of the IoT hub.", + "type": "object", + "properties": { + "etag": { + "description": "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.", + "type": "string" + }, + "properties": { + "description": "IotHub properties", + "$ref": "#/definitions/IotHubProperties" + }, + "sku": { + "description": "IotHub SKU info", + "$ref": "#/definitions/IotHubSkuInfo" + }, + "identity": { + "description": "The managed identities for the IotHub.", + "$ref": "#/definitions/ArmIdentity" + }, + "systemData": { + "readOnly": true, + "description": "The system meta data relating to this resource.", + "$ref": "#/definitions/systemData" + } + }, + "allOf": [ + { + "$ref": "#/definitions/Resource" + } + ], + "required": [ + "sku" + ] + }, + "Resource": { + "description": "The common properties of an Azure resource.", + "properties": { + "id": { + "readOnly": true, + "type": "string", + "description": "The resource identifier." + }, + "name": { + "readOnly": true, + "type": "string", + "description": "The resource name.", + "pattern": "^(?![0-9]+$)(?!-)[a-zA-Z0-9-]{2,49}[a-zA-Z0-9]$" + }, + "type": { + "readOnly": true, + "type": "string", + "description": "The resource type." + }, + "location": { + "type": "string", + "description": "The resource location." + }, + "tags": { + "type": "object", + "additionalProperties": { + "type": "string" + }, + "description": "The resource tags." + } + }, + "x-ms-azure-resource": true, + "required": [ + "location" + ] + }, + "SharedAccessSignatureAuthorizationRuleListResult": { + "description": "The list of shared access policies with a next link.", + "type": "object", + "properties": { + "value": { + "description": "The list of shared access policies.", + "type": "array", + "items": { + "$ref": "#/definitions/SharedAccessSignatureAuthorizationRule" + } + }, + "nextLink": { + "description": "The next link.", + "type": "string", + "readOnly": true + } + } + }, + "OperationListResult": { + "description": "Result of the request to list IoT Hub operations. It contains a list of operations and a URL link to get the next set of results.", + "properties": { + "value": { + "description": "List of IoT Hub operations supported by the Microsoft.Devices resource provider.", + "type": "array", + "readOnly": true, + "items": { + "$ref": "#/definitions/Operation" + } + }, + "nextLink": { + "readOnly": true, + "type": "string", + "description": "URL to get the next set of operation list results if there are any." + } + } + }, + "Operation": { + "description": "IoT Hub REST API operation", + "type": "object", + "properties": { + "name": { + "readOnly": true, + "type": "string", + "description": "Operation name: {provider}/{resource}/{read | write | action | delete}" + }, + "display": { + "description": "The object that represents the operation.", + "properties": { + "provider": { + "readOnly": true, + "type": "string", + "description": "Service provider: Microsoft Devices" + }, + "resource": { + "readOnly": true, + "type": "string", + "description": "Resource Type: IotHubs" + }, + "operation": { + "readOnly": true, + "type": "string", + "description": "Name of the operation" + }, + "description": { + "readOnly": true, + "type": "string", + "description": "Description of the operation" + } + } + } + } + }, + "ErrorDetails": { + "description": "Error details.", + "type": "object", + "properties": { + "code": { + "description": "The error code.", + "type": "string", + "readOnly": true + }, + "httpStatusCode": { + "description": "The HTTP status code.", + "type": "string", + "readOnly": true + }, + "message": { + "description": "The error message.", + "type": "string", + "readOnly": true + }, + "details": { + "description": "The error details.", + "type": "string", + "readOnly": true + } + } + }, + "IotHubQuotaMetricInfoListResult": { + "description": "The JSON-serialized array of IotHubQuotaMetricInfo objects with a next link.", + "type": "object", + "properties": { + "value": { + "description": "The array of quota metrics objects.", + "type": "array", + "items": { + "$ref": "#/definitions/IotHubQuotaMetricInfo" + } + }, + "nextLink": { + "description": "The next link.", + "type": "string", + "readOnly": true + } + } + }, + "EndpointHealthDataListResult": { + "description": "The JSON-serialized array of EndpointHealthData objects with a next link.", + "type": "object", + "properties": { + "value": { + "description": "JSON-serialized array of Endpoint health data", + "type": "array", + "items": { + "$ref": "#/definitions/EndpointHealthData" + } + }, + "nextLink": { + "description": "Link to more results", + "type": "string", + "readOnly": true + } + } + }, + "EndpointHealthData": { + "description": "The health data for an endpoint", + "type": "object", + "properties": { + "endpointId": { + "description": "Id of the endpoint", + "type": "string" + }, + "healthStatus": { + "description": "Health statuses have following meanings. The 'healthy' status shows that the endpoint is accepting messages as expected. The 'unhealthy' status shows that the endpoint is not accepting messages as expected and IoT Hub is retrying to send data to this endpoint. The status of an unhealthy endpoint will be updated to healthy when IoT Hub has established an eventually consistent state of health. The 'dead' status shows that the endpoint is not accepting messages, after IoT Hub retried sending messages for the retrial period. See IoT Hub metrics to identify errors and monitor issues with endpoints. The 'unknown' status shows that the IoT Hub has not established a connection with the endpoint. No messages have been delivered to or rejected from this endpoint", + "enum": [ + "unknown", + "healthy", + "degraded", + "unhealthy", + "dead" + ], + "type": "string", + "x-ms-enum": { + "name": "EndpointHealthStatus", + "modelAsString": true + } + }, + "lastKnownError": { + "description": "Last error obtained when a message failed to be delivered to iot hub", + "type": "string" + }, + "lastKnownErrorTime": { + "description": "Time at which the last known error occurred", + "type": "string", + "format": "date-time-rfc1123" + }, + "lastSuccessfulSendAttemptTime": { + "description": "Last time iot hub successfully sent a message to the endpoint", + "type": "string", + "format": "date-time-rfc1123" + }, + "lastSendAttemptTime": { + "description": "Last time iot hub tried to send a message to the endpoint", + "type": "string", + "format": "date-time-rfc1123" + } + } + }, + "RegistryStatistics": { + "description": "Identity registry statistics.", + "type": "object", + "properties": { + "totalDeviceCount": { + "format": "int64", + "description": "The total count of devices in the identity registry.", + "type": "integer", + "readOnly": true + }, + "enabledDeviceCount": { + "format": "int64", + "description": "The count of enabled devices in the identity registry.", + "type": "integer", + "readOnly": true + }, + "disabledDeviceCount": { + "format": "int64", + "description": "The count of disabled devices in the identity registry.", + "type": "integer", + "readOnly": true + } + } + }, + "JobResponseListResult": { + "description": "The JSON-serialized array of JobResponse objects with a next link.", + "type": "object", + "properties": { + "value": { + "description": "The array of JobResponse objects.", + "type": "array", + "items": { + "$ref": "#/definitions/JobResponse" + } + }, + "nextLink": { + "description": "The next link.", + "type": "string", + "readOnly": true + } + } + }, + "IotHubSkuDescription": { + "description": "SKU properties.", + "type": "object", + "properties": { + "resourceType": { + "description": "The type of the resource.", + "type": "string", + "readOnly": true + }, + "sku": { + "description": "The type of the resource.", + "$ref": "#/definitions/IotHubSkuInfo" + }, + "capacity": { + "description": "IotHub capacity", + "$ref": "#/definitions/IotHubCapacity" + } + }, + "required": [ + "sku", + "capacity" + ] + }, + "TagsResource": { + "properties": { + "tags": { + "additionalProperties": { + "type": "string" + }, + "description": "Resource tags" + } + }, + "description": "A container holding only the Tags for a resource, allowing the user to update the tags on an IoT Hub instance." + }, + "IotHubCapacity": { + "description": "IoT Hub capacity information.", + "type": "object", + "properties": { + "minimum": { + "format": "int64", + "description": "The minimum number of units.", + "type": "integer", + "minimum": 1, + "maximum": 1, + "readOnly": true + }, + "maximum": { + "format": "int64", + "description": "The maximum number of units.", + "type": "integer", + "readOnly": true + }, + "default": { + "format": "int64", + "description": "The default number of units.", + "type": "integer", + "readOnly": true + }, + "scaleType": { + "description": "The type of the scaling enabled.", + "enum": [ + "Automatic", + "Manual", + "None" + ], + "readOnly": true, + "type": "string", + "x-ms-enum": { + "name": "IotHubScaleType", + "modelAsString": false + } + } + } + }, + "EventHubConsumerGroupsListResult": { + "description": "The JSON-serialized array of Event Hub-compatible consumer group names with a next link.", + "type": "object", + "properties": { + "value": { + "description": "List of consumer groups objects", + "type": "array", + "items": { + "$ref": "#/definitions/EventHubConsumerGroupInfo" + } + }, + "nextLink": { + "description": "The next link.", + "type": "string", + "readOnly": true + } + } + }, + "EventHubConsumerGroupBodyDescription": { + "description": "The EventHub consumer group.", + "type": "object", + "properties": { + "properties": { + "$ref": "#/definitions/EventHubConsumerGroupName" + } + }, + "required": [ + "properties" + ] + }, + "EventHubConsumerGroupName": { + "description": "The EventHub consumer group name.", + "type": "object", + "properties": { + "name": { + "description": "EventHub consumer group name", + "type": "string" + } + }, + "required": [ + "name" + ] + }, + "EventHubConsumerGroupInfo": { + "description": "The properties of the EventHubConsumerGroupInfo object.", + "x-ms-azure-resource": true, + "type": "object", + "properties": { + "properties": { + "description": "The tags.", + "type": "object", + "additionalProperties": {} + }, + "id": { + "description": "The Event Hub-compatible consumer group identifier.", + "type": "string", + "readOnly": true + }, + "name": { + "description": "The Event Hub-compatible consumer group name.", + "type": "string", + "readOnly": true + }, + "type": { + "description": "the resource type.", + "type": "string", + "readOnly": true + }, + "etag": { + "description": "The etag.", + "type": "string", + "readOnly": true + } + } + }, + "IotHubSkuDescriptionListResult": { + "description": "The JSON-serialized array of IotHubSkuDescription objects with a next link.", + "type": "object", + "properties": { + "value": { + "description": "The array of IotHubSkuDescription.", + "type": "array", + "items": { + "$ref": "#/definitions/IotHubSkuDescription" + } + }, + "nextLink": { + "description": "The next link.", + "type": "string", + "readOnly": true + } + } + }, + "JobResponse": { + "description": "The properties of the Job Response object.", + "type": "object", + "properties": { + "jobId": { + "description": "The job identifier.", + "type": "string", + "readOnly": true + }, + "startTimeUtc": { + "format": "date-time-rfc1123", + "description": "The start time of the job.", + "type": "string", + "readOnly": true + }, + "endTimeUtc": { + "format": "date-time-rfc1123", + "description": "The time the job stopped processing.", + "type": "string", + "readOnly": true + }, + "type": { + "description": "The type of the job.", + "enum": [ + "unknown", + "export", + "import", + "backup", + "readDeviceProperties", + "writeDeviceProperties", + "updateDeviceConfiguration", + "rebootDevice", + "factoryResetDevice", + "firmwareUpdate" + ], + "type": "string", + "readOnly": true, + "x-ms-enum": { + "name": "JobType", + "modelAsString": true + } + }, + "status": { + "description": "The status of the job.", + "enum": [ + "unknown", + "enqueued", + "running", + "completed", + "failed", + "cancelled" + ], + "type": "string", + "readOnly": true, + "x-ms-enum": { + "name": "JobStatus", + "modelAsString": false + } + }, + "failureReason": { + "description": "If status == failed, this string containing the reason for the failure.", + "type": "string", + "readOnly": true + }, + "statusMessage": { + "description": "The status message for the job.", + "type": "string", + "readOnly": true + }, + "parentJobId": { + "description": "The job identifier of the parent job, if any.", + "type": "string", + "readOnly": true + } + } + }, + "IotHubDescriptionListResult": { + "description": "The JSON-serialized array of IotHubDescription objects with a next link.", + "type": "object", + "properties": { + "value": { + "description": "The array of IotHubDescription objects.", + "type": "array", + "items": { + "$ref": "#/definitions/IotHubDescription" + } + }, + "nextLink": { + "description": "The next link.", + "type": "string", + "readOnly": true + } + } + }, + "IotHubQuotaMetricInfo": { + "description": "Quota metrics properties.", + "type": "object", + "properties": { + "name": { + "description": "The name of the quota metric.", + "type": "string", + "readOnly": true + }, + "currentValue": { + "format": "int64", + "description": "The current value for the quota metric.", + "type": "integer", + "readOnly": true + }, + "maxValue": { + "format": "int64", + "description": "The maximum value of the quota metric.", + "type": "integer", + "readOnly": true + } + } + }, + "OperationInputs": { + "description": "Input values.", + "type": "object", + "properties": { + "name": { + "description": "The name of the IoT hub to check.", + "type": "string" + } + }, + "required": [ + "name" + ] + }, + "IotHubNameAvailabilityInfo": { + "description": "The properties indicating whether a given IoT hub name is available.", + "type": "object", + "properties": { + "nameAvailable": { + "description": "The value which indicates whether the provided name is available.", + "type": "boolean", + "readOnly": true + }, + "reason": { + "description": "The reason for unavailability.", + "enum": [ + "Invalid", + "AlreadyExists" + ], + "type": "string", + "readOnly": true, + "x-ms-enum": { + "name": "IotHubNameUnavailabilityReason", + "modelAsString": false + } + }, + "message": { + "description": "The detailed reason message.", + "type": "string" + } + } + }, + "UserSubscriptionQuotaListResult": { + "type": "object", + "description": "Json-serialized array of User subscription quota response", + "properties": { + "value": { + "type": "array", + "items": { + "$ref": "#/definitions/UserSubscriptionQuota" + } + }, + "nextLink": { + "type": "string", + "readOnly": true + } + } + }, + "UserSubscriptionQuota": { + "description": "User subscription quota response", + "type": "object", + "properties": { + "id": { + "description": "IotHub type id", + "type": "string" + }, + "type": { + "description": "Response type", + "type": "string" + }, + "unit": { + "description": "Unit of IotHub type", + "type": "string" + }, + "currentValue": { + "description": "Current number of IotHub type", + "format": "int32", + "type": "integer" + }, + "limit": { + "description": "Numerical limit on IotHub type", + "format": "int32", + "type": "integer" + }, + "name": { + "description": "IotHub type", + "$ref": "#/definitions/Name" + } + } + }, + "Name": { + "description": "Name of Iot Hub type", + "type": "object", + "properties": { + "value": { + "description": "IotHub type", + "type": "string" + }, + "localizedValue": { + "description": "Localized value of name", + "type": "string" + } + } + }, + "TestAllRoutesInput": { + "description": "Input for testing all routes", + "type": "object", + "properties": { + "routingSource": { + "description": "Routing source", + "enum": [ + "Invalid", + "DeviceMessages", + "TwinChangeEvents", + "DeviceLifecycleEvents", + "DeviceJobLifecycleEvents", + "DigitalTwinChangeEvents", + "DeviceConnectionStateEvents", + "MqttBrokerMessages" + ], + "type": "string", + "x-ms-enum": { + "name": "RoutingSource", + "modelAsString": true + } + }, + "message": { + "description": "Routing message", + "$ref": "#/definitions/RoutingMessage" + }, + "twin": { + "description": "Routing Twin Reference", + "$ref": "#/definitions/RoutingTwin" + } + } + }, + "RoutingTwin": { + "description": "Twin reference input parameter. This is an optional parameter", + "type": "object", + "properties": { + "tags": { + "description": "Twin Tags", + "type": "object" + }, + "properties": { + "properties": { + "desired": { + "description": "Twin desired properties", + "type": "object" + }, + "reported": { + "description": "Twin desired properties", + "type": "object" + } + } + } + } + }, + "RoutingMessage": { + "description": "Routing message", + "type": "object", + "properties": { + "body": { + "description": "Body of routing message", + "type": "string" + }, + "appProperties": { + "description": "App properties", + "type": "object", + "additionalProperties": { + "type": "string" + } + }, + "systemProperties": { + "description": "System properties", + "type": "object", + "additionalProperties": { + "type": "string" + } + } + } + }, + "TestAllRoutesResult": { + "description": "Result of testing all routes", + "type": "object", + "properties": { + "routes": { + "description": "JSON-serialized array of matched routes", + "type": "array", + "items": { + "$ref": "#/definitions/MatchedRoute" + } + } + } + }, + "MatchedRoute": { + "description": "Routes that matched", + "type": "object", + "properties": { + "properties": { + "description": "Properties of routes that matched", + "$ref": "#/definitions/RouteProperties" + } + } + }, + "TestRouteInput": { + "required": [ + "route" + ], + "description": "Input for testing route", + "type": "object", + "properties": { + "message": { + "description": "Routing message", + "$ref": "#/definitions/RoutingMessage" + }, + "route": { + "description": "Route properties", + "$ref": "#/definitions/RouteProperties" + }, + "twin": { + "description": "Routing Twin Reference", + "$ref": "#/definitions/RoutingTwin" + } + } + }, + "TestRouteResult": { + "description": "Result of testing one route", + "type": "object", + "properties": { + "result": { + "description": "Result of testing route", + "enum": [ + "undefined", + "false", + "true" + ], + "type": "string", + "x-ms-enum": { + "name": "TestResultStatus", + "modelAsString": true + } + }, + "details": { + "description": "Detailed result of testing route", + "$ref": "#/definitions/TestRouteResultDetails" + } + } + }, + "TestRouteResultDetails": { + "description": "Detailed result of testing a route", + "type": "object", + "properties": { + "compilationErrors": { + "description": "JSON-serialized list of route compilation errors", + "type": "array", + "items": { + "$ref": "#/definitions/RouteCompilationError" + } + } + } + }, + "RouteCompilationError": { + "description": "Compilation error when evaluating route", + "type": "object", + "properties": { + "message": { + "description": "Route error message", + "type": "string" + }, + "severity": { + "description": "Severity of the route error", + "enum": [ + "error", + "warning" + ], + "type": "string", + "x-ms-enum": { + "name": "RouteErrorSeverity", + "modelAsString": true + } + }, + "location": { + "description": "Location where the route error happened", + "$ref": "#/definitions/RouteErrorRange" + } + } + }, + "RouteErrorRange": { + "description": "Range of route errors", + "type": "object", + "properties": { + "start": { + "description": "Start where the route error happened", + "$ref": "#/definitions/RouteErrorPosition" + }, + "end": { + "description": "End where the route error happened", + "$ref": "#/definitions/RouteErrorPosition" + } + } + }, + "RouteErrorPosition": { + "description": "Position where the route error happened", + "type": "object", + "properties": { + "line": { + "description": "Line where the route error happened", + "format": "int32", + "type": "integer" + }, + "column": { + "description": "Column where the route error happened", + "format": "int32", + "type": "integer" + } + } + }, + "ExportDevicesRequest": { + "description": "Use to provide parameters when requesting an export of all devices in the IoT hub.", + "type": "object", + "properties": { + "exportBlobContainerUri": { + "description": "The export blob container URI.", + "type": "string" + }, + "excludeKeys": { + "description": "The value indicating whether keys should be excluded during export.", + "type": "boolean" + }, + "exportBlobName": { + "description": "The name of the blob that will be created in the provided output blob container. This blob will contain the exported device registry information for the IoT Hub.", + "type": "string" + }, + "authenticationType": { + "description": "Specifies authentication type being used for connecting to the storage account.", + "enum": [ + "keyBased", + "identityBased" + ], + "type": "string", + "x-ms-enum": { + "name": "AuthenticationType", + "modelAsString": true + } + }, + "identity": { + "description": "Managed identity properties of storage endpoint for export devices.", + "$ref": "#/definitions/ManagedIdentity" + }, + "includeConfigurations": { + "description": "The value indicating whether configurations should be exported.", + "type": "boolean" + }, + "configurationsBlobName": { + "description": "The name of the blob that will be created in the provided output blob container. This blob will contain the exported configurations for the Iot Hub.", + "type": "string" + } + }, + "required": [ + "exportBlobContainerUri", + "excludeKeys" + ] + }, + "ImportDevicesRequest": { + "description": "Use to provide parameters when requesting an import of all devices in the hub.", + "type": "object", + "properties": { + "inputBlobContainerUri": { + "description": "The input blob container URI.", + "type": "string" + }, + "outputBlobContainerUri": { + "description": "The output blob container URI.", + "type": "string" + }, + "inputBlobName": { + "description": "The blob name to be used when importing from the provided input blob container.", + "type": "string" + }, + "outputBlobName": { + "description": "The blob name to use for storing the status of the import job.", + "type": "string" + }, + "authenticationType": { + "description": "Specifies authentication type being used for connecting to the storage account.", + "enum": [ + "keyBased", + "identityBased" + ], + "type": "string", + "x-ms-enum": { + "name": "AuthenticationType", + "modelAsString": true + } + }, + "identity": { + "description": "Managed identity properties of storage endpoint for import devices.", + "$ref": "#/definitions/ManagedIdentity" + }, + "includeConfigurations": { + "description": "The value indicating whether configurations should be imported.", + "type": "boolean" + }, + "configurationsBlobName": { + "description": "The blob name to be used when importing configurations from the provided input blob container.", + "type": "string" + } + }, + "required": [ + "inputBlobContainerUri", + "outputBlobContainerUri" + ] + }, + "FailoverInput": { + "description": "Use to provide failover region when requesting manual Failover for a hub.", + "type": "object", + "properties": { + "failoverRegion": { + "description": "Region the hub will be failed over to", + "type": "string" + } + }, + "required": [ + "failoverRegion" + ] + }, + "IotHubLocationDescription": { + "description": "Public representation of one of the locations where a resource is provisioned.", + "type": "object", + "properties": { + "location": { + "description": "The name of the Azure region", + "type": "string" + }, + "role": { + "description": "The role of the region, can be either primary or secondary. The primary region is where the IoT hub is currently provisioned. The secondary region is the Azure disaster recovery (DR) paired region and also the region where the IoT hub can failover to.", + "enum": [ + "primary", + "secondary" + ], + "type": "string", + "x-ms-enum": { + "name": "IotHubReplicaRoleType", + "modelAsString": true + } + } + } + }, + "ArmIdentity": { + "type": "object", + "properties": { + "principalId": { + "description": "Principal Id", + "type": "string", + "readOnly": true + }, + "tenantId": { + "description": "Tenant Id", + "type": "string", + "readOnly": true + }, + "type": { + "description": "The type of identity used for the resource. The type 'SystemAssigned,UserAssigned' includes both an implicitly created identity and a set of user assigned identities. The type 'None' will remove any identities from the service.", + "type": "string", + "enum": [ + "SystemAssigned", + "UserAssigned", + "SystemAssigned, UserAssigned", + "None" + ], + "x-ms-enum": { + "name": "ResourceIdentityType", + "modelAsString": false + } + }, + "userAssignedIdentities": { + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/ArmUserIdentity" + } + } + } + }, + "ArmUserIdentity": { + "type": "object", + "properties": { + "principalId": { + "type": "string", + "readOnly": true + }, + "clientId": { + "type": "string", + "readOnly": true + } + } + }, + "EncryptionPropertiesDescription": { + "description": "The encryption properties for the IoT hub.", + "type": "object", + "properties": { + "keySource": { + "description": "The source of the key.", + "type": "string" + }, + "keyVaultProperties": { + "description": "The properties of the KeyVault key.", + "type": "array", + "items": { + "$ref": "#/definitions/KeyVaultKeyProperties" + } + } + } + }, + "KeyVaultKeyProperties": { + "description": "The properties of the KeyVault key.", + "type": "object", + "properties": { + "keyIdentifier": { + "type": "string", + "description": "The identifier of the key." + }, + "identity": { + "description": "Managed identity properties of KeyVault Key.", + "$ref": "#/definitions/ManagedIdentity" + } + } + }, + "ManagedIdentity": { + "description": "The properties of the Managed identity.", + "type": "object", + "properties": { + "userAssignedIdentity": { + "type": "string", + "description": "The user assigned identity." + } + } + }, + "systemData": { + "description": "Metadata pertaining to creation and last modification of the resource.", + "type": "object", + "readOnly": true, + "properties": { + "createdBy": { + "type": "string", + "description": "The identity that created the resource." + }, + "createdByType": { + "type": "string", + "description": "The type of identity that created the resource.", + "enum": [ + "User", + "Application", + "ManagedIdentity", + "Key" + ], + "x-ms-enum": { + "name": "createdByType", + "modelAsString": true + } + }, + "createdAt": { + "type": "string", + "format": "date-time", + "description": "The timestamp of resource creation (UTC)." + }, + "lastModifiedBy": { + "type": "string", + "description": "The identity that last modified the resource." + }, + "lastModifiedByType": { + "type": "string", + "description": "The type of identity that last modified the resource.", + "enum": [ + "User", + "Application", + "ManagedIdentity", + "Key" + ], + "x-ms-enum": { + "name": "createdByType", + "modelAsString": true + } + }, + "lastModifiedAt": { + "type": "string", + "format": "date-time", + "description": "The timestamp of resource last modification (UTC)" + } + } + } + }, + "parameters": { + "subscriptionId": { + "name": "subscriptionId", + "in": "path", + "description": "The subscription identifier.", + "required": true, + "type": "string" + }, + "api-version": { + "name": "api-version", + "in": "query", + "description": "The version of the API.", + "required": true, + "type": "string" + }, + "resourceGroupName": { + "name": "resourceGroupName", + "description": "The name of the resource group that contains the IoT hub.", + "in": "path", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "resourceName": { + "name": "resourceName", + "in": "path", + "description": "The name of the IoT hub.", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "certificateName": { + "name": "certificateName", + "in": "path", + "description": "The name of the certificate", + "required": true, + "type": "string", + "pattern": "^[A-Za-z0-9-._]{1,64}$", + "x-ms-parameter-location": "method" + }, + "groupId": { + "name": "groupId", + "in": "path", + "description": "The name of the private link resource", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "privateEndpointConnectionName": { + "name": "privateEndpointConnectionName", + "in": "path", + "description": "The name of the private endpoint connection", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + } + } +} From a29a04535bb1c86112e085024ee49cc1ec408dac Mon Sep 17 00:00:00 2001 From: didact2401 Date: Mon, 18 Apr 2022 15:09:25 -0700 Subject: [PATCH 02/42] Updates readme --- specification/iothub/resource-manager/readme.md | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/specification/iothub/resource-manager/readme.md b/specification/iothub/resource-manager/readme.md index 04bf69013ef7..8193790e1c76 100644 --- a/specification/iothub/resource-manager/readme.md +++ b/specification/iothub/resource-manager/readme.md @@ -26,15 +26,23 @@ These are the global settings for the IotHub API. ``` yaml openapi-type: arm -tag: package-2021-07-02 +tag: package-preview-2022-04 ``` +### Tag: package-preview-2022-04 + +These settings apply only when `--tag=package-preview-2022-04` is specified on the command line. + +```yaml $(tag) == 'package-preview-2022-04' +input-file: + - Microsoft.Devices/preview/2022-04-30-preview/iothub.json +``` ### Tag: package-2021-07-02 These settings apply only when `--tag=package-2021-07-02` is specified on the command line. -```yaml $(tag) == 'package-2021-07-02' +``` yaml $(tag) == 'package-2021-07-02' input-file: - Microsoft.Devices/stable/2021-07-02/iothub.json ``` @@ -43,7 +51,7 @@ input-file: These settings apply only when `--tag=package-preview-2021-07-02` is specified on the command line. -```yaml $(tag) == 'package-preview-2021-07-02' +``` yaml $(tag) == 'package-preview-2021-07-02' input-file: - Microsoft.Devices/preview/2021-07-02-preview/iothub.json ``` From 874816bc91a10796132b4233a7f0bbe5c43b9f62 Mon Sep 17 00:00:00 2001 From: didact2401 Date: Mon, 18 Apr 2022 15:09:27 -0700 Subject: [PATCH 03/42] Updates API version in new specs and examples --- .../2022-04-30-preview/examples/IotHub_ManualFailover.json | 2 +- .../2022-04-30-preview/examples/checkNameAvailability.json | 2 +- .../examples/iothub_certificatescreateorupdate.json | 2 +- .../2022-04-30-preview/examples/iothub_certificatesdelete.json | 2 +- .../preview/2022-04-30-preview/examples/iothub_certverify.json | 2 +- .../2022-04-30-preview/examples/iothub_createOrUpdate.json | 2 +- .../2022-04-30-preview/examples/iothub_createconsumergroup.json | 2 +- .../preview/2022-04-30-preview/examples/iothub_delete.json | 2 +- .../2022-04-30-preview/examples/iothub_deleteconsumergroup.json | 2 +- .../examples/iothub_deleteprivateendpointconnection.json | 2 +- .../2022-04-30-preview/examples/iothub_exportdevices.json | 2 +- .../examples/iothub_generateverificationcode.json | 2 +- .../preview/2022-04-30-preview/examples/iothub_get.json | 2 +- .../2022-04-30-preview/examples/iothub_getcertificate.json | 2 +- .../2022-04-30-preview/examples/iothub_getconsumergroup.json | 2 +- .../preview/2022-04-30-preview/examples/iothub_getjob.json | 2 +- .../preview/2022-04-30-preview/examples/iothub_getkey.json | 2 +- .../examples/iothub_getprivateendpointconnection.json | 2 +- .../examples/iothub_getprivatelinkresources.json | 2 +- .../preview/2022-04-30-preview/examples/iothub_getskus.json | 2 +- .../2022-04-30-preview/examples/iothub_importdevices.json | 2 +- .../preview/2022-04-30-preview/examples/iothub_listbyrg.json | 2 +- .../2022-04-30-preview/examples/iothub_listbysubscription.json | 2 +- .../2022-04-30-preview/examples/iothub_listcertificates.json | 2 +- .../2022-04-30-preview/examples/iothub_listehgroups.json | 2 +- .../preview/2022-04-30-preview/examples/iothub_listjobs.json | 2 +- .../preview/2022-04-30-preview/examples/iothub_listkeys.json | 2 +- .../examples/iothub_listprivateendpointconnections.json | 2 +- .../examples/iothub_listprivatelinkresources.json | 2 +- .../preview/2022-04-30-preview/examples/iothub_operations.json | 2 +- .../preview/2022-04-30-preview/examples/iothub_patch.json | 2 +- .../2022-04-30-preview/examples/iothub_quotametrics.json | 2 +- .../examples/iothub_routingendpointhealth.json | 2 +- .../2022-04-30-preview/examples/iothub_testallroutes.json | 2 +- .../2022-04-30-preview/examples/iothub_testnewroute.json | 2 +- .../examples/iothub_updateprivateendpointconnection.json | 2 +- .../preview/2022-04-30-preview/examples/iothub_usages.json | 2 +- .../Microsoft.Devices/preview/2022-04-30-preview/iothub.json | 2 +- 38 files changed, 38 insertions(+), 38 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/IotHub_ManualFailover.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/IotHub_ManualFailover.json index ba3ce8591da0..0ba4e56a23b2 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/IotHub_ManualFailover.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/IotHub_ManualFailover.json @@ -2,7 +2,7 @@ "parameters": { "iotHubName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "failoverInput": { "failoverRegion": "testHub" diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/checkNameAvailability.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/checkNameAvailability.json index f9d5e2f6e31f..670c1ab9207f 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/checkNameAvailability.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/checkNameAvailability.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "operationInputs": { "name": "test-request" diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certificatescreateorupdate.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certificatescreateorupdate.json index 5c7ffa5f75d2..e8c577826f18 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certificatescreateorupdate.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certificatescreateorupdate.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "iothub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "certificateName": "cert", "certificateDescription": { diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certificatesdelete.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certificatesdelete.json index 6674ad724fce..7d4719e90622 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certificatesdelete.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certificatesdelete.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "myhub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "certificateName": "cert", "If-Match": "AAAAAAAADGk=" diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certverify.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certverify.json index 9f14c412ae66..260843c53b21 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certverify.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_certverify.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "myFirstProvisioningService", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "certificateName": "cert", "If-Match": "AAAAAAAADGk=", diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createOrUpdate.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createOrUpdate.json index b0e130d5660a..59e3700a4efb 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createOrUpdate.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createOrUpdate.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "iotHubDescription": { "location": "centraluseuap", diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createconsumergroup.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createconsumergroup.json index 5ae8777b4386..6eef87432550 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createconsumergroup.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createconsumergroup.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "eventHubEndpointName": "events", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "name": "test", diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_delete.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_delete.json index 20685015f32a..d5bfef77c95a 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_delete.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_delete.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" }, "responses": { diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteconsumergroup.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteconsumergroup.json index f8e12b770a27..22482782e4aa 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteconsumergroup.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteconsumergroup.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "eventHubEndpointName": "events", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "name": "test" diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteprivateendpointconnection.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteprivateendpointconnection.json index 27d65e823743..f20fcdb99268 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteprivateendpointconnection.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteprivateendpointconnection.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "privateEndpointConnectionName": "myPrivateEndpointConnection" }, diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_exportdevices.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_exportdevices.json index 3e7a090bb890..2cd5e3b132f3 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_exportdevices.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_exportdevices.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "exportDevicesParameters": { "authenticationType": "identityBased", diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_generateverificationcode.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_generateverificationcode.json index 2a56c890fcc2..b70efad239dd 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_generateverificationcode.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_generateverificationcode.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "certificateName": "cert", "If-Match": "AAAAAAAADGk=" diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_get.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_get.json index 083f33f8bc60..73f4856ff15f 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_get.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_get.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" }, "responses": { diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getcertificate.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getcertificate.json index 31ff921df634..e61a7ebe1627 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getcertificate.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getcertificate.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testhub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "certificateName": "cert" }, diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getconsumergroup.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getconsumergroup.json index 7d37e97dd0d5..6254f2182800 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getconsumergroup.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getconsumergroup.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "eventHubEndpointName": "events", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "name": "test" diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getjob.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getjob.json index 11311db37fd6..2f347dac8519 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getjob.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getjob.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "jobId": "test" }, diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getkey.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getkey.json index bf4f814f8518..b2abbc820410 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getkey.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getkey.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "keyName": "iothubowner" }, diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getprivateendpointconnection.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getprivateendpointconnection.json index 4ff0b85da780..ec0ba99211b1 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getprivateendpointconnection.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getprivateendpointconnection.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "privateEndpointConnectionName": "myPrivateEndpointConnection" }, diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getprivatelinkresources.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getprivatelinkresources.json index 2208810789c9..3a2c5a5143a0 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getprivatelinkresources.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getprivatelinkresources.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "groupId": "iotHub" }, diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getskus.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getskus.json index 367922d2f233..5794fcc141b1 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getskus.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_getskus.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" }, "responses": { diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_importdevices.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_importdevices.json index cf3940c37ac4..552b6c73fb0a 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_importdevices.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_importdevices.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "importDevicesParameters": { "inputBlobContainerUri": "testBlob", diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listbyrg.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listbyrg.json index 4c4d8590fd3f..3d1192b4819b 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listbyrg.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listbyrg.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" }, "responses": { diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listbysubscription.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listbysubscription.json index 4cba193e6de0..67b7fb591585 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listbysubscription.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listbysubscription.json @@ -1,7 +1,7 @@ { "parameters": { "resourceName": "testHub", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" }, "responses": { diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listcertificates.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listcertificates.json index bac71cb62a87..eb852172d15d 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listcertificates.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listcertificates.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testhub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" }, "responses": { diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listehgroups.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listehgroups.json index 92f349047ce9..9732962f4c91 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listehgroups.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listehgroups.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "eventHubEndpointName": "events", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" }, diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listjobs.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listjobs.json index c5a6c8fe132d..7b9bf286bf8a 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listjobs.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listjobs.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" }, "responses": { diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listkeys.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listkeys.json index 51dfe405df35..cbdee9949486 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listkeys.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listkeys.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" }, "responses": { diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listprivateendpointconnections.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listprivateendpointconnections.json index 8867691fb477..270327b894d3 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listprivateendpointconnections.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listprivateendpointconnections.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" }, "responses": { diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listprivatelinkresources.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listprivatelinkresources.json index d690aa05e12c..d28eab648484 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listprivatelinkresources.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_listprivatelinkresources.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" }, "responses": { diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_operations.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_operations.json index acd916d9d5ef..b2730d31770d 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_operations.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_operations.json @@ -1,6 +1,6 @@ { "parameters": { - "api-version": "2021-07-02-preview" + "api-version": "2022-04-30-preview" }, "responses": { "200": { diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_patch.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_patch.json index 8f28ea7a184e..041c1de66a6a 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_patch.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_patch.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "myHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "location": "East US", "type": "Microsoft.Devices/IotHubs", diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_quotametrics.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_quotametrics.json index d8c89aa76fa3..2b5b33be8cde 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_quotametrics.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_quotametrics.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" }, "responses": { diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_routingendpointhealth.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_routingendpointhealth.json index a11d3e1bccd1..4a24bc749e8b 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_routingendpointhealth.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_routingendpointhealth.json @@ -2,7 +2,7 @@ "parameters": { "iotHubName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" }, "responses": { diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_testallroutes.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_testallroutes.json index 852b33807074..0416d41373a3 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_testallroutes.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_testallroutes.json @@ -2,7 +2,7 @@ "parameters": { "iotHubName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "input": { "routingSource": "DeviceMessages", diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_testnewroute.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_testnewroute.json index 7d3725b8243f..1a51968f2a34 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_testnewroute.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_testnewroute.json @@ -2,7 +2,7 @@ "parameters": { "iotHubName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "input": { "message": { diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_updateprivateendpointconnection.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_updateprivateendpointconnection.json index 791e5ee279fc..9dec81f36cf9 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_updateprivateendpointconnection.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_updateprivateendpointconnection.json @@ -2,7 +2,7 @@ "parameters": { "resourceName": "testHub", "resourceGroupName": "myResourceGroup", - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0", "privateEndpointConnectionName": "myPrivateEndpointConnection", "privateEndpointConnection": { diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_usages.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_usages.json index ee71609f8b0c..4080dc1d2cdc 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_usages.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_usages.json @@ -1,6 +1,6 @@ { "parameters": { - "api-version": "2021-07-02-preview", + "api-version": "2022-04-30-preview", "subscriptionId": "91d12660-3dec-467a-be2a-213b5544ddc0" }, "responses": { diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 5dd7e602e110..3bf3aa385a44 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -1,7 +1,7 @@ { "swagger": "2.0", "info": { - "version": "2021-07-02-preview", + "version": "2022-04-30-preview", "title": "iotHubClient", "description": "Use this API to manage the IoT hubs in your Azure subscription.", "x-ms-code-generation-settings": { From 83f4a7bcc724f9a91dbb79e94d869bb2d49a6cb2 Mon Sep 17 00:00:00 2001 From: Jared Wilson Date: Tue, 19 Apr 2022 14:09:35 -0700 Subject: [PATCH 04/42] Add RoutingCosmosDBCollectionProperties to iothub.json. --- .../preview/2022-04-30-preview/iothub.json | 79 +++++++++++++++++++ 1 file changed, 79 insertions(+) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 3bf3aa385a44..30466f75729e 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -2919,6 +2919,13 @@ "items": { "$ref": "#/definitions/RoutingStorageContainerProperties" } + }, + "cosmosDBSqlCollections": { + "description": "The list of cosmos DB collection endpoints that IoT hub routes messages to, based on the routing rules.", + "type": "array", + "items": { + "$ref": "#/definitions/RoutingCosmosDBSqlCollectionProperties" + } } } }, @@ -3166,6 +3173,78 @@ "containerName" ] }, + "RoutingCosmosDBSqlCollectionProperties": { + "description": "The properties related to a cosmos DB collection endpoint.", + "type": "object", + "properties": { + "name": { + "description": "The name that identifies this endpoint. The name can only include alphanumeric characters, periods, underscores, hyphens and has a maximum length of 64 characters. The following names are reserved: events, fileNotifications, $default. Endpoint names must be unique across endpoint types.", + "type": "string", + "pattern": "^[A-Za-z0-9-._]{1,64}$" + }, + "id": { + "description": "Id of the cosmos DB collection endpoint", + "type": "string" + }, + "subscriptionId": { + "description": "The subscription identifier of the cosmos DB account.", + "type": "string" + }, + "resourceGroup": { + "description": "The name of the resource group of the cosmos DB account.", + "type": "string" + }, + "endpointUri": { + "description": "The url of the cosmos DB account. It must include the protocol https://", + "type": "string" + }, + "authenticationType": { + "description": "Method used to authenticate against the cosmos DB collection endpoint", + "enum": [ + "keyBased", + "identityBased" + ], + "type": "string", + "x-ms-enum": { + "name": "authenticationType", + "modelAsString": true + } + }, + "identity": { + "description": "Managed identity properties of routing cosmos DB collection endpoint.", + "$ref": "#/definitions/ManagedIdentity" + }, + "primaryKey": { + "description": "The primary key of the cosmos DB account.", + "type": "string" + }, + "secondaryKey": { + "description": "The secondary key of the cosmos DB account.", + "type": "string" + }, + "databaseName": { + "description": "The name of the cosmos DB database in the cosmos DB account.", + "type": "string" + }, + "collectionName": { + "description": "The name of the cosmos DB collection in the cosmos DB database.", + "type": "string" + }, + "PartitionKeyName": { + "description": "The name of the partition key associated with this cosmos DB collection if one exists. This is an optional parameter.", + "type": "string" + }, + "PartitionKeyTemplate": { + "description": "The template for generating a synthetic partition key value for use with this cosmos DB collection. The template must include at least one of the following placeholders: {iothub}, {deviceid}, {DD}, {MM}, and {YYYY}. Any one placeholder may be specified at most once, but order and non-placeholder components are arbitrary. This parameter is only required if PartitionKeyName is specified.", + "type": "string" + } + }, + "required": [ + "name", + "databaseName", + "collectionName" + ] + }, "RouteProperties": { "description": "The properties of a routing rule that your IoT hub uses to route messages to endpoints.", "type": "object", From d837bf6f86c6212b53e369c5fbfa7250a2131eb3 Mon Sep 17 00:00:00 2001 From: Jared Wilson Date: Tue, 19 Apr 2022 16:23:39 -0700 Subject: [PATCH 05/42] Update naming. --- .../preview/2022-04-30-preview/iothub.json | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 30466f75729e..6b2ba2afa410 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -2921,10 +2921,10 @@ } }, "cosmosDBSqlCollections": { - "description": "The list of cosmos DB collection endpoints that IoT hub routes messages to, based on the routing rules.", + "description": "The list of Cosmos DB collection endpoints that IoT hub routes messages to, based on the routing rules.", "type": "array", "items": { - "$ref": "#/definitions/RoutingCosmosDBSqlCollectionProperties" + "$ref": "#/definitions/RoutingCosmosDBSqlApiProperties" } } } @@ -3173,8 +3173,8 @@ "containerName" ] }, - "RoutingCosmosDBSqlCollectionProperties": { - "description": "The properties related to a cosmos DB collection endpoint.", + "RoutingCosmosDBSqlApiProperties": { + "description": "The properties related to a cosmos DB sql collection endpoint.", "type": "object", "properties": { "name": { @@ -3183,7 +3183,7 @@ "pattern": "^[A-Za-z0-9-._]{1,64}$" }, "id": { - "description": "Id of the cosmos DB collection endpoint", + "description": "Id of the cosmos DB sql collection endpoint", "type": "string" }, "subscriptionId": { @@ -3199,7 +3199,7 @@ "type": "string" }, "authenticationType": { - "description": "Method used to authenticate against the cosmos DB collection endpoint", + "description": "Method used to authenticate against the cosmos DB sql collection endpoint", "enum": [ "keyBased", "identityBased" @@ -3231,16 +3231,17 @@ "type": "string" }, "PartitionKeyName": { - "description": "The name of the partition key associated with this cosmos DB collection if one exists. This is an optional parameter.", + "description": "The name of the partition key associated with this cosmos DB sql collection if one exists. This is an optional parameter.", "type": "string" }, "PartitionKeyTemplate": { - "description": "The template for generating a synthetic partition key value for use with this cosmos DB collection. The template must include at least one of the following placeholders: {iothub}, {deviceid}, {DD}, {MM}, and {YYYY}. Any one placeholder may be specified at most once, but order and non-placeholder components are arbitrary. This parameter is only required if PartitionKeyName is specified.", + "description": "The template for generating a synthetic partition key value for use with this cosmos DB sql collection. The template must include at least one of the following placeholders: {iothub}, {deviceid}, {DD}, {MM}, and {YYYY}. Any one placeholder may be specified at most once, but order and non-placeholder components are arbitrary. This parameter is only required if PartitionKeyName is specified.", "type": "string" } }, "required": [ "name", + "endpointUri", "databaseName", "collectionName" ] From b167354e30134994f8266b63704dd554a1d38842 Mon Sep 17 00:00:00 2001 From: Jared Wilson Date: Wed, 20 Apr 2022 13:23:32 -0700 Subject: [PATCH 06/42] Fix enum. --- .../preview/2022-04-30-preview/iothub.json | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 6b2ba2afa410..4df4d01df4ad 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -3227,7 +3227,7 @@ "type": "string" }, "collectionName": { - "description": "The name of the cosmos DB collection in the cosmos DB database.", + "description": "The name of the cosmos DB sql collection in the cosmos DB database.", "type": "string" }, "PartitionKeyName": { @@ -3309,7 +3309,14 @@ "source": { "description": "The source to which the routing rule is to be applied to. For example, DeviceMessages", "enum": [ - "DeviceMessages" + "Invalid", + "DeviceMessages", + "TwinChangeEvents", + "DeviceLifecycleEvents", + "DeviceJobLifecycleEvents", + "DigitalTwinChangeEvents", + "DeviceConnectionStateEvents", + "MqttBrokerMessages" ], "type": "string", "x-ms-enum": { From 061ac5651d935c07adc1d373076e277e9b984e2a Mon Sep 17 00:00:00 2001 From: Jared Wilson Date: Tue, 26 Apr 2022 11:37:18 -0700 Subject: [PATCH 07/42] Unique x-ms-enum names. --- .../preview/2022-04-30-preview/iothub.json | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 4df4d01df4ad..f17bc9ff5b76 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -3309,18 +3309,11 @@ "source": { "description": "The source to which the routing rule is to be applied to. For example, DeviceMessages", "enum": [ - "Invalid", - "DeviceMessages", - "TwinChangeEvents", - "DeviceLifecycleEvents", - "DeviceJobLifecycleEvents", - "DigitalTwinChangeEvents", - "DeviceConnectionStateEvents", - "MqttBrokerMessages" + "DeviceMessages" ], "type": "string", "x-ms-enum": { - "name": "RoutingSource", + "name": "FallbackRoutingSource", "modelAsString": true } }, @@ -4071,7 +4064,7 @@ ], "type": "string", "x-ms-enum": { - "name": "RoutingSource", + "name": "TestRoutingSource", "modelAsString": true } }, From 6279e703315921b21ca72f306850305f91743874 Mon Sep 17 00:00:00 2001 From: Jared Wilson Date: Tue, 26 Apr 2022 14:16:07 -0700 Subject: [PATCH 08/42] Use same name for same enum def. --- .../Microsoft.Devices/preview/2022-04-30-preview/iothub.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index f17bc9ff5b76..9724a1048655 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -4064,7 +4064,7 @@ ], "type": "string", "x-ms-enum": { - "name": "TestRoutingSource", + "name": "RoutingSource", "modelAsString": true } }, From 214fb0acdcb28f3dee0322bc3ad9de35ab43a1bf Mon Sep 17 00:00:00 2001 From: Jared Wilson Date: Tue, 26 Apr 2022 14:59:25 -0700 Subject: [PATCH 09/42] Revert "Use same name for same enum def." This reverts commit 6279e703315921b21ca72f306850305f91743874. --- .../Microsoft.Devices/preview/2022-04-30-preview/iothub.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 9724a1048655..f17bc9ff5b76 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -4064,7 +4064,7 @@ ], "type": "string", "x-ms-enum": { - "name": "RoutingSource", + "name": "TestRoutingSource", "modelAsString": true } }, From 366c4b337da16aa23bf3eac86095f0d1f0b7418e Mon Sep 17 00:00:00 2001 From: Jared Wilson Date: Thu, 28 Apr 2022 12:34:28 -0700 Subject: [PATCH 10/42] Use same name for enum. --- .../Microsoft.Devices/preview/2022-04-30-preview/iothub.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index f17bc9ff5b76..78f608740ec3 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -3313,7 +3313,7 @@ ], "type": "string", "x-ms-enum": { - "name": "FallbackRoutingSource", + "name": "RoutingSource", "modelAsString": true } }, @@ -4064,7 +4064,7 @@ ], "type": "string", "x-ms-enum": { - "name": "TestRoutingSource", + "name": "RoutingSource", "modelAsString": true } }, From 15b8dc9796d24b34c476d980f4c9c2b2d64a7881 Mon Sep 17 00:00:00 2001 From: Jared Wilson Date: Thu, 28 Apr 2022 19:52:52 -0700 Subject: [PATCH 11/42] Revert "Use same name for enum." This reverts commit 366c4b337da16aa23bf3eac86095f0d1f0b7418e. --- .../Microsoft.Devices/preview/2022-04-30-preview/iothub.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 78f608740ec3..f17bc9ff5b76 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -3313,7 +3313,7 @@ ], "type": "string", "x-ms-enum": { - "name": "RoutingSource", + "name": "FallbackRoutingSource", "modelAsString": true } }, @@ -4064,7 +4064,7 @@ ], "type": "string", "x-ms-enum": { - "name": "RoutingSource", + "name": "TestRoutingSource", "modelAsString": true } }, From dd9f07f3dc7b811990ff93872c00538040fdfd6e Mon Sep 17 00:00:00 2001 From: didact2401 Date: Fri, 29 Apr 2022 12:04:45 -0700 Subject: [PATCH 12/42] Adds suppression to readme --- specification/iothub/resource-manager/readme.md | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/specification/iothub/resource-manager/readme.md b/specification/iothub/resource-manager/readme.md index 8193790e1c76..cbc3f77aa063 100644 --- a/specification/iothub/resource-manager/readme.md +++ b/specification/iothub/resource-manager/readme.md @@ -29,15 +29,15 @@ openapi-type: arm tag: package-preview-2022-04 ``` - ### Tag: package-preview-2022-04 These settings apply only when `--tag=package-preview-2022-04` is specified on the command line. -```yaml $(tag) == 'package-preview-2022-04' +``` yaml $(tag) == 'package-preview-2022-04' input-file: - Microsoft.Devices/preview/2022-04-30-preview/iothub.json ``` + ### Tag: package-2021-07-02 These settings apply only when `--tag=package-2021-07-02` is specified on the command line. @@ -313,3 +313,13 @@ See configuration in [readme.go.md](./readme.go.md) ## Java See configuration in [readme.java.md](./readme.go.md) + +## Suppression + +``` yaml +directive: + - suppress: UniqueXmsEnumName + where: $.definitions.FallbackRouteProperties.properties.source + from: iothub.json + reason: False positive. +``` From 0636b65b4648a6b2fed84ae89cce0d692c1f26b1 Mon Sep 17 00:00:00 2001 From: Jared Wilson Date: Fri, 29 Apr 2022 17:53:45 -0700 Subject: [PATCH 13/42] Revert "Revert "Use same name for enum."" This reverts commit 15b8dc9796d24b34c476d980f4c9c2b2d64a7881. --- .../Microsoft.Devices/preview/2022-04-30-preview/iothub.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index f17bc9ff5b76..78f608740ec3 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -3313,7 +3313,7 @@ ], "type": "string", "x-ms-enum": { - "name": "FallbackRoutingSource", + "name": "RoutingSource", "modelAsString": true } }, @@ -4064,7 +4064,7 @@ ], "type": "string", "x-ms-enum": { - "name": "TestRoutingSource", + "name": "RoutingSource", "modelAsString": true } }, From 96d4e45ab6cc25f095cb44739fdf4bfc228f98b7 Mon Sep 17 00:00:00 2001 From: Jared Wilson Date: Mon, 2 May 2022 12:12:23 -0700 Subject: [PATCH 14/42] Update reason on UniqueXmsEnumName suppression. --- specification/iothub/resource-manager/readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification/iothub/resource-manager/readme.md b/specification/iothub/resource-manager/readme.md index cbc3f77aa063..d2c9096e81b3 100644 --- a/specification/iothub/resource-manager/readme.md +++ b/specification/iothub/resource-manager/readme.md @@ -321,5 +321,5 @@ directive: - suppress: UniqueXmsEnumName where: $.definitions.FallbackRouteProperties.properties.source from: iothub.json - reason: False positive. + reason: Ensure non-breaking change. ``` From 8c9b66fd7b350760a154c4e0dfd16b18bb3a32dd Mon Sep 17 00:00:00 2001 From: Jared Wilson Date: Mon, 2 May 2022 12:40:30 -0700 Subject: [PATCH 15/42] Ensure camel casing on partitionKeyName and partitionKeyTemplate. --- .../Microsoft.Devices/preview/2022-04-30-preview/iothub.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 78f608740ec3..d96446683092 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -3230,11 +3230,11 @@ "description": "The name of the cosmos DB sql collection in the cosmos DB database.", "type": "string" }, - "PartitionKeyName": { + "partitionKeyName": { "description": "The name of the partition key associated with this cosmos DB sql collection if one exists. This is an optional parameter.", "type": "string" }, - "PartitionKeyTemplate": { + "partitionKeyTemplate": { "description": "The template for generating a synthetic partition key value for use with this cosmos DB sql collection. The template must include at least one of the following placeholders: {iothub}, {deviceid}, {DD}, {MM}, and {YYYY}. Any one placeholder may be specified at most once, but order and non-placeholder components are arbitrary. This parameter is only required if PartitionKeyName is specified.", "type": "string" } From c0ba99ecc6df5d3ed7f518532f75d54befd637f7 Mon Sep 17 00:00:00 2001 From: Jared Wilson Date: Thu, 12 May 2022 14:28:50 -0700 Subject: [PATCH 16/42] Add 'deviceid' to custom-words.txt. --- custom-words.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/custom-words.txt b/custom-words.txt index 86c004c47426..3d37982f15a2 100644 --- a/custom-words.txt +++ b/custom-words.txt @@ -579,6 +579,7 @@ deterministically deviceclasses devicecredentials devicegroups +deviceid deviceids deviceprovisioningservices devicestates From e04f4033e7e1de957cbb82799997f3ba39393564 Mon Sep 17 00:00:00 2001 From: Jared Wilson Date: Mon, 16 May 2022 14:45:31 -0700 Subject: [PATCH 17/42] Add x-ms-secret. --- .../preview/2022-04-30-preview/iothub.json | 21 ++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index d96446683092..b06c7a849b76 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -2514,7 +2514,8 @@ }, "connectionString": { "description": "The connection string for the Azure Storage account to which files are uploaded.", - "type": "string" + "type": "string", + "x-ms-secret": true }, "containerName": { "description": "The name of the root container where you upload files. The container need not exist but should be creatable using the connectionString specified.", @@ -2939,7 +2940,8 @@ }, "connectionString": { "description": "The connection string of the service bus queue endpoint.", - "type": "string" + "type": "string", + "x-ms-secret": true }, "endpointUri": { "description": "The url of the service bus queue endpoint. It must include the protocol sb://", @@ -2993,7 +2995,8 @@ }, "connectionString": { "description": "The connection string of the service bus topic endpoint.", - "type": "string" + "type": "string", + "x-ms-secret": true }, "endpointUri": { "description": "The url of the service bus topic endpoint. It must include the protocol sb://", @@ -3047,7 +3050,8 @@ }, "connectionString": { "description": "The connection string of the event hub endpoint. ", - "type": "string" + "type": "string", + "x-ms-secret": true }, "endpointUri": { "description": "The url of the event hub endpoint. It must include the protocol sb://", @@ -3101,7 +3105,8 @@ }, "connectionString": { "description": "The connection string of the storage account.", - "type": "string" + "type": "string", + "x-ms-secret": true }, "endpointUri": { "description": "The url of the storage endpoint. It must include the protocol https://", @@ -3216,11 +3221,13 @@ }, "primaryKey": { "description": "The primary key of the cosmos DB account.", - "type": "string" + "type": "string", + "x-ms-secret": true }, "secondaryKey": { "description": "The secondary key of the cosmos DB account.", - "type": "string" + "type": "string", + "x-ms-secret": true }, "databaseName": { "description": "The name of the cosmos DB database in the cosmos DB account.", From b8a3f12adb8916dee6e6d16ce5ed9ca0cee257fb Mon Sep 17 00:00:00 2001 From: Jared Wilson Date: Mon, 16 May 2022 15:57:31 -0700 Subject: [PATCH 18/42] Remove secret tag for storage endpoint connection string. --- .../Microsoft.Devices/preview/2022-04-30-preview/iothub.json | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index b06c7a849b76..273399d41f8a 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -2514,8 +2514,7 @@ }, "connectionString": { "description": "The connection string for the Azure Storage account to which files are uploaded.", - "type": "string", - "x-ms-secret": true + "type": "string" }, "containerName": { "description": "The name of the root container where you upload files. The container need not exist but should be creatable using the connectionString specified.", From 3b1b3a0797c70044a48712d8ac068a5250f58ebf Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Fri, 17 Jun 2022 16:18:01 -0700 Subject: [PATCH 19/42] Adding the change for rootCertificateV2 --- .../examples/iothub_createOrUpdate.json | 17 ++++++++++++++--- .../preview/2022-04-30-preview/iothub.json | 19 +++++++++++++++++++ 2 files changed, 33 insertions(+), 3 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createOrUpdate.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createOrUpdate.json index 59e3700a4efb..673650c65ceb 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createOrUpdate.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_createOrUpdate.json @@ -76,7 +76,10 @@ }, "features": "None", "minTlsVersion": "1.2", - "enableDataResidency": true + "enableDataResidency": true, + "rootCertificate": { + "enableRootCertificateV2": true + } }, "sku": { "name": "S1", @@ -181,7 +184,11 @@ }, "features": "None", "minTlsVersion": "1.2", - "enableDataResidency": true + "enableDataResidency": true, + "rootCertificate": { + "enableRootCertificateV2": true, + "lastUpdatedTimeUtc": "2022-04-08T11:16:49.0748958-07:00" + } }, "sku": { "name": "S1", @@ -289,7 +296,11 @@ }, "features": "None", "minTlsVersion": "1.2", - "enableDataResidency": true + "enableDataResidency": true, + "rootCertificate": { + "enableRootCertificateV2": true, + "lastUpdatedTimeUtc": "2022-04-08T11:16:49.0748958-07:00" + } }, "sku": { "name": "S1", diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 273399d41f8a..38ad18f6305b 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -2421,6 +2421,9 @@ "enableDataResidency": { "description": "This property when set to true, will enable data residency, thus, disabling disaster recovery.", "type": "boolean" + }, + "rootCertificate": { + "$ref": "#/definitions/RootCertificateProperties" } } }, @@ -4538,6 +4541,22 @@ "description": "The timestamp of resource last modification (UTC)" } } + }, + "RootCertificateProperties": { + "description": "This property store root certificate related informaiton", + "type": "object", + "properties": { + "enableRootCertificateV2": { + "description": "This property when set to true, hub will use G2 cert; while it's set to false, hub uses Baltimore Cert.", + "type": "boolean" + }, + "lastUpdatedTimeUtc": { + "type": "string", + "readOnly": true, + "format": "date-time", + "description": "the last update time to root certificate flag." + } + } } }, "parameters": { From 43c1d40d92e0b9f52b31ef17f96e5e7e6c757cee Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Tue, 12 Jul 2022 20:06:33 -0700 Subject: [PATCH 20/42] typo --- .../Microsoft.Devices/preview/2022-04-30-preview/iothub.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 38ad18f6305b..ab07921eb605 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -4543,7 +4543,7 @@ } }, "RootCertificateProperties": { - "description": "This property store root certificate related informaiton", + "description": "This property store root certificate related information", "type": "object", "properties": { "enableRootCertificateV2": { From 811ae3847a8b56a2ad911dfc3ed036cdd7b51fbd Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Fri, 22 Jul 2022 15:44:05 -0700 Subject: [PATCH 21/42] fixing validation error --- .../examples/iothub_routingendpointhealth.json | 10 +++++----- .../preview/2022-04-30-preview/iothub.json | 4 ++++ 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_routingendpointhealth.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_routingendpointhealth.json index 4a24bc749e8b..bf3b698efa75 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_routingendpointhealth.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_routingendpointhealth.json @@ -12,8 +12,8 @@ { "endpointId": "id1", "healthStatus": "healthy", - "lastSuccessfulSendAttemptTime": "2020-03-26T21:20:57Z", - "lastSendAttemptTime": "2020-03-26T21:24:57Z" + "lastSuccessfulSendAttemptTime": "Wed, 13 Sep 2017 18:04:32 GMT", + "lastSendAttemptTime": "Wed, 13 Sep 2017 18:04:32 GMT" }, { "endpointId": "id2", @@ -23,9 +23,9 @@ "endpointId": "id3", "healthStatus": "unhealthy", "lastKnownError": "NotFound", - "lastKnownErrorTime": "2020-03-26T21:24:57Z", - "lastSuccessfulSendAttemptTime": "2020-03-26T21:20:57Z", - "lastSendAttemptTime": "2020-03-26T21:24:57Z" + "lastKnownErrorTime": "Wed, 13 Sep 2017 18:04:32 GMT", + "lastSuccessfulSendAttemptTime": "Wed, 13 Sep 2017 18:04:32 GMT", + "lastSendAttemptTime": "Wed, 13 Sep 2017 18:04:32 GMT" } ] } diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index ab07921eb605..d95fb8c6daaf 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -162,6 +162,7 @@ "responses": { "201": { "description": "This is a long running operation. The operation returns a 201 if the validation is complete. The response includes an Azure-AsyncOperation header that contains a status URL. Clients are expected to poll the status URL for the status of the operation. If successful, the operation returns HTTP status code of 201 (OK).", + "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2022-04-30-preview", "schema": { "$ref": "#/definitions/IotHubDescription" } @@ -270,6 +271,7 @@ "responses": { "202": { "description": "The Iot Hub resource provider always returns a 202 Accepted status code with valid Location and Retry-After headers. The resource provider also sets the Azure-AsyncOperation header with a URL that points to the operation resource for this operation. Subsequent GET attempts on the resource after a DELETE operation return a resource representation that indicates a transitional provisioning state (such as Terminating). To retrieve the status of the operation, a client can either poll the URL returned in the Location header after the Retry-After interval, get the IoT Hub service status directly, or query the operation resource.", + "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2022-04-30-preview", "schema": { "$ref": "#/definitions/IotHubDescription" } @@ -1951,6 +1953,7 @@ "responses": { "201": { "description": "This is a long running operation. The operation returns a 201 if the validation is complete. The response includes an Azure-AsyncOperation header that contains a status URL. Clients are expected to poll the status URL for the status of the operation. If successful, the operation returns HTTP status code of 201 (OK).", + "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2022-04-30-preview", "schema": { "$ref": "#/definitions/PrivateEndpointConnection" } @@ -2003,6 +2006,7 @@ "responses": { "202": { "description": "This is a long running operation. The operation returns a 202 if the validation is complete. The response includes an Azure-AsyncOperation header that contains a status URL. Clients are expected to poll the status URL for the status of the operation.", + "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2022-04-30-preview", "schema": { "$ref": "#/definitions/PrivateEndpointConnection" } From d5c5d12db196471f0f5c42bd5c924616589ea4ea Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Fri, 22 Jul 2022 16:03:32 -0700 Subject: [PATCH 22/42] Update error response schema --- .../preview/2022-04-30-preview/iothub.json | 26 ++++++++++++------- 1 file changed, 16 insertions(+), 10 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index d95fb8c6daaf..2bdacf83cbb5 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -3528,25 +3528,31 @@ "description": "Error details.", "type": "object", "properties": { - "code": { - "description": "The error code.", - "type": "string", - "readOnly": true - }, "httpStatusCode": { "description": "The HTTP status code.", "type": "string", "readOnly": true }, - "message": { - "description": "The error message.", - "type": "string", - "readOnly": true - }, "details": { "description": "The error details.", "type": "string", "readOnly": true + }, + "error": { + "type": "object", + "description": "The error object.", + "properties": { + "code": { + "readOnly": true, + "type": "string", + "description": "The error code." + }, + "message": { + "readOnly": true, + "type": "string", + "description": "The error message." + } + } } } }, From 04dfea81cfde6782c40bc85781520f752fa96780 Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Fri, 22 Jul 2022 16:23:07 -0700 Subject: [PATCH 23/42] fixing tag --- specification/iothub/resource-manager/readme.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/specification/iothub/resource-manager/readme.md b/specification/iothub/resource-manager/readme.md index d2c9096e81b3..3e2d305582d9 100644 --- a/specification/iothub/resource-manager/readme.md +++ b/specification/iothub/resource-manager/readme.md @@ -26,14 +26,14 @@ These are the global settings for the IotHub API. ``` yaml openapi-type: arm -tag: package-preview-2022-04 +tag: package-preview-2022-04-30 ``` ### Tag: package-preview-2022-04 -These settings apply only when `--tag=package-preview-2022-04` is specified on the command line. +These settings apply only when `--tag=package-preview-2022-04-30` is specified on the command line. -``` yaml $(tag) == 'package-preview-2022-04' +``` yaml $(tag) == 'package-preview-2022-04-30' input-file: - Microsoft.Devices/preview/2022-04-30-preview/iothub.json ``` From cd3f84e23cc7853b6c8cb564c110687ae44802df Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Fri, 22 Jul 2022 16:37:04 -0700 Subject: [PATCH 24/42] adding Azure-AsyncOperation as header --- specification/iothub/resource-manager/readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification/iothub/resource-manager/readme.md b/specification/iothub/resource-manager/readme.md index 3e2d305582d9..592e7ba4eb63 100644 --- a/specification/iothub/resource-manager/readme.md +++ b/specification/iothub/resource-manager/readme.md @@ -29,7 +29,7 @@ openapi-type: arm tag: package-preview-2022-04-30 ``` -### Tag: package-preview-2022-04 +### Tag: package-preview-2022-04-30 These settings apply only when `--tag=package-preview-2022-04-30` is specified on the command line. From 7bcd8ff461bee197e421902ce17d8aa1710d5fca Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Fri, 22 Jul 2022 16:47:21 -0700 Subject: [PATCH 25/42] fix: adding Azure-AsyncOperation as header --- .../preview/2022-04-30-preview/iothub.json | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 2bdacf83cbb5..8893dfe93db2 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -161,8 +161,10 @@ ], "responses": { "201": { + "headers": { + "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2021-09-01-preview" + }, "description": "This is a long running operation. The operation returns a 201 if the validation is complete. The response includes an Azure-AsyncOperation header that contains a status URL. Clients are expected to poll the status URL for the status of the operation. If successful, the operation returns HTTP status code of 201 (OK).", - "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2022-04-30-preview", "schema": { "$ref": "#/definitions/IotHubDescription" } @@ -269,9 +271,11 @@ } ], "responses": { + "headers": { + "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2021-09-01-preview" + }, "202": { "description": "The Iot Hub resource provider always returns a 202 Accepted status code with valid Location and Retry-After headers. The resource provider also sets the Azure-AsyncOperation header with a URL that points to the operation resource for this operation. Subsequent GET attempts on the resource after a DELETE operation return a resource representation that indicates a transitional provisioning state (such as Terminating). To retrieve the status of the operation, a client can either poll the URL returned in the Location header after the Retry-After interval, get the IoT Hub service status directly, or query the operation resource.", - "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2022-04-30-preview", "schema": { "$ref": "#/definitions/IotHubDescription" } @@ -1952,8 +1956,10 @@ ], "responses": { "201": { + "headers": { + "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2021-09-01-preview" + }, "description": "This is a long running operation. The operation returns a 201 if the validation is complete. The response includes an Azure-AsyncOperation header that contains a status URL. Clients are expected to poll the status URL for the status of the operation. If successful, the operation returns HTTP status code of 201 (OK).", - "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2022-04-30-preview", "schema": { "$ref": "#/definitions/PrivateEndpointConnection" } @@ -2005,8 +2011,10 @@ ], "responses": { "202": { + "headers": { + "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2021-09-01-preview" + }, "description": "This is a long running operation. The operation returns a 202 if the validation is complete. The response includes an Azure-AsyncOperation header that contains a status URL. Clients are expected to poll the status URL for the status of the operation.", - "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2022-04-30-preview", "schema": { "$ref": "#/definitions/PrivateEndpointConnection" } From 51f90c38d910a8e693ca4fdd739474d6b2d59f5b Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Mon, 25 Jul 2022 10:49:24 -0700 Subject: [PATCH 26/42] Fix semantic error --- .../preview/2022-04-30-preview/iothub.json | 20 +++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 8893dfe93db2..6820d1f67580 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -162,7 +162,10 @@ "responses": { "201": { "headers": { - "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2021-09-01-preview" + "Azure-AsyncOperation": { + "description": "URL to query for status of the operation.", + "type": "string" + } }, "description": "This is a long running operation. The operation returns a 201 if the validation is complete. The response includes an Azure-AsyncOperation header that contains a status URL. Clients are expected to poll the status URL for the status of the operation. If successful, the operation returns HTTP status code of 201 (OK).", "schema": { @@ -272,7 +275,10 @@ ], "responses": { "headers": { - "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2021-09-01-preview" + "Azure-AsyncOperation": { + "description": "URL to query for status of the operation.", + "type": "string" + } }, "202": { "description": "The Iot Hub resource provider always returns a 202 Accepted status code with valid Location and Retry-After headers. The resource provider also sets the Azure-AsyncOperation header with a URL that points to the operation resource for this operation. Subsequent GET attempts on the resource after a DELETE operation return a resource representation that indicates a transitional provisioning state (such as Terminating). To retrieve the status of the operation, a client can either poll the URL returned in the Location header after the Retry-After interval, get the IoT Hub service status directly, or query the operation resource.", @@ -1957,7 +1963,10 @@ "responses": { "201": { "headers": { - "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2021-09-01-preview" + "Azure-AsyncOperation": { + "description": "URL to query for status of the operation.", + "type": "string" + } }, "description": "This is a long running operation. The operation returns a 201 if the validation is complete. The response includes an Azure-AsyncOperation header that contains a status URL. Clients are expected to poll the status URL for the status of the operation. If successful, the operation returns HTTP status code of 201 (OK).", "schema": { @@ -2012,7 +2021,10 @@ "responses": { "202": { "headers": { - "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2021-09-01-preview" + "Azure-AsyncOperation": { + "description": "URL to query for status of the operation.", + "type": "string" + } }, "description": "This is a long running operation. The operation returns a 202 if the validation is complete. The response includes an Azure-AsyncOperation header that contains a status URL. Clients are expected to poll the status URL for the status of the operation.", "schema": { From 47d477e033955f406e012edb39e6af4e85bd2e4f Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Mon, 25 Jul 2022 10:58:29 -0700 Subject: [PATCH 27/42] header fix --- .../preview/2022-04-30-preview/iothub.json | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 6820d1f67580..bebdc1aa9f05 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -274,13 +274,13 @@ } ], "responses": { - "headers": { - "Azure-AsyncOperation": { - "description": "URL to query for status of the operation.", - "type": "string" - } - }, "202": { + "headers": { + "Azure-AsyncOperation": { + "description": "URL to query for status of the operation.", + "type": "string" + } + }, "description": "The Iot Hub resource provider always returns a 202 Accepted status code with valid Location and Retry-After headers. The resource provider also sets the Azure-AsyncOperation header with a URL that points to the operation resource for this operation. Subsequent GET attempts on the resource after a DELETE operation return a resource representation that indicates a transitional provisioning state (such as Terminating). To retrieve the status of the operation, a client can either poll the URL returned in the Location header after the Retry-After interval, get the IoT Hub service status directly, or query the operation resource.", "schema": { "$ref": "#/definitions/IotHubDescription" From aeba554f3063e9701447881d3433cbf690f8b74c Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Mon, 25 Jul 2022 11:15:10 -0700 Subject: [PATCH 28/42] adding x-ms-identifiers --- .../Microsoft.Devices/preview/2022-04-30-preview/iothub.json | 1 + 1 file changed, 1 insertion(+) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index bebdc1aa9f05..5e5b44a9600a 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -4489,6 +4489,7 @@ "keyVaultProperties": { "description": "The properties of the KeyVault key.", "type": "array", + "x-ms-identifiers ": [], "items": { "$ref": "#/definitions/KeyVaultKeyProperties" } From 14158c92a84a91e168ee059b8bdfc36bdd917514 Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Mon, 25 Jul 2022 11:34:36 -0700 Subject: [PATCH 29/42] fix --- .../preview/2022-04-30-preview/iothub.json | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 5e5b44a9600a..ec2792f91cd8 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -287,6 +287,12 @@ } }, "200": { + "headers": { + "Azure-AsyncOperation": { + "description": "URL to query for status of the operation.", + "type": "string" + } + }, "description": "This is returned as a response to the status polling request for the delete operation. The body contains the resource representation that indicates a transitional provisioning state.", "schema": { "$ref": "#/definitions/IotHubDescription" @@ -2032,6 +2038,12 @@ } }, "200": { + "headers": { + "Azure-AsyncOperation": { + "description": "URL to query for status of the operation.", + "type": "string" + } + }, "description": "This is returned as a response to the status polling request for the delete operation.", "schema": { "$ref": "#/definitions/PrivateEndpointConnection" @@ -4489,10 +4501,10 @@ "keyVaultProperties": { "description": "The properties of the KeyVault key.", "type": "array", - "x-ms-identifiers ": [], "items": { "$ref": "#/definitions/KeyVaultKeyProperties" - } + }, + "x-ms-identifiers ": ["keyIdentifier"] } } }, From a237dd07dbf113a8716f5539b3b0558e830c6d59 Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Mon, 25 Jul 2022 11:43:01 -0700 Subject: [PATCH 30/42] fix --- .../Microsoft.Devices/preview/2022-04-30-preview/iothub.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index ec2792f91cd8..bd88b46472c0 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -4504,7 +4504,7 @@ "items": { "$ref": "#/definitions/KeyVaultKeyProperties" }, - "x-ms-identifiers ": ["keyIdentifier"] + "x-ms-identifiers": ["keyIdentifier"] } } }, From 998bac51824609cbf11565e50f9bff8bffe10601 Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Mon, 25 Jul 2022 13:22:48 -0700 Subject: [PATCH 31/42] prettier fix --- .../Microsoft.Devices/preview/2022-04-30-preview/iothub.json | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index bd88b46472c0..2b3f4f588f75 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -4504,7 +4504,9 @@ "items": { "$ref": "#/definitions/KeyVaultKeyProperties" }, - "x-ms-identifiers": ["keyIdentifier"] + "x-ms-identifiers": [ + "keyIdentifier" + ] } } }, From 8388c98142628b4241a68f3ee38c148067720d7f Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Mon, 25 Jul 2022 13:32:33 -0700 Subject: [PATCH 32/42] Azure-Async header position testing --- .../preview/2022-04-30-preview/iothub.json | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 2b3f4f588f75..8c531d002e59 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -2025,13 +2025,13 @@ } ], "responses": { + "headers": { + "Azure-AsyncOperation": { + "description": "URL to query for status of the operation.", + "type": "string" + } + }, "202": { - "headers": { - "Azure-AsyncOperation": { - "description": "URL to query for status of the operation.", - "type": "string" - } - }, "description": "This is a long running operation. The operation returns a 202 if the validation is complete. The response includes an Azure-AsyncOperation header that contains a status URL. Clients are expected to poll the status URL for the status of the operation.", "schema": { "$ref": "#/definitions/PrivateEndpointConnection" From 42960e956eecaccfc47c871e4adcc0b8c9204191 Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Mon, 25 Jul 2022 17:15:41 -0700 Subject: [PATCH 33/42] re-trigger stuck queue validation jobs --- .../Microsoft.Devices/preview/2022-04-30-preview/iothub.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 8c531d002e59..589396ee9337 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -364,7 +364,7 @@ "GET" ], "summary": "Get all the IoT hubs in a resource group", - "description": "Get all the IoT hubs in a resource group.", + "description": "Get all the IoT Hubs in a resource group.", "operationId": "IotHubResource_ListByResourceGroup", "x-ms-examples": { "IotHubResource_ListByResourceGroup": { From 8a10eaacb25276587d26cc52a30b40ec5fb0c7ba Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Mon, 25 Jul 2022 17:27:32 -0700 Subject: [PATCH 34/42] revert change --- .../preview/2022-04-30-preview/iothub.json | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 589396ee9337..af87f794e4b6 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -364,7 +364,7 @@ "GET" ], "summary": "Get all the IoT hubs in a resource group", - "description": "Get all the IoT Hubs in a resource group.", + "description": "Get all the IoT hubs in a resource group.", "operationId": "IotHubResource_ListByResourceGroup", "x-ms-examples": { "IotHubResource_ListByResourceGroup": { @@ -2025,12 +2025,6 @@ } ], "responses": { - "headers": { - "Azure-AsyncOperation": { - "description": "URL to query for status of the operation.", - "type": "string" - } - }, "202": { "description": "This is a long running operation. The operation returns a 202 if the validation is complete. The response includes an Azure-AsyncOperation header that contains a status URL. Clients are expected to poll the status URL for the status of the operation.", "schema": { From 97ce1b21cbf02187a83ce31bc355cde54543fe34 Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Tue, 26 Jul 2022 16:23:40 -0700 Subject: [PATCH 35/42] testing Azure AsyncOperation header --- .../preview/2022-04-30-preview/iothub.json | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index af87f794e4b6..41ae47d94971 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -299,6 +299,12 @@ } }, "204": { + "headers": { + "Azure-AsyncOperation": { + "description": "URL to query for status of the operation.", + "type": "string" + } + }, "description": "Once the long running delete operation completes successfully, a 204 No Content status code is returned when the status polling request finds the Iot hub metadata in the service and the status of the delete operation is set to a completed state." }, "404": { @@ -2026,6 +2032,12 @@ ], "responses": { "202": { + "headers": { + "Azure-AsyncOperation": { + "description": "URL to query for status of the operation.", + "type": "string" + } + }, "description": "This is a long running operation. The operation returns a 202 if the validation is complete. The response includes an Azure-AsyncOperation header that contains a status URL. Clients are expected to poll the status URL for the status of the operation.", "schema": { "$ref": "#/definitions/PrivateEndpointConnection" @@ -2044,6 +2056,12 @@ } }, "204": { + "headers": { + "Azure-AsyncOperation": { + "description": "URL to query for status of the operation.", + "type": "string" + } + }, "description": "PrivateEndpoint does not exist." }, "default": { From 7f7d724a9da58f0c5af5958fbc6c6e62329eaf3d Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Tue, 26 Jul 2022 16:32:28 -0700 Subject: [PATCH 36/42] Adding Azure-AsyncOperation to other possible place to mitigate the error --- .../preview/2022-04-30-preview/iothub.json | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 41ae47d94971..2ef5893c39d9 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -233,6 +233,12 @@ ], "responses": { "200": { + "headers": { + "Azure-AsyncOperation": { + "description": "URL to query for status of the operation.", + "type": "string" + } + }, "description": "Iot Hub was successfully updated", "schema": { "$ref": "#/definitions/IotHubDescription" From 9139f8829550b8a917d2b62f2cecf3febb9a5fc6 Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Tue, 26 Jul 2022 16:40:21 -0700 Subject: [PATCH 37/42] make small change to retrigger the check queue --- .../Microsoft.Devices/preview/2022-04-30-preview/iothub.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 2ef5893c39d9..c8f884f5e841 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -192,7 +192,7 @@ "PATCH" ], "summary": "Update an existing IoT Hubs tags.", - "description": "Update an existing IoT Hub tags. to update other fields use the CreateOrUpdate method", + "description": "Update an existing IoT Hub tag. to update other fields use the CreateOrUpdate method", "x-ms-long-running-operation": true, "operationId": "IotHubResource_Update", "x-ms-examples": { From 37eccbc86e8d2d6667fafd2805af5c52857bb743 Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Wed, 27 Jul 2022 09:42:44 -0700 Subject: [PATCH 38/42] Adding Async Operation header to the examples. --- .../examples/iothub_delete.json | 6 +++ ...othub_deleteprivateendpointconnection.json | 6 +++ .../preview/2022-04-30-preview/iothub.json | 37 ++++--------------- 3 files changed, 19 insertions(+), 30 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_delete.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_delete.json index d5bfef77c95a..04e23102638f 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_delete.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_delete.json @@ -7,6 +7,9 @@ }, "responses": { "200": { + "headers": { + "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2022-04-30-preview" + }, "body": { "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/IotHubs/testHub", "name": "testHub", @@ -113,6 +116,9 @@ }, "204": {}, "202": { + "headers": { + "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2022-04-30-preview" + }, "body": { "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/IotHubs/testHub", "name": "testHub", diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteprivateendpointconnection.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteprivateendpointconnection.json index f20fcdb99268..9d60a416d74a 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteprivateendpointconnection.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/examples/iothub_deleteprivateendpointconnection.json @@ -8,6 +8,9 @@ }, "responses": { "200": { + "headers": { + "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2022-04-30-preview" + }, "body": { "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/IotHubs/testHub/PrivateEndpointConnections/myPrivateEndpointConnection", "name": "myPrivateEndpointConnection", @@ -25,6 +28,9 @@ } }, "202": { + "headers": { + "Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000/Spring/default?api-version=2022-04-30-preview" + }, "body": { "id": "/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/IotHubs/testHub/PrivateEndpointConnections/myPrivateEndpointConnection", "name": "myPrivateEndpointConnection", diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index c8f884f5e841..3a82c68e18a7 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -192,7 +192,7 @@ "PATCH" ], "summary": "Update an existing IoT Hubs tags.", - "description": "Update an existing IoT Hub tag. to update other fields use the CreateOrUpdate method", + "description": "Update an existing IoT Hub tags. to update other fields use the CreateOrUpdate method", "x-ms-long-running-operation": true, "operationId": "IotHubResource_Update", "x-ms-examples": { @@ -293,24 +293,12 @@ } }, "200": { - "headers": { - "Azure-AsyncOperation": { - "description": "URL to query for status of the operation.", - "type": "string" - } - }, "description": "This is returned as a response to the status polling request for the delete operation. The body contains the resource representation that indicates a transitional provisioning state.", "schema": { "$ref": "#/definitions/IotHubDescription" } }, "204": { - "headers": { - "Azure-AsyncOperation": { - "description": "URL to query for status of the operation.", - "type": "string" - } - }, "description": "Once the long running delete operation completes successfully, a 204 No Content status code is returned when the status polling request finds the Iot hub metadata in the service and the status of the delete operation is set to a completed state." }, "404": { @@ -2050,24 +2038,12 @@ } }, "200": { - "headers": { - "Azure-AsyncOperation": { - "description": "URL to query for status of the operation.", - "type": "string" - } - }, "description": "This is returned as a response to the status polling request for the delete operation.", "schema": { "$ref": "#/definitions/PrivateEndpointConnection" } }, "204": { - "headers": { - "Azure-AsyncOperation": { - "description": "URL to query for status of the operation.", - "type": "string" - } - }, "description": "PrivateEndpoint does not exist." }, "default": { @@ -4388,7 +4364,10 @@ "type": "string" }, "inputBlobName": { - "description": "The blob name to be used when importing from the provided input blob container.", + "descrip "x-ms-identifiers": [ + "keyIdentifier" + ] +from the provided input blob container.", "type": "string" }, "outputBlobName": { @@ -4464,7 +4443,7 @@ "type": "object", "properties": { "principalId": { - "description": "Principal Id", + "desiption": "Principal Id s", "type": "string", "readOnly": true }, @@ -4522,9 +4501,7 @@ "items": { "$ref": "#/definitions/KeyVaultKeyProperties" }, - "x-ms-identifiers": [ - "keyIdentifier" - ] + "x-ms-identifiers": ["keyIdentifier"] } } }, From 4652054a02e3d57940850d9cb44316f4b216d1d6 Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Wed, 27 Jul 2022 09:56:42 -0700 Subject: [PATCH 39/42] fix format --- .../preview/2022-04-30-preview/iothub.json | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 3a82c68e18a7..f3a9da018fe5 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -4364,10 +4364,7 @@ "type": "string" }, "inputBlobName": { - "descrip "x-ms-identifiers": [ - "keyIdentifier" - ] -from the provided input blob container.", + "description": "from the provided input blob container.", "type": "string" }, "outputBlobName": { @@ -4441,9 +4438,9 @@ from the provided input blob container.", }, "ArmIdentity": { "type": "object", - "properties": { + "propties": { "principalId": { - "desiption": "Principal Id s", + "description": "Principal Id", "type": "string", "readOnly": true }, @@ -4501,7 +4498,9 @@ from the provided input blob container.", "items": { "$ref": "#/definitions/KeyVaultKeyProperties" }, - "x-ms-identifiers": ["keyIdentifier"] + "x-ms-identifiers": [ + "keyIdentifier" + ] } } }, From 5d520568fcd17dc7aa0b8df27d14f7281c3484c1 Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Wed, 27 Jul 2022 10:16:58 -0700 Subject: [PATCH 40/42] Typo fix --- .../Microsoft.Devices/preview/2022-04-30-preview/iothub.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index f3a9da018fe5..9d636f1557bc 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -4438,7 +4438,7 @@ }, "ArmIdentity": { "type": "object", - "propties": { + "properties": { "principalId": { "description": "Principal Id", "type": "string", From 845c26ba3af5e6f2e4f3bbfffee623c1682e604c Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Wed, 27 Jul 2022 11:15:59 -0700 Subject: [PATCH 41/42] revert the change of error details schema --- .../preview/2022-04-30-preview/iothub.json | 26 +++++++------------ 1 file changed, 10 insertions(+), 16 deletions(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 9d636f1557bc..8f6721a18d43 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -3554,31 +3554,25 @@ "description": "Error details.", "type": "object", "properties": { + "code": { + "description": "The error code.", + "type": "string", + "readOnly": true + }, "httpStatusCode": { "description": "The HTTP status code.", "type": "string", "readOnly": true }, + "message": { + "description": "The error message.", + "type": "string", + "readOnly": true + }, "details": { "description": "The error details.", "type": "string", "readOnly": true - }, - "error": { - "type": "object", - "description": "The error object.", - "properties": { - "code": { - "readOnly": true, - "type": "string", - "description": "The error code." - }, - "message": { - "readOnly": true, - "type": "string", - "description": "The error message." - } - } } } }, From 8827e4e3f3ce528c8c690761b01fc561e96600c7 Mon Sep 17 00:00:00 2001 From: Chris Huang Date: Wed, 3 Aug 2022 15:59:15 -0700 Subject: [PATCH 42/42] Revert unwanted changes --- .../Microsoft.Devices/preview/2022-04-30-preview/iothub.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json index 8f6721a18d43..36e924479988 100644 --- a/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json +++ b/specification/iothub/resource-manager/Microsoft.Devices/preview/2022-04-30-preview/iothub.json @@ -4358,7 +4358,7 @@ "type": "string" }, "inputBlobName": { - "description": "from the provided input blob container.", + "description": "The blob name to be used when importing from the provided input blob container.", "type": "string" }, "outputBlobName": {