@@ -609,7 +609,8 @@ Three types of measurement attributes can be provisioned:
609609# ### 3️⃣ Request:
610610
611611` ` ` console
612- curl -L -X POST 'http://localhost:4041/iot/devices' \
612+ curl -L -X POST \
613+ 'http://localhost:4041/iot/devices' \
613614 -H 'fiware-service: openiot' \
614615 -H 'fiware-servicepath: /' \
615616 -H 'Content-Type: application/json' \
@@ -678,7 +679,8 @@ making the following request
678679# ### 4️⃣ Request:
679680
680681` ` ` console
681- curl -L -X POST 'http://localhost:7896/iot/json?k=4jggokgpepnvsb2uv4s40d59ov&i=temperature001' \
682+ curl -L -X POST \
683+ 'http://localhost:7896/iot/json?k=4jggokgpepnvsb2uv4s40d59ov&i=temperature001' \
682684 -H 'Content-Type: application/json' \
683685 --data-raw '{ "t": 3}'
684686` ` `
@@ -700,11 +702,12 @@ add the `fiware-service` and `fiware-service-path` headers.
700702# ### 5️⃣ Request:
701703
702704` ` ` console
703- curl -G -iX GET 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:temperature001' \
705+ curl -G -iX GET \
706+ 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:temperature001' \
704707 -H 'NGSILD-Tenant: openiot' \
705708 -H 'Accept: application/ld+json' \
706709 -H 'Link: <http://context/user-context.jsonld>; rel="http://www.w3.org/ns/json-ld#context"; type="application/ld+json"' \
707- -d 'attrs= temperature'
710+ -d 'pick=id,type, temperature'
708711` ` `
709712
710713# ### Response:
@@ -754,7 +757,8 @@ based on the knowledge of the service group
754757# ### 7️⃣ Request:
755758
756759` ` ` console
757- curl -L -X GET 'http://localhost:1026/ngsi-ld/v1/entities/?type=Device' \
760+ curl -L -X GET \
761+ 'http://localhost:1026/ngsi-ld/v1/entities/?type=Device' \
758762 -H 'NGSILD-Tenant: openiot' \
759763 -H 'Accept: application/ld+json' \
760764 -H 'Link: <http://context/user-context.jsonld>; rel="http://www.w3.org/ns/json-ld#context"; type="application/ld+json"'
@@ -805,7 +809,8 @@ communications protocol to be used.
805809# ### 8️⃣ Request:
806810
807811` ` ` console
808- curl -L -X POST 'http://localhost:4041/iot/devices' \
812+ curl -L -X POST \
813+ 'http://localhost:4041/iot/devices' \
809814 -H 'fiware-service: openiot' \
810815 -H 'fiware-servicepath: /' \
811816 -H 'Content-Type: application/json' \
@@ -846,7 +851,8 @@ command directly as shown:
846851# ### 9️⃣ Request:
847852
848853` ` ` console
849- curl -L -X PATCH 'http://localhost:4041/ngsi-ld/v1/entities/urn:ngsi-ld:Device:water001/attrs/on' \
854+ curl -L -X PATCH \
855+ 'http://localhost:4041/ngsi-ld/v1/entities/urn:ngsi-ld:Device:water001/attrs/on' \
850856 -H 'fiware-service: openiot' \
851857 -H 'fiware-servicepath: /' \
852858 -H 'Content-Type: application/json' \
@@ -867,7 +873,8 @@ The result of the command to turn on the irrigation system can be read by queryi
867873# ### 1️⃣0️⃣ Request:
868874
869875` ` ` console
870- curl -L -X GET 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:water001' \
876+ curl -L -X GET \
877+ 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:water001' \
871878 -H 'NGSILD-Tenant: openiot' \
872879 -H 'Link: <http://context/user-context.jsonld>; rel="http://www.w3.org/ns/json-ld#context"; type="application/ld+json"' \
873880 -H 'Accept: application/json'
@@ -914,7 +921,8 @@ both `attributes` and `command` attributes in the body of the request.
914921# ### 1️⃣1️⃣ Request:
915922
916923` ` ` console
917- curl -L -X POST 'http://localhost:4041/iot/devices' \
924+ curl -L -X POST \
925+ 'http://localhost:4041/iot/devices' \
918926 -H 'fiware-service: openiot' \
919927 -H 'fiware-servicepath: /' \
920928 -H 'Content-Type: application/json' \
@@ -970,7 +978,8 @@ Similarly, a **Tractor** with two commands (`start` and `stop`) and two attribut
970978# ### 1️⃣2️⃣ Request:
971979
972980` ` ` console
973- curl -L -X POST 'http://localhost:4041/iot/devices' \
981+ curl -L -X POST \
982+ 'http://localhost:4041/iot/devices' \
974983 -H 'fiware-service: openiot' \
975984 -H 'fiware-servicepath: /' \
976985 -H 'Content-Type: application/json' \
@@ -1005,7 +1014,8 @@ The full list of provisioned devices can be obtained by making a GET request to
10051014# ### 1️⃣3️⃣ Request:
10061015
10071016` ` ` console
1008- curl -L -X GET 'http://localhost:4041/iot/devices' \
1017+ curl -L -X GET \
1018+ 'http://localhost:4041/iot/devices' \
10091019 -H 'fiware-service: openiot' \
10101020 -H 'fiware-servicepath: /'
10111021` ` `
@@ -1028,7 +1038,8 @@ To invoke the `on` command, the `on` attribute must be updated in the context.
10281038# ### 1️⃣4️⃣ Request:
10291039
10301040` ` ` console
1031- curl -L -X PATCH 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:water001/attrs/on' \
1041+ curl -L -X PATCH \
1042+ 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:water001/attrs/on' \
10321043-H 'NGSILD-Tenant: openiot' \
10331044-H 'Content-Type: application/json' \
10341045-H 'Link: <http://context/user-context.jsonld>; rel="http://www.w3.org/ns/json-ld#context"; type="application/ld+json"' \
@@ -1051,7 +1062,8 @@ To invoke the `start` command, the `start` attribute must be updated in the cont
10511062# ### 1️⃣5️⃣ Request:
10521063
10531064` ` ` console
1054- curl -L -X PATCH 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:tractor001/attrs/start' \
1065+ curl -L -X PATCH \
1066+ 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:tractor001/attrs/start' \
10551067 -H 'NGSILD-Tenant: openiot' \
10561068 -H 'Content-Type: application/json' \
10571069 -H 'Link: <http://context/user-context.jsonld>; rel="http://www.w3.org/ns/json-ld#context"; type="application/ld+json"' \
@@ -1070,7 +1082,8 @@ Change the state of the **Fillling System**, the `add` attribute must be updated
10701082# ### 1️⃣6️⃣ Request:
10711083
10721084` ` ` console
1073- curl -L -X PATCH 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:filling001/attrs/add' \
1085+ curl -L -X PATCH \
1086+ 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:filling001/attrs/add' \
10741087 -H 'NGSILD-Tenant: openiot' \
10751088 -H 'Content-Type: application/json' \
10761089 -H 'Link: <http://context/user-context.jsonld>; rel="http://www.w3.org/ns/json-ld#context"; type="application/ld+json"' \
0 commit comments