+ Start a Discussion
Natasha AliNatasha Ali 

Splitting of Address field into Address 1 & 2, City & Postcode for API connection


So we will be using an API to connect Salesforce to a third party app and one of the fields shared is Address. In Salesforce, the address is already concatenated (it comes in through a separate web app as Address Line, Address Line 2, City and Postcode). However the third party we want to connect to requires the Address field to be split. Is there some apex or mechnanism that would split the fields? Or anything that needs to be written into the API connections to enable this?

Any help is much appreciated :)
Many Thanks,
Khan AnasKhan Anas (Salesforce Developers) 
Hi Natasha,

Greetings to you!

Please refer to the below links which might help you further with the above requirement.




I hope it helps you.

Kindly let me know if it helps you and close your query by marking it as solved so that it can help others in the future. It will help to keep this community clean.

Thanks and Regards,
Khan Anas
Lokesh KumarLokesh Kumar
Are you connecting the standard account object? If yes, There are already these fields available as Billing City, Billing Country and so on.
Natasha AliNatasha Ali
Hi Lokesh,
The accounts are person accounts so I can't find those fields.

Many Thanks,
You can login to workbench and go to Standard & Custom Objects > Account > click on fields
There you can find the BillingAddress fields API individually like BillingStreet, BillingCity, BillingCountry...