How do I pass data (string) from one App to another App on Mac OS

I’m new to MAC OS and learning swift 3 programming. I have 2 apps and My requirement is to pass a string from one app to another app.

How do i accomplish it using swift 3?

Thanks’
wlan