Requirement for double quotes for properties instead of null
Malformed JSON request was generated on sending empty values to Boolean, Integer, Decimal or Double type properties and HFix-35253 was provided to resolve it. Post applying HFix-35253, Pega generates JSON request with null values for Boolean, Integer, Decimal or Double type properties when empty value is provided for these type of properties.
Requirement for double quotes ("") for the properties instead of null for the use case.
The below sample response is generated by Pega post installing HFix-35253:
User needs the response generated by Pega as below when empty values are sent to Boolean, Integer, Decimal or Double type properties:
Steps to Reproduce
- Install HFix-35253
- Create a Service-REST integration
- Return the empty value to the Boolean, Integer, Double and Decimal type properties as response of the Service-REST integration. The empty values for Boolean, Integer, Double and Decimal properties are replaced by null
This behavior is as per the JSON specifications.
Here’s the explanation for the reported behavior:
According to the JSON specification, null represents a missing or an empty value. Representing the empty or missing value as 'False', 0 or "" is incorrect.
0% found this useful