HomeGuidesRecipesAPI
HomeGuidesAPILog In

Data Parse Action

The Data Parse Action has been developed to enable clients to extract value from a JSON or XML data.

Features

  • Extract value from JSON data

The Data Parse Action lets you extract relevant information from JSON data using JPath expressions.

  • Extract value from XML data

The Data Parse Action lets you extract relevant information from XML data using XPath expressions.

Installation Requirements

Before installing or upgrading this extension you must consider the following requirements:

  • You must have administrator/elevated permissions to the Infiniti web server, including the ability to copy and replace files in the Infiniti installation folder. This is usually c:\inetpub\wwwroot\infiniti however may vary from system to system.

  • You must have the following installation file: DataParseExtension.dll

Installing the Action

Use the instructions below to install the action. If you are upgrading the action from a previous version, refer to the section Upgrading the Action below.

Note that [Infiniti Produce Path] refers to the installation path on the web server running Infiniti, where the Produce site has been installed. By default this is c:\inetpub\wwwroot\infiniti\produce however path may vary from environment to environment. Equally, [Infiniti Manage Path] refers to where the Manage site has been installed, and [IntelledoxScheduler Path] refers to the where the Intelledox Scheduler service has been installed.

How to install the Data Parse Action in Infiniti v9

  1. Copy the files listed above into the following folder on the Infiniti web server:
    [Infiniti Produce Path]\bin
  2. Using a text editor such as Notepad, open the following file:
    [Infiniti Produce Path]\web.config

📘

Note

Ensure you have elevated privileges when opening the web.config file, otherwise you may not be able to save in the current folder.

  1. Locate the <action> section of the web.config file. It should appear similar to the following, and may include reference to different action providers:
<action>
    <providers>
    </providers>
</action>
  1. Within this block, before the ‘’ end tag, add the following:
<add name="DataParseExtension" type="DataParseExtension.DataParseAction, DataParseExtension" />
  1. Save and close the web.config file.

  2. Using a web browser, navigate to the Infiniti Produce application to allow the system to register the action.

How to install the Data Parse Action in Infiniti v10

  1. Copy the files listed above into the following folder on the Infiniti web server:
    [Infiniti Produce Path]\bin

  2. Using a text editor such as Notepad, open the following file:
    [Infiniti Produce Path]\appsettings.json

  3. Locate the <Extensions> section of the appsettings.json file and add the following entries:

"Intelledox.Action.LegacyAction`1[[DataParseExtension.DataParseAction, DataParseExtension]], Intelledox.Action"

Produce appsettings.json file should look like:

{
  "Extensions": [
    "Intelledox.Extension.DatasourceBuiltin.OleDbDatasource, Intelledox.Extension.DatasourceBuiltin",
    "Intelledox.Extension.DatasourceBuiltin.SqlServerDatasource, Intelledox.Extension.DatasourceBuiltin",
    "Intelledox.Extension.DatasourceBuiltin.CsvDatasource, Intelledox.Extension.DatasourceBuiltin",
    "Intelledox.Extension.DatasourceBuiltin.OdbcDatasource, Intelledox.Extension.DatasourceBuiltin",
    "Intelledox.Extension.DatasourceBuiltin.RSSDatasource, Intelledox.Extension.DatasourceBuiltin",
    "Intelledox.Extension.DatasourceBuiltin.WebserviceDatasource, Intelledox.Extension.DatasourceBuiltin",
    "Intelledox.Extension.DatasourceBuiltin.XmlDatasource, Intelledox.Extension.DatasourceBuiltin",
    "Intelledox.Extension.DatasourceBuiltin.InfinitiDatasource, Intelledox.Extension.DatasourceBuiltin",
    "Intelledox.Extension.DatasourceBuiltin.JsonDatasource, Intelledox.Extension.DatasourceBuiltin",
    "Intelledox.Extension.DatasourceBuiltin.RestDatasource, Intelledox.Extension.DatasourceBuiltin",
    "Intelledox.Extension.ActionBuiltin.FileAction, Intelledox.Extension.ActionBuiltin",
    "Intelledox.Extension.ActionBuiltin.SQLServerAction, Intelledox.Extension.ActionBuiltin",
    "Intelledox.Extension.ActionBuiltin.DownloadPageMessageAction, Intelledox.Extension.ActionBuiltin",
    "Intelledox.Extension.ActionBuiltin.RedirectAction, Intelledox.Extension.ActionBuiltin",
    "Intelledox.Extension.ActionBuiltin.EmailAction, Intelledox.Extension.ActionBuiltin",
    "Intelledox.Extension.ActionBuiltin.PrintAction, Intelledox.Extension.ActionBuiltin",
    "Intelledox.Extension.ActionBuiltin.UserAction, Intelledox.Extension.ActionBuiltin",
    "Intelledox.Extension.ActionBuiltin.WebhookAction, Intelledox.Extension.ActionBuiltin",
    "Intelledox.Extension.ActionBuiltin.RESTAction, Intelledox.Extension.ActionBuiltin",
    "Intelledox.Extension.ActionBuiltin.OracleAction, Intelledox.Extension.ActionBuiltin",
    "Intelledox.Extension.ActionBuiltin.PushNotificationAction, Intelledox.Extension.ActionBuiltin",
    "Intelledox.Extension.EscalationBuiltin.EmailEscalation, Intelledox.Extension.EscalationBuiltin",
    "Intelledox.Extension.EscalationBuiltin.ReassignmentEscalation, Intelledox.Extension.EscalationBuiltin",
    "Intelledox.Extension.EscalationBuiltin.PushNotificationEscalation, Intelledox.Extension.EscalationBuiltin", 
    
"Intelledox.Action.LegacyAction`1[[DataParseExtension.DataParseAction, DataParseExtension]], Intelledox.Action"
  ],
  "Authentication": {
    "Settings": {
      "CookiePrefix": "infiniti",
      "Timeout": "30"
    }
  },
  "LegacyDatasources": {
    "Dynamics365Extension.DynamicsDataProvider, Dynamics365Extension": {
      "name": "Dynamics 365"
    }
	}
}
  1. Save and close the appsettings.json file.

  2. Using a web browser, navigate to the Infiniti Produce application to allow the system to register the action.

The Data Parse Action should now be installed ready for configuration and usage.

Upgrading the Action

  1. Copy the files listed above into the following folders on the Infiniti web server, overwriting the existing files:
    [Infiniti Produce Path]\bin
  2. Using a web browser, navigate to the Infiniti Produce application to allow the system to register the upgraded action.

Installation to Intelledox Scheduler

If the target environment is using the Intelledox Scheduler, it is best practice to always install actions and accelerators to this service at the same time as the installation in Infiniti Produce application. If this is not installed to the Intelledox Scheduler there may be errors if any projects are executed from the scheduler that refers to this action.

To install any action to the Intelledox Scheduler, follow the instructions in this guide as they apply to Infiniti Produce, except instead of [Infiniti Produce Path] use [IntelledoxScheduler Path], noting that there is no ‘bin’ folder in this path so all files should be copied into the root of this path. For example, consider the path:
c:\inetpub\wwwroot\infiniti\produce\bin

To install to the Intelledox Scheduler, simply use this path:

c:\inetpub\wwwroot\infiniti\intelledoxscheduler

Also, you must apply the same configuration changes as instructed for the Produce appsettings.json or web.config file, except to the IntelledoxScheduler.exe.config file.

Using the action in Design

Once you’ve added the Data Parse Action to your project, either on the Finish page or on a workflow transition, use the following table to configure any action attributes that you require.

Action Attributes

NameDescription
DataThe JSON or XML data.
PathEnter XPath to extract value from XML data or JPath to extract valude from JSON data.
File Format [json/xml]File format of the data. By default, this will be set to JSON.

📘

Note

With XML Data, if your XML have custom namespaces, you would need to use the local-name() function for the XPath to work.

e.g. /[local-name()='string']/[local-name()='NewDataSet']/[local-name()='Table'][1]/[local-name()='Country']

See this for more information regarding local-name() function.