{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/azure-health/json-schema/azure-health-iot-connector-collection-schema.json",
  "title": "IotConnectorCollection",
  "description": "A collection of IoT Connectors.",
  "x-generated": "2026-11-05",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/azure-health-iotconnectors-api-openapi.yml#/components/schemas/IotConnectorCollection",
  "type": "object",
  "properties": {
    "nextLink": {
      "description": "The link used to get the next page of IoT Connectors.",
      "type": "string"
    },
    "value": {
      "description": "The list of IoT Connectors.",
      "type": "array",
      "items": {
        "$ref": "#/$defs/IotConnector"
      }
    }
  },
  "$defs": {
    "IotConnector": {
      "type": "object",
      "description": "IoT Connector definition.",
      "allOf": [
        {
          "$ref": "#/$defs/TaggedResource"
        },
        {
          "$ref": "#/$defs/ServiceManagedIdentity"
        }
      ],
      "properties": {
        "properties": {
          "description": "IoT Connector configuration.",
          "$ref": "#/$defs/IotConnectorProperties",
          "x-ms-client-flatten": true
        },
        "systemData": {
          "description": "Metadata pertaining to creation and last modification of the resource.",
          "$ref": "#/$defs/systemData"
        }
      }
    },
    "IotConnectorProperties": {
      "description": "IoT Connector properties.",
      "type": "object",
      "properties": {
        "provisioningState": {
          "description": "The provisioning state.",
          "$ref": "#/$defs/ProvisioningState"
        },
        "ingestionEndpointConfiguration": {
          "description": "Source configuration.",
          "$ref": "#/$defs/IotEventHubIngestionEndpointConfiguration"
        },
        "deviceMapping": {
          "description": "Device Mappings.",
          "$ref": "#/$defs/IotMappingProperties"
        }
      }
    },
    "IotEventHubIngestionEndpointConfiguration": {
      "type": "object",
      "properties": {
        "eventHubName": {
          "type": "string",
          "description": "Event Hub name to connect to."
        },
        "consumerGroup": {
          "type": "string",
          "description": "Consumer group of the event hub to connected to."
        },
        "fullyQualifiedEventHubNamespace": {
          "type": "string",
          "description": "Fully qualified namespace of the Event Hub to connect to."
        }
      },
      "description": "Event Hub ingestion endpoint configuration"
    },
    "IotMappingProperties": {
      "description": "The mapping content.",
      "type": "object",
      "properties": {
        "content": {
          "description": "The mapping.",
          "type": "object"
        }
      }
    },
    "LocationBasedResource": {
      "type": "object",
      "description": "The common properties for any location based resource, tracked or proxy.",
      "allOf": [
        {
          "$ref": "#/$defs/ResourceCore"
        }
      ],
      "properties": {
        "location": {
          "type": "string",
          "description": "The resource location.",
          "x-ms-mutability": [
            "create",
            "read"
          ]
        }
      },
      "x-ms-azure-resource": true
    },
    "ProvisioningState": {
      "description": "The provisioning state.",
      "enum": [
        "Deleting",
        "Succeeded",
        "Creating",
        "Accepted",
        "Verifying",
        "Updating",
        "Failed",
        "Canceled",
        "Deprovisioned",
        "Moving",
        "Suspended",
        "Warned",
        "SystemMaintenance"
      ],
      "type": "string",
      "readOnly": true,
      "x-ms-enum": {
        "name": "provisioningState",
        "modelAsString": true
      }
    },
    "ResourceCore": {
      "type": "object",
      "description": "The common properties for any resource, tracked or proxy.",
      "properties": {
        "id": {
          "readOnly": true,
          "type": "string",
          "description": "The resource identifier."
        },
        "name": {
          "readOnly": true,
          "type": "string",
          "description": "The resource name.",
          "pattern": "^[a-z0-9][a-z0-9-]{1,21}[a-z0-9]$"
        },
        "type": {
          "readOnly": true,
          "type": "string",
          "description": "The resource type."
        },
        "etag": {
          "description": "An etag associated with the resource, used for optimistic concurrency when editing it.",
          "type": "string"
        }
      },
      "x-ms-azure-resource": true
    },
    "ResourceTags": {
      "type": "object",
      "description": "List of key value pairs that describe the resource. This will overwrite the existing tags.",
      "properties": {
        "tags": {
          "type": "object",
          "additionalProperties": {
            "type": "string"
          },
          "x-ms-mutability": [
            "read",
            "create",
            "update"
          ],
          "description": "Resource tags."
        }
      }
    },
    "ServiceManagedIdentity": {
      "type": "object",
      "description": "Managed service identity (system assigned and/or user assigned identities)",
      "properties": {
        "identity": {
          "type": "object",
          "description": "Setting indicating whether the service has a managed identity associated with it.",
          "properties": {
            "type": {
              "description": "Type of identity being specified, currently SystemAssigned and None are allowed.",
              "type": "string",
              "enum": [
                "None",
                "SystemAssigned",
                "UserAssigned",
                "SystemAssigned,UserAssigned"
              ],
              "x-ms-enum": {
                "name": "ServiceManagedIdentityType",
                "modelAsString": true
              }
            },
            "principalId": {
              "readOnly": true,
              "format": "uuid",
              "type": "string",
              "description": "The service principal ID of the system assigned identity. This property will only be provided for a system assigned identity."
            },
            "tenantId": {
              "readOnly": true,
              "format": "uuid",
              "type": "string",
              "description": "The tenant ID of the system assigned identity. This property will only be provided for a system assigned identity."
            },
            "userAssignedIdentities": {
              "$ref": "#/$defs/UserAssignedIdentities"
            }
          },
          "required": [
            "type"
          ]
        }
      }
    },
    "TaggedResource": {
      "type": "object",
      "description": "The common properties of tracked resources in the service.",
      "allOf": [
        {
          "$ref": "#/$defs/ResourceTags"
        },
        {
          "$ref": "#/$defs/LocationBasedResource"
        }
      ],
      "x-ms-azure-resource": true
    },
    "UserAssignedIdentities": {
      "title": "User-Assigned Identities",
      "description": "The set of user assigned identities associated with the resource. The userAssignedIdentities dictionary keys will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}. The dictionary values can be empty objects ({}) in requests.",
      "type": "object",
      "additionalProperties": {
        "$ref": "#/$defs/UserAssignedIdentity"
      }
    },
    "UserAssignedIdentity": {
      "type": "object",
      "description": "User assigned identity properties",
      "properties": {
        "principalId": {
          "description": "The principal ID of the assigned identity.",
          "format": "uuid",
          "type": "string",
          "readOnly": true
        },
        "clientId": {
          "description": "The client ID of the assigned identity.",
          "format": "uuid",
          "type": "string",
          "readOnly": true
        }
      }
    },
    "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)"
        }
      }
    }
  }
}