@@ -598,7 +598,8 @@ Three types of measurement attributes can be provisioned:
598598# ### 3️⃣ Request:
599599
600600` ` ` console
601- curl -L -X POST 'http://localhost:4041/iot/devices' \
601+ curl -L -X POST \
602+ 'http://localhost:4041/iot/devices' \
602603 -H 'fiware-service: openiot' \
603604 -H 'fiware-servicepath: /' \
604605 -H 'Content-Type: application/json' \
@@ -667,7 +668,8 @@ making the following request
667668# ### 4️⃣ Request:
668669
669670` ` ` console
670- curl -L -X POST 'http://localhost:7896/iot/d?k=4jggokgpepnvsb2uv4s40d59ov&i=temperature001' \
671+ curl -L -X POST \
672+ 'http://localhost:7896/iot/d?k=4jggokgpepnvsb2uv4s40d59ov&i=temperature001' \
671673 -H 'Content-Type: text/plain' \
672674 --data-raw 't|3'
673675` ` `
@@ -689,11 +691,12 @@ add the `fiware-service` and `fiware-service-path` headers.
689691# ### 5️⃣ Request:
690692
691693` ` ` console
692- curl -G -iX GET 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:temperature001' \
694+ curl -G -iX GET \
695+ 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:temperature001' \
693696 -H 'NGSILD-Tenant: openiot' \
694697 -H 'Accept: application/ld+json' \
695698 -H 'Link: <http://context/user-context.jsonld>; rel="http://www.w3.org/ns/json-ld#context"; type="application/ld+json"' \
696- -d 'attrs= temperature'
699+ -d 'pick=id,type, temperature'
697700` ` `
698701
699702# ### Response:
@@ -743,7 +746,8 @@ based on the knowledge of the service group
743746# ### 7️⃣ Request:
744747
745748` ` ` console
746- curl -L -X GET 'http://localhost:1026/ngsi-ld/v1/entities/?type=Device' \
749+ curl -L -X GET \
750+ 'http://localhost:1026/ngsi-ld/v1/entities/?type=Device' \
747751 -H 'NGSILD-Tenant: openiot' \
748752 -H 'Accept: application/ld+json' \
749753 -H 'Link: <http://context/user-context.jsonld>; rel="http://www.w3.org/ns/json-ld#context"; type="application/ld+json"'
@@ -794,7 +798,8 @@ communications protocol to be used.
794798# ### 8️⃣ Request:
795799
796800` ` ` console
797- curl -L -X POST 'http://localhost:4041/iot/devices' \
801+ curl -L -X POST \
802+ 'http://localhost:4041/iot/devices' \
798803 -H 'fiware-service: openiot' \
799804 -H 'fiware-servicepath: /' \
800805 -H 'Content-Type: application/json' \
@@ -835,7 +840,8 @@ command directly as shown:
835840# ### 9️⃣ Request:
836841
837842` ` ` console
838- curl -L -X PATCH 'http://localhost:4041/ngsi-ld/v1/entities/urn:ngsi-ld:Device:water001/attrs/on' \
843+ curl -L -X PATCH \
844+ 'http://localhost:4041/ngsi-ld/v1/entities/urn:ngsi-ld:Device:water001/attrs/on' \
839845 -H 'fiware-service: openiot' \
840846 -H 'fiware-servicepath: /' \
841847 -H 'Content-Type: application/json' \
@@ -856,7 +862,8 @@ The result of the command to turn on the irrigation system can be read by queryi
856862# ### 1️⃣0️⃣ Request:
857863
858864` ` ` console
859- curl -L -X GET 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:water001' \
865+ curl -L -X GET \
866+ 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:water001' \
860867 -H 'NGSILD-Tenant: openiot' \
861868 -H 'Link: <http://context/user-context.jsonld>; rel="http://www.w3.org/ns/json-ld#context"; type="application/ld+json"' \
862869 -H 'Accept: application/json'
@@ -903,7 +910,8 @@ both `attributes` and `command` attributes in the body of the request.
903910# ### 1️⃣1️⃣ Request:
904911
905912` ` ` console
906- curl -L -X POST 'http://localhost:4041/iot/devices' \
913+ curl -L -X POST \
914+ 'http://localhost:4041/iot/devices' \
907915-H 'fiware-service: openiot' \
908916-H 'fiware-servicepath: /' \
909917-H 'Content-Type: application/json' \
@@ -959,7 +967,8 @@ Similarly, a **Tractor** with two commands (`start` and `stop`) and two attribut
959967# ### 1️⃣2️⃣ Request:
960968
961969` ` ` console
962- curl -L -X POST 'http://localhost:4041/iot/devices' \
970+ curl -L -X POST \
971+ 'http://localhost:4041/iot/devices' \
963972 -H 'fiware-service: openiot' \
964973 -H 'fiware-servicepath: /' \
965974 -H 'Content-Type: application/json' \
@@ -994,7 +1003,8 @@ The full list of provisioned devices can be obtained by making a GET request to
9941003# ### 1️⃣3️⃣ Request:
9951004
9961005` ` ` console
997- curl -L -X GET 'http://localhost:4041/iot/devices' \
1006+ curl -L -X GET \
1007+ 'http://localhost:4041/iot/devices' \
9981008 -H 'fiware-service: openiot' \
9991009 -H 'fiware-servicepath: /'
10001010` ` `
@@ -1017,7 +1027,8 @@ To invoke the `on` command, the `on` attribute must be updated in the context.
10171027# ### 1️⃣4️⃣ Request:
10181028
10191029` ` ` console
1020- curl -L -X PATCH 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:water001/attrs/on' \
1030+ curl -L -X PATCH \
1031+ 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:water001/attrs/on' \
10211032-H 'NGSILD-Tenant: openiot' \
10221033-H 'Content-Type: application/json' \
10231034-H 'Link: <http://context/user-context.jsonld>; rel="http://www.w3.org/ns/json-ld#context"; type="application/ld+json"' \
@@ -1040,7 +1051,8 @@ To invoke the `start` command, the `start` attribute must be updated in the cont
10401051# ### 1️⃣5️⃣ Request:
10411052
10421053` ` ` console
1043- curl -L -X PATCH 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:tractor001/attrs/start' \
1054+ curl -L -X PATCH \
1055+ 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:tractor001/attrs/start' \
10441056 -H 'NGSILD-Tenant: openiot' \
10451057 -H 'Content-Type: application/json' \
10461058 -H 'Link: <http://context/user-context.jsonld>; rel="http://www.w3.org/ns/json-ld#context"; type="application/ld+json"' \
@@ -1059,7 +1071,8 @@ Change the state of the **Fillling System**, the `add` attribute must be updated
10591071# ### 1️⃣6️⃣ Request:
10601072
10611073` ` ` console
1062- curl -L -X PATCH 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:filling001/attrs/add' \
1074+ curl -L -X PATCH \
1075+ 'http://localhost:1026/ngsi-ld/v1/entities/urn:ngsi-ld:Device:filling001/attrs/add' \
10631076 -H 'NGSILD-Tenant: openiot' \
10641077 -H 'Content-Type: application/json' \
10651078 -H 'Link: <http://context/user-context.jsonld>; rel="http://www.w3.org/ns/json-ld#context"; type="application/ld+json"' \
0 commit comments