Thanks @avinash_gupta_ and @_manoj_kumar_ , Please refer below source data and transferred data. Here, Source data transferred using NodeJS in the XDM format.
Needs to do same transformation using JAVA, Kindly share your thoughts.
Appreciate your supports !
Source Data:
{
"myPlace": "AWS",
"account": "12378",
"PlannedDate": "2022-11-02T09:14:57Z",
"delayDays": "2",
"assetType": "mobile"
}
Transformed Data:
{
"header": {
"schemaRef": {
"id": "https://ns.adobe.com/test/schemas/f1234567",
"contentType": "application/vnd.adobe.xed-full+json;version=1.0"
},
"source": {
"name": "aws"
}
},
"body": {
"xdmMeta": {
"schemaRef": {
"id": "https://ns.adobe.com/test/schemas/f1234567",
"contentType": "application/vnd.adobe.xed-full+json;version=1.0"
}
},
"xdmEntity": {
"myType": "mobile",
"_id": "sdsdsd1234",
"_mobile": {
"group": {
"my_place": "AWS",
"delay_days": 2,
"planned_date": "2022-11-02T09:14:57.000+00:00"
},
"my_group": {
"account": "12378",
"encrypted_account": "+a23def=="
}
},
"time": "2022-11-02T09:14:57.000+00:00"
}
}
}
Hi @arulprakashve
I don't think there is any OOB feature available in AEP to transform your source JSON. You would have to write your own custom utility in java to transform the JSON. Various methods are available like Google GSON, Jackson in java that you can use to transform the JSON.
https://mkyong.com/java/how-do-convert-java-object-to-from-json-format-gson-api/
https://mkyong.com/java/jackson-2-convert-java-object-to-from-json/
Hope this helps.