ÃÛ¶¹ÊÓƵ

Configure Microsoft® Dynamics 365 for AEM Forms

ÃÛ¶¹ÊÓƵ Experience Manager Forms Data Integration provides a cloud service configuration to integrate forms with Microsoft Dynamics server. It enables you to create Form Data Model (FDM) based on the entities, attributes, and services defined in Microsoft Dynamics service. The Form Data Model (FDM) can be used to create Adaptive Forms that interact with Microsoft Dynamics server to enable business workflows. For example:

  • Query Microsoft Dynamics server for data and prepopulate Adaptive Forms.
  • Write data into Microsoft Dynamics on Adaptive Form submission.
  • Write data in Microsoft Dynamics through custom entities defined in Form Data Model (FDM).

AEM as a Cloud Service offers various out of the box submit actions for handling form submissions. You can learn more about these options in the Adaptive Form Submit Action article.

Prerequisites

Before integrating Microsoft® Dynamics 365 with AEM Forms as a Cloud Service, ensure that you have performed the following steps:

  1. Set up the account in Microsoft Dynamics 365

    Follow the steps explained in the video to set up a Microsoft Dynamics 365 account. In this video, a trial account is created for demonstration purposes.

    embed

    video poster

  2. Create an account in the Power Platform Admin Center
    Create an account in the Power Platform Admin Center to:

    • Add Dataverse
    • Enable Microsoft Dynamics 365 aaplications

    Follow the steps in the video to create an account in the Power Platform Admin Center. In this video, a trial account has been created for demonstration purposes.

    embed

    video poster

  3. Register an application for Microsoft® Dynamics 365 in Azure Active Directory

    Follow the steps in the video to register an application for Microsoft® Dynamics 365 in Azure Active Directory.

    embed

    video poster

    note note
    NOTE
    • To create the connected Microsoft® Dynamics 365 application, select Web as the platform and specify the Redirect URI in the following format: https://'[server]:[port]'/libs/fd/fdm/gui/components/admin/fdmcloudservice/fdm.html.
    • Make sure to save the Client ID (also known as the Application ID) and Client secret for future reference.

Connect Forms to Microsoft® Dynamics 365

Once you have configured the prerequisites above, you can proceed with integrating Adaptive Forms with Microsoft® Dynamics 365. To send data to Microsoft® Dynamics 365 on form submission, follow the below steps:

1. Configure cloud service configuration for Microsoft Dynamics

2. Create Form Data Model (FDM)

1. Configure cloud service configuration for Microsoft Dynamics

video poster

Perform the following steps to configure the Microsoft® Dynamics 365 cloud service configuration:

  1. Navigate to Tools hammer > Cloud Services > Data Sources on AEM Forms author instance,.

    Select Cloud Data Source

  2. Select a Configuration Container. The configuration is stored in the selected Configuration Container.

  3. Click Create.

    Create Cloud Configuration

    The Create Data Source Configuration configuration wizard appears.

    Create Data Source Configuration wizard

  4. Specify the Title, Name and select Service Type as OData Service.

  5. Click Next. The Authentication tab appears.

    Authentication Tab

  6. Specify the value for the Service Root field.

    Go to your Dynamics instance in the Power Platform Admin Center and navigate to to view the value of the Service Root. The Web API endpoint represents the Service Root value for the Dynamics instance you want to integrate with Adaptive Forms. The Service Root URL is in the following format: https://<tenant-name>.dynamics.com/api/data/v9.1/

    Service Root field

  7. Select the Authentication Type as OAuth2.0.

  8. Specify the Client ID (referred to as Application ID) and Client Secret for the connected application.
    You can retrieve the Client ID and Client Secret from the Azure Active Directory Application.

    Client ID and Client Secret

  9. Specify the following in the OAuth URL, Refresh Token URL, and Access Token URL fields.
    You can retrieve the OAuth URL, Refresh Token URL, and Access Token URL from the Endpoints section of your Azure Active Directory Application.

    Azure App Endpoints

  10. Specify openid in the Authorization Scope field for authorization process on Microsoft® Dynamics 365.

  11. Specify the dynamics instance URL in the Resource field to configure Microsoft® Dynamics 365 with a Form Data Model (FDM).
    You can copy the Environment URL from the Power Platform Admin Center or derive the Dynamics instance URL using the Service Root URL. The resource URL is in the following format: https://<tenant-name>.dynamics.com.

    Power App Resource Field

  12. Log in with your Microsoft® Dynamics 365 credentials and accept to allow the cloud service configuration to connect to Microsoft® Dynamics 365 service. If the connection is successful, you are redirected to the Microsoft® Dynamics 365 cloud service configuration page, which displays a success message.

  13. Select Create to save the configuration.

2. Create Form Data Model (FDM)

video poster

You can use the create the Form Data Model (FDM) using the created Microsoft® Dynamics 365 cloud configuration. Perform the following steps to create Form Data Model:

  1. Navigate to ÃÛ¶¹ÊÓƵ Experience Manager > Forms > Data Integrations.
    Create Form Data Model

  2. Click Create and select Form data Model.
    Select Form Data Model

    The Create Form Data Model wizard appears.

  3. Click Next.

  4. Select the created cloud configuration from the Select Datasource tab.
    Select Cloud Configuration

  5. Click the Edit Edit icon to view and configure the Form Data Model (FDM).

Next, you can configure the Form Data Model (FDM) and use it in various Adaptive Form use cases, such as:

  • Prefill Adaptive Form by querying information from Microsoft Dynamics entities and services
  • Invoke Microsoft Dynamics server operations defined in a Form Data Model (FDM) using Adaptive Form rules
  • Write submitted form data to Microsoft Dynamics entities
  • You can configure the Form Data Model Submit Action for an Adaptive Form to send data to Microsoft Dynamics.

You can then use the Submit using Form Data Model (FDM) option in an Adaptive Form to transfer data from your form to the configured Microsoft® Dynamics 365.

recommendation-more-help
fbcff2a9-b6fe-4574-b04a-21e75df764ab