Create a Basic List Merge Example (Managed Package)

For the managed package runtime, the first Integration Procedure retrieves all Contacts with the same AccountId in two lists, one containing addresses, the other birthdates. It then merges the two lists into one.

Managed Package app icon This information is for Omnistudio for Managed Packages. For Omnistudio on standard runtime, see Omnistudio Help.

To download a DataPack of this example for Omnistudio for Managed Packages, click here.

The Integration Procedure has these components:

  1. An Omnistudio Data Mapper Extract Action component named DRExtractAddresses
  2. A Data Mapper Extract Action component named DRExtractBirthdates
  3. A List Merge Action named ListAction1
  4. A Response Action named ResponseAction1

The Structure panel looks like this:

The contents of the Structure panel are listed in the preceding text.

To build this Integration Procedure:

  1. Create the Data Mapper Extract that the DRExtractAddresses component calls. Name it GetAddresses and give it these settings:
    Extract A Contact extract step set to contact AccountId = id
    Output These mappings:
    • contact:Id to contact:id
    • contact:FirstName to contact:firstName
    • contact:LastName to contact:lastName
    • contact:MailingStreet to contact:street
    • contact:MailingCity to contact:city
    • contact:MailingState to contact:state
    If you aren't sure how to create a Data Mapper Extract, see the examples in Omnistudio Data Mapper Extract Examples (Managed Package).
  2. Create the Data Mapper Extract that the DRExtractBirthdates component calls:
    1. Clone the GetAddresses Data Mapper and name the clone GetBirthdates.
    2. On the Output tab, delete the city, state, and street mappings.
    3. Add a mapping from contact:Birthdate to contact:birthdate.
  3. From the Omnistudio Integration Procedures tab, click New.
  4. Provide an Integration Procedure Name, a Type, and a SubType, and click Save.
  5. Drag the first Data Mapper Extract Action component into the Structure panel.
  6. Give the component an Element Name of DRExtractAddresses and a Data Mapper Interface of GetAddresses.
  7. Drag the second Data Mapper Extract Action component into the Structure panel below the first.
  8. Give the component an Element Name of DRExtractBirthdates and a Data Mapper Interface of GetBirthdates.
  9. Drag a List Action component into the Structure panel below the second Data Mapper Extract Action component and give it these settings:
    MERGE LISTS ORDER
    • DRExtractAddresses:contact
    • DRExtractBirthdates:contact
    MERGE FIELDS id
    SORT BY
    • lastName
    • firstName
  10. Drag a Response Action component below all the others.
  11. Give the component a Send JSON Path of ListAction1 and a Send JSON Node of contactMerge.
  12. On the Preview tab, in the Input Parameters pane, click Add New Key/Value Pair.
  13. Enter id as the Key and an Account Id from your org as the Value.
  14. Click Execute.
    The output looks like this:
    {
      "contactMerge": [
        {
          "birthdate": "1975-10-03",
          "street": "300 Broadway",
          "state": "FL",
          "city": "Orlando",
          "lastName": "Jones",
          "id": "0036100001E5xrWAAR",
          "firstName": "Cathy"
        },
        {
          "birthdate": "1976-10-04",
          "street": "400 Washington Blvd",
          "state": "AZ",
          "city": "Phoenix",
          "lastName": "Jones",
          "id": "0036100001E5xrvAAB",
          "firstName": "Doug"
        },
        {
          "birthdate": "1973-10-01",
          "street": "100 Main Street",
          "state": "CA",
          "city": "San Francisco",
          "lastName": "Smith",
          "id": "0036100001E5xqnAAB",
          "firstName": "Albert"
        },
        {
          "birthdate": "1974-10-02",
          "street": "200 Second Street",
          "state": "OR",
          "city": "Portland",
          "lastName": "Smith",
          "id": "0036100001E5xr2AAB",
          "firstName": "Ben"
        }
      ]
    }