When you enter XML which has more than one repeated adapters, our JSON converter converts the repeated adapters into a JSON array with different JSON objects within the array. Shown below is a sample XML response payload we received from a vendor:
In the above XML,
<GLENTRY> is repeated more than once and the JSON conversion is as shown below. The JSON converter converts the XML into a JSON array with multiple objects.
However, if the XML contains only one repeated adapter, the JSON converter converts the XML into an object instead of an array.
In order to avoid this from happening, you can now configure a parameter by adding the comma-separated JSON path of the repeated adapters in the XML and vendor's information field as xmlResponseArrayField as shown below.