Skip to content

Commit bb12f40

Browse files
committed
Standardizing IoT Sensor Alias
1 parent 430701b commit bb12f40

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

FIWARE IoT Agent JSON.postman_collection.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,7 @@
193193
],
194194
"body": {
195195
"mode": "raw",
196-
"raw": "{\n \"devices\": [\n {\n \"device_id\": \"bell001\",\n \"entity_name\": \"urn:ngsi-ld:Bell:001\",\n \"entity_type\": \"Bell\",\n \"protocol\": \"PDI-IoTA-UltraLight\",\n \"transport\": \"HTTP\",\n \"endpoint\": \"http://context-provider:3001/iot/bell001\",\n \"commands\": [ \n {\n \"name\": \"ring\",\n \"type\": \"command\"\n }\n ],\n \"static_attributes\": [\n {\"name\":\"refStore\", \"type\": \"Relationship\",\"value\": \"urn:ngsi-ld:Store:001\"}\n \t]\n }\n ]\n}\n"
196+
"raw": "{\n \"devices\": [\n {\n \"device_id\": \"bell001\",\n \"entity_name\": \"urn:ngsi-ld:Bell:001\",\n \"entity_type\": \"Bell\",\n \"protocol\": \"PDI-IoTA-UltraLight\",\n \"transport\": \"HTTP\",\n \"endpoint\": \"http://iot-sensors:3001/iot/bell001\",\n \"commands\": [ \n {\n \"name\": \"ring\",\n \"type\": \"command\"\n }\n ],\n \"static_attributes\": [\n {\"name\":\"refStore\", \"type\": \"Relationship\",\"value\": \"urn:ngsi-ld:Store:001\"}\n \t]\n }\n ]\n}\n"
197197
},
198198
"url": {
199199
"raw": "http://{{iot-agent}}/iot/devices",
@@ -206,7 +206,7 @@
206206
"devices"
207207
]
208208
},
209-
"description": "Provisioning an actuator is similar to provisioning a sensor. This time an `endpoint` attribute holds\nthe location where the IoT Agent needs to send the UltraLight command and the `commands` array includes\na list of each command that can be invoked. The example below provisions a bell with the `deviceId=bell001`.\nThe endpoint is `http://context-provider:3001/iot/bell001` and it can accept the `ring` command."
209+
"description": "Provisioning an actuator is similar to provisioning a sensor. This time an `endpoint` attribute holds\nthe location where the IoT Agent needs to send the UltraLight command and the `commands` array includes\na list of each command that can be invoked. The example below provisions a bell with the `deviceId=bell001`.\nThe endpoint is `http://iot-sensors:3001/iot/bell001` and it can accept the `ring` command."
210210
},
211211
"response": []
212212
},
@@ -304,7 +304,7 @@
304304
],
305305
"body": {
306306
"mode": "raw",
307-
"raw": "{\n \"devices\": [\n {\n \"device_id\": \"door001\",\n \"entity_name\": \"urn:ngsi-ld:Door:001\",\n \"entity_type\": \"Door\",\n \"protocol\": \"PDI-IoTA-UltraLight\",\n \"transport\": \"HTTP\",\n \"endpoint\": \"http://context-provider:3001/iot/door001\",\n \"commands\": [ \n {\"name\": \"unlock\",\"type\": \"command\"},\n {\"name\": \"open\",\"type\": \"command\"},\n {\"name\": \"close\",\"type\": \"command\"},\n {\"name\": \"lock\",\"type\": \"command\"}\n ],\n \"attributes\": [\n \t{\"object_id\": \"s\", \"name\": \"state\", \"type\":\"Text\"}\n ],\n \"static_attributes\": [\n {\"name\":\"refStore\", \"type\": \"Relationship\",\"value\": \"urn:ngsi-ld:Store:001\"}\n ]\n }\n ]\n}\n"
307+
"raw": "{\n \"devices\": [\n {\n \"device_id\": \"door001\",\n \"entity_name\": \"urn:ngsi-ld:Door:001\",\n \"entity_type\": \"Door\",\n \"protocol\": \"PDI-IoTA-UltraLight\",\n \"transport\": \"HTTP\",\n \"endpoint\": \"http://iot-sensors:3001/iot/door001\",\n \"commands\": [ \n {\"name\": \"unlock\",\"type\": \"command\"},\n {\"name\": \"open\",\"type\": \"command\"},\n {\"name\": \"close\",\"type\": \"command\"},\n {\"name\": \"lock\",\"type\": \"command\"}\n ],\n \"attributes\": [\n \t{\"object_id\": \"s\", \"name\": \"state\", \"type\":\"Text\"}\n ],\n \"static_attributes\": [\n {\"name\":\"refStore\", \"type\": \"Relationship\",\"value\": \"urn:ngsi-ld:Store:001\"}\n ]\n }\n ]\n}\n"
308308
},
309309
"url": {
310310
"raw": "http://{{iot-agent}}/iot/devices",
@@ -341,7 +341,7 @@
341341
],
342342
"body": {
343343
"mode": "raw",
344-
"raw": "{\n \"devices\": [\n {\n \"device_id\": \"lamp001\",\n \"entity_name\": \"urn:ngsi-ld:Lamp:001\",\n \"entity_type\": \"Lamp\",\n \"protocol\": \"PDI-IoTA-UltraLight\",\n \"transport\": \"HTTP\",\n \"endpoint\": \"http://context-provider:3001/iot/lamp001\",\n \"commands\": [ \n {\"name\": \"on\",\"type\": \"command\"},\n {\"name\": \"off\",\"type\": \"command\"}\n ],\n \"attributes\": [\n \t{\"object_id\": \"s\", \"name\": \"state\", \"type\":\"Text\"},\n {\"object_id\": \"l\", \"name\": \"luminosity\", \"type\":\"Integer\"}\n ],\n \"static_attributes\": [\n {\"name\":\"refStore\", \"type\": \"Relationship\",\"value\": \"urn:ngsi-ld:Store:001\"}\n \t]\n }\n ]\n}\n"
344+
"raw": "{\n \"devices\": [\n {\n \"device_id\": \"lamp001\",\n \"entity_name\": \"urn:ngsi-ld:Lamp:001\",\n \"entity_type\": \"Lamp\",\n \"protocol\": \"PDI-IoTA-UltraLight\",\n \"transport\": \"HTTP\",\n \"endpoint\": \"http://iot-sensors:3001/iot/lamp001\",\n \"commands\": [ \n {\"name\": \"on\",\"type\": \"command\"},\n {\"name\": \"off\",\"type\": \"command\"}\n ],\n \"attributes\": [\n \t{\"object_id\": \"s\", \"name\": \"state\", \"type\":\"Text\"},\n {\"object_id\": \"l\", \"name\": \"luminosity\", \"type\":\"Integer\"}\n ],\n \"static_attributes\": [\n {\"name\":\"refStore\", \"type\": \"Relationship\",\"value\": \"urn:ngsi-ld:Store:001\"}\n \t]\n }\n ]\n}\n"
345345
},
346346
"url": {
347347
"raw": "http://{{iot-agent}}/iot/devices",
@@ -1026,7 +1026,7 @@
10261026
],
10271027
"body": {
10281028
"mode": "raw",
1029-
"raw": "{\n \"devices\": [\n {\n \"device_id\": \"bell002\",\n \"entity_name\": \"urn:ngsi-ld:Bell:002\",\n \"entity_type\": \"Bell\",\n \"protocol\": \"PDI-IoTA-UltraLight\",\n \"transport\": \"HTTP\",\n \"endpoint\": \"http://context-provider:3001/iot/bell002\",\n \"commands\": [ \n {\n \"name\": \"ring\",\n \"type\": \"command\"\n }\n ],\n \"static_attributes\": [\n {\"name\":\"refStore\", \"type\": \"Relationship\",\"value\": \"urn:ngsi-ld:Store:002\"}\n \t]\n }\n ]\n}\n"
1029+
"raw": "{\n \"devices\": [\n {\n \"device_id\": \"bell002\",\n \"entity_name\": \"urn:ngsi-ld:Bell:002\",\n \"entity_type\": \"Bell\",\n \"protocol\": \"PDI-IoTA-UltraLight\",\n \"transport\": \"HTTP\",\n \"endpoint\": \"http://iot-sensors:3001/iot/bell002\",\n \"commands\": [ \n {\n \"name\": \"ring\",\n \"type\": \"command\"\n }\n ],\n \"static_attributes\": [\n {\"name\":\"refStore\", \"type\": \"Relationship\",\"value\": \"urn:ngsi-ld:Store:002\"}\n \t]\n }\n ]\n}\n"
10301030
},
10311031
"url": {
10321032
"raw": "http://{{iot-agent}}/iot/devices",
@@ -1039,7 +1039,7 @@
10391039
"devices"
10401040
]
10411041
},
1042-
"description": "This example provisions an individual device. It maps the `device_id=bell002` to the entity URN `urn:ngsi-ld:Bell:002` and gives the\nentity a type `Bell`. The IoT Agent has been informed that the device offers a single `ring` `command` and is listening on \n`http://context-provider:3001/iot/bell002` using HTTP. `attributes`, `lazy` attributes and `static_attributes` can also be provisioned."
1042+
"description": "This example provisions an individual device. It maps the `device_id=bell002` to the entity URN `urn:ngsi-ld:Bell:002` and gives the\nentity a type `Bell`. The IoT Agent has been informed that the device offers a single `ring` `command` and is listening on \n`http://iot-sensors:3001/iot/bell002` using HTTP. `attributes`, `lazy` attributes and `static_attributes` can also be provisioned."
10431043
},
10441044
"response": []
10451045
},

docker-compose.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,15 +73,15 @@ services:
7373
# Tutorial acts as a series of dummy IoT Sensors over HTTP
7474
tutorial:
7575
image: fiware/tutorials.context-provider
76-
hostname: tutorial
76+
hostname: iot-sensors
7777
container_name: fiware-tutorial
7878
depends_on:
7979
- orion
8080
- iot-agent
8181
networks:
8282
default:
8383
aliases:
84-
- iot-sensors
84+
- tutorial
8585
- context-provider
8686
expose:
8787
- "${TUTORIAL_APP_PORT}"

0 commit comments

Comments
 (0)