Technology. People. Progress.
Dynamics 365

Create a fulfilment provider in Dynamics 365 IOM

Configure the provider for the order-to-fulfilment process.

Create a fulfilment provider in Dynamics 365 IOM

Microsoft Dynamics 365 Intelligent Order Management IOM Step by Step Tutorial

Follow Below Steps

Step 1 - COMPLETEDCreate the free 30 Days Trial Version Environment for the Microsoft Dynamics 365 Intelligent Order Management

Step 2 - COMPLETEDSet up an IOM environment / Configure platform connection references in Microsoft Dynamics 365 Intelligent order Management

Step 3 - COMPLETEDCreate a new solution for PROVIDER Customization in Microsoft Dynamics 365 IOM / Create a provider solution

Step 4 - COMPLETEDCreate RequestBin Custom connector (Power Platform) for Step by Step Microsoft IOM Tutorial

Step 5 - COMPLETEDCreate new intake provider definition for Step by Step IOM Tutorial Scenario- Microsoft Dynamics 365 Intelligent Order Management / Register a new Provider in Library

Step 6 - COMPLETEDCreate a provider message request handler for Quick Start Lab Scenario for Microsoft Intelligent order Management IOM tutorial

Step 7Create Fulfillment provider in Microsoft Dynamics Intelligent Order Management IOM – Order to Fulfillment in IOM

Step 8Add a provider definition logic definition to the Outlook Provider Definition in Microsoft Dynamics Intelligent Management IOM

Step 9Create a provider action - Power Automate Flow - to send a fulfillment Order payload to RequestBin

Step 10Activate the Intake, Fulfillment, & Internal Application Service provider created in Previous Step by Step IOM Tutorial

Step 11Create Orchestration policies and their associated rules for Quick Start Lab Scenario in Microsoft Dynamics 365 Intelligent Order Management IOM

Step 12Create Sales Order Orchestration flow in Microsoft Dynamics Intelligent Order Management IOM

Step 13Set up Customer(Account) and product mapping in Microsoft Dynamics Intelligent order Management IOM

Step 14Run a sample order orchestration flow in Microsoft Dynamics 365 Intelligent Order Management - END TO END DEMO IOM

PREVIOUS STEP 6 - COMPLETEDCreate a provider message request handler for Quick Start Lab Scenario for Microsoft Intelligent order Management IOM tutorial

Create New Provider Defination

Create new provider definition:

For Creating a provider, we should follow these steps:

  • Go to Providers > Library.
  • Select New Provider Definition.

Create new provider definition: — screenshot 1
Create new provider definition: — screenshot 1 View full size

  • For Display Name, enter “IOMLabFulfillmentProvider”.
  • For Logical Name, enter “msdyn_IOMLabFulfillmentProvider”.
  • For Description, enter “IOM lab fulfillment provider”.
  • For Logo, select “IOMLab.png”.
  • For Service Type, enter “Fulfillment”.
  • Skip next tabs (Logical definition and transformation) by Clicking Next.
  • Select Save and close on summary.

Create new provider definition: — screenshot 2
Create new provider definition: — screenshot 2 View full size

Add provider definition to solution

To add a provider definition to the solution, follow these steps.

  1. Go to the Power App Maker portal and navigate to the newly-created solution IOMLabProviders.
  2. Select Add existing > Provider Definition.
  3. Select IOMLabFulfillmentProvider and then select Add to add it to the solution.

Add provider definition to solution — screenshot 3
Add provider definition to solution — screenshot 3 View full size

To create a provider action to send a fulfillment payload to Outlook, follow these steps.

  1. Go to the Power App Maker portal and navigate to Solutions.
  2. Open the Default Solution or you can create a new Solution.

To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 4
To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 4 View full size

  1. Then Click on Create.
  2. Select New.

To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 5
To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 5 View full size

  1. Select Cloud Flow> automated and then name it “IOM Lab Send To Fulfillment (Outlook)”.

To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 6
To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 6 View full size

      1. Select the trigger action type as When an http request is received and then do the following:
      2. Copy the code given below and paste it into your Request Body JSON Schema section.
Code example
{
"type": "object",
"properties": {
"text": {
"title": "ProviderActionExecutionEventId",
"type": "string",
"x-ms-dynamically-added": true,
"description": "Please enter your input",
"x-ms-content-hint": "TEXT"
},
"text_1": {
"title": "EntityRecordId",
"type": "string",
"x-ms-dynamically-added": true,
"description": "Please enter your input",
"x-ms-content-hint": "TEXT"
}
},
"required": [
"text",
"text_1"
]
}

To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 7
To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 7 View full size

  • Then click on +New Step.
  • Create a variable initialization action:
    • For Name, enter “ExecutionResult”.
    • For Type, select Boolean.
    • For Value, enter “true”.
  • You Can rename it too with a suitable name for understanding.:

To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 8
To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 8 View full size

Create a second variable initialization action:

  • For Name, enter “ProcessedSaleOrderLines”.
  • For Type, select Array.

Create a third variable initialization action:

  • For Name, enter “ProcessedFulfillmentOrderLines”.
  • For Type, select Array.

To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 9
To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 9 View full size

  • Add a Try scope.
  • Within the Try scope, add a Perform an unbound action action as follows:
  • ProviderActionExecutionEventId: Under Dynamic content, select ProviderActionExecutionEventId.
  • PowerAutomateRunId: Specify the following as an expression: workflow()['run']?['name'].

To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 10
To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 10 View full size

Add a Get a row by ID action and then do the following:

  • For Table name, enter “Fulfillment Orders”.
  • For Row ID, select EntityRecordId under Dynamic content.

To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 11
To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 11 View full size

Add a Send an email action from the Outlook.com connector, as follows. There are couple of email connectors, make sure to select Outlook.com since that’s the connection set up earlier.

  • On the To line, “placeholder@placeholder.com” is used as placeholder text. This will be replaced by a provider parameter in later steps.
  • On the Subject line, “name” is obtained from the Get fulfillment order step under Dynamic content.
  • For Body, specify the following as an expression: outputs('Get_fulfillment_order')['body']

To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 12
To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 12 View full size

Add a List rows action as follows:

  • For Table name, enter “Fulfillment Order Products”.
  • For Fetch Xml query enter the following:
Code example
<fetch> <entity name="msdyn_fulfillmentorderdetail"> <all-attributes /> <filter> <condition attribute="msdyn_fulfillmentid" operator="eq" value="@{triggerBody()['text_1']}"/> </filter> </entity> </fetch>

To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 13
To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 13 View full size

Add an Apply to each control with a Send an email action as follows:

  • value is obtained from the Get fulfillment order line step under Dynamic content.
  • name is obtained from the Get fulfillment order line step under Dynamic content.
  • Current item is selected from under Dynamic content.

To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 14
To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 14 View full size

Within the loop, add an Append to array variable action as follows:

  • For Name, enter “ProcessedFulfillmentOrderLines”.
  • For Value, select Fulfillment line ID from under Dynamic content.

To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 15
To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 15 View full size

Within the loop, add another Append to array variable action as follows:

  • For Name, enter “ProcessedSalesOrderLines”.
  • For Value, select Sales line ID from under Dynamic content.

To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 16
To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 16 View full size

  • Collapse the Try scope by selecting its title bar.
  • Select New step and add another scope named “Catch”.
  • On the Catch scope, select the ellipsis (“…“), select Configure run after, and configure as follows:
    1. Select the has failed checkbox.
    2. Select the has timed out checkbox.

To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 17
To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 17 View full size

  • In the Catch scope, select Add an action and add a Set variable action, and rename it “Set the execution result to failed”.
  • Configure the properties as follows:
    1. For Name, enter “ExecutionResult”.
    2. For Value, enter “false”.

To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 18
To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 18 View full size

  • Select New step, and add another scope named “Finally”.
  • On the Finally scope, select the ellipsis (“…“), select Configure run after, and configure as follows:
    1. Select the is successful checkbox.
    2. Select the has timed out checkbox.
    3. Select the is skipped checkbox.
    4. Select the has timed out checkbox.

To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 19
To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 19 View full size

  • In the Finally scope, add a “condition” step and compare the ExecutionResult variable to true as follows:
  1. In the first field, select the ExecutionResult variable.
  2. In the second field, select is equal to.
  3. In the third field, select true.
  • In the If yes branch, add a Run a child flow action and rename it “Raise Business Events for processed fulfillment order lines”.
  • Configure the properties as follows:
    1. For Child flow, enter “IOM Raise Business Event”.
    2. For BusinessEventDefinitionId, enter “063d85c8-60a4-eb11-9443-000d3a313675”.
    3. For EntityRecordId, specify the following as expressions: string(variables('ProcessedFulfillmentOrderLines'))
  • In the If yes branch, add another Run a child flow action and rename it “Raise Sales Order Aggregated Events”.
  • Configure the properties as follows:
    1. For LineBusinessEventDefinitionId, enter “ccf64002-61a4-eb11-9443-000d3a313675”.
    2. For LineRecordId, specify the following as an expression: string(variables('ProcessedSalesOrderLines')).
    3. For OrderBusinessEventDefinitionId, enter “48688716-61a4-eb11-9443-000d3a313675”.

To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 20
To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 20 View full size

  • Collapse the condition step.
  • Add a Perform an unbound action action as follows:
    1. For Action name, enter “msdyn_CompleteProviderActionExecution”.
    2. For ExecutionResult, select the ExecutionResult variable from under Dynamic content.
    3. For ProviderActionExecutionEventId, select ProviderActionExecutionEventId from under Dynamic conten

To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 21
To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 21 View full size

To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 22
To create a provider action to send a fulfillment payload to Outlook, follow these steps. — screenshot 22 View full size

Step 8Add a provider definition logic definition to the Outlook Provider Definition in Microsoft Dynamics Intelligent Management IOM

Need help applying this to your business?

Talk to our team about your systems and next step.

Talk to our team
Open original image