Bicep 資源定義
namespaces/discoveredAssets 資源型別可以使用以下列為目標的作業來部署:
如需每個 API 版本中已變更屬性的清單,請參閱 變更記錄檔。
創造一個 Microsoft。DeviceRegistry/namespaces/discoveredAssets 資源,請將以下 Bicep 加入你的範本。
resource symbolicname 'Microsoft.DeviceRegistry/namespaces/discoveredAssets@2026-11-01-preview' = {
parent: resourceSymbolicName
extendedLocation: {
name: 'string'
type: 'string'
}
location: 'string'
name: 'string'
properties: {
assetTypeRefs: [
'string'
]
attributes: {
{customized property}: any(...)
}
datasets: [
{
dataPoints: [
{
dataPointConfiguration: 'string'
dataSource: 'string'
lastUpdatedOn: 'string'
name: 'string'
typeRef: 'string'
}
]
datasetConfiguration: 'string'
dataSource: 'string'
destinations: [
{
target: 'string'
// For remaining properties, see DatasetDestination objects
}
]
lastUpdatedOn: 'string'
name: 'string'
typeRef: 'string'
}
]
defaultDatasetsConfiguration: 'string'
defaultDatasetsDestinations: [
{
target: 'string'
// For remaining properties, see DatasetDestination objects
}
]
defaultEventsConfiguration: 'string'
defaultEventsDestinations: [
{
target: 'string'
// For remaining properties, see EventDestination objects
}
]
defaultManagementGroupsConfiguration: 'string'
defaultStreamsConfiguration: 'string'
defaultStreamsDestinations: [
{
target: 'string'
// For remaining properties, see StreamDestination objects
}
]
description: 'string'
deviceRef: {
deviceName: 'string'
endpointName: 'string'
}
discoveryId: 'string'
displayName: 'string'
documentationUri: 'string'
eventGroups: [
{
dataSource: 'string'
defaultDestinations: [
{
target: 'string'
// For remaining properties, see EventDestination objects
}
]
eventGroupConfiguration: 'string'
events: [
{
dataSource: 'string'
destinations: [
{
target: 'string'
// For remaining properties, see EventDestination objects
}
]
eventConfiguration: 'string'
lastUpdatedOn: 'string'
name: 'string'
typeRef: 'string'
}
]
name: 'string'
typeRef: 'string'
}
]
externalAssetId: 'string'
hardwareRevision: 'string'
managementGroups: [
{
actions: [
{
actionConfiguration: 'string'
actionType: 'string'
lastUpdatedOn: 'string'
name: 'string'
targetUri: 'string'
timeoutInSeconds: int
topic: 'string'
typeRef: 'string'
}
]
dataSource: 'string'
defaultTimeoutInSeconds: int
defaultTopic: 'string'
lastUpdatedOn: 'string'
managementGroupConfiguration: 'string'
name: 'string'
typeRef: 'string'
}
]
manufacturer: 'string'
manufacturerUri: 'string'
model: 'string'
productCode: 'string'
serialNumber: 'string'
softwareRevision: 'string'
streams: [
{
destinations: [
{
target: 'string'
// For remaining properties, see StreamDestination objects
}
]
lastUpdatedOn: 'string'
name: 'string'
streamConfiguration: 'string'
typeRef: 'string'
}
]
version: int
}
tags: {
{customized property}: 'string'
}
}
StreamDestination 物件
設置 target 屬性以指定物件的類型。
對於 Mqtt,請使用:
{
configuration: {
qos: 'string'
retain: 'string'
topic: 'string'
ttl: int
}
target: 'Mqtt'
}
對於 存儲,請使用:
{
configuration: {
path: 'string'
}
target: 'Storage'
}
EventDestination 物件
設置 target 屬性以指定物件的類型。
對於 Mqtt,請使用:
{
configuration: {
qos: 'string'
retain: 'string'
topic: 'string'
ttl: int
}
target: 'Mqtt'
}
對於 存儲,請使用:
{
configuration: {
path: 'string'
}
target: 'Storage'
}
DatasetDestination 物件
設置 target 屬性以指定物件的類型。
對於 BrokerStateStore,請使用:
{
configuration: {
key: 'string'
}
target: 'BrokerStateStore'
}
對於 Mqtt,請使用:
{
configuration: {
qos: 'string'
retain: 'string'
topic: 'string'
ttl: int
}
target: 'Mqtt'
}
對於 存儲,請使用:
{
configuration: {
path: 'string'
}
target: 'Storage'
}
屬性值
Microsoft。DeviceRegistry/namespaces/discoveredAssets
| 名稱 |
說明 |
價值 |
| extendedLocation |
擴充位置。 |
ExtendedLocation (必要) |
| 位置 |
資源所在的地理位置 |
字串 (必要) |
| 名字 |
資源名稱 |
string
Constraints: 最小長度 = 3 最大長度 = 63 模式 = ^[a-z0-9][a-z0-9-]*[a-z0-9]$ (必要) |
| 父代 |
在 Bicep 中,你可以指定子資源的父資源。 只有在父資源外部宣告子資源時,才需要新增這個屬性。
如需詳細資訊,請參閱 父資源外部的子資源。 |
類型的資源符號名稱:命名空間 |
| 屬性 |
此資源的資源特定屬性。 |
命名空間發現資產屬性 |
| tags |
資源標籤 |
標記名稱和值的字典。 請參閱範本中的標籤 |
BrokerStateStoreDestinationConfiguration
| 名稱 |
說明 |
價值 |
| Key |
MQTT 代理狀態儲存目標金鑰。 |
字串 (必要) |
數據集BrokerStateStoreDestination
數據集目標
數據集MqttDestination
數據集存儲目標
設備參考
| 名稱 |
說明 |
價值 |
| 裝置名稱 |
設備資源的名稱 |
字串 (必要) |
| endpointName |
要使用的 endpoint 的名稱 |
字串 (必要) |
事件目的地
事件Mqtt目的地
事件存儲目標
ExtendedLocation
| 名稱 |
說明 |
價值 |
| 名字 |
擴充位置名稱。 |
字串 (必要) |
| 型別 |
擴充位置類型。 |
字串 (必要) |
MqttDestinationConfiguration
| 名稱 |
說明 |
價值 |
| QoS |
MQTT QoS 設置。 預設為 QoS 1。 |
'Qos0' “Qos1” |
| retain |
當設定為 [保留] 時,發佈至 MQTT 訊息代理程式的訊息將會設定保留旗標。 預設值:『Never』。 |
'Keep' 'Never' |
| 主題 |
MQTT 主題。 |
字串 (必要) |
| ttl |
MQTT TTL 設置。 |
int |
命名空間發現資產屬性
| 名稱 |
說明 |
價值 |
| assetTypeRefs |
URI 或類型定義ID。 |
字串[] |
| attributes |
一組包含自定義屬性的鍵值對。 |
NamespaceDiscoveredAssetProperties屬性 |
| 數據集 |
屬於資產一部分的數據集陣列。 每個數據集規格都會描述組成集合的數據點。 |
命名空間發現資料集[] |
| defaultDatasetsConfiguration |
字串化 JSON,其中包含所有數據集的連接器特定預設組態。 每個數據集都可以有自己的組態來覆寫這裡的預設設定。 |
字串 |
| defaultDatasets目標 |
數據集的預設目標。 |
資料集目的地[] |
| defaultEventsConfiguration |
字串化 JSON,其中包含所有事件的連接器特定預設組態。 每個事件都可以有自己的組態來覆寫這裡的預設設定。 |
字串 |
| defaultEventsDestinations (預設事件目標) |
事件的預設目標。 |
事件目的地[] |
| defaultManagementGroups配置 |
字串化的 JSON,其中包含所有管理組的特定於連接器的預設配置。 每個管理組都可以有自己的配置,該配置將覆蓋此處的預設設置。 |
字串 |
| defaultStreams配置 |
字串化的 JSON,其中包含所有流的特定於連接器的預設配置。 每個流都可以有自己的配置,該配置將覆蓋此處的預設設置。 |
字串 |
| defaultStreamsDestinations (預設流目標) |
流的默認目標。 |
流目的地[] |
| 描述 |
資產的人類可讀取描述。 |
字串 |
| 設備引用 |
對此資產提供數據的設備的引用。 必須在設備上提供設備名稱和端點才能使用。 |
DeviceRef (必填) |
| discoveryId |
用來偵測資產變更的標識碼。 |
字串 (必要) |
| 顯示名稱 |
人類可讀取的顯示名稱。 |
字串 |
| documentationUri |
資產文件參考。 |
字串 |
| 事件群組 |
屬於資產一部分的事件群組陣列。 每個事件群組都可以有每個事件群組設定。 |
命名空間發現事件組[] |
| externalAssetId |
客戶提供的資產ID。 |
字串 |
| hardwareRevision |
資產硬體修訂號。 |
字串 |
| managementGroups |
屬於資產的管理組陣列。 每個管理組都可以具有每組配置。 |
命名空間發現管理組[] |
| 製造商 |
資產製造商。 |
字串 |
| manufacturerUri |
資產製造商 URI。 |
字串 |
| 型號 |
資產模型。 |
字串 |
| productCode |
資產產品代碼。 |
字串 |
| serialNumber |
資產序號。 |
字串 |
| softwareRevision |
資產軟體修訂號。 |
字串 |
| streams |
屬於資產的流陣列。 每個流都可以具有每個流的配置。 |
命名空間發現流[] |
| 版本 |
每次修改資源時遞增的整數。 |
int (必要) |
NamespaceDiscoveredAssetProperties屬性
命名空間發現數據集
| 名稱 |
說明 |
價值 |
| dataPoints |
屬於數據集一部分的數據點陣列。 每個數據點可以有每個數據點組態。 |
命名空間發現資料集數據點[] |
| datasetConfiguration |
字串化 JSON,其中包含描述特定數據集組態的連接器特定屬性。 |
字串 |
| dataSource |
對給定數據集的數據源的引用。 |
字串 |
| destinations |
數據集的目標。 |
資料集目的地[] |
| lastUpdatedOn |
時間戳 (UTC) 指示添加或修改資料集的時間。 |
字串 |
| 名字 |
資料集的名稱。 |
字串 (必要) |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
NamespaceDiscoveredDatasetDataPoint
| 名稱 |
說明 |
價值 |
| dataPointConfiguration |
字串化 JSON,其中包含數據點的連接器特定組態。 針對 OPC UA,這可能包括設定,例如 publishingInterval、samplingInterval 和 queueSize。 |
字串 |
| dataSource |
資產中數據源的位址(例如 URL),讓用戶端可以存取資產上的資料源。 |
字串 (必要) |
| lastUpdatedOn |
UTC 時間戳,指出何時新增或修改數據點。 |
字串 |
| 名字 |
數據點的名稱。 |
字串 (必要) |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
命名空間發現事件
| 名稱 |
說明 |
價值 |
| dataSource |
對指定事件的資料來源的參照。 |
字串 |
| destinations |
事件的目標。 |
事件目的地[] |
| eventConfiguration |
包含事件連接器特定組態的字串化 JSON。 針對 OPC UA,這可能包括設定,例如 publishingInterval、samplingInterval 和 queueSize。 |
字串 |
| lastUpdatedOn |
UTC 時間戳,指出事件新增或修改時間。 |
字串 |
| 名字 |
事件的名稱。 |
字串 (必要) |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
命名空間發現事件群組
| 名稱 |
說明 |
價值 |
| dataSource |
資產中事件群組的通知者位址(例如 URL),以便用戶端可以存取資產上的事件群組。 |
字串 |
| 預設目的地 |
活動目的地。 未在事件層級定義目的地時的預設目的地。 |
事件目的地[] |
| eventGroup組態 |
字串化 JSON,其中包含事件群組的連接器特定設定。 針對 OPC UA,這可能包括設定,例如 publishingInterval、samplingInterval 和 queueSize。 |
字串 |
| events |
屬於事件群組的事件陣列。 |
命名空間發現事件[] |
| 名字 |
事件群組的名稱。 |
字串 (必要) |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
NamespaceDiscoveredManagementAction
| 名稱 |
說明 |
價值 |
| actionConfiguration |
字串化的 JSON,其中包含作的連接器特定配置。 |
字串 |
| actionType |
動作的類型。 |
呼叫” 'Read' 'Write' |
| lastUpdatedOn |
時間戳 (UTC) 指示添加或修改管理作的時間。 |
字串 |
| 名字 |
動作的名稱。 |
字串 (必要) |
| targetUri |
用戶端可以調用特定作的目標URI。 |
字串 (必要) |
| timeoutInSeconds |
作的回應超時。 |
int |
| 主題 |
用戶端將接收作請求的 MQTT 主題路徑。 |
字串 |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
命名空間發現管理組
| 名稱 |
說明 |
價值 |
| 行為 |
屬於管理組的作陣列。 每個作都可以有單獨的配置。 |
NamespaceDiscoveredManagementAction[] |
| dataSource |
對指定管理群組的資料來源的參考。 |
字串 |
| defaultTimeoutInSeconds |
屬於管理組的所有作的預設回應超時。 |
int |
| defaultTopic |
預設 MQTT 主題路徑,用戶端將在其上接收屬於管理組的所有作的請求。 |
字串 |
| lastUpdatedOn |
時間戳 (UTC) 指示添加或修改管理組的時間。 |
字串 |
| managementGroup配置 |
字串化的 JSON,其中包含管理組的特定於連接器的配置。 |
字串 |
| 名字 |
管理群組的名稱。 |
字串 (必要) |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
命名空間發現流
| 名稱 |
說明 |
價值 |
| destinations |
流的目標。 |
流目的地[] |
| lastUpdatedOn |
時間戳 (UTC) 指示添加或修改流的時間。 |
字串 |
| 名字 |
流定義的名稱。 |
字串 (必要) |
| 流配置 |
字串化 JSON,其中包含特定流的特定於連接器的配置。 |
字串 |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
存儲目標配置
| 名稱 |
說明 |
價值 |
| 路徑 |
存儲目標路徑。 |
字串 (必要) |
流目標
StreamMqtt目的地
流存儲目標
ARM 樣本資源定義
namespaces/discoveredAssets 資源型別可以使用以下列為目標的作業來部署:
如需每個 API 版本中已變更屬性的清單,請參閱 變更記錄檔。
創造一個 Microsoft。DeviceRegistry/namespaces/discoveredAssets 資源,將以下 JSON 加入你的範本。
{
"type": "Microsoft.DeviceRegistry/namespaces/discoveredAssets",
"apiVersion": "2026-11-01-preview",
"name": "string",
"extendedLocation": {
"name": "string",
"type": "string"
},
"location": "string",
"properties": {
"assetTypeRefs": [ "string" ],
"attributes": {
"{customized property}": {}
},
"datasets": [
{
"dataPoints": [
{
"dataPointConfiguration": "string",
"dataSource": "string",
"lastUpdatedOn": "string",
"name": "string",
"typeRef": "string"
}
],
"datasetConfiguration": "string",
"dataSource": "string",
"destinations": [ {
"target": "string"
// For remaining properties, see DatasetDestination objects
} ],
"lastUpdatedOn": "string",
"name": "string",
"typeRef": "string"
}
],
"defaultDatasetsConfiguration": "string",
"defaultDatasetsDestinations": [ {
"target": "string"
// For remaining properties, see DatasetDestination objects
} ],
"defaultEventsConfiguration": "string",
"defaultEventsDestinations": [ {
"target": "string"
// For remaining properties, see EventDestination objects
} ],
"defaultManagementGroupsConfiguration": "string",
"defaultStreamsConfiguration": "string",
"defaultStreamsDestinations": [ {
"target": "string"
// For remaining properties, see StreamDestination objects
} ],
"description": "string",
"deviceRef": {
"deviceName": "string",
"endpointName": "string"
},
"discoveryId": "string",
"displayName": "string",
"documentationUri": "string",
"eventGroups": [
{
"dataSource": "string",
"defaultDestinations": [ {
"target": "string"
// For remaining properties, see EventDestination objects
} ],
"eventGroupConfiguration": "string",
"events": [
{
"dataSource": "string",
"destinations": [ {
"target": "string"
// For remaining properties, see EventDestination objects
} ],
"eventConfiguration": "string",
"lastUpdatedOn": "string",
"name": "string",
"typeRef": "string"
}
],
"name": "string",
"typeRef": "string"
}
],
"externalAssetId": "string",
"hardwareRevision": "string",
"managementGroups": [
{
"actions": [
{
"actionConfiguration": "string",
"actionType": "string",
"lastUpdatedOn": "string",
"name": "string",
"targetUri": "string",
"timeoutInSeconds": "int",
"topic": "string",
"typeRef": "string"
}
],
"dataSource": "string",
"defaultTimeoutInSeconds": "int",
"defaultTopic": "string",
"lastUpdatedOn": "string",
"managementGroupConfiguration": "string",
"name": "string",
"typeRef": "string"
}
],
"manufacturer": "string",
"manufacturerUri": "string",
"model": "string",
"productCode": "string",
"serialNumber": "string",
"softwareRevision": "string",
"streams": [
{
"destinations": [ {
"target": "string"
// For remaining properties, see StreamDestination objects
} ],
"lastUpdatedOn": "string",
"name": "string",
"streamConfiguration": "string",
"typeRef": "string"
}
],
"version": "int"
},
"tags": {
"{customized property}": "string"
}
}
StreamDestination 物件
設置 target 屬性以指定物件的類型。
對於 Mqtt,請使用:
{
"configuration": {
"qos": "string",
"retain": "string",
"topic": "string",
"ttl": "int"
},
"target": "Mqtt"
}
對於 存儲,請使用:
{
"configuration": {
"path": "string"
},
"target": "Storage"
}
EventDestination 物件
設置 target 屬性以指定物件的類型。
對於 Mqtt,請使用:
{
"configuration": {
"qos": "string",
"retain": "string",
"topic": "string",
"ttl": "int"
},
"target": "Mqtt"
}
對於 存儲,請使用:
{
"configuration": {
"path": "string"
},
"target": "Storage"
}
DatasetDestination 物件
設置 target 屬性以指定物件的類型。
對於 BrokerStateStore,請使用:
{
"configuration": {
"key": "string"
},
"target": "BrokerStateStore"
}
對於 Mqtt,請使用:
{
"configuration": {
"qos": "string",
"retain": "string",
"topic": "string",
"ttl": "int"
},
"target": "Mqtt"
}
對於 存儲,請使用:
{
"configuration": {
"path": "string"
},
"target": "Storage"
}
屬性值
Microsoft。DeviceRegistry/namespaces/discoveredAssets
| 名稱 |
說明 |
價值 |
| apiVersion |
API 版本 |
『2026-11-01-預覽』 |
| extendedLocation |
擴充位置。 |
ExtendedLocation (必要) |
| 位置 |
資源所在的地理位置 |
字串 (必要) |
| 名字 |
資源名稱 |
string
Constraints: 最小長度 = 3 最大長度 = 63 模式 = ^[a-z0-9][a-z0-9-]*[a-z0-9]$ (必要) |
| 屬性 |
此資源的資源特定屬性。 |
命名空間發現資產屬性 |
| tags |
資源標籤 |
標記名稱和值的字典。 請參閱範本中的標籤 |
| 型別 |
資源類型 |
「Microsoft。裝置登錄/命名空間/發現資產' |
BrokerStateStoreDestinationConfiguration
| 名稱 |
說明 |
價值 |
| Key |
MQTT 代理狀態儲存目標金鑰。 |
字串 (必要) |
數據集BrokerStateStoreDestination
數據集目標
數據集MqttDestination
數據集存儲目標
設備參考
| 名稱 |
說明 |
價值 |
| 裝置名稱 |
設備資源的名稱 |
字串 (必要) |
| endpointName |
要使用的 endpoint 的名稱 |
字串 (必要) |
事件目的地
事件Mqtt目的地
事件存儲目標
ExtendedLocation
| 名稱 |
說明 |
價值 |
| 名字 |
擴充位置名稱。 |
字串 (必要) |
| 型別 |
擴充位置類型。 |
字串 (必要) |
MqttDestinationConfiguration
| 名稱 |
說明 |
價值 |
| QoS |
MQTT QoS 設置。 預設為 QoS 1。 |
'Qos0' “Qos1” |
| retain |
當設定為 [保留] 時,發佈至 MQTT 訊息代理程式的訊息將會設定保留旗標。 預設值:『Never』。 |
'Keep' 'Never' |
| 主題 |
MQTT 主題。 |
字串 (必要) |
| ttl |
MQTT TTL 設置。 |
int |
命名空間發現資產屬性
| 名稱 |
說明 |
價值 |
| assetTypeRefs |
URI 或類型定義ID。 |
字串[] |
| attributes |
一組包含自定義屬性的鍵值對。 |
NamespaceDiscoveredAssetProperties屬性 |
| 數據集 |
屬於資產一部分的數據集陣列。 每個數據集規格都會描述組成集合的數據點。 |
命名空間發現資料集[] |
| defaultDatasetsConfiguration |
字串化 JSON,其中包含所有數據集的連接器特定預設組態。 每個數據集都可以有自己的組態來覆寫這裡的預設設定。 |
字串 |
| defaultDatasets目標 |
數據集的預設目標。 |
資料集目的地[] |
| defaultEventsConfiguration |
字串化 JSON,其中包含所有事件的連接器特定預設組態。 每個事件都可以有自己的組態來覆寫這裡的預設設定。 |
字串 |
| defaultEventsDestinations (預設事件目標) |
事件的預設目標。 |
事件目的地[] |
| defaultManagementGroups配置 |
字串化的 JSON,其中包含所有管理組的特定於連接器的預設配置。 每個管理組都可以有自己的配置,該配置將覆蓋此處的預設設置。 |
字串 |
| defaultStreams配置 |
字串化的 JSON,其中包含所有流的特定於連接器的預設配置。 每個流都可以有自己的配置,該配置將覆蓋此處的預設設置。 |
字串 |
| defaultStreamsDestinations (預設流目標) |
流的默認目標。 |
流目的地[] |
| 描述 |
資產的人類可讀取描述。 |
字串 |
| 設備引用 |
對此資產提供數據的設備的引用。 必須在設備上提供設備名稱和端點才能使用。 |
DeviceRef (必填) |
| discoveryId |
用來偵測資產變更的標識碼。 |
字串 (必要) |
| 顯示名稱 |
人類可讀取的顯示名稱。 |
字串 |
| documentationUri |
資產文件參考。 |
字串 |
| 事件群組 |
屬於資產一部分的事件群組陣列。 每個事件群組都可以有每個事件群組設定。 |
命名空間發現事件組[] |
| externalAssetId |
客戶提供的資產ID。 |
字串 |
| hardwareRevision |
資產硬體修訂號。 |
字串 |
| managementGroups |
屬於資產的管理組陣列。 每個管理組都可以具有每組配置。 |
命名空間發現管理組[] |
| 製造商 |
資產製造商。 |
字串 |
| manufacturerUri |
資產製造商 URI。 |
字串 |
| 型號 |
資產模型。 |
字串 |
| productCode |
資產產品代碼。 |
字串 |
| serialNumber |
資產序號。 |
字串 |
| softwareRevision |
資產軟體修訂號。 |
字串 |
| streams |
屬於資產的流陣列。 每個流都可以具有每個流的配置。 |
命名空間發現流[] |
| 版本 |
每次修改資源時遞增的整數。 |
int (必要) |
NamespaceDiscoveredAssetProperties屬性
命名空間發現數據集
| 名稱 |
說明 |
價值 |
| dataPoints |
屬於數據集一部分的數據點陣列。 每個數據點可以有每個數據點組態。 |
命名空間發現資料集數據點[] |
| datasetConfiguration |
字串化 JSON,其中包含描述特定數據集組態的連接器特定屬性。 |
字串 |
| dataSource |
對給定數據集的數據源的引用。 |
字串 |
| destinations |
數據集的目標。 |
資料集目的地[] |
| lastUpdatedOn |
時間戳 (UTC) 指示添加或修改資料集的時間。 |
字串 |
| 名字 |
資料集的名稱。 |
字串 (必要) |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
NamespaceDiscoveredDatasetDataPoint
| 名稱 |
說明 |
價值 |
| dataPointConfiguration |
字串化 JSON,其中包含數據點的連接器特定組態。 針對 OPC UA,這可能包括設定,例如 publishingInterval、samplingInterval 和 queueSize。 |
字串 |
| dataSource |
資產中數據源的位址(例如 URL),讓用戶端可以存取資產上的資料源。 |
字串 (必要) |
| lastUpdatedOn |
UTC 時間戳,指出何時新增或修改數據點。 |
字串 |
| 名字 |
數據點的名稱。 |
字串 (必要) |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
命名空間發現事件
| 名稱 |
說明 |
價值 |
| dataSource |
對指定事件的資料來源的參照。 |
字串 |
| destinations |
事件的目標。 |
事件目的地[] |
| eventConfiguration |
包含事件連接器特定組態的字串化 JSON。 針對 OPC UA,這可能包括設定,例如 publishingInterval、samplingInterval 和 queueSize。 |
字串 |
| lastUpdatedOn |
UTC 時間戳,指出事件新增或修改時間。 |
字串 |
| 名字 |
事件的名稱。 |
字串 (必要) |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
命名空間發現事件群組
| 名稱 |
說明 |
價值 |
| dataSource |
資產中事件群組的通知者位址(例如 URL),以便用戶端可以存取資產上的事件群組。 |
字串 |
| 預設目的地 |
活動目的地。 未在事件層級定義目的地時的預設目的地。 |
事件目的地[] |
| eventGroup組態 |
字串化 JSON,其中包含事件群組的連接器特定設定。 針對 OPC UA,這可能包括設定,例如 publishingInterval、samplingInterval 和 queueSize。 |
字串 |
| events |
屬於事件群組的事件陣列。 |
命名空間發現事件[] |
| 名字 |
事件群組的名稱。 |
字串 (必要) |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
NamespaceDiscoveredManagementAction
| 名稱 |
說明 |
價值 |
| actionConfiguration |
字串化的 JSON,其中包含作的連接器特定配置。 |
字串 |
| actionType |
動作的類型。 |
呼叫” 'Read' 'Write' |
| lastUpdatedOn |
時間戳 (UTC) 指示添加或修改管理作的時間。 |
字串 |
| 名字 |
動作的名稱。 |
字串 (必要) |
| targetUri |
用戶端可以調用特定作的目標URI。 |
字串 (必要) |
| timeoutInSeconds |
作的回應超時。 |
int |
| 主題 |
用戶端將接收作請求的 MQTT 主題路徑。 |
字串 |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
命名空間發現管理組
| 名稱 |
說明 |
價值 |
| 行為 |
屬於管理組的作陣列。 每個作都可以有單獨的配置。 |
NamespaceDiscoveredManagementAction[] |
| dataSource |
對指定管理群組的資料來源的參考。 |
字串 |
| defaultTimeoutInSeconds |
屬於管理組的所有作的預設回應超時。 |
int |
| defaultTopic |
預設 MQTT 主題路徑,用戶端將在其上接收屬於管理組的所有作的請求。 |
字串 |
| lastUpdatedOn |
時間戳 (UTC) 指示添加或修改管理組的時間。 |
字串 |
| managementGroup配置 |
字串化的 JSON,其中包含管理組的特定於連接器的配置。 |
字串 |
| 名字 |
管理群組的名稱。 |
字串 (必要) |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
命名空間發現流
| 名稱 |
說明 |
價值 |
| destinations |
流的目標。 |
流目的地[] |
| lastUpdatedOn |
時間戳 (UTC) 指示添加或修改流的時間。 |
字串 |
| 名字 |
流定義的名稱。 |
字串 (必要) |
| 流配置 |
字串化 JSON,其中包含特定流的特定於連接器的配置。 |
字串 |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
存儲目標配置
| 名稱 |
說明 |
價值 |
| 路徑 |
存儲目標路徑。 |
字串 (必要) |
流目標
StreamMqtt目的地
流存儲目標
使用範例
namespaces/discoveredAssets 資源型別可以使用以下列為目標的作業來部署:
如需每個 API 版本中已變更屬性的清單,請參閱 變更記錄檔。
創造一個 Microsoft。DeviceRegistry/namespaces/discoveredAssets 資源,將以下 Terraform 加入你的範本。
resource "azapi_resource" "symbolicname" {
type = "Microsoft.DeviceRegistry/namespaces/discoveredAssets@2026-11-01-preview"
name = "string"
parent_id = "string"
location = "string"
tags = {
{customized property} = "string"
}
body = {
extendedLocation = {
name = "string"
type = "string"
}
properties = {
assetTypeRefs = [
"string"
]
attributes = {
{customized property} = ?
}
datasets = [
{
dataPoints = [
{
dataPointConfiguration = "string"
dataSource = "string"
lastUpdatedOn = "string"
name = "string"
typeRef = "string"
}
]
datasetConfiguration = "string"
dataSource = "string"
destinations = [
{
target = "string"
// For remaining properties, see DatasetDestination objects
}
]
lastUpdatedOn = "string"
name = "string"
typeRef = "string"
}
]
defaultDatasetsConfiguration = "string"
defaultDatasetsDestinations = [
{
target = "string"
// For remaining properties, see DatasetDestination objects
}
]
defaultEventsConfiguration = "string"
defaultEventsDestinations = [
{
target = "string"
// For remaining properties, see EventDestination objects
}
]
defaultManagementGroupsConfiguration = "string"
defaultStreamsConfiguration = "string"
defaultStreamsDestinations = [
{
target = "string"
// For remaining properties, see StreamDestination objects
}
]
description = "string"
deviceRef = {
deviceName = "string"
endpointName = "string"
}
discoveryId = "string"
displayName = "string"
documentationUri = "string"
eventGroups = [
{
dataSource = "string"
defaultDestinations = [
{
target = "string"
// For remaining properties, see EventDestination objects
}
]
eventGroupConfiguration = "string"
events = [
{
dataSource = "string"
destinations = [
{
target = "string"
// For remaining properties, see EventDestination objects
}
]
eventConfiguration = "string"
lastUpdatedOn = "string"
name = "string"
typeRef = "string"
}
]
name = "string"
typeRef = "string"
}
]
externalAssetId = "string"
hardwareRevision = "string"
managementGroups = [
{
actions = [
{
actionConfiguration = "string"
actionType = "string"
lastUpdatedOn = "string"
name = "string"
targetUri = "string"
timeoutInSeconds = int
topic = "string"
typeRef = "string"
}
]
dataSource = "string"
defaultTimeoutInSeconds = int
defaultTopic = "string"
lastUpdatedOn = "string"
managementGroupConfiguration = "string"
name = "string"
typeRef = "string"
}
]
manufacturer = "string"
manufacturerUri = "string"
model = "string"
productCode = "string"
serialNumber = "string"
softwareRevision = "string"
streams = [
{
destinations = [
{
target = "string"
// For remaining properties, see StreamDestination objects
}
]
lastUpdatedOn = "string"
name = "string"
streamConfiguration = "string"
typeRef = "string"
}
]
version = int
}
}
}
StreamDestination 物件
設置 target 屬性以指定物件的類型。
對於 Mqtt,請使用:
{
configuration = {
qos = "string"
retain = "string"
topic = "string"
ttl = int
}
target = "Mqtt"
}
對於 存儲,請使用:
{
configuration = {
path = "string"
}
target = "Storage"
}
EventDestination 物件
設置 target 屬性以指定物件的類型。
對於 Mqtt,請使用:
{
configuration = {
qos = "string"
retain = "string"
topic = "string"
ttl = int
}
target = "Mqtt"
}
對於 存儲,請使用:
{
configuration = {
path = "string"
}
target = "Storage"
}
DatasetDestination 物件
設置 target 屬性以指定物件的類型。
對於 BrokerStateStore,請使用:
{
configuration = {
key = "string"
}
target = "BrokerStateStore"
}
對於 Mqtt,請使用:
{
configuration = {
qos = "string"
retain = "string"
topic = "string"
ttl = int
}
target = "Mqtt"
}
對於 存儲,請使用:
{
configuration = {
path = "string"
}
target = "Storage"
}
屬性值
Microsoft。DeviceRegistry/namespaces/discoveredAssets
| 名稱 |
說明 |
價值 |
| extendedLocation |
擴充位置。 |
ExtendedLocation (必要) |
| 位置 |
資源所在的地理位置 |
字串 (必要) |
| 名字 |
資源名稱 |
string
Constraints: 最小長度 = 3 最大長度 = 63 模式 = ^[a-z0-9][a-z0-9-]*[a-z0-9]$ (必要) |
| parent_id |
此資源為父系之資源的標識碼。 |
類型的資源標識碼:命名空間 |
| 屬性 |
此資源的資源特定屬性。 |
命名空間發現資產屬性 |
| tags |
資源標籤 |
標記名稱和值的字典。 |
| 型別 |
資源類型 |
「Microsoft。DeviceRegistry/namespaces/discoveredAssets@2026-11-01-preview” |
BrokerStateStoreDestinationConfiguration
| 名稱 |
說明 |
價值 |
| Key |
MQTT 代理狀態儲存目標金鑰。 |
字串 (必要) |
數據集BrokerStateStoreDestination
數據集目標
數據集MqttDestination
數據集存儲目標
設備參考
| 名稱 |
說明 |
價值 |
| 裝置名稱 |
設備資源的名稱 |
字串 (必要) |
| endpointName |
要使用的 endpoint 的名稱 |
字串 (必要) |
事件目的地
事件Mqtt目的地
事件存儲目標
ExtendedLocation
| 名稱 |
說明 |
價值 |
| 名字 |
擴充位置名稱。 |
字串 (必要) |
| 型別 |
擴充位置類型。 |
字串 (必要) |
MqttDestinationConfiguration
| 名稱 |
說明 |
價值 |
| QoS |
MQTT QoS 設置。 預設為 QoS 1。 |
'Qos0' “Qos1” |
| retain |
當設定為 [保留] 時,發佈至 MQTT 訊息代理程式的訊息將會設定保留旗標。 預設值:『Never』。 |
'Keep' 'Never' |
| 主題 |
MQTT 主題。 |
字串 (必要) |
| ttl |
MQTT TTL 設置。 |
int |
命名空間發現資產屬性
| 名稱 |
說明 |
價值 |
| assetTypeRefs |
URI 或類型定義ID。 |
字串[] |
| attributes |
一組包含自定義屬性的鍵值對。 |
NamespaceDiscoveredAssetProperties屬性 |
| 數據集 |
屬於資產一部分的數據集陣列。 每個數據集規格都會描述組成集合的數據點。 |
命名空間發現資料集[] |
| defaultDatasetsConfiguration |
字串化 JSON,其中包含所有數據集的連接器特定預設組態。 每個數據集都可以有自己的組態來覆寫這裡的預設設定。 |
字串 |
| defaultDatasets目標 |
數據集的預設目標。 |
資料集目的地[] |
| defaultEventsConfiguration |
字串化 JSON,其中包含所有事件的連接器特定預設組態。 每個事件都可以有自己的組態來覆寫這裡的預設設定。 |
字串 |
| defaultEventsDestinations (預設事件目標) |
事件的預設目標。 |
事件目的地[] |
| defaultManagementGroups配置 |
字串化的 JSON,其中包含所有管理組的特定於連接器的預設配置。 每個管理組都可以有自己的配置,該配置將覆蓋此處的預設設置。 |
字串 |
| defaultStreams配置 |
字串化的 JSON,其中包含所有流的特定於連接器的預設配置。 每個流都可以有自己的配置,該配置將覆蓋此處的預設設置。 |
字串 |
| defaultStreamsDestinations (預設流目標) |
流的默認目標。 |
流目的地[] |
| 描述 |
資產的人類可讀取描述。 |
字串 |
| 設備引用 |
對此資產提供數據的設備的引用。 必須在設備上提供設備名稱和端點才能使用。 |
DeviceRef (必填) |
| discoveryId |
用來偵測資產變更的標識碼。 |
字串 (必要) |
| 顯示名稱 |
人類可讀取的顯示名稱。 |
字串 |
| documentationUri |
資產文件參考。 |
字串 |
| 事件群組 |
屬於資產一部分的事件群組陣列。 每個事件群組都可以有每個事件群組設定。 |
命名空間發現事件組[] |
| externalAssetId |
客戶提供的資產ID。 |
字串 |
| hardwareRevision |
資產硬體修訂號。 |
字串 |
| managementGroups |
屬於資產的管理組陣列。 每個管理組都可以具有每組配置。 |
命名空間發現管理組[] |
| 製造商 |
資產製造商。 |
字串 |
| manufacturerUri |
資產製造商 URI。 |
字串 |
| 型號 |
資產模型。 |
字串 |
| productCode |
資產產品代碼。 |
字串 |
| serialNumber |
資產序號。 |
字串 |
| softwareRevision |
資產軟體修訂號。 |
字串 |
| streams |
屬於資產的流陣列。 每個流都可以具有每個流的配置。 |
命名空間發現流[] |
| 版本 |
每次修改資源時遞增的整數。 |
int (必要) |
NamespaceDiscoveredAssetProperties屬性
命名空間發現數據集
| 名稱 |
說明 |
價值 |
| dataPoints |
屬於數據集一部分的數據點陣列。 每個數據點可以有每個數據點組態。 |
命名空間發現資料集數據點[] |
| datasetConfiguration |
字串化 JSON,其中包含描述特定數據集組態的連接器特定屬性。 |
字串 |
| dataSource |
對給定數據集的數據源的引用。 |
字串 |
| destinations |
數據集的目標。 |
資料集目的地[] |
| lastUpdatedOn |
時間戳 (UTC) 指示添加或修改資料集的時間。 |
字串 |
| 名字 |
資料集的名稱。 |
字串 (必要) |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
NamespaceDiscoveredDatasetDataPoint
| 名稱 |
說明 |
價值 |
| dataPointConfiguration |
字串化 JSON,其中包含數據點的連接器特定組態。 針對 OPC UA,這可能包括設定,例如 publishingInterval、samplingInterval 和 queueSize。 |
字串 |
| dataSource |
資產中數據源的位址(例如 URL),讓用戶端可以存取資產上的資料源。 |
字串 (必要) |
| lastUpdatedOn |
UTC 時間戳,指出何時新增或修改數據點。 |
字串 |
| 名字 |
數據點的名稱。 |
字串 (必要) |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
命名空間發現事件
| 名稱 |
說明 |
價值 |
| dataSource |
對指定事件的資料來源的參照。 |
字串 |
| destinations |
事件的目標。 |
事件目的地[] |
| eventConfiguration |
包含事件連接器特定組態的字串化 JSON。 針對 OPC UA,這可能包括設定,例如 publishingInterval、samplingInterval 和 queueSize。 |
字串 |
| lastUpdatedOn |
UTC 時間戳,指出事件新增或修改時間。 |
字串 |
| 名字 |
事件的名稱。 |
字串 (必要) |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
命名空間發現事件群組
| 名稱 |
說明 |
價值 |
| dataSource |
資產中事件群組的通知者位址(例如 URL),以便用戶端可以存取資產上的事件群組。 |
字串 |
| 預設目的地 |
活動目的地。 未在事件層級定義目的地時的預設目的地。 |
事件目的地[] |
| eventGroup組態 |
字串化 JSON,其中包含事件群組的連接器特定設定。 針對 OPC UA,這可能包括設定,例如 publishingInterval、samplingInterval 和 queueSize。 |
字串 |
| events |
屬於事件群組的事件陣列。 |
命名空間發現事件[] |
| 名字 |
事件群組的名稱。 |
字串 (必要) |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
NamespaceDiscoveredManagementAction
| 名稱 |
說明 |
價值 |
| actionConfiguration |
字串化的 JSON,其中包含作的連接器特定配置。 |
字串 |
| actionType |
動作的類型。 |
呼叫” 'Read' 'Write' |
| lastUpdatedOn |
時間戳 (UTC) 指示添加或修改管理作的時間。 |
字串 |
| 名字 |
動作的名稱。 |
字串 (必要) |
| targetUri |
用戶端可以調用特定作的目標URI。 |
字串 (必要) |
| timeoutInSeconds |
作的回應超時。 |
int |
| 主題 |
用戶端將接收作請求的 MQTT 主題路徑。 |
字串 |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
命名空間發現管理組
| 名稱 |
說明 |
價值 |
| 行為 |
屬於管理組的作陣列。 每個作都可以有單獨的配置。 |
NamespaceDiscoveredManagementAction[] |
| dataSource |
對指定管理群組的資料來源的參考。 |
字串 |
| defaultTimeoutInSeconds |
屬於管理組的所有作的預設回應超時。 |
int |
| defaultTopic |
預設 MQTT 主題路徑,用戶端將在其上接收屬於管理組的所有作的請求。 |
字串 |
| lastUpdatedOn |
時間戳 (UTC) 指示添加或修改管理組的時間。 |
字串 |
| managementGroup配置 |
字串化的 JSON,其中包含管理組的特定於連接器的配置。 |
字串 |
| 名字 |
管理群組的名稱。 |
字串 (必要) |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
命名空間發現流
| 名稱 |
說明 |
價值 |
| destinations |
流的目標。 |
流目的地[] |
| lastUpdatedOn |
時間戳 (UTC) 指示添加或修改流的時間。 |
字串 |
| 名字 |
流定義的名稱。 |
字串 (必要) |
| 流配置 |
字串化 JSON,其中包含特定流的特定於連接器的配置。 |
字串 |
| 類型引用 |
URI 或類型定義ID。 |
字串 |
存儲目標配置
| 名稱 |
說明 |
價值 |
| 路徑 |
存儲目標路徑。 |
字串 (必要) |
流目標
StreamMqtt目的地
流存儲目標