To send parameters data or call a method from the Logic app to Dynamics 365 F&O using Data Entity, you need to follow the below steps:
Create a data entity in Dynamics 365 F&O, Now create a method as shown below
Method:
public class LSAPIINTAmazonOrderHeaderEntity extends common
{
[SysODataActionAttribute("insertRecordInLSAPIOrderOrderCallResponseEntity", false)]
public static boolean insertRecordInLCRProtestStaging(Str _record, Str _LSSPAPIOrderType)
{
boolean Success = true;
if(_LSSPAPIOrderType == "Header")
{
info(_record);
}
return success;
}
}
![Execute action in logic app](https://dynamicscommunity101.com/wp-content/uploads/2024/05/Execute-action-in-Logic-app.png)
Now go to the Logic app and search for Execute action and you will be able to see 2 parameters(Instance and action),
For instance, you need to fill Your Dynamics 365 F&O URL
In Action you need to enter Data entity method you created(Name of DataEntity-Method)
Now you can add the parameters as specified by you in the Data Entity method and pass the values as required
![Execute action with parameters](https://dynamicscommunity101.com/wp-content/uploads/2024/05/Execute-action-with-parameters.png)
So whenever this logic app runs, it will call this D365 Data entity method and perform the operation you have written on the Data entity method.
Need help? Connect Atul
Latest posts by Atul Yadav (see all)
- D365 business events return JSON - July 20, 2024
- How to setup D365 business event - July 14, 2024
- IP level security on Dynamics 365 F&O Dev Server using NSG - July 5, 2024