Re: [Dev] How to handle an array of one

2019-04-23 Thread Arunan Sugunakumar
Hi Kanishka, It would be helpful if you can share the payload factory configuration. The scenario works fine according to the below configuration. http://ws.apache.org/ns/synapse; name="arrayCheck" context="/check1"> {"outerbody" : $1}

[Dev] How to handle an array of one

2019-04-23 Thread Kanishka Gunathilaka
Hi All, When I try to pass single item only array through payloadfactory or datamapper mediator it returns me array as an object. For example I am expecting following result. { “entity” : [ { “attr1” : “value”, “attr2” : “another value”} ] } But I am getting this response. { “entity” : {