Examples of Request Message Parameters (RESTful)
Example 1
|
Field |
Input |
|---|---|
|
Parameter Name |
device |
|
Parameter Type |
string |
|
Value |
ABF3209 |
|
Input Variable |
Checkbox not selected |
Result: With each request, PCo sends a parameter (fixed value) with the name device and the value ABF3209.
Example 2
|
Field |
Input |
|---|---|
|
Parameter Name |
sensor |
|
Parameter Type |
string |
|
Value |
sensorID |
|
Input Variable |
Checkbox selected |
Result: With each request, PCo sends a parameter (variable) with the name sensor. The value of this variable is filled dynamically using the mapping in the notification. In the notification, the field has the name sensorID.
Example 3
|
Field |
Input |
|---|---|
|
Parameter Name |
message[0].measurementvalue |
|
Parameter Type |
string |
|
Value |
measurementvalue |
|
Input Variable |
Checkbox selected |
|
Field |
Input |
|---|---|
|
Parameter Name |
message[0].unit |
|
Parameter Type |
string |
|
Value |
unit |
|
Input Variable |
Checkbox selected |
Result: We have now created a static array with only one entry. This entry consists of two lower-level entries:
-
Measured value
-
Unit
In the case of JSON, the array would look like this:
"message":[{"measurementvalue":"<value>", "unit":"<unit>"}]