Apex and Flow
I want to begin the chapter by having a brief discussion comparing Apex and Flow, talking about when to use each tool, and looking at the reason that Apex developers should be aware of Flow and its capabilities.
When Salesforce first launched Flow, it caused concern among some developers that there would be less investment in Apex and the Salesforce programmatic stack, that their jobs may be at risk if more work could be done declaratively, and that some of the rigor applied to programmatic solutions through practices such as unit testing would not be followed, leading to more brittle solutions.
Since its launch, Flow has grown and developed into a very capable automation tool that can handle many requirements quickly and effectively. The concerns of a lack of investment in Apex or loss of jobs have been found to be unwarranted, as Flow has opened up new integration and development opportunities (as we will see), as well as enabling developers to focus on delivering...