In this part we’re looking at connecting to a D365 environment.
Just like we did with the first part, we’re putting the connection code in a function. We’re doing this in order to be able to call it multiple times, depending on the environment we’re connecting to. Eventually, we’ll connect to both a source and a target environments.