You need to sign in to do that
Don't have an account?
Admin User 1137
How to deserialize the below mentioned json format from Mule in Apex Salesforce ?
Could any one help me out with this ?
{
SalesDetails= [
{
"getVO":{
"Delivery_Date__c":" test";
"Salesman_Name__c":"test",
"Deal_Number__c":"test",
"Worksheet_Total__c":"test",
"Selling_Dealer__C":"test",
"Name":"UNREG",
"ContactName__c":"test"
},
"getVehicle":{
"Stock_No__c":"test",
"Name":"test",
"Engine_Number__c":"test",
"Rego_Number__c":"test",
"Make__c":"test",
"Model_Name__c":"test",
"Model_Description__c":"test",
"Colour__c":"test",
"Vehicle_Type__c":"test"
},
"getAccount":{
"Customer_ID__c":"test",
"First_Name__c":"test",
"Last_Name__c":"test",
"Salutation__c":"test",
"Business_Email__c":"test",
"Home_Email__c":"test",
"Date_of_Birth__c":test",
"License_Number__c":"test",
"Preferred_Name__c":"test",
"License_Expiry_Date__c":test",
"Selling_Dealer__c":"test",
"Contact_Type__c":"test",
"Name":"test",
"Business_Phone__c":"test",
"Business_Phone_Valid__c":true,
"Phone1__c":"test",
"Phone1_Valid__c":true,
"Home_Phone__c":"",
"Home_Phone_Valid__c":false,
"Mobile__c":"test",
"Mobile_Phone_Valid__c":true,
"Business_Email_Valid__c":true,
"Home_Email_Valid__c":true,
"Physical_Latitude__c":"test",
"Physical_Longitude__c":"test",
"Physical_Address__c":"test",
"Physical_Address_Valid__c":true,
"PhysicalDPID__c":"test",
"Physical_Suburb__c":"test",
"Physical_State__c":"test",
"Physical_Post_Code__c":"test",
"Eranet_Data_Time__c":test,
"Id":"test",
"Old_Customer_Id__c":"test",
"Physical_Country__c":"test"
},
"getContact":{
"Customer_ID__c":"test",
"Salutation":"test",
"Preferred_Name__c":"test",
"FirstName":"test",
"LastName":"test",
"Business_Email__c":"test",
"Home_Email__c":"test",
"Date_of_Birth__c":test,
"License_Number__c":"test",
"License_Expiry_Date__c":test,
"Selling_Dealer__c":"test",
"Business_Phone__c":"test",
"Business_Phone_Valid__c":test,
"Phone1__c":"test",
"Phone1_Valid__c":true,
"HomePhone":"",
"Home_Phone_Valid__c":false,
"MobilePhone":"test",
"Mobile_Phone_Valid__c":true,
"Business_Email_Valid__c":true,
"Home_Email_Valid__c":true,
"Physical_Latitude__c":"test",
"Physical_Longitude__c":"test",
"Physical_Address__c":"test",
"Physical_Address_Valid__c":true,
"PhysicalDPID__c":"test",
"Physical_Suburb__c":"test",
"Physical_State__c":"test",
"Physical_Post_Code__c":"test",
"Eranet_Data_Time__c":test,
"AccountId":"test",
"Id":"test",
"Old_Customer_Id__c":"test",
"Physical_Country__c":"test"
}
"getLead":{
"Id": "",
"Type": "test",
"AccountId":"",
"ContactID":"",
"OppurtunityFlag": "Yes"
},
"getOpportunityFields":{
"AccountId": "",
"AccountName": "",
"VehicleId": "",
"Model__c":"",
"Make__c": "",
"Selling_Dealership__c": "",
"Request_Type__c": "",
"Enrolled_Date__c": "",
"LeadSource": "",
"CampaignId": "",
"OpportunityName": "",
"OpportunityOwner": "",
"OpportunityStage": "Won",
"Closeddate": "",
"Status":"",
"Price__c": ""
},
"getlstLiveCampaignMemberId":
[
{
"LiveCMID": "test",
"Status": "test"
}
],
"getlstPrimaryCampaignMemberId":
[
{
"PrimaryCMID": "test",
"Status":"Closed"
}
]
}
],
TransactionId=dfd62371-766b-11e6-87eb-b82a72a03108
}
How to deserialize the below mentioned json format from Mule in Apex Salesforce ?
How to deserialize the below mentioned json format from Mule in Apex Salesforce ?
Could any one help me out with this ?
{
SalesDetails= [
{
"getVO":{
"Delivery_Date__c":" test";
"Salesman_Name__c":"test",
"Deal_Number__c":"test",
"Worksheet_Total__c":"test",
"Selling_Dealer__C":"test",
"Name":"UNREG",
"ContactName__c":"test"
},
"getVehicle":{
"Stock_No__c":"test",
"Name":"test",
"Engine_Number__c":"test",
"Rego_Number__c":"test",
"Make__c":"test",
"Model_Name__c":"test",
"Model_Description__c":"test",
"Colour__c":"test",
"Vehicle_Type__c":"test"
},
"getAccount":{
"Customer_ID__c":"test",
"First_Name__c":"test",
"Last_Name__c":"test",
"Salutation__c":"test",
"Business_Email__c":"test",
"Home_Email__c":"test",
"Date_of_Birth__c":test",
"License_Number__c":"test",
"Preferred_Name__c":"test",
"License_Expiry_Date__c":test",
"Selling_Dealer__c":"test",
"Contact_Type__c":"test",
"Name":"test",
"Business_Phone__c":"test",
"Business_Phone_Valid__c":true,
"Phone1__c":"test",
"Phone1_Valid__c":true,
"Home_Phone__c":"",
"Home_Phone_Valid__c":false,
"Mobile__c":"test",
"Mobile_Phone_Valid__c":true,
"Business_Email_Valid__c":true,
"Home_Email_Valid__c":true,
"Physical_Latitude__c":"test",
"Physical_Longitude__c":"test",
"Physical_Address__c":"test",
"Physical_Address_Valid__c":true,
"PhysicalDPID__c":"test",
"Physical_Suburb__c":"test",
"Physical_State__c":"test",
"Physical_Post_Code__c":"test",
"Eranet_Data_Time__c":test,
"Id":"test",
"Old_Customer_Id__c":"test",
"Physical_Country__c":"test"
},
"getContact":{
"Customer_ID__c":"test",
"Salutation":"test",
"Preferred_Name__c":"test",
"FirstName":"test",
"LastName":"test",
"Business_Email__c":"test",
"Home_Email__c":"test",
"Date_of_Birth__c":test,
"License_Number__c":"test",
"License_Expiry_Date__c":test,
"Selling_Dealer__c":"test",
"Business_Phone__c":"test",
"Business_Phone_Valid__c":test,
"Phone1__c":"test",
"Phone1_Valid__c":true,
"HomePhone":"",
"Home_Phone_Valid__c":false,
"MobilePhone":"test",
"Mobile_Phone_Valid__c":true,
"Business_Email_Valid__c":true,
"Home_Email_Valid__c":true,
"Physical_Latitude__c":"test",
"Physical_Longitude__c":"test",
"Physical_Address__c":"test",
"Physical_Address_Valid__c":true,
"PhysicalDPID__c":"test",
"Physical_Suburb__c":"test",
"Physical_State__c":"test",
"Physical_Post_Code__c":"test",
"Eranet_Data_Time__c":test,
"AccountId":"test",
"Id":"test",
"Old_Customer_Id__c":"test",
"Physical_Country__c":"test"
}
"getLead":{
"Id": "",
"Type": "test",
"AccountId":"",
"ContactID":"",
"OppurtunityFlag": "Yes"
},
"getOpportunityFields":{
"AccountId": "",
"AccountName": "",
"VehicleId": "",
"Model__c":"",
"Make__c": "",
"Selling_Dealership__c": "",
"Request_Type__c": "",
"Enrolled_Date__c": "",
"LeadSource": "",
"CampaignId": "",
"OpportunityName": "",
"OpportunityOwner": "",
"OpportunityStage": "Won",
"Closeddate": "",
"Status":"",
"Price__c": ""
},
"getlstLiveCampaignMemberId":
[
{
"LiveCMID": "test",
"Status": "test"
}
],
"getlstPrimaryCampaignMemberId":
[
{
"PrimaryCMID": "test",
"Status":"Closed"
}
]
}
],
TransactionId=dfd62371-766b-11e6-87eb-b82a72a03108
}
Below is the sample code but not exact code,
replace jsonInput with above mule JSON string. make same formate. and try
Hope this will help you,
Thanks
karthik