我正在使用 Fiware cygnus 订阅 orion 上下文代理实体。是否可以使用一个脚本订阅所有上下文更新?我不想一一做。以下是订阅示例:
(curl 192.168.1.79:1026/v1/subscribeContext -s -S --header 'Content-Type: application/json' --header 'Accept: application/json' --header 'Fiware-Service: test' --header 'Fiware-ServicePath: /testPath' -d @- | python -mjson.tool) <<EOF
{
"entities": [
{
"type": "room",
"isPattern": "false",
"id": "temperature"
}
],
"attributes": [
"tmpValue"
],
"reference": "http://192.168.1.40:5050/notify",
"duration": "P1M",
"notifyConditions": [
{
"type": "ONCHANGE",
"condValues": [
"tmpValue"
]
}
],
"throttling": "PT1S"
}
EOF