Call a method or Send parameters data from the Logic app to Microsoft Dynamics 365 F&O using Data Entity

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

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

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

Atul Yadav

Comments

No comments yet. Why don’t you start the discussion?

Leave a Reply

Your email address will not be published. Required fields are marked *