Swamulu Bandhamneni (BANDHAMNENI)
Tech Lead
BANDHAMNENI Member since 2012 3 posts
Posted: August 28, 2018
Last activity: September 17, 2018
Posted: 28 Aug 2018 3:35 EDT
Last activity: 17 Sep 2018 7:09 EDT

encloses decimal property values double quotes json response


We are generating JSON response object using pxConvertPageToString function and passing parameter format as JSON. This function is enclosing double quotes around all the property types (Decimal, Date, Boolean, Integer) and making it as a string. The consuming system is taking it as String instead of its original property type.

By using Map from as JSON on the response tab of the Service REST rule will work, but we have many API's so, we have generic code to send a response back instead of mapping every rest rule.

Ex: I have a property; Amount' of type Decimal. This property has to be incorporated into JSON as Decimal, but getJSON() method forming JSON object with Amount as String.

JSON Output:

{"ServiceFee": {

"Amount": "200.25",

"CurrencyCode": "USD"


Is there any way to get rid of the double quotes in JSON and rather than converting it to String, can we form the JSON object with its original property types.

***Moderator Edit-Vidyaranjan: Updated Platform Capability***

Data Integration
Moderation Team has archived post, This thread is closed to future replies. Content and links will no longer be updated. If you have the same/similar Question, please write a new Question.