Hi Guys

I am saving data via a Rest API, If I run the API in Postman the field saves, 

But if I run the API in OutSystems it doesn't update the boolean value.
It always saves my IsStudent field as True

Every time.

I check the info just before the API is hit and my info shows me that the data I am submitting is correct.
Showing False.
But then returns true. And I am receiving no errors. The API will even update all the other Json data but not the IsStudent Boolean

Hi Garth,

I'm tempted to say that there's some mapping of the REST JSON structure name going on. Did you log the actual JSON sent? Check for the name of the Attribute in the JSON. Also, check whether the "name in JSON" property of the Structure Attribute it set right.

Solution

So we came up with another solution.

The mapping was fine. 

If the data submitted is not True.
Then we set a default value of false which seemed to fix the problem.

We were unable to figure out the exact cause. 

But setting a default value fixed the problem.


Solution