Configure Data Source
AEM Forms Data Integration allows you to configure and connect to disparate data sources. The following types are supported out-of-the-box. However, with a little customization, you can integrate with other data sources as well.
- Relational databases - MySQL, Microsoft SQL Server, IBM DB2, and Oracle RDBMS
- AEM user profile
- RESTful web services
- SOAP-based web services
- OData services
For the integrating AEM Forms with Marketo, we are using RESTful web services. The first step in integrating is to configure a data source. Please use the swagger file provided as part of this tutorial. The following screenshot shows you the important properties that need to be specified while configuring the data source.
The “marketo.json” is the swagger file and is provided to you as part of this tutorial’s assets.
Property Host is specific to your Marketo instance.
Authentication Type is custom and Authentication Implementation has to match “AemForms With Marketo”. (Unless you have changed this in your code).
Create Form Data Model
After, configuring the data source the next step is to create a Form Data Model which is based on the data source configured in the earlier step. To create Form Data Model please follow the following steps:
Point your browser to the data integrations page. This lists all the data integrations created on your AEM instance.
- Click Create | Form Data Model
- Provide meaningful title such as FormsAndMarketo and click Next
- Select the data source that was configured in the earlier step and click create and edit to open the Form Data Model in the edit mode
- Expand the “FormsAndMarketo” node. Expand the Services node
- Select the first “Get” operation
- Click on Add Selected
- Click on “Select All” in the “Add Associated Model Objects” dialog box and then click on Add
- Save your form data model by clicking the Save button
- Tab to the Services tab
- Select the only service that is listed and click on Test Service
- Provide a valid leadId and click on Test. If everything goes well you should get back the lead details as shown in the screenshot below
Next Steps
Putting it all together for testing