Message Configuration: Define Parameters Manually (for JSON, XML, and URL-Encoded)
If you have selected JSON, XML, or URL-encoded as the payload type, you can add the tag parameters manually. Using the parameters you have entered, PCo then generates a template for the MQTT messages.
To be able to add parameters (tags) of the type object, do the following:
-
Choose
below the message configuration screen area.The Add Tag dialog box appears.
-
Enter the following data:
Adding a Tag Field
Description
Parent Parameter
The root parameter is displayed here: $out
Parameter
Here you enter the name of the parameter that you want to be used in the MQTT message. This might be a multilevel property name.
Data Type
You can enter the data type of the tag here.
Tag Name
You enter the tag name of your choice here.
The tags that are entered are displayed in the Message Configuration table.
-
To enter a parameter of type array, proceed as follows:
To specify that a specific parameter is an array, you have to add [0] to the parameter name to define the first array element. Alternatively, you can use a dynamic index, for example, by entering [i].
If you try to extend the same parameter again, the Array Configuration dialog box appears. You enter, for example, 1 in the Array Index field.