Symptoms

When trying to integrate Elements Connect Cloud with Microsoft Business Central (MS BC) you are facing issues such as failed connection tests via OAuth2 and errors like "invalid client" or "404" when Elements Connect tries to retrieve data.



Cause

Microsoft Business Central API does not accept the default "User-Agent" header sent by Elements Connect, leading to failed data retrieval attempts.

Resolution

To resolve the connectivity and data retrieval issues with Microsoft Business Central, follow these steps:

  1. Modify the Data Source Configuration: In your Elements Connect configuration for the data source connecting to Microsoft Business Central.
    Navigate to the data source configuration section and insert a "User-Agent" header with an empty value.
    This step is crucial as the default "User-Agent" value ("ECC/RestRequester/1.0") is not accepted by the Business Central API.

  2. Test the Connection Again: After updating the configuration, try to test the connection again.
    Ensure no errors occur at this stage to verify that the connection settings are correctly configured.

  3. Verify Data Retrieval Functionality: Attempt to retrieve data from Microsoft Business Central using Elements Connect Cloud.
    The addition of the custom "User-Agent" header should allow successful data communication between Elements Connect and Microsoft Business Central.