When making calls to instances of Microsoft Dynamics 365, you may notice that some calls are very slow, often taking several seconds to complete. This scenario is usually a side-effect of using basic (username/password) authentication to create your Dynamics instance. Basic authentication connections require the handshake process to occur more frequently, particularly when the same username and password are used to log in elsewhere. This handshake process can add several seconds to API calls.
To fix this issue, we encourage users to use OAuth2 to create their instances. This prevents the issue of credentials being used elsewhere and thus requiring the handshake process to take place. For more information on how to create instances of Dynamics via OAuth2, see our documentation: https://developers.cloud-elements.com/docs/elements/dynamicscrm/#authenticating-with-cloud-elements.