Klevr Product Documentation logo

Inbound Dataverse Stage

The Inbound Dataverse stage allows inbound payloads to be ingested from the Dataverse.

Stage Overview

The Inbound Dataverse stage allows inbound payloads to be ingested from the Dataverse.

Stage Definition File Location

All Inbound Dataverse stages are defined by creating an appropriately formatted JSON definition file in the following location:

interfaces
{businessUnitCode}
{domainCode}
{integrationName}
in
dv
{STAGE_NAME}.json

Stage JSON Definition File Format

The JSON definition file for an Inbound Dataverse stage is as follows:

{
  "name": "stage-name",
  "displayName": "Brief Stage Title",
  "description": "Brief description of the stage.",
  "enabled": "$env:STATUS_<INTEGRATION_NAME>",
  "concurrency": 10,
  "connectionClientId": "$env:DATAVERSE_CLIENT_ID",
  "connectionClientSecret": "$env:DATAVERSE_CLIENT_SECRET",
  "connectionTenantId": "$env:DATAVERSE_TENANT_ID",
  "environment": "$env:DATAVERSE_ENVIRONMENT_NAME",
  "changeType": "SEE CHANGE TYPE TABLE BELOW",
  "table": "tableName",
  "selectColumns": "columnName1,columnName2,columnName3",
  "filterExpression": "columnName1 eq 'Value'",
  "deduplicate": {
    "timeWindow": "HH:MM:SS",
    "schemaMessageId": "schemas/path/to/transform.liquid"
  },
  "preLogTransformSchemaFileName": "schemas/path/to/schema/schema-name.liquid",
  "preLogTransformSchemaType": "liquid|javascript",
  "preLogTransformFormat": "json|xml|csv"
}
PropertySub-PropertyDescription
nameThe name of the stage.
displayNameOptional (but highly recommended). A short (3 or 4 word) "display name" for the stage, used as a "title" of the stage in the Integration Hub Portal service's self-documentation capability.
descriptionOptional (but highly recommended). A brief (10 to 15 word) description of the stage, used as a brief description of the stage's purpose in the Integration Hub Portal service's self-documentation capability. For a more detailed explanation (when needed), use the stage markdown feature.
enabledOptional boolean flag (true or false). Default is true.

Generally set via a DevOps variable. Controls if the stage is deployed enabled or not.
concurrencyOptional number of concurrent runs permitted for the stage. Default is 10.
connectionClientIdThe Client ID of the Service Principal used to connect to the Dataverse. Generally set via a DevOps variable.
connectionClientSecretThe Client Secret for the Service Principal used to connect to the Dataverse. Generally set via a DevOps variable.
connectionTenantIdThe Tenant ID of the Service Principal used to connect to the Dataverse. Generally set via a DevOps variable.
environmentThe name of the D365 environment which contains the Dataverse service.
changeTypeRequired. See table below.
tableRequired. The table in Dataverse to monitor for events of the specified changeType value.
selectColumnsAn optional comma-separated list of Dataverse table column names. When set, only the provided columns will be considered when deciding if the change in the Dataverse table should trigger the in-dv stage to execute or not.

Column names in Dataverse can be difficult to get right (display name vs. schema name vs. logical name). It's recommended to start without this filter in place, and then review the payload details received in the stage before adding column name filtering.
filterExpressionAn optional Dataverse OData expression. When set, the in-dv stage run will only trigger if the supplied expression matches the Dataverse record's state.

Column names in Dataverse can be difficult to get right (display name vs. schema name vs. logical name), as are the values received for those columns (they will often not match display values). It's recommended to start without this filter in place, and then review the payload details received in the stage before adding OData filtering.
deduplicateInbound message de-duplication options, to allow incoming duplicate messages to be discarded.
timeWindowThe time window in which any duplicate payloads detected should be discarded. (Hours, minutes, and seconds.)
schemaMessageIdA filename that defines a Liquid transform, which will transform the received payload into a text string, which defines a unique ID for each message, allowing any duplicates of this unique ID received within the timeWindow to be discarded.

Pre-Logging Transformation

This stage supports the optional pre-logging transformation feature using the following fields:

  • preLogTransformSchemaFileName
  • preLogTransformSchemaType
  • preLogTransformFormat

See the Pre-Logging Transformation for details.

Change Type Values

Change TypeDescription
aAdded Only. Action will only fire when a record is added to the Dataverse table entered in the table attribute.
mModified Only. Action will only fire when a record is modified in the Dataverse table entered in the table attribute.
dDeleted Only. Action will only fire when a record is deleted from the Dataverse table entered in the table attribute.
amAdded or Modified. Action will only fire when a record is added to or modified in the Dataverse table entered in the table attribute.
adAdded or Deleted. Action will only fire when a record is added to or deleted from the Dataverse table entered in the table attribute.
mdModified or Deleted. Action will only fire when a record is modified in or deleted from the Dataverse table entered in the table attribute.
amdAdded, Modified, or Deleted. Action will fire when a record is added to, modified in, or deleted from the Dataverse table entered in the table attribute.

Last updated on