Question

9
Views
Close popover
Aravinth Thangavel (AravinthT)
Tata Consultancy Services

Tata Consultancy Services
MX
AravinthT Member since 2016 16 posts
Tata Consultancy Services
Posted: 3 weeks 5 days ago
Last activity: 3 weeks 5 days ago

In Connect-REST json, how to parse dynamic Key values with spaces in names

We have been trying to map a connect-rest response and we are facing the issues in parsing dynamic keys that we receive in response. The problem is that the key in the JSON both dynamic and it has space in the key.

Example - 1:

{"status": { "aaa 1234": "SUCCESS", "bbb 3456":"FAILED"}}

Example - 2:

{"status": { "def 1234": "SUCCESS", "ghi 3456":"FAILED"}}

The value "aaa 1234" changes for each case depending on the account details of the customer.

When we try to parse the above we observed two things:

Dynamic values can be parsed in Pega using value groups. But the problem is keys for value group cannot contain spaces. Therefore, it fails when we try to pase the above JSON.

Pega allows space in Keys for property names using pzExternalName qualifier but this is only for static values. We cannot use that for dynamic values.

 

Considering the above observations is there any other way we can parse the JSON.

 

Pega Platform 8.5.3 Data Integration Financial Services System Architect