Skip to content

Configuring an App Registration in Azure

The following steps need to be completed to create an App Registration in DPS by Simova. An App Registration is required by DPS, to be able to use all of the features that are available in DPS.

Info

To perform this setup, it is necessary for the administrator account to be present in both Business Central and Azure Portal as only administrators have the necessary privileges.

Business Central (SaaS)

An App Registration Wizard is available in DPS by Simova to configure an App Registration in DPS. The App Registration Wizard will guide you to create a new App Registration for DPS or using an existing App Registration. The following steps to configure the App Registration in DPS for Business Central in SaaS environment.

  1. Navigate to DPS - Setup.
  2. Click on the Configure App Registration action in the DPS - Setup to proceed.
  3. Click on Begin to start the configuration of the App Registration.
  4. Choose either to Create a new App Registration or to Use an existing App Registration.

Create New App Registration

The following steps will guide you on how to create a new App Registration for DPS through the App Registration Wizard.

  1. If a pop-up to sign in appears, make sure to sign in with an administrator account in both DPS and Azure to continue with the creation of the App Registration.
  2. Enter a name for the App Registration in the App Registration Name field.
  3. Clicking on Next will start the creation process of the App Registration in Azure. This process will create all the necessary permissions and credentials to be used by DPS.
  4. A pop-up will appear to create a new user in the Azure Active Directory Application. CLick on Yes to continue with the creation of the App Registration.
  5. You will be navigated to the Azure Active Directory Application page where you can click on the Grant Consent action button to provide administrator consent and permissions in Azure. If a pop-up appears. Make sure to sign in with an administrator account in both DPS and Azure.
  6. Close the Azure Active Directory Application page, and the App Registration Wizard will be automatically navigated to the next step.
  7. The Client Secret of the App Registration will be shown only once. Please take a note of the Client Secret. You will not be able to go back to this step once you click on Next.
  8. Click on Next to continue.
  9. The configuration of the App Registration is now complete. Click on Finish to close the App Registration Wizard.

Use Existing App Registration

The following steps will guide you on how to use an existing App Registration for DPS through the App Registration Wizard.

  1. If a pop-up to sign in appears, make sure to sign in with an administrator account in both DPS and Azure to continue with the creation of the App Registration.
  2. Enter the App Registration Name of the App Registration you want to use in the App Registration Name field or use the lookup function to look for all existing App Registrations in your Azure tenant.

Using the lookup to enter the App Registration data automatically

  1. Choose an App Registration via the lookup, the wizard will automatically fill all of the necessary fields in the App Registration Wizard, except for the Client Secret.
  2. Enter the Client Secret of the selected App Registration in the Client Secret field. If the Client Secret is correct, the Next button will be enabled to proceed with the configuration of the App Registration.

Entering the App Registration data manually

  1. Enter the App Registration Name of the App Registration you want to use in the App Registration Name field.
  2. Enter the Application (client) ID of the App Registration you want to use in the Client ID field.
  3. Enter the Client Secret of the App Registration you want to use in the Client Secret field.
  4. Enter the Directory (tenant) ID of the App Registration you want to use in the Tenant ID field.
  5. Enter the Redirect URL of the App Registration you want to use in the Redirect URL field. In SaaS environment, the Redirect URL should be https://businesscentral.dynamics.com/OAuthLanding.htm.
  6. Enter the Service Principal ID of the App Registration you want to use in the Service Principal ID field.
  7. Click on Next to proceed with the configuration. If the Next button is disabled, make sure that all of the fields are filled in correctly.

Info

To get the Service Principal ID the following steps can be followed :

  1. In the Azure Portal, navigate to Enterprise applications.
  2. Change the filter to Application type == All Applications.
  3. Search for the App Registration you want to use.
  4. Click on the App Registration to open the App Registration page.
  5. Copy the Object ID from the Overview page. The Object ID is the Service Principal ID.

Warning

Existing App Registration will be overwritten upon finishing the App Registration Wizard.

Renewing an App Registration credentials

The Client Secret have an expiration date. The credentials can be renewed automatically without the need for the administrator to go to the Azure Portal by using the action Renew Secret. The following steps will guide you on how to renew the credentials of an App Registration.

  1. Navigate to the DPS - Setup.
  2. Click on the Renew Secret to start the renewal process.
  3. Once the renewal process is finished, a message will be shown to inform the user that the renewal process is successful, and the new Client Secret will be shown once. An administrator can take a note of the new Client Secret for future use.
  4. Click on OK to close the message, and the new Client Secret will be saved and used by DPS automatically.

Info

The new Client Secret will be automatically applied to the other companies in Business Central, when the company shares the same App Registration data.

Business Central (On-Premise)

Creating the App Registration automatically from Business Central On-Premise is not feasible. Therefore, the creation of the App Registration needs to be done manually through the Azure Portal.

Creating the Azure App Registration in Azure Portal

The following steps will guide you on how to create a new App Registration for DPS in Azure Portal.

  1. Log in to the Azure Portal at Azure Portal.
  2. Click on the Azure Active Directory icon in the left-hand navigation menu.
  3. In the Azure Active Directory menu, click on App Registrations.
  4. Click the New registration button.
  5. Enter the name DPS by Simova in the Name field.
  6. Choose the appropriate Supported account types option for the app registration.
  7. Enter the appropriate Redirect URI for your app registration. This is the URI that Azure AD will redirect the user to after authentication. The URI should be set to Web for the platform and written in the following format https://external Business Central address/BC/OAuthLanding.htm.
  8. Click the Register button to create the app registration.
  9. On the app registration page, note the Application (client) ID and Directory (tenant) ID. This is the unique identifier for your app registration that you will need to use when configuring your DPS by Simova in Business Central.
  10. Under the Certificates & secrets tab, click New client secret to create a new secret that will be used to authenticate your app with Azure AD.
  11. Enter a description for the secret, select an expiration date, and click Add.
  12. Note the generated secret value, as it will only be displayed once and cannot be retrieved later. Please take a note of the secret value as it is needed to configure DPS by Simova in Business Central.
  13. Under the API permissions tab, click Add a permission and add the following permissions.

    Permission group API / Permission name Type Description
    Azure Service Management user_impersonation Delegated Access Azure Service Management as organization users
    Dynamics 365 Business Central API.ReadWrite.All Application Full access to web services API
    Dynamics 365 Business Central Automation.ReadWrite.All Application Full access to automation
    Microsoft Graph User.Read Application Read all users' profiles
  14. Click the Grant admin consent button to grant the permission an admin consent.

Adding role to a Subscription

Assigning DPS by Simova app a role in a subcription is necessary to enable them to have access to the a App Service.

Info

The role assignment could only be done by an administrator account.

  1. Log in to the Azure Portal at Azure Portal.
  2. Search for Subscriptions using the search bar.
  3. If you have multiple subscriptions, select the one intended for Azure Blob Storage since a storage account must have a subscription.
  4. Go to the Access control (IAM) tab and click on the Role assignment tab.
  5. Click Add button and select Add role assignment.
  6. Under the Role tab, choose the Contributor role and click Next.
  7. Click the Select members button under the Members tab, then add DPS by Simova.
  8. Click on Review + assign to complete the role assignment process.

Entering the Azure App Registration information in Business Central

The following steps will guide you on how to configure the App Registration for DPS through the App Registration Wizard.

  1. Navigate to DPS - Setup.
  2. Click on the Configure App Registration action in the DPS - Setup to proceed.
  3. An App Registration Wizard will appear. Click on Begin to start the configuration.
  4. To continue this step, it is necessary to already have an App Registration prepared for DPS. If you have not created an App Registration for DPS, please refer to the Creating the Azure App Registration in Azure Portal section.
  5. Fill the App Registration Name, Client ID, Client Secret, Tenant ID, and Redirect URL fields.
  6. Once all fields are filled correctly, click on Next to proceed with the configuration.
  7. Upon clicking Finish the changes will be applied to the App Registration settings in DPS.

Warning

  • If the App Registration is not configured correctly, the DPS by Simova will not be able to function properly in some area.
  • Existing App Registration will be overwritten upon finishing the App Registration Wizard.