Skip to content

Commit

Permalink
Explicitly add apiKey
Browse files Browse the repository at this point in the history
  • Loading branch information
jason-fox committed Jun 28, 2024
1 parent 0179d50 commit 7bdc3a9
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 7 deletions.
14 changes: 7 additions & 7 deletions FIWARE IoT Agent.postman_collection.json
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@
],
"body": {
"mode": "raw",
"raw": "{\n \"devices\": [\n {\n \"device_id\": \"motion001\",\n \"entity_name\": \"urn:ngsi-ld:Motion:001\",\n \"entity_type\": \"Motion\",\n \"timezone\": \"Europe/Berlin\",\n \"attributes\": [\n { \"object_id\": \"c\", \"name\": \"count\", \"type\": \"Integer\" }\n ],\n \"static_attributes\": [\n { \"name\":\"refStore\", \"type\": \"Relationship\", \"value\": \"urn:ngsi-ld:Store:001\"}\n ]\n }\n ]\n}"
"raw": "{\n \"devices\": [\n {\n \"device_id\": \"motion001\",\n \"entity_name\": \"urn:ngsi-ld:Motion:001\",\n \"entity_type\": \"Motion\",\n \"apikey\": \"4jggokgpepnvsb2uv4s40d59ov\",\n \"timezone\": \"Europe/Berlin\",\n \"attributes\": [\n { \"object_id\": \"c\", \"name\": \"count\", \"type\": \"Integer\" }\n ],\n \"static_attributes\": [\n { \"name\":\"refStore\", \"type\": \"Relationship\", \"value\": \"urn:ngsi-ld:Store:001\"}\n ]\n }\n ]\n}"
},
"url": {
"raw": "http://{{iot-agent}}/iot/devices",
Expand Down Expand Up @@ -199,7 +199,7 @@
],
"body": {
"mode": "raw",
"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"
"raw": "{\n \"devices\": [\n {\n \"device_id\": \"bell001\",\n \"entity_name\": \"urn:ngsi-ld:Bell:001\",\n \"entity_type\": \"Bell\",\n \"apikey\": \"4jggokgpepnvsb2uv4s40d59ov\",\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"
},
"url": {
"raw": "http://{{iot-agent}}/iot/devices",
Expand Down Expand Up @@ -236,7 +236,7 @@
],
"body": {
"mode": "raw",
"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 \"attributes\": [\n {\n \"name\": \"ring\",\n \"type\": \"Text\",\n \"expression\": \"ring\",\n \"reverse\": [\n {\n \"object_id\": \"ring\",\n \"type\": \"Text\",\n \"expression\": \"ring | toString()\"\n }\n ]\n }\n ],\n \"static_attributes\": [\n {\n \"name\": \"refStore\",\n \"type\": \"Relationship\",\n \"value\": \"urn:ngsi-ld:Store:002\"\n }\n ]\n }\n ]\n}"
"raw": "{\n \"devices\": [\n {\n \"device_id\": \"bell002\",\n \"entity_name\": \"urn:ngsi-ld:Bell:002\",\n \"entity_type\": \"Bell\",\n \"apikey\": \"4jggokgpepnvsb2uv4s40d59ov\",\n \"protocol\": \"PDI-IoTA-UltraLight\",\n \"transport\": \"HTTP\",\n \"endpoint\": \"http://context-provider:3001/iot/bell002\",\n \"attributes\": [\n {\n \"name\": \"ring\",\n \"type\": \"Text\",\n \"expression\": \"ring\",\n \"reverse\": [\n {\n \"object_id\": \"ring\",\n \"type\": \"Text\",\n \"expression\": \"ring | toString()\"\n }\n ]\n }\n ],\n \"static_attributes\": [\n {\n \"name\": \"refStore\",\n \"type\": \"Relationship\",\n \"value\": \"urn:ngsi-ld:Store:002\"\n }\n ]\n }\n ]\n}"
},
"url": {
"raw": "http://{{iot-agent}}/iot/devices",
Expand Down Expand Up @@ -351,7 +351,7 @@
],
"body": {
"mode": "raw",
"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"
"raw": "{\n \"devices\": [\n {\n \"device_id\": \"door001\",\n \"entity_name\": \"urn:ngsi-ld:Door:001\",\n \"entity_type\": \"Door\",\n \"apikey\": \"4jggokgpepnvsb2uv4s40d59ov\",\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"
},
"url": {
"raw": "http://{{iot-agent}}/iot/devices",
Expand Down Expand Up @@ -388,7 +388,7 @@
],
"body": {
"mode": "raw",
"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"
"raw": "{\n \"devices\": [\n {\n \"device_id\": \"lamp001\",\n \"entity_name\": \"urn:ngsi-ld:Lamp:001\",\n \"entity_type\": \"Lamp\",\n \"apikey\": \"4jggokgpepnvsb2uv4s40d59ov\",\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"
},
"url": {
"raw": "http://{{iot-agent}}/iot/devices",
Expand Down Expand Up @@ -1020,8 +1020,8 @@
},
{
"key": "Content-Type",
"name": "Content-Type",
"value": "application/x-www-form-urlencoded",
"name": "Content-Type",
"type": "text"
}
],
Expand Down Expand Up @@ -1217,7 +1217,7 @@
],
"body": {
"mode": "raw",
"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"
"raw": "{\n \"devices\": [\n {\n \"device_id\": \"bell002\",\n \"entity_name\": \"urn:ngsi-ld:Bell:002\",\n \"entity_type\": \"Bell\",\n \"apikey\": \"4jggokgpepnvsb2uv4s40d59ov\",\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 {\n \"name\": \"refStore\",\n \"type\": \"Relationship\",\n \"value\": \"urn:ngsi-ld:Store:002\"\n }\n ]\n }\n ]\n}"
},
"url": {
"raw": "http://{{iot-agent}}/iot/devices",
Expand Down
7 changes: 7 additions & 0 deletions README.ja.md
Original file line number Diff line number Diff line change
Expand Up @@ -656,6 +656,7 @@ curl -iX POST \
"device_id": "motion001",
"entity_name": "urn:ngsi-ld:Motion:001",
"entity_type": "Motion",
"apikey": "4jggokgpepnvsb2uv4s40d59ov",
"timezone": "Europe/Berlin",
"attributes": [
{ "object_id": "c", "name": "count", "type": "Integer" }
Expand Down Expand Up @@ -800,6 +801,7 @@ curl -iX POST \
"device_id": "bell001",
"entity_name": "urn:ngsi-ld:Bell:001",
"entity_type": "Bell",
"apikey": "4jggokgpepnvsb2uv4s40d59ov",
"protocol": "PDI-IoTA-UltraLight",
"transport": "HTTP",
"endpoint": "http://iot-sensors:3001/iot/bell001",
Expand Down Expand Up @@ -838,6 +840,7 @@ curl -L -X POST 'http://localhost:4041/iot/devices' \
"device_id": "bell002",
"entity_name": "urn:ngsi-ld:Bell:002",
"entity_type": "Bell",
"apikey": "4jggokgpepnvsb2uv4s40d59ov",
"protocol": "PDI-IoTA-UltraLight",
"transport": "HTTP",
"endpoint": "http://iot-sensors:3001/iot/bell002",
Expand Down Expand Up @@ -949,6 +952,7 @@ curl -iX POST \
"device_id": "door001",
"entity_name": "urn:ngsi-ld:Door:001",
"entity_type": "Door",
"apikey": "4jggokgpepnvsb2uv4s40d59ov",
"protocol": "PDI-IoTA-UltraLight",
"transport": "HTTP",
"endpoint": "http://iot-sensors:3001/iot/door001",
Expand Down Expand Up @@ -991,6 +995,7 @@ curl -iX POST \
"device_id": "lamp001",
"entity_name": "urn:ngsi-ld:Lamp:001",
"entity_type": "Lamp",
"apikey": "4jggokgpepnvsb2uv4s40d59ov",
"protocol": "PDI-IoTA-UltraLight",
"transport": "HTTP",
"endpoint": "http://iot-sensors:3001/iot/lamp001",
Expand Down Expand Up @@ -1312,6 +1317,7 @@ curl -iX POST \
"device_id": "bell002",
"entity_name": "urn:ngsi-ld:Bell:002",
"entity_type": "Bell",
"apikey": "4jggokgpepnvsb2uv4s40d59ov",
"protocol": "PDI-IoTA-UltraLight",
"transport": "HTTP",
"endpoint": "http://iot-sensors:3001/iot/bell002",
Expand Down Expand Up @@ -1413,6 +1419,7 @@ curl -X GET \
"service_path": "/",
"entity_name": "urn:ngsi",
"entity_type": "Bell",
"apikey": "4jggokgpepnvsb2uv4s40d59ov",
"endpoint": "http://iot-sensors:3001/iot/bell002",
"transport": "HTTP",
"attributes": [],
Expand Down
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -569,6 +569,7 @@ curl -iX POST \
"entity_name": "urn:ngsi-ld:Motion:001",
"entity_type": "Motion",
"timezone": "Europe/Berlin",
"apikey": "4jggokgpepnvsb2uv4s40d59ov",
"attributes": [
{ "object_id": "c", "name": "count", "type": "Integer" }
],
Expand Down Expand Up @@ -704,6 +705,7 @@ curl -iX POST \
"device_id": "bell001",
"entity_name": "urn:ngsi-ld:Bell:001",
"entity_type": "Bell",
"apikey": "4jggokgpepnvsb2uv4s40d59ov",
"protocol": "PDI-IoTA-UltraLight",
"transport": "HTTP",
"endpoint": "http://iot-sensors:3001/iot/bell001",
Expand Down Expand Up @@ -741,6 +743,7 @@ curl -L -X POST 'http://localhost:4041/iot/devices' \
"device_id": "bell002",
"entity_name": "urn:ngsi-ld:Bell:002",
"entity_type": "Bell",
"apikey": "4jggokgpepnvsb2uv4s40d59ov",
"protocol": "PDI-IoTA-UltraLight",
"transport": "HTTP",
"endpoint": "http://iot-sensors:3001/iot/bell002",
Expand Down Expand Up @@ -847,6 +850,7 @@ curl -iX POST \
"device_id": "door001",
"entity_name": "urn:ngsi-ld:Door:001",
"entity_type": "Door",
"apikey": "4jggokgpepnvsb2uv4s40d59ov",
"protocol": "PDI-IoTA-UltraLight",
"transport": "HTTP",
"endpoint": "http://iot-sensors:3001/iot/door001",
Expand Down Expand Up @@ -886,6 +890,7 @@ curl -iX POST \
"device_id": "lamp001",
"entity_name": "urn:ngsi-ld:Lamp:001",
"entity_type": "Lamp",
"apikey": "4jggokgpepnvsb2uv4s40d59ov",
"protocol": "PDI-IoTA-UltraLight",
"transport": "HTTP",
"endpoint": "http://iot-sensors:3001/iot/lamp001",
Expand Down Expand Up @@ -1176,6 +1181,7 @@ curl -iX POST \
"device_id": "bell002",
"entity_name": "urn:ngsi-ld:Bell:002",
"entity_type": "Bell",
"apikey": "4jggokgpepnvsb2uv4s40d59ov",
"protocol": "PDI-IoTA-UltraLight",
"transport": "HTTP",
"endpoint": "http://iot-sensors:3001/iot/bell002",
Expand Down Expand Up @@ -1219,6 +1225,7 @@ The response includes all the commands and attributes mappings associated with t
"service_path": "/",
"entity_name": "urn:ngsi",
"entity_type": "Bell",
"apikey": "4jggokgpepnvsb2uv4s40d59ov",
"endpoint": "http://iot-sensors:3001/iot/bell002",
"transport": "HTTP",
"attributes": [],
Expand Down Expand Up @@ -1268,6 +1275,7 @@ The response includes all the commands and attributes mappings associated with a
"service_path": "/",
"entity_name": "urn:ngsi",
"entity_type": "Bell",
"apikey": "4jggokgpepnvsb2uv4s40d59ov",
"endpoint": "http://iot-sensors:3001/iot/bell002",
"transport": "HTTP",
"attributes": [],
Expand Down

0 comments on commit 7bdc3a9

Please sign in to comment.