How to convert JSON format to String format

Hi All,

I have requirement which i need to convert below mentioned JSON format to..

{
  "requestId": "221a0000-faff-00e3-ac11-dbe6ebd00d00",
  "sourceSystemName": "ABCD",
  "requestDateTime": "2023-08-23T15:03:31.919Z",
  "requestInitiator": "App Name",
  "context": "/fetchData",
  "data": {
    "kind": "fetchDataRequest",
    "items": [
      {
        "item": {
          "key": "ID",
          "value": [
            "1234567890"
          ]
        }
      },
      {
        "item": {
          "key": "CRITERIA",
          "value": [
            "EMPLOYEEDETAILS",
            "INCLUDEIDDETAILS"
          ]
        }
      }
    ]
  }
}

.. this string format:

"{
""requestId"": ""221a0000-faff-00e3-ac11-dbe6ebd00d00"",
""sourceSystemName"": ""ABCD"",
""requestDateTime"": ""2023-08-23T15:03:31.919Z"",
""requestInitiator"": ""App Name"",
""context"": ""/fetchData"",
""data"": {
""kind"": ""fetchDataRequest"",
""items"": [
{
""item"": {
""key"": ""ID"",
""value"": [
""1234567890""
]
}
},
{
""item"": {
""key"": ""CRITERIA"",
""value"": [
""EMPLOYEEDETAILS"",
""INCLUDEIDDETAILS""
]
}
}
]
}
}"

How to achieve this? After converting i need to pass in Request Body of integration to get data.

Regards,
Sandeep

  Discussion posts and replies are publicly visible